/* ==========================================================================
   AFIRIN PROFILE SYSTEM - DESIGN SPECIFICATION MATCHING REFERENCE SCREENSHOT
   Exact layout, proportions, colors, card density, and hierarchy
   ========================================================================== */

:root {
    --af-primary: #fa470d;
    --af-primary-hover: #e03a04;
    --af-primary-deep: #9a2400;
    --af-primary-soft: #fff4f0;
    --af-primary-soft-hover: #ffe7df;
    --af-primary-border: #fed4c4;
    --af-primary-text: #ffffff;
    --af-primary-glow: rgba(250, 71, 13, 0.35);
    --af-primary-focus: rgba(250, 71, 13, 0.40);
    --af-primary-gradient: linear-gradient(135deg, #fa470d 0%, #e03a04 100%);
    --af-primary-rgb: 250, 71, 13;
    --af-blue-primary: var(--af-primary);
    --af-blue-deep: var(--af-primary-deep);
    --af-blue-soft: var(--af-primary-soft);
    --af-blue-border: var(--af-primary-border);
    --af-bg-canvas: #ebf3fa;
    --af-text-dark: #0f172a;
    --af-text-muted: #64748b;
    --af-card-bg: #ffffff;
    --af-card-border: #e2e8f0;
    --af-radius-card: 20px;
}

/* Base Body for Profile */
.af-profile-body {
    margin: 0;
    padding: 0;
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    background-color: var(--af-bg-canvas);
    color: var(--af-text-dark);
    -webkit-font-smoothing: antialiased;
    box-sizing: border-box;
}

.af-profile-body *,
.af-profile-body *::before,
.af-profile-body *::after {
    box-sizing: border-box;
}

/* ==========================================================================
   1. FULL-WIDTH TOP NAVBAR
   ========================================================================== */
.af-navbar {
    width: 100%;
    height: 66px;
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
}

.af-navbar-inner {
    max-width: 1440px;
    height: 100%;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.af-nav-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}

.af-nav-brand-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.af-brand-title {
    font-size: 20px;
    font-weight: 900;
    color: #0f172a;
    letter-spacing: -0.4px;
    display: block;
    line-height: 1.1;
}

.af-brand-tagline {
    font-size: 9px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    display: block;
}

/* Center Links */
.af-nav-center {
    display: flex;
    align-items: center;
    gap: 20px;
}

.af-nav-link {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 6px 10px;
    color: #475569;
    text-decoration: none;
    font-size: 11px;
    font-weight: 700;
    border-radius: 8px;
    transition: all 0.15s ease;
    background: transparent;
    border: none;
    cursor: pointer;
}

.af-nav-link-icon {
    color: #3b82f6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.af-nav-link:hover,
.af-nav-link.active {
    color: #1d77f2;
}

.af-nav-link.active .af-nav-link-icon {
    color: #1d77f2;
}

.af-nav-more-dropdown {
    position: relative;
}

.af-more-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.08);
    padding: 8px;
    min-width: 160px;
    z-index: 1010;
}

.af-nav-more-dropdown:hover .af-more-menu {
    display: flex;
    flex-direction: column;
}

.af-more-menu a {
    padding: 8px 12px;
    font-size: 12.5px;
    font-weight: 700;
    color: #334155;
    text-decoration: none;
    border-radius: 8px;
}

.af-more-menu a:hover {
    background: #f1f5f9;
    color: #1d77f2;
}

/* Right Nav Actions */
.af-nav-right {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.af-icon-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #475569;
    cursor: pointer;
    transition: all 0.15s ease;
}

.af-icon-btn:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
}

.af-notif-wrap {
    position: relative;
}

.af-notif-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #f43f5e;
    color: #ffffff;
    font-size: 10px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #ffffff;
}

.af-user-pill {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 9999px;
    padding: 3px 10px 3px 4px;
    text-decoration: none;
    transition: all 0.15s ease;
}

.af-user-pill:hover {
    border-color: #bfdbfe;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.08);
}

.af-user-pill-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: cover;
    border: 1px solid #bfdbfe;
}

