:root {
  --navy: #B0175E;
  --navy-2: #7D0F46;
  --ink: #2E1728;
  --muted: #8A6478;
  --canvas: #FFF4F9;
  --white: #ffffff;
  --lime: #ffd84d;
  --cyan: #58dfc2;
  --coral: #ff7868;
  --violet: #7868e6;
  --line: #F4D9E7;
  --shadow: 0 18px 45px rgba(176, 23, 94, .1);
  --radius: 24px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: radial-gradient(circle at 92% 2%, rgba(224,25,130,.12), transparent 25rem), var(--canvas); font-family: "DM Sans", sans-serif; font-size: 16px; }
button, a { font: inherit; }
button { color: inherit; }
a { color: inherit; text-decoration: none; }
button:focus-visible, a:focus-visible { outline: 3px solid rgba(84, 216, 237, .55); outline-offset: 3px; }

.app-shell { min-height: 100vh; display: grid; grid-template-columns: 250px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 28px; padding: 30px 22px; color: #F6DCE9; background: linear-gradient(180deg, var(--navy), var(--navy-2)); }
.brand { display: flex; align-items: center; gap: 11px; color: #fff; font-family: "Plus Jakarta Sans", sans-serif; font-size: 1.15rem; font-weight: 800; letter-spacing: -.04em; }
.brand > span:last-child span { color: var(--lime); }
.brand-mark { display: grid; place-items: center; width: 35px; height: 35px; border-radius: 11px; color: var(--navy); background: var(--lime); font-size: 1.4rem; }
.side-nav { display: grid; gap: 7px; }
.nav-item { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 47px; padding: 0 14px; border: 0; border-radius: 13px; color: #E3A8C4; background: transparent; text-align: left; font-weight: 600; cursor: pointer; }
.nav-item > span { width: 22px; text-align: center; font-size: 1.15rem; }
.nav-item:hover, .nav-item.active { color: #fff; background: rgba(255,255,255,.08); }
.nav-item.active { box-shadow: inset 3px 0 var(--lime); }
.sidebar-spacer { flex: 1; }
.mini-target { display: flex; gap: 11px; padding: 15px 14px; border: 1px solid rgba(255,255,255,.1); border-radius: 16px; background: rgba(255,255,255,.04); }
.target-icon { display: grid; place-items: center; width: 34px; height: 34px; flex: 0 0 34px; border-radius: 50%; color: var(--navy); background: var(--cyan); font-weight: 800; }
.mini-target strong, .mini-target span { display: block; }
.mini-target strong { font-size: .84rem; color: #fff; }
.mini-target span { margin-top: 3px; color: #E3A8C4; font-size: .76rem; }

.main { width: min(1260px, 100%); margin: 0 auto; padding: 34px 42px 70px; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.eyebrow, .section-kicker { margin: 0 0 6px; color: #8A7280; font-size: .72rem; font-weight: 800; letter-spacing: .14em; }
h1, h2, p { margin-top: 0; }
h1, h2 { font-family: "Plus Jakarta Sans", sans-serif; letter-spacing: -.04em; }
h1 { margin-bottom: 0; font-size: clamp(1.6rem, 2.4vw, 2.2rem); }
h2 { margin-bottom: 0; font-size: clamp(1.25rem, 2vw, 1.65rem); }
.top-actions, .streak { display: flex; align-items: center; }
.top-actions { gap: 15px; }
.streak { gap: 7px; padding: 9px 13px; border: 1px solid #e7dcb5; border-radius: 999px; background: #fff7d8; color: #7c5d00; font-size: .84rem; }
.streak > span:first-child { color: #f2a900; }
.avatar { width: 44px; height: 44px; border: 0; border-radius: 14px; background: var(--navy); color: #fff; font-weight: 800; cursor: pointer; }

.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(300px, .9fr); gap: 20px; }
.focus-card, .stats-card { border-radius: var(--radius); box-shadow: var(--shadow); }
.focus-card { position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) 175px; min-height: 300px; padding: 34px; color: #fff; background: linear-gradient(135deg, #B0175E 0%, #E0257F 100%); }
.focus-card::after { content: ""; position: absolute; right: 112px; bottom: -105px; width: 270px; height: 270px; border: 1px solid rgba(255,216,77,.25); border-radius: 50%; box-shadow: 0 0 0 42px rgba(255,216,77,.05), 0 0 0 84px rgba(88,223,194,.04); }
.focus-copy, .focus-score { position: relative; z-index: 1; }
.day-chip { display: inline-flex; margin-bottom: 25px; padding: 7px 11px; border: 1px solid rgba(255,216,77,.35); border-radius: 999px; color: var(--lime); background: rgba(255,216,77,.1); font-size: .72rem; font-weight: 800; letter-spacing: .1em; }
.focus-card .section-kicker { color: #F0C2DC; }
.focus-card h2 { max-width: 420px; font-size: clamp(1.6rem, 3vw, 2.4rem); }
.focus-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin: 13px 0 26px; color: #F0C2DC; font-size: .88rem; }
.focus-meta i { width: 3px; height: 3px; border-radius: 50%; background: #C98AA8; }
.primary-btn { display: inline-flex; align-items: center; justify-content: space-between; gap: 22px; min-height: 50px; padding: 0 18px; border: 0; border-radius: 14px; color: var(--navy); background: var(--lime); font-weight: 800; cursor: pointer; transition: transform .18s, box-shadow .18s; }
.primary-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(255,216,77,.26); }
.primary-btn span { font-size: 1.3rem; }
.focus-score { display: grid; align-content: center; justify-items: center; }
.score-ring { --progress: calc(var(--value) * 1%); display: grid; place-items: center; width: 132px; aspect-ratio: 1; border-radius: 50%; background: conic-gradient(var(--lime) 0 76%, rgba(255,255,255,.12) 76%); }
.score-ring::before { content: ""; grid-area: 1/1; width: 104px; aspect-ratio: 1; border-radius: 50%; background: var(--navy); }
.score-ring > div { grid-area: 1/1; text-align: center; z-index: 1; }
.score-ring strong, .score-ring span { display: block; }
.score-ring strong { font: 800 2rem/1 "Plus Jakarta Sans", sans-serif; }
.score-ring span { margin-top: 5px; color: #F0C2DC; font-size: .75rem; }
.focus-score p { margin: 14px 0 0; color: #F0C2DC; font-size: .8rem; }
.focus-score p b { color: #fff; }

.stats-card { padding: 29px; background: var(--white); }
.stats-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; margin-bottom: 28px; }
.trend { padding: 6px 8px; border-radius: 8px; color: #287252; background: #e5f8ee; font-size: .78rem; font-weight: 800; }
.stat-row { display: flex; align-items: end; justify-content: space-between; color: var(--muted); }
.stat-row strong { color: var(--ink); font: 800 2.2rem/1 "Plus Jakarta Sans", sans-serif; }
.meter { height: 8px; margin: 10px 0 28px; overflow: hidden; border-radius: 999px; background: #F6E6EE; }
.meter span { display: block; height: 100%; border-radius: inherit; background: var(--cyan); }
.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.stats-grid > div { padding: 22px 8px 0; }
.stats-grid > div + div { border-left: 1px solid var(--line); padding-left: 17px; }
.stats-grid strong, .stats-grid span { display: block; }
.stats-grid strong { font: 800 1.35rem "Plus Jakarta Sans", sans-serif; }
.stats-grid span { margin-top: 5px; color: var(--muted); font-size: .72rem; line-height: 1.25; }

.section-block { margin-top: 32px; }
.section-heading { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.text-btn { padding: 8px 0; border: 0; color: #A3195F; background: none; font-weight: 700; cursor: pointer; }
.day-track { display: grid; grid-template-columns: repeat(10, minmax(68px, 1fr)); gap: 10px; padding: 19px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; box-shadow: 0 10px 30px rgba(120,10,60,.04); }
.day { display: grid; place-items: center; gap: 5px; min-height: 75px; padding: 8px; border: 1px solid var(--line); border-radius: 14px; background: #fff; cursor: pointer; }
.day span { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; font-weight: 800; }
.day small { color: var(--muted); font-size: .7rem; }
.day.done span { color: #fff; background: var(--navy); }
.day.done span::after { content: "✓"; position: absolute; }
.day.done span { font-size: 0; }
.day.current { border-color: var(--lime); background: #fff7e0; box-shadow: inset 0 0 0 1px var(--lime); }
.day.current span { color: var(--navy); background: var(--lime); }
.day.locked { opacity: .48; }
.day.more { border-style: dashed; background: #FBEEF4; }

.subject-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.subject-card { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; align-items: center; gap: 13px; min-height: 105px; padding: 17px; border: 1px solid var(--line); border-radius: 18px; text-align: left; background: #fff; cursor: pointer; transition: transform .18s, box-shadow .18s; }
.subject-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.subject-icon { display: grid; place-items: center; width: 52px; height: 52px; border-radius: 15px; font: 800 1.25rem "Plus Jakarta Sans", sans-serif; }
.subject-card strong, .subject-card small { display: block; }
.subject-card strong { font: 700 .94rem "Plus Jakarta Sans", sans-serif; }
.subject-card small { margin-top: 5px; color: var(--muted); font-size: .72rem; }
.subject-card > b { color: #B98AA4; }
.math .subject-icon { background: #e8e4ff; color: #5e4bd0; }
.science .subject-icon { background: #ddf8f0; color: #16795c; }
.language .subject-icon { background: #fff0e7; color: #b95228; }
.logic .subject-icon { background: #e3f6fb; color: #18778b; }
.complete { grid-column: span 3; color: #fff; border-color: var(--navy); background: linear-gradient(100deg, var(--navy), #E0257F); }
.complete .subject-icon { color: var(--navy); background: var(--lime); }
.complete small { color: #E3A8C4; }
.mobile-nav { display: none; }

.skip-link { position: fixed; z-index: 100; top: 10px; left: 10px; transform: translateY(-150%); padding: 10px 14px; border-radius: 10px; color: #fff; background: var(--navy); }
.skip-link:focus { transform: translateY(0); }
.brand-button { padding: 0; border: 0; text-align: left; background: transparent; cursor: pointer; }
.screen[hidden], .mobile-nav[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.full { width: 100%; justify-content: center; }
.compact { min-height: 46px; gap: 12px; }
.secondary-btn { min-height: 46px; padding: 0 17px; border: 1px solid var(--line); border-radius: 13px; color: var(--ink); background: #fff; font-weight: 700; cursor: pointer; }
.secondary-btn:hover { border-color: #E0A8C4; background: #FBEEF4; }
.secondary-btn:disabled { opacity: .42; cursor: not-allowed; }
.trend.down { color: #a33e32; background: #ffebe8; }
.day:disabled { cursor: not-allowed; }

/* Ruang latihan */
.quiz-mode { background: #FBEEF4; }
.quiz-mode .app-shell { display: block; }
.quiz-mode .sidebar { display: none; }
.quiz-mode .main { width: min(1180px, 100%); padding: 26px 32px 54px; }
.quiz-topbar, .result-topbar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 20px; }
.quiz-topbar { margin-bottom: 18px; }
.icon-btn { display: grid; place-items: center; width: 42px; height: 42px; border: 1px solid var(--line); border-radius: 13px; background: #fff; font-size: 1.7rem; cursor: pointer; }
.quiz-identity { display: flex; align-items: center; justify-content: center; gap: 11px; }
.brand-mark.small { width: 38px; height: 38px; border-radius: 12px; font-size: 1.25rem; }
.quiz-identity strong, .quiz-identity span { display: block; }
.quiz-identity strong { font: 800 1rem "Plus Jakarta Sans", sans-serif; }
.quiz-identity span { margin-top: 2px; color: var(--muted); font-size: .76rem; }
.timer { justify-self: end; display: flex; align-items: center; gap: 8px; min-width: 102px; padding: 10px 13px; border-radius: 13px; color: #4A1F38; background: #fff; box-shadow: 0 8px 25px rgba(120,10,60,.06); }
.timer span { color: #8A7280; font-size: 1.15rem; }
.timer strong { font: 800 .98rem "Plus Jakarta Sans", sans-serif; font-variant-numeric: tabular-nums; }
.timer.urgent { color: #a52f23; background: #fff0ee; }
.quiz-progress { height: 5px; overflow: hidden; border-radius: 999px; background: #F5DCE8; }
.quiz-progress span { display: block; height: 100%; border-radius: inherit; background: var(--lime); transition: width .25s ease; }
.quiz-layout { display: grid; grid-template-columns: minmax(0, 1fr) 285px; align-items: start; gap: 22px; margin-top: 28px; }
.question-card, .quiz-panel { border: 1px solid var(--line); border-radius: 22px; background: #fff; box-shadow: 0 14px 42px rgba(120,10,60,.06); }
.question-card { min-height: 620px; padding: 38px; }
.question-meta { display: flex; justify-content: space-between; gap: 15px; color: #8A7280; font-size: .76rem; font-weight: 800; letter-spacing: .08em; }
.question-meta span:first-child { color: #5d4bc7; }
.question-card h1 { max-width: 780px; margin: 27px 0 29px; font-size: clamp(1.35rem, 2.2vw, 1.85rem); line-height: 1.45; white-space: pre-line; }
.question-card h1:focus { outline: none; }
.answer-list { display: grid; gap: 12px; }
.answer-option { display: grid; grid-template-columns: 42px minmax(0,1fr) 26px; align-items: center; gap: 14px; min-height: 64px; padding: 10px 16px; border: 1.5px solid #F2D9E6; border-radius: 15px; text-align: left; background: #fff; cursor: pointer; transition: border-color .16s, background .16s, transform .16s; }
.answer-option:hover { transform: translateX(3px); border-color: #D68AAE; }
.answer-option > span { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 11px; color: #8A4468; background: #FBEEF4; font: 800 .86rem "Plus Jakarta Sans", sans-serif; }
.answer-option > b { font-weight: 600; line-height: 1.45; }
.answer-option > i { display: none; place-items: center; width: 24px; height: 24px; border-radius: 50%; color: var(--navy); background: var(--lime); font-style: normal; font-size: .78rem; font-weight: 900; }
.answer-option.selected { border-color: var(--navy); background: #fff5e0; box-shadow: inset 4px 0 var(--lime); }
.answer-option.selected > span { color: var(--navy); background: var(--lime); }
.answer-option.selected > i { display: grid; }
.question-actions { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 30px; padding-top: 24px; border-top: 1px solid var(--line); }
.question-actions > div { display: flex; gap: 9px; }
.hint-btn { padding: 8px 0; border: 0; color: #526582; background: none; font-weight: 700; cursor: pointer; }
.hint-btn span { color: #7a64e2; }
.quiz-panel { position: sticky; top: 24px; padding: 25px; }
.panel-heading { display: flex; justify-content: space-between; gap: 12px; }
.flag-btn { width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 11px; color: #7d8ca2; background: #fff; font-size: 1.1rem; cursor: pointer; }
.flag-btn.active { color: #9b6500; border-color: #ffcf63; background: #fff7dc; }
.question-map { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin: 22px 0 17px; }
.map-number { position: relative; aspect-ratio: 1; border: 1px solid #F2D9E6; border-radius: 10px; color: #8A7280; background: #fff; font-size: .78rem; font-weight: 800; cursor: pointer; }
.map-number.answered { color: var(--navy); border-color: #ffcf63; background: #fff7dc; }
.map-number.current { color: #fff; border-color: var(--navy); background: var(--navy); box-shadow: 0 5px 13px rgba(120,10,60,.18); }
.map-number.flagged::after { content: ""; position: absolute; top: 4px; right: 4px; width: 5px; height: 5px; border-radius: 50%; background: #f1a71a; }
.map-legend { display: flex; flex-wrap: wrap; gap: 8px 12px; color: var(--muted); font-size: .67rem; }
.map-legend span { display: flex; align-items: center; gap: 5px; }
.legend { width: 8px; height: 8px; border-radius: 3px; background: #F2D9E6; }
.legend.answered { background: var(--lime); }
.legend.current { background: var(--navy); }
.legend.flagged { border-radius: 50%; background: #f1a71a; }
.answered-summary { display: flex; align-items: end; justify-content: space-between; margin: 24px 0 11px; color: var(--muted); font-size: .8rem; }
.answered-summary strong { color: var(--ink); font: 800 1.05rem "Plus Jakarta Sans", sans-serif; }
.finish-btn { width: 100%; min-height: 48px; border: 0; border-radius: 13px; color: #fff; background: var(--navy); font-weight: 800; cursor: pointer; }

/* Dialog dan notifikasi */
.app-dialog { width: min(460px, calc(100% - 30px)); padding: 0; border: 0; border-radius: 22px; color: var(--ink); box-shadow: 0 35px 90px rgba(120,10,60,.28); }
.app-dialog::backdrop { background: rgba(5,17,35,.62); backdrop-filter: blur(5px); }
.app-dialog form { position: relative; padding: 32px; }
.dialog-close { position: absolute; top: 16px; right: 16px; width: 34px; height: 34px; border: 0; border-radius: 10px; color: #8A7280; background: #FBEEF4; font-size: 1.3rem; cursor: pointer; }
.dialog-symbol { display: grid; place-items: center; width: 54px; height: 54px; margin-bottom: 18px; border-radius: 17px; color: var(--navy); background: var(--lime); font-size: 1.45rem; font-weight: 900; }
.dialog-symbol.hint { color: #fff; background: var(--violet); }
.app-dialog h2 { margin-bottom: 10px; }
.app-dialog p { color: var(--muted); line-height: 1.6; }
.dialog-actions { display: grid; grid-template-columns: 1fr 1.15fr; gap: 10px; margin-top: 25px; }
.profile-head { display: flex; align-items: center; gap: 14px; margin-bottom: 23px; }
.avatar.large { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 17px; }
.profile-head h2, .profile-head p { margin-bottom: 0; }
.profile-head p { margin-top: 3px; font-size: .84rem; }
.license-card { display: grid; gap: 4px; padding: 19px; border-radius: 17px; color: #fff; background: var(--navy); }
.license-card span { color: var(--lime); font-size: .67rem; font-weight: 800; letter-spacing: .13em; }
.license-card strong { font: 800 1.25rem "Plus Jakarta Sans", sans-serif; }
.license-card small { color: #F0C2DC; }
.profile-stat { display: flex; justify-content: space-between; margin: 21px 0; padding-bottom: 17px; border-bottom: 1px solid var(--line); color: var(--muted); }
.profile-stat b { color: var(--ink); }
.guide-list { display: grid; gap: 11px; margin: 20px 0 25px; padding-left: 22px; color: #8A7280; line-height: 1.5; }
.toast { position: fixed; z-index: 200; left: 50%; bottom: 28px; transform: translate(-50%, 130px); max-width: min(440px, calc(100% - 30px)); padding: 13px 18px; border-radius: 13px; color: #fff; background: var(--navy); box-shadow: 0 20px 50px rgba(120,10,60,.25); opacity: 0; transition: .25s ease; }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
.toast.error { background: #9d3429; }

.subscription-banner { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; padding: 13px 16px; border-radius: 13px; border: 1px solid #ffcf63; background: #fff7e0; color: #6b4f10; font-size: .85rem; line-height: 1.5; }
.subscription-banner span:first-child { font-size: 1.1rem; }
.subscription-banner.urgent { border-color: #f3b3ab; background: #ffebe8; color: #a33e32; }

/* Hasil */
.result-mode .app-shell { display: block; }
.result-mode .sidebar { display: none; }
.result-mode .main { width: min(1000px, 100%); padding: 26px 32px 70px; }
.result-topbar { display: flex; justify-content: space-between; margin-bottom: 28px; }
.result-topbar .brand { color: var(--ink); }
.result-hero { position: relative; overflow: hidden; padding: 45px 38px 35px; border-radius: 25px; text-align: center; color: #fff; background: var(--navy); }
.result-hero::before, .result-hero::after { content: ""; position: absolute; width: 250px; height: 250px; border: 1px solid rgba(255,216,77,.12); border-radius: 50%; }
.result-hero::before { top: -160px; left: -60px; box-shadow: 0 0 0 42px rgba(255,216,77,.025); }
.result-hero::after { right: -85px; bottom: -180px; box-shadow: 0 0 0 42px rgba(84,216,237,.025); }
.result-hero > * { position: relative; z-index: 1; }
.medal { display: grid; justify-items: center; gap: 7px; margin-bottom: 20px; }
.medal > span { display: grid; place-items: center; width: 62px; height: 62px; border-radius: 19px; color: var(--navy); background: var(--lime); font-size: 1.65rem; }
.medal small { color: #afbdd2; font-weight: 700; }
.medal.silver > span { background: #dfe8f2; }
.medal.bronze > span { background: #eab08a; }
.medal.practice > span { background: var(--cyan); }
.result-hero .section-kicker { color: #F0C2DC; }
.result-hero h1 { font-size: clamp(1.6rem, 3.5vw, 2.5rem); }
.result-subtitle { margin: 8px 0 18px; color: #F0C2DC; }
.big-score { display: flex; align-items: end; justify-content: center; }
.big-score strong { font: 800 clamp(3.7rem, 8vw, 5.4rem)/.95 "Plus Jakarta Sans", sans-serif; }
.big-score span { margin-bottom: 8px; color: #91a4c1; font-weight: 700; }
.result-metrics { display: grid; grid-template-columns: repeat(3, 1fr); width: min(500px, 100%); margin: 30px auto 0; padding-top: 23px; border-top: 1px solid rgba(255,255,255,.1); }
.result-metrics > div { display: grid; grid-template-columns: auto auto; justify-content: center; align-items: center; gap: 2px 7px; }
.result-metrics i { grid-row: 1 / span 2; width: 8px; height: 8px; border-radius: 50%; }
.result-metrics i.green { background: var(--lime); }
.result-metrics i.red { background: var(--coral); }
.result-metrics i.blue { background: var(--cyan); }
.result-metrics span { color: #E3A8C4; font-size: .7rem; }
.result-metrics strong { text-align: left; }
.result-analysis { display: flex; align-items: center; justify-content: space-between; gap: 25px; margin-top: 20px; padding: 25px 28px; border: 1px solid var(--line); border-radius: 20px; background: #fff; }
.result-analysis h2 { font-size: 1.25rem; }
.result-analysis p:last-child { max-width: 590px; margin: 7px 0 0; color: var(--muted); line-height: 1.5; }
.result-actions { display: flex; flex: 0 0 auto; gap: 9px; }
.review-section, .history-section { margin-top: 34px; }
.review-count { padding: 7px 10px; border-radius: 9px; color: #21664c; background: #e2f7ed; font-size: .8rem; font-weight: 800; }
.review-list { display: grid; gap: 10px; }
.review-item { overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.review-item summary { display: grid; grid-template-columns: 38px minmax(0,1fr) auto; align-items: center; gap: 12px; padding: 17px 19px; cursor: pointer; list-style: none; }
.review-item summary::-webkit-details-marker { display: none; }
.review-status { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 11px; color: #277255; background: #e5f8ef; font-weight: 900; }
.review-item.wrong .review-status { color: #a03c31; background: #ffebe8; }
.review-item summary small, .review-item summary strong { display: block; }
.review-item summary small { margin-bottom: 4px; color: #8A7280; font-size: .66rem; font-weight: 800; letter-spacing: .05em; }
.review-item summary strong { overflow: hidden; font-size: .9rem; font-weight: 700; white-space: nowrap; text-overflow: ellipsis; }
.review-item summary > b { color: #277255; }
.review-item.wrong summary > b { color: #a03c31; }
.review-body { padding: 3px 69px 24px; border-top: 1px solid var(--line); }
.review-question { margin: 20px 0; color: var(--ink); line-height: 1.6; white-space: pre-line; }
.answer-comparison { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.answer-comparison > div { display: grid; gap: 5px; padding: 14px; border-radius: 12px; background: #FBEEF4; }
.answer-comparison span { color: var(--muted); font-size: .72rem; }
.answer-comparison strong { font-size: .86rem; }
.answer-comparison .correct-answer { background: #eff9e0; }
.explanation { display: flex; gap: 11px; margin-top: 13px; padding: 15px; border-radius: 12px; background: #eef8fb; }
.explanation > span { color: #347e8d; }
.explanation b { font-size: .82rem; }
.explanation p { margin: 4px 0 0; color: #8A7280; line-height: 1.55; white-space: pre-line; }
.history-header { padding: 34px; border-radius: 24px; color: #fff; background: var(--navy); }
.history-header .section-kicker { color: var(--lime); }
.history-header p:last-of-type { margin: 8px 0 25px; color: #F0C2DC; }
.history-overview { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.history-overview > div { display: grid; gap: 4px; padding: 16px; border: 1px solid rgba(255,255,255,.1); border-radius: 14px; background: rgba(255,255,255,.05); }
.history-overview span { color: #E3A8C4; font-size: .72rem; }
.history-overview strong { font: 800 1.45rem "Plus Jakarta Sans", sans-serif; }
.history-list { display: grid; gap: 10px; }
.history-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 19px; border: 1px solid var(--line); border-radius: 15px; background: #fff; }
.history-subject { display: flex; align-items: center; gap: 12px; }
.history-subject > span { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 12px; background: #FBEEF4; font-weight: 800; }
.history-subject strong, .history-subject small, .history-score span, .history-score strong { display: block; }
.history-subject small { margin-top: 3px; color: var(--muted); }
.history-score { display: flex; align-items: center; gap: 14px; }
.history-score span { color: var(--muted); font-size: .75rem; }
.history-score strong { font: 800 1.45rem "Plus Jakarta Sans", sans-serif; }
.empty-state { padding: 65px 25px; text-align: center; }
.empty-state > span { font-size: 2rem; }
.empty-state p { color: var(--muted); }

@media (max-width: 1020px) {
  .app-shell { grid-template-columns: 90px minmax(0,1fr); }
  .sidebar { padding-inline: 16px; }
  .brand > span:last-child, .nav-item:not(.active) { font-size: 0; }
  .brand { justify-content: center; }
  .nav-item { justify-content: center; padding-inline: 0; font-size: 0; }
  .nav-item > span { font-size: 1.2rem; }
  .mini-target { display: none; }
  .subject-grid { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .complete { grid-column: span 2; }
  .day-track { overflow-x: auto; grid-template-columns: repeat(10, 74px); }
}

@media (max-width: 760px) {
  .app-shell { display: block; }
  .sidebar { display: none; }
  .main { padding: 22px 18px 96px; }
  .topbar { margin-bottom: 20px; }
  .streak span:last-child { display: none; }
  .dashboard-grid { grid-template-columns: 1fr; }
  .focus-card { grid-template-columns: 1fr; min-height: auto; padding: 25px; }
  .focus-score { display: none; }
  .stats-card { padding: 24px; }
  .day-track { margin-inline: -18px; border-radius: 0; border-left: 0; border-right: 0; padding-inline: 18px; }
  .subject-grid { grid-template-columns: 1fr; }
  .complete { grid-column: span 1; }
  .mobile-nav { position: fixed; z-index: 10; left: 12px; right: 12px; bottom: 12px; display: grid; grid-template-columns: repeat(4, 1fr); padding: 8px; border: 1px solid rgba(255,255,255,.12); border-radius: 18px; color: #F0C2DC; background: rgba(120,10,60,.96); box-shadow: 0 15px 35px rgba(120,10,60,.25); backdrop-filter: blur(12px); }
  .mobile-nav button { display: grid; justify-items: center; gap: 3px; padding: 5px; border: 0; color: inherit; background: none; font-size: .67rem; cursor: pointer; }
  .mobile-nav button span { font-size: 1.05rem; }
  .mobile-nav button.active { color: var(--lime); }
}

@media (max-width: 430px) {
  .top-actions { gap: 8px; }
  .avatar { width: 40px; height: 40px; }
  .focus-meta { gap: 7px; }
  .stats-grid > div { padding-inline: 5px; }
}

@media (max-width: 900px) {
  .quiz-layout { grid-template-columns: 1fr; }
  .quiz-panel { position: static; }
  .question-map { grid-template-columns: repeat(8, 1fr); }
  .result-analysis { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 760px) {
  .quiz-mode .main, .result-mode .main { padding: 18px 16px 38px; }
  .quiz-topbar { grid-template-columns: auto 1fr auto; }
  .quiz-identity { justify-content: flex-start; }
  .quiz-identity .brand-mark { display: none; }
  .question-card { min-height: 0; padding: 24px 19px; }
  .question-card h1 { margin-block: 22px; font-size: 1.25rem; }
  .question-actions { align-items: stretch; flex-direction: column-reverse; }
  .question-actions > div { display: grid; grid-template-columns: 1fr 1fr; }
  .question-actions .primary-btn { justify-content: center; }
  .hint-btn { min-height: 42px; text-align: left; }
  .quiz-panel { padding: 21px; }
  .question-map { grid-template-columns: repeat(5, 1fr); }
  .result-topbar .brand > span:last-child { display: inline; }
  .result-topbar .secondary-btn { font-size: .8rem; }
  .result-hero { padding: 35px 20px 28px; }
  .result-analysis { padding: 22px; }
  .result-actions { width: 100%; display: grid; grid-template-columns: 1fr 1fr; }
  .review-body { padding: 3px 18px 20px; }
  .answer-comparison { grid-template-columns: 1fr; }
  .history-overview { grid-template-columns: 1fr 1fr; }
  .history-overview > div:last-child { grid-column: span 2; }
}

@media (max-width: 480px) {
  .timer { min-width: 86px; padding-inline: 10px; }
  .quiz-identity strong { max-width: 135px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .answer-option { grid-template-columns: 38px minmax(0,1fr) 22px; padding-inline: 12px; }
  .answer-option > span { width: 34px; height: 34px; }
  .question-actions > div, .dialog-actions, .result-actions { grid-template-columns: 1fr; }
  .result-metrics span { display: none; }
  .history-row { align-items: flex-start; }
  .history-score { align-items: flex-end; flex-direction: column-reverse; gap: 2px; }
}

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