/* =============================================================
   OvationLMS — Learner Dashboard  (v2 UI refresh)
   Same class names & structure as before — refreshed visuals only.
   Mobile-first · calm surfaces · crisp cards · confident type.
   ============================================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:ital,wght@0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,400&family=Plus+Jakarta+Sans:wght@600;700;800&display=swap');

/* ── DESIGN TOKENS ────────────────────────────────────────── */
/* Global fallback: the same tokens as .ovfd-root below, defined on :root too.
   .ovfd-* classes (input, button, card, etc.) are reused outside the learner
   dashboard — e.g. the admin portal course editor — where .ovfd-root never
   wraps the page. Without this, every var(--ovfd-*) resolves to nothing and
   inputs/cards/buttons render with no border, background, or radius. Elements
   inside .ovfd-root still get its own values (closer ancestor wins); this
   block only fills the gap everywhere else. */
:root{
    --ovfd-bg:        #f4f5f8;
    --ovfd-surface:   #ffffff;
    --ovfd-surface-2: #fafbfc;
    --ovfd-border:    #e9ebf0;
    --ovfd-border-2:  #f0f2f5;
    --ovfd-ink:       #14161c;
    --ovfd-ink-2:     #4b5160;
    --ovfd-ink-3:     #8b91a1;
    --ovfd-primary:   var(--ovlms-primary,   #FFDE17);
    --ovfd-secondary: var(--ovlms-secondary, #B9D13D);
    --ovfd-dark:      var(--ovlms-dark,       #1C1A1A);
    --ovfd-accent:    var(--ovlms-accent,     #E42F3B);
    --ovfd-r:    16px;
    --ovfd-r-sm: 11px;
    --ovfd-r-lg: 22px;
    --ovfd-shadow-sm: 0 1px 2px rgba(20,22,28,.05), 0 1px 3px rgba(20,22,28,.04);
    --ovfd-shadow:    0 2px 6px rgba(20,22,28,.05), 0 8px 24px -12px rgba(20,22,28,.12);
    --ovfd-shadow-lg: 0 12px 40px -12px rgba(20,22,28,.18);
    --ovfd-ring:      0 0 0 3px rgba(255,222,23,.35);
}
.ovfd-root{
    --ovfd-bg:        #f4f5f8;
    --ovfd-surface:   #ffffff;
    --ovfd-surface-2: #fafbfc;
    --ovfd-border:    #e9ebf0;
    --ovfd-border-2:  #f0f2f5;
    --ovfd-ink:       #14161c;
    --ovfd-ink-2:     #4b5160;
    --ovfd-ink-3:     #8b91a1;
    --ovfd-primary:   var(--ovlms-primary,   #FFDE17);
    --ovfd-secondary: var(--ovlms-secondary, #B9D13D);
    --ovfd-dark:      var(--ovlms-dark,       #1C1A1A);
    --ovfd-accent:    var(--ovlms-accent,     #E42F3B);
    --ovfd-r:    16px;
    --ovfd-r-sm: 11px;
    --ovfd-r-lg: 22px;
    --ovfd-shadow-sm: 0 1px 2px rgba(20,22,28,.05), 0 1px 3px rgba(20,22,28,.04);
    --ovfd-shadow:    0 2px 6px rgba(20,22,28,.05), 0 8px 24px -12px rgba(20,22,28,.12);
    --ovfd-shadow-lg: 0 12px 40px -12px rgba(20,22,28,.18);
    --ovfd-ring:      0 0 0 3px rgba(255,222,23,.35);
}

/* ── RESET & BASE ─────────────────────────────────────────── */
.ovfd-root,
.ovfd-root *{ box-sizing:border-box; }
.ovfd-root{
    font-family: var(--ovlms-font, 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif);
    -webkit-font-smoothing:antialiased;
    -moz-osx-font-smoothing:grayscale;
    background:var(--ovfd-bg);
    color:var(--ovfd-ink);
    min-height:100vh;
    line-height:1.55;
    letter-spacing:-0.005em;
}
.ovfd-root h1,.ovfd-root h2,.ovfd-root h3{ font-family:'Plus Jakarta Sans','Inter',sans-serif; letter-spacing:-0.02em; }

/* ── LAYOUT ───────────────────────────────────────────────── */
.ovfd-layout{ display:flex; min-height:100vh; }

/* ── SIDEBAR (desktop) ────────────────────────────────────── */
.ovfd-sidebar{
    width:264px; flex-shrink:0;
    background:var(--ovfd-surface);
    border-right:1px solid var(--ovfd-border);
    display:flex; flex-direction:column;
    position:sticky; top:0; height:100vh;
    overflow-y:auto; scrollbar-width:none; z-index:50;
}
.ovfd-sidebar::-webkit-scrollbar{ display:none; }
.ovfd-sidebar-logo{ display:flex; align-items:center; gap:10px; padding:22px 22px 14px; min-height:64px; }
.ovfd-sidebar-logo-icon{
    width:42px; height:42px; border-radius:12px;
    display:flex; align-items:center; justify-content:center;
    font-size:20px; flex-shrink:0;
    background:linear-gradient(135deg,var(--ovfd-primary),var(--ovfd-secondary));
    box-shadow:0 6px 16px -6px rgba(255,222,23,.6);
}
.ovfd-sidebar-logo-name{ font-size:15px; font-weight:800; color:var(--ovfd-ink); }
.ovfd-sidebar-logo-role{ font-size:11px; color:var(--ovfd-ink-3); }
.ovfd-sidebar-user{
    display:flex; align-items:center; gap:11px;
    margin:2px 14px 12px; padding:12px;
    background:var(--ovfd-surface-2); border:1px solid var(--ovfd-border-2);
    border-radius:var(--ovfd-r-sm);
}
.ovfd-sidebar-user-avatar{ width:40px; height:40px; border-radius:50%; flex-shrink:0; object-fit:cover; border:2px solid var(--ovfd-primary); }
.ovfd-sidebar-user-name{ font-size:13.5px; font-weight:700; color:var(--ovfd-ink); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:150px; }
.ovfd-sidebar-user-email{ font-size:11px; color:var(--ovfd-ink-3); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; max-width:150px; }
.ovfd-sidebar-user-role{
    display:inline-block; margin-top:3px;
    font-size:9px; font-weight:800; letter-spacing:.6px; text-transform:uppercase;
    color:#9a7d00; background:rgba(255,222,23,.22);
    padding:2px 7px; border-radius:5px;
}
.ovfd-sidebar-nav{ flex:1; padding:4px 14px; }
.ovfd-sidebar-nav-group{ margin-bottom:18px; }
.ovfd-sidebar-nav-label{ font-size:10px; font-weight:800; letter-spacing:1px; text-transform:uppercase; color:var(--ovfd-ink-3); padding:0 10px; margin-bottom:6px; }
.ovfd-sidebar-nav-item{
    display:flex; align-items:center; gap:11px; width:100%;
    padding:9px 11px; margin-bottom:2px;
    background:transparent; border:none; border-radius:10px;
    font-family:inherit; font-size:13.5px; font-weight:600; color:var(--ovfd-ink-2);
    cursor:pointer; text-align:left; text-decoration:none; position:relative;
    transition:background .16s, color .16s;
}
.ovfd-sidebar-nav-item:hover{ background:var(--ovfd-surface-2); color:var(--ovfd-ink); }
.ovfd-sidebar-nav-item.active{
    background:linear-gradient(90deg, rgba(255,222,23,.16), rgba(185,209,61,.10));
    color:var(--ovfd-ink); font-weight:800;
}
.ovfd-sidebar-nav-item.active::before{
    content:''; position:absolute; left:-14px; top:50%; transform:translateY(-50%);
    width:4px; height:22px; border-radius:0 4px 4px 0;
    background:linear-gradient(var(--ovfd-primary),var(--ovfd-secondary));
}
.ovfd-nav-icon{ font-size:16px; width:20px; text-align:center; flex-shrink:0; }
.ovfd-nav-label{ flex:1; }
.ovfd-nav-count,
.ovfd-nav-badge{ background:var(--ovfd-surface-2); color:var(--ovfd-ink-2); font-size:10px; font-weight:800; padding:2px 8px; border-radius:999px; border:1px solid var(--ovfd-border); }
.ovfd-sidebar-nav-item.active .ovfd-nav-count{ background:var(--ovfd-primary); color:var(--ovfd-dark); border-color:transparent; }
.ovfd-sidebar-footer{ padding:10px 14px 6px; border-top:1px solid var(--ovfd-border-2); }
.ovfd-home-link:hover{ color:var(--ovfd-ink); }
.ovfd-logout-link{ color:var(--ovfd-accent) !important; }
.ovfd-logout-link:hover{ background:rgba(228,47,59,.08); }

/* ── MAIN ─────────────────────────────────────────────────── */
.ovfd-main{ flex:1; min-width:0; display:flex; flex-direction:column; }
.ovfd-xp-card{
    background:
        radial-gradient(120% 160% at 100% 0%, rgba(255,222,23,.14), transparent 60%),
        linear-gradient(135deg, var(--ovfd-dark) 0%, #2a2724 100%);
    color:#fff; padding:16px 20px;
}
#ovfd-top-xp{ padding-left:max(40px, calc((100% - 1100px)/2)); padding-right:max(40px, calc((100% - 1100px)/2)); border-radius:0; margin-bottom:0; }
.ovfd-xp-top-row{ display:flex; justify-content:space-between; align-items:center; margin-bottom:9px; }
.ovfd-xp-level{ font-size:12px; font-weight:800; background:var(--ovfd-primary); color:var(--ovfd-dark); padding:3px 11px; border-radius:999px; }
.ovfd-xp-pts{ font-size:13px; font-weight:700; color:rgba(255,255,255,.92); }
.ovfd-xp-track{ height:7px; background:rgba(255,255,255,.14); border-radius:999px; overflow:hidden; }
.ovfd-xp-fill{ height:100%; border-radius:999px; background:linear-gradient(90deg, var(--ovfd-primary), var(--ovfd-secondary)); box-shadow:0 0 12px rgba(255,222,23,.5); transition:width .9s cubic-bezier(.4,0,.2,1); }
.ovfd-xp-sub{ font-size:11.5px; color:rgba(255,255,255,.6); margin-top:8px; }
.ovfd-topbar{
    height:64px; background:var(--ovfd-surface); border-bottom:1px solid var(--ovfd-border);
    display:flex; align-items:center; gap:16px;
    padding-left:max(40px, calc((100% - 1100px)/2)); padding-right:max(40px, calc((100% - 1100px)/2));
    position:sticky; top:0; z-index:40;
}
.ovfd-topbar-title{ font-size:17px; font-weight:800; color:var(--ovfd-ink); font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-topbar-spacer{ flex:1; }
.ovfd-topbar-actions{ display:flex; align-items:center; gap:10px; }
.ovfd-body{ flex:1; width:100%; box-sizing:border-box; padding:32px max(56px, calc((100% - 1100px)/2)); }

/* ── MOBILE bits hidden on desktop ────────────────────────── */
.ovfd-mobile-header,.ovfd-mobile-hero,.ovfd-tab-bar,.ovfd-drawer,.ovfd-drawer-overlay{ display:none; }
.ovfd-mobile-header-greeting{ font-size:14px; font-weight:800; color:var(--ovfd-ink); }
.ovfd-mobile-icon-btn{ width:38px; height:38px; border-radius:11px; display:flex; align-items:center; justify-content:center; background:var(--ovfd-surface-2); border:1px solid var(--ovfd-border); color:var(--ovfd-ink-2); cursor:pointer; position:relative; text-decoration:none; }
.ovfd-mobile-icon-btn svg{ width:20px; height:20px; stroke-width:2.2; }
.ovfd-mobile-icon-btn:active{ transform:scale(.94); }
.ovfd-mobile-avatar-btn{ padding:0; overflow:hidden; }
.ovfd-mobile-avatar-btn img{ width:100%; height:100%; object-fit:cover; }
.ovfd-cart-icon-btn{ width:38px; height:38px; border-radius:11px; display:flex; align-items:center; justify-content:center; background:var(--ovfd-surface-2); border:1px solid var(--ovfd-border); color:var(--ovfd-ink-2); cursor:pointer; position:relative; }
.ovfd-cart-icon-btn svg{ width:20px; height:20px; stroke-width:2.2; }
.ovfd-cart-badge{ position:absolute; top:-5px; right:-5px; min-width:17px; height:17px; padding:0 4px; background:var(--ovfd-accent); color:#fff; font-size:10px; font-weight:800; border-radius:999px; display:flex; align-items:center; justify-content:center; border:2px solid var(--ovfd-surface); }
/* Desktop topbar cart button (light themed, sits in the white topbar) */
.ovfd-cart-icon-btn--desktop{ width:48px; height:48px; border-radius:13px; background:var(--ovfd-surface-2); border:1px solid var(--ovfd-border); color:var(--ovfd-ink); }
.ovfd-cart-icon-btn--desktop svg{ width:26px; height:26px; stroke-width:2.4; }
.ovfd-cart-icon-btn--desktop:hover{ background:var(--ovfd-surface); border-color:var(--ovfd-ink-3); color:var(--ovfd-ink); }
.ovfd-cart-icon-btn--desktop .ovfd-cart-badge{ border-color:var(--ovfd-surface); }
.ovfd-mobile-stat{ flex-shrink:0; min-width:74px; background:rgba(255,255,255,.08); border:1px solid rgba(255,255,255,.12); border-radius:12px; padding:10px 12px; text-align:center; }
.ovfd-mobile-stat-val{ font-size:17px; font-weight:800; color:#fff; line-height:1.1; }
.ovfd-mobile-stat-lbl{ font-size:10px; color:rgba(255,255,255,.6); margin-top:2px; }

/* ── PANES ────────────────────────────────────────────────── */
.ovfd-pane{ display:none; animation:ovfdFade .28s ease; }
.ovfd-pane.active{ display:block; }
@keyframes ovfdFade{ from{ opacity:0; transform:translateY(6px);} to{ opacity:1; transform:none;} }

/* ── STAT CARDS (desktop) ─────────────────────────────────── */
.ovfd-stats-grid{ display:grid; grid-template-columns:repeat(4,1fr); gap:16px; margin-bottom:24px; }
.ovfd-stat-card{
    position:relative; overflow:hidden;
    background:var(--ovfd-surface); border:1px solid var(--ovfd-border);
    border-radius:var(--ovfd-r); padding:20px;
    box-shadow:var(--ovfd-shadow-sm);
    transition:transform .18s, box-shadow .18s;
}
.ovfd-stat-card:hover{ transform:translateY(-3px); box-shadow:var(--ovfd-shadow); }
.ovfd-stat-card::after{
    content:''; position:absolute; top:-30px; right:-30px;
    width:110px; height:110px; border-radius:50%; opacity:.10;
}
.ovfd-stat-card.yellow::after{ background:var(--ovfd-primary); }
.ovfd-stat-card.green::after{ background:var(--ovfd-secondary); }
.ovfd-stat-card.dark::after{ background:var(--ovfd-dark); }
.ovfd-stat-card.red::after{ background:var(--ovfd-accent); }
.ovfd-stat-icon{
    width:44px; height:44px; border-radius:12px;
    display:flex; align-items:center; justify-content:center;
    font-size:21px; margin-bottom:14px; position:relative; z-index:1;
}
.ovfd-stat-icon.yellow{ background:rgba(255,222,23,.18); }
.ovfd-stat-icon.green{ background:rgba(185,209,61,.20); }
.ovfd-stat-icon.dark{ background:var(--ovfd-dark); }
.ovfd-stat-icon.red{ background:rgba(228,47,59,.14); }
.ovfd-stat-value{ font-size:30px; font-weight:800; line-height:1; color:var(--ovfd-ink); font-family:'Plus Jakarta Sans','Inter',sans-serif; position:relative; z-index:1; }
.ovfd-stat-label{ font-size:12.5px; color:var(--ovfd-ink-2); margin-top:6px; font-weight:500; position:relative; z-index:1; }
.ovfd-stat-change{ font-size:11px; font-weight:700; margin-top:6px; }

/* ── SECTION CARD ─────────────────────────────────────────── */
.ovfd-section-card{ background:var(--ovfd-surface); border:1px solid var(--ovfd-border); border-radius:var(--ovfd-r); margin-bottom:20px; box-shadow:var(--ovfd-shadow-sm); overflow:hidden; }
.ovfd-section-card-header{ display:flex; align-items:center; justify-content:space-between; gap:12px; padding:16px 20px; border-bottom:1px solid var(--ovfd-border-2); }
.ovfd-section-card-title{ font-size:15px; font-weight:800; color:var(--ovfd-ink); font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-section-card-body{ padding:20px; }

/* ── COURSE ROWS ──────────────────────────────────────────── */
.ovfd-course-row{ display:flex; align-items:center; gap:16px; padding:16px 0; border-bottom:1px solid var(--ovfd-border-2); }
.ovfd-course-row:last-child{ border-bottom:none; }
.ovfd-course-thumb{ width:76px; height:56px; border-radius:10px; object-fit:cover; flex-shrink:0; background:var(--ovfd-surface-2); position:relative; overflow:hidden; display:block; }
.ovfd-course-thumb-empty{ width:76px; height:56px; border-radius:10px; flex-shrink:0; display:flex; align-items:center; justify-content:center; font-size:22px; background:linear-gradient(135deg, rgba(255,222,23,.18), rgba(185,209,61,.14)); }
.ovfd-course-row-info{ flex:1; min-width:0; }
.ovfd-course-row-title{ font-size:14.5px; font-weight:700; color:var(--ovfd-ink); margin-bottom:3px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ovfd-course-row-meta{ font-size:12px; color:var(--ovfd-ink-3); display:flex; align-items:center; gap:8px; flex-wrap:wrap; }
.ovfd-course-row-action{ flex-shrink:0; text-align:right; }

/* ── PROGRESS BARS ────────────────────────────────────────── */
.ovfd-progress-wrap{ display:flex; align-items:center; gap:10px; }
.ovfd-progress-track{ flex:1; height:8px; background:var(--ovfd-border); border-radius:999px; overflow:hidden; }
.ovfd-progress-bar{ height:100%; border-radius:999px; background:linear-gradient(90deg,var(--ovfd-primary),var(--ovfd-secondary)); transition:width .9s cubic-bezier(.4,0,.2,1); }
.ovfd-progress-pct{ font-size:12px; font-weight:800; color:var(--ovfd-ink); min-width:38px; text-align:right; }

/* ── BUTTONS ──────────────────────────────────────────────── */
.ovfd-btn{ display:inline-flex; align-items:center; justify-content:center; gap:7px; font-family:inherit; font-size:13.5px; font-weight:700; padding:9px 18px; border-radius:10px; border:1.5px solid transparent; cursor:pointer; text-decoration:none; transition:transform .05s, filter .15s, background .15s, border-color .15s; white-space:nowrap; }
.ovfd-btn:active{ transform:translateY(1px); }
.ovfd-btn-sm{ font-size:12.5px; padding:7px 14px; border-radius:9px; }
.ovfd-btn-lg{ font-size:15px; padding:13px 26px; border-radius:12px; }
.ovfd-btn-full{ width:100%; }
.ovfd-btn-primary{ background:var(--ovfd-primary); color:var(--ovfd-dark); box-shadow:0 6px 16px -8px rgba(255,222,23,.9); }
.ovfd-btn-primary:hover{ filter:brightness(.96); }
.ovfd-btn-secondary{ background:var(--ovfd-secondary); color:var(--ovfd-dark); }
.ovfd-btn-dark{ background:var(--ovfd-dark); color:#fff; }
.ovfd-btn-dark:hover{ filter:brightness(1.15); }
.ovfd-btn-outline{ background:var(--ovfd-surface); color:var(--ovfd-ink-2); border-color:var(--ovfd-border); }
.ovfd-btn-outline:hover{ border-color:var(--ovfd-ink-3); color:var(--ovfd-ink); }
.ovfd-btn-ghost{ background:transparent; color:var(--ovfd-ink-2); }
.ovfd-btn-ghost:hover{ background:var(--ovfd-surface-2); }
.ovfd-btn-danger{ background:var(--ovfd-accent); color:#fff; }

/* ── CERTIFICATES ─────────────────────────────────────────── */
.ovfd-cert-grid{ display:flex; flex-wrap:wrap; gap:18px; align-items:start; justify-content:flex-start; }
.ovfd-cert-card{
    flex:0 1 300px; max-width:340px; min-width:0;
    background:var(--ovfd-surface); border:1px solid var(--ovfd-border);
    border-radius:var(--ovfd-r); overflow:hidden;
    box-shadow:var(--ovfd-shadow-sm);
    transition:transform .18s, box-shadow .18s;
}
.ovfd-cert-card:hover{ transform:translateY(-4px); box-shadow:var(--ovfd-shadow); }
.ovfd-cert-head{
    background:
        radial-gradient(120% 140% at 50% 0%, rgba(255,222,23,.16), transparent 55%),
        linear-gradient(135deg, #16181f, #2c2f3a);
    padding:26px 20px; text-align:center; color:#fff;
}
.ovfd-cert-head .icon{ font-size:38px; display:block; margin-bottom:10px; }
.ovfd-cert-head .type{ font-size:9px; letter-spacing:2.5px; text-transform:uppercase; color:rgba(255,255,255,.55); margin-bottom:6px; }
.ovfd-cert-head .name{ font-size:15px; font-weight:800; line-height:1.3; font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-cert-foot{ padding:16px; }
.ovfd-cert-num{ font-size:11px; color:var(--ovfd-ink-3); font-family:ui-monospace,Menlo,monospace; }
.ovfd-cert-date{ font-size:12px; color:var(--ovfd-ink-2); margin:2px 0 12px; }
.ovfd-cert-actions{ display:flex; gap:8px; flex-wrap:wrap; }

/* ── BADGES / GAMIFICATION ────────────────────────────────── */
.ovfd-game-row{ display:grid; grid-template-columns:1fr 1fr; gap:16px; margin-bottom:20px; }
.ovfd-streak-box{
    background:linear-gradient(135deg, var(--ovfd-accent), #b91d29);
    border-radius:var(--ovfd-r); padding:22px; color:#fff; text-align:center;
    box-shadow:0 12px 30px -14px rgba(228,47,59,.7);
}
.ovfd-streak-flame{ font-size:30px; }
.ovfd-streak-num{ font-size:34px; font-weight:800; line-height:1; margin:4px 0; font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-streak-lbl{ font-size:11px; letter-spacing:1.5px; text-transform:uppercase; opacity:.85; }
.ovfd-level-box{
    background:linear-gradient(135deg, var(--ovfd-primary), var(--ovfd-secondary));
    border-radius:var(--ovfd-r); padding:22px; color:var(--ovfd-dark); text-align:center;
    box-shadow:0 12px 30px -14px rgba(255,222,23,.8);
}
.ovfd-level-circle{ width:52px; height:52px; border-radius:50%; background:var(--ovfd-dark); color:#fff; display:flex; align-items:center; justify-content:center; font-size:20px; font-weight:800; margin:0 auto 8px; }
.ovfd-level-num{ font-size:19px; font-weight:800; font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-level-sub{ font-size:12px; opacity:.75; margin-top:2px; }
.ovfd-badges-grid{ display:grid; grid-template-columns:repeat(5,1fr); gap:12px; }
.ovfd-badge-item{ text-align:center; cursor:default; }
.ovfd-badge-icon{ font-size:24px; display:block; background:var(--ovfd-surface-2); border:1px solid var(--ovfd-border-2); border-radius:14px; padding:14px; margin-bottom:6px; transition:transform .18s; }
.ovfd-badge-item:not(.locked):hover .ovfd-badge-icon{ transform:translateY(-3px) scale(1.04); }
.ovfd-badge-icon.earned{ background:linear-gradient(135deg, rgba(255,222,23,.28), rgba(185,209,61,.2)); border-color:rgba(255,222,23,.5); }
.ovfd-badge-item.locked .ovfd-badge-icon{ opacity:.28; filter:grayscale(1); }
.ovfd-badge-lbl{ font-size:9.5px; font-weight:700; color:var(--ovfd-ink-3); line-height:1.3; }
.ovfd-badge{ display:inline-block; font-size:10px; font-weight:800; padding:2px 8px; border-radius:999px; }
.ovfd-badge-yellow{ background:rgba(255,222,23,.2); color:#9a7d00; }
.ovfd-badge-green{ background:rgba(185,209,61,.22); color:#5f7a12; }
.ovfd-badge-red{ background:rgba(228,47,59,.14); color:#c81e2a; }
.ovfd-badge-blue{ background:rgba(59,130,246,.14); color:#1d4ed8; }
.ovfd-badge-gray{ background:var(--ovfd-surface-2); color:var(--ovfd-ink-2); }

/* ── LEADERBOARD ──────────────────────────────────────────── */
.ovfd-board-row{ display:flex; align-items:center; gap:14px; padding:13px 0; border-bottom:1px solid var(--ovfd-border-2); }
.ovfd-board-row:last-child{ border-bottom:none; }
.ovfd-board-rank{ width:30px; text-align:center; font-size:15px; font-weight:800; color:var(--ovfd-ink-3); flex-shrink:0; }
.ovfd-board-avi{ width:40px; height:40px; border-radius:50%; object-fit:cover; flex-shrink:0; }
.ovfd-board-name{ flex:1; font-size:14px; font-weight:700; color:var(--ovfd-ink); min-width:0; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.ovfd-board-xp{ font-size:13px; font-weight:800; color:#5f7a12; flex-shrink:0; }

/* ── PROFILE ──────────────────────────────────────────────── */
.ovfd-profile-header{
    width:100%; box-sizing:border-box;
    background:
        radial-gradient(130% 130% at 100% 0%, rgba(255,222,23,.16), transparent 55%),
        linear-gradient(135deg, var(--ovfd-dark), #2a2724);
    border-radius:var(--ovfd-r-lg); padding:40px 24px; text-align:center; color:#fff; margin-bottom:20px;
}
.ovfd-profile-avatar{ width:96px; height:96px; border-radius:50%; object-fit:cover; border:3px solid var(--ovfd-primary); margin-bottom:14px; }
.ovfd-profile-name{ font-size:22px; font-weight:800; font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-profile-email{ font-size:13px; color:rgba(255,255,255,.6); margin-top:2px; }
.ovfd-profile-stats{ display:flex; justify-content:center; gap:36px; margin-top:22px; }
.ovfd-profile-stat{ text-align:center; }
.ovfd-profile-stat-val{ font-size:22px; font-weight:800; color:var(--ovfd-primary); font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-profile-stat-lbl{ font-size:10px; letter-spacing:1px; text-transform:uppercase; color:rgba(255,255,255,.55); margin-top:2px; }

/* ── FORMS ────────────────────────────────────────────────── */
.ovfd-form-group{ margin-bottom:16px; }
.ovfd-label{ display:block; font-size:13px; font-weight:700; color:var(--ovfd-ink-2); margin-bottom:6px; }
.ovfd-input,.ovfd-textarea{ width:100%; padding:11px 14px; border:1.5px solid var(--ovfd-border, #e9ebf0); border-radius:10px; font-family:inherit; font-size:14px; color:var(--ovfd-ink, #14161c); background:var(--ovfd-surface, #ffffff); transition:border-color .15s, box-shadow .15s; }
.ovfd-input:focus,.ovfd-textarea:focus{ outline:none; border-color:var(--ovfd-primary, #FFDE17); box-shadow:var(--ovfd-ring, 0 0 0 3px rgba(255,222,23,.35)); }
.ovfd-textarea{ resize:vertical; min-height:96px; }

/* ── TABLE ────────────────────────────────────────────────── */
.ovfd-table-wrap{ overflow-x:auto; border:1px solid var(--ovfd-border); border-radius:var(--ovfd-r); }
.ovfd-table{ width:100%; border-collapse:collapse; font-size:13.5px; }
.ovfd-table th{ text-align:left; padding:12px 16px; background:var(--ovfd-surface-2); font-weight:700; color:var(--ovfd-ink-2); border-bottom:1px solid var(--ovfd-border); }
.ovfd-table td{ padding:12px 16px; border-bottom:1px solid var(--ovfd-border-2); }
.ovfd-table tr:last-child td{ border-bottom:none; }

/* ── EMPTY STATES & UTILITIES ─────────────────────────────── */
.ovfd-empty{ text-align:center; padding:48px 20px; }
.ovfd-empty-icon{ font-size:44px; display:block; margin-bottom:12px; opacity:.9; }
.ovfd-divider{ height:1px; background:var(--ovfd-border-2); margin:16px 0; border:none; }
.ovfd-flex-between{ display:flex; align-items:center; justify-content:space-between; gap:12px; }
.ovfd-text-center{ text-align:center; }
.ovfd-text-muted{ color:var(--ovfd-ink-3); }

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE — MOBILE  (< 900px)
   Same breakpoints & behavior as before, refreshed styling.
   ═══════════════════════════════════════════════════════════ */
@media (max-width: 899px){
    .ovfd-layout{ display:block; }
    .ovfd-sidebar{ display:none; }
    .ovfd-main{ display:block; }
    .ovfd-topbar{ display:none; }
    .ovfd-body{ padding:16px 16px calc(140px + env(safe-area-inset-bottom, 0px)); max-width:100%; margin:0 auto; }
    #ovfd-top-xp{ padding-left:16px; padding-right:16px; }
    .ovfd-stats-grid{ grid-template-columns:1fr 1fr; gap:10px; }

    /* Mobile sticky header */
    .ovfd-mobile-header{
        display:flex !important; align-items:center; gap:12px;
        background:var(--ovfd-dark); color:#fff; padding:12px 16px;
        position:sticky; top:0; z-index:100; box-shadow:0 2px 12px rgba(0,0,0,.2);
    }
    .ovfd-mobile-header-avatar{ width:34px; height:34px; border-radius:50%; object-fit:cover; border:2px solid var(--ovfd-primary); flex-shrink:0; }
    .ovfd-mobile-header-info{ flex:1; min-width:0; }
    .ovfd-mobile-header-greeting{ font-size:14px; font-weight:800; line-height:1.3; color:#fff; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
    .ovfd-mobile-header-actions{ display:flex; align-items:center; gap:8px; flex-shrink:0; }
    .ovfd-mobile-icon-btn{
        width:36px; height:36px; border-radius:11px;
        background:rgba(255,255,255,.10); border:1px solid rgba(255,255,255,.14);
        display:flex; align-items:center; justify-content:center;
        color:#fff; cursor:pointer; text-decoration:none; padding:0; flex-shrink:0;
        transition:background .15s;
    }
    .ovfd-mobile-icon-btn:hover{ background:rgba(255,255,255,.18); }
    .ovfd-mobile-avatar-btn{ background:none; border:none; padding:0; overflow:hidden; }
    .ovfd-mobile-avatar-btn img{ width:36px; height:36px; border-radius:11px; border:2px solid var(--ovfd-primary); object-fit:cover; display:block; }
    .ovfd-cart-icon-btn{ width:36px; height:36px; border-radius:11px; background:rgba(255,255,255,.10); border:1px solid rgba(255,255,255,.14); color:#fff; }
    .ovfd-cart-badge{ border-color:var(--ovfd-dark); }

    /* Mobile hero strip */
    .ovfd-mobile-hero{
        display:flex !important;
        background:
            radial-gradient(120% 160% at 100% 0%, rgba(255,222,23,.14), transparent 60%),
            linear-gradient(135deg, var(--ovfd-dark), #252323);
        padding:16px; gap:10px; overflow-x:auto; scrollbar-width:none;
        border-bottom:2px solid var(--ovfd-primary);
    }
    .ovfd-mobile-hero::-webkit-scrollbar{ display:none; }
    .ovfd-mobile-stat{ background:rgba(255,255,255,.08); border:1px solid rgba(255,255,255,.10); border-radius:12px; padding:11px 14px; flex-shrink:0; text-align:center; min-width:80px; }
    .ovfd-mobile-stat-val{ font-size:18px; font-weight:800; color:var(--ovfd-primary); line-height:1; }
    .ovfd-mobile-stat-lbl{ font-size:9px; color:rgba(255,255,255,.5); text-transform:uppercase; letter-spacing:.5px; margin-top:3px; }

    /* XP bar on mobile */
    .ovfd-xp-card{ border-radius:0; margin:0; padding:12px 16px; }

    /* Bottom tab bar */
    .ovfd-tab-bar{
        display:flex !important; position:fixed; bottom:0; left:0; right:0;
        background:var(--ovfd-surface); border-top:1px solid var(--ovfd-border);
        z-index:200; box-shadow:0 -4px 18px rgba(0,0,0,.08);
        padding-bottom:env(safe-area-inset-bottom);
    }
    .ovfd-tab-btn{
        flex:1; display:flex; flex-direction:column; align-items:center;
        padding:9px 4px 7px; gap:3px; cursor:pointer; border:none;
        background:none; font-family:inherit; color:var(--ovfd-ink-3);
        transition:color .15s; min-width:0;
    }
    .ovfd-tab-btn-icon{ font-size:20px; transition:transform .2s; line-height:1; }
    .ovfd-tab-btn-lbl{ font-size:9px; font-weight:800; text-transform:uppercase; letter-spacing:.3px; }
    .ovfd-tab-btn.active{ color:var(--ovfd-ink); }
    .ovfd-tab-btn.active .ovfd-tab-btn-icon{ transform:scale(1.18); }

    /* Cards on mobile */
    .ovfd-section-card{ border-radius:13px; margin-bottom:12px; }
    .ovfd-section-card-body{ padding:16px; }
    .ovfd-cert-grid{ gap:12px; }
    .ovfd-cert-card{ flex:1 1 100%; max-width:100%; }
    .ovfd-game-row{ grid-template-columns:1fr 1fr; gap:10px; }
    .ovfd-badges-grid{ grid-template-columns:repeat(4,1fr); gap:8px; }
    .ovfd-profile-stats{ gap:20px; }
    .ovfd-profile-header{ border-radius:16px; padding:32px 20px; }
    .ovfd-stats-grid{ margin-bottom:14px; }
    .ovfd-stat-card{ padding:15px; }
    .ovfd-stat-value{ font-size:22px; }
    .ovfd-stat-icon{ width:36px; height:36px; font-size:16px; margin-bottom:9px; }
    .ovfd-course-thumb,.ovfd-course-thumb-empty{ width:64px; height:48px; }
    .ovfd-course-row{ gap:12px; }
}

/* Desktop only */
@media (min-width: 900px){
    .ovfd-mobile-header{ display:none; }
    .ovfd-mobile-hero{ display:none; }
    .ovfd-tab-bar{ display:none; }
    .ovfd-sidebar{ display:flex; }
    .ovfd-topbar{ display:flex; }
    .ovfd-badges-grid{ grid-template-columns:repeat(5,1fr); }
    .ovfd-game-row{ grid-template-columns:1fr 1fr; }
}

/* ── MOBILE ACCOUNT DRAWER ────────────────────────────────── */
.ovfd-drawer-overlay{ display:none; position:fixed; inset:0; background:rgba(0,0,0,.5); z-index:998; backdrop-filter:blur(2px); opacity:0; transition:opacity .25s ease; }
.ovfd-drawer-overlay.open{ display:block; opacity:1; }
.ovfd-drawer{
    position:fixed; top:0; right:0; bottom:0; width:288px; max-width:84vw;
    background:var(--ovfd-surface); z-index:999; transform:translateX(100%);
    transition:transform .28s cubic-bezier(.4,0,.2,1); overflow-y:auto;
    box-shadow:-8px 0 40px rgba(0,0,0,.2); display:flex; flex-direction:column;
}
.ovfd-drawer.open{ transform:translateX(0); }
.ovfd-drawer-header{
    background:
        radial-gradient(120% 140% at 100% 0%, rgba(255,222,23,.16), transparent 55%),
        linear-gradient(135deg, var(--ovfd-dark), #2c2a2a);
    color:#fff; padding:26px 20px; text-align:center; position:relative;
}
.ovfd-drawer-close{ position:absolute; top:14px; right:14px; width:30px; height:30px; border-radius:50%; background:rgba(255,255,255,.12); border:none; color:#fff; font-size:15px; cursor:pointer; display:flex; align-items:center; justify-content:center; }
.ovfd-drawer-avatar{ width:66px; height:66px; border-radius:50%; object-fit:cover; border:3px solid var(--ovfd-primary); margin:0 auto 10px; display:block; }
.ovfd-drawer-name{ font-size:16px; font-weight:800; font-family:'Plus Jakarta Sans','Inter',sans-serif; }
.ovfd-drawer-email{ font-size:12px; opacity:.6; margin-top:2px; }
.ovfd-drawer-nav{ padding:12px; flex:1; }
.ovfd-drawer-item{
    display:flex; align-items:center; gap:12px; width:100%;
    padding:12px 14px; border-radius:11px;
    font-size:14px; font-weight:600; color:var(--ovfd-ink-2) !important;
    cursor:pointer; border:none; background:none; text-align:left; font-family:inherit;
    text-decoration:none; transition:background .15s, color .15s;
}
.ovfd-drawer-item:hover{ background:rgba(255,222,23,.15); color:var(--ovfd-dark) !important; text-decoration:none; }
.ovfd-drawer-item.active{ background:rgba(255,222,23,.2); color:var(--ovfd-dark) !important; box-shadow:inset 3px 0 0 var(--ovfd-primary); }
.ovfd-drawer-icon{ font-size:18px; width:24px; text-align:center; flex-shrink:0; }
.ovfd-drawer-divider{ border:none; border-top:1px solid var(--ovfd-border-2); margin:8px 12px; }
.ovfd-drawer-footer{ padding:12px 12px 0; border-top:1px solid var(--ovfd-border-2); display:flex; flex-direction:column; gap:4px; }
.ovfd-sidebar-footer .ovfd-home-link{ color:var(--ovfd-ink-2) !important; }
.ovfd-sidebar-footer .ovfd-home-link:hover{ color:var(--ovfd-dark) !important; }
.ovfd-drawer-footer .ovfd-home-link{ color:var(--ovfd-ink-2) !important; }
.ovfd-drawer-footer .ovfd-home-link:hover{ background:rgba(15,23,42,.06) !important; color:var(--ovfd-dark) !important; }
@media (min-width: 900px){ .ovfd-drawer, .ovfd-drawer-overlay{ display:none !important; } }

@media (prefers-reduced-motion: reduce){
    .ovfd-pane, .ovfd-xp-fill, .ovfd-progress-bar, .ovfd-stat-card, .ovfd-cert-card{ animation:none !important; transition:none !important; }
}
