/* K53 Pass - design direction B "Taxi-rank loud" (DESIGN.md v3). Flat colour: no gradients, no blur,
   no glow. Thick ink outlines, hard offset shadows on the few things you press to move on.
   One font: Rubik (variable 300-900, Latin only, 35 KB). Latin Extended letters and the ten Tshivenda
   letters Rubik lacks are added by js/core.js loadLatinExt() only for a language that needs them.
   Light only on purpose: the sign-yellow ground and ink outlines ARE the look (see DESIGN.md). */

@font-face { font-family: "Rubik"; font-style: normal; font-weight: 300 900; font-display: swap;
  src: url(fonts/rubik-latin.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  color-scheme: light;
  --yellow: #ffd100;
  --red: #e4002b;
  --red-ink: #b0001f;
  --blue: #0047bb;
  --ink: #141414;
  --white: #fff;
  --cream: #fff8e1;
  --green: #00843d;
  --muted: #4a4a4a;
  --soft: #ececec;
  --dash: #bdbdbd;
  --bw: 3px;
  --r: 16px;
  --r-big: 20px;
  --f: "Rubik", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --gutter: max(16px, env(safe-area-inset-left));
}

* { box-sizing: border-box; }
html { background: var(--white); -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; color: var(--ink); background: var(--white); font: 400 17px/1.45 var(--f); overflow-wrap: break-word; }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
img { max-width: 100%; }
[hidden] { display: none !important; }
h1, h2, h3, h4 { font-weight: 900; line-height: 1.12; margin: 0; letter-spacing: -.01em; }
h1 { font-size: 32px; }
h2 { font-size: 24px; }
h3 { font-size: 20px; font-weight: 800; }
h4 { font-size: 18px; font-weight: 800; }
p { margin: 0; }
a { color: var(--blue); font-weight: 600; text-underline-offset: 3px; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -80px; z-index: 20; padding: 10px 14px; color: var(--ink); background: var(--yellow); border: var(--bw) solid var(--ink); border-radius: 12px; font-weight: 700; }
.skip:focus { top: 12px; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; box-shadow: 0 0 0 3px var(--white); }
[tabindex="-1"]:focus { outline: none; box-shadow: none; }

/* ---------- chrome ---------- */
.topbar { background: var(--yellow); border-bottom: var(--bw) solid var(--ink); }
body:has(.hero) .topbar { border-bottom: 0; }
.topbar-in { max-width: 1080px; margin: 0 auto; padding: 10px var(--gutter) 10px; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; }
.brand { display: inline-flex; align-items: center; min-height: 48px; color: var(--white); text-decoration: none; }
.board { display: inline-block; padding: 7px 13px 6px; background: var(--red); border: var(--bw) solid var(--ink); border-radius: 9px; box-shadow: inset 0 0 0 3px var(--white); transform: rotate(-2deg); }
.logo-type { display: block; height: 26px; width: auto; aspect-ratio: 470 / 77; }
.lang-picker { margin-left: auto; }
.lang-picker select { min-height: 48px; max-width: 46vw; padding: 0 10px; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 12px; font-size: 16px; font-weight: 600; }
/* System fonts: the language names include Latin Extended letters (Tshivenda). */
.lang-picker select, .lang-picker option { font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
/* Phones: one row of four tab buttons, icon over a short label. Never wraps into a second row:
   a long label (siSwati "Inchubekelembili yami") breaks between words inside its own button. */
.mainnav { display: flex; gap: 4px; width: 100%; padding: 2px 0 4px; }
.navbtn { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; min-height: 58px; padding: 5px 3px; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: 14px; font-size: 13px; font-weight: 700; line-height: 1.1; text-align: center; overflow-wrap: anywhere; }
.nav-ico { flex: none; width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.navbtn:hover { background: var(--cream); }
.navbtn[aria-current="page"] { color: var(--yellow); background: var(--ink); }
@media (min-width: 760px) {
  .mainnav { gap: 8px; width: auto; order: 2; margin-left: auto; }
  .navbtn { flex: 0 0 auto; flex-direction: row; min-height: 48px; padding: 4px 18px; border-radius: 999px; font-size: 16px; white-space: nowrap; }
  .nav-ico { display: none; }
  .lang-picker { order: 3; margin-left: 0; }
}
.lang-note { max-width: 1080px; margin: 12px auto 0; padding: 12px 14px; background: var(--cream); border: var(--bw) solid var(--ink); border-left-width: 10px; border-left-color: var(--blue); border-radius: 14px; font-size: 16px; width: calc(100% - 2 * var(--gutter)); }
main { display: block; max-width: 1080px; margin: 0 auto; padding: 24px var(--gutter) 48px; }
main:focus { outline: none; box-shadow: none; }
.site-foot { padding: 20px var(--gutter) calc(24px + env(safe-area-inset-bottom)); color: var(--white); background: var(--ink); font-size: 15px; }
.site-foot p { max-width: 1080px; margin: 0 auto; }
/* The "A bascorp agency product" badge (public/img, not to be restyled): last footer row, right on
   wide screens, centred on phones. The site is light-only, so always the light badge. */
.foot-badge { max-width: 1080px; margin: 4px auto 0; text-align: right; }
.bascorp-badge { display: inline-flex; line-height: 0; margin: 12px; }
.bascorp-badge img { height: 36px; width: auto; }
.bascorp-badge .bb-light { display: none; } .bascorp-badge .bb-dark { display: inline; } /* footer is dark ink: dark badge per the Bascorp badge spec */
@media (max-width: 599px) { .foot-badge { text-align: center; } }
@media (max-width: 480px) { .bascorp-badge img { height: 30px; } }

/* ---------- controls ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 6px 18px; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: 14px; font-size: 16px; font-weight: 700; line-height: 1.2; text-decoration: none; text-align: center; }
.btn:hover { background: var(--cream); }
.btn:active { transform: translateY(2px); }
.btn.primary, .btn.danger { color: var(--white); background: var(--red); box-shadow: 0 4px 0 var(--ink); }
.btn.primary:hover, .btn.danger:hover { background: #cc0027; }
.btn.primary:active, .btn.danger:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--ink); }
.btn.ghost { background: transparent; border-color: transparent; text-decoration: underline; text-underline-offset: 3px; }
.btn.ghost:hover { background: rgba(20, 20, 20, .06); }
.btn.small { font-size: 15px; padding: 4px 14px; }
/* A link-style button lines up with the column's left edge like the text around it. */
.btn.ghost, .btn.ghost.small { padding-left: 0; padding-right: 0; border-left-width: 0; border-right-width: 0; }
.btn.big { min-height: 60px; padding: 8px 26px; font-size: 22px; font-weight: 900; }
.btn[disabled] { opacity: .4; cursor: not-allowed; transform: none; }
.row { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 16px; }
.msg { margin: 12px 0 0; padding: 12px 14px; background: var(--cream); border: var(--bw) solid var(--ink); border-left-width: 10px; border-left-color: var(--blue); border-radius: 14px; font-size: 16px; }
.msg.ok { border-left-color: var(--green); }
.msg.err { border-left-color: var(--red); }
.msg.bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.msg.bar p { flex: 1 1 220px; }
.panel { background: var(--white); border: var(--bw) solid var(--ink); border-radius: var(--r-big); padding: 20px; }
.lead { margin-top: 8px; color: var(--muted); font-size: 17px; max-width: 65ch; }
.category { display: inline-block; margin: 0 0 10px; padding: 4px 12px; color: var(--white); background: var(--blue); border: 2.5px solid var(--ink); border-radius: 14px; font-size: 15px; font-weight: 700; transform: rotate(-1deg); }
.source { margin-top: 8px; color: var(--muted); font-size: 15px; }
.segs { display: inline-flex; margin: 16px 0 0; border: var(--bw) solid var(--ink); border-radius: 999px; overflow: hidden; max-width: 100%; }
.seg { min-height: 48px; padding: 0 18px; background: var(--white); border: 0; font-size: 16px; font-weight: 700; }
.seg + .seg { border-left: var(--bw) solid var(--ink); }
.seg[aria-pressed="true"] { color: var(--yellow); background: var(--ink); }
.seg:focus-visible { outline-offset: -6px; box-shadow: none; }
.chip { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 4px 16px; color: var(--ink); background: var(--white); border: 2.5px solid var(--ink); border-radius: 999px; font-size: 16px; font-weight: 600; text-decoration: none; }
.chip:hover { background: var(--cream); }
.chip-n { color: var(--muted); font-size: 14px; font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin: 12px 0 0; padding: 0; }
.field { display: grid; gap: 6px; margin-top: 16px; max-width: 440px; }
.field label { font-size: 16px; font-weight: 700; }
.field input { min-height: 52px; padding: 0 14px; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 14px; font-size: 18px; }
.hint { color: var(--muted); font-size: 15px; }

/* Stickers: tilted pills. .stamp = the same thing where the older markup says "stamp". */
.sticker, .stamp { display: inline-block; padding: 3px 12px; color: var(--ink); background: var(--white); border: 2.5px solid var(--ink); border-radius: 999px; font-size: 15px; font-weight: 800; line-height: 1.3; white-space: nowrap; transform: rotate(-3deg); }
.sticker-pass, .stamp-pass { color: var(--white); background: var(--green); }
.sticker-fail, .stamp-fail { color: var(--white); background: var(--red); transform: rotate(3deg); }
.sticker-new { color: var(--yellow); background: var(--ink); transform: rotate(-2deg); }
.stamp.small { font-size: 14px; padding: 1px 10px; }
.stamp.big { padding: 6px 22px; font-size: 32px; font-weight: 900; border-width: var(--bw); box-shadow: 0 5px 0 var(--ink); transform: rotate(-5deg); }
.sticker-ready { padding: 6px 24px; color: var(--white); background: var(--green); border-width: var(--bw); font-size: 40px; font-weight: 900; box-shadow: 0 5px 0 var(--ink); transform: rotate(-5deg); }
.stamp-in { animation: slap .5s cubic-bezier(.2, 1.5, .4, 1) both; }
@keyframes slap { from { opacity: 0; transform: scale(2.2) rotate(-24deg); } 55% { opacity: 1; } to { opacity: 1; transform: scale(1) rotate(-5deg); } }

/* ---------- readiness meters ---------- */
.meters { background: var(--white); border: var(--bw) solid var(--ink); border-radius: var(--r-big); padding: 6px 16px 14px; }
.meter-list { list-style: none; margin: 0; padding: 0; }
.m { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: baseline; gap: 8px 12px; padding: 12px 0 10px; }
.m + .m { border-top: 2px dashed var(--dash); }
.m-name { font-size: 17px; font-weight: 700; overflow-wrap: anywhere; }
.m-num { font-size: 26px; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.track { grid-column: 1 / -1; position: relative; height: 18px; margin: 4px 0; background: var(--soft); border: 2px solid var(--ink); border-radius: 999px; }
.track i { position: absolute; left: 0; top: 0; bottom: 0; background: var(--muted); border-radius: 999px; }
.m-ok .track i { background: var(--blue); }
.m-short .track i { background: var(--red); }
/* The pass line: an ink bar that sticks out above and below the track, edged in white. */
.track b { position: absolute; top: -7px; bottom: -7px; width: 4px; margin-left: -2px; background: var(--ink); border-radius: 2px; box-shadow: 0 0 0 2px var(--white); }
.m-hint { grid-column: 1 / -1; color: var(--muted); font-size: 15px; }
.m-short .m-hint { color: var(--red-ink); font-weight: 700; }
.m-ok .m-hint { color: var(--ink); }
.meter-list.is-locked .m-num { color: var(--muted); letter-spacing: .1em; }
.disc-basis { margin-top: 6px; color: var(--muted); font-size: 15px; }
.disc-unlock { margin-top: 12px; }
.verdict { font-size: clamp(32px, 9.5vw, 50px); font-weight: 900; line-height: 1; letter-spacing: -.02em; overflow-wrap: break-word; hyphens: auto; }
.verdict.v-ready { padding: 10px 0 6px; }
.verdict.long { font-size: clamp(28px, 7.6vw, 44px); }
.hero-head:has(.verdict.long) .shapes { zoom: .62; }
.ready-card .verdict { margin-bottom: 14px; font-size: 32px; }
.ready-card .sticker-ready { font-size: 30px; }
.ready-card .meters { border: 0; padding: 0; }

/* ---------- home ---------- */
.hero { position: relative; margin-top: -24px; padding: 18px 0 30px; background: var(--yellow); box-shadow: 0 0 0 100vmax var(--yellow); clip-path: inset(0 -100vmax); }
.hero > .msg { margin: 0 0 14px; }
.hero-grid { display: grid; gap: 16px; }
.hero-head { display: flow-root; }
/* Floated, so long words (isiZulu, Tshivenda) drop below the shapes instead of running under them. */
.shapes { float: right; position: relative; width: 116px; height: 116px; margin: 0 0 8px 14px; }
.shapes i { position: absolute; display: block; }
.s-oct { right: 0; top: 0; width: 70px; height: 70px; background: var(--red); clip-path: polygon(29% 0, 71% 0, 100% 29%, 100% 71%, 71% 100%, 29% 100%, 0 71%, 0 29%); }
.s-disc { left: 0; top: 50px; width: 52px; height: 52px; background: var(--blue); border: 4px solid var(--ink); border-radius: 50%; }
.s-tri { right: 4px; bottom: 0; width: 60px; height: 52px; background: var(--ink); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.s-tri::after { content: ""; position: absolute; left: 15px; top: 20px; width: 30px; height: 26px; background: var(--white); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.hero .code-line { justify-content: flex-start; margin-top: 0; font-size: 15px; }
.next { display: grid; gap: 14px; align-content: start; }
.diag { font-size: 19px; font-weight: 700; line-height: 1.35; max-width: 40ch; }
.cta { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 84px; padding: 14px 14px 14px 22px; color: var(--white); background: var(--red); border: var(--bw) solid var(--ink); border-radius: var(--r-big); box-shadow: 0 6px 0 var(--ink); text-align: left; }
.cta:hover { background: #cc0027; }
.cta:active { transform: translateY(4px); box-shadow: 0 2px 0 var(--ink); }
.cta-t { display: grid; gap: 2px; min-width: 0; }
.cta-t b { font-size: 26px; font-weight: 900; line-height: 1.1; overflow-wrap: anywhere; }
.cta-t span { font-size: 16px; font-weight: 500; }
.cta-arrow { flex: none; display: grid; place-items: center; width: 56px; height: 56px; color: var(--ink); background: var(--white); border-radius: 50%; }
.cta-arrow svg { width: 26px; height: 26px; }
.cta.locked .lock { color: var(--white); }
.next .resume-no { justify-self: start; margin-top: -4px; }
/* 404.html: the Home hero's look with one way back. */
.hero.nf { display: grid; gap: 14px; padding-bottom: 44px; }
.nf-title { font-size: 26px; }
.nf .diag { max-width: 40ch; }
.nf-go { max-width: 520px; }
.nf-go .cta { text-decoration: none; }
/* Phones: verdict, the one sentence and the red action block first (above the fold at 390x844,
   also in isiZulu), then compact meters: name + score on one row, the bar below, the pass line as
   the marker only. */
@media (max-width: 599px) {
  .hero-grid .next { order: 1; }
  .hero-grid .meters { order: 2; padding: 2px 14px 10px; }
  .hero-head { margin-bottom: -4px; }
  .m { padding: 9px 0 8px; gap: 6px 10px; }
  .m-num { font-size: 22px; }
  .m .track { height: 14px; margin: 2px 0 4px; }
  .m-hint { display: none; }
  .cta { min-height: 76px; }
  .cta-t b { font-size: 24px; }
}
@media (min-width: 860px) {
  .hero { padding: 28px 0 40px; }
  .hero-grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); column-gap: 40px; align-items: start; }
  .hero-grid .meters { grid-column: 2; grid-row: 1 / 3; }
  .hero-head, .next { grid-column: 1; }
  .verdict { font-size: 56px; }
  .diag { font-size: 21px; }
}
.shelf { margin-top: 40px; }
.shelf-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; margin-bottom: 14px; }
.shelf-head h2 { font-size: 26px; }
.shelf-head p { font-size: 16px; }
.sub { margin: 26px 0 12px; font-size: 20px; }
.papers { list-style: none; display: flex; gap: 12px; margin: 0 calc(-1 * var(--gutter)); padding: 4px var(--gutter) 12px; overflow-x: auto; scroll-snap-type: x proximity; scroll-padding-inline: var(--gutter); }
.papers li { flex: 0 0 142px; scroll-snap-align: start; }
@media (min-width: 760px) {
  .papers { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); margin: 0; padding: 0; overflow: visible; }
}
.paper { position: relative; width: 100%; min-height: 156px; display: grid; align-content: start; gap: 2px; padding: 12px; text-align: left; color: var(--ink); background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 18px; }
.paper:hover { background: #fff1c2; }
.paper.is-next { background: var(--yellow); }
.paper-n { font-size: 16px; font-weight: 700; overflow-wrap: anywhere; }
.paper-score { font-size: 46px; font-weight: 900; line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.paper-score small { font-size: 17px; font-weight: 600; letter-spacing: 0; }
.paper-score.none { color: var(--muted); }
.paper .sticker { position: absolute; left: 10px; bottom: 12px; }
.tiles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 10px; }
.tile-btn { display: flex; align-items: center; gap: 14px; width: 100%; height: 100%; min-height: 76px; padding: 12px 16px; text-align: left; color: var(--ink); background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 18px; text-decoration: none; }
.tile-btn:hover { background: #fff1c2; }
.tile-txt { display: grid; gap: 2px; flex: 1; min-width: 0; }
.tile-title { font-size: 18px; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.tile-meta { color: var(--muted); font-size: 15px; }
.tile-btn.done .tile-meta { color: var(--green); font-weight: 700; }
/* Flat sign shapes beside a tile's words (never behind them). */
.tile-ico { position: relative; flex: none; width: 44px; height: 44px; }
.ico-oct { background: var(--red); clip-path: polygon(29% 0, 71% 0, 100% 29%, 100% 71%, 71% 100%, 29% 100%, 0 71%, 0 29%); }
.ico-disc { background: var(--white); border: 7px solid var(--red); border-radius: 50%; box-shadow: 0 0 0 2px var(--ink); }
.ico-tri { background: var(--red); clip-path: polygon(50% 4%, 100% 94%, 0 94%); }
.ico-tri::after { content: ""; position: absolute; left: 12px; top: 16px; width: 20px; height: 18px; background: var(--white); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.ico-dia { width: 34px; height: 34px; margin: 5px; background: var(--yellow); border: var(--bw) solid var(--ink); border-radius: 5px; transform: rotate(45deg); }
.ico-sq { background: var(--blue); border: var(--bw) solid var(--ink); border-radius: 10px; }
.ico-sq::after { content: ""; position: absolute; inset: 9px; border: 3px solid var(--white); border-radius: 50%; }
.band-blue { margin-top: 44px; padding: 10px 0 30px; color: var(--white); background: var(--blue); box-shadow: 0 0 0 100vmax var(--blue); clip-path: inset(0 -100vmax); }
.band-blue .shelf-head { margin-top: 12px; }
.band-blue .tile-btn { background: var(--white); }
.band-blue .tile-btn:hover { background: var(--cream); }
.band-blue :focus-visible { outline-color: var(--yellow); box-shadow: 0 0 0 3px var(--ink); }
.band-blue + .shelf { margin-top: 36px; }
.about { margin-top: 40px; background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 18px; }
.about summary { min-height: 52px; display: flex; align-items: center; padding: 8px 16px; font-size: 18px; font-weight: 800; cursor: pointer; }
.about-body { padding: 0 16px 18px; display: grid; gap: 10px; font-size: 16px; max-width: 65ch; }
.about-body ul { margin: 0; padding-left: 22px; }
.about-body h3 { font-size: 18px; margin-top: 6px; }

/* ---------- question parts ---------- */
.visual { display: grid; place-items: center; padding: 16px; background: var(--cream); border: var(--bw) solid var(--ink); border-radius: var(--r-big); }
.visual img { display: block; width: auto; height: 160px; object-fit: contain; }
.visual.road img, .visual.diagram img { width: 100%; max-width: 520px; height: auto; max-height: 360px; aspect-ratio: 4 / 3; }
.visual.small { justify-self: start; padding: 8px; margin: 8px 0; }
.visual.small img { height: 84px; }
.visual.small.diagram img, .visual.small.road img { height: auto; max-height: 200px; max-width: 320px; }
.visual.big img { height: 220px; }
.qtext { font-size: 21px; font-weight: 700; line-height: 1.3; max-width: 60ch; overflow-wrap: anywhere; hyphens: auto; }
.options { display: grid; gap: 10px; margin-top: 18px; max-width: 65ch; }
.option { width: 100%; display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 14px; align-items: center; min-height: 60px; padding: 8px 14px 8px 8px; text-align: left; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: var(--r); font-size: 18px; font-weight: 600; line-height: 1.35; }
.option:hover { background: var(--cream); }
.option-text { overflow-wrap: anywhere; hyphens: auto; }
.letter { display: grid; place-items: center; width: 42px; height: 42px; background: var(--cream); border: 2px solid var(--ink); border-radius: 12px; font-size: 20px; font-weight: 900; }
.option.chosen, .option.chosen:hover { color: var(--white); background: var(--blue); box-shadow: 0 5px 0 var(--ink); transform: translateY(-2px); }
.option.chosen .letter { color: var(--ink); background: var(--yellow); }
.option[aria-disabled="true"] { cursor: default; }
.option[aria-disabled="true"]:not(.chosen):not(.correct):hover { background: var(--white); }
.option.correct, .option.correct:hover { color: var(--white); background: var(--green); }
.option.wrong, .option.wrong:hover { color: var(--white); background: var(--red); }
.option.correct .letter, .option.wrong .letter { color: var(--ink); background: var(--white); }
.tick { font-size: 24px; font-weight: 900; line-height: 1; }
.keys-hint { margin-top: 14px; color: var(--muted); font-size: 15px; }
/* Keyboard keys mean nothing on a touch phone. */
@media (hover: none), (pointer: coarse), (max-width: 599px) { .keys-hint { display: none; } }

/* ---------- exam simulator ---------- */
body.in-exam .topbar, body.in-exam .site-foot, body.in-exam .lang-note { display: none; }
body.in-exam main { max-width: none; padding: 0; }
.sim { min-height: 100vh; min-height: 100dvh; display: flex; flex-direction: column; }
.sim-top { position: sticky; top: 0; z-index: 5; padding: calc(10px + env(safe-area-inset-top)) var(--gutter) 12px; background: var(--yellow); border-bottom: var(--bw) solid var(--ink); }
.sim-row, .sim-row2, .sim-top .dots, .timer-note { max-width: 1200px; margin-left: auto; margin-right: auto; }
.sim-row { display: flex; align-items: center; gap: 12px; }
.xbtn { flex: none; display: grid; place-items: center; width: 48px; height: 48px; padding: 0; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: 50%; }
.xbtn svg { width: 18px; height: 18px; }
.xbtn:hover { background: var(--cream); }
.sim-where { flex: 1; min-width: 0; display: grid; }
.sim-mode { font-size: 20px; font-weight: 900; line-height: 1.15; overflow-wrap: anywhere; }
.sim-sec { font-size: 15px; font-weight: 600; }
.timer { flex: none; padding: 9px 12px; color: var(--yellow); background: var(--ink); border-radius: 12px; }
.timer strong { font-size: 18px; font-weight: 800; font-variant-numeric: tabular-nums; }
.timer.low { color: var(--white); background: var(--red); border: 2px solid var(--ink); }
.dots { display: flex; gap: 4px; margin-top: 12px; }
.dots.many { gap: 2px; }
.dots i { flex: 1; height: 12px; background: rgba(20, 20, 20, .18); border-radius: 999px; }
.dots i.d { background: var(--ink); }
.dots i.f { background: var(--blue); }
.dots i.c { background: var(--red); }
.dots i.ok { background: var(--green); }
.dots i.no { background: var(--red); }
.sim-row2 { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 12px; margin-top: 8px; font-size: 16px; }
.sim-count { font-weight: 800; }
.sim-answered { font-weight: 600; }
.timer-note { margin-top: 2px; color: var(--muted); font-size: 14px; }
.sim-main { flex: 1; width: 100%; max-width: 1200px; margin: 0 auto; padding: 20px var(--gutter) 28px; display: grid; gap: 24px; align-content: start; }
.sim-body { display: grid; gap: 18px; align-content: start; }
.qgrid { display: none; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 18px; padding: 14px; }
.qgrid.qgrid-sheet { display: block; max-width: 1200px; margin: 0 auto 12px; max-height: 55vh; overflow-y: auto; background: var(--cream); }
.qgrid-legend { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 15px; }
.qgrid-legend span { display: inline-flex; align-items: center; gap: 6px; }
.qgrid-legend .sq { width: 16px; height: 16px; min-height: 0; padding: 0; border-radius: 4px; }
.qgrid-sec h3 { margin: 14px 0 8px; font-size: 16px; font-weight: 800; }
.squares { display: grid; grid-template-columns: repeat(auto-fill, minmax(46px, 1fr)); gap: 6px; }
.sq { position: relative; display: grid; place-items: center; min-height: 48px; padding: 0; color: var(--ink); background: var(--white); border: 2px solid var(--ink); border-radius: 10px; font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
i.sq { display: inline-block; }
.sq.answered { color: var(--yellow); background: var(--ink); }
.sq.flagged::after { content: ""; position: absolute; top: -2px; right: -2px; border-style: solid; border-width: 0 16px 16px 0; border-color: transparent var(--blue) transparent transparent; border-top-right-radius: 10px; }
.sq.current { outline: 3px solid var(--red); outline-offset: 2px; }
.sim-foot { position: sticky; bottom: 0; z-index: 5; padding: 12px var(--gutter) calc(12px + env(safe-area-inset-bottom)); background: var(--white); border-top: var(--bw) solid var(--ink); }
.sim-actions, .sim-actions2, .sim-foot .confirm { max-width: 1200px; margin: 0 auto; }
.sim-actions { display: grid; grid-template-columns: 1fr 1fr 1.4fr; gap: 10px; }
.sim-actions .btn { min-height: 56px; padding: 6px 10px; }
.sim-actions .btn.primary { font-size: 20px; font-weight: 900; }
.sim-actions2 { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-top: 6px; }
.btn.flag.on { color: var(--white); background: var(--blue); }
.confirm { margin-bottom: 12px; padding: 16px; background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 18px; }
.confirm > p:first-child { font-size: 20px; font-weight: 800; line-height: 1.25; }
.confirm .muted { margin-top: 4px; font-size: 16px; }
.confirm .row { margin-top: 14px; }
@media (min-width: 960px) {
  .sim-main { grid-template-columns: minmax(0, 1fr) 320px; }
  .sim-body.has-visual { grid-template-columns: minmax(240px, 38%) minmax(0, 1fr); gap: 32px; }
  .sim-body .visual img { height: 220px; }
  .qgrid { display: block; position: sticky; top: 150px; align-self: start; max-height: calc(100vh - 260px); overflow-y: auto; }
  .nav-toggle { visibility: hidden; }
  .qgrid.qgrid-sheet { display: none; }
  .qtext { font-size: 22px; }
}

/* ---------- drills ---------- */
.drill { max-width: 820px; margin: 0 auto; }
.drill-top { display: flex; flex-wrap: wrap; gap: 4px 16px; align-items: baseline; }
.drill-mode { flex: 1 1 100%; font-size: 24px; font-weight: 900; line-height: 1.15; overflow-wrap: anywhere; }
.drill-count { font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
.drill-score { margin-left: auto; padding: 2px 12px; color: var(--yellow); background: var(--ink); border-radius: 999px; font-size: 15px; font-weight: 700; font-variant-numeric: tabular-nums; }
.drill > .dots { margin: 12px 0 18px; }
.drill > .dots i { background: var(--soft); border: 1.5px solid var(--ink); height: 14px; }
.drill > .dots i.d { background: var(--ink); }
.drill > .dots i.ok { background: var(--green); }
.drill > .dots i.no { background: var(--red); }
.qtimer { --left: 1; display: flex; align-items: center; gap: 12px; margin: -6px 0 16px; }
.qtimer i { flex: 1; position: relative; height: 16px; background: var(--soft); border: 2px solid var(--ink); border-radius: 999px; overflow: hidden; }
.qtimer i::after { content: ""; position: absolute; inset: 0; background: var(--red); transform-origin: left; transform: scaleX(var(--left)); }
.qtimer span { min-width: 2ch; text-align: right; font-size: 24px; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.drill-body { display: grid; gap: 18px; }
@media (min-width: 760px) { .drill-body.has-visual { grid-template-columns: minmax(200px, 36%) minmax(0, 1fr); align-items: start; gap: 24px; } }
.explain { margin-top: 18px; padding: 0 16px 16px; display: grid; gap: 8px; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 18px; overflow: hidden; font-size: 17px; animation: slide .22s ease-out both; }
.explain h3 { margin: 0 -16px 4px; padding: 10px 16px; color: var(--white); background: var(--green); border-bottom: var(--bw) solid var(--ink); font-size: 22px; font-weight: 900; }
.explain.is-wrong h3 { background: var(--red); }
@keyframes slide { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.drill-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 22px; }
.drill-actions .btn.primary { min-width: 170px; min-height: 60px; font-size: 22px; font-weight: 900; }

/* ---------- result ---------- */
/* minmax(0, 1fr): the one column never grows to a child's min-content width (a wide slip table
   would otherwise push the card past the screen on a phone). */
.result { max-width: 860px; margin: 0 auto; display: grid; grid-template-columns: minmax(0, 1fr); gap: 18px; }
.result > .msg { margin: 0; }
.slip-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; padding-bottom: 14px; border-bottom: 2px dashed var(--dash); }
.slip-head h2 { font-size: 30px; }
.slip-head .muted { margin-top: 4px; font-size: 16px; }
.slip-total { display: grid; justify-items: start; }
.slip-total strong { font-size: 46px; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.slip-total span { color: var(--muted); font-size: 15px; }
.table-wrap { overflow-x: auto; }
.slip-table { width: 100%; border-collapse: collapse; margin-top: 8px; }
.slip-table th, .slip-table td { padding: 14px 8px; border-bottom: 2px dashed var(--dash); text-align: left; vertical-align: middle; }
.slip-table thead th { color: var(--muted); font-size: 14px; font-weight: 700; padding-top: 4px; }
.slip-table tbody th { font-size: 16px; font-weight: 700; }
.slip-table .num { font-size: 22px; font-weight: 800; white-space: nowrap; font-variant-numeric: tabular-nums; }
.slip-table tbody th { overflow-wrap: anywhere; hyphens: auto; }
/* Phones: the slip fits a 360 px screen in every language: tighter cells, smaller numbers and
   stickers; a long section name or column heading wraps (even mid-word) instead of pushing the
   Result column off the card. */
@media (max-width: 599px) {
  .panel.result { padding: 16px 12px; }
  .slip-head h2 { font-size: 26px; }
  .slip-table { table-layout: fixed; }
  .slip-table th, .slip-table td { padding: 10px 3px; }
  .slip-table thead th:nth-child(2), .slip-table thead th:nth-child(3) { width: 18%; }
  .slip-table thead th:nth-child(4) { width: 36%; }
  .slip-table thead th { font-size: 13px; overflow-wrap: anywhere; }
  .slip-table tbody th { font-size: 15px; }
  .slip-table thead th { font-size: 12px; }
  .slip-table .num { font-size: 16px; letter-spacing: -.01em; }
  .slip-table .stamp { max-width: 100%; font-size: 12px; padding: 1px 6px; border-width: 2px; white-space: normal; overflow-wrap: anywhere; text-align: center; }
  .slip-overall { padding: 14px 12px; gap: 12px; }
  .stamp.big { font-size: 26px; padding: 4px 16px; }
  .review-item { padding: 12px; }
}
.review-item h4, .review-item p { overflow-wrap: anywhere; }
.slip-overall { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 18px; margin-top: 18px; padding: 16px; background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 18px; }
.slip-overall > div { flex: 1 1 240px; }
.overall-label { font-size: 22px; font-weight: 900; }
.overall-copy { margin-top: 4px; font-size: 16px; }
.drill-result { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; }
.big-score { display: grid; gap: 2px; padding: 14px 22px; background: var(--yellow); border: var(--bw) solid var(--ink); border-radius: 18px; box-shadow: 0 5px 0 var(--ink); transform: rotate(-2deg); }
.big-score strong { font-size: 50px; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.big-score span { font-size: 15px; font-weight: 600; }
.drill-result > div:last-child { flex: 1 1 260px; display: grid; gap: 8px; }
/* One row per section: the name wraps in its own column, the score keeps a fixed right column. */
.mini-secs { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 6px; max-width: 420px; font-size: 16px; }
.mini-secs li { display: grid; grid-template-columns: minmax(0, 1fr) 3.4em; gap: 12px; align-items: baseline; }
.mini-secs strong { text-align: right; font-variant-numeric: tabular-nums; }
/* Topic pills: left-aligned; a long topic name wraps inside the pill, the count never splits. */
.study-chips .chip { max-width: 100%; justify-content: flex-start; text-align: left; line-height: 1.25; padding-block: 6px; border-radius: 24px; }
.chip-name { min-width: 0; }
.chip-n { flex: none; white-space: nowrap; }
.chip-more { color: var(--blue); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }
.result > .row { margin: 0; }
.save-note { color: var(--muted); font-size: 15px; }
.study h3 { font-size: 20px; }
.review { display: grid; gap: 12px; }
.review > h3 { margin-top: 8px; font-size: 22px; }
.review-item { padding: 14px 16px; display: grid; gap: 6px; background: var(--white); border: var(--bw) solid var(--ink); border-left-width: 10px; border-left-color: var(--red); border-radius: 16px; font-size: 16px; }
.review-item h4 { font-size: 18px; font-weight: 700; line-height: 1.35; }
.review-item .category { margin: 0; justify-self: start; }
.ans.wrong b { color: var(--red-ink); }
.ans.right b { color: var(--green); }
.sources { color: var(--muted); font-size: 14px; }

/* ---------- progress ---------- */
.progress-view { max-width: 960px; margin: 0 auto; }
.progress-view > h2 { margin: 40px 0 8px; }
.progress-view > .panel { margin-top: 16px; }
.stats { list-style: none; margin: 16px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; }
@media (min-width: 640px) { .stats { grid-template-columns: repeat(4, 1fr); } }
.stats li { display: grid; gap: 2px; padding: 12px 14px; background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 16px; }
.stats strong { font-size: 28px; font-weight: 900; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stats span { font-size: 15px; font-weight: 600; }
.chart { margin: 10px 0 0; padding: 14px; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 18px; }
/* The chart's drawing is scaled to the box (js/progress.js picks a coordinate box per width). */
.chart svg { display: block; width: 100%; max-width: 100%; height: auto; overflow: hidden; }
.chart-grid { stroke: var(--dash); stroke-width: 1.5; }
.chart-target { stroke: var(--green); stroke-width: 3; stroke-dasharray: 10 6; }
.chart-line { fill: none; stroke: var(--ink); stroke-width: 3.5; stroke-linejoin: round; }
.chart-dot { fill: var(--white); stroke: var(--ink); stroke-width: 3; }
.chart-dot.full { fill: var(--blue); }
.chart-label { fill: var(--muted); font: 500 18px var(--f); }
.chart-label.strong { fill: var(--green); font-weight: 800; }
.chart figcaption { margin-top: 8px; font-size: 15px; display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.dot-key { display: inline-block; width: 12px; height: 12px; margin-left: 8px; background: var(--white); border: 3px solid var(--ink); border-radius: 50%; }
.dot-key.full { background: var(--blue); }
.topic-map { display: grid; gap: 22px; margin-top: 14px; }
.tm-sec h4 { margin-bottom: 10px; font-size: 20px; }
.tm-sec h4 .muted { font-size: 15px; font-weight: 600; }
.tm-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 150px), 1fr)); gap: 8px; }
.tm-tile { width: 100%; height: 100%; min-height: 76px; display: grid; align-content: space-between; gap: 4px; padding: 10px 12px; text-align: left; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: 14px; }
.tm-name { font-size: 15px; font-weight: 700; line-height: 1.3; overflow-wrap: anywhere; }
.tm-val { font-size: 22px; font-weight: 900; line-height: 1; font-variant-numeric: tabular-nums; }
.lv-new { border-style: dashed; }
.lv-new .tm-val { font-size: 15px; font-weight: 600; color: var(--muted); }
.lv-weak { color: var(--white); background: var(--red); }
.lv-mid { background: var(--yellow); }
.lv-strong { color: var(--white); background: var(--green); }
.tm-tile.lv-new:hover { background: var(--cream); }
.tm-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 15px; }
.tm-legend .lg { display: inline-block; width: 16px; height: 16px; margin-left: 6px; border: 2px solid var(--ink); border-radius: 4px; }
.paper-strip { list-style: none; margin: 12px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.ps { display: grid; place-items: center; width: 56px; min-height: 64px; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: 12px; }
.ps strong { font-size: 22px; font-weight: 900; line-height: 1; }
.ps span { font-size: 14px; font-weight: 600; }
.ps.is-pass { color: var(--white); background: var(--green); }
.ps.is-fail { color: var(--white); background: var(--red); }
.history { margin-top: 40px; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 18px; }
.history summary { min-height: 52px; display: flex; align-items: center; padding: 8px 16px; font-size: 20px; font-weight: 900; cursor: pointer; }
.attempts { list-style: none; margin: 0; padding: 0 16px 12px; }
.attempt { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: 2px 12px; align-items: center; padding: 12px 0; border-top: 2px dashed var(--dash); font-size: 16px; }
.a-mode { font-weight: 700; }
.a-when { grid-column: 1; grid-row: 2; font-size: 14px; }
.a-score { grid-row: 1 / 3; grid-column: 2; font-size: 22px; font-weight: 900; font-variant-numeric: tabular-nums; }
.attempt > :last-child { grid-row: 1 / 3; grid-column: 3; min-width: 48px; }
.device-zone { margin-top: 40px; }
.device-zone h3 { margin-bottom: 4px; }

/* ---------- study ---------- */
.library { max-width: 1080px; margin: 0 auto; }
.library > .lead { margin-top: 12px; }
.lib-count { margin-top: 12px; font-size: 15px; }
.lib-jump { display: flex; gap: 8px; overflow-x: auto; padding: 12px 2px 6px; }
.lib-jump .chip { flex: 0 0 auto; }
.lib-group { margin-top: 30px; scroll-margin-top: 12px; }
.lib-group h2 { font-size: 22px; margin-bottom: 12px; }
.lib-n { font-size: 15px; font-weight: 600; }
.lib-grid { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(122px, 1fr)); gap: 10px; }
.lib-card { width: 100%; height: 100%; display: grid; align-content: start; gap: 6px; padding: 8px 8px 10px; text-align: left; color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-radius: 16px; }
.lib-card:hover { background: var(--cream); }
.lib-img { display: grid; place-items: center; height: 88px; padding: 6px; background: var(--cream); border-radius: 10px; }
.lib-img img { height: 74px; width: auto; max-width: 100%; object-fit: contain; }
.lib-code { font-size: 16px; font-weight: 900; line-height: 1; }
/* Short names (js/library.js) shown whole: never clamped, never cut mid-word. */
.lib-name { font-size: 15px; line-height: 1.3; overflow-wrap: break-word; hyphens: auto; }
.sign-full { margin-top: -6px; }
.sign-detail { margin-top: 14px; display: grid; gap: 14px; max-width: 760px; }
.sign-detail h1 { font-size: 28px; overflow-wrap: anywhere; }
.sign-detail .category { justify-self: start; margin: 0; }
.diagrams { list-style: none; margin: 18px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 14px; }
.diagrams .panel { display: grid; gap: 12px; align-content: start; }
.diagrams h2 { font-size: 20px; }
.privacy { margin-top: 16px; padding: 12px 14px; background: var(--cream); border: var(--bw) solid var(--ink); border-left-width: 10px; border-left-color: var(--blue); border-radius: 14px; font-size: 16px; }
.account { max-width: 720px; margin: 0 auto; }
.danger-zone { margin-top: 30px; padding-top: 18px; border-top: 2px dashed var(--dash); }
.danger-zone h2 { font-size: 20px; }

@media (min-width: 760px) {
  h1 { font-size: 40px; }
  .progress-view > h1, .library > h1, .account h1, .code-pick h1 { font-size: 40px; }
  h2 { font-size: 26px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .option.chosen { transform: none; }
}

/* ---------- licence code ---------- */
.code-line { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0 8px; margin-top: 12px; font-size: 16px; }
.code-tag { display: inline-block; padding: 0 8px; color: var(--ink); background: var(--white); border: 2px solid var(--ink); border-radius: 999px; font-size: 14px; font-weight: 700; line-height: 1.5; white-space: nowrap; vertical-align: middle; }
.code-pick { max-width: 720px; margin: 0 auto; }
.code-list { list-style: none; margin: 22px 0 0; padding: 0; display: grid; gap: 12px; }
.code-btn { width: 100%; display: grid; gap: 4px; min-height: 84px; padding: 14px 18px; text-align: left; color: var(--ink); background: var(--cream); border: var(--bw) solid var(--ink); border-radius: 18px; }
.code-btn:hover { background: #fff1c2; }
.code-btn.on { color: var(--white); background: var(--blue); box-shadow: 0 5px 0 var(--ink); }
.code-main { font-size: 26px; font-weight: 900; line-height: 1.1; overflow-wrap: anywhere; }
.code-sub { font-size: 16px; }
.small-print { margin-top: 16px; font-size: 15px; }
.acc-code { margin-top: 30px; padding-top: 18px; border-top: 2px dashed var(--dash); }
.acc-code h2 { font-size: 20px; }
.acc-code .code-line { justify-content: flex-start; }

/* ---------- K53 Pass Plus: locked items (paywall off: none of this renders) ---------- */
.lock { display: inline-flex; align-items: center; gap: 4px; margin-left: 6px; padding: 0 8px; color: var(--yellow); background: var(--ink); border-radius: 999px; font-size: 14px; font-weight: 700; vertical-align: middle; white-space: nowrap; }
.lock-ico { width: 12px; height: 12px; fill: currentColor; stroke: currentColor; stroke-width: 1.6; }
.lock-ico path { fill: none; }
.lock.icon-only { margin: 0; padding: 3px; background: transparent; color: currentColor; }
.btn .lock.icon-only .lock-ico, .chip .lock.icon-only .lock-ico { width: 14px; height: 14px; }
.tile-btn.locked, .paper.locked, .tm-tile.locked, .ps.locked { color: var(--ink); background: #f2f2f2; border-style: dashed; }
.tile-btn.locked .tile-txt, .paper.locked > :not(.lock), .tm-tile.locked > span, .ps.locked > * { opacity: .7; }
.paper.locked .lock.icon-only { position: absolute; right: 10px; bottom: 10px; color: var(--ink); }
.paper.locked .lock-ico { width: 16px; height: 16px; }
.btn.locked { opacity: .8; }
.linkbtn { padding: 0; min-height: 48px; background: none; border: 0; color: var(--blue); font-size: 16px; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.pass-line { margin-top: 20px; padding: 16px; background: var(--yellow); border: var(--bw) solid var(--ink); border-radius: 18px; }
.pass-line h2 { font-size: 22px; }
.pass-line p { margin-top: 4px; }
.pass-line .muted { color: var(--ink); }
.pass-line .btn { margin-top: 12px; }
.pass-line.is-active { background: var(--white); border-left-width: 10px; border-left-color: var(--green); }

/* The one paywall sheet: a bottom sheet on phones, a centred card on wide screens. */
body.sheet-open { overflow: hidden; }
.sheet-wrap { position: fixed; inset: 0; z-index: 50; display: flex; align-items: flex-end; justify-content: center; }
.sheet-backdrop { position: absolute; inset: 0; background: rgba(20, 20, 20, .62); }
.sheet { position: relative; width: 100%; max-width: 520px; max-height: calc(100vh - 24px); overflow-y: auto; padding: 24px var(--gutter) calc(22px + env(safe-area-inset-bottom)); color: var(--ink); background: var(--white); border: var(--bw) solid var(--ink); border-bottom: 0; border-radius: 24px 24px 0 0; }
.sheet h2 { font-size: 28px; outline: none; }
.sheet-kicker { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 10px; padding: 3px 12px; color: var(--yellow); background: var(--ink); border-radius: 999px; font-size: 15px; font-weight: 800; transform: rotate(-2deg); }
.sheet-note { margin-top: 10px; font-size: 16px; }
.sheet-list { margin: 16px 0 0; padding: 0; list-style: none; display: grid; gap: 10px; }
.sheet-list li { position: relative; padding-left: 32px; font-size: 17px; }
.sheet-list li::before { content: ""; position: absolute; left: 0; top: .1em; width: 22px; height: 22px; background: var(--green); border: 2px solid var(--ink); border-radius: 50%; }
.sheet-list li::after { content: ""; position: absolute; left: 7px; top: calc(.1em + 5px); width: 8px; height: 5px; border-left: 3px solid var(--white); border-bottom: 3px solid var(--white); transform: rotate(-45deg); }
.sheet-price { margin-top: 18px; padding: 12px 14px; background: var(--yellow); border: var(--bw) solid var(--ink); border-radius: 14px; font-size: 22px; font-weight: 900; line-height: 1.25; }
.sheet-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.sheet-actions .btn.primary { flex: 1 1 200px; }
.sheet-small { margin-top: 12px; font-size: 15px; }
.sheet .field { max-width: none; }
@media (min-width: 640px) {
  .sheet-wrap { align-items: center; }
  .sheet { border-bottom: var(--bw) solid var(--ink); border-radius: 24px; padding: 28px; box-shadow: 0 8px 0 var(--ink); }
}

/* ---------- Offline pack ---------- */
.tiles .pack-li.open { grid-column: 1 / -1; }
.pack-li.open > .tile-btn { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.pack { padding: 16px; background: var(--white); border: var(--bw) solid var(--ink); border-radius: 18px; }
.pack.compact { border-top: 0; border-radius: 0 0 18px 18px; }
.pack.compact .pack-title { display: none; }
.pack-title { font-size: 20px; margin-bottom: 6px; }
.pack p + p { margin-top: 6px; }
.pack .row { margin-top: 12px; }
.pack-bar { height: 18px; margin: 4px 0 10px; background: var(--soft); border: 2px solid var(--ink); border-radius: 999px; overflow: hidden; }
.pack-bar i { display: block; height: 100%; background: var(--blue); transition: width .2s linear; }
.pack-ok { color: var(--green); font-weight: 700; }
.acc-pack { margin-top: 22px; }

/* ---------- privacy ---------- */
.site-foot a { color: var(--yellow); }
.privacy-page { max-width: 720px; margin: 0 auto; }
.privacy-page h2 { margin-top: 22px; font-size: 20px; }
.privacy-page p { margin-top: 6px; max-width: 65ch; }
