/* ==========================================================================
   GHA Public Profile — Instructor & Student Profile Page
   Design System v2
   ========================================================================== */

.gha-profile {
    background: var(--gha-bg);
    padding: 0 20px 60px;
    min-height: calc(100vh - 90px);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.gha-profile-inner {
    max-width: 900px;
    margin: 0 auto;
}

/* ==========================================================================
   1. HERO / EN-TETE PROFIL
   ========================================================================== */

.gha-profile-hero {
    display: flex;
    align-items: center;
    gap: 28px;
    padding: 40px 0 32px;
    border-bottom: 1px solid var(--gha-border);
    margin-bottom: 32px;
}

.gha-profile-avatar {
    flex-shrink: 0;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    border: 4px solid var(--gha-white);
    box-shadow: var(--gha-shadow-md);
}

.gha-profile-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gha-profile-info {
    flex: 1;
    min-width: 0;
}

.gha-profile-name {
    font-family: 'Sora', sans-serif;
    font-size: 28px;
    font-weight: 800;
    color: var(--gha-text);
    margin: 0 0 8px;
    line-height: 1.2;
}

.gha-profile-rating {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
}

.gha-profile-rating .gha-stars {
    display: inline-flex;
    gap: 1px;
}

.gha-profile-rating .gha-star {
    color: #facc15;
    font-size: 16px;
    line-height: 1;
}

.gha-profile-rating .gha-star-empty {
    color: #e2e8f0;
}

.gha-profile-rating .gha-star-half {
    color: #facc15;
}

.gha-profile-rating-value {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 15px;
    font-weight: 700;
    color: var(--gha-text);
}

.gha-profile-rating-count {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 13px;
    color: var(--gha-text-secondary);
}

.gha-profile-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.gha-profile-stat {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: var(--gha-bg);
    border: 1px solid var(--gha-border);
    border-radius: 20px;
    padding: 6px 14px;
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 13px;
    font-weight: 600;
    color: var(--gha-text-secondary);
}

.gha-profile-stat svg {
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    color: var(--gha-primary);
}

/* ==========================================================================
   2. SECTION-CARD (Bio, Cours)
   ========================================================================== */

.gha-profile-section {
    background: var(--gha-white);
    border: 1px solid var(--gha-border);
    border-radius: var(--gha-radius);
    overflow: hidden;
    margin-bottom: 32px;
}

.gha-profile-section-header {
    background: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    padding: 14px 20px;
    border-bottom: 1px solid var(--gha-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.gha-profile-section-title {
    font-family: 'Sora', sans-serif;
    font-size: 16px;
    font-weight: 700;
    color: var(--gha-text);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.gha-profile-section-title svg {
    width: 18px;
    height: 18px;
    color: var(--gha-primary);
    flex-shrink: 0;
}

.gha-profile-section-badge {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 12px;
    font-weight: 600;
    padding: 4px 10px;
    border-radius: 12px;
    background: var(--gha-primary-light);
    color: #1e3a8a;
}

.gha-profile-section-body {
    padding: 24px 20px;
}

/* Bio text styling */
.gha-profile-bio {
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 15px;
    line-height: 1.7;
    color: var(--gha-text);
}

.gha-profile-bio p {
    margin: 0 0 16px;
}

.gha-profile-bio p:last-child {
    margin-bottom: 0;
}

.gha-profile-bio a {
    color: var(--gha-primary);
    text-decoration: none;
    font-weight: 600;
}

.gha-profile-bio a:hover {
    text-decoration: underline;
}

/* ==========================================================================
   3. GRILLE DE COURS
   ========================================================================== */

.gha-profile-courses-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    padding: 20px;
}

/* Etat vide */
.gha-profile-empty {
    text-align: center;
    padding: 48px 20px;
    color: var(--gha-text-secondary);
    font-family: 'Inter', system-ui, sans-serif;
    font-size: 15px;
}

/* ==========================================================================
   4. RESPONSIVE
   ========================================================================== */

/* Tablette */
@media (max-width: 991px) {
    .gha-profile-hero {
        gap: 20px;
        padding: 32px 0 28px;
    }

    .gha-profile-avatar {
        width: 96px;
        height: 96px;
    }

    .gha-profile-name {
        font-size: 24px;
    }

    .gha-profile-courses-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 16px;
    }
}

/* Mobile */
@media (max-width: 600px) {
    .gha-profile {
        padding: 0 16px 40px;
    }

    .gha-profile-hero {
        flex-direction: column;
        text-align: center;
        gap: 16px;
        padding: 28px 0 24px;
    }

    .gha-profile-avatar {
        width: 88px;
        height: 88px;
    }

    .gha-profile-name {
        font-size: 22px;
    }

    .gha-profile-stats {
        justify-content: center;
    }

    .gha-profile-rating {
        justify-content: center;
    }

    .gha-profile-courses-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        padding: 16px;
    }

    .gha-profile-section-body {
        padding: 20px 16px;
    }
}
