/* Domain colours */
:root, [data-theme="ocean"], [data-theme="sage"], [data-theme="apricot"], [data-theme="lavender"], [data-theme="sepia"] {
  --d1: #2a66c4; --d2: #0b7f75; --d3: #6d4fcb; --d4: #0779a8; --d5: #c2551d; --d6: #b5356d; --d7: #347f33; --d8: #8f6a05;
  color-scheme: light;
}
[data-theme="midnight"], [data-theme="forest"], [data-theme="plum"], [data-theme="graphite"] {
  --d1: #7fb0ff; --d2: #4fd1c0; --d3: #b6a1ff; --d4: #5cc8f2; --d5: #ffa671; --d6: #ff8fbe; --d7: #8bdc85; --d8: #eec95a;
  color-scheme: dark;
}
.d1 { --d: var(--d1); } .d2 { --d: var(--d2); } .d3 { --d: var(--d3); } .d4 { --d: var(--d4); }
.d5 { --d: var(--d5); } .d6 { --d: var(--d6); } .d7 { --d: var(--d7); } .d8 { --d: var(--d8); }

/* Themes */
:root, [data-theme="ocean"] {
  --bg: #f1f5fb; --surface: #ffffff; --surface-2: #f6f8fc; --line: #dce4ef; --text: #1b2a3f; --text-2: #4f6077; --text-3: #667689;
  --primary: #2160bf; --on-primary: #ffffff; --primary-soft: #e5effc; --side: #ffffff; --bar: #173f7a; --on-bar: #ffffff;
  --hl: #fff3b8; --hl-text: #3e3200; --trap: #ffeee3; --trap-text: #6d3413;
  --right: #11704c; --right-soft: #e1f5ec; --wrong: #bd3535; --wrong-soft: #fdeaea;
  --radius: 14px; --shadow: 0 1px 2px rgba(23,50,90,.06), 0 4px 14px rgba(23,50,90,.05);
}
[data-theme="paper"] {
  --d1: #141414; --d2: #141414; --d3: #141414; --d4: #141414; --d5: #141414; --d6: #141414; --d7: #141414; --d8: #141414;
  --bg: #ffffff; --surface: #ffffff; --surface-2: #f4f4f2; --line: #d8d8d4; --text: #141414; --text-2: #55565a; --text-3: #6b6c70;
  --primary: #141414; --on-primary: #ffffff; --primary-soft: #efefec; --side: #ffffff; --bar: #222222; --on-bar: #ffffff;
  --hl: #f0f0ec; --hl-text: #141414; --trap: #f7f7f5; --trap-text: #3e3f42;
  --right: #17693f; --right-soft: #edf6f0; --wrong: #a8201a; --wrong-soft: #fbefed;
  --radius: 2px; --shadow: none; color-scheme: light;
}
[data-theme="sage"] {
  --bg: #eff5f0; --surface: #ffffff; --surface-2: #f5f9f6; --line: #d7e4da; --text: #1d3026; --text-2: #4b6355; --text-3: #5f7568;
  --primary: #2a7350; --on-primary: #ffffff; --primary-soft: #e0f0e6; --side: #ffffff; --bar: #1f5239; --on-bar: #ffffff;
  --hl: #fbf3bd; --hl-text: #3b3200; --trap: #fdeee2; --trap-text: #6a3514;
  --right: #146c47; --right-soft: #dff3e8; --wrong: #b93838; --wrong-soft: #fceaea;
  --radius: 14px; --shadow: 0 1px 2px rgba(30,70,50,.06), 0 4px 14px rgba(30,70,50,.05);
}
[data-theme="apricot"] {
  --bg: #fdf4ec; --surface: #fffdfb; --surface-2: #fef8f2; --line: #f0e0d1; --text: #38261a; --text-2: #6c5242; --text-3: #7f6655;
  --d5: #a3460f; --primary: #a8440f; --on-primary: #ffffff; --primary-soft: #fde6d6; --side: #fffdfb; --bar: #7f3510; --on-bar: #ffffff;
  --hl: #fff0ae; --hl-text: #413300; --trap: #fde5de; --trap-text: #70301f;
  --right: #1b6f4a; --right-soft: #e2f4ea; --wrong: #b73030; --wrong-soft: #fde8e6;
  --radius: 16px; --shadow: 0 1px 2px rgba(120,70,30,.07), 0 4px 14px rgba(120,70,30,.05);
}
[data-theme="lavender"] {
  --bg: #f4f2fc; --surface: #ffffff; --surface-2: #f8f6fe; --line: #e2ddf4; --text: #2a2545; --text-2: #5b5578; --text-3: #6f698b;
  --primary: #5d43b8; --on-primary: #ffffff; --primary-soft: #ebe6fb; --side: #ffffff; --bar: #3e2d84; --on-bar: #ffffff;
  --hl: #fff2bb; --hl-text: #3e3200; --trap: #fdeaf0; --trap-text: #70294a;
  --right: #14704c; --right-soft: #e1f5ec; --wrong: #b9344a; --wrong-soft: #fdeaee;
  --radius: 16px; --shadow: 0 1px 2px rgba(60,40,130,.06), 0 4px 14px rgba(60,40,130,.05);
}
[data-theme="sepia"] {
  --bg: #f4ecd9; --surface: #fbf6e9; --surface-2: #f6efdf; --line: #e2d6bb; --text: #33291a; --text-2: #5f5240; --text-3: #6f6250;
  --d5: #a3460f; --primary: #79521f; --on-primary: #fffaf0; --primary-soft: #efe2c6; --side: #fbf6e9; --bar: #553a17; --on-bar: #fffaf0;
  --hl: #f8e89c; --hl-text: #3a2e00; --trap: #f5dfcb; --trap-text: #65321a;
  --right: #24663f; --right-soft: #e0ecd3; --wrong: #a5322a; --wrong-soft: #f6dfd6;
  --radius: 10px; --shadow: 0 1px 2px rgba(90,65,25,.08);
}
[data-theme="midnight"] {
  --bg: #111a28; --surface: #1a2536; --surface-2: #212f43; --line: #2e3e55; --text: #e7eef8; --text-2: #aebccf; --text-3: #94a4b9;
  --primary: #79aefc; --on-primary: #0d1b30; --primary-soft: #223a5c; --side: #151f2f; --bar: #0d1522; --on-bar: #e7eef8;
  --hl: #4a4016; --hl-text: #ffeeb0; --trap: #472f22; --trap-text: #ffd9c2;
  --right: #5fd8ab; --right-soft: #173b30; --wrong: #ff9a90; --wrong-soft: #472729;
  --radius: 14px; --shadow: 0 1px 3px rgba(0,0,0,.28);
}
[data-theme="forest"] {
  --bg: #111c17; --surface: #19281f; --surface-2: #203329; --line: #2e4537; --text: #e6f2ea; --text-2: #abc2b3; --text-3: #92aa9b;
  --primary: #6fd6a1; --on-primary: #0b2117; --primary-soft: #21442f; --side: #14211a; --bar: #0c1611; --on-bar: #e6f2ea;
  --hl: #484116; --hl-text: #fbedb0; --trap: #453124; --trap-text: #fbd9c3;
  --right: #6fe0ae; --right-soft: #17402d; --wrong: #ff9d92; --wrong-soft: #47292a;
  --radius: 14px; --shadow: 0 1px 3px rgba(0,0,0,.28);
}
[data-theme="plum"] {
  --bg: #1b1426; --surface: #261c35; --surface-2: #2f2442; --line: #413357; --text: #f1eaf8; --text-2: #c0b2d0; --text-3: #a99aba;
  --primary: #c9a4ff; --on-primary: #21113a; --primary-soft: #3e2c5e; --side: #20182d; --bar: #150f1e; --on-bar: #f1eaf8;
  --hl: #4c4118; --hl-text: #ffeeb2; --trap: #4d2c3c; --trap-text: #ffd5e4;
  --right: #66dcae; --right-soft: #1b4034; --wrong: #ff9eab; --wrong-soft: #4c2835;
  --radius: 16px; --shadow: 0 1px 3px rgba(0,0,0,.3);
}
[data-theme="graphite"] {
  --bg: #161718; --surface: #212224; --surface-2: #2a2b2e; --line: #3a3c40; --text: #ececec; --text-2: #b8b9bc; --text-3: #9e9fa3;
  --primary: #f0b849; --on-primary: #261a02; --primary-soft: #40351d; --side: #1b1c1e; --bar: #101112; --on-bar: #ececec;
  --hl: #4b4117; --hl-text: #ffeeb0; --trap: #472f23; --trap-text: #ffd9c4;
  --right: #63d8a8; --right-soft: #193b2f; --wrong: #ff9a90; --wrong-soft: #472828;
  --radius: 10px; --shadow: 0 1px 3px rgba(0,0,0,.32);
}

:root { --sans: "Noto Sans Sinhala", "Iskoola Pota", "Sinhala Sangam MN", "Avenir Next", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; --mono: ui-monospace, "SF Mono", Menlo, monospace; --d: var(--primary); }
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { background: var(--bg); color: var(--text); font: 400 16px/1.6 var(--sans); -webkit-font-smoothing: antialiased; }
h1, h2, h3, p, dl, dd, ul { margin: 0; padding: 0; }
ul { list-style: none; }
button, input, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; padding: 0; cursor: pointer; text-align: left; }
a { color: inherit; }
svg.icon { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.quiet { color: var(--text-2); } .faint { color: var(--text-3); } .small { font-size: 14px; } .num { font-variant-numeric: tabular-nums; }
.label { font-size: 12px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--text-2); }
.pass { color: var(--right); font-weight: 600; } .fail { color: var(--wrong); font-weight: 600; }

/* App frame */
.app-shell { display: grid; grid-template-columns: 236px minmax(0, 1fr); min-height: 100vh; }
.side { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 26px; padding: 22px 14px; background: var(--side); border-right: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 8px; font-size: 18px; font-weight: 700; text-decoration: none; }
.brand-badge { display: grid; place-items: center; width: 34px; height: 34px; border-radius: min(var(--radius), 10px); background: var(--primary); color: var(--on-primary); }
.side-nav { display: grid; gap: 4px; }
.nav-item { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border-radius: min(var(--radius), 10px); color: var(--text-2); font-weight: 500; text-decoration: none; transition: background .12s, color .12s; }
.nav-item:hover { background: var(--surface-2); color: var(--text); }
.nav-item.on { background: var(--primary-soft); color: var(--primary); font-weight: 600; }
.side-foot { margin-top: auto; padding: 12px 8px 0; border-top: 1px solid var(--line); display: grid; gap: 4px; }
.side-user { font-weight: 600; font-size: 14.5px; overflow-wrap: anywhere; }
.signout { display: inline-flex; align-items: center; gap: 8px; color: var(--text-2); font-size: 14px; }
.signout:hover { color: var(--text); }
.signout svg.icon { width: 16px; height: 16px; }
.mobile-top { display: none; }
main { padding: 34px 0 72px; }
.page { width: min(1080px, 100%); margin: 0 auto; padding: 0 32px; }
.column { width: min(800px, 100%); margin: 0 auto; padding: 0 28px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface); color: var(--text); font-size: 15px; font-weight: 600; text-decoration: none; text-align: center; transition: background .12s, border-color .12s, filter .12s; }
.btn:hover { border-color: var(--primary); background: var(--primary-soft); }
.btn.solid { border-color: var(--primary); background: var(--primary); color: var(--on-primary); }
.btn.solid:hover { background: var(--primary); filter: brightness(.92); }
.btn:disabled, .btn.solid:disabled { border-color: var(--line); background: var(--surface-2); color: var(--text-3); cursor: not-allowed; filter: none; }
.text-btn { font-size: 14px; font-weight: 600; color: var(--primary); text-decoration: none; }
.text-btn:hover { text-decoration: underline; text-underline-offset: 3px; }
.row-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* Sign in */
.auth { min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr; }
.auth-side { background: var(--bar); color: var(--on-bar); padding: 44px 52px; display: flex; flex-direction: column; justify-content: space-between; gap: 44px; }
.auth-side .brand { padding: 0; }
.auth-side h1 { font-size: clamp(36px, 4.6vw, 58px); line-height: 1.08; font-weight: 600; letter-spacing: -.02em; max-width: 10em; }
.auth-facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; padding-top: 18px; border-top: 1px solid color-mix(in srgb, var(--on-bar) 25%, transparent); }
.auth-facts b { display: block; font-size: 25px; font-weight: 600; }
.auth-facts span { font-size: 13.5px; opacity: .82; }
.auth-main { display: flex; align-items: center; justify-content: center; padding: 44px 28px; background: var(--surface); }
.auth-form { width: min(370px, 100%); }
.auth-form h2 { font-size: 28px; font-weight: 600; margin-bottom: 24px; }
.field { display: block; margin-bottom: 16px; }
.field span { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
input[type=text], input[type=password], textarea { width: 100%; min-height: 46px; padding: 10px 13px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); }
input:focus, textarea:focus { outline: 2px solid var(--primary); outline-offset: -1px; border-color: var(--primary); }
input::placeholder { color: var(--text-3); }
.form-error { color: var(--wrong); font-size: 14px; min-height: 22px; margin-bottom: 6px; }
.auth-form .btn { width: 100%; }
.auth-switch { margin-top: 16px; font-size: 14px; color: var(--text-2); }

/* Overview */
.greet { margin-bottom: 20px; }
.greet h1, .exam-title { font-size: clamp(27px, 3.4vw, 36px); line-height: 1.15; font-weight: 600; letter-spacing: -.015em; margin-bottom: 4px; }
.lead-row { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(250px, 1fr); gap: 16px; }
.card, .lead, .goal, .stat, .dom-card, .plan, .q-card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.lead { padding: 24px 26px; border-left: 5px solid var(--d); background: color-mix(in srgb, var(--d) 7%, var(--surface)); }
.lead .label { color: var(--d); }
.lead h2 { font-size: clamp(23px, 2.7vw, 30px); line-height: 1.2; font-weight: 600; letter-spacing: -.012em; margin: 5px 0 5px; }
.lead .row-actions { margin-top: 20px; }
.goal { padding: 22px 24px; display: flex; flex-direction: column; justify-content: center; }
.goal b { font-size: 31px; font-weight: 600; line-height: 1.2; font-variant-numeric: tabular-nums; }
.goal b span { font-size: 17px; color: var(--text-2); font-weight: 500; }
.meter { height: 7px; border-radius: 9px; overflow: hidden; background: color-mix(in srgb, var(--d) 15%, var(--surface-2)); }
.meter i { display: block; height: 100%; border-radius: 9px; background: var(--d); transition: width .3s; }
.goal .meter { margin: 8px 0 9px; --d: var(--primary); }
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 16px; }
.stat { padding: 15px 18px; }
.stat b { display: block; font-size: 26px; line-height: 1.2; font-weight: 600; font-variant-numeric: tabular-nums; }
.section { margin-top: 34px; }
.section-head { display: flex; justify-content: space-between; align-items: baseline; gap: 14px; margin-bottom: 12px; flex-wrap: wrap; }
.section-head h2 { font-size: 20px; font-weight: 600; }
.dom-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 14px; }
.dom-card { display: flex; flex-direction: column; gap: 12px; padding: 17px 18px; text-decoration: none; transition: transform .12s, border-color .12s; }
.dom-card:hover { transform: translateY(-2px); border-color: var(--d); }
.dom-top { display: flex; gap: 12px; align-items: flex-start; }
.dom-badge { display: grid; place-items: center; width: 36px; height: 36px; flex: none; border-radius: min(var(--radius), 10px); background: color-mix(in srgb, var(--d) 15%, var(--surface)); color: var(--d); font-weight: 700; }
.dom-name { display: block; font-weight: 600; line-height: 1.28; }
.dom-foot { display: flex; justify-content: space-between; gap: 10px; font-size: 13.5px; color: var(--text-2); }
.dom-foot b { color: var(--wrong); font-weight: 600; }
.plan { display: grid; grid-template-columns: 1fr auto; gap: 18px; align-items: center; padding: 18px 20px; }
.plan p { white-space: pre-line; max-width: 64ch; }
.two-up { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; }
.line-link { display: flex; justify-content: space-between; gap: 14px; padding: 10px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: min(var(--radius), 10px); text-decoration: none; }
.line-link:hover { border-color: var(--primary); }
.table { width: 100%; border-collapse: separate; border-spacing: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.table th { text-align: left; font-size: 12px; font-weight: 600; letter-spacing: .05em; text-transform: uppercase; color: var(--text-2); padding: 10px 14px; background: var(--surface-2); border-bottom: 1px solid var(--line); }
.table td { padding: 11px 14px; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.table tr:last-child td { border-bottom: 0; }
.table tr.link { cursor: pointer; }
.table tr.link:hover td { background: var(--primary-soft); }

/* Practice */
.q-top { display: flex; justify-content: space-between; align-items: center; gap: 14px; }
.q-top h1 { font-size: 21px; font-weight: 600; line-height: 1.3; }
.q-score { display: flex; align-items: center; gap: 12px; flex: none; }
.dots { display: flex; gap: 4px; }
.dots i { width: 9px; height: 9px; border-radius: 50%; }
.dots i.ok { background: var(--right); } .dots i.no { background: var(--wrong); }
.tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 12px 0 16px; }
.tabs a, .tabs button { padding: 5px 13px; border-radius: 99px; font-size: 14px; font-weight: 500; color: var(--text-2); text-decoration: none; border: 1px solid transparent; }
.tabs a:hover, .tabs button:hover { color: var(--text); background: var(--surface); border-color: var(--line); }
.tabs a.on, .tabs button.on { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.q-card { padding: 24px 28px 26px; border-top: 4px solid var(--d); }
.q-meta { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.q-meta .label { color: var(--d); }
.scenario { padding: 14px 17px; margin-bottom: 18px; border-radius: min(var(--radius), 10px); background: var(--surface-2); font-size: 15.5px; }
.stem { font-size: 19.5px; line-height: 1.5; font-weight: 500; white-space: pre-line; margin-bottom: 20px; }
.picture { display: block; max-width: 100%; max-height: 440px; margin: 12px auto 20px; padding: 6px; border: 1px solid var(--line); border-radius: min(var(--radius), 8px); background: #fff; }
.options { display: grid; gap: 9px; }
.opt { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 11px; align-items: start; width: 100%; padding: 11px 14px 11px 11px; background: var(--surface); border: 1.5px solid var(--line); border-radius: min(var(--radius), 12px); transition: background .1s, border-color .1s; }
.opt:hover:not(:disabled) { border-color: var(--primary); background: var(--primary-soft); }
.opt:disabled { cursor: default; color: var(--text); }
.opt-k { display: grid; place-items: center; width: 30px; height: 30px; border-radius: min(var(--radius), 8px); background: var(--surface-2); font-size: 14px; font-weight: 700; }
.opt-text { align-self: center; }
.opt-tag { font-size: 12.5px; font-weight: 600; align-self: center; white-space: nowrap; }
.opt.sel { border-color: var(--primary); background: var(--primary-soft); }
.opt.sel .opt-k { background: var(--primary); color: var(--on-primary); }
.opt.is-right { border-color: var(--right); background: var(--right-soft); }
.opt.is-right .opt-k { background: var(--right); color: var(--surface); }
.opt.is-right .opt-tag { color: var(--right); }
.opt.is-wrong { border-color: var(--wrong); background: var(--wrong-soft); }
.opt.is-wrong .opt-k { background: var(--wrong); color: var(--surface); }
.opt.is-wrong .opt-tag { color: var(--wrong); }
.q-actions { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 18px; flex-wrap: wrap; }
.hint { font-size: 13px; color: var(--text-3); }
.outcome { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--line); animation: settle .18s ease-out; }
.verdict { font-size: 21px; font-weight: 600; margin-bottom: 12px; }
.good .verdict { color: var(--right); } .bad .verdict { color: var(--wrong); }
.memo { display: grid; gap: 9px; }
.memo-rule, .memo-trap { padding: 12px 15px; border-radius: min(var(--radius), 10px); }
.memo-rule { background: var(--hl); color: var(--hl-text); }
.memo-trap { background: var(--trap); color: var(--trap-text); }
.memo .label { color: inherit; opacity: .82; }
.memo .rule { font-size: 18px; line-height: 1.38; font-weight: 600; }
.memo .trap { font-size: 15.5px; }
details { margin-top: 12px; border-top: 1px solid var(--line); }
summary { padding: 10px 0; cursor: pointer; font-size: 14.5px; font-weight: 600; }
details p { padding-bottom: 10px; font-size: 15.5px; color: var(--text-2); white-space: pre-line; }
.tutor { border-top: 1px solid var(--line); padding-top: 12px; }
.tutor-links { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 4px 0 11px; }
.ask { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.tutor-reply { margin-top: 12px; padding: 12px 15px; border-radius: min(var(--radius), 10px); background: var(--primary-soft); white-space: pre-line; font-size: 15.5px; }
.tutor-reply:empty { display: none; }
@keyframes settle { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }

/* Notes */
.note-domain { margin-top: 24px; }
.note-domain h3 { font-size: 17px; font-weight: 600; color: var(--d); margin-bottom: 8px; }
.note-item { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 16px; padding: 12px 15px; margin-bottom: 8px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--d); border-radius: min(var(--radius), 10px); }
.note-item .rule { font-weight: 600; line-height: 1.4; }
.note-item .trap { color: var(--text-2); font-size: 14.5px; margin-top: 2px; }
.note-topic { font-size: 13.5px; color: var(--text-2); }
.note-topic b { color: var(--wrong); font-weight: 600; }

/* Themes */
.theme-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 14px; margin-top: 18px; }
.theme-card { display: block; width: 100%; padding: 10px; background: var(--surface); color: var(--text); border: 2px solid var(--line); border-radius: 14px; transition: transform .12s; }
.theme-card:hover { transform: translateY(-2px); }
.theme-card.on { border-color: var(--primary); box-shadow: 0 0 0 2px var(--primary); }
.mini { display: grid; grid-template-columns: 26px 1fr; height: 92px; overflow: hidden; background: var(--bg); border: 1px solid var(--line); border-radius: 8px; }
.mini-side { background: var(--side); border-right: 1px solid var(--line); padding: 7px 6px; display: grid; align-content: start; gap: 4px; }
.mini-side i { display: block; height: 4px; border-radius: 2px; background: var(--line); }
.mini-side i:first-child { background: var(--primary); height: 9px; }
.mini-main { padding: 8px; display: grid; align-content: start; gap: 5px; }
.mini-line { height: 5px; width: 80%; border-radius: 3px; background: var(--text); }
.mini-opt { height: 13px; border: 1px solid var(--line); border-radius: 3px; background: var(--surface); }
.mini-opt.right { background: var(--right-soft); border-color: var(--right); }
.mini-btn { width: 40%; height: 11px; border-radius: 3px; background: var(--primary); }
.theme-name { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; margin-top: 8px; font-weight: 600; }
.theme-name span { font-size: 12.5px; font-weight: 500; color: var(--text-2); }

/* Mock exam and results */
.spec { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 22px 0; }
.spec div { padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.spec b { display: block; font-size: 25px; line-height: 1.2; font-weight: 600; font-variant-numeric: tabular-nums; }
.rules { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 4px 18px; }
.rules li { display: grid; grid-template-columns: 30px 1fr; padding: 10px 0; border-bottom: 1px solid var(--line); }
.rules li:last-child { border-bottom: 0; }
.result-top { padding: 26px 28px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.score { font-size: clamp(64px, 10vw, 96px); line-height: 1; font-weight: 600; letter-spacing: -.03em; font-variant-numeric: tabular-nums; margin: 8px 0; }
.review-item { padding: 22px 24px; margin-top: 14px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }

/* Exam room */
.room { min-height: 100vh; display: flex; flex-direction: column; background: var(--surface); }
.room-bar { position: sticky; top: 0; z-index: 5; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; min-height: 52px; padding: 0 24px; background: var(--bar); color: var(--on-bar); font-size: 14.5px; font-weight: 500; }
.room-time { justify-self: end; font: 600 19px/1 var(--mono); padding: 6px 10px; border-radius: 6px; }
.room-time.low { background: #c22f2f; color: #fff; }
.room-body { flex: 1; width: min(860px, 100%); margin: 0 auto; padding: 32px 28px 112px; }
.room .stem { font-size: 19px; }
.room .opt { cursor: pointer; }
.room .opt.struck .opt-text { color: var(--text-3); text-decoration: line-through; }
.strike { font-size: 12.5px; color: var(--text-3); padding: 2px 6px; align-self: center; }
.strike:hover { color: var(--text); text-decoration: underline; }
.room-foot { position: fixed; left: 0; right: 0; bottom: 0; z-index: 5; display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 24px; background: var(--surface); border-top: 1px solid var(--line); }
.pad { position: fixed; right: 24px; bottom: 76px; z-index: 6; width: min(330px, calc(100vw - 48px)); padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 8px 26px rgba(0,0,0,.2); }
.pad textarea { height: 180px; margin-top: 8px; resize: vertical; }
.overlay { position: fixed; inset: 0; z-index: 50; display: grid; place-items: center; padding: 20px; background: rgba(15,22,34,.55); }
.dialog { width: min(430px, 100%); padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.dialog h2 { font-size: 20px; font-weight: 600; margin-bottom: 5px; }
.dialog p { color: var(--text-2); }
.dialog .row-actions { justify-content: flex-end; margin-top: 20px; }
.blank { padding: 48px 20px; text-align: center; color: var(--text-2); }
.blank h2 { color: var(--text); font-size: 23px; font-weight: 600; margin-bottom: 5px; }
.blank .row-actions { justify-content: center; margin-top: 18px; }

.pin-input { margin-top: 14px; text-align: center; font: 700 22px var(--mono) !important; letter-spacing: .25em; }
.dialog .form-error { margin-top: 8px; }
/* Matching questions */
.match-options { display: grid; gap: 7px; padding: 14px 15px; margin-bottom: 18px; background: var(--surface-2); border-radius: min(var(--radius), 11px); }
.match-option { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 10px; align-items: start; font-size: 15px; line-height: 1.42; }
.match-option .opt-k { width: 26px; height: 26px; background: var(--primary-soft); color: var(--primary); font-size: 13px; }
.match-label { display: block; margin-bottom: 8px; }
.match-rows { display: grid; gap: 9px; }
.match-row { display: grid; grid-template-columns: 32px minmax(0, 1fr) auto; gap: 11px; align-items: center; padding: 11px 12px; background: var(--surface); border: 1.5px solid var(--line); border-radius: min(var(--radius), 12px); transition: border-color .1s, background .1s; }
.match-row.active { border-color: var(--primary); background: color-mix(in srgb, var(--primary-soft) 45%, var(--surface)); }
.match-main { min-width: 0; display: grid; gap: 1px; }
.match-main > b { font-weight: 600; }
.match-chosen { font-size: 13.5px; line-height: 1.4; color: var(--text-2); }
.match-chosen.empty { color: var(--text-3); }
.match-yours { color: var(--wrong); }
.match-picks { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 5px; }
.match-pick { display: grid; place-items: center; width: 36px; height: 36px; text-align: center; font-size: 14px; font-weight: 700; background: var(--surface-2); border: 1.5px solid var(--line); border-radius: min(var(--radius), 8px); transition: background .1s, border-color .1s; }
.match-pick:hover:not(:disabled) { border-color: var(--primary); background: var(--primary-soft); }
.match-pick.on { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.match-pick:disabled { cursor: default; opacity: .45; }
.match-pick.truth:disabled { opacity: 1; background: var(--right); border-color: var(--right); color: var(--surface); }
.match-pick.miss:disabled { opacity: 1; background: var(--wrong); border-color: var(--wrong); color: var(--surface); }
.match-row.is-right { border-color: var(--right); background: var(--right-soft); }
.match-row.is-right .match-chosen { color: var(--right); }
.match-row.is-right .opt-k { background: var(--right); color: var(--surface); }
.match-row.is-wrong { border-color: var(--wrong); background: var(--wrong-soft); }
.match-row.is-wrong .match-chosen, .match-row.is-wrong .match-chosen b { color: var(--right); }
.match-row.is-wrong .opt-k { background: var(--wrong); color: var(--surface); }
@media (max-width: 620px) {
  .match-row { grid-template-columns: 32px minmax(0, 1fr); }
  .match-picks { grid-column: 1 / -1; justify-content: flex-start; }
  .match-pick { width: 40px; height: 40px; }
}

/* Practice progress map */
.side { overflow-y: auto; gap: 18px; }
.pmap { display: grid; gap: 8px; padding: 11px; background: var(--surface-2); border: 1px solid var(--line); border-radius: min(var(--radius), 10px); }
.pmap-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; font-size: 13px; }
.pmap .meter { height: 4px; --d: var(--right); }
.pmap-grid { display: grid; grid-template-columns: repeat(auto-fill, 8px); gap: 2px; justify-content: space-between; max-height: max(112px, calc(100vh - 720px)); padding: 2px; overflow-y: auto; scrollbar-width: thin; position: relative; }
.pm { display: block; width: 8px; height: 8px; padding: 0; border: 0; border-radius: min(var(--radius), 2px); background: color-mix(in srgb, var(--text-3) 18%, var(--surface)); }
button.pm { cursor: pointer; transition: transform .08s; }
button.pm:hover { transform: scale(1.45); position: relative; z-index: 1; }
.pm.l1 { background: color-mix(in srgb, var(--right) 60%, var(--surface)); }
.pm.l2 { background: color-mix(in srgb, var(--right) 70%, var(--surface)); }
.pm.l3 { background: color-mix(in srgb, var(--right) 80%, var(--surface)); }
.pm.l4 { background: color-mix(in srgb, var(--right) 90%, var(--surface)); }
.pm.l5 { background: var(--right); }
.pm.no { background: var(--wrong); }
.pm.cur { outline: 1.5px solid var(--primary); outline-offset: 1px; position: relative; z-index: 2; }
.pmap-key { display: grid; gap: 2px; font-size: 12.5px; color: var(--text-2); }
.pmap-key span { display: grid; grid-template-columns: 8px 1fr auto; gap: 7px; align-items: center; }
.pmap-key b { color: var(--text); font-weight: 600; }
.pmap-mobile { display: none; margin: 0 0 12px; border: 0; }
.pmap-mobile summary { padding: 8px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: min(var(--radius), 10px); }
.pmap-mobile[open] summary { border-radius: min(var(--radius), 10px) min(var(--radius), 10px) 0 0; }
.pmap-inline { border-top: 0; border-radius: 0 0 min(var(--radius), 10px) min(var(--radius), 10px); }
.pmap-inline .pmap-grid { grid-template-columns: repeat(auto-fill, 10px); gap: 3px; max-height: 190px; }
.pmap-inline .pm { width: 10px; height: 10px; }
.pmap-inline .pmap-key { grid-template-columns: repeat(3, auto); justify-content: space-between; }
@media (max-width: 820px) {
  .side { overflow: visible; }
  .side > .pmap { display: none; }
  .pmap-mobile { display: block; }
}

/* Mock exam results */
.result-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.result-stats .stat b { font-size: 30px; }
.good-stat b { color: var(--right); } .bad-stat b { color: var(--wrong); }
.summary-note { margin-top: 10px; }
.weak-list { display: grid; gap: 8px; }
.weak-row { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: min(var(--radius), 12px); }
.weak-row.is-weak { border-color: color-mix(in srgb, var(--wrong) 45%, var(--line)); background: color-mix(in srgb, var(--wrong-soft) 55%, var(--surface)); }
.weak-row.is-weak .meter { --d: var(--wrong); }
.weak-main { display: grid; gap: 5px; min-width: 0; }
.weak-title { display: flex; justify-content: space-between; gap: 10px; }
.weak-title b { font-weight: 600; }
.weak-title .num { flex: none; color: var(--text-2); font-size: 14px; }
.weak-topics { margin-top: 16px; }
.topic-chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 7px; }
.topic-chip { display: inline-flex; align-items: center; gap: 8px; padding: 5px 7px 5px 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 99px; font-size: 14px; text-decoration: none; }
a.topic-chip:hover { border-color: var(--primary); color: var(--primary); }
.topic-chip b { padding: 1px 7px; border-radius: 99px; background: var(--wrong-soft); color: var(--wrong); font-size: 12.5px; }
.study-plan { display: grid; gap: 9px; margin: 0; padding: 16px 18px 16px 38px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.study-plan li { padding-left: 4px; line-height: 1.5; }
.cheat-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.cheat { display: grid; gap: 5px; align-content: start; padding: 13px 15px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--d); border-radius: min(var(--radius), 10px); break-inside: avoid; }
.cheat .label { color: var(--d); }
.cheat .rule { font-weight: 600; line-height: 1.4; }
.cheat .trap { color: var(--text-2); font-size: 14.5px; }
@media (max-width: 720px) {
  .result-stats { grid-template-columns: 1fr 1fr; }
  .cheat-grid { grid-template-columns: 1fr; }
  .weak-row { grid-template-columns: 32px minmax(0, 1fr); }
  .weak-row .btn { grid-column: 2; justify-self: start; }
}
@media print {
  .side, .mobile-top, .site-head, .site-foot, .no-print { display: none !important; }
  .app-shell { display: block; }
  body { background: #fff; }
  body.printing-cheats .no-cheat-print { display: none !important; }
  body.printing-cheats .cheat-section { margin-top: 0; }
  .cheat-grid { grid-template-columns: 1fr 1fr; }
}

/* ExamSupport site */
[hidden] { display: none !important; }
.site { min-height: 100vh; display: flex; flex-direction: column; }
.site-main { flex: 1; padding: 0; }
.site-inner { width: min(1180px, 100%); margin: 0 auto; padding: 0 28px; }
.site-head { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--side) 92%, transparent); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
.site-head .site-inner { display: flex; align-items: center; gap: 28px; min-height: 68px; }
.site-head .brand { padding: 0; font-size: 20px; letter-spacing: -.01em; }
.site-nav { display: flex; gap: 6px; margin-right: auto; }
.site-nav a { padding: 7px 13px; border-radius: 9px; color: var(--text-2); font-weight: 500; text-decoration: none; }
.site-nav a:hover { color: var(--text); background: var(--surface-2); }
.site-nav a.on { color: var(--primary); background: var(--primary-soft); font-weight: 600; }
.site-tools { display: flex; align-items: center; gap: 16px; }
.cart-link { position: relative; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; color: var(--text-2); }
.cart-link:hover { background: var(--surface-2); color: var(--text); }
.cart-count { position: absolute; top: 1px; right: 0; min-width: 18px; height: 18px; padding: 0 4px; display: grid; place-items: center; border-radius: 9px; background: var(--primary); color: var(--on-primary); font-size: 11px; font-weight: 700; }
.account-link { display: flex; align-items: center; gap: 8px; font-weight: 600; text-decoration: none; }
.avatar { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--primary-soft); color: var(--primary); font-weight: 700; }
.btn-sm { min-height: 38px; padding: 0 16px; font-size: 14px; }
.btn-lg { min-height: 50px; padding: 0 26px; font-size: 16px; }
.btn-block { width: 100%; }
.center { text-align: center; }
.hero { background: linear-gradient(180deg, var(--primary-soft), var(--bg)); }
.hero-inner { display: grid; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr); gap: 56px; align-items: center; padding-top: 72px; padding-bottom: 76px; }
.eyebrow { display: inline-block; margin-bottom: 16px; color: var(--primary); font-size: 14px; font-weight: 700; }
.hero h1 { font-size: clamp(40px, 5.6vw, 68px); line-height: 1.04; font-weight: 700; letter-spacing: -.03em; margin-bottom: 20px; }
.hero h1 em { font-style: normal; color: var(--primary); }
.hero-sub { max-width: 34em; color: var(--text-2); font-size: 18.5px; line-height: 1.55; margin-bottom: 26px; }
.hero-preview { display: grid; gap: 13px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 6px); box-shadow: 0 2px 4px rgba(20,40,70,.05), 0 24px 54px rgba(20,40,70,.14); }
.preview-top { display: flex; justify-content: space-between; align-items: center; }
.preview-q { font-size: 18.5px; font-weight: 600; line-height: 1.38; }
.hero-preview .memo-rule { padding: 11px 14px; border-radius: min(var(--radius), 10px); background: var(--hl); color: var(--hl-text); }
.hero-preview .memo-rule .label { color: inherit; }
.hero-preview .rule { font-weight: 600; }
.strip { background: var(--surface); border-block: 1px solid var(--line); }
.strip-inner { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; padding-top: 22px; padding-bottom: 22px; }
.strip b { display: block; font-size: 28px; font-weight: 700; line-height: 1.2; letter-spacing: -.01em; }
.strip span { color: var(--text-2); font-size: 14.5px; }
.band { padding: 66px 0; }
.band-alt { background: var(--surface); border-block: 1px solid var(--line); }
.band-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; flex-wrap: wrap; margin-bottom: 26px; }
.band-head h2, .band-head h1 { font-size: clamp(27px, 3.3vw, 38px); line-height: 1.15; font-weight: 700; letter-spacing: -.02em; }
.exam-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 18px; }
.exam-card { display: flex; flex-direction: column; gap: 12px; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 2px); box-shadow: var(--shadow); text-decoration: none; transition: transform .14s, border-color .14s, box-shadow .14s; }
.exam-card:hover { transform: translateY(-3px); border-color: var(--primary); box-shadow: 0 12px 30px rgba(20,40,70,.12); }
.exam-card-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.exam-code { display: inline-block; padding: 4px 11px; border-radius: 8px; background: var(--primary); color: var(--on-primary); font-size: 13.5px; font-weight: 700; letter-spacing: .03em; }
.exam-tag { display: inline-block; padding: 3px 10px; border-radius: 99px; background: var(--surface-2); color: var(--text-2); font-size: 13px; font-weight: 500; }
.exam-card h3 { font-size: 20px; line-height: 1.26; font-weight: 700; }
.exam-facts { display: grid; gap: 6px; color: var(--text-2); font-size: 14.5px; }
.exam-facts li { display: flex; align-items: center; gap: 8px; }
.exam-facts svg.icon { width: 17px; height: 17px; color: var(--primary); }
.exam-card-foot { display: flex; justify-content: space-between; align-items: center; margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line); }
.exam-card-foot b { font-size: 22px; }
.exam-card.owned .exam-card-foot { border-top: 0; padding-top: 2px; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.step-n { display: grid; place-items: center; width: 40px; height: 40px; margin-bottom: 13px; border-radius: 50%; background: var(--primary); color: var(--on-primary); font-weight: 700; }
.step h3, .feature h3 { font-size: 19px; font-weight: 700; margin-bottom: 5px; }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature { padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.feature-icon { display: grid; place-items: center; width: 42px; height: 42px; margin-bottom: 13px; border-radius: min(var(--radius), 11px); background: var(--primary-soft); color: var(--primary); }
.cta { background: var(--bar); color: var(--on-bar); }
.cta-inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; padding-top: 48px; padding-bottom: 48px; }
.cta h2 { font-size: clamp(26px, 3.2vw, 36px); font-weight: 700; letter-spacing: -.02em; }
.cta p { opacity: .85; }
.cta-btn, .cta-btn:hover { background: var(--on-bar); color: var(--bar); border-color: var(--on-bar); }
.site-foot { background: var(--side); border-top: 1px solid var(--line); padding: 30px 0; }
.foot-inner { display: grid; grid-template-columns: 1fr auto; gap: 14px 28px; }
.foot-inner .brand { padding: 0; margin-bottom: 4px; }
.foot-links { display: flex; gap: 18px; }
.foot-links a { color: var(--text-2); text-decoration: none; font-size: 14.5px; }
.foot-links a:hover { color: var(--primary); }
.foot-legal { grid-column: 1 / -1; padding-top: 12px; border-top: 1px solid var(--line); }
.page-pad { padding-top: 42px; padding-bottom: 72px; }
.narrow-page { width: min(1000px, 100%); }
.page-h1 { font-size: clamp(29px, 3.6vw, 40px); font-weight: 700; letter-spacing: -.02em; margin-bottom: 18px; }
.page-sub { margin: -12px 0 22px; }
.detail { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 44px; align-items: start; }
.detail h1 { font-size: clamp(30px, 4vw, 46px); line-height: 1.12; font-weight: 700; letter-spacing: -.025em; margin-bottom: 12px; }
.detail-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 16px 0 13px; }
.detail-h2 { font-size: 22px; font-weight: 700; margin-bottom: 12px; }
.buy-card { position: sticky; top: 92px; display: grid; gap: 14px; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 2px); box-shadow: 0 10px 34px rgba(20,40,70,.1); }
.price { font-size: 40px; line-height: 1.1; font-weight: 700; letter-spacing: -.02em; }
.check-list { display: grid; gap: 8px; font-size: 15px; }
.check-list li { display: flex; gap: 9px; }
.check-list svg.icon { width: 18px; height: 18px; margin-top: 3px; color: var(--right); }
.domain-list { display: grid; gap: 7px; }
.domain-line { display: grid; grid-template-columns: 36px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; background: var(--surface); border: 1px solid var(--line); border-radius: min(var(--radius), 11px); }
.domain-text { display: grid; gap: 4px; font-weight: 500; }
.domain-text .meter { display: block; height: 5px; }
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 22px; align-items: start; }
.cart-lines { display: grid; gap: 12px; }
.cart-line { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 15px; align-items: start; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.summary { display: grid; gap: 12px; padding: 22px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.summary h2 { font-size: 20px; font-weight: 700; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; color: var(--text-2); }
.sum-row.total { padding-top: 12px; border-top: 1px solid var(--line); color: var(--text); font-size: 20px; font-weight: 700; }
.test-banner { padding: 14px 17px; margin-bottom: 12px; background: var(--hl); color: var(--hl-text); border-radius: min(var(--radius), 11px); }
.billing { display: grid; gap: 1px; padding: 18px 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.done-card { max-width: 520px; margin: 26px auto; padding: 36px 30px; text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 2px); box-shadow: var(--shadow); }
.done-card h1 { font-size: 30px; font-weight: 700; }
.done-card .row-actions { justify-content: center; margin-top: 18px; }
.done-icon { display: grid; place-items: center; width: 58px; height: 58px; margin: 0 auto 13px; border-radius: 50%; background: var(--right-soft); color: var(--right); }
.done-icon svg.icon { width: 28px; height: 28px; }
.account-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; align-items: start; }
.form-card { padding: 24px; }
.form-card h2 { font-size: 20px; font-weight: 700; margin-bottom: 14px; }
input:disabled { opacity: .72; cursor: not-allowed; }
input[type=email], input[type=tel] { width: 100%; min-height: 46px; padding: 10px 13px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); }
.field .hint, .strength .hint { display: block; margin-top: 4px; font-size: 12.5px; font-weight: 400; color: var(--text-3); }
.auth-side h1 { margin-bottom: 12px; }
.auth-lede { font-size: 18px; opacity: .88; }
.auth-points { display: grid; gap: 10px; }
.auth-points li { display: flex; align-items: center; gap: 10px; }
.auth-side .brand-badge { background: var(--on-bar); color: var(--bar); }
.auth-side .brand { color: var(--on-bar); font-size: 20px; }
.auth-form { width: min(420px, 100%); }
.auth-back { display: inline-block; margin-bottom: 18px; }
.auth-form h2 { margin-bottom: 5px; }
.auth-sub { margin-bottom: 20px; }
.auth-main { align-items: flex-start; padding-top: 52px; }
.stepper { list-style: none; display: flex; gap: 10px; margin: 0 0 22px; padding: 0; font-size: 13.5px; color: var(--text-3); }
.stepper li { flex: 1; display: flex; align-items: center; gap: 6px; padding-bottom: 7px; border-bottom: 3px solid var(--line); font-weight: 600; }
.stepper li span { display: grid; place-items: center; width: 21px; height: 21px; border-radius: 50%; background: var(--surface-2); font-size: 12px; }
.stepper li.now { color: var(--primary); border-color: var(--primary); }
.stepper li.now span { background: var(--primary); color: var(--on-primary); }
.stepper li.done { color: var(--right); border-color: var(--right); }
.stepper li.done span { background: var(--right); color: var(--surface); }
.otp-row { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; margin-bottom: 8px; }
input.otp-box { width: 100%; min-height: 58px; padding: 0; text-align: center; font: 700 25px var(--mono); border: 1.5px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); }
.resend-row { text-align: center; margin: 12px 0; }
.resend { font-size: 14.5px; font-weight: 600; color: var(--primary); font-variant-numeric: tabular-nums; }
.resend:disabled { color: var(--text-3); cursor: default; }
.resend:not(:disabled):hover { text-decoration: underline; }
.spam-note { display: grid; grid-template-columns: 20px 1fr; gap: 10px; padding: 12px 14px; margin-bottom: 12px; background: var(--hl); color: var(--hl-text); border-radius: min(var(--radius), 10px); font-size: 14px; line-height: 1.45; }
.spam-note svg.icon { margin-top: 1px; }
.change-email { display: block; margin: 0 auto; }
.form-row { display: flex; justify-content: flex-end; margin: -6px 0 8px; }
.form-two { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 62px; }
.pw-toggle { position: absolute; right: 11px; top: 50%; transform: translateY(-50%); color: var(--primary); font-size: 13.5px; font-weight: 600; }
.strength { margin: -8px 0 14px; }
.strength-bar { height: 5px; border-radius: 4px; overflow: hidden; background: var(--surface-2); }
.strength-bar i { display: block; height: 100%; width: 0; background: var(--wrong); transition: width .15s; }
.strength-bar i[data-level="mid"] { background: var(--d8); }
.strength-bar i[data-level="high"] { background: var(--right); }
.check-field { display: flex; gap: 9px; align-items: flex-start; margin: 2px 0 10px; font-size: 14px; color: var(--text-2); }
.check-field input { margin-top: 4px; accent-color: var(--primary); }
.verified-email { display: flex; align-items: center; gap: 8px; padding: 9px 13px; margin-bottom: 15px; background: var(--right-soft); color: var(--right); border-radius: min(var(--radius), 10px); font-size: 14.5px; font-weight: 600; overflow-wrap: anywhere; }
.toast { position: fixed; left: 50%; bottom: 26px; z-index: 80; transform: translateX(-50%); max-width: calc(100vw - 32px); padding: 11px 18px; background: var(--text); color: var(--bg); border-radius: 10px; font-weight: 500; box-shadow: 0 10px 30px rgba(0,0,0,.25); animation: settle .18s ease-out; }
.side-exam { display: grid; gap: 1px; padding: 10px 12px; background: var(--surface-2); border-radius: min(var(--radius), 10px); }
.side-exam b { font-size: 17px; }
.side-foot a.signout { text-decoration: none; overflow-wrap: anywhere; }
.side-foot { gap: 8px; }

@media (max-width: 1000px) {
  .hero-inner { grid-template-columns: 1fr; gap: 34px; padding-top: 44px; padding-bottom: 48px; }
  .features { grid-template-columns: 1fr 1fr; }
  .detail, .cart-layout { grid-template-columns: 1fr; }
  .buy-card { position: static; }
}
@media (max-width: 720px) {
  .site-inner { padding: 0 16px; }
  .site-head .site-inner { flex-wrap: wrap; gap: 4px 10px; min-height: 0; padding-top: 9px; padding-bottom: 7px; }
  .site-head .brand { margin-right: auto; font-size: 18px; }
  .site-nav { order: 3; width: 100%; margin: 0; }
  .site-nav a, .site-nav .site-nav-action { padding: 5px 11px; font-size: 14px; }
  .site-tools { gap: 8px; }
  .hide-small { display: none !important; }
  .strip-inner { grid-template-columns: 1fr 1fr; }
  .band { padding: 42px 0; }
  .steps, .features, .account-grid, .form-two { grid-template-columns: 1fr; }
  .form-two { gap: 0; }
  .exam-grid { grid-template-columns: 1fr; }
  .foot-inner { grid-template-columns: 1fr; }
  .cart-line { grid-template-columns: minmax(0, 1fr) auto; }
  .cart-line .exam-code { grid-column: 1 / -1; justify-self: start; }
  .auth-side h1 { font-size: 32px; }
  .auth-points { display: none; }
  .auth-main { padding-top: 26px; }
  input.otp-box { min-height: 50px; font-size: 21px; }
  .otp-row { gap: 6px; }
  .page-pad { padding-top: 26px; }
}

@media (max-width: 960px) {
  .lead-row { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .app-shell { display: block; padding-bottom: 66px; }
  .side { position: fixed; z-index: 20; left: 0; right: 0; top: auto; bottom: 0; height: auto; padding: 5px 6px; border-right: 0; border-top: 1px solid var(--line); }
  .side > .brand, .side-foot, .side-exam { display: none; }
  .side-nav { grid-auto-flow: column; grid-auto-columns: 1fr; gap: 2px; }
  .nav-item { flex-direction: column; gap: 1px; padding: 5px 2px; font-size: 11.5px; text-align: center; }
  .mobile-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 16px; background: var(--side); border-bottom: 1px solid var(--line); }
  .mobile-top .brand { padding: 0; font-size: 17px; }
  .mobile-top .brand-badge { width: 30px; height: 30px; }
  main { padding: 20px 0 34px; }
  .page, .column { padding: 0 16px; }
  .auth { grid-template-columns: 1fr; min-height: 0; }
  .auth-side { padding: 24px 18px; gap: 24px; }
  .auth-main { padding: 28px 18px 40px; }
  .q-card { padding: 18px 16px 20px; }
  .stem { font-size: 18px; }
  .two-up, .note-item { grid-template-columns: 1fr; }
  .note-item { gap: 2px; }
  .spec { grid-template-columns: 1fr 1fr; }
  .plan { grid-template-columns: 1fr; }
  .dom-grid { grid-template-columns: 1fr; }
  .theme-grid { grid-template-columns: 1fr 1fr; gap: 10px; }
  .hide-small { display: none; }
  .room-bar { grid-template-columns: auto 1fr auto; padding: 0 14px; gap: 10px; }
  .room-title { display: none; }
  .room-body { padding: 22px 16px 100px; }
  .room-foot { padding: 9px 14px; }
  .room-foot .btn { padding: 0 14px; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

.q-actions > .btn.solid { margin-left: auto; }

.exhibit { margin: -6px 0 20px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); overflow: hidden; background: var(--surface-2); }
.exhibit .label { display: block; padding: 7px 13px; border-bottom: 1px solid var(--line); background: var(--surface); }
.exhibit pre { margin: 0; padding: 12px 14px; overflow-x: auto; font: 13px/1.5 var(--mono); color: var(--text); white-space: pre; tab-size: 4; }

/* Labs */
.lab-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; margin-top: 18px; }
.lab-card { display: flex; flex-direction: column; gap: 8px; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); text-decoration: none; transition: transform .12s, border-color .12s; }
.lab-card:hover { transform: translateY(-2px); border-color: var(--primary); }
.lab-card h3 { font-size: 18px; font-weight: 600; line-height: 1.3; }
.lab-card-top, .lab-card-foot { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.lab-card-foot { margin-top: auto; padding-top: 8px; border-top: 1px solid var(--line); }
.lab-status { padding: 2px 9px; border-radius: 99px; background: var(--surface-2); color: var(--text-2); font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.lab-status.pass { background: var(--right-soft); color: var(--right); }
.lab-status.started { background: var(--primary-soft); color: var(--primary); }
.lab-page { padding-bottom: 30px; }
.lab-head { margin: 10px 0 16px; }
.lab-head h1 { font-size: clamp(25px, 3vw, 32px); font-weight: 600; letter-spacing: -.012em; margin: 4px 0; }
.lab-banner { padding: 12px 16px; margin-bottom: 14px; background: var(--right-soft); color: var(--right); border: 1px solid var(--right); border-radius: min(var(--radius), 10px); font-weight: 600; }
.lab-layout { display: grid; grid-template-columns: minmax(300px, 0.9fr) minmax(0, 1.25fr); gap: 16px; align-items: start; }
.lab-side { display: grid; gap: 14px; }
.lab-topo { padding: 6px; }
.topo { display: block; width: 100%; height: auto; }
.topo-link { stroke: var(--text-3); stroke-width: 2; }
.topo-tagbg { fill: var(--surface); stroke: var(--line); }
.topo-tag { fill: var(--text-2); font: 600 11px var(--sans); text-anchor: middle; }
.topo-node { fill: var(--surface-2); stroke: var(--text-3); stroke-width: 2; }
.topo-node.mine { fill: var(--primary-soft); stroke: var(--primary); stroke-width: 2.5; }
.topo-node.end { fill: var(--surface); stroke: var(--line); }
.topo-name { fill: var(--text); font: 700 13px var(--sans); text-anchor: middle; }
.topo-name.end { font-weight: 500; font-size: 12px; fill: var(--text-2); }
.topo-sub { fill: var(--text-3); font: 500 10.5px var(--sans); text-anchor: middle; }
.lab-task-card { padding: 16px 18px; display: grid; gap: 12px; }
.row-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; }
.row-head h2 { font-size: 18px; font-weight: 600; }
.lab-tasks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.lab-tasks li { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 10px; align-items: start; padding: 9px 10px; border-radius: min(var(--radius), 9px); background: var(--surface-2); line-height: 1.45; }
.lab-tick { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; background: var(--surface); border: 1px solid var(--line); font-size: 12.5px; font-weight: 700; }
.lab-tasks li.pass { background: var(--right-soft); } .lab-tasks li.pass .lab-tick { background: var(--right); border-color: var(--right); color: var(--surface); }
.lab-tasks li.fail { background: var(--wrong-soft); } .lab-tasks li.fail .lab-tick { background: var(--wrong); border-color: var(--wrong); color: var(--surface); }
.lab-solution { padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); display: grid; gap: 8px; }
.lab-solution pre { margin: 4px 0 0; padding: 10px 12px; background: var(--surface-2); border-radius: 8px; font: 13px/1.5 var(--mono); overflow-x: auto; }
.terminal { display: flex; flex-direction: column; min-height: 520px; background: #0d1117; border: 1px solid #222a35; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.term-tabs { display: flex; flex-wrap: wrap; gap: 4px; padding: 8px 10px; background: #161b22; border-bottom: 1px solid #222a35; }
.term-tabs button, .term-locked { padding: 5px 12px; border-radius: 7px; font: 600 13px var(--mono); color: #9aa7b8; }
.term-tabs button:hover { color: #e6edf3; background: #222a35; }
.term-tabs button.on { background: #2f81f7; color: #fff; }
.term-locked { opacity: .55; cursor: not-allowed; }
.term-locked::after { content: " (locked)"; font-weight: 400; }
.term-out { flex: 1; margin: 0; padding: 12px 14px; min-height: 380px; max-height: 62vh; overflow: auto; color: #d6dee8; font: 13.5px/1.5 var(--mono); white-space: pre; cursor: text; }
.term-line { display: flex; align-items: center; gap: 4px; padding: 9px 14px 11px; border-top: 1px solid #222a35; background: #0d1117; }
.term-prompt { color: #7ee787; font: 600 13.5px var(--mono); white-space: nowrap; }
.term-in { flex: 1; min-width: 0; min-height: 0 !important; padding: 2px 0 !important; border: 0 !important; background: transparent !important; color: #e6edf3; font: 13.5px var(--mono); outline: none !important; caret-color: #7ee787; }
.term-hint { margin: 0; padding: 6px 14px 9px; background: #0d1117; color: #6e7b8b; font-size: 12px; }
@media (max-width: 980px) { .lab-layout { grid-template-columns: 1fr; } .terminal { min-height: 440px; } .term-out { min-height: 300px; max-height: 55vh; } }
.topo-key { display: flex; gap: 16px; justify-content: center; padding: 2px 0 8px; font-size: 12.5px; color: var(--text-2); }
.topo-key span { display: inline-flex; align-items: center; gap: 6px; }
.topo-key i { width: 12px; height: 12px; border-radius: 3px; background: var(--surface-2); border: 2px solid var(--text-3); }
.topo-key i.mine { background: var(--primary-soft); border-color: var(--primary); }

.preview-tabs { display: flex; gap: 4px; }
.preview-tabs button { padding: 3px 10px; border-radius: 99px; font-size: 12.5px; font-weight: 700; color: var(--text-2); background: var(--surface-2); }
.preview-tabs button.on { background: var(--primary); color: var(--on-primary); }
.preview-top { gap: 10px; flex-wrap: wrap; }
.exam-card.coming { border-style: dashed; box-shadow: none; background: color-mix(in srgb, var(--surface) 60%, var(--bg)); }
.exam-card.coming:hover { transform: none; border-color: var(--line); }
.exam-card.coming .exam-code { background: var(--surface-2); color: var(--text-2); }
.exam-card-foot .soon { font-size: 15px; color: var(--text-2); }

/* Logo */
.brand-badge svg.icon { width: 24px; height: 24px; stroke-width: 2.8; }
.wordmark { font-weight: 700; letter-spacing: -.01em; }
.wordmark span { color: var(--primary); }
.auth-side .wordmark span, .cta .wordmark span { color: inherit; opacity: .8; }

/* Admin console */
.admin-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.admin-head .page-h1 { margin: 2px 0 0; }
.admin-tabs { margin: 0; }
.admin-tabs a { text-decoration: none; }
.admin-stats { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.admin-two { display: grid; grid-template-columns: 1fr 1fr; gap: 0 20px; }
.table-wrap { overflow-x: auto; }
.table-wrap .table { min-width: 560px; }
.bars { display: grid; grid-template-columns: repeat(14, 1fr); gap: 6px; align-items: end; height: 190px; padding: 16px 16px 10px; }
.bar-col { display: grid; grid-template-rows: auto 1fr auto; height: 100%; align-items: end; text-align: center; gap: 4px; }
.bar-col i { display: block; width: 100%; min-height: 2px; border-radius: 5px 5px 2px 2px; background: var(--primary); opacity: .85; align-self: end; }
.bar-val { font-size: 11px; color: var(--text-2); font-variant-numeric: tabular-nums; }
.bar-day { font-size: 11px; color: var(--text-3); }
.chip-status { display: inline-block; padding: 2px 9px; border-radius: 99px; font-size: 12.5px; font-weight: 600; background: var(--surface-2); color: var(--text-2); white-space: nowrap; }
.chip-status.good { background: var(--right-soft); color: var(--right); }
.chip-status.bad { background: var(--wrong-soft); color: var(--wrong); }
.chip-status.info { background: var(--primary-soft); color: var(--primary); }
.chip-row { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.danger-btn { color: var(--wrong); border-color: color-mix(in srgb, var(--wrong) 45%, var(--line)); }
.danger-btn:hover { background: var(--wrong-soft); border-color: var(--wrong); }
.pin-form { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px; padding: 18px; }
.pin-fields { display: flex; flex-wrap: wrap; gap: 12px; flex: 1; }
.pin-fields .field { margin: 0; min-width: 130px; }
.pin-fields .grow { flex: 1; min-width: 220px; }
select { width: 100%; min-height: 46px; padding: 9px 12px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); color: var(--text); font: inherit; }
input[type=number] { width: 100%; min-height: 46px; padding: 10px 13px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); }
.pin-result { margin-top: 12px; padding: 16px 18px; background: var(--hl); color: var(--hl-text); border-radius: var(--radius); }
.pin-result pre { margin: 10px 0; font: 700 18px/1.7 var(--mono); letter-spacing: .08em; white-space: pre-wrap; }
.admin-user { padding: 22px; margin-top: 12px; }
.admin-user-top { display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; }
.admin-user-top h2 { font-size: 22px; font-weight: 600; }
.avatar.big { width: 56px; height: 56px; font-size: 22px; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; padding-top: 14px; border-top: 1px solid var(--line); }
.facts dt { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .05em; color: var(--text-2); }
.facts dd { margin: 2px 0 0; font-weight: 500; }
.access-list { padding: 6px 18px; }
.access-row { display: flex; justify-content: space-between; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.access-row:last-child { border-bottom: 0; }
@media (max-width: 900px) { .admin-stats { grid-template-columns: repeat(3, 1fr); } .admin-two { grid-template-columns: 1fr; } }
@media (max-width: 620px) { .admin-stats { grid-template-columns: 1fr 1fr; } .admin-user-top { grid-template-columns: auto 1fr; } .admin-user-top .btn { grid-column: 1 / -1; } .facts { grid-template-columns: 1fr; } .bars { gap: 3px; padding: 12px 8px 8px; } .bar-val { display: none; } }
.admin-two { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.admin-two .table-wrap .table { min-width: 0; }
.brand-badge svg.icon { width: 26px; height: 26px; }

/* Plans, orders, payments */
.price-tag { display: inline-flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.price-tag b { font-size: 20px; }
.plan-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.plan-card { display: grid; gap: 2px; padding: 11px 12px; text-align: left; background: var(--surface); border: 1.5px solid var(--line); border-radius: min(var(--radius), 12px); text-decoration: none; color: inherit; }
.plan-card:hover { border-color: var(--primary); }
.plan-card.on { border-color: var(--primary); background: var(--primary-soft); box-shadow: 0 0 0 1px var(--primary); }
.plan-top { display: flex; justify-content: space-between; align-items: center; gap: 6px; }
.plan-price { font-size: 20px; font-weight: 700; line-height: 1.25; }
.plan-price.small-price { font-size: 17px; color: var(--primary); }
.save { padding: 1px 7px; border-radius: 99px; background: var(--right-soft); color: var(--right); font-size: 11.5px; font-weight: 700; }
.save.wa { background: #e7f8ee; color: #128c4b; }
.wa-line { display: inline-flex; align-items: center; gap: 5px; margin-top: 3px; color: #128c4b; font-weight: 600; font-size: 13.5px; }
.wa-line svg.icon { width: 16px; height: 16px; }
.access-note { display: flex; gap: 8px; align-items: center; padding: 10px 12px; background: var(--right-soft); color: var(--right); border-radius: min(var(--radius), 10px); font-weight: 600; font-size: 14.5px; }
.access-note svg.icon { width: 18px; height: 18px; }
.plan-select { display: flex; align-items: center; gap: 8px; margin: 6px 0; }
.plan-select select { width: auto; min-height: 36px; padding: 4px 10px; }
.order-page { display: grid; gap: 14px; }
.order-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; flex-wrap: wrap; }
.order-head .page-h1 { margin: 2px 0 0; font-family: var(--mono); letter-spacing: .04em; }
.order-steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; font-size: 13.5px; color: var(--text-3); }
.order-steps li { display: flex; align-items: center; gap: 7px; padding-bottom: 8px; border-bottom: 3px solid var(--line); font-weight: 600; }
.order-steps li span { display: grid; place-items: center; flex: none; width: 22px; height: 22px; border-radius: 50%; background: var(--surface-2); font-size: 12px; }
.order-steps li.now { color: var(--primary); border-color: var(--primary); } .order-steps li.now span { background: var(--primary); color: var(--on-primary); }
.order-steps li.done { color: var(--right); border-color: var(--right); } .order-steps li.done span { background: var(--right); color: var(--surface); }
.order-items { padding: 14px 18px; display: grid; gap: 8px; }
.pay-card { padding: 20px 22px; display: grid; gap: 12px; }
.pay-card h2 { font-size: 19px; font-weight: 600; }
.ref-box { display: grid; justify-items: center; gap: 6px; padding: 16px; background: var(--primary-soft); border-radius: min(var(--radius), 12px); text-align: center; }
.ref-num { font: 700 clamp(26px, 6vw, 36px) var(--mono); letter-spacing: .12em; color: var(--primary); }
.bank-rows { display: grid; gap: 2px; }
.bank-row { display: grid; grid-template-columns: 140px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.bank-row b { overflow-wrap: anywhere; }
.copy-btn { padding: 4px 10px; border: 1px solid var(--line); border-radius: 7px; font-size: 13px; font-weight: 600; color: var(--primary); background: var(--surface); }
.copy-btn:hover { border-color: var(--primary); }
.pay-steps { margin: 0; padding-left: 20px; display: grid; gap: 5px; color: var(--text-2); }
.upload-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.upload-row input[type=file] { flex: 1; min-width: 200px; padding: 9px; border: 1.5px dashed var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); }
.order-alert { padding: 13px 16px; border-radius: min(var(--radius), 11px); background: var(--surface-2); display: grid; gap: 3px; text-decoration: none; }
.order-alert.warn { background: var(--hl); color: var(--hl-text); }
.order-alert.bad { background: var(--wrong-soft); color: var(--wrong); }
.admin-pending { display: flex; justify-content: space-between; margin-bottom: 14px; }
.good-text { color: var(--right); font-weight: 600; } .bad-text { color: var(--wrong); }
.chip-status.warn { background: var(--hl); color: var(--hl-text); }
.redeem-form { display: grid; gap: 8px; }
.redeem-row { display: flex; gap: 8px; }
.redeem-row .pin-input { margin: 0; flex: 1; }
.redeem-card { max-width: 560px; }
.lib-tabs { margin-bottom: 18px; }
.lib-tabs a { text-decoration: none; }
.access-line { display: flex; align-items: center; gap: 6px; font-size: 13.5px; color: var(--text-2); font-weight: 600; }
.access-line svg.icon { width: 16px; height: 16px; }
.exam-card.expired { opacity: .85; border-style: dashed; }
.exam-tag.trial { background: var(--hl); color: var(--hl-text); }
.pay-actions { justify-content: flex-end; margin-bottom: 12px; }
.pay-list { display: grid; gap: 12px; margin-top: 8px; }
.pay-review { padding: 18px 20px; display: grid; gap: 10px; }
.pay-review-top { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.pay-review-top .ref { font-family: var(--mono); font-size: 17px; margin-right: 8px; letter-spacing: .05em; }
.pay-review-top .amount { font-size: 21px; }
.pay-review .facts { margin-top: 0; padding-top: 0; border-top: 0; }
.settings-card { padding: 20px 22px; margin-bottom: 14px; display: grid; gap: 6px; }
.settings-card h2 { font-size: 19px; font-weight: 600; }
.settings-card textarea { min-height: 80px; }
.price-table input { min-height: 40px; padding: 6px 10px; }
.grant { display: flex; gap: 6px; align-items: center; }
.grant select { width: auto; min-height: 36px; padding: 4px 8px; }
.access-row { flex-wrap: wrap; }
@media (max-width: 720px) {
  .plan-grid { grid-template-columns: 1fr 1fr; }
  .order-steps { grid-template-columns: 1fr 1fr; }
  .bank-row { grid-template-columns: 1fr auto; }
  .bank-row .quiet { grid-column: 1 / -1; font-size: 13px; }
  .redeem-row { flex-direction: column; }
}
.plan-top { flex-wrap: wrap; align-items: flex-start; }
.plan-top b { white-space: nowrap; font-size: 15px; }
.plan-card { padding: 11px; }

/* Study guide */
.guide-tools { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; margin: 12px 0 4px; }
.guide-domain { margin-top: 26px; }
.guide-domain h3 { font-size: 18px; font-weight: 600; color: var(--d); margin-bottom: 10px; }
.guide-note { padding: 16px 18px; margin-bottom: 10px; background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--d); border-radius: min(var(--radius), 12px); }
.guide-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 12px; align-items: start; }
.guide-head h4 { font-size: 17px; font-weight: 600; line-height: 1.35; margin: 0 0 3px; }
.guide-code { padding: 3px 8px; border-radius: 7px; background: color-mix(in srgb, var(--d) 14%, var(--surface)); color: var(--d); font: 700 13px var(--mono); }
.guide-note details { margin-top: 10px; }
.guide-points { margin: 4px 0 12px; padding-left: 20px; display: grid; gap: 6px; line-height: 1.5; }
.guide-tips { margin-bottom: 12px; }
.guide-tips ul { margin: 4px 0 0; padding-left: 18px; display: grid; gap: 4px; }

/* Admin: student usage */
.usage-bars { grid-template-columns: repeat(30, 1fr); gap: 3px; }
.usage-bars .bar-val { font-size: 10px; }
.usage-exams { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 14px; }
.usage-exam { padding: 16px 18px; display: grid; gap: 10px; align-content: start; }
.usage-exam-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.usage-exam-head h3 { margin: 0; font-size: 18px; }
.usage-meter-top { display: flex; justify-content: space-between; font-size: 13.5px; margin-bottom: 4px; }
.usage-domains { display: grid; gap: 8px; margin-top: 8px; }
.usage-domain { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(60px, 1fr) auto; gap: 10px; align-items: center; }
.usage-exam details summary { cursor: pointer; font-size: 14px; font-weight: 600; }
.usage-exam { min-width: 0; grid-template-columns: minmax(0, 1fr); }
.usage-exam .table-wrap { max-width: 100%; }
.usage-exam .table-wrap .table { min-width: 0; font-size: 13.5px; }
.usage-exam .table th, .usage-exam .table td { padding-left: 8px; padding-right: 8px; }
.stat b.stat-small { font-size: 18px; }
.usage-logins { display: flex; flex-wrap: wrap; gap: 6px; padding: 14px; }
@media (max-width: 700px) { .usage-exams { grid-template-columns: 1fr; } .usage-bars .bar-val { display: none; } }

.idle-note { margin-bottom: 14px; }

/* Public site refinement */
.site-head { background: var(--side); backdrop-filter: none; }
.site-head .site-inner { min-height: 66px; }
.site-head .brand { font-size: 19px; }
.site-head .site-tools { margin-left: auto; }
.site-nav .site-nav-action { padding: 7px 13px; border-radius: 9px; color: var(--text-2); font-weight: 500; }
.site-nav .site-nav-action:hover { color: var(--text); background: var(--surface-2); }

/* Landing and catalog */
.lp { background: var(--bg); }
.lp .hero { background: var(--surface); border-bottom: 1px solid var(--line); }
.lp .hero-inner { grid-template-columns: minmax(0, 1.02fr) minmax(0, .98fr); gap: clamp(36px, 5vw, 72px); padding-top: clamp(60px, 7vw, 92px); padding-bottom: clamp(60px, 7vw, 92px); }
.lp-eyebrow, .lp-kicker, .hero-demo-label { display: block; color: var(--primary); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.lp .hero h1 { max-width: 700px; margin: 16px 0 21px; font-size: clamp(42px, 4.7vw, 64px); line-height: 1.08; letter-spacing: -.045em; font-weight: 700; }
.lp .hero h1 em { color: var(--primary); }
.lp .hero-sub { max-width: 530px; margin-bottom: 27px; font-size: 17px; line-height: 1.65; }
.lp .hero .row-actions { gap: 19px; }
.lp .hero .btn.solid { gap: 18px; min-height: 48px; padding: 0 23px; }
.hero-text-link { color: var(--primary); font-weight: 650; text-decoration: underline; text-decoration-color: color-mix(in srgb, var(--primary) 35%, transparent); text-underline-offset: 5px; }
.hero-text-link:hover { text-decoration-color: currentColor; }
.lp-trial-note { display: flex; align-items: center; gap: 8px; margin-top: 20px; color: var(--text-2); font-size: 13px; }
.lp-trial-note svg.icon { width: 16px; height: 16px; color: var(--right); }
.lp-paths { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 28px; }
.lp-paths span { padding: 4px 10px; border: 1px solid var(--line); border-radius: 6px; color: var(--text-2); font-size: 12px; font-weight: 650; }
.hero-demo { min-width: 0; align-self: center; }
.hero-demo-label { margin: 0 0 12px 4px; color: var(--text-3); font-size: 11px; }
.lp .hero-preview { padding: clamp(19px, 2.5vw, 28px); border: 1px solid var(--line); border-radius: 17px; background: var(--surface-2); box-shadow: 0 18px 45px rgba(20, 40, 70, .09); }
.lp .hero-preview .preview-q { font-size: 19px; }
.lp .hero-preview .opt { min-height: 49px; cursor: pointer; text-align: left; font: inherit; color: var(--text); background: var(--surface); }
.lp .hero-preview .opt:disabled { cursor: default; }
.lp .hero-preview .memo-rule { background: var(--hl); }
.lp .hero-preview .preview-top { gap: 12px; }
.lp .preview-tabs { flex-wrap: wrap; justify-content: flex-end; }
.lp .preview-tabs button { padding: 4px 10px; }
.lp .band { padding: clamp(58px, 6.5vw, 86px) 0; }
.lp #lp-exams, .lp #lp-benefits, .lp #lp-pricing { scroll-margin-top: 90px; }
.lp .band-head { margin-bottom: 25px; }
.lp .band-head h1, .lp .band-head h2 { margin: 7px 0 9px; font-size: clamp(30px, 3.1vw, 41px); line-height: 1.15; letter-spacing: -.035em; }
.lp .band-head p { max-width: 590px; font-size: 15.5px; }
.lp .exam-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.lp .exam-card { padding: 24px; border: 1px solid var(--line); border-radius: 15px; box-shadow: 0 4px 16px rgba(20, 40, 70, .045); }
.lp .exam-card:hover { transform: translateY(-2px); box-shadow: 0 10px 28px rgba(20, 40, 70, .1); }
.lp-card { position: relative; }
.lp-card-link { position: absolute; inset: 0; border-radius: inherit; z-index: 0; }
.lp-card > :not(.lp-card-link) { position: relative; z-index: 1; pointer-events: none; }
.lp-card .lp-card-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; pointer-events: auto; }
.lp .exam-card-top { align-items: baseline; }
.lp .exam-card h3 { margin: 0; color: var(--text); font-size: 27px; line-height: 1.1; letter-spacing: -.03em; }
.lp .exam-card .exam-tag { font-size: 12px; }
.lp-card-name { color: var(--text); font-size: 14px; font-weight: 650; line-height: 1.35; }
.lp-card-tagline { min-height: 45px; line-height: 1.5; }
.lp .exam-card .exam-facts { display: flex; flex-wrap: wrap; gap: 7px 15px; margin: 1px 0 4px; font-size: 13px; }
.lp .exam-card .exam-facts li { gap: 6px; }
.lp .exam-card .exam-facts svg.icon { width: 15px; height: 15px; }
.lp .lp-card .exam-card-foot { margin-top: auto; padding: 13px 0 0; border-top: 1px solid var(--line); }
.lp .price-tag b { font-size: 19px; }
.lp .lp-card-actions .btn.solid { min-height: 42px; padding: 0 18px; }
.lp .lp-card-actions .lp-detail-link { min-height: 42px; padding: 0; border: 0; background: transparent; color: var(--primary); }
.lp .lp-card-actions .lp-detail-link:hover { background: transparent; text-decoration: underline; }
.lp-coming { margin-top: 20px; color: var(--text-2); font-size: 13px; }
.lp .band-alt { background: var(--surface-2); }
.lp .features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.lp .feature { min-height: 180px; padding: 23px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.lp .feature-icon { width: 39px; height: 39px; margin-bottom: 16px; border-radius: 9px; }
.lp .feature h3 { font-size: 18px; }
.lp .feature p { font-size: 14px; line-height: 1.55; }
.lp-price-tabs { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 18px; }
.lp-price-tabs button { padding: 7px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text-2); font-size: 13px; }
.lp-price-tabs button.on { border-color: var(--primary); background: var(--primary); color: var(--on-primary); }
.lp-plans { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
.lp-plan { position: relative; display: flex; flex-direction: column; gap: 6px; padding: 22px 18px 18px; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.lp-plan h3 { color: var(--text-2); font-size: 15px; }
.lp-plan-price { font-size: 29px; line-height: 1.2; font-weight: 700; letter-spacing: -.03em; }
.lp-plan-price.small-price { font-size: 23px; }
.lp-plan .check-list { margin: 8px 0 16px; font-size: 13px; }
.lp-plan .btn { margin-top: auto; }
.lp-plan.featured { border-color: var(--primary); box-shadow: 0 0 0 1px var(--primary); }
.lp-plan-flag { position: absolute; top: -12px; left: 16px; padding: 3px 10px; border-radius: 6px; background: var(--primary); color: var(--on-primary); font-size: 11px; font-weight: 700; }
.lp-plan.contact { border-style: dashed; }
.wa-btn { gap: 7px; border-color: #18864a; color: #137541; }
.wa-btn:hover { border-color: #18864a; background: #e7f8ee; }
.wa-btn svg.icon, .cta-ghost svg.icon { width: 18px; height: 18px; }
.lp-steps { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; }
.lp-steps .step { padding: 21px; border: 1px solid var(--line); border-radius: 13px; background: var(--surface); }
.lp-steps .step-n { width: 31px; height: 31px; margin-bottom: 13px; font-size: 12px; }
.lp-steps .step h3 { font-size: 16px; }
.lp-steps .step p { font-size: 13px; line-height: 1.55; }
.lp-faq { max-width: 800px; }
.lp-faq-list { display: grid; gap: 8px; }
.lp-faq-item { padding: 15px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); }
.lp-faq-item summary { display: flex; justify-content: space-between; gap: 12px; cursor: pointer; font-size: 15px; font-weight: 650; list-style: none; }
.lp-faq-item summary::-webkit-details-marker { display: none; }
.lp-faq-item summary::after { content: "+"; color: var(--primary); font-size: 20px; line-height: 1; }
.lp-faq-item[open] summary::after { content: "−"; }
.lp-faq-item p { margin-top: 10px; line-height: 1.55; font-size: 14px; }
.lp .cta { background: var(--bar); }
.lp .cta-inner { padding-top: 43px; padding-bottom: 43px; }
.lp .cta .row-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.lp .cta-ghost { gap: 7px; border-color: color-mix(in srgb, var(--on-bar) 40%, transparent); background: transparent; color: var(--on-bar); }
.lp .cta-ghost:hover { border-color: var(--on-bar); background: color-mix(in srgb, var(--on-bar) 10%, transparent); color: var(--on-bar); }
.catalog-page .page-pad { padding-top: 62px; }
@media (max-width: 1000px) { .lp-plans, .lp-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 850px) { .lp .hero-inner { grid-template-columns: 1fr; gap: 38px; } .lp .hero-copy { max-width: 680px; } .lp .hero-demo { max-width: 650px; } }
@media (max-width: 720px) {
  .site-head .site-inner { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "brand tools" "nav nav"; gap: 2px 8px; min-height: 0; padding-top: 7px; padding-bottom: 5px; }
  .site-head.no-nav .site-inner { grid-template-areas: "brand tools"; padding-bottom: 7px; }
  .site-head .brand { grid-area: brand; min-width: 0; margin: 0; font-size: 17px; }
  .site-head .brand-badge { width: 29px; height: 29px; }
  .site-tools { grid-area: tools; gap: 8px; }
  .site-tools .btn-sm { min-height: 34px; padding: 0 11px; font-size: 12px; }
  .site-tools .signin-link { font-size: 12px; }
  .site-nav { grid-area: nav; order: initial; width: 100%; gap: 0; margin: 0; }
  .site-nav a, .site-nav .site-nav-action { padding: 5px 10px; font-size: 12px; }
  .lp .hero-inner { gap: 31px; padding-top: 42px; padding-bottom: 48px; }
  .lp .hero h1 { max-width: 480px; margin: 11px 0 15px; font-size: clamp(35px, 9.2vw, 48px); line-height: 1.11; }
  .lp .hero-sub { margin-bottom: 20px; font-size: 15px; line-height: 1.6; }
  .lp .hero .row-actions { gap: 15px; }
  .lp .hero .btn.solid { min-height: 44px; padding: 0 17px; font-size: 14px; }
  .lp-trial-note { margin-top: 13px; font-size: 12px; }
  .lp-paths { margin-top: 18px; }
  .lp .hero-preview { padding: 17px; box-shadow: 0 8px 24px rgba(20, 40, 70, .08); }
  .lp .hero-preview .preview-top { flex-direction: column; align-items: flex-start; gap: 9px; }
  .lp .preview-tabs { justify-content: flex-start; }
  .lp .hero-preview .preview-q { font-size: 17px; }
  .lp .band { padding: 42px 0; }
  .lp .band-head h1, .lp .band-head h2 { font-size: 28px; }
  .lp .exam-grid, .lp .features { grid-template-columns: 1fr; }
  .lp .exam-card { padding: 19px; }
  .lp-card-tagline { min-height: 0; }
  .lp .feature { min-height: 0; }
  .lp-plans, .lp-steps { grid-template-columns: 1fr; }
  .lp-steps { gap: 0; }
  .lp-steps .step { display: grid; grid-template-columns: 31px minmax(0, 1fr); column-gap: 13px; padding: 16px 0; border: 0; border-bottom: 1px solid var(--line); border-radius: 0; background: transparent; }
  .lp-steps .step:last-child { border-bottom: 0; }
  .lp-steps .step-n { grid-row: 1 / 3; margin: 0; }
  .lp-steps .step h3 { align-self: end; margin-bottom: 2px; }
  .lp-steps .step p { grid-column: 2; }
  .catalog-page .page-pad { padding-top: 35px; }
}
@media (max-width: 380px) { .site-head .brand { font-size: 15px; } .site-head .brand-badge { width: 27px; height: 27px; } .site-tools .signin-link { display: none; } }
@media (max-width: 820px) {
  .auth { background: var(--surface); }
  .auth-side { padding: 13px 18px; gap: 0; border-bottom: 1px solid var(--line); background: var(--surface); color: var(--text); }
  .auth-side > div, .auth-side .auth-points { display: none; }
  .auth-side .brand { color: var(--text); font-size: 17px; }
  .auth-side .brand-badge { width: 30px; height: 30px; background: var(--primary); color: var(--on-primary); }
  .auth-main { padding: 24px 18px 40px; }
  .auth-form { width: min(500px, 100%); }
  .auth-form h2 { font-size: 25px; }
  .auth-sub { font-size: 14px; }
  .stepper { gap: 6px; margin-bottom: 18px; font-size: 12px; }
  .stepper li { gap: 4px; white-space: nowrap; }
}

.admin-add-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; }

/* Start here */
.start-page { max-width: 900px; }
.start-section { margin-top: 34px; }
.start-head { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px; align-items: start; margin-bottom: 14px; }
.start-head .step-n { margin: 0; }
.start-head h2 { font-size: 23px; font-weight: 700; margin-bottom: 2px; }
.start-list { display: grid; gap: 9px; margin: 14px 0; }
.start-list li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 10px; line-height: 1.55; }
.start-list svg.icon { width: 18px; height: 18px; margin-top: 3px; color: var(--right); }
.start-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.start-phases { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.start-phases li { padding: 16px 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.start-phases b { font-size: 17px; }
.start-ready { padding: 8px 18px 14px; }
.ready-row { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line); }
.ready-mark { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); color: var(--right); }
.ready-row.done .ready-mark { border-color: var(--right); background: var(--right-soft); }
.ready-mark svg.icon { width: 14px; height: 14px; }
.start-ready > p { margin-top: 12px; font-weight: 600; }
.start-finish { margin: 34px 0 10px; display: flex; justify-content: flex-end; }
@media (max-width: 700px) { .start-grid, .start-phases { grid-template-columns: 1fr; } .ready-row { grid-template-columns: 26px minmax(0, 1fr); } .ready-row .quiet { grid-column: 2; } }

.danger-card { border-color: color-mix(in srgb, var(--wrong) 40%, var(--line)); }

/* Security labs */
.seclab-layout { display: grid; grid-template-columns: minmax(260px, 0.8fr) minmax(0, 1.6fr); gap: 18px; align-items: start; margin-top: 16px; }
.seclab-work { display: grid; gap: 14px; min-width: 0; }
.lab-editor { padding: 16px 18px; display: grid; gap: 10px; min-width: 0; }
.lab-editor h2 { font-size: 17px; }
.code-editor, .filter-input, .evidence { font: 13.5px/1.5 var(--mono); }
.code-editor { width: 100%; min-height: 170px; padding: 12px; border: 1px solid var(--line); border-radius: min(var(--radius), 10px); background: var(--surface-2); color: var(--text); resize: vertical; }
.filter-input { width: 100%; padding: 10px 12px; border: 2px solid color-mix(in srgb, var(--right) 55%, var(--line)); border-radius: 8px; background: var(--surface); color: var(--text); }
.filter-input.bad { border-color: var(--wrong); background: var(--wrong-soft); }
.lab-result { max-height: 420px; overflow: auto; }
.lab-result .table { font-size: 12.5px; }
.lab-result td { font-family: var(--mono); white-space: nowrap; max-width: 520px; overflow: hidden; text-overflow: ellipsis; }
.packets td:last-child { white-space: normal; }
.lab-tasks li.selectable { cursor: pointer; border-radius: 8px; }
.lab-tasks li.current { background: var(--primary-soft); outline: 1px solid var(--primary); }
.lab-hint { color: var(--hl-text); background: var(--hl); padding: 4px 8px; border-radius: 6px; margin-top: 4px; }
.lab-answer input { width: 100%; margin-top: 6px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text); font: 14px var(--mono); }
.lab-schema { padding: 12px 16px; }
.lab-schema summary { cursor: pointer; font-weight: 600; }
.schema-table { margin-top: 10px; }
.schema-table p { font-family: var(--mono); font-size: 12px; line-height: 1.6; }
.lab-tests { margin-top: 12px; }
.lab-tests td.pass { color: var(--right); font-weight: 700; }
.lab-tests td.fail { color: var(--wrong); font-weight: 700; }
.evidence { max-height: 460px; overflow: auto; padding: 12px; background: var(--surface-2); border-radius: 8px; white-space: pre; }
@media (max-width: 900px) { .seclab-layout { grid-template-columns: 1fr; } }
.wide-dialog { max-width: min(760px, 94vw); }

/* Lab layout fixes: keep every workspace inside its column, use the screen width for labs */
.page.lab-page { width: min(1480px, 100%); }
.seclab-layout { grid-template-columns: minmax(280px, 340px) minmax(0, 1fr); }
.seclab-layout > *, .seclab-work, .seclab-work > *, .lab-editor > * { min-width: 0; }
.seclab-work { grid-template-columns: minmax(0, 1fr); }
.lab-editor { grid-template-columns: minmax(0, 1fr); overflow: hidden; }
.lab-editor .row-head { flex-wrap: wrap; row-gap: 2px; }
.lab-editor .row-head .quiet { margin-left: auto; }
.lab-result, .lab-tests .table-wrap { max-width: 100%; overflow: auto; }
.lab-result .table, .lab-tests .table { min-width: 0; width: 100%; }
.lab-result td { max-width: 360px; }
.lab-tests .table td { white-space: normal; }
.lab-task-card { position: sticky; top: 16px; max-height: calc(100vh - 32px); overflow: auto; }
.lab-card-top { align-items: flex-start; }
.lab-kind { display: inline-block; padding: 2px 9px; border-radius: 99px; background: var(--primary-soft); color: var(--primary); font-size: 12px; font-weight: 700; letter-spacing: .02em; }
.lab-meta { font-size: 12.5px; color: var(--text-3); font-weight: 600; letter-spacing: .02em; text-transform: uppercase; }
.lab-tests h3 { font-size: 15px; font-weight: 700; margin: 4px 0 6px; }
.lab-tests td.wait { color: var(--text-3); }
@media (max-width: 900px) {
  .seclab-layout { grid-template-columns: minmax(0, 1fr); }
  .lab-task-card { position: static; max-height: none; }
  .page.lab-page { padding: 0 14px; }
}
.lab-section-title { font-size: 15px; font-weight: 700; margin: 6px 0 2px; }
.lab-tests .table { table-layout: fixed; }
.lab-tests .table th:nth-child(1) { width: 50%; }
.lab-tests .table th:nth-child(2) { width: 20%; }
.lab-tests .table th:nth-child(3) { width: 24%; }
.lab-tests .table th:nth-child(4) { width: 6%; }
@media (max-width: 600px) { .lab-tests .table th:nth-child(1) { width: 40%; } .lab-tests .table th:nth-child(4) { width: 10%; } }

.lab-editor input[type=search] { width: 100%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; }
@media (max-width: 900px) {
  .seclab-layout.kind-investigate .seclab-work { order: -1; }
  .evidence { white-space: pre-wrap; word-break: break-word; max-height: 360px; font-size: 12.5px; }
}

/* Study plan */
.plan-summary { display: grid; gap: 8px; align-content: start; }
.plan-countdown { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.pace { font-size: 13px; font-weight: 600; padding: 5px 10px; border-radius: 8px; }
.pace.on_track { background: var(--right-soft); color: var(--right); }
.pace.behind { background: var(--wrong-soft); color: var(--wrong); }
.plan-list { display: grid; gap: 8px; }
.plan-list li { display: grid; grid-template-columns: 28px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: min(var(--radius), 12px); }
.plan-list li a { display: grid; gap: 2px; text-decoration: none; color: inherit; }
.plan-list li a b { font-weight: 600; }
.plan-tick { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); color: var(--right); }
.plan-tick svg.icon { width: 14px; height: 14px; }
.plan-list li.done { opacity: .7; }
.plan-list li.done .plan-tick { border-color: var(--right); background: var(--right-soft); }
.plan-go { font-size: 13.5px; font-weight: 600; color: var(--primary); white-space: nowrap; }
.plan-list li.done .plan-go { color: var(--right); }

/* Flashcards */
.flash-page { max-width: 760px; }
.flash-stage { display: grid; gap: 16px; margin-top: 16px; }
.flash-card { display: grid; gap: 14px; min-height: 280px; align-content: start; padding: 26px 28px; text-align: left; font: inherit; color: var(--text); background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 4px); box-shadow: var(--shadow); cursor: pointer; }
.flash-card:hover { border-color: var(--primary); }
.flash-card.flipped { background: color-mix(in srgb, var(--primary-soft) 45%, var(--surface)); }
.flash-front p:first-child { font-size: 19px; line-height: 1.5; font-weight: 500; }
.flash-domain { justify-self: start; padding: 3px 10px; border-radius: 99px; font-size: 12.5px; font-weight: 700; background: color-mix(in srgb, var(--d) 14%, var(--surface)); color: var(--d); }
.flash-answer { font-size: 18px; font-weight: 600; white-space: pre-line; margin: 4px 0 12px; }
.flash-back .memo-rule { padding: 11px 14px; border-radius: 10px; background: var(--hl); color: var(--hl-text); margin-bottom: 8px; }
.flash-grades { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; }
.flash-grades .btn { gap: 8px; }
.flash-grades .btn span { font-size: 11px; opacity: .6; border: 1px solid currentColor; border-radius: 5px; padding: 0 5px; }
.grade-again { border-color: var(--wrong); color: var(--wrong); }
.grade-good { border-color: var(--primary); color: var(--primary); }
.grade-easy { border-color: var(--right); color: var(--right); }

/* Exam simulator */
.room-pos { justify-self: center; font-weight: 600; }
.room.examday .room-bar { background: #0f2747; color: #fff; }
.flag-btn.on { border-color: #b7791f; background: #fff4dc; color: #8a5a00; }
.review-screen { display: grid; gap: 14px; }
.review-key { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; }
.rk::before { content: ""; display: inline-block; width: 12px; height: 12px; margin-right: 6px; border-radius: 3px; vertical-align: -1px; border: 1px solid var(--line); }
.rk.answered::before, .rq.answered { background: var(--primary-soft); border-color: var(--primary); }
.rk.flagged::before { background: #fff4dc; border-color: #b7791f; }
.rk.open::before, .rq.open { background: var(--surface); }
.review-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); gap: 6px; }
.rq { position: relative; height: 40px; border: 1px solid var(--line); border-radius: 8px; font: 600 14px var(--mono); color: var(--text); cursor: pointer; }
.rq.flagged { box-shadow: inset 0 -4px 0 #b7791f; }
.rq:disabled { opacity: .35; cursor: default; }
.case-tabs { display: flex; gap: 4px; margin-bottom: 12px; }
.case-tabs button { padding: 7px 16px; border: 1px solid var(--line); border-radius: 8px 8px 0 0; background: var(--surface-2); font-weight: 600; }
.case-tabs button.on { background: var(--surface); border-bottom-color: var(--surface); color: var(--primary); }
.case-layout > * { display: none; }
.case-layout > .shown { display: block; }
.case-text { white-space: pre-line; line-height: 1.6; }
.examday-opt { margin: 14px 0 4px; }
@media (min-width: 1200px) {
  .room-body:has(.case-layout) { width: min(1280px, 100%); }
  .case-tabs { display: none; }
  .case-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; align-items: start; }
  .case-layout > * { display: block; }
  .case-panel { position: sticky; top: 70px; max-height: calc(100vh - 170px); overflow: auto; }
}

.pbq { display: grid; gap: 12px; }
.pbq-tasks { display: grid; gap: 6px; padding-left: 20px; list-style: decimal; }
.pbq-term { min-height: 220px; max-height: 320px; }
.pbq-status.pass { color: var(--right); font-weight: 600; }
.pbq-status.fail { color: var(--wrong); font-weight: 600; }

/* Automation rule builder */
.auto-rules { display: grid; gap: 12px; }
.auto-rule { padding: 14px 16px; display: grid; gap: 8px; }
.auto-head { display: grid; grid-template-columns: 70px minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.auto-row { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; align-items: center; }
.auto-row.three { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.3fr) auto; }
.auto-row.two { grid-template-columns: minmax(0, 1fr) minmax(0, 1.6fr) auto; }
.auto-rule input, .auto-rule select, .lab-answer select { width: 100%; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--text); font: inherit; font-size: 14px; }
.text-btn.danger { color: var(--wrong); }
@media (max-width: 700px) { .auto-row.three, .auto-row.two { grid-template-columns: minmax(0, 1fr); } }

/* Certificate */
.cert-page { max-width: 920px; }
.certificate { position: relative; display: grid; gap: 14px; padding: 46px 52px; background: var(--surface); border: 2px solid var(--primary); border-radius: 18px; box-shadow: 0 20px 50px rgba(20,40,70,.14); text-align: center; }
.certificate::before { content: ""; position: absolute; inset: 10px; border: 1px solid color-mix(in srgb, var(--primary) 35%, transparent); border-radius: 12px; pointer-events: none; }
.cert-brand { display: flex; justify-content: center; align-items: center; gap: 10px; font-size: 20px; }
.certificate h1 { font-size: clamp(30px, 4.6vw, 46px); font-weight: 700; letter-spacing: -.02em; }
.cert-line { max-width: 40em; margin: 0 auto; font-size: 17px; line-height: 1.6; color: var(--text-2); }
.cert-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin: 10px 0; }
.cert-facts li { display: grid; gap: 2px; padding: 12px; background: var(--surface-2); border-radius: 10px; }
.cert-facts b { font-size: 20px; }
.cert-facts span { font-size: 13px; color: var(--text-2); }
.cert-foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; font-weight: 600; font-size: 14px; border-top: 1px solid var(--line); padding-top: 14px; }
.cert-actions { margin-top: 18px; justify-content: center; }
@media (max-width: 640px) { .certificate { padding: 30px 22px; } .cert-facts { grid-template-columns: 1fr; } }
@media print { .site-head, .site-foot, .cert-actions { display: none !important; } .certificate { box-shadow: none; } }
/* Alignment fixes for new screens */
.plan-summary { place-items: stretch; justify-items: stretch; text-align: left; align-content: start; }
.plan-summary .meter { width: 100%; }
.plan-list { padding: 0; margin: 0; list-style: none; }
.rq { display: grid; place-items: center; text-align: center; padding: 0; }
.lab-tests .table.auto-results th:nth-child(1) { width: 38%; }
.lab-tests .table.auto-results th:nth-child(2) { width: 54%; }
.lab-tests .table.auto-results th:nth-child(3) { width: 8%; }
.plan-summary { justify-content: stretch; grid-template-columns: minmax(0, 1fr); }

/* ---------- Landing page (hm) ---------- */
.hm { --serif: var(--sans); }
.hm h1, .hm h2 { font-family: var(--serif); font-weight: 600; letter-spacing: -.01em; color: var(--text); }
.hm h2 { font-size: clamp(28px, 3.4vw, 40px); line-height: 1.15; margin-bottom: 10px; }
.hm section { padding: 76px 0; }
.hm-sub { color: var(--text-2); font-size: 17px; max-width: 38em; margin-bottom: 34px; }
.hm-small { font-size: 13px; color: var(--text-3); }
/* hero */
.hm-hero { padding: 56px 0 70px !important; background: linear-gradient(180deg, color-mix(in srgb, var(--primary) 6%, var(--bg)), var(--bg)); border-bottom: 1px solid var(--line); }
.hm-hero-inner { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 56px; align-items: start; }
.hm-byline { font-size: 14px; font-weight: 600; color: var(--primary); margin-bottom: 14px; }
.hm h1 { font-size: clamp(40px, 5.2vw, 64px); line-height: 1.05; margin-bottom: 20px; max-width: 12em; }
.hm-lede { font-size: 18.5px; line-height: 1.6; color: var(--text-2); max-width: 34em; margin-bottom: 28px; }
.hm-pick { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; box-shadow: 0 1px 2px rgba(20,40,70,.04), 0 12px 32px rgba(20,40,70,.08); }
.hm-pick-q { padding: 14px 18px; font-weight: 600; border-bottom: 1px solid var(--line); background: var(--surface-2); }
.hm-pick-row { display: grid; grid-template-columns: 78px minmax(0, 1fr) auto; gap: 12px; align-items: center; width: 100%; padding: 15px 18px; border: 0; border-bottom: 1px solid var(--line); background: var(--surface); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.hm-pick-row:last-child { border-bottom: 0; }
.hm-pick-row:hover { background: var(--primary-soft); }
.hm-pick-row b { font-size: 17px; }
.hm-pick-name { font-size: 15px; }
.hm-pick-name small { color: var(--text-3); font-size: 13px; }
.hm-pick-go { font-size: 14px; font-weight: 600; color: var(--primary); white-space: nowrap; }
.hm-note { margin-top: 12px; font-size: 14px; color: var(--text-2); }
/* product collage */
.hm-collage { position: relative; min-height: 520px; }
.hm-shot { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 2px 4px rgba(20,40,70,.05), 0 20px 44px rgba(20,40,70,.14); }
.hm-mock { position: absolute; top: 0; left: 0; right: 40px; overflow: hidden; }
.hm-mock-bar { display: flex; justify-content: space-between; gap: 10px; padding: 10px 16px; background: #173f7a; color: #fff; font-size: 12.5px; }
.hm-mock-bar b { font-family: var(--mono); }
.hm-mock-body { padding: 18px; display: grid; gap: 8px; }
.hm-mock-body > p { font-weight: 600; line-height: 1.45; margin-bottom: 4px; }
.hm-opt { display: flex; gap: 10px; align-items: center; padding: 8px 10px; border: 1.5px solid var(--line); border-radius: 8px; font-size: 14px; }
.hm-opt span { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 6px; background: var(--surface-2); font-size: 12px; font-weight: 700; }
.hm-opt.sel { border-color: var(--primary); background: var(--primary-soft); }
.hm-opt.sel span { background: var(--primary); color: var(--on-primary); }
.hm-mock-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 6px; font-size: 13px; color: var(--text-2); }
.hm-next { padding: 6px 16px; border-radius: 7px; background: var(--primary); color: var(--on-primary); font-weight: 600; }
.hm-plan { position: absolute; right: 0; top: 250px; width: 270px; padding: 16px; display: grid; gap: 8px; transform: rotate(1.2deg); }
.hm-plan-row { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 8px; font-size: 13.5px; align-items: center; }
.hm-plan-row i { display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; border: 1.5px solid var(--line); font-size: 11px; font-style: normal; color: var(--right); }
.hm-plan-row.done i { border-color: var(--right); background: var(--right-soft); }
.hm-plan-row.done { color: var(--text-3); text-decoration: line-through; }
.hm-term { margin: 0; padding: 14px 16px; background: #0f1724; color: #d7e0ea; font: 12.5px/1.6 var(--mono); white-space: pre-wrap; border-color: #0f1724; }
.hm-term .c { color: #7fd1a5; }
.hm-term .ok { color: #9ee6b8; font-weight: 700; }
.hm-collage .hm-term { position: absolute; left: 24px; bottom: 0; width: 330px; transform: rotate(-1deg); }
/* newcomers */
.hm-new { background: var(--surface); border-bottom: 1px solid var(--line); padding: 56px 0 !important; }
.hm-steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 30px; margin-top: 22px; counter-reset: s; }
.hm-steps li { counter-increment: s; position: relative; padding-top: 44px; line-height: 1.6; color: var(--text-2); }
.hm-steps li::before { content: counter(s); position: absolute; top: 0; left: 0; font: 600 34px/1 var(--serif); color: var(--primary); }
.hm-steps b { color: var(--text); }
/* week */
.hm-moment { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 56px; align-items: center; padding: 34px 0; border-top: 1px solid var(--line); }
.hm-moment.flip .hm-moment-text { order: 2; }
.hm-when { display: inline-block; font-size: 13px; font-weight: 700; color: var(--primary); letter-spacing: .02em; margin-bottom: 8px; }
.hm-moment h3 { font: 600 25px/1.25 var(--serif); margin-bottom: 8px; }
.hm-moment p { color: var(--text-2); line-height: 1.65; font-size: 16.5px; }
.hm-moment-visual { min-width: 0; }
.hm-flash { padding: 22px; display: grid; gap: 10px; max-width: 420px; }
.hm-flash b { font-size: 18px; line-height: 1.45; }
.hm-flash-btns { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 6px; }
.hm-flash-btns span { text-align: center; padding: 7px; border: 1.5px solid var(--line); border-radius: 8px; font-size: 13.5px; font-weight: 600; }
.hm-flash-btns span.on { border-color: var(--primary); color: var(--primary); background: var(--primary-soft); }
.hm-debrief { padding: 20px; display: grid; gap: 8px; max-width: 440px; }
.hm-debrief p { font-size: 14.5px !important; }
.hm-score { display: flex; align-items: baseline; gap: 10px; padding-top: 8px; border-top: 1px solid var(--line); }
.hm-score b { font: 600 30px var(--serif); }
.hm-score small { color: var(--text-3); }
.hm-moment-visual .hero-preview { max-width: 520px; }
/* honest */
.hm-honest { background: var(--surface); border-block: 1px solid var(--line); }
.hm-honest-inner { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 56px; align-items: start; }
.hm-honest-inner p { color: var(--text-2); line-height: 1.7; font-size: 16.5px; margin-bottom: 14px; }
.hm-sign { font-family: var(--serif); font-style: italic; color: var(--text) !important; }
.hm-table-wrap { overflow-x: auto; }
.hm-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.hm-table th { text-align: left; font-size: 12.5px; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); padding: 0 12px 10px 0; border-bottom: 2px solid var(--text); }
.hm-table td { padding: 14px 12px 14px 0; border-bottom: 1px solid var(--line); vertical-align: top; }
.hm-table td a { text-decoration: none; color: var(--text); }
.hm-table td small { display: block; color: var(--text-3); font-size: 12.5px; }
.hm-table + .hm-small { margin-top: 10px; }
/* prices */
.hm-paying { margin-top: 34px; padding: 24px 26px; border-left: 4px solid var(--primary); background: var(--surface); border-radius: 0 12px 12px 0; display: grid; gap: 10px; justify-items: start; }
.hm-paying h3 { font: 600 21px var(--serif); }
.hm-paying p { color: var(--text-2); line-height: 1.65; max-width: 46em; }
/* faq */
.hm-faqs { background: var(--surface); border-top: 1px solid var(--line); }
.hm-faq-inner { display: grid; grid-template-columns: minmax(0, .7fr) minmax(0, 1.3fr); gap: 56px; }
.hm-faq { border-bottom: 1px solid var(--line); padding: 16px 0; }
.hm-faq summary { cursor: pointer; font-weight: 600; font-size: 17px; list-style: none; display: flex; justify-content: space-between; gap: 12px; }
.hm-faq summary::-webkit-details-marker { display: none; }
.hm-faq summary::after { content: "+"; color: var(--primary); font-size: 22px; line-height: 1; }
.hm-faq[open] summary::after { content: "−"; }
.hm-faq p { margin-top: 10px; color: var(--text-2); line-height: 1.65; }
/* end */
.hm-end { padding: 56px 0 !important; }
.hm-end-inner { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.hm-end-inner p { font: 500 22px/1.4 var(--serif); max-width: 30em; }
@media (max-width: 980px) {
  .hm-hero-inner, .hm-honest-inner, .hm-faq-inner { grid-template-columns: minmax(0, 1fr); gap: 34px; }
  .hm-collage { min-height: 0; display: grid; gap: 14px; }
  .hm-mock, .hm-plan, .hm-collage .hm-term { position: static; width: auto; transform: none; right: auto; }
  .hm-plan, .hm-collage .hm-term { display: none; }
  .hm-steps { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .hm-moment, .hm-moment.flip { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .hm-moment.flip .hm-moment-text { order: 0; }
}
@media (max-width: 600px) {
  .hm section { padding: 52px 0; }
  .hm-pick-row { grid-template-columns: 64px minmax(0, 1fr); }
  .hm-pick-go { grid-column: 2; }
  .hm-mock-bar span:first-child { display: none; }
}
/* hero collage: three shots that never collide */
.hm-collage { min-height: 560px; }
.hm-mock { right: 70px; }
.hm-plan { top: 300px; right: 0; width: 250px; transform: rotate(1.5deg); z-index: 2; }
.hm-collage .hm-term { top: 380px; bottom: auto; left: 0; width: 300px; transform: rotate(-1.2deg); z-index: 1; }
@media (max-width: 1150px) { .hm-collage .hm-term { width: 260px; } .hm-plan { width: 220px; } }
@media (max-width: 600px) {
  .hm-table th:nth-child(3), .hm-table td:nth-child(3), .hm-table th:nth-child(4), .hm-table td:nth-child(4) { display: none; }
  .hm h1 { font-size: 38px; }
  .hm-end-inner p { font-size: 19px; }
}
.hm-collage .hm-term { width: 245px; font-size: 11.5px; }
@media (max-width: 1150px) { .hm-collage .hm-term { width: 230px; } }

/* ---------- PassLab virtual practicals ---------- */
.pr-grid { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 20px; align-items: start; margin-top: 16px; }
.pr-main { display: grid; gap: 16px; min-width: 0; }
.pr-side { position: sticky; top: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; }
.pr-side h2, .pr-card h2 { font-size: 1.05rem; margin: 0 0 10px; }
.pr-card { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 16px; min-width: 0; }
.pr-stage { background: color-mix(in srgb, var(--surface) 85%, var(--primary) 4%); border: 1px solid var(--line); border-radius: 10px; padding: 8px; }
.pr-svg { width: 100%; height: auto; display: block; }
.pr-controls { display: flex; flex-wrap: wrap; gap: 12px 20px; align-items: end; margin-top: 12px; }
.pr-control { display: grid; gap: 4px; min-width: 220px; flex: 1; }
.pr-control label, .pr-field label { font-weight: 600; font-size: .9rem; }
.pr-control input[type=range] { width: 100%; accent-color: var(--primary); }
.pr-out { font-variant-numeric: tabular-nums; color: var(--text-2); }
.pr-nudge { display: inline-flex; gap: 6px; }
.pr-nudge .btn { min-width: 40px; padding: 4px 10px; }
.pr-field { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 10px 0; }
.pr-field label { flex-basis: 100%; }
.pr-input { flex: 1; min-width: 120px; max-width: 220px; padding: 8px 10px; border: 1px solid var(--line); border-radius: 8px; background: var(--bg, var(--surface)); color: var(--text); font: inherit; }
.pr-msg { min-height: 1.4em; font-weight: 600; color: var(--primary); }
.pr-table td, .pr-table th { font-variant-numeric: tabular-nums; white-space: nowrap; }
.pr-table tr.pr-bad td { background: color-mix(in srgb, #d33 14%, transparent); }
.pr-theory { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 12px 16px; margin-top: 12px; }
.pr-theory summary { cursor: pointer; font-weight: 600; }
.pr-svg text { font-family: var(--sans); }
.pr-cap { font-size: 12px; fill: var(--text-2); }
.pr-num { font-size: 11px; fill: var(--text); }
.pr-lcd { font-size: 26px; font-family: ui-monospace, Menlo, monospace !important; fill: var(--primary); }
.pr-tick { stroke: var(--text); stroke-width: 1.2; }
.pr-solid { fill: var(--text-2); }
.pr-string, .pr-lead { stroke: var(--text); stroke-width: 1.5; fill: none; }
.pr-guide { stroke: var(--line); stroke-dasharray: 4 4; }
.pr-bob, .pr-jockey { fill: var(--primary); }
.pr-device { fill: var(--surface); stroke: var(--text-2); stroke-width: 1.5; }
.pr-rule { fill: color-mix(in srgb, #e9c46a 30%, var(--surface)); stroke: var(--text-2); }
.pr-vernier { fill: color-mix(in srgb, var(--primary) 16%, var(--surface)); stroke: var(--text-2); }
.pr-spring { stroke: var(--text-2); stroke-width: 2; fill: none; }
.pr-pointer, .pr-needle { stroke: #d33; stroke-width: 2; }
.pr-mass { fill: var(--text-2); }
.pr-wire { stroke: #b87333; stroke-width: 3; }
.pr-lens { fill: color-mix(in srgb, #4aa3df 35%, transparent); stroke: #4aa3df; }
.pr-arrow, .pr-image { stroke: var(--primary); stroke-width: 4; }
.pr-tube { fill: none; stroke: var(--text-2); stroke-width: 2; }
.pr-water { fill: color-mix(in srgb, #4aa3df 45%, transparent); }
.pr-fork { stroke: var(--text-2); stroke-width: 4; fill: none; }
.pr-bar { fill: var(--line); } .pr-bar.on { fill: var(--primary); }
.pr-gridline { stroke: var(--line); stroke-width: .6; }
.pr-axis { stroke: var(--text); stroke-width: 1.4; }
.pr-fit { stroke: var(--primary); stroke-width: 2; }
.pr-point { stroke: #d33; stroke-width: 2; }
@media (max-width: 860px) { .pr-grid { grid-template-columns: minmax(0, 1fr); } .pr-side { position: static; order: -1; } }

/* PassLab papers */
.paper-group { margin: 28px 0 4px; font-size: 1.15rem; }
.paper-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin-top: 12px; }
.paper-card { display: grid; gap: 8px; align-content: start; padding: 16px; }
.paper-card h3 { margin: 0; font-size: 1rem; line-height: 1.45; }
.paper-top { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.paper-card .btn { justify-self: start; }
.paper-soon { opacity: .7; border-style: dashed; }

/* PassLab landing */
.pl .hm-hero h1 { font-size: clamp(1.7rem, 3.6vw, 2.6rem); line-height: 1.35; }
.pl-cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 8px; }
.btn.big { padding: 12px 20px; font-size: 1rem; }
.pl-hero-visual { display: grid; align-content: center; }
.pl-sample { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; box-shadow: 0 10px 30px rgba(0,0,0,.08); }
.pl-sample-tag { font-size: .8rem; color: var(--text-2); margin: 0 0 6px; }
.pl-sample-q { font-weight: 600; line-height: 1.6; margin: 0 0 10px; }
.pl-sample-opts { margin: 0; padding-left: 1.4em; display: grid; gap: 6px; }
.pl-sample-opts li { padding: 4px 8px; border-radius: 8px; }
.pl-sample-opts li.right { background: color-mix(in srgb, var(--primary) 14%, transparent); font-weight: 600; }
.pl-sample-ex { margin: 12px 0 0; font-size: .9rem; color: var(--text-2); line-height: 1.6; }
.pl-features { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin-top: 18px; }
.pl-feature { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 18px; }
.pl-feature h3 { margin: 8px 0 6px; font-size: 1.05rem; }
.pl-feature p { margin: 0; color: var(--text-2); line-height: 1.65; }
.pl-ico { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: 10px; background: color-mix(in srgb, var(--primary) 14%, transparent); color: var(--primary); font-size: 1.2rem; }
.pl-lab { padding: 48px 0; }
.pl-lab-inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 28px; align-items: center; }
.pl-lab-inner p { line-height: 1.7; }
.pl-lab-visual { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 10px; }
.pl-subjects { padding: 36px 0; }
.pl-subject-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-top: 14px; }
.pl-subject { display: grid; gap: 4px; text-align: left; padding: 16px; border: 1px dashed var(--line); border-radius: 12px; background: var(--surface); color: var(--text); font: inherit; }
.pl-subject.on { border: 2px solid var(--primary); cursor: pointer; }
.pl-subject small { color: var(--text-2); }
@media (max-width: 760px) { .pl-lab-inner { grid-template-columns: minmax(0, 1fr); } }
.pr-side .lab-tasks { display: grid; gap: 8px; padding: 0; margin: 0; list-style: none; counter-reset: none; }
.pr-side .lab-tasks li { display: block; padding: 10px 12px; border-radius: 10px; background: color-mix(in srgb, var(--line) 35%, transparent); }
.pr-side .lab-tasks li::before { display: none; }
.pr-side .lab-tasks li.pass { background: color-mix(in srgb, #2a9d63 16%, transparent); }
.pr-side .lab-tasks li.pass strong::before { content: "✓ "; color: #2a9d63; }
.pr-side .lab-tasks li strong { display: block; line-height: 1.5; }
.pr-side .lab-tasks li p { margin: 4px 0 0; line-height: 1.55; }
.pr-stage .pr-svg { max-height: 360px; width: 100%; }
.pr-plot { max-height: 340px; }
.pr-table th { text-transform: none; letter-spacing: 0; }
@media (max-width: 640px) {
  .site-head .site-inner > *:last-child { display: flex; flex-wrap: wrap; gap: 6px; justify-content: flex-end; max-width: 60%; }
  .site-head .btn { padding: 6px 10px; font-size: 12.5px; white-space: normal; line-height: 1.3; }
  .hm-hero-inner, .pl-lab-inner { grid-template-columns: minmax(0, 1fr) !important; }
  .pl .hm-hero-copy, .pl-hero-visual, .pl-sample, .pl-features, .pl-feature { min-width: 0; max-width: 100%; }
  .pl-features { grid-template-columns: minmax(0, 1fr); }
  .pl-sample-q, .hm-lede, .pl-feature p { overflow-wrap: anywhere; }
}
