

/* ============================================================
   COURSE LEARNING PAGE (Video Player + Tabs + Curriculum)
   ============================================================ */
.learn-shell { display: grid; grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); gap: 32px; padding: 32px 0 80px; align-items: start; }
.learn-topbar { background: var(--ink-950); color: var(--paper); padding: 14px 0; border-bottom: 1px solid var(--ink-800); position: sticky; top: 0; z-index: 60; }
.learn-topbar .inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.learn-topbar .title { display: flex; align-items: center; gap: 14px; }
.learn-topbar .title h4 { margin: 0; font-size: 1rem; font-weight: 600; color: #fff; }
.learn-topbar .title small { color: var(--ink-300); font-size: .78rem; font-family: var(--font-mono); }
.learn-topbar .prog { display: flex; align-items: center; gap: 12px; color: var(--ink-300); font-size: .82rem; }
.learn-topbar .bar { width: 180px; height: 6px; background: rgba(255,255,255,.12); border-radius: var(--r-pill); overflow: hidden; }
.learn-topbar .bar > i { display: block; height: 100%; background: var(--brand-gradient); border-radius: var(--r-pill); }
.learn-topbar a.exit { color: var(--ink-200); font-size: .85rem; }
.learn-topbar a.exit:hover { color: #fff; }

.player-wrap { background: #000; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow-3); aspect-ratio: 16 / 9; position: relative; width: 100%; }
.player-wrap video { width: 100%; height: 100%; display: block; object-fit: contain; }
.player-wrap iframe { display: block; width: 100%; height: 100%; min-height: 0; border: 0; }
.player-wrap img { display: block; width: 100%; height: 100%; object-fit: contain; }
.player-wrap audio { display: block; width: min(calc(100% - 32px), 560px); position: absolute; inset: 50% 16px auto; transform: translateY(-50%); margin: auto; }
.player-wrap > div#lessonVideo { position: absolute; inset: 0; }
.player-wrap .recording-player { position: absolute; inset: 0; background: #000; }
.player-wrap .recording-player video { width: 100%; height: 100%; object-fit: contain; }
.player-wrap .recording-player-title { position: absolute; left: 16px; right: 16px; bottom: 14px; padding: 10px 12px; border-radius: 10px; background: rgba(31,17,40,.82); color: #fff; font-size: .82rem; font-weight: 600; }
.player-wrap .pdf-player { width: 100%; height: 100%; border: 0; }
.player-wrap .zoom-cover { position: absolute; inset: 0; background: linear-gradient(135deg, #5F2E7A, #B0315E); display: grid; place-items: center; text-align: center; padding: 40px; color: #fff; }
.player-wrap .zoom-cover .z-icon { width: 76px; height: 76px; border-radius: 22px; background: rgba(255,255,255,.14); display: grid; place-items: center; font-size: 2rem; margin: 0 auto 20px; border: 1px solid rgba(255,255,255,.18); }
.player-wrap .zoom-cover h3 { font-family: var(--font-display); font-size: 2rem; margin: 0 0 8px; }
.player-wrap .zoom-cover p { color: rgba(255,255,255,.85); margin: 0 0 24px; }
.player-wrap .zoom-cover .btn { color: var(--mint-700); background: #fff; }

.lesson-meta { display: flex; justify-content: space-between; align-items: center; padding: 20px 0 24px; border-bottom: 1px solid var(--ink-100); flex-wrap: wrap; gap: 16px; }
.lesson-meta .l { display: flex; align-items: center; gap: 12px; }
.lesson-meta .l .num { font-family: var(--font-mono); color: var(--ink-400); font-size: .82rem; }
.lesson-meta .l h2 { margin: 0; font-family: var(--font-display); font-size: 1.6rem; font-weight: 400; line-height: 1.1; }
.lesson-meta .r { display: flex; gap: 8px; }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--ink-100); margin: 28px 0; overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs button { padding: 14px 18px; background: transparent; border: none; font-size: .92rem; font-weight: 500; color: var(--ink-500); border-bottom: 2px solid transparent; margin-bottom: -1px; transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease); white-space: nowrap; }
.tabs button:hover { color: var(--ink-950); }
.tabs button.active { color: var(--mint-700); border-bottom-color: var(--mint-700); }
.tab-panel { display: none; }
.tab-panel.active { display: block; animation: fadeIn 400ms var(--ease); }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* Curriculum sidebar (learning) */
.curriculum { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 20px; position: sticky; top: 88px; max-height: calc(100vh - 110px); overflow-y: auto; }
.curriculum h4 { margin: 0 0 4px; font-size: 1rem; font-weight: 600; }
.curriculum .prog-line { display: flex; justify-content: space-between; color: var(--ink-500); font-size: .82rem; margin-bottom: 14px; }
.curr-module { border-top: 1px solid var(--ink-100); padding-top: 14px; margin-top: 14px; }
.curr-module:first-of-type { border-top: none; padding-top: 0; margin-top: 0; }
.curr-module summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; align-items: center; padding: 8px 0; font-weight: 600; font-size: .92rem; }
.curr-module summary::-webkit-details-marker { display: none; }
.curr-module summary::after { content: '⌄'; color: var(--ink-400); transition: transform var(--dur) var(--ease); }
.curr-module[open] summary::after { transform: rotate(180deg); }
.curr-module small { display: block; color: var(--ink-500); font-size: .76rem; font-weight: 400; margin-top: 2px; }
.curr-lesson { display: flex; align-items: center; gap: 10px; padding: 10px 8px; border-radius: 8px; cursor: pointer; font-size: .88rem; transition: background var(--dur) var(--ease); }
.curr-lesson:hover { background: var(--ink-50); }
.curr-lesson.active { background: rgba(95,46,122,.08); color: var(--mint-700); font-weight: 500; }
.curr-lesson .check { width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--ink-300); display: grid; place-items: center; flex-shrink: 0; font-size: .68rem; color: transparent; }
.curr-lesson.done .check { background: var(--mint-600); border-color: var(--mint-600); color: #fff; }
.curr-lesson .txt { flex: 1; }
.curr-lesson .dur { color: var(--ink-400); font-size: .76rem; font-family: var(--font-mono); }
.curr-lesson i.type { color: var(--ink-400); font-size: .95rem; }

/* Assessment tab */
.assessment-card { display: grid; grid-template-columns: 60px 1fr auto; gap: 20px; align-items: center; background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 22px; margin-bottom: 12px; transition: all var(--dur) var(--ease); }
.assessment-card:hover { border-color: var(--ink-950); transform: translateY(-2px); }
.assessment-card .icn { width: 60px; height: 60px; border-radius: 16px; background: rgba(95,46,122,.10); color: var(--mint-700); display: grid; place-items: center; font-size: 1.6rem; }
.assessment-card h4 { margin: 0 0 4px; font-size: 1.05rem; font-weight: 600; }
.assessment-card p { margin: 0; color: var(--ink-500); font-size: .85rem; }
.assessment-card .badge-status { padding: 6px 12px; border-radius: var(--r-pill); font-size: .78rem; font-weight: 500; }
.status-pass { background: rgba(38,150,90,.12); color: #1e7a4a; border: 1px solid rgba(38,150,90,.22); }
.status-pending { background: rgba(176,49,94,.10); color: var(--ochre-600); border: 1px solid rgba(176,49,94,.22); }

/* Resources */
.resource-item { display: flex; align-items: center; gap: 16px; padding: 16px; border: 1px solid var(--ink-100); border-radius: var(--r-md); margin-bottom: 10px; transition: all var(--dur) var(--ease); background: #fff; }
.resource-item:hover { border-color: var(--mint-600); background: var(--ink-50); }
.resource-item .ext { width: 44px; height: 44px; border-radius: 10px; background: var(--brand-gradient); color: #fff; display: grid; place-items: center; font-family: var(--font-mono); font-size: .72rem; font-weight: 700; flex-shrink: 0; }
.resource-item .info { flex: 1; }
.resource-item .info h5 { margin: 0 0 2px; font-size: .95rem; font-weight: 600; }
.resource-item .info span { color: var(--ink-500); font-size: .8rem; }

/* ============================================================
   EXAM PAGE
   ============================================================ */
.exam-shell { display: grid; grid-template-columns: 1fr 340px; gap: 40px; padding: 40px 0 80px; align-items: start; }
.q-card { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 36px; min-height: 360px; }
.q-card .q-num { font-family: var(--font-mono); color: var(--ink-400); font-size: .82rem; margin-bottom: 8px; letter-spacing: .1em; }
.q-card .q-text { font-size: 1.2rem; font-weight: 600; margin: 0 0 28px; line-height: 1.4; color: var(--ink-950); }
.q-options { display: grid; gap: 10px; }
.q-option { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border: 1.5px solid var(--ink-200); border-radius: var(--r-md); cursor: pointer; transition: all var(--dur) var(--ease); background: #fff; }
.q-option:hover { border-color: var(--mint-600); background: var(--ink-50); }
.q-option input { accent-color: var(--mint-600); width: 18px; height: 18px; margin: 0; }
.q-option.selected { border-color: var(--mint-600); background: rgba(95,46,122,.06); }
.q-option .letter { width: 28px; height: 28px; border-radius: 8px; background: var(--ink-100); display: grid; place-items: center; font-family: var(--font-mono); font-size: .82rem; font-weight: 600; color: var(--ink-700); flex-shrink: 0; }
.q-option.selected .letter { background: var(--mint-600); color: #fff; }
.q-nav { display: flex; justify-content: space-between; align-items: center; margin-top: 28px; gap: 12px; flex-wrap: wrap; }
.q-nav .left, .q-nav .right { display: flex; gap: 10px; }

/* Exam sidebar */
.exam-side { position: sticky; top: 20px; display: grid; gap: 16px; }
.timer-card { background: var(--brand-gradient); color: #fff; border-radius: var(--r-md); padding: 20px; text-align: center; }
.timer-card b { display: block; font-family: var(--font-display); font-size: 2.4rem; line-height: 1; }
.timer-card span { font-size: .78rem; color: rgba(255,255,255,.85); letter-spacing: .1em; text-transform: uppercase; font-family: var(--font-mono); }
.q-legend { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 20px; }
.q-legend h5 { margin: 0 0 4px; font-size: .95rem; }
.q-legend .filter-tabs { display: flex; gap: 4px; padding: 4px; background: var(--ink-50); border-radius: var(--r-pill); margin: 12px 0 16px; font-size: .74rem; }
.q-legend .filter-tabs button { flex: 1; padding: 6px 8px; border: none; background: transparent; border-radius: var(--r-pill); font-weight: 500; color: var(--ink-500); }
.q-legend .filter-tabs button.active { background: #fff; color: var(--ink-950); box-shadow: var(--shadow-1); }
.q-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.q-grid button { aspect-ratio: 1; border-radius: 8px; border: 1.5px solid var(--ink-200); background: #fff; font-family: var(--font-mono); font-size: .82rem; font-weight: 600; color: var(--ink-700); cursor: pointer; transition: all var(--dur) var(--ease); }
.q-grid button:hover { border-color: var(--mint-600); }
.q-grid button.answered { background: rgba(38,150,90,.12); border-color: rgba(38,150,90,.35); color: #1e7a4a; }
.q-grid button.marked { background: rgba(212,155,52,.15); border-color: rgba(212,155,52,.4); color: #7a5511; }
.q-grid button.current { background: var(--mint-600); color: #fff; border-color: var(--mint-600); box-shadow: var(--ring); }
.q-grid button.skipped { background: rgba(176,49,94,.10); border-color: rgba(176,49,94,.30); color: var(--ochre-600); }
.legend-dots { display: flex; gap: 14px; margin-top: 14px; font-size: .76rem; color: var(--ink-500); flex-wrap: wrap; }
.legend-dots span { display: inline-flex; align-items: center; gap: 6px; }
.legend-dots i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* Exam states */
.exam-intro, .exam-result { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: clamp(32px, 5vw, 64px); text-align: center; max-width: 720px; margin: 40px auto; }
.exam-intro .icn, .exam-result .icn { width: 88px; height: 88px; border-radius: 26px; background: var(--brand-gradient); color: #fff; display: grid; place-items: center; margin: 0 auto 20px; font-size: 2.4rem; }
.exam-intro h1, .exam-result h1 { font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem); margin: 0 0 12px; }
.exam-intro p, .exam-result p { color: var(--ink-500); max-width: 480px; margin: 0 auto 28px; }
.exam-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 20px; padding: 28px 0; margin: 20px 0; border-top: 1px solid var(--ink-100); border-bottom: 1px solid var(--ink-100); }
.exam-info-grid .info b { display: block; font-family: var(--font-display); font-size: 1.6rem; line-height: 1; }
.exam-info-grid .info span { color: var(--ink-500); font-size: .8rem; }

.result-score { width: 200px; height: 200px; border-radius: 50%; background: conic-gradient(var(--mint-600) calc(var(--pct) * 1%), var(--ink-100) 0); display: grid; place-items: center; margin: 0 auto 24px; position: relative; }
.result-score::after { content: ''; position: absolute; inset: 14px; background: #fff; border-radius: 50%; }
.result-score b { position: relative; z-index: 1; font-family: var(--font-display); font-size: 3.4rem; line-height: 1; }
.result-score span { position: relative; z-index: 1; font-size: .78rem; color: var(--ink-500); text-transform: uppercase; letter-spacing: .1em; }
.result-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 24px 0; text-align: center; }
.result-stats .box { padding: 20px 12px; background: var(--paper-alt); border-radius: var(--r-md); border: 1px solid var(--paper-line); }
.result-stats .box b { display: block; font-family: var(--font-display); font-size: 2rem; line-height: 1; }
.result-stats .box span { color: var(--ink-500); font-size: .78rem; }
.result-stats .box.pass b { color: #1e7a4a; }
.result-stats .box.fail b { color: var(--ochre-600); }

/* ============================================================
   CART / CHECKOUT
   ============================================================ */
.cart-shell, .checkout-shell { display: grid; grid-template-columns: 1fr 400px; gap: 32px; align-items: start; padding: 20px 0 80px; }
.cart-item { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 20px; display: grid; grid-template-columns: 130px 1fr auto; gap: 20px; align-items: center; margin-bottom: 12px; transition: all var(--dur) var(--ease); }
.cart-item:hover { border-color: var(--ink-950); box-shadow: var(--shadow-2); }
.cart-item .cover { border-radius: var(--r-md); aspect-ratio: 16 / 10; overflow: hidden; }
.cart-item .cover img { width: 100%; height: 100%; object-fit: cover; }
.cart-item .info h4 { margin: 0 0 4px; font-size: 1.05rem; font-weight: 600; }
.cart-item .info small { color: var(--ink-500); font-size: .82rem; font-family: var(--font-mono); text-transform: uppercase; letter-spacing: .1em; }
.cart-item .info .badges { display: flex; gap: 6px; margin-top: 10px; }
.cart-item .price-col { text-align: right; }
.cart-item .price-col b { font-family: var(--font-display); font-size: 1.5rem; display: block; }
.cart-item .price-col small { color: var(--ink-400); text-decoration: line-through; font-size: .82rem; }
.cart-item .remove { background: transparent; border: none; color: var(--ink-500); font-size: .82rem; margin-top: 10px; padding: 0; }
.cart-item .remove:hover { color: var(--ochre-600); }

.summary-card { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 28px; position: sticky; top: 100px; }
.summary-card h3 { margin: 0 0 20px; font-size: 1.15rem; font-weight: 600; }
.summary-row { display: flex; justify-content: space-between; padding: 10px 0; color: var(--ink-500); font-size: .92rem; }
.summary-row.total { border-top: 1px solid var(--ink-100); padding-top: 16px; margin-top: 8px; font-size: 1.1rem; color: var(--ink-950); font-weight: 600; }
.summary-row.total b { font-family: var(--font-display); font-size: 1.6rem; }
.coupon-row { display: flex; gap: 8px; margin: 16px 0; }
.coupon-row input { flex: 1; padding: 12px 14px; border: 1px solid var(--ink-200); border-radius: var(--r-pill); font-family: inherit; font-size: .88rem; outline: none; }
.coupon-row input:focus { border-color: var(--ink-950); }

.empty-state { text-align: center; padding: 80px 24px; background: #fff; border: 1px dashed var(--ink-200); border-radius: var(--r-lg); }
.empty-state .icn { width: 88px; height: 88px; border-radius: 24px; background: var(--paper-alt); color: var(--ink-400); display: grid; place-items: center; margin: 0 auto 20px; font-size: 2.4rem; }
.empty-state h3 { font-family: var(--font-display); font-size: 1.8rem; margin: 0 0 8px; }
.empty-state p { color: var(--ink-500); margin: 0 0 24px; }

/* Payment methods */
.pay-methods { display: grid; gap: 10px; margin-top: 20px; }
.pay-option { display: flex; align-items: center; gap: 14px; padding: 18px 20px; border: 1.5px solid var(--ink-200); border-radius: var(--r-md); cursor: pointer; transition: all var(--dur) var(--ease); }
.pay-option:hover { border-color: var(--mint-600); }
.pay-option input { accent-color: var(--mint-600); }
.pay-option.active { border-color: var(--mint-600); background: rgba(95,46,122,.04); }
.pay-option .logo { margin-left: auto; height: 24px; opacity: .7; font-family: var(--font-display); font-size: 1.1rem; color: var(--mint-700); font-weight: 600; }

/* ============================================================
   MY LEARNING / PROFILE / DASHBOARD SHARED
   ============================================================ */
.page-hero { background: var(--ink-950); color: var(--paper); padding: 60px 0 40px; position: relative; overflow: hidden; }
.page-hero::before { content:''; position: absolute; inset: 0; background: var(--brand-gradient-soft); opacity: .32; }
.page-hero .ol-container { position: relative; z-index: 1; }
.page-hero h1 { font-family: var(--font-display); font-size: clamp(2.4rem, 5vw, 3.6rem); margin: 12px 0 8px; color: #fff; letter-spacing: -.02em; }
.page-hero .eyebrow { color: rgba(255,255,255,.7); }
.page-hero p { color: rgba(255,255,255,.78); max-width: 560px; margin: 0; }

.mylearn-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-top: 32px; }
.mylearn-stats .stat { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.12); border-radius: var(--r-lg); padding: 20px; backdrop-filter: blur(10px); }
.mylearn-stats .stat b { display: block; font-family: var(--font-display); font-size: 2.2rem; line-height: 1; color: #fff; }
.mylearn-stats .stat span { color: rgba(255,255,255,.72); font-size: .82rem; }

.learn-card { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); overflow: hidden; display: flex; flex-direction: column; transition: all var(--dur) var(--ease); }
.learn-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); border-color: var(--ink-950); }
.learn-card .cover { aspect-ratio: 16 / 9; position: relative; overflow: hidden; }
.learn-card .cover img { width: 100%; height: 100%; object-fit: cover; }
.learn-card .cover .type { position: absolute; top: 12px; left: 12px; }
.learn-card .body { padding: 20px; flex: 1; display: flex; flex-direction: column; gap: 12px; }
.learn-card h4 { margin: 0; font-size: 1.05rem; font-weight: 600; line-height: 1.3; }
.learn-card .cat { font-family: var(--font-mono); font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; color: var(--mint-700); }
.progress { height: 6px; background: var(--ink-100); border-radius: var(--r-pill); overflow: hidden; }
.progress > i { display: block; height: 100%; background: var(--brand-gradient); border-radius: var(--r-pill); }
.learn-card .prog-txt { display: flex; justify-content: space-between; font-size: .78rem; color: var(--ink-500); }
.learn-card .foot { display: flex; justify-content: space-between; align-items: center; padding-top: 14px; border-top: 1px solid var(--ink-100); margin-top: auto; }

/* Profile layout */
.profile-shell { display: grid; grid-template-columns: 300px 1fr; gap: 32px; align-items: start; padding: 40px 0 80px; }
.profile-side { background: #fff; border: 1px solid var(--ink-100); border-radius: var(--r-lg); padding: 28px; position: sticky; top: 100px; }
.profile-avatar { display: grid; place-items: center; gap: 12px; text-align: center; padding-bottom: 20px; border-bottom: 1px solid var(--ink-100); margin-bottom: 20px; }
.profile-avatar .avi { width: 84px; height: 84px; border-radius: 50%; background: var(--brand-gradient); display: grid; place-items: center; color: #fff; font-family: var(--font-display); font-size: 2.2rem; }
.profile-avatar h3 { margin: 0; font-size: 1.15rem; font-weight: 600; }
.profile-avatar span { color: var(--ink-500); font-size: .85rem; }
.profile-menu { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.profile-menu a { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--r-md); font-size: .92rem; color: var(--ink-700); font-weight: 500; transition: background var(--dur) var(--ease); }
.profile-menu a:hover { background: var(--ink-50); }
.profile-menu a.active { background: rgba(95,46,122,.08); color: var(--mint-700); }
.profile-menu a i { font-size: 1.1rem; }

/* Mobile navigation: the desktop mega menu becomes a contained accordion panel */
.mobile-nav-panel { display: none; }
.mobile-nav-panel[hidden] { display: none !important; }
.mobile-nav { display: grid; gap: 2px; }
.mobile-nav-link,
.mobile-nav-group > summary {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  width: 100%; padding: 13px 4px; border: 0; border-bottom: 1px solid var(--ink-100);
  background: transparent; color: var(--ink-900); font: inherit; font-size: .96rem;
  font-weight: 600; text-align: left; text-decoration: none; cursor: pointer;
}
.mobile-nav-link:hover,
.mobile-nav-group > summary:hover { color: var(--mint-700); }
.mobile-nav-group > summary { list-style: none; }
.mobile-nav-group > summary::-webkit-details-marker { display: none; }
.mobile-nav-group > summary i { color: var(--ink-400); font-size: .75rem; transition: transform var(--dur) var(--ease); }
.mobile-nav-group[open] > summary i { transform: rotate(180deg); }
.mobile-nav-submenu { display: grid; gap: 18px; padding: 14px 0 18px; border-bottom: 1px solid var(--ink-100); }
.mobile-nav-feature { background: var(--brand-gradient); color: #fff; border-radius: var(--r-md); padding: 18px; }
.mobile-nav-feature h4 { margin: 8px 0 8px; font-family: var(--font-display); font-size: 1.35rem; line-height: 1.05; }
.mobile-nav-feature p { margin: 0 0 14px; color: var(--ink-300); font-size: .82rem; line-height: 1.45; }
.mobile-nav-feature .btn { color: var(--mint-700); background: #fff; }
.mobile-nav-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.mobile-nav-columns h5 { margin: 0 0 8px; color: var(--ink-500); font: 500 .68rem var(--font-mono); letter-spacing: .15em; text-transform: uppercase; }
.mobile-nav-columns ul { display: grid; gap: 2px; list-style: none; margin: 0; padding: 0; }
.mobile-nav-columns a { display: flex; justify-content: space-between; gap: 8px; padding: 8px 0; color: var(--ink-700); font-size: .86rem; text-decoration: none; }
.mobile-nav-columns a:hover { color: var(--mint-700); }
.mobile-nav-columns a i { color: var(--ink-400); }
.mobile-account-group { margin-top: 4px; border-top: 1px solid var(--ink-100); }
.mobile-nav-account { display: grid; gap: 2px; padding: 8px 0 12px; border-bottom: 1px solid var(--ink-100); }
.mobile-nav-account a,
.mobile-nav-account button { display: flex; align-items: center; gap: 10px; width: 100%; padding: 10px 4px; border: 0; background: transparent; color: var(--ink-700); font: inherit; font-size: .88rem; text-align: left; text-decoration: none; cursor: pointer; }
.mobile-nav-account a:hover,
.mobile-nav-account button:hover { color: var(--mint-700); }
.mobile-nav-account i { width: 18px; text-align: center; }
.mobile-nav-account form { margin: 4px 0 0; border-top: 1px solid var(--ink-100); }
.mobile-nav-account form button { color: var(--ochre-600); padding-top: 12px; }

/* Keep long desktop mega menus inside the viewport and let the menu scroll independently. */
.mega {
  max-height: calc(100vh - 96px); max-height: min(680px, calc(100svh - 96px));
  overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-gutter: stable;
  align-items: start;
}
.mega > div { min-width: 0; align-self: start; }
.mega .mega-categories ul { grid-template-columns: repeat(1, minmax(0, 1fr)); column-gap: 12px; align-content: start; }
.mega .mega-categories li { min-width: 0; }
.mega .mega-categories a { min-width: 0; }
.mega .mega-categories a i { flex-shrink: 0; }


.info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.info-cell { background: var(--paper-alt); border: 1px solid var(--paper-line); border-radius: var(--r-md); padding: 18px; }
.info-cell small { color: var(--ink-500); font-family: var(--font-mono); text-transform: uppercase; font-size: .7rem; letter-spacing: .12em; }
.info-cell b { display: block; margin-top: 6px; font-size: 1.02rem; color: var(--ink-950); font-weight: 500; }

/* Sub-tabs (inside profile / my learning) */
.subtabs { display: flex; gap: 4px; background: var(--paper-alt); border: 1px solid var(--paper-line); border-radius: var(--r-pill); padding: 4px; margin-bottom: 28px; width: fit-content; overflow-x: auto; }
.subtabs button { padding: 10px 18px; border-radius: var(--r-pill); border: none; background: transparent; font-size: .88rem; font-weight: 500; color: var(--ink-500); transition: all var(--dur) var(--ease); white-space: nowrap; }
.subtabs button.active { background: #fff; color: var(--ink-950); box-shadow: var(--shadow-1); }

/* Responsive learn/checkout/cart/profile */
@media (max-width: 960px) {
  .learn-shell, .cart-shell, .checkout-shell, .exam-shell, .profile-shell { grid-template-columns: 1fr; }
  .curriculum, .summary-card, .exam-side, .profile-side { position: static; max-height: none; }
  .cart-item { grid-template-columns: 100px 1fr; }
  .cart-item .price-col { grid-column: 1 / -1; text-align: left; padding-top: 12px; border-top: 1px solid var(--ink-100); display: flex; justify-content: space-between; align-items: center; }
}

/* Learning page responsive hardening */
@media (max-width: 760px) {
  .learn-topbar { padding: 10px 0; }
  .learn-topbar .inner { align-items: flex-start; gap: 10px; }
  .learn-topbar .title { min-width: 0; flex: 1 1 auto; gap: 9px; }
  .learn-topbar .title > div { min-width: 0; }
  .learn-topbar .title h4,
  .learn-topbar .title small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .learn-topbar .title h4 { font-size: .86rem; }
  .learn-topbar .title small { display: block; max-width: 58vw; font-size: .68rem; }
  .learn-topbar .prog { flex: 0 0 auto; gap: 7px; font-size: .7rem; }
  .learn-topbar .prog > span { display: none; }
  .learn-topbar .bar { width: 78px; }
  .learn-topbar a.exit { font-size: .72rem; }
  .learn-shell { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 18px 0 56px; }
  .player-wrap { border-radius: 14px; }
  .lesson-meta { align-items: flex-start; }
  .lesson-meta .l { min-width: 0; width: 100%; align-items: flex-start; }
  .lesson-meta .l > div { min-width: 0; }
  .lesson-meta .l h2 { font-size: 1.35rem; overflow-wrap: anywhere; }
  .lesson-meta .r { width: 100%; justify-content: space-between; }
  .tabs { margin: 20px 0; }
  .tabs button { padding: 12px 13px; font-size: .8rem; }
  .assessment-card { grid-template-columns: 48px minmax(0, 1fr); gap: 12px; align-items: start; }
  .assessment-card .icn { width: 48px; height: 48px; }
  .assessment-card > div:nth-child(2) { min-width: 0; }
  .assessment-card > div:last-child { grid-column: 2; }
  .curriculum { width: 100%; }
  .live-table-wrap { max-width: 100%; }
}

@media (max-width: 420px) {
  .ol-container { padding-inline: 14px; }
  .learn-topbar .brand-mark { display: none; }
  .learn-topbar a.exit { display: none; }
  .learn-topbar .bar { width: 64px; }
  .player-wrap .zoom-cover { padding: 22px; }
  .player-wrap .zoom-cover h3 { font-size: 1.45rem; }
  .player-wrap .zoom-cover p { font-size: .78rem; }
  .player-wrap .recording-player-title { left: 10px; right: 10px; bottom: 10px; font-size: .72rem; }
  .tabs button { padding-inline: 11px; font-size: .74rem; }
  .live-tabs button { padding-inline: 10px; font-size: .78rem; }
}
/* Responsive learn/checkout/cart/profile */
@media (max-width: 960px) {
  .nav-inner { padding: 12px 0; gap: 12px; }
  .nav-cta { margin-left: auto; gap: 8px; }
  .mobile-toggle { display: inline-flex; align-items: center; justify-content: center; width: 42px; height: 42px; padding: 0; border: 1px solid var(--ink-200); color: var(--ink-900); cursor: pointer; }
  .mobile-toggle:hover, .mobile-toggle[aria-expanded="true"] { background: var(--ink-100); }
  .mobile-toggle i { font-size: 1.15rem; line-height: 1; }
  .mobile-nav-panel { display: block; max-height: calc(100vh - 68px); max-height: calc(100svh - 68px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; padding: 0 max(14px, calc((100vw - 1180px) / 2)); background: rgba(255,255,255,.98); border-top: 1px solid var(--ink-100); box-shadow: var(--shadow-3); }
  .learn-shell, .cart-shell, .checkout-shell, .exam-shell, .profile-shell { grid-template-columns: 1fr; }
  .curriculum, .summary-card, .exam-side, .profile-side { position: static; max-height: none; }
  .cart-item { grid-template-columns: 100px 1fr; }
  .cart-item .price-col { grid-column: 1 / -1; text-align: left; padding-top: 12px; border-top: 1px solid var(--ink-100); display: flex; justify-content: space-between; align-items: center; }
}

/* Learning page responsive hardening */
@media (max-width: 760px) {
  .nav-links, .nav-cta .desktop { display: none; }
  .learn-topbar { padding: 10px 0; }
  .learn-topbar .inner { align-items: flex-start; gap: 10px; }
  .learn-topbar .title { min-width: 0; flex: 1 1 auto; gap: 9px; }
  .learn-topbar .title > div { min-width: 0; }
  .learn-topbar .title h4,
  .learn-topbar .title small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .learn-topbar .title h4 { font-size: .86rem; }
  .learn-topbar .title small { display: block; max-width: 58vw; font-size: .68rem; }
  .learn-topbar .prog { flex: 0 0 auto; gap: 7px; font-size: .7rem; }
  .learn-topbar .prog > span { display: none; }
  .learn-topbar .bar { width: 78px; }
  .learn-topbar a.exit { font-size: .72rem; }
  .learn-shell { grid-template-columns: minmax(0, 1fr); gap: 20px; padding: 18px 0 56px; }
  .player-wrap { border-radius: 14px; }
  .lesson-meta { align-items: flex-start; }
  .lesson-meta .l { min-width: 0; width: 100%; align-items: flex-start; }
  .lesson-meta .l > div { min-width: 0; }
  .lesson-meta .l h2 { font-size: 1.35rem; overflow-wrap: anywhere; }
  .lesson-meta .r { width: 100%; justify-content: space-between; }
  .tabs { margin: 20px 0; }
  .tabs button { padding: 12px 13px; font-size: .8rem; }
  .assessment-card { grid-template-columns: 48px minmax(0, 1fr); gap: 12px; align-items: start; }
  .assessment-card .icn { width: 48px; height: 48px; }
  .assessment-card > div:nth-child(2) { min-width: 0; }
  .assessment-card > div:last-child { grid-column: 2; }
  .curriculum { width: 100%; }
  .live-table-wrap { max-width: 100%; }
}

@media (max-width: 420px) {
  .mobile-nav-columns { grid-template-columns: 1fr; gap: 14px; }
  .mobile-nav-feature h4 { font-size: 1.2rem; }
  .ol-container { padding-inline: 14px; }
  .learn-topbar .brand-mark { display: none; }
  .learn-topbar a.exit { display: none; }
  .learn-topbar .bar { width: 64px; }
  .player-wrap .zoom-cover { padding: 22px; }
  .player-wrap .zoom-cover h3 { font-size: 1.45rem; }
  .player-wrap .zoom-cover p { font-size: .78rem; }
  .player-wrap .recording-player-title { left: 10px; right: 10px; bottom: 10px; font-size: .72rem; }
  .tabs button { padding-inline: 11px; font-size: .74rem; }
  .live-tabs button { padding-inline: 10px; font-size: .78rem; }
}
@media (max-width: 960px) {
  .nav-inner > nav {
    display: none !important;
  }

  .nav-links,
  .nav-cta .desktop {
    display: none !important;
  }
}
@media (min-width: 961px) {
  .mobile-nav-panel,
  .mobile-nav-panel[hidden] {
    display: none !important;
  }

  .mobile-toggle {
    display: none !important;
  }
}