.af-user-pill-name {
    font-size: 13.5px;
    font-weight: 800;
    color: #0f172a;
}

.af-user-pill-points {
    background: #fef3c7;
    color: #b45309;
    font-size: 12px;
    font-weight: 800;
    padding: 3px 8px;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    gap: 3px;
}

/* ==========================================================================
   2. MAIN CANVAS & 2-COLUMN PAGE GRID
   ========================================================================== */
.af-profile-canvas {
    width: 100%;
    background-color: var(--af-bg-canvas);
}

.af-page-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 20px 24px 40px 24px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

/* Left Rail (~230px) */
.af-left-rail {
    width: 230px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

/* Main Profile Area (Remaining width ~1166px) */
.af-main-area {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ==========================================================================
   3. LEFT RAIL CARDS
   ========================================================================== */
.af-rail-card {
    background: #ffffff;
    border-radius: var(--af-radius-card);
    border: 1px solid var(--af-card-border);
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
    padding: 18px 12px 14px;
    text-align: center;
}

.af-rail-avatar {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: 3px solid #bfdbfe;
    object-fit: cover;
    margin: 0 auto 6px auto;
    display: block;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.1);
}

.af-rail-name {
    font-size: 15px;
    font-weight: 800;
    color: var(--af-text-dark);
    margin-bottom: 14px;
}

.af-rail-menu {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.af-rail-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 700;
    color: #475569;
    text-decoration: none;
    transition: all 0.15s ease;
}

.af-rail-item svg {
    width: 20px;
    height: 20px;
    color: #2563eb;
    flex-shrink: 0;
}

.af-rail-item:hover {
    background: #f0f7ff;
    color: #1d77f2;
}

.af-rail-item.active {
    background: #1d77f2;
    color: #ffffff;
}

.af-rail-item.active svg {
    color: #ffffff;
}

/* Girl Theme Left Nav Active */
.af-profile-girl .af-rail-item.active {
    background: #db2777;
    color: #ffffff;
}

.af-profile-girl .af-rail-item svg {
    color: #db2777;
}

.af-profile-girl .af-rail-item.active svg {
    color: #ffffff;
}

/* Mascot Left Card */
.af-rail-mascot-card {
    background: linear-gradient(180deg, #e0f2fe 0%, #bae6fd 100%);
    border: 1px solid #bae6fd;
    border-radius: var(--af-radius-card);
    padding: 20px 14px 14px;
    text-align: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
}

.af-profile-girl .af-rail-mascot-card {
    background: linear-gradient(180deg, #fce7f3 0%, #fbcfe8 100%);
    border-color: #fbcfe8;
}

.af-mascot-tag-text {
    font-size: 16px;
    font-weight: 900;
    color: #0284c7;
    line-height: 1.25;
    margin-bottom: 10px;
}

.af-profile-girl .af-mascot-tag-text {
    color: #db2777;
}

.af-rail-mascot-img {
    width: 140px;
    height: 160px;
    object-fit: contain;
    margin: 0 auto;
    display: block;
}

.af-mascot-bottom-icon {
    margin-top: 6px;
    font-size: 20px;
}

/* ==========================================================================
   4. MAIN PROFILE AREA: HEADER HERO CARD
   ========================================================================== */
.af-hero-card {
    background: #ffffff;
    border-radius: var(--af-radius-card);
    border: 1px solid var(--af-card-border);
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
    overflow: hidden;
}

.af-cover-wrap {
    height: 270px;
    position: relative;
    background-size: cover;
    background-position: center;
    overflow: hidden;
}

.af-cover-edit-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: rgba(29, 119, 242, 0.9);
    color: #ffffff;
    border: none;
    border-radius: 10px;
    padding: 7px 14px;
    font-size: 12.5px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 6px;
    text-decoration: none;
    backdrop-filter: blur(4px);
    transition: all 0.15s ease;
    z-index: 10;
}

.af-cover-edit-btn:hover {
    background: #1d77f2;
    transform: translateY(-1px);
}

.af-profile-girl .af-cover-edit-btn {
    background: rgba(219, 39, 119, 0.9);
}

/* Identity & Avatar Section */
.af-identity-section {
    padding: 0 28px 12px 28px;
    position: relative;
}

.af-identity-top-row {
    display: flex;
    align-items: flex-start;
}

.af-avatar-box {
    position: relative;
    margin-top: -85px;
    flex-shrink: 0;
    z-index: 20;
}

.af-avatar-img {
    width: 160px;
    height: 160px;
    border-radius: 50%;
    border: 5px solid #ffffff;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
    object-fit: cover;
    background: #ffffff;
    display: block;
}

.af-avatar-camera-btn {
    position: absolute;
    bottom: 8px;
    right: 8px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #2563eb;
    color: #ffffff;
    border: 3px solid #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    text-decoration: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.af-profile-girl .af-avatar-camera-btn {
    background: #db2777;
}

.af-identity-info {
    margin-left: 24px;
    margin-top: 14px;
    flex: 1;
}

.af-user-title-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.af-name-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}

.af-name {
    font-size: 24px;
    font-weight: 800;
    color: #0f172a;
    line-height: 1.2;
}

.af-verified-badge {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #2563eb;
    color: #ffffff;
    font-size: 11px;
    font-weight: 900;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.af-profile-girl .af-verified-badge {
    background: #db2777;
}

.af-edit-profile-btn {
    background: #f0f7ff;
    color: #2563eb;
    border: 1px solid #bfdbfe;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 700;
    padding: 8px 18px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease;
}

.af-edit-profile-btn:hover {
    background: #2563eb;
    color: #ffffff;
}

.af-profile-girl .af-edit-profile-btn {
    background: #fce7f3;
    color: #db2777;
    border-color: #fbcfe8;
}

.af-profile-girl .af-edit-profile-btn:hover {
    background: #db2777;
    color: #ffffff;
}

.af-country-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13.5px;
    color: #475569;
    font-weight: 600;
    margin-top: 4px;
}

.af-bio {
    font-size: 14px;
    color: #475569;
    font-weight: 500;
    margin-top: 4px;
}

/* Summary Metrics Row */
.af-summary-row {
    display: flex;
    align-items: center;
    gap: 36px;
    margin-top: 14px;
    padding-left: 184px; /* Matches avatar offset */
}

.af-stat-item {
    text-align: center;
}

.af-stat-num {
    font-size: 18px;
    font-weight: 900;
    color: #0f172a;
    line-height: 1;
}

.af-stat-lbl {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    margin-top: 4px;
}

/* Tabs Bar */
.af-profile-tabs {
    border-top: 1px solid #f1f5f9;
    padding: 0 28px;
    display: flex;
    gap: 36px;
    margin-top: 14px;
}

.af-tab-link {
    font-size: 14.5px;
    font-weight: 700;
    color: #64748b;
    padding: 14px 0;
    text-decoration: none;
    border-bottom: 3px solid transparent;
    margin-bottom: -1px;
    transition: all 0.15s ease;
    cursor: pointer;
    background: none;
    border-left: none;
    border-right: none;
    border-top: none;
}

.af-tab-link:hover {
    color: #1d77f2;
}

.af-tab-link.active {
    color: #1d77f2;
    border-bottom-color: #1d77f2;
}

.af-profile-girl .af-tab-link:hover,
.af-profile-girl .af-tab-link.active {
    color: #db2777;
    border-bottom-color: #db2777;
}

/* ==========================================================================
   5. THREE-ROW CONTENT GRID (30% | 40% | 30%)
   ========================================================================== */
.af-content-row {
    display: grid;
    grid-template-columns: 3fr 4fr 3fr;
    gap: 18px;
}

.af-card {
    background: #ffffff;
    border-radius: var(--af-radius-card);
    border: 1px solid var(--af-card-border);
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
    padding: 20px 22px;
    display: flex;
    flex-direction: column;
}

.af-card-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.af-card-title {
    font-size: 15.5px;
    font-weight: 800;
    color: var(--af-text-dark);
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
}

.af-card-action {
    font-size: 12.5px;
    font-weight: 700;
    color: #1d77f2;
    text-decoration: none;
}

.af-card-action:hover {
    text-decoration: underline;
}

.af-profile-girl .af-card-action {
    color: #db2777;
}

/* --- ROW 1 COL 1: My Progress --- */
.af-donut-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6px 0;
}

.af-donut-circle {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: conic-gradient(#2563eb calc(var(--score-val, 82) * 1%), #e2e8f0 0);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 8px 24px rgba(37, 99, 235, 0.15);
    margin-bottom: 14px;
}

.af-profile-girl .af-donut-circle {
    background: conic-gradient(#ec4899 calc(var(--score-val, 78) * 1%), #fce7f3 0);
    box-shadow: 0 8px 24px rgba(236, 72, 153, 0.15);
}

.af-donut-inner {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    background: #ffffff;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.af-donut-percent {
    font-size: 26px;
    font-weight: 900;
    color: #0f172a;
    line-height: 1;
}

.af-donut-sub {
    font-size: 11px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.af-donut-quote {
    font-size: 13.5px;
    font-weight: 700;
    font-style: italic;
    color: #1e3a8a;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.af-profile-girl .af-donut-quote {
    color: #9d174d;
}

/* --- ROW 1 COL 2: Subjects Participated --- */
.af-subject-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.af-subj-item {
    display: flex;
    align-items: center;
    gap: 12px;
}

.af-subj-icon-box {
    width: 34px;
    height: 34px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex-shrink: 0;
}

.af-subj-details {
    flex: 1;
}

.af-subj-meta-row {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 4px;
}

.af-subj-bar-bg {
    height: 7px;
    background: #e2e8f0;
    border-radius: 9999px;
    overflow: hidden;
}

.af-subj-bar-fill {
    height: 100%;
    border-radius: 9999px;
    transition: width 0.6s ease;
}

/* --- ROW 1 COL 3: My Achievements --- */
.af-badge-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.af-badge-tile {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 14px 8px;
    text-align: center;
    transition: transform 0.15s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.af-badge-tile:hover {
    transform: translateY(-2px);
    border-color: #bfdbfe;
}

.af-badge-graphic {
    font-size: 2.2rem;
    margin-bottom: 4px;
    line-height: 1;
}

.af-badge-name {
    font-size: 11.5px;
    font-weight: 800;
    color: #1e293b;
    line-height: 1.25;
}

/* --- ROW 2 COL 1: About Me --- */
.af-about-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.af-about-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 13px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f1f5f9;
}

.af-about-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.af-about-lbl {
    font-weight: 700;
    color: #64748b;
    width: 70px;
    flex-shrink: 0;
}

.af-about-val {
    font-weight: 600;
    color: #0f172a;
    flex: 1;
}

/* --- ROW 2 COL 2: Favorite Subjects --- */
.af-fav-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.af-fav-box {
    border-radius: 14px;
    padding: 16px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 8px;
    border: 1px solid transparent;
}

.af-fav-box.purple { background: #f3e8ff; color: #7e22ce; }
.af-fav-box.mint { background: #ecfdf5; color: #047857; }
.af-fav-box.cyan { background: #ecfeff; color: #0e7490; }
.af-fav-box.rose { background: #fff1f2; color: #be123c; }

.af-fav-icon {
    font-size: 28px;
    line-height: 1;
}

.af-fav-name {
    font-size: 13.5px;
    font-weight: 800;
}

/* --- ROW 2 COL 3: My Goals --- */
.af-goals-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.af-goal-row {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    font-weight: 600;
    color: #1e293b;
}

.af-goal-check {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 11px;
    font-weight: 900;
}

.af-goal-check.done {
    background: #10b981;
    color: #ffffff;
}

.af-goal-check.todo {
    border: 2px solid #cbd5e1;
    background: #ffffff;
}

/* --- ROW 3 COL 1: Recent Exams Table --- */
.af-exams-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12.5px;
}

.af-exams-table th {
    text-align: left;
    color: #64748b;
    font-weight: 700;
    padding-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
    font-size: 11.5px;
    text-transform: uppercase;
}

.af-exams-table td {
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.af-exams-table tr:last-child td {
    border-bottom: none;
}

.af-exam-subj-cell {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 700;
    color: #0f172a;
}

.af-exam-score {
    font-weight: 800;
}

.af-score-green { color: #10b981; }
.af-score-blue { color: #3b82f6; }
.af-score-purple { color: #8b5cf6; }
.af-score-orange { color: #f97316; }
.af-score-teal { color: #06b6d4; }

/* --- ROW 3 COL 2: Recent Activity --- */
.af-activity-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.af-activity-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.af-act-icon {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    flex-shrink: 0;
}

.af-act-info {
    flex: 1;
}

.af-act-title {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
    line-height: 1.25;
}

.af-act-time {
    font-size: 11.5px;
    color: #94a3b8;
    margin-top: 2px;
}

/* --- ROW 3 COL 3: Motivational Mascot Card --- */
.af-moti-card {
    background: linear-gradient(180deg, #dbeafe 0%, #bfdbfe 100%);
    border-radius: var(--af-radius-card);
    border: 1px solid #bfdbfe;
    padding: 16px 18px;
    text-align: center;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-between;
}

.af-profile-girl .af-moti-card {
    background: linear-gradient(180deg, #fce7f3 0%, #fbcfe8 100%);
    border-color: #fbcfe8;
}

.af-moti-slogan {
    font-size: 16px;
    font-weight: 900;
    color: #1d4ed8;
    line-height: 1.2;
    margin-bottom: 8px;
}

.af-profile-girl .af-moti-slogan {
    color: #be185d;
}

.af-moti-img {
    width: 140px;
    height: 150px;
    object-fit: contain;
    margin: 0 auto;
}

/* ==========================================================================
   6. DECORATIVE OCEAN WAVE FOOTER
   ========================================================================== */
.af-profile-footer {
    width: 100%;
    margin-top: 36px;
    background: linear-gradient(180deg, #1d4ed8 0%, #1e3a8a 100%);
    color: #ffffff;
    padding: 36px 20px 48px;
    text-align: center;
    position: relative;
    border-top-left-radius: 40px;
    border-top-right-radius: 40px;
}

.af-profile-girl .af-profile-footer {
    background: linear-gradient(180deg, #ec4899 0%, #be185d 100%);
}

.af-footer-brand {
    font-size: 24px;
    font-weight: 900;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
}

.af-footer-sub {
    font-size: 13px;
    font-weight: 600;
    opacity: 0.9;
    margin-bottom: 12px;
}

.af-footer-slogan {
    font-size: 14.5px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.15);
    padding: 6px 18px;
    border-radius: 9999px;
}

/* ==========================================================================
   7. RESPONSIVE MEDIA QUERIES
   ========================================================================== */
@media (max-width: 1200px) {
    .af-content-row {
        grid-template-columns: 1fr 1fr;
    }
    .af-content-row > div:nth-child(3) {
        grid-column: span 2;
    }
}

@media (max-width: 992px) {
    .af-page-container {
        flex-direction: column;
        padding: 16px 16px 30px;
    }
    .af-left-rail {
        width: 100%;
    }
    .af-nav-center {
        display: none;
    }
    .af-content-row {
        grid-template-columns: 1fr;
    }
    .af-content-row > div:nth-child(3) {
        grid-column: span 1;
    }
    .af-summary-row {
        padding-left: 0;
        justify-content: space-around;
        gap: 16px;
    }
    .af-identity-top-row {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .af-identity-info {
        margin-left: 0;
        margin-top: 14px;
        width: 100%;
    }
    .af-user-title-row {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
}

/* Aliases for Parent and Legacy class names */
.af-profile-sidebar {
    width: 230px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.af-profile-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.af-side-card {
    background: #ffffff;
    border-radius: var(--af-radius-card);
    border: 1px solid var(--af-card-border);
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.04);
    padding: 18px 12px 14px;
    text-align: center;
}

.af-side-user-header {
    text-align: center;
    margin-bottom: 12px;
}

.af-side-avatar {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: 3px solid #bfdbfe;
    object-fit: cover;
    margin: 0 auto 6px auto;
    display: block;
}

.af-side-name {
    font-size: 15px;
    font-weight: 800;
    color: var(--af-text-dark);
}

.af-side-role {
    font-size: 11.5px;
    color: #64748b;
    font-weight: 600;
}

.af-side-nav {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-top: 10px;
}

.af-side-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 14px;
    border-radius: 12px;
    font-size: 13.5px;
    font-weight: 700;
    color: #475569;
    text-decoration: none;
    transition: all 0.15s ease;
}

.af-side-link svg {
    width: 20px;
    height: 20px;
    color: #0d9488;
    flex-shrink: 0;
}

.af-side-link:hover {
    background: #f0fdfa;
    color: #0d9488;
}

.af-side-link.active {
    background: #0d9488;
    color: #ffffff;
}

.af-side-link.active svg {
    color: #ffffff;
}

/* Authenticated User Header Dropdown */
.af-header-user-wrap {
    position: relative;
    display: inline-block;
}
.af-chip-chevron,
.af-pill-chevron {
    font-size: 11px;
    color: #94a3b8;
    margin-left: 2px;
    transition: transform 0.2s ease;
}
.af-header-user-wrap:hover .af-chip-chevron,
.af-header-user-wrap:hover .af-pill-chevron {
    transform: rotate(180deg);
}
.af-header-user-dropdown {
    display: none;
    position: absolute;
    top: calc(100% + 6px);
    right: 0;
    min-width: 180px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    padding: 6px;
    z-index: 1000;
}
.af-header-user-wrap:hover .af-header-user-dropdown,
.af-header-user-wrap:focus-within .af-header-user-dropdown {
    display: block;
}
.af-user-dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 12px;
    font-size: 13px;
    font-weight: 700;
    color: #475569;
    text-decoration: none;
    border-radius: 8px;
    background: transparent;
    border: none;
    width: 100%;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    transition: all 0.15s ease;
}
.af-user-dropdown-item:hover {
    background: #f8fafc;
    color: #1e293b;
}
.af-user-dropdown-item svg {
    color: #64748b;
    flex-shrink: 0;
}
.af-user-dropdown-divider {
    height: 1px;
    background: #f1f5f9;
    margin: 4px 0;
}
.af-dropdown-logout-form {
    margin: 0;
    padding: 0;
}
.af-user-dropdown-item.af-user-dropdown-logout {
    color: #ef4444;
}
.af-user-dropdown-item.af-user-dropdown-logout svg {
    color: #ef4444;
}
.af-user-dropdown-item.af-user-dropdown-logout:hover {
    background: #fef2f2;
    color: #dc2626;
}
.af-user-dropdown-item.af-user-dropdown-logout:hover svg {
    color: #dc2626;
}

/* Sidebar Logout Button */
.af-side-logout-form,
.af-rail-logout-form {
    margin: 0;
    padding: 0;
    width: 100%;
}
.af-side-link.af-side-link-logout,
.af-rail-item.af-rail-item-logout {
    width: 100%;
    background: transparent;
    border: none;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    color: #ef4444 !important;
}
.af-side-link.af-side-link-logout svg,
.af-rail-item.af-rail-item-logout svg {
    color: #ef4444 !important;
}
.af-side-link.af-side-link-logout:hover,
.af-rail-item.af-rail-item-logout:hover {
    background: #fef2f2 !important;
    color: #dc2626 !important;
}
.af-side-link.af-side-link-logout:hover svg,
.af-rail-item.af-rail-item-logout:hover svg {
    color: #dc2626 !important;
}

.af-more-logout-btn {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    font-size: 12.5px;
    font-weight: 700;
    color: #ef4444;
    background: none;
    border: none;
    cursor: pointer;
    text-align: left;
    border-radius: 8px;
    font-family: inherit;
    transition: all 0.15s ease;
}
.af-more-logout-btn:hover {
    background: #fef2f2;
    color: #dc2626;
}


