:root {
  --bg: #061019;
  --surface: #0b1b27;
  --surface-2: #102635;
  --surface-3: #163142;
  --line: rgba(142, 196, 218, .14);
  --line-strong: rgba(104, 226, 239, .28);
  --text: #f3f7f9;
  --muted: #91a8b5;
  --cyan: #64e2ee;
  --blue: #78aaff;
  --yellow: #f5c84b;
  --green: #35d39a;
  --red: #ff7d79;
  --shadow: 0 24px 80px rgba(0, 0, 0, .45);
  --radius: 22px;
  font-family: "Segoe UI", system-ui, sans-serif;
  color: var(--text);
  background: var(--bg);
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 12% 4%, rgba(50, 205, 220, .09), transparent 28%),
    radial-gradient(circle at 90% 90%, rgba(77, 120, 255, .10), transparent 32%),
    var(--bg);
  overflow-x: hidden;
}
button { font: inherit; }
button, [role="button"] { -webkit-tap-highlight-color: transparent; }

.ambient { position: fixed; border-radius: 50%; filter: blur(90px); pointer-events: none; opacity: .18; }
.ambient-one { width: 300px; height: 300px; background: #1abccc; top: -140px; left: -120px; }
.ambient-two { width: 330px; height: 330px; background: #4776e6; right: -160px; bottom: -160px; }

.app-shell {
  width: min(100%, 430px);
  min-height: 100svh;
  margin: 0 auto;
  position: relative;
  background: linear-gradient(180deg, rgba(8, 24, 34, .98), rgba(5, 16, 24, .99));
  box-shadow: var(--shadow);
  border-inline: 1px solid rgba(255,255,255,.04);
  overflow: hidden;
}

.screen { min-height: 100svh; padding: max(18px, env(safe-area-inset-top)) 20px calc(102px + env(safe-area-inset-bottom)); animation: enter .35s ease both; }
.screen.study { padding-bottom: 36px; }
@keyframes enter { from { opacity: 0; transform: translateY(7px); } }

.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 24px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand-mark { width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center; color: var(--cyan); background: rgba(100,226,238,.09); border: 1px solid rgba(100,226,238,.2); font-weight: 800; }
.brand-copy small, .eyebrow { display: block; font: 600 10px/1.2 ui-monospace, "Cascadia Mono", monospace; letter-spacing: .13em; text-transform: uppercase; color: var(--cyan); }
.brand-copy strong { display: block; margin-top: 2px; font-size: 14px; letter-spacing: .02em; }
.avatar { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line-strong); color: var(--text); background: var(--surface-2); font-weight: 700; cursor: pointer; }

h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(28px, 8vw, 36px); line-height: 1.08; letter-spacing: -.045em; margin-bottom: 12px; }
h2 { font-size: 22px; line-height: 1.2; letter-spacing: -.025em; }
h3 { font-size: 15px; }
.lead { color: var(--muted); line-height: 1.62; font-size: 14px; }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, "Cascadia Mono", monospace; }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 14px; margin: 28px 0 12px; }
.section-head h2 { margin: 0; font-size: 18px; }
.text-button { border: 0; color: var(--cyan); background: transparent; padding: 4px 0; font-size: 12px; cursor: pointer; }

.hero-card { padding: 22px; border-radius: 28px; background: linear-gradient(145deg, rgba(28, 66, 86, .94), rgba(12, 32, 45, .96)); border: 1px solid rgba(100,226,238,.18); position: relative; overflow: hidden; }
.hero-card::after { content: ""; position: absolute; width: 170px; height: 170px; border: 1px solid rgba(100,226,238,.13); border-radius: 50%; right: -60px; top: -82px; box-shadow: 0 0 0 24px rgba(100,226,238,.025), 0 0 0 50px rgba(100,226,238,.018); }
.hero-card h1 { max-width: 290px; }
.hero-card .lead { max-width: 315px; margin-bottom: 22px; }
.progress-label { display: flex; justify-content: space-between; gap: 12px; font-size: 11px; color: var(--muted); margin-bottom: 8px; }
.progress-track { height: 6px; border-radius: 99px; background: rgba(255,255,255,.08); overflow: hidden; }
.progress-fill { height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan), var(--blue)); box-shadow: 0 0 16px rgba(100,226,238,.35); }

.primary, .secondary { min-height: 48px; border-radius: 15px; border: 1px solid transparent; padding: 0 18px; display: inline-flex; justify-content: center; align-items: center; gap: 8px; font-weight: 800; cursor: pointer; transition: .2s ease; }
.primary { color: #06212a; background: var(--cyan); box-shadow: 0 8px 24px rgba(100,226,238,.17); }
.primary:hover { transform: translateY(-1px); background: #82edf5; }
.primary:disabled { opacity: .38; cursor: not-allowed; transform: none; }
.secondary { color: var(--text); background: var(--surface-2); border-color: var(--line); }
.wide { width: 100%; }

.quick-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.quick-card { min-height: 112px; text-align: left; padding: 15px; border-radius: 18px; border: 1px solid var(--line); color: var(--text); background: rgba(16,38,53,.72); cursor: pointer; }
.quick-card span { display: block; width: 34px; height: 34px; border-radius: 11px; display: grid; place-items: center; color: var(--cyan); background: rgba(100,226,238,.09); margin-bottom: 12px; }
.quick-card strong { display: block; font-size: 13px; }
.quick-card small { display: block; color: var(--muted); font-size: 10px; margin-top: 3px; }

.topic-list { display: grid; gap: 10px; }
.topic-card { display: grid; grid-template-columns: 44px 1fr auto; align-items: center; gap: 12px; width: 100%; padding: 13px; text-align: left; color: var(--text); background: rgba(13,31,43,.78); border: 1px solid var(--line); border-radius: 17px; cursor: pointer; }
.topic-icon { width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center; background: rgba(120,170,255,.1); color: var(--blue); font: 600 13px ui-monospace, "Cascadia Mono", monospace; }
.topic-card strong { font-size: 13px; display: block; }
.topic-card small { display: block; color: var(--muted); font-size: 10px; margin-top: 4px; }
.chevron { color: var(--cyan); font-size: 20px; }

.bottom-nav { position: fixed; z-index: 20; width: min(100%, 430px); left: 50%; bottom: 0; transform: translateX(-50%); display: grid; grid-template-columns: repeat(4,1fr); padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: rgba(5,16,24,.92); backdrop-filter: blur(18px); border-top: 1px solid var(--line); }
.nav-item { border: 0; background: transparent; color: #6f8795; min-height: 50px; display: grid; place-items: center; gap: 3px; font-size: 9px; cursor: pointer; }
.nav-item .nav-icon { font-size: 17px; }
.nav-item.active { color: var(--cyan); }

.back { width: 40px; height: 40px; border-radius: 13px; border: 1px solid var(--line); background: var(--surface); color: var(--text); cursor: pointer; }
.study-progress { flex: 1; }
.study-progress .progress-track { height: 4px; }
.question-meta { display: flex; flex-wrap: wrap; gap: 7px; margin: 6px 0 18px; }
.chip { border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: rgba(255,255,255,.02); padding: 5px 9px; font: 500 9px ui-monospace, "Cascadia Mono", monospace; }
.question-card { background: linear-gradient(180deg, rgba(16,38,53,.93), rgba(9,27,39,.92)); border: 1px solid var(--line); border-radius: 22px; padding: 20px; margin-bottom: 16px; }
.question-card p { line-height: 1.62; font-size: 15px; margin-bottom: 0; }
.answers { display: grid; gap: 10px; }
.answer { width: 100%; min-height: 56px; padding: 12px 14px; display: grid; grid-template-columns: 32px 1fr; align-items: center; gap: 11px; text-align: left; color: var(--text); background: rgba(12,30,42,.88); border: 1px solid var(--line); border-radius: 16px; cursor: pointer; transition: .2s; }
.answer:hover, .answer.selected { border-color: var(--cyan); background: rgba(100,226,238,.075); }
.answer-key { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; color: var(--muted); background: rgba(255,255,255,.05); font: 500 12px ui-monospace, "Cascadia Mono", monospace; }
.answer.selected .answer-key { color: #06212a; background: var(--cyan); }
.answer.correct { border-color: var(--green); background: rgba(53,211,154,.08); }
.answer.wrong { border-color: var(--red); background: rgba(255,125,121,.08); }
.study-action { margin-top: 18px; }

.result-hero { text-align: center; padding: 8px 0 20px; }
.result-icon { width: 68px; height: 68px; margin: 0 auto 14px; border-radius: 22px; display: grid; place-items: center; font-size: 28px; background: rgba(53,211,154,.12); color: var(--green); border: 1px solid rgba(53,211,154,.25); }
.result-icon.error { background: rgba(255,125,121,.1); color: var(--red); border-color: rgba(255,125,121,.25); }
.result-hero h1 { font-size: 29px; margin-bottom: 6px; }
.result-hero p { color: var(--muted); font-size: 13px; }
.essential { padding: 19px; border-radius: 20px; background: linear-gradient(145deg, rgba(27,63,82,.9), rgba(12,32,45,.92)); border: 1px solid var(--line-strong); }
.editorial-seal { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 15px; padding: 5px 8px; border-radius: 999px; color: var(--green); background: rgba(53,211,154,.07); border: 1px solid rgba(53,211,154,.18); font: 600 8px ui-monospace, "Cascadia Mono", monospace; text-transform: uppercase; letter-spacing: .06em; }
.essential .answer-value { color: var(--cyan); font-size: 25px; font-weight: 800; margin: 5px 0 9px; }
.essential p { color: #c0d1d9; line-height: 1.55; font-size: 13px; margin-bottom: 0; }
.save-row { display: flex; gap: 9px; margin: 12px 0 20px; }
.save-row button { flex: 1; }
.coverage-card { margin: 4px 0 22px; padding: 16px; border-radius: 18px; background: rgba(9,27,39,.82); border: 1px solid var(--line); display: grid; grid-template-columns: 1fr auto; gap: 10px 14px; align-items: end; }
.coverage-card strong { display: block; margin-top: 5px; font-size: 13px; }
.coverage-card .coverage-value { color: var(--cyan); font-size: 23px; font-weight: 800; }
.coverage-card .progress-track, .coverage-card small { grid-column: 1 / -1; }
.coverage-card small { color: var(--muted); font-size: 9px; line-height: 1.4; }

.insight-list { display: grid; gap: 10px; }
.insight { border: 1px solid var(--line); border-radius: 18px; background: rgba(12,30,42,.72); overflow: hidden; }
.insight summary { list-style: none; display: grid; grid-template-columns: 38px 1fr auto auto; align-items: center; gap: 9px; padding: 14px; cursor: pointer; }
.insight summary::-webkit-details-marker { display: none; }
.layer-num { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: rgba(100,226,238,.09); color: var(--cyan); font: 500 11px ui-monospace, "Cascadia Mono", monospace; }
.insight summary strong { font-size: 13px; display: block; }
.insight summary small { color: var(--muted); font-size: 10px; }
.group-count { color: var(--muted); padding: 4px 7px; border: 1px solid var(--line); border-radius: 999px; font: 500 9px ui-monospace, "Cascadia Mono", monospace; }
.insight-content { border-top: 1px solid var(--line); padding: 15px; color: #c0d1d9; font-size: 13px; line-height: 1.6; animation: reveal .25s ease; }
@keyframes reveal { from { opacity: 0; transform: translateY(-4px); } }
.insight-content h3 { color: var(--text); margin: 12px 0 5px; }
.insight-content h3:first-child { margin-top: 0; }
.insight-content ol, .insight-content ul { padding-left: 20px; margin-bottom: 0; }
.insight-content li { margin-bottom: 7px; }
.reference { border-left: 2px solid var(--cyan); padding-left: 11px; }
.editorial-fields { display: grid; gap: 10px; }
.editorial-field { padding: 14px; border-radius: 14px; background: rgba(255,255,255,.025); border: 1px solid rgba(142,196,218,.10); }
.editorial-field .field-label { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.editorial-field h3 { margin: 0; font-size: 12px; }
.editorial-field p { margin: 0; }
.editorial-field ul { margin-top: 5px; }
.field-number { display: inline-grid; place-items: center; min-width: 25px; height: 20px; padding: 0 5px; border-radius: 6px; color: var(--cyan); background: rgba(100,226,238,.08); font: 600 9px ui-monospace, "Cascadia Mono", monospace; }
.resource-card { width: 100%; color: var(--text); text-align: left; display: grid; grid-template-columns: 27px 1fr auto; gap: 10px; align-items: center; padding: 13px; border-radius: 14px; background: linear-gradient(145deg, rgba(120,170,255,.07), rgba(100,226,238,.035)); border: 1px solid rgba(120,170,255,.16); cursor: pointer; }
.resource-card:hover { border-color: var(--line-strong); }
.resource-card strong { display: block; margin: 3px 0; font-size: 12px; }
.resource-card small { display: block; margin: 0; color: var(--muted); font-size: 10px; line-height: 1.4; }
.resource-kind { color: var(--blue); font: 600 8px ui-monospace, "Cascadia Mono", monospace; text-transform: uppercase; letter-spacing: .08em; }
.resource-open { color: var(--cyan); font-size: 20px; }
.group-media .layer-num { color: var(--green); background: rgba(53,211,154,.09); }
.group-interactive .layer-num { color: var(--blue); background: rgba(120,170,255,.10); }
.next-card { margin-top: 18px; padding: 18px; border-radius: 20px; background: rgba(120,170,255,.08); border: 1px solid rgba(120,170,255,.22); }
.next-card p { color: var(--muted); font-size: 12px; line-height: 1.5; }

.empty { text-align: center; padding: 60px 20px; }
.empty-icon { width: 62px; height: 62px; margin: auto auto 14px; display: grid; place-items: center; border-radius: 20px; background: var(--surface-2); color: var(--cyan); font-size: 24px; }
.stat-grid { display: grid; grid-template-columns: repeat(2,1fr); gap: 10px; }
.stat { padding: 16px; border-radius: 18px; background: var(--surface); border: 1px solid var(--line); }
.stat strong { display: block; font-size: 25px; }
.stat small { color: var(--muted); }
.knowledge-row { margin-top: 18px; }
.knowledge-row .progress-label strong { color: var(--text); font-size: 12px; }

.modal-backdrop { position: fixed; z-index: 60; inset: 0; display: flex; align-items: flex-end; justify-content: center; padding-top: 60px; background: rgba(0,8,13,.76); backdrop-filter: blur(8px); animation: fade .2s ease; }
@keyframes fade { from { opacity: 0; } }
.resource-modal { width: min(100%,430px); max-height: calc(100svh - 54px); overflow-y: auto; padding: 10px 20px calc(25px + env(safe-area-inset-bottom)); border-radius: 26px 26px 0 0; background: linear-gradient(180deg, #102635, #071722); border: 1px solid var(--line-strong); border-bottom: 0; box-shadow: 0 -24px 80px rgba(0,0,0,.5); animation: sheet .28s ease; }
@keyframes sheet { from { transform: translateY(40px); opacity: .7; } }
.modal-handle { width: 42px; height: 4px; border-radius: 99px; background: rgba(255,255,255,.18); margin: 0 auto 16px; }
.resource-modal header { display: flex; justify-content: space-between; align-items: start; gap: 12px; margin-bottom: 18px; }
.resource-modal header h2 { margin: 6px 0 0; }
.modal-body > p { color: var(--muted); line-height: 1.6; }
.media-placeholder { min-height: 210px; border-radius: 20px; display: grid; place-items: center; align-content: center; gap: 10px; color: var(--cyan); font-size: 44px; background: radial-gradient(circle, rgba(100,226,238,.12), transparent 55%), var(--surface); border: 1px solid var(--line); }
.media-placeholder small { color: var(--muted); font-size: 10px; text-transform: uppercase; letter-spacing: .08em; }
.source-note { margin-top: 14px; padding: 13px; display: grid; gap: 4px; border-radius: 13px; background: rgba(53,211,154,.055); border: 1px solid rgba(53,211,154,.14); }
.source-note strong { color: var(--green); font-size: 10px; text-transform: uppercase; }
.source-note span { color: var(--muted); font-size: 10px; line-height: 1.5; }
.tool-panel > p { color: var(--muted); font-size: 12px; line-height: 1.55; }
.tool-label { display: grid; gap: 7px; margin: 14px 0; color: var(--muted); font-size: 11px; }
.tool-label input[type="number"] { width: 100%; min-height: 48px; border-radius: 13px; padding: 0 13px; color: var(--text); background: var(--surface); border: 1px solid var(--line); font: 600 16px ui-monospace, monospace; }
.tool-label input[type="range"] { width: 100%; accent-color: var(--cyan); }
.tool-result { margin-top: 14px; padding: 17px; border-radius: 16px; display: grid; gap: 3px; background: rgba(100,226,238,.07); border: 1px solid var(--line-strong); }
.tool-result small, .tool-result span { color: var(--muted); font-size: 10px; }
.tool-result strong { color: var(--cyan); font-size: 26px; }
.sim-visual { min-height: 220px; position: relative; overflow: hidden; border-radius: 18px; background: linear-gradient(#112c3c 0 62%, #15291f 62%); border: 1px solid var(--line); }
.sim-line { position: absolute; left: 12px; right: 12px; display: flex; justify-content: space-between; color: var(--muted); font-size: 10px; border-top: 1px dashed rgba(255,255,255,.22); padding-top: 5px; }
.sim-line.indicated { top: 34%; }.sim-line.true { top: 67%; color: var(--cyan); }
.sim-aircraft { position: absolute; z-index: 2; left: calc(50% - 17px); top: calc(50% - 17px); width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #06212a; background: var(--cyan); transition: transform .15s ease; }
.tool-hint { color: var(--cyan) !important; }
.compare-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 9px; }
.compare-grid article { padding: 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); }
.compare-grid small { display: block; color: var(--muted); font-size: 9px; }.compare-grid strong { display: block; margin-top: 6px; font-size: 20px; }
.compare-grid .accent { border-color: var(--line-strong); }.compare-grid .accent strong { color: var(--cyan); }
.exercise-question { color: var(--text) !important; font-weight: 700; }
.mini-options { display: grid; gap: 8px; }
.mini-options button { min-height: 45px; border-radius: 13px; color: var(--text); background: var(--surface); border: 1px solid var(--line); cursor: pointer; }
.mini-options button.mini-correct { color: var(--green); border-color: var(--green); background: rgba(53,211,154,.08); }
.mini-options button.mini-wrong { color: var(--red); border-color: var(--red); background: rgba(255,125,121,.08); }
.mini-feedback { margin-top: 12px; padding: 12px; border-radius: 12px; color: var(--muted); background: rgba(255,255,255,.03); font-size: 11px; }
.mini-feedback.ok { color: var(--green); }.mini-feedback.attention { color: var(--yellow); }

@media (min-width: 700px) {
  body { padding: 28px 0; }
  .app-shell { min-height: calc(100vh - 56px); border-radius: 32px; }
  .screen { min-height: calc(100vh - 56px); }
  .bottom-nav { bottom: 28px; border-radius: 0 0 32px 32px; }
}

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; } }

/* =========================================================
   iOS DESIGN SYSTEM — Apple HIG-inspired web prototype
   ========================================================= */
:root {
  --bg: #000000;
  --surface: #1c1c1e;
  --surface-2: #2c2c2e;
  --surface-3: #3a3a3c;
  --line: rgba(84,84,88,.62);
  --line-strong: rgba(99,99,102,.72);
  --text: #ffffff;
  --muted: #98989d;
  --cyan: #0a84ff;
  --blue: #0a84ff;
  --yellow: #ff9f0a;
  --green: #30d158;
  --red: #ff453a;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", sans-serif;
}

body { background: #09090b; }
.ambient { display: none; }
.app-shell { background: #000; border-color: #202024; }
.screen { padding: 0 16px calc(112px + env(safe-area-inset-bottom)); }
.screen.study { padding-bottom: calc(34px + env(safe-area-inset-bottom)); }

.ios-status-bar { height: calc(47px + env(safe-area-inset-top)); padding: max(14px, env(safe-area-inset-top)) 8px 0; display: flex; justify-content: space-between; align-items: flex-start; font-size: 14px; letter-spacing: -.01em; }
.ios-status-bar strong { padding-left: 8px; }
.status-icons { padding-right: 7px; font-size: 11px; letter-spacing: .08em; }

.topbar { min-height: 44px; margin: 0 -2px 8px; }
.brand { gap: 8px; }
.brand-mark { width: 30px; height: 30px; border-radius: 9px; border: 0; color: #fff; background: var(--blue); font-size: 13px; }
.brand-copy small { color: var(--muted); font: 600 9px/1.1 -apple-system, BlinkMacSystemFont, sans-serif; letter-spacing: .04em; text-transform: uppercase; }
.brand-copy strong { font-size: 12px; }
.avatar { width: 32px; height: 32px; border: 0; background: var(--surface-2); color: var(--blue); font-size: 11px; }

.ios-large-title { padding: 10px 0 16px; }
.ios-large-title span { color: var(--muted); font-size: 12px; font-weight: 600; }
.ios-large-title h1 { margin: 2px 0 0; font-size: 34px; line-height: 1.12; letter-spacing: -.035em; font-weight: 750; }
.ios-prompt { margin: 4px 0 6px; font-size: 20px; }
.eyebrow { color: var(--muted); font-family: -apple-system, BlinkMacSystemFont, sans-serif; font-size: 10px; font-weight: 650; letter-spacing: .055em; }

.ios-nav { position: relative; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; min-height: 44px; margin: 0 -8px 12px; }
.ios-back, .ios-more { min-height: 44px; border: 0; color: var(--blue); background: transparent; cursor: pointer; }
.ios-back { justify-self: start; padding: 0 8px; font-size: 16px; }
.ios-back span { font-size: 34px; line-height: 0; vertical-align: -3px; font-weight: 300; }
.ios-more { justify-self: end; width: 44px; font-size: 14px; letter-spacing: 2px; }
.nav-title { font-size: 16px; font-weight: 650; }
.study > .study-progress { margin: -2px 0 17px; }

.hero-card { padding: 20px; border-radius: 16px; background: var(--surface); border: 0; box-shadow: none; }
.hero-card::after { display: none; }
.hero-card h1 { font-size: 27px; line-height: 1.12; letter-spacing: -.035em; }
.lead { font-size: 14px; line-height: 1.45; }
.primary, .secondary { min-height: 50px; border-radius: 13px; font-weight: 650; }
.primary { color: #fff; background: var(--blue); box-shadow: none; }
.primary:hover { background: #409cff; transform: none; }
.secondary { color: var(--blue); background: var(--surface); border: 0; }

.progress-track { height: 4px; background: var(--surface-3); }
.progress-fill { background: var(--blue); box-shadow: none; }
.progress-label { font-size: 11px; }

.section-head { margin: 28px 4px 9px; }
.section-head h2 { font-size: 20px; }
.text-button { color: var(--blue); font-size: 14px; }
.quick-grid { gap: 10px; }
.quick-card { min-height: 104px; padding: 14px; border-radius: 16px; border: 0; background: var(--surface); }
.quick-card span { width: 32px; height: 32px; border-radius: 9px; color: #fff; background: var(--blue); }
.quick-card strong { font-size: 14px; }.quick-card small { font-size: 11px; }

/* Inset grouped lists with hairline separators */
.topic-list { display: block; overflow: hidden; border-radius: 12px; background: var(--surface); }
.topic-card { position: relative; min-height: 62px; grid-template-columns: 38px 1fr 16px; gap: 11px; padding: 10px 13px; border: 0; border-radius: 0; background: transparent; }
.topic-card:not(:last-child)::after { content: ""; position: absolute; height: .5px; left: 62px; right: 0; bottom: 0; background: var(--line); }
.topic-card:active { background: var(--surface-2); }
.topic-icon { width: 36px; height: 36px; border-radius: 8px; color: #fff; background: var(--blue); font-family: -apple-system, BlinkMacSystemFont, sans-serif; font-size: 11px; }
.topic-card strong { font-size: 15px; font-weight: 560; }.topic-card small { font-size: 11px; }
.chevron { color: #636366; font-size: 22px; font-weight: 300; }

.bottom-nav { width: min(calc(100% - 20px), 410px); bottom: calc(8px + env(safe-area-inset-bottom)); grid-template-columns: repeat(4,1fr); padding: 7px 10px 17px; border: 1px solid rgba(255,255,255,.14); border-radius: 26px; background: rgba(44,44,46,.76); backdrop-filter: saturate(180%) blur(28px); box-shadow: 0 10px 38px rgba(0,0,0,.5); }
.nav-item { min-height: 45px; color: #98989d; font-size: 10px; }
.nav-item .nav-icon { font-size: 19px; }.nav-item.active { color: var(--blue); }
.home-indicator { position: absolute; width: 114px; height: 4px; border-radius: 99px; background: rgba(255,255,255,.92); left: 50%; bottom: 5px; transform: translateX(-50%); }

.chip { padding: 4px 7px; border: 0; color: var(--muted); background: var(--surface-2); font-family: -apple-system, BlinkMacSystemFont, sans-serif; font-size: 10px; }
.question-meta { margin-bottom: 12px; }
.question-card { padding: 17px; border-radius: 12px; border: 0; background: var(--surface); }
.question-card p { font-size: 17px; line-height: 1.48; }

.answers { display: block; overflow: hidden; border-radius: 12px; background: var(--surface); }
.answer { position: relative; min-height: 54px; width: 100%; display: grid; grid-template-columns: 1fr 24px; gap: 10px; padding: 12px 14px; border: 0; border-radius: 0; background: transparent; font-size: 16px; }
.answer:not(:last-child)::after { content: ""; position: absolute; left: 14px; right: 0; bottom: 0; height: .5px; background: var(--line); }
.answer:hover { background: transparent; border: 0; }.answer:active { background: var(--surface-2); }
.answer.selected { color: var(--text); background: transparent; border: 0; }
.answer b { color: var(--muted); font-weight: 500; margin-right: 4px; }
.answer-check { color: var(--blue); justify-self: end; font-size: 21px; font-weight: 650; }
.answer-key { display: none; }
.study-action { margin-top: 22px; }

.result-hero { padding-top: 8px; }
.result-icon { width: 64px; height: 64px; border-radius: 50%; border: 0; color: #fff; background: var(--green); }
.result-icon.error { color: #fff; border: 0; background: var(--orange, #ff9f0a); }
.result-hero h1 { font-size: 28px; }.result-hero p { font-size: 14px; }
.essential { border: 0; border-radius: 14px; background: var(--surface); }
.editorial-seal { color: var(--green); border: 0; background: rgba(48,209,88,.12); }
.essential .answer-value { color: var(--green); }
.save-row .secondary { background: var(--surface); }
.coverage-card { border: 0; border-radius: 14px; background: var(--surface); }
.coverage-card .coverage-value { color: var(--blue); }

.insight-list { overflow: hidden; gap: 0; border-radius: 12px; background: var(--surface); }
.insight { position: relative; border: 0; border-radius: 0; background: transparent; }
.insight:not(:last-child)::after { content: ""; position: absolute; left: 64px; right: 0; bottom: 0; height: .5px; background: var(--line); }
.insight summary { min-height: 62px; padding: 10px 13px; }
.layer-num { width: 36px; height: 36px; border-radius: 9px; color: #fff; background: var(--blue); font-family: -apple-system, BlinkMacSystemFont, sans-serif; }
.group-correct .layer-num { background: var(--orange, #ff9f0a); }.group-apply .layer-num { background: var(--green); }.group-deepen .layer-num { background: #bf5af2; }.group-continue .layer-num { background: #ff375f; }.group-media .layer-num { background: #64d2ff; color: #002836; }.group-interactive .layer-num { background: #5e5ce6; }
.insight summary strong { font-size: 15px; font-weight: 560; }.insight summary small { font-size: 11px; }
.group-count { border: 0; background: var(--surface-2); font-family: -apple-system, BlinkMacSystemFont, sans-serif; }
.insight-content { padding: 12px 14px 16px; border-top: .5px solid var(--line); background: #121214; }
.editorial-field { border: 0; border-radius: 10px; background: var(--surface); }
.field-number { color: var(--blue); background: rgba(10,132,255,.14); font-family: -apple-system, BlinkMacSystemFont, sans-serif; }
.resource-card { border: 0; border-radius: 10px; background: var(--surface); }
.resource-kind { color: var(--blue); font-family: -apple-system, BlinkMacSystemFont, sans-serif; }
.next-card { border: 0; border-radius: 14px; background: var(--surface); }

.stat-grid { gap: 10px; }.stat { border: 0; border-radius: 14px; background: var(--surface); }
.resource-modal { background: rgba(28,28,30,.98); border-color: rgba(255,255,255,.14); }
.modal-backdrop { background: rgba(0,0,0,.55); }
.source-note { border: 0; background: rgba(48,209,88,.1); }
.tool-label input[type="number"], .mini-options button, .compare-grid article { border: 0; background: var(--surface-2); }

@media (min-width: 700px) {
  body { padding: 24px 0; }
  .app-shell { min-height: calc(100vh - 48px); border-radius: 48px; border: 8px solid #171719; box-shadow: 0 28px 90px rgba(0,0,0,.62); }
  .screen { min-height: calc(100vh - 64px); }
  .bottom-nav { bottom: 36px; }
}
