/* 公民考试中文题库 — design system “闯关”.
   Jade green is the brand, sunny yellow is THE primary action (and the dress of 小玛, the mascot), red means wrong or
   danger and nothing else. Big radii, chunky controls with a solid darker bottom edge that goes down when pressed,
   thick progress bars, solid colour tiles with white text. The hexagon is the motif: goal ring, option letters,
   theme icons, active tab, bullets. Reuse what is listed here before inventing anything.

   TOKENS (light on :root, dark in the two blocks right under it — always define a new one three times)
     --bg --card --soft --line          ground, raised surface, neutral fill / track, edge
     --ink --ink2                       text, secondary text
     --g --g-d --g-l --g-t              brand green: fill, its bottom edge, soft tint, green as TEXT on --bg/--card
     --sun --sun-d --on-sun             primary action yellow, its edge, text on it
     --red --red-d --red-l --red-t      wrong / danger: fill, edge, soft tint, red as text
     --ok-panel --bad-panel             the two feedback panels (dark enough for white body text)
     --warm --warm-l --warm-t           "estimate / not yet" orange: fill, tint, text
     --water                            rivers and seas on the map
     --t-principes --t-institutions --t-droits --t-histoire --t-societe   the five theme colours (+ -d edge, + -l tint)
     --f-zh --f-disp --f-lat            Chinese system stack, Fredoka (numerals, display), Nunito (French)
     --r-s --r --r-l                    radii 12 / 18 / 24
     --tabs-h, --dock-h                 height of the tab bar; height of the quiz dock (set by app.js)
   A theme's colour on any element: class .t-<id> (sets --c, --cd, --cl) or style="--c:…;--cd:…".

   COMPONENTS
     .btn                    chunky button, yellow by default. .ghost secondary, .quiet neutral, .danger red,
                             .white for coloured panels; sizes .sm .lg; .wide full width; [disabled]
     .sq                     44px square icon button (back, close, previous)
     .link                   inline text action
     .card                   neutral raised surface.  .tile solid colour tile (--c/--cd), white text.
     .stat                   stat tile: .lab, .num (b + span), .bar, .cap
     .bar                    progress bar (i = fill). .ok green, .warm orange, .on-c on a colour tile; .pass = pass mark
     .hexring                hexagon progress ring (hexRing() in app.js);  .hexic hexagon badge (hexBadge())
     .six                    小玛, the mascot (six(mood, size, cls, opt) in app.js; .six.mini is her head alone); add .bob to make it float
     .tag                    small label. .g green, .hot yellow, .warm orange, .red.  .chip tappable pill ([aria-pressed])
     .seg                    segmented switch (buttons with aria-pressed, or links with aria-current)
     .list > .lrow           rows for navigation lists (icon, .grow text with .t1/.t2, trailing)
     .qlist .qrow .crow .words .split .rules .centres   long lists inside a rounded card
     .field  input  .msg     form field with its button, message line (.ok / .bad)
     .veil > .sheet          bottom sheet / modal
     .topbar                 sub-page bar: back + title (+ slot).  .pagehead: tab root title (+ slot)
     .qbar                   quiz / exam bar: back, thick progress, position
     .tabs                   bottom tab bar (five items, hexagon behind the active one)
     .dock                   fixed bottom bar of the quiz; .dock.fb.good / .miss = the feedback panel
     .copy                   the explanation (inside the panel, or inline as a card: .good .miss .plain)
     .tw  .tw-pop            tappable French word and its note
     #oops                   error notice
     .note                   callout (.blue info, .warn)
     .pay  .buy              compact offer block, price button with its terms
     table.cmp               free vs unlocked
     details.disc            disclosure row
     .hero                   green headline card (.plain = white)
     .say                    speech bubble next to 小玛
     print                   only the cram sheet (.sheetpage) is laid out for paper
*/
:root {
  --bg: #EEF4F0; --card: #FFFFFF; --soft: #E2ECE6; --line: #D2E1D9;
  --ink: #10302A; --ink2: #4E6860;
  --g: #00A66C; --g-d: #007D51; --g-l: #DDF4E8; --g-t: #007A4F;
  --sun: #FFC933; --sun-d: #DE9A00; --on-sun: #10302A;
  --red: #EE443F; --red-d: #BF2A27; --red-l: #FFE7E4; --red-t: #B92A26;
  --ok-panel: #00875A; --bad-panel: #D4352F;
  --warm: #E87512; --warm-l: #FFEBD3; --warm-t: #A84F00;
  --water: #1A78CF;
  --t-principes: #E5483D; --t-principes-d: #B83329; --t-principes-l: #FFE5E1;
  --t-institutions: #7657EE; --t-institutions-d: #573CC9; --t-institutions-l: #ECE6FF;
  --t-droits: #197BD6; --t-droits-d: #115FAA; --t-droits-l: #DDEEFF;
  --t-histoire: #D06200; --t-histoire-d: #A34B00; --t-histoire-l: #FFE9D2;
  --t-societe: #D93A82; --t-societe-d: #AE2565; --t-societe-l: #FFE3F0;
  --pop: #10302A; --on-pop: #FFFFFF;
  --veil: rgba(10, 32, 26, .55);
  --f-zh: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Source Han Sans SC", "Microsoft YaHei", "Segoe UI", sans-serif;
  --f-disp: "Fredoka", ui-rounded, "Arial Rounded MT Bold", "Nunito", var(--f-zh);
  --f-lat: "Nunito", ui-rounded, "Arial Rounded MT Bold", "Fredoka", var(--f-zh);
  --r-s: 12px; --r: 18px; --r-l: 24px;
  --tabs-h: 64px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0B1915; --card: #14261F; --soft: #213A30; --line: #2A463B;
    --ink: #E8F3EE; --ink2: #A3BBB1;
    --g: #0A8F60; --g-d: #066644; --g-l: #153C2E; --g-t: #5AD9A6;
    --sun: #FFC933; --sun-d: #B97F00; --on-sun: #10302A;
    --red: #D9423D; --red-d: #A12C28; --red-l: #44201D; --red-t: #FF9A93;
    --ok-panel: #0B7A54; --bad-panel: #B5322D;
    --warm: #D96D10; --warm-l: #47300F; --warm-t: #FFB56B;
    --water: #6DB5F5;
    --t-principes: #CF4036; --t-principes-d: #9C2B23; --t-principes-l: #4A211D;
    --t-institutions: #6A4EDB; --t-institutions-d: #4B34B0; --t-institutions-l: #2D2558;
    --t-droits: #166FC2; --t-droits-d: #0E5294; --t-droits-l: #15324F;
    --t-histoire: #BC5900; --t-histoire-d: #8C4200; --t-histoire-l: #472C10;
    --t-societe: #C53476; --t-societe-d: #98225A; --t-societe-l: #48203A;
    --pop: #2C4D41; --on-pop: #FFFFFF;
    --veil: rgba(0, 0, 0, .66);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0B1915; --card: #14261F; --soft: #213A30; --line: #2A463B;
  --ink: #E8F3EE; --ink2: #A3BBB1;
  --g: #0A8F60; --g-d: #066644; --g-l: #153C2E; --g-t: #5AD9A6;
  --sun: #FFC933; --sun-d: #B97F00; --on-sun: #10302A;
  --red: #D9423D; --red-d: #A12C28; --red-l: #44201D; --red-t: #FF9A93;
  --ok-panel: #0B7A54; --bad-panel: #B5322D;
  --warm: #D96D10; --warm-l: #47300F; --warm-t: #FFB56B;
  --water: #6DB5F5;
  --t-principes: #CF4036; --t-principes-d: #9C2B23; --t-principes-l: #4A211D;
  --t-institutions: #6A4EDB; --t-institutions-d: #4B34B0; --t-institutions-l: #2D2558;
  --t-droits: #166FC2; --t-droits-d: #0E5294; --t-droits-l: #15324F;
  --t-histoire: #BC5900; --t-histoire-d: #8C4200; --t-histoire-l: #472C10;
  --t-societe: #C53476; --t-societe-d: #98225A; --t-societe-l: #48203A;
  --pop: #2C4D41; --on-pop: #FFFFFF;
  --veil: rgba(0, 0, 0, .66);
  color-scheme: dark;
}
.t-principes { --c: var(--t-principes); --cd: var(--t-principes-d); --cl: var(--t-principes-l); }
.t-institutions { --c: var(--t-institutions); --cd: var(--t-institutions-d); --cl: var(--t-institutions-l); }
.t-droits { --c: var(--t-droits); --cd: var(--t-droits-d); --cl: var(--t-droits-l); }
.t-histoire { --c: var(--t-histoire); --cd: var(--t-histoire-d); --cl: var(--t-histoire-l); }
.t-societe { --c: var(--t-societe); --cd: var(--t-societe-d); --cl: var(--t-societe-l); }
.t-brand { --c: var(--g); --cd: var(--g-d); --cl: var(--g-l); }

/* ================================================================ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding: 76px 0 calc(var(--dock-h, 0px) + 16px); }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font-family: var(--f-zh); font-size: 16px; line-height: 1.6;
  -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent;
}
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--bg); }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
h1 { font-size: 24px; font-weight: 800; line-height: 1.25; letter-spacing: .02em; }
h2 { font-size: 18px; font-weight: 800; line-height: 1.35; text-wrap: balance; }
h3 { font-size: 16px; font-weight: 800; line-height: 1.4; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; padding: 0; text-align: inherit; }
a { color: var(--g-t); text-underline-offset: 3px; }
svg { flex: none; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; border-radius: 8px; }
[lang="fr"] { font-family: var(--f-lat); }
.num { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-weight: 600; }
.sub { color: var(--ink2); font-size: 14px; }
.small { font-size: 13px; color: var(--ink2); line-height: 1.6; }
.small a { color: var(--g-t); }
.center { text-align: center; }
.hr { height: 2px; border-radius: 2px; background: var(--line); border: 0; margin: 0; }

/* ================================================================ layout */
.wrap {
  max-width: 580px; margin: 0 auto; min-width: 0;
  padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  padding-block: 10px calc(var(--tabs-h) + 30px);
  display: flex; flex-direction: column; gap: 18px;
}
.wrap.bare { padding-block: 0 calc(var(--dock-h, 96px) + 28px); gap: 14px; }
.stack { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.stack.tight { gap: 6px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.row.between { justify-content: space-between; }
.grow { flex: 1 1 0; min-width: 0; }

/* ================================================================ buttons */
.btn {
  --b: var(--sun); --bd: var(--sun-d); --bt: var(--on-sun);
  position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 8px 20px; margin-bottom: 5px; border-radius: var(--r);
  background: var(--b); color: var(--bt); box-shadow: 0 5px 0 var(--bd);
  font-size: 17px; font-weight: 800; line-height: 1.25; letter-spacing: .04em; text-align: center; text-decoration: none;
}
.btn::before { content: ""; position: absolute; left: 14px; right: 14px; top: 5px; height: 5px; border-radius: 5px; background: rgba(255, 255, 255, .36); pointer-events: none; }
.btn svg { width: 20px; height: 20px; }
.btn .n, .btn .buy-p { font-family: var(--f-disp); font-weight: 700; letter-spacing: 0; }
.btn.ghost { --b: var(--card); --bd: var(--line); --bt: var(--g-t); box-shadow: 0 0 0 2px var(--line) inset, 0 5px 0 var(--bd); }
.btn.quiet { --b: var(--soft); --bd: var(--line); --bt: var(--ink); }
.btn.danger { --b: var(--red); --bd: var(--red-d); --bt: #fff; }
.btn.white { --b: #fff; --bd: rgba(0, 0, 0, .28); --bt: var(--ink); }
.btn.ghost::before, .btn.quiet::before, .btn.white::before, .btn.danger::before { display: none; }
.btn.wide { display: flex; width: 100%; }
.btn.sm { min-height: 40px; padding: 5px 14px; font-size: 14.5px; border-radius: 13px; box-shadow: 0 4px 0 var(--bd); margin-bottom: 4px; }
.btn.sm.ghost { box-shadow: 0 0 0 2px var(--line) inset, 0 4px 0 var(--bd); }
.btn.sm::before { display: none; }
.btn.lg { min-height: 60px; font-size: 19px; border-radius: 20px; }
.btn:active:not([disabled]) { transform: translateY(3px); box-shadow: 0 2px 0 var(--bd); }
.btn.ghost:active:not([disabled]) { box-shadow: 0 0 0 2px var(--line) inset, 0 2px 0 var(--bd); }
.btn[disabled] { --b: var(--soft); --bd: var(--line); --bt: var(--ink2); cursor: default; }
.btn[disabled]::before { display: none; }
.link { color: var(--g-t); font-weight: 700; font-size: 14px; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }
.sq {
  width: 44px; height: 44px; flex: none; display: grid; place-items: center; border-radius: 14px;
  background: var(--card); color: var(--ink); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); margin-bottom: 3px;
}
.sq svg { width: 20px; height: 20px; }
.sq:active:not([disabled]) { transform: translateY(2px); box-shadow: 0 1px 0 var(--line); }
.sq[disabled] { opacity: .4; cursor: default; }

/* ================================================================ cards, tiles, stats */
.card { background: var(--card); border: 2px solid var(--line); border-radius: var(--r-l); box-shadow: 0 3px 0 var(--line); padding: 14px 16px; min-width: 0; }
.tile {
  position: relative; overflow: hidden; display: block; min-width: 0; border-radius: var(--r-l); padding: 12px 14px 14px; margin-bottom: 5px;
  background: var(--c, var(--g)); color: #fff; box-shadow: 0 5px 0 var(--cd, var(--g-d)); text-decoration: none;
}
button.tile:active, a.tile:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--cd, var(--g-d)); }
.tile > .deco { position: absolute; right: -18px; top: -18px; width: 74px; height: 74px; color: #fff; opacity: .15; pointer-events: none; }
.tile .n { position: relative; display: flex; align-items: baseline; gap: 4px; }
.tile .n b { font-family: var(--f-disp); font-weight: 700; font-size: 44px; line-height: 1.1; text-shadow: 0 3px 0 rgba(0, 0, 0, .14); }
.tile .n span { font-size: 16px; font-weight: 800; }
.tile p { position: relative; font-size: 15px; font-weight: 700; line-height: 1.35; }
.stat { background: var(--card); border: 2px solid var(--line); border-radius: 22px; box-shadow: 0 3px 0 var(--line); padding: 10px 14px 11px; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.stat .lab { font-size: 13px; font-weight: 700; color: var(--ink2); display: flex; align-items: center; flex-wrap: wrap; gap: 3px 6px; min-height: 22px; line-height: 1.3; }
.stat .num { display: flex; align-items: baseline; gap: 5px; font-weight: 600; }
.stat .num b { font-family: var(--f-disp); font-weight: 700; font-size: 34px; line-height: 38px; }
.stat .num span { font-family: var(--f-disp); font-weight: 600; font-size: 15px; color: var(--ink2); white-space: nowrap; }
.stat .num em, .goal .num em { font-style: normal; font-family: var(--f-zh); font-size: 12.5px; font-weight: 700; margin-left: 2px; }
.stat .cap { display: flex; justify-content: space-between; gap: 6px; font-size: 12px; font-weight: 700; color: var(--ink2); line-height: 1.4; margin-top: 2px; }
.stat .cap b { font-family: var(--f-disp); font-size: 13px; color: var(--ink); }

/* a row of big numbers (the exam in three numbers); .pass is the one to remember */
.nums { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.nums.n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.nums li { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 8px 2px 9px; text-align: center; min-width: 0; border-radius: 16px; background: var(--card); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); }
.nums b { font-family: var(--f-disp); font-weight: 700; font-size: 28px; line-height: 1.15; }
.nums b i { font-style: normal; font-weight: 500; color: var(--ink2); padding: 0 1px; }
.nums span { font-size: 12px; font-weight: 700; line-height: 1.3; color: var(--ink2); }
.nums .pass { background: var(--sun); border-color: var(--sun-d); box-shadow: 0 3px 0 var(--sun-d); color: var(--on-sun); }
.nums .pass span { color: var(--on-sun); }
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; padding: 22px 18px; font-size: 15px; color: var(--ink2); }

/* ================================================================ progress */
.bar { position: relative; height: 12px; border-radius: 8px; background: var(--soft); }
.bar i { position: absolute; left: 0; top: 0; bottom: 0; min-width: 0; max-width: 100%; border-radius: 8px; background: var(--g); }
.bar i::after { content: ""; position: absolute; left: 5px; right: 5px; top: 3px; height: 3px; border-radius: 3px; background: rgba(255, 255, 255, .4); }
.bar i[style*="width:0%"]::after { display: none; }
.bar.ok i { background: var(--g); }
.bar.warm i { background: var(--warm); }
.bar.bad i { background: var(--red); }
.bar.on-c { height: 8px; background: rgba(0, 0, 0, .22); }
.bar.on-c i { background: #fff; }
.bar.on-c i::after { display: none; }
.bar .pass { position: absolute; top: -4px; bottom: -4px; width: 4px; margin-left: -2px; border-radius: 2px; background: var(--ink); }
.hexring { position: relative; flex: none; width: 132px; height: 132px; }
.hexring > svg.r { display: block; width: 100%; height: 100%; }
.hexring .trk { fill: none; stroke: rgba(0, 0, 0, .2); stroke-width: 15; stroke-linejoin: round; }
.hexring .arc { fill: none; stroke: var(--sun); stroke-width: 15; stroke-linejoin: round; stroke-linecap: round; }
.hexring > .six { position: absolute; left: 19.5%; top: 18%; width: 61%; height: 61%; }
.hexic { position: relative; flex: none; width: 34px; height: 34px; display: grid; place-items: center; color: var(--soft); }
.hexic > .hx { position: absolute; inset: 0; width: 100%; height: 100%; }
.hexic > b { position: relative; font-family: var(--f-disp); font-weight: 700; font-size: 17px; line-height: 1; color: var(--ink2); }
.hexic > svg:not(.hx) { position: relative; width: 52%; height: 52%; color: var(--c, var(--g-t)); }
.hexic.solid { color: var(--c, var(--g)); }
.hexic.solid > svg:not(.hx), .hexic.solid > b { color: #fff; }
.hexic.white { color: #fff; }
.six { display: block; }

/* ================================================================ tags, chips, segmented switch */
.tag { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 700; line-height: 1; padding: 4px 7px; border-radius: 7px; background: var(--soft); color: var(--ink2); white-space: nowrap; }
.tag.g, .tag.blue { background: var(--g-l); color: var(--g-t); }
.tag.hot { background: var(--sun); color: var(--on-sun); }
.tag.warm { background: var(--warm-l); color: var(--warm-t); }
.tag.red { background: var(--red-l); color: var(--red-t); }
.tag.th { background: var(--cl); color: var(--ink); }
.tag.th i { width: 9px; height: 9px; border-radius: 3px; background: var(--c); }
.chips { display: flex; flex-wrap: wrap; gap: 10px 8px; }
.chip {
  position: relative; display: inline-flex; align-items: center; gap: 6px; min-height: 36px; padding: 4px 13px; border-radius: 13px;
  background: var(--card); color: var(--ink); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); margin-bottom: 3px;
  font-size: 14px; font-weight: 700; line-height: 1.2; text-decoration: none; white-space: nowrap;
}
.chip::after { content: ""; position: absolute; inset: -5px -2px -6px; }
.chip svg { width: 17px; height: 17px; }
.chip b { font-family: var(--f-disp); font-weight: 700; font-size: 1.25em; line-height: 1; }
.chip:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--line); }
.chip[aria-pressed="true"] { background: var(--g-l); border-color: var(--g); box-shadow: 0 3px 0 var(--g); color: var(--g-t); }
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; background: var(--soft); border-radius: var(--r); }
.seg.n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.seg button, .seg a { min-height: 46px; padding: 5px 6px; border-radius: 14px; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; line-height: 1.25; color: var(--ink2); text-decoration: none; }
.seg b { font-size: 15px; font-weight: 800; }
.seg span { font-size: 11.5px; font-weight: 700; opacity: .9; }
.seg button[aria-pressed="true"], .seg a[aria-current="page"] { background: var(--card); color: var(--g-t); box-shadow: 0 3px 0 var(--line); }

/* ================================================================ lists */
.list { display: flex; flex-direction: column; background: var(--card); border: 2px solid var(--line); border-radius: var(--r-l); box-shadow: 0 3px 0 var(--line); overflow: hidden; }
.lrow { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 60px; padding: 10px 14px; color: var(--ink); text-decoration: none; }
.lrow + .lrow, .list > li + li > .lrow { border-top: 2px solid var(--line); }
.lrow:active { background: var(--soft); }
.lrow .t1 { display: block; font-weight: 800; font-size: 16px; line-height: 1.35; }
.lrow .t2 { display: block; font-size: 13px; color: var(--ink2); line-height: 1.4; }
.go { color: var(--ink2); display: inline-flex; flex: none; }
.go svg { width: 18px; height: 18px; }
.lockm { width: 18px; height: 18px; color: var(--ink2); }
.lrow .cnt { font-family: var(--f-disp); font-weight: 700; font-size: 16px; white-space: nowrap; }
.lrow .cnt small { font-size: 13px; font-weight: 600; color: var(--ink2); }
.lrow .dot { min-width: 24px; height: 24px; padding: 0 7px; border-radius: 12px; background: var(--red); color: #fff; font-family: var(--f-disp); font-weight: 700; font-size: 13.5px; display: inline-flex; align-items: center; justify-content: center; }
.lrow .bar { margin-top: 6px; height: 8px; }
.lrow .bar i { background: var(--c, var(--g)); }
/* long lists: questions, study cards, words, results, rules — rows inside one rounded card */
.qlist, .words, .split, .rules { display: flex; flex-direction: column; background: var(--card); border: 2px solid var(--line); border-radius: var(--r); box-shadow: 0 3px 0 var(--line); overflow: hidden; }
.qlist > li + li, .words li + li, .split li + li, .rules li + li { border-top: 2px solid var(--line); }
.qlist.inner { border-width: 2px 0 0; border-radius: 0; box-shadow: none; background: var(--bg); }
.qrow { display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 10px; align-items: start; width: 100%; min-height: 48px; padding: 12px 14px; }
.qrow .i { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-weight: 600; font-size: 14px; color: var(--ink2); padding-top: 2px; }
.qrow .s { font-family: var(--f-lat); font-weight: 700; font-size: 15.5px; line-height: 1.45; overflow-wrap: anywhere; }
.qrow .s.zhs { font-family: var(--f-zh); font-weight: 500; }
.qrow .m { font-weight: 800; font-size: 16px; padding-top: 1px; }
.qrow .m.okm { color: var(--g-t); }
.qrow .m.badm { color: var(--red-t); }
.m.more { color: var(--g-t); font-family: var(--f-disp); font-size: 20px; font-weight: 600; line-height: 1.2; display: inline-flex; align-items: center; }
.crow { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; width: 100%; min-height: 56px; padding: 12px 14px; }
.crow .ct { display: block; font-weight: 800; font-size: 16px; line-height: 1.4; }
.crow .cl { display: block; font-size: 13.5px; color: var(--ink2); line-height: 1.5; }
.detail { padding: 4px 14px 16px; display: flex; flex-direction: column; gap: 12px; }
.detail .small { display: block; }
.words li { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; padding: 10px 14px; font-size: 15px; align-items: baseline; }
.words .w { font-family: var(--f-lat); font-weight: 800; overflow-wrap: anywhere; color: var(--ink); }
.words.mini { border-radius: var(--r-s); box-shadow: none; }
.words.mini li { padding: 7px 12px; font-size: 14px; }
.split li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: center; min-height: 48px; padding: 8px 14px; font-size: 15px; font-weight: 600; }
.split .n { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-weight: 700; font-size: 17px; }
.split .n.lowv { color: var(--red-t); }
.split .link { min-height: 32px; }
.rules li { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 12px; padding: 11px 14px; font-size: 15px; }
.rules .k { color: var(--ink2); font-size: 14px; font-weight: 700; }
.rules .v b { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-size: 1.1em; }
.facts { display: flex; flex-direction: column; gap: 10px; font-size: 15px; }
.facts li { padding-left: 20px; position: relative; }
.facts li::before { content: ""; position: absolute; left: 1px; top: .5em; width: 10px; height: 9px; background: var(--g); clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.pick { display: flex; align-items: center; gap: 12px; width: 100%; min-height: 68px; padding: 12px 14px 12px 16px; border-radius: var(--r); background: var(--card); border: 2px solid var(--line); box-shadow: 0 4px 0 var(--line); margin-bottom: 4px; text-align: left; }
.pick:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--line); }
.pick .t1 { font-weight: 800; font-size: 17px; line-height: 1.35; }
.pick .t2 { font-size: 13px; font-weight: 700; color: var(--ink2); line-height: 1.35; overflow-wrap: anywhere; }
.pick .cnt { font-size: 13px; font-weight: 700; color: var(--ink2); white-space: nowrap; display: inline-flex; align-items: center; gap: 4px; }
.pick .cnt b { font-family: var(--f-disp); font-size: 20px; color: var(--ink); }
.pick .go { color: var(--g-t); font-weight: 800; font-size: 22px; line-height: 1; margin-left: 4px; }

/* ================================================================ forms */
.field { display: flex; gap: 8px; align-items: flex-start; }
.field input, input[type="date"] {
  flex: 1 1 0; min-width: 0; min-height: 52px; border-radius: 16px; border: 2px solid var(--line); background: var(--card); color: var(--ink);
  padding: 8px 14px; font-family: var(--f-disp); font-weight: 600; font-size: 17px; letter-spacing: .06em; text-transform: uppercase;
}
.field input:focus, input[type="date"]:focus { outline: none; border-color: var(--g); box-shadow: 0 0 0 3px var(--g-l); }
.field input::placeholder { font-family: var(--f-zh); font-weight: 500; font-size: 15px; letter-spacing: 0; color: var(--ink2); opacity: .8; text-transform: none; }
.field input.plain, input[type="date"] { font-family: var(--f-lat); font-weight: 700; font-size: 16px; letter-spacing: 0; text-transform: none; }
.field .btn { flex: none; }
.code { font-family: var(--f-disp); font-weight: 700; font-size: 20px; letter-spacing: .06em; white-space: nowrap; }
.msg { font-size: 14px; font-weight: 700; min-height: 1.4em; }
.msg:empty { display: none; }
.msg.bad { color: var(--red-t); }
.msg.ok { color: var(--g-t); }

/* ================================================================ notes */
.note { border-radius: var(--r); background: var(--soft); padding: 13px 16px; font-size: 14.5px; line-height: 1.6; color: var(--ink); }
.note.blue { background: var(--g-l); }
.note.warn { background: var(--red-l); box-shadow: 0 0 0 2px var(--red) inset; }
.note b { font-weight: 800; }

/* ================================================================ disclosure */
details.disc { background: var(--card); border: 2px solid var(--line); border-radius: var(--r); box-shadow: 0 3px 0 var(--line); min-width: 0; }
details.disc > summary { list-style: none; cursor: pointer; display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 52px; padding: 8px 16px; font-weight: 800; font-size: 15.5px; }
details.disc > summary::-webkit-details-marker { display: none; }
details.disc > summary::after { content: ""; flex: none; width: 10px; height: 10px; border: solid var(--ink2); border-width: 0 3px 3px 0; border-radius: 2px; transform: rotate(45deg) translate(-2px, -2px); }
details.disc[open] > summary::after { transform: rotate(-135deg) translate(-2px, -2px); }
details.disc > .in { padding: 2px 16px 16px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
details.disc.flat { background: none; border: 0; box-shadow: none; }
details.disc.flat > summary { padding: 0; min-height: 44px; justify-content: flex-start; font-size: 13px; color: var(--ink2); }
details.disc.flat > .in { padding: 0 0 6px; }

/* ================================================================ bottom sheet */
.veil { position: fixed; inset: 0; z-index: 20; background: var(--veil); display: flex; align-items: flex-end; justify-content: center; }
.sheet {
  width: 100%; max-width: 580px; max-height: 88%; overflow: auto; background: var(--bg); border-radius: 28px 28px 0 0;
  padding: 26px max(16px, env(safe-area-inset-right, 0px)) calc(18px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
  display: flex; flex-direction: column; gap: 14px; position: relative;
}
.sheet::before { content: ""; position: absolute; top: 9px; left: 50%; width: 44px; height: 5px; margin-left: -22px; border-radius: 5px; background: var(--line); }
.sheet > h2 { font-size: 20px; }
.sheet p { font-size: 15px; }
@media (min-width: 620px) { .veil { align-items: center; padding: 24px; } .sheet { border-radius: 28px; } .sheet::before { display: none; } }

/* ================================================================ bars: page head, sub-page bar, quiz bar, tabs */
.pagehead { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 10px; min-height: 48px; }
.pagehead .slot { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.topbar { display: flex; align-items: center; gap: 12px; min-height: 48px; }
.topbar h1 { flex: 1 1 0; min-width: 0; font-size: 20px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qbar {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 5; background: var(--bg);
  display: flex; align-items: center; gap: 12px; padding: 8px 0 5px;
}
.qbar .bar { flex: 1 1 0; height: 16px; border-radius: 10px; }
.qbar .bar i { border-radius: 10px; }
.qbar .bar i::after { top: 4px; height: 4px; }
.qbar .pos { font-family: var(--f-disp); font-weight: 700; font-size: 18px; white-space: nowrap; }
.qbar .pos small { font-size: 15px; font-weight: 600; color: var(--ink2); }
.qbar .ttl { flex: 1 1 0; min-width: 0; font-size: 13.5px; font-weight: 700; color: var(--ink2); text-align: center; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.timer { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-weight: 700; font-size: 20px; min-width: 62px; padding: 6px 10px; border-radius: 13px; background: var(--card); border: 2px solid var(--line); text-align: center; line-height: 1.2; }
.timer.low { color: var(--red-t); border-color: var(--red); }
.tabs, .dock {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 8;
  padding-bottom: env(safe-area-inset-bottom, 0px);
  padding-left: env(safe-area-inset-left, 0px); padding-right: env(safe-area-inset-right, 0px);
}
.tabs { background: var(--card); border-top: 2px solid var(--line); }
.tabs ul { max-width: 580px; margin: 0 auto; display: grid; grid-template-columns: repeat(5, 1fr); height: var(--tabs-h); padding: 0 6px; }
.tabs a { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; font-size: 11.5px; font-weight: 700; line-height: 1.2; color: var(--ink2); text-decoration: none; }
.tabs .ic { position: relative; width: 40px; height: 34px; display: grid; place-items: center; }
.tabs .ic svg { position: relative; width: 24px; height: 24px; }
.tabs .ic .hx { position: absolute; left: 2px; top: -1px; width: 36px; height: 36px; color: var(--g-l); display: none; }
.tabs a[aria-current="page"] { color: var(--g-t); }
.tabs a[aria-current="page"] .hx { display: block; }

/* ================================================================ question */
.kind { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.stem { font-family: var(--f-lat); font-size: 22px; line-height: 1.4; font-weight: 800; letter-spacing: -.005em; overflow-wrap: anywhere; }
.stemz { font-size: 15px; font-weight: 600; color: var(--ink2); line-height: 1.55; }
.tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.tw { cursor: pointer; border-radius: 8px; }
.tw.on { background: var(--sun); color: var(--on-sun); box-shadow: 0 3px 0 var(--sun-d); padding: 1px 4px; margin: -1px -4px; }
.tw-hint { font-size: 12.5px; font-weight: 600; line-height: 1.5; color: var(--ink2); }
.opts { display: flex; flex-direction: column; gap: 9px; }
.opt {
  display: flex; align-items: center; gap: 11px; width: 100%; min-height: 56px; padding: 9px 14px 9px 11px; margin-bottom: 3px;
  background: var(--card); border: 2px solid var(--line); border-radius: var(--r); box-shadow: 0 3px 0 var(--line); text-align: left;
}
button.opt:active:not([disabled]) { transform: translateY(2px); box-shadow: 0 1px 0 var(--line); }
.opt .txt { flex: 1 1 0; display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.opt .fr { font-family: var(--f-lat); font-weight: 800; font-size: 17px; line-height: 1.35; overflow-wrap: anywhere; }
.opt .zh { font-size: 14px; font-weight: 600; color: var(--ink2); line-height: 1.45; }
.opt .st { width: 24px; height: 24px; }
.opt.sel, .opt.right { background: var(--g-l); border-color: var(--g); box-shadow: 0 3px 0 var(--g); }
.opt.sel .hexic, .opt.right .hexic { color: var(--g); }
.opt.right .fr, .opt.right .zh, .opt.right .st { color: var(--g-t); }
.opt.wrong { background: var(--red-l); border-color: var(--red); box-shadow: 0 3px 0 var(--red); }
.opt.wrong .hexic { color: var(--red); }
.opt.wrong .fr, .opt.wrong .zh, .opt.wrong .st { color: var(--red-t); }
.opt.sel .hexic b, .opt.right .hexic b, .opt.wrong .hexic b { color: #fff; }
.opt[disabled] { cursor: default; }
.opt.dim { opacity: .6; }

/* the explanation. Inside the feedback panel it is white on colour; inline (review, example, welcome) it is a card */
.copy { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.copy h3 { display: flex; align-items: center; gap: 9px; font-size: 21px; letter-spacing: .04em; }
.copy h3 svg { width: 28px; height: 28px; }
.copy .ans { display: flex; align-items: center; flex-wrap: wrap; gap: 6px 8px; font-size: 14px; font-weight: 700; }
.copy .pill { display: inline-flex; align-items: baseline; gap: 7px; max-width: 100%; padding: 4px 12px 5px 10px; border-radius: 12px; background: #fff; color: #00704A; }
.copy .pill b { font-family: var(--f-disp); font-size: 18px; font-weight: 700; }
.copy .pill i { font-style: normal; font-family: var(--f-lat); font-weight: 800; font-size: 15.5px; line-height: 1.3; overflow-wrap: anywhere; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.copy .why { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.copy .why > p { font-size: 15px; line-height: 1.6; font-weight: 500; }
.copy .why > * { flex: none; }      /* the panel scrolls; nothing in it may be squeezed onto its neighbour */
.copy .voc { display: flex; flex-direction: column; gap: 5px; }
.copy .voc li { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 8px; font-size: 14.5px; line-height: 1.5; }
.copy .voc .w { font-family: var(--f-lat); font-weight: 800; background: var(--sun); color: var(--on-sun); padding: 0 6px; border-radius: 6px; }
.copy .voc .tip { flex: 0 0 100%; font-size: 13px; opacity: .85; }
.copy .more { display: flex; flex-wrap: wrap; gap: 2px 16px; align-items: center; }
.copy .src, .copy .report { display: inline-block; padding: 8px 0; font-size: 13px; font-weight: 700; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.copy .report .rid { margin-left: 6px; opacity: .8; font-family: var(--f-disp); }
.detail .copy, .wl-try .copy, .offer-sample .copy { border-radius: var(--r); padding: 13px 14px 10px; }
.copy.good { background: var(--g-l); box-shadow: 0 0 0 2px var(--g) inset; }
.copy.good h3 { color: var(--g-t); }
.copy.miss { background: var(--red-l); box-shadow: 0 0 0 2px var(--red) inset; }
.copy.miss h3 { color: var(--red-t); }
.copy.plain { background: var(--card); box-shadow: 0 0 0 2px var(--line) inset; }
.copy.plain h3 { color: var(--g-t); font-size: 17px; }
.detail .copy h3, .wl-try .copy h3, .offer-sample .copy h3 { font-size: 17px; }
.detail .copy h3 svg, .wl-try .copy h3 svg, .offer-sample .copy h3 svg { width: 22px; height: 22px; }
.copy .pill { box-shadow: 0 0 0 2px var(--g) inset; }
.copy h3 svg path { stroke: var(--card); }
.dock.fb.good .copy h3 svg path { stroke: var(--ok-panel); }
.dock.fb.miss .copy h3 svg path { stroke: var(--bad-panel); }

/* the quiz dock: previous / next, and after an answer the feedback panel that rises from the bottom */
.dock { pointer-events: none; }
.dock .in {
  pointer-events: auto; position: relative; max-width: 580px; margin: 0 auto; display: flex; gap: 10px; align-items: center;
  padding: 10px max(16px, env(safe-area-inset-left, 0px)) 8px; background: var(--card); border-top: 2px solid var(--line);
}
@media (min-width: 612px) { .dock .in { border: 2px solid var(--line); border-bottom: 0; border-radius: var(--r-l) var(--r-l) 0 0; } }
.dock .btn { flex: 1 1 0; min-width: 0; }
.dock .btn.fix { flex: 0 0 auto; }
.dock.fb .in {
  flex-direction: column; align-items: stretch; gap: 12px; max-height: 62vh; max-height: min(62dvh, 560px);
  padding: 16px max(16px, env(safe-area-inset-left, 0px)) 10px; border: 0; border-radius: 28px 28px 0 0; color: #fff;
  background: var(--ok-panel); box-shadow: inset 0 5px 0 rgba(255, 255, 255, .16);
}
.dock.fb.miss .in { background: var(--bad-panel); }
.dock.fb > .six { position: absolute; right: max(18px, calc(50% - 272px)); bottom: calc(100% - 20px); width: 78px; height: 78px; pointer-events: none; }
.dock.fb .copy { flex: 1 1 auto; min-height: 0; background: none; box-shadow: none; }
.dock.fb .copy h3 { color: #fff; }
.dock.fb .copy .pill { box-shadow: none; }
.dock.fb .copy .why { flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; margin-right: -8px; padding-right: 8px; }
.dock.fb .fb-go { flex: none; display: flex; gap: 10px; align-items: center; }
.dock.fb .sq { background: rgba(255, 255, 255, .16); border-color: transparent; box-shadow: 0 3px 0 rgba(0, 0, 0, .2); color: #fff; }
.dock.fb .btn.white { --bt: #00704A; }
.dock.fb.miss .btn.white { --bt: #A82420; }

/* the note of a tapped word */
.tw-pop {
  position: fixed; z-index: 9; left: 0; top: 0; width: max-content; min-width: 132px; max-width: min(300px, calc(100vw - 20px));
  padding: 8px 14px 11px; background: var(--pop); color: var(--on-pop); border-radius: 16px; box-shadow: 0 4px 0 rgba(0, 0, 0, .28); cursor: pointer;
}
.tw-pop::after { content: ""; position: absolute; left: var(--tw-x, 50%); bottom: -6px; width: 14px; height: 14px; margin-left: -7px; background: var(--pop); border-radius: 3px; transform: rotate(45deg); }
.tw-pop.below::after { bottom: auto; top: -6px; }
.tw-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 34px; }
.tw-w { font-family: var(--f-lat); font-size: 15px; font-weight: 800; line-height: 1.3; overflow-wrap: anywhere; min-width: 0; opacity: .85; }
.tw-say { position: relative; flex: none; width: 34px; height: 34px; margin-right: -6px; border-radius: 11px; display: flex; align-items: center; justify-content: center; color: var(--on-pop); background: rgba(255, 255, 255, .16); }
.tw-say::before { content: ""; position: absolute; inset: -5px; }
.tw-say svg { width: 18px; height: 18px; }
.tw-zh { font-size: 18px; font-weight: 800; line-height: 1.4; color: var(--sun); }
.tw-tip { margin-top: 5px; font-size: 13.5px; font-weight: 600; line-height: 1.55; opacity: .95; }
.tw-tip b { display: inline-block; margin-right: 7px; padding: 0 6px; border-radius: 6px; background: rgba(255, 255, 255, .18); font-size: 11.5px; font-weight: 700; line-height: 1.6; vertical-align: 1px; }
.tw-none { font-size: 14px; font-weight: 600; line-height: 1.55; opacity: .9; }

/* ================================================================ error notice */
#oops {
  position: fixed; z-index: 40; left: 10px; right: 10px; top: calc(10px + env(safe-area-inset-top, 0px)); max-width: 560px; margin: 0 auto;
  padding: 12px 14px; border-radius: var(--r); background: var(--card); color: var(--ink); border: 2px solid var(--red); box-shadow: 0 4px 0 var(--red-d);
  display: flex; flex-direction: column; gap: 6px; font-size: 14px; line-height: 1.5;
}
#oops b { color: var(--red-t); font-weight: 800; }
#oops code { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12px; overflow-wrap: anywhere; color: var(--ink2); }
#oops button { align-self: flex-end; min-height: 40px; padding: 4px 16px; border-radius: var(--r-s); background: var(--soft); font-weight: 800; }

/* ================================================================ hero card, speech bubble */
.hero { position: relative; overflow: hidden; display: flex; flex-direction: column; gap: 12px; border-radius: 28px; padding: 14px 16px; margin-bottom: 6px; background: var(--g); color: #fff; box-shadow: 0 6px 0 var(--g-d); }
.hero > .deco { position: absolute; color: #fff; opacity: .08; pointer-events: none; }
.hero > .deco.d1 { width: 150px; height: 150px; right: -44px; top: -52px; }
.hero > .deco.d2 { width: 70px; height: 70px; right: 86px; top: -30px; }
.hero > * { position: relative; }
.hero .sub { color: #fff; font-weight: 700; font-size: 15px; }
.hero.plain { background: var(--card); color: var(--ink); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); margin-bottom: 3px; }
.hero.plain .sub { color: var(--ink2); }
.hero .btn { box-shadow: 0 5px 0 var(--bd), 0 9px 0 rgba(0, 0, 0, .14); margin-bottom: 9px; }
.hero .btn:active:not([disabled]) { box-shadow: 0 2px 0 var(--bd), 0 6px 0 rgba(0, 0, 0, .14); }
.hero.plain .btn { box-shadow: 0 5px 0 var(--bd); margin-bottom: 5px; }
.big { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-size: 56px; font-weight: 700; line-height: 1.05; }
.big small { font-family: var(--f-disp); font-size: 20px; font-weight: 600; opacity: .85; }
.hero:not(.plain) .big { color: var(--sun); text-shadow: 0 3px 0 rgba(0, 0, 0, .16); }
.hero:not(.plain) .big small { color: #fff; text-shadow: none; }
.say { position: relative; display: inline-block; align-self: flex-start; background: #fff; color: #10302A; font-size: 13.5px; font-weight: 700; line-height: 1.4; padding: 6px 12px; border-radius: 14px; }
.say::before { content: ""; position: absolute; left: -5px; top: 50%; width: 14px; height: 14px; margin-top: -7px; background: #fff; border-radius: 3px; transform: rotate(45deg); }
.say > span { position: relative; }
.say b { font-family: var(--f-disp); font-size: 16px; color: #007D51; }
.say.up::before { left: 26px; top: -5px; margin-top: 0; }
.confetti { position: absolute; inset: 0; pointer-events: none; }
.confetti .cf { position: absolute; width: 14px; height: 14px; }

/* ================================================================ home */
.h-head h1 { font-size: 22px; white-space: nowrap; }
.count { align-items: baseline; }
.count b { color: var(--t-principes); font-size: 20px; }
.count.late { border-color: var(--red); color: var(--red-t); box-shadow: 0 3px 0 var(--red); }
.hero-top { display: flex; align-items: center; gap: 12px; }
.goal { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: flex-start; }
.goal .lab { font-size: 14px; font-weight: 700; letter-spacing: .08em; }
.goal .num { display: flex; align-items: baseline; gap: 6px; margin-top: -4px; }
.goal .num b { font-family: var(--f-disp); font-weight: 700; font-size: 60px; line-height: 66px; color: var(--sun); text-shadow: 0 3px 0 rgba(0, 0, 0, .16); }
.goal .num span { font-family: var(--f-disp); font-weight: 600; font-size: 22px; white-space: nowrap; }
.goal .num em { font-size: 15px; margin-left: 3px; }
.stats { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.rd { text-align: left; }
button.rd:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--line); }
.rd-invite { font-size: 13px; font-weight: 600; line-height: 1.5; color: var(--ink2); }
.rd-invite .small { display: block; font-size: 12px; }
.rd.go .rd-state { color: var(--g-t); }
.rd.near .rd-state, .rd.low .rd-state { color: var(--warm-t); }
.rd-weak, .hero-fact { display: flex; align-items: center; gap: 12px; padding: 10px 12px 10px 14px; }
.rd-weak p { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; line-height: 1.35; }
.rd-weak p b { font-size: 15.5px; font-weight: 800; }
.rd-weak p .small { font-size: 12.5px; font-weight: 600; }
.hero-fact { font-size: 14px; font-weight: 700; color: var(--ink2); text-decoration: none; min-height: 48px; }
.hero-fact b { font-family: var(--f-disp); font-size: 19px; color: var(--ink); margin: 0 2px; }
.hero-fact b.pass { color: var(--g-t); }
.hero-fact .go { margin-left: auto; }
.rd-how { display: flex; flex-direction: column; gap: 10px; }
.rd-how p { font-size: 14px; line-height: 1.6; }
.rd-how li { font-size: 14.5px; }
.rd-how li b { font-family: var(--f-disp); font-weight: 700; }
.themes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.theme { display: grid; grid-template-columns: auto 1fr; column-gap: 8px; row-gap: 6px; align-items: center; min-height: 92px; padding: 10px 12px 12px; border-radius: 20px; text-align: left; }
.theme .ti { width: 32px; height: 32px; }
.theme .cnt { justify-self: end; font-family: var(--f-disp); font-weight: 700; font-size: 20px; white-space: nowrap; }
.theme .cnt small { font-size: 13.5px; font-weight: 600; opacity: .9; }
.theme .t1 { grid-column: 1 / -1; font-size: 15px; font-weight: 800; letter-spacing: .01em; line-height: 1.3; }
.theme .bar { grid-column: 1 / -1; }
.theme:last-child:nth-child(odd) { grid-column: 1 / -1; grid-template-columns: auto auto 1fr auto; min-height: 58px; column-gap: 10px; padding: 10px 12px 11px; }
.theme:last-child:nth-child(odd) .t1, .theme:last-child:nth-child(odd) .bar { grid-column: auto; }
.theme:last-child:nth-child(odd) .cnt { order: 4; }
.theme-rules b { font-family: var(--f-disp); }

/* ================================================================ offer */
.pay { display: flex; flex-direction: column; gap: 12px; }
.pay-head { display: flex; align-items: center; gap: 10px; }
.pay-head .six { width: 48px; height: 48px; margin: -4px 0 -4px -2px; }
.pay-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.pay-facts li { display: flex; flex-direction: column; align-items: flex-start; min-width: 0; padding: 7px 10px 8px; border-radius: 14px; background: var(--soft); }
.pay-facts b { font-family: var(--f-disp); font-weight: 700; font-size: 26px; line-height: 1.15; }
.pay-facts span { font-size: 12px; font-weight: 700; color: var(--ink2); line-height: 1.3; }
.buy { display: flex; flex-direction: column; gap: 6px; }
.buy-terms { font-size: 12.5px; font-weight: 700; color: var(--ink2); text-align: center; }
.u-hero { margin: -10px -16px 0; padding: 8px 16px 22px; border-radius: 0 0 36px 36px; align-items: center; text-align: center; gap: 4px; }
.u-hero .deco.d1 { width: 190px; height: 190px; left: -90px; right: auto; top: 96px; opacity: .09; }
.u-hero .deco.d2 { width: 120px; height: 120px; right: -36px; top: -30px; opacity: .09; }
.u-hero .sq { align-self: flex-start; background: rgba(255, 255, 255, .18); border-color: transparent; box-shadow: 0 3px 0 rgba(0, 0, 0, .16); color: #fff; }
.u-hero .sq { z-index: 2; }
.u-stage { pointer-events: none; position: relative; width: 100%; max-width: 358px; height: 128px; margin-top: -30px; }
.u-stage > .six { width: 132px; height: 132px; margin: 0 auto; }
.u-hero h1 { font-size: 26px; letter-spacing: .06em; }
.u-hero .code { display: inline-block; margin-top: 4px; padding: 6px 16px; border-radius: 14px; background: #fff; color: #10302A; }
.u-hero .msg { color: #fff; }
.offer-code { margin-top: 8px; }
@media (min-width: 612px) { .u-hero { margin-top: 0; border-radius: 36px; } }
.gets { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.offer-price { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 12px; }
.offer-price > b { font-family: var(--f-disp); font-weight: 700; font-size: 42px; line-height: 1.1; white-space: nowrap; }
.offer-terms { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 4px 12px 4px 8px; border-radius: 16px; background: var(--g-l); color: var(--g-t); font-size: 13.5px; font-weight: 700; }
.offer-terms svg { width: 18px; height: 18px; }
.offer-honest { font-size: 12.5px; line-height: 1.6; color: var(--ink2); text-align: center; font-weight: 500; }
.offer-after { font-size: 13.5px; color: var(--ink2); }
.offer-after ol { list-style: decimal; padding-left: 20px; display: flex; flex-direction: column; gap: 3px; }
.offer-sample { position: relative; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.offer-stamp { align-self: flex-start; font-size: 12px; font-weight: 800; letter-spacing: .08em; padding: 3px 10px; border-radius: 9px; background: var(--sun); color: var(--on-sun); }
.cmp { width: 100%; border-collapse: separate; border-spacing: 0; font-size: 13.5px; table-layout: fixed; }
.cmp th, .cmp td { padding: 9px 6px; text-align: left; vertical-align: top; border-top: 2px solid var(--line); line-height: 1.35; overflow-wrap: anywhere; }
.cmp thead th, .cmp thead td { border-top: 0; font-size: 12.5px; font-weight: 800; color: var(--ink2); }
.cmp tbody th { width: 27%; font-weight: 800; }
.cmp th small { display: block; font-weight: 600; font-size: 11.5px; color: var(--ink2); }
.cmp td b { font-family: var(--f-disp); font-weight: 700; font-size: 19px; margin-right: 2px; }
.cmp td small { display: block; font-size: 12px; color: var(--ink2); }
.cmp .on { background: var(--g-l); padding-left: 10px; }
.cmp thead .on { color: var(--g-t); border-radius: 12px 12px 0 0; }
.cmp tbody tr:last-child .on { border-radius: 0 0 12px 12px; }
.cmp td .key { color: var(--g-t); font-size: 22px; }
.bank-asof { text-align: center; }

/* ================================================================ practice hub, me hub */
.hub-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.hub-tile { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-height: 96px; padding: 12px 14px; border-radius: 20px; background: var(--card); border: 2px solid var(--line); box-shadow: 0 4px 0 var(--line); margin-bottom: 4px; color: var(--ink); text-decoration: none; text-align: left; }
.hub-tile:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--line); }
.hub-tile .hexic { width: 38px; height: 38px; }
.hub-tile .top { display: flex; align-items: center; justify-content: space-between; width: 100%; }
.hub-tile .t1 { font-size: 16px; font-weight: 800; line-height: 1.3; }
.hub-tile .t2 { font-size: 12.5px; font-weight: 600; color: var(--ink2); line-height: 1.35; }
.hub-tile .dot { min-width: 26px; height: 26px; padding: 0 8px; border-radius: 13px; background: var(--red); color: #fff; font-family: var(--f-disp); font-weight: 700; font-size: 14px; display: inline-flex; align-items: center; justify-content: center; }
.hub-tile .dot.calm { background: var(--soft); color: var(--ink2); }
.th-row { align-items: center; padding-top: 8px; padding-bottom: 8px; }
.th-open { flex: 1 1 0; min-width: 0; min-height: 48px; display: flex; align-items: center; gap: 12px; text-align: left; }
.th-row .hexic { width: 40px; height: 40px; }
.th-row .btn { flex: none; }
.me-card { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; }
.me-card .six { width: 52px; height: 52px; margin: -2px 0 -2px -2px; }
.me-card .t1 { font-size: 17px; font-weight: 800; line-height: 1.3; }
.me-card .t2 { font-size: 13px; color: var(--ink2); font-weight: 600; }
.me-card.done { background: var(--g-l); border-color: var(--g); box-shadow: 0 3px 0 var(--g); }
.foot { font-size: 12.5px; color: var(--ink2); line-height: 1.65; display: flex; flex-direction: column; gap: 4px; }
.foot .hex-b { display: inline-block; padding: 1px 7px; margin-right: 6px; border-radius: 7px; background: var(--soft); color: var(--ink); font-weight: 800; font-size: 11.5px; }

/* ================================================================ set summary, result */
.done-hero { align-items: center; text-align: center; padding: 18px 16px 20px; gap: 6px; }
.done-hero > .six { width: 112px; height: 112px; }
.done-hero h2 { font-size: 24px; letter-spacing: .04em; }
.done-hero .bar { width: 100%; max-width: 280px; margin-top: 6px; }
.verdict-line { font-size: 22px; font-weight: 800; line-height: 1.3; }
.verdict-line.pass { color: var(--g-t); }
.verdict-line.fail { color: var(--red-t); }
.res-hero { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 4px 14px; }
.res-hero > .six { width: 84px; height: 84px; }
.res-hero > .sub, .res-hero > .scale { flex: 0 0 100%; }
.scale { position: relative; padding: 28px 0 22px; }
.scale .track { height: 14px; border-radius: 9px; background: var(--soft); overflow: hidden; }
.scale .track i { display: block; height: 100%; background: var(--red); border-radius: 9px; }
.scale.pass .track i { background: var(--g); }
.scale .passmark { position: absolute; top: 22px; bottom: 16px; width: 4px; margin-left: -2px; border-radius: 2px; background: var(--ink); }
.scale .passmark span { position: absolute; top: -24px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 12px; font-weight: 800; line-height: 1.6; background: var(--sun); color: var(--on-sun); padding: 0 7px; border-radius: 7px; }
.scale .ends { display: flex; justify-content: space-between; font-family: var(--f-disp); font-size: 12px; font-weight: 600; color: var(--ink2); position: absolute; left: 0; right: 0; bottom: 0; line-height: 1.4; }
.rd-next { display: flex; flex-direction: column; gap: 10px; }
.rd-next p { font-size: 14.5px; }
.rd-next p b { font-family: var(--f-disp); font-size: 1.2em; }

/* ================================================================ exam */
.grid40 { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 7px 6px; }
.grid40 button { aspect-ratio: 1 / 1; border-radius: 11px; font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-size: 15px; font-weight: 700; background: var(--card); color: var(--ink2); position: relative; box-shadow: 0 0 0 2px var(--line) inset, 0 3px 0 var(--line); }
.grid40 button.done { background: var(--g); color: #fff; box-shadow: 0 3px 0 var(--g-d); }
.grid40 button.cur { outline: 3px solid var(--ink); outline-offset: 1px; }
.grid40 button.flag::after { content: ""; position: absolute; top: -4px; right: -4px; width: 12px; height: 12px; border-radius: 50%; background: var(--sun); box-shadow: 0 0 0 2px var(--bg); }
.exam-tools { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.exam-tools .link { min-height: 44px; display: inline-flex; align-items: center; color: var(--ink2); }

/* ================================================================ welcome */
.wl { gap: 16px; }
.wl-hero { flex-direction: row; align-items: center; gap: 12px; padding: 12px 14px 14px; }
.wl-hero > .six { width: 84px; height: 84px; margin: -4px -2px -4px -6px; }
.wl-hero .txt { flex: 1 1 0; min-width: 0; }
.wl-kicker { font-size: 12.5px; font-weight: 700; opacity: .95; }
.wl-hero h1 { font-size: 23px; line-height: 1.25; }
.wl-hero h1 em { font-style: normal; color: var(--sun); }
.wl-lead { font-size: 14px; font-weight: 700; margin-top: 2px; }
.wl-proof-wrap { display: flex; flex-direction: column; gap: 8px; }
.wl-proof { display: grid; gap: 8px; }
.wl-proof li { display: flex; flex-direction: column; min-width: 0; padding: 6px 8px 7px; border-radius: 14px; background: var(--card); border: 2px solid var(--line); }
.wl-proof b { font-family: var(--f-disp); font-variant-numeric: tabular-nums; font-size: 25px; font-weight: 700; line-height: 1.15; }
.wl-proof .free { background: var(--sun); border-color: var(--sun-d); color: var(--on-sun); }
.wl-proof span { font-size: 11.5px; font-weight: 700; line-height: 1.3; color: var(--ink2); }
.wl-proof .free span { color: var(--on-sun); }
.wl-try { padding: 14px; border-radius: var(--r-l); background: var(--card); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); }
.wl-try .opt { background: var(--bg); }
.wl-try .opt.right { background: var(--g-l); }
.wl-try .opt.wrong { background: var(--red-l); }
.wl-on { display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%; min-height: 56px; padding: 10px 16px; border-radius: var(--r); background: var(--sun); color: var(--on-sun); box-shadow: 0 5px 0 var(--sun-d); margin-bottom: 5px; font-size: 14px; font-weight: 600; line-height: 1.4; text-align: left; }
.wl-on b { display: block; font-size: 16px; font-weight: 800; }
.wl-on i { font-style: normal; font-size: 22px; font-weight: 800; }
.wl-on:active { transform: translateY(3px); box-shadow: 0 2px 0 var(--sun-d); }
.wl-next { gap: 10px; scroll-margin-top: 12px; }
.wl-step { font-size: 13px; font-weight: 800; color: var(--g-t); letter-spacing: .02em; }
.wl-next h2 { font-size: 21px; }
.wl-check { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 48px; padding: 8px 14px; border-radius: var(--r); background: var(--soft); color: var(--ink); font-size: 14px; font-weight: 600; text-decoration: none; }
.wl-check b { color: var(--g-t); font-weight: 800; white-space: nowrap; }

/* ================================================================ self-check, registration */
.chk-said { display: flex; flex-direction: column; background: var(--card); border: 2px solid var(--line); border-radius: var(--r); overflow: hidden; }
.chk-said li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0 12px; align-items: center; padding: 8px 6px 8px 14px; }
.chk-said li + li { border-top: 2px solid var(--line); }
.chk-said .q { grid-column: 1; font-size: 12.5px; font-weight: 600; color: var(--ink2); }
.chk-said .a { grid-column: 1; font-weight: 800; font-size: 15px; }
.chk-said .link { grid-column: 2; grid-row: 1 / span 2; min-height: 44px; min-width: 44px; text-align: center; }
.chk-q h3 { font-size: 20px; line-height: 1.4; }
.chk-opt { min-height: 64px; }
.chk-res { position: relative; border-radius: var(--r-l); background: var(--card); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.chk-res h3 { font-size: 21px; line-height: 1.35; }
.chk-res p { font-size: 15px; line-height: 1.7; }
.chk-stamp { align-self: flex-start; padding: 3px 12px; border-radius: 10px; font-size: 13.5px; font-weight: 800; letter-spacing: .08em; white-space: nowrap; background: var(--soft); color: var(--ink); }
.chk-res.yes { border-color: var(--warm); box-shadow: 0 3px 0 var(--warm); }
.chk-res.yes .chk-stamp { background: var(--warm-l); color: var(--warm-t); }
.chk-res.no { border-color: var(--g); box-shadow: 0 3px 0 var(--g); }
.chk-res.no .chk-stamp { background: var(--g-l); color: var(--g-t); }
.steps { counter-reset: step; display: flex; flex-direction: column; gap: 16px; }
.steps > li { counter-increment: step; position: relative; padding-left: 44px; display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }
.steps > li::before { content: counter(step); position: absolute; left: 0; top: -2px; width: 34px; height: 30px; background: var(--g); color: #fff; font-family: var(--f-disp); font-weight: 700; font-size: 16px; display: flex; align-items: center; justify-content: center; clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.steps > li > b { font-size: 16px; font-weight: 800; line-height: 28px; }
.steps p { font-size: 15px; line-height: 1.7; }
.steps .facts { font-size: 14.5px; }
.centres { display: flex; flex-direction: column; gap: 10px; }
.centre { border-radius: var(--r); background: var(--card); border: 2px solid var(--line); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.centre .cn { font-size: 15.5px; font-weight: 800; line-height: 1.4; min-width: 0; overflow-wrap: anywhere; flex: 1 1 0; }
.centre .ca { font-size: 14px; font-weight: 600; line-height: 1.55; overflow-wrap: anywhere; }
.centre .cd { font-size: 13px; color: var(--ink2); }
.clinks { display: flex; flex-wrap: wrap; gap: 4px 16px; margin-top: 2px; }
.clinks a { font-weight: 700; font-size: 14px; min-height: 36px; display: inline-flex; align-items: center; }

/* ================================================================ narrow and wide screens */
@media (max-width: 359px) {
  h1, .h-head h1 { font-size: 20px; }
  .h-opt { display: none; }
  .pagehead .slot { gap: 6px; }
  .stem { font-size: 20px; }
  .hexring { width: 108px; height: 108px; }
  .goal .num b { font-size: 50px; line-height: 56px; }
  .goal .num span { font-size: 19px; }
  .hero { padding: 12px; }
  .stats, .themes, .gets, .hub-grid { gap: 10px; }
  .stat { padding: 9px 11px 10px; }
  .stat .num b { font-size: 30px; }
  .theme { padding: 9px 10px 11px; }
  .theme .t1 { font-size: 14px; }
  .theme .cnt { font-size: 18px; }
  .tile .n b { font-size: 38px; }
  .tile p { font-size: 14px; }
  .offer-price > b { font-size: 36px; }
  .u-hero h1 { font-size: 23px; }
  .chip { padding: 4px 10px; font-size: 13px; }
  .dock.fb > .six { width: 64px; height: 64px; bottom: calc(100% - 14px); }
  .pay-facts b { font-size: 22px; }
  .wl-hero > .six { width: 68px; height: 68px; }
  .wl-hero h1 { font-size: 21px; }
  .wl-proof b { font-size: 21px; }
  .wl-proof li { padding: 5px 6px 6px; }
  .wl-proof span { font-size: 11px; }
  .nums b { font-size: 23px; }
  .sh-fig { padding-left: 8px; padding-right: 8px; }
  .sh-tiles .k { font-size: 22px; }
  .sh-pic { width: 19px; height: 19px; }
  .rules li { grid-template-columns: 64px minmax(0, 1fr); }
}
@media (max-width: 339px) { .sh-grid { grid-template-columns: minmax(0, 1fr); } }
@media (min-width: 480px) {
  .stem { font-size: 24px; }
  .sh-grid { gap: 12px; }
  .sh-card { padding-left: 14px; padding-right: 14px; }
  .sh-card .v { font-size: 14px; }
  .nums b { font-size: 32px; }
  .sh-fig { padding: 10px 16px 18px; }
}
@media (min-width: 612px) { .wrap { padding-top: 22px; } .wrap.bare { padding-top: 10px; } }

/* ================================================================ motion */
@media (prefers-reduced-motion: no-preference) {
  .btn, .sq, .chip, .opt, .pick, .tile, .hub-tile { transition: transform .06s ease, box-shadow .06s ease; }
  .bar i, .scale .track i { transition: width .5s ease; }
  .bob { animation: bob 2.6s ease-in-out infinite; }
  .dock.fb .in { animation: rise .42s cubic-bezier(.2, .9, .3, 1.12) both; }
  .dock.fb > .six { animation: peek .5s .22s cubic-bezier(.2, .9, .3, 1.3) both; }
  .detail .copy, .wl-try .copy { animation: pop .26s ease both; }
  .tw-pop { animation: tw-in .12s ease-out; }
  .confetti .cf { animation: float 3.2s ease-in-out infinite; }
  .confetti .cf:nth-child(odd) { animation-delay: -1.4s; }
  .sheet { animation: rise .3s cubic-bezier(.2, .9, .3, 1.05) both; }
  @keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-3px); } }
  @keyframes rise { from { transform: translateY(55%); } to { transform: translateY(0); } }
  @keyframes peek { from { transform: translateY(46px); } to { transform: translateY(0); } }
  @keyframes pop { from { transform: translateY(6px); opacity: .4; } to { transform: none; opacity: 1; } }
  @keyframes tw-in { from { opacity: 0; } }
  @keyframes float { 0%, 100% { transform: translateY(0) rotate(0); } 50% { transform: translateY(-5px) rotate(8deg); } }
}

/* ======================================================================================================
   Screen-specific rules added after the foundation. One section per group of screens; add rules directly
   under your own heading and nowhere else, so that parallel work merges cleanly.
   ====================================================================================================== */

/* ==== screens: welcome, mock exam, result, mistakes ==== */
/* .mix: a stacked bar of theme-coloured blocks, each as wide as its share (themeMix() in app.js); .mix-key names them */
.mix { display: flex; gap: 5px; min-width: 0; }
.mix > span {
  flex: 1 1 0; min-width: 32px; height: 56px; margin-bottom: 4px; border-radius: 14px; background: var(--c); color: #fff; box-shadow: 0 4px 0 var(--cd);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
}
.mix svg { width: 17px; height: 17px; opacity: .92; }
.mix b { font-family: var(--f-disp); font-weight: 700; font-size: 19px; line-height: 1; }
.mix-key li { display: flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 700; line-height: 1.4; }
.mix-key i { flex: none; width: 13px; height: 13px; border-radius: 4px; background: var(--c); }
.mix-key b { margin-left: auto; font-family: var(--f-disp); font-size: 16px; }

/* ---- welcome: the hero runs to the top edge, the bank's numbers sit across its lower edge */
.wl { gap: 14px; }
.wl-hero { margin: -10px -16px 0; padding: 14px 16px 50px; border-radius: 0 0 34px 34px; gap: 10px; }
.wl-hero > .six { width: 96px; height: 96px; margin: -2px -4px -6px -6px; }
.wl-hero .txt { display: flex; flex-direction: column; align-items: flex-start; gap: 5px; }
.wl-hi { font-size: 13px; padding: 4px 11px; }
.wl-hero h1 { font-size: 24px; line-height: 1.22; }
.wl-lead { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 7px; font-size: 15px; font-weight: 700; margin: 0; }
.wl-un { font-size: 12.5px; font-weight: 800; line-height: 1.7; padding: 0 8px; border-radius: 8px; background: rgba(0, 0, 0, .26); }
.wl-proof-wrap { position: relative; margin-top: -54px; gap: 7px; }
.wl-proof li { align-items: center; text-align: center; padding: 7px 2px 8px; border-radius: 17px; box-shadow: 0 4px 0 var(--line); margin-bottom: 4px; }
.wl-proof b { font-size: 28px; line-height: 1.1; }
.wl-proof span { font-size: 12px; }
.wl-proof .free { box-shadow: 0 4px 0 var(--sun-d); }
.wl-proof-wrap .small { text-align: center; font-size: 12.5px; }
.wl-try { gap: 11px; }
.wl-try-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.wl-try-head .offer-stamp { font-size: 13.5px; line-height: 1.6; padding: 2px 11px; }
.wl-try .stem { font-size: 21px; }
.wl-react { display: flex; align-items: center; gap: 12px; min-height: 60px; }
.wl-react .six { width: 64px; height: 64px; margin: -2px 0 -2px -4px; }
.wl-react .say { align-self: center; font-size: 15px; padding: 8px 14px; background: var(--g-l); color: var(--ink); }
.wl-react .say::before { background: var(--g-l); }
.wl-react.miss .say, .wl-react.miss .say::before { background: var(--soft); }
.wl-on { justify-content: center; gap: 8px; min-height: 54px; }
.wl-on b { display: inline; font-size: 17px; letter-spacing: .04em; }
.wl-on i { font-size: 20px; line-height: 1; }
.wl-next { gap: 12px; }
.wl-next-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 4px 10px; }
.wl-pick {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: 12px; align-items: center; width: 100%;
  padding: 12px 16px 13px 14px; border-radius: 22px; text-align: left;
}
.lv-csp { --c: var(--g); --cd: var(--g-d); }
.lv-cr { --c: var(--t-droits); --cd: var(--t-droits-d); }
.lv-nat { --c: var(--t-institutions); --cd: var(--t-institutions-d); }
.wl-pick > .hexic { grid-row: 1 / span 2; width: 48px; height: 48px; }
.wl-pick > * { position: relative; }
.wl-pick > .deco { position: absolute; right: -16px; top: -22px; width: 96px; height: 96px; opacity: .13; }
.wl-pick .t1 { align-self: end; font-size: 20px; font-weight: 800; line-height: 1.3; letter-spacing: .02em; }
.wl-pick .t2 { align-self: start; grid-column: 2; font-size: 15px; font-weight: 700; line-height: 1.25; overflow-wrap: anywhere; }
.wl-pick .cnt { align-self: end; justify-self: end; }
.wl-pick .cnt b { font-family: var(--f-disp); font-weight: 700; font-size: 32px; line-height: 1.05; text-shadow: 0 3px 0 rgba(0, 0, 0, .14); }
.wl-pick .u { align-self: start; justify-self: end; grid-column: 3; font-size: 15px; font-weight: 700; line-height: 1.25; white-space: nowrap; }
.wl-check b { display: inline-flex; align-items: center; gap: 2px; }
.wl-check svg { width: 16px; height: 16px; }
@media (min-width: 612px) { .wl-hero { margin: 0; border-radius: 34px; } .wl-proof { padding: 0 16px; } }

/* ---- mock exam: the challenge card, how the questions are shared, past results */
.ex-hero { gap: 12px; padding-top: 12px; }
.ex-top { display: flex; align-items: center; gap: 10px; }
.ex-top .six { width: 80px; height: 80px; margin: -6px 0 -8px -6px; }
.ex-top .say { align-self: center; font-size: 16px; padding: 8px 14px; }
.ex-hero .nums { gap: 10px; }
.ex-hero .nums li { color: var(--ink); padding: 9px 2px 11px; border-radius: 20px; border-color: var(--card); box-shadow: 0 4px 0 rgba(0, 0, 0, .2); margin-bottom: 4px; }
.ex-hero .nums b { font-size: 40px; line-height: 1.1; }
.ex-hero .nums span { font-size: 13px; }
.ex-hero .nums .pass { border-color: var(--sun); color: var(--on-sun); }
.ex-hero > .sub { text-align: center; }
.ex-note { margin-top: -8px; }
.ex-mix { display: flex; flex-direction: column; gap: 12px; padding-bottom: 4px; }
.ex-mix .tag { font-size: 12.5px; padding: 5px 9px; }
.ex-mix .tag b { font-family: var(--f-disp); font-size: 14px; color: var(--ink); }
.ex-mix .mix-key { gap: 7px; padding-bottom: 10px; }
.ex-past { min-height: 58px; text-align: left; }
.ex-past .sc { flex: none; min-width: 70px; font-family: var(--f-disp); font-weight: 600; font-size: 15px; color: var(--ink2); white-space: nowrap; }
.ex-past .sc b { font-weight: 700; font-size: 26px; line-height: 1; color: var(--g-t); }
.ex-past.fail .sc b { color: var(--warm-t); }
.ex-past .t2 { font-weight: 600; }
.ex-past .tag { font-size: 12.5px; padding: 5px 8px; }

/* ---- the running exam: the clock turns warm in the last five minutes; flags are "come back later", so warm too */
.ex-run .qbar { gap: 10px; }
.timer { min-width: 78px; border-radius: 14px; box-shadow: 0 3px 0 var(--line); margin-bottom: 3px; }
.timer.low { color: var(--warm-t); background: var(--warm-l); border-color: var(--warm); box-shadow: 0 3px 0 var(--warm); }
.ex-bar { display: flex; align-items: center; gap: 8px; min-height: 44px; }
.ex-bar .pos { flex: 1 1 0; min-width: 0; font-size: 15px; font-weight: 800; color: var(--ink2); white-space: nowrap; }
.ex-bar .pos b { font-family: var(--f-disp); font-weight: 700; font-size: 28px; line-height: 1; color: var(--ink); margin: 0 1px; }
.ex-bar .pos small { font-size: 14px; font-weight: 700; }
.ex-bar .chip { min-height: 40px; }
.ex-flag[aria-pressed="true"] { background: var(--warm-l); border-color: var(--warm); box-shadow: 0 3px 0 var(--warm); color: var(--warm-t); }
.grid40 { grid-template-columns: repeat(8, minmax(0, 1fr)); gap: 4px 2px; }
.grid40.few { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px 4px; }
.grid40 button, .grid40 button.done { aspect-ratio: auto; height: 44px; display: grid; place-items: center; background: none; box-shadow: none; border-radius: 12px; color: var(--soft); }
.grid40 button > .hx { grid-area: 1 / 1; width: 40px; height: 40px; }
.grid40 button > b { grid-area: 1 / 1; position: relative; font-family: var(--f-disp); font-weight: 700; font-size: 16px; color: var(--ink2); }
.grid40.few button { height: 52px; }
.grid40.few button > .hx { width: 48px; height: 48px; }
.grid40.few button > b { font-size: 19px; }
.grid40 button.done { color: var(--g); }
.grid40 button.done > b { color: #fff; }
.grid40 button.cur { outline: 3px solid var(--ink); outline-offset: -2px; }
.grid40 button.flag::after { top: 1px; right: calc(50% - 21px); width: 13px; height: 13px; background: var(--warm); box-shadow: 0 0 0 2.5px var(--bg); }
.grid40.few button.flag::after { right: calc(50% - 25px); }
.grid-key { display: flex; justify-content: center; flex-wrap: wrap; gap: 4px 18px; font-size: 13.5px; font-weight: 700; color: var(--ink2); }
.grid-key li { display: inline-flex; align-items: center; gap: 6px; }
.grid-key i { width: 15px; height: 14px; background: var(--soft); clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.grid-key .done i { background: var(--g); }
.grid-key .flag i { width: 12px; height: 12px; border-radius: 50%; clip-path: none; background: var(--warm); }
.grid-key b { font-family: var(--f-disp); font-size: 15px; color: var(--ink); }
.ex-sum b { font-size: 30px; }
.ex-sum .miss b { color: var(--warm-t); }

/* ---- result: green and confetti when passed; calm, white and warm when not yet */
.res-hero { flex-direction: column; flex-wrap: nowrap; align-items: center; text-align: center; gap: 2px; padding: 14px 16px 16px; }
.res-hero > .six { width: 112px; height: 112px; }
.res-hero .verdict-line { font-size: 24px; letter-spacing: .04em; }
.res-hero.pass .verdict-line { color: #fff; }
.res-hero.fail .verdict-line { color: var(--ink); }
.res-hero.fail .verdict-line b { font-family: var(--f-disp); font-size: 1.3em; line-height: 1; color: var(--warm-t); }
.res-hero .big { font-size: 68px; }
.res-hero .big small { font-size: 24px; }
.res-hero > .sub, .res-hero > .scale { flex: 0 0 auto; width: 100%; }
.res-hero > .scale { max-width: 330px; }
.res-hero > .sub { font-size: 14px; }
.res-hero.pass > .sub { font-size: 15px; }
.res-hero.pass .scale .track { background: rgba(0, 0, 0, .24); }
.res-hero.pass .scale .track i { background: #fff; }
.res-hero.pass .scale .passmark { background: #10302A; }
.res-hero.pass .scale .ends { color: #fff; }
.res-hero.fail .scale .track i { background: var(--warm); }
.res-th { display: flex; flex-direction: column; gap: 13px; padding: 14px; }
.res-th li { display: flex; align-items: center; gap: 12px; min-width: 0; }
.res-th .hexic { width: 38px; height: 38px; }
.res-th .t1 { display: block; font-size: 14.5px; font-weight: 800; line-height: 1.3; margin-bottom: 5px; }
.res-th .bar { height: 10px; }
.res-th .bar i { background: var(--c); }
.res-th .n { flex: none; min-width: 54px; text-align: right; font-family: var(--f-disp); font-weight: 600; font-size: 15px; color: var(--ink2); white-space: nowrap; }
.res-th .n b { font-weight: 700; font-size: 24px; line-height: 1; color: var(--ink); }
.res-th .n.full b { color: var(--g-t); }
.rd-next { gap: 12px; }
.rd-th { display: flex; align-items: center; gap: 12px; }
.rd-th .hexic { width: 42px; height: 42px; }
.rd-th p { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; line-height: 1.35; }
.rd-next .rd-th p b { font-family: inherit; font-size: 17px; font-weight: 800; }
.rd-th .small { font-size: 12.5px; font-weight: 600; }
.rd-none { font-weight: 700; }
.rd-est { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-weight: 700; }
.res-rev .chips { gap: 8px; flex-wrap: nowrap; }
.res-list .qrow .m { width: 24px; height: 24px; padding: 0; border-radius: 50%; display: grid; place-items: center; font-size: 14px; line-height: 1; color: #fff; }
.res-list .qrow .m.okm { background: var(--g); color: #fff; }
.res-list .qrow .m.badm { background: var(--red); color: #fff; }

/* ---- mistakes */
.mis-hero { gap: 12px; }
.mis-top { display: flex; align-items: center; gap: 12px; }
.mis-top .six { width: 84px; height: 84px; margin: -4px 0 -6px -6px; }
.mis-hero .big { font-size: 54px; color: var(--red-t); }
.mis-hero .big small { font-family: var(--f-zh); font-size: 16px; font-weight: 800; color: var(--ink); opacity: 1; }
.mis-hero .mix > span { height: 44px; flex-direction: row; gap: 5px; }
.mis-h { display: flex; align-items: center; gap: 10px; }
.mis-h .cnt { flex: none; min-width: 30px; padding: 0 9px; border-radius: 15px; background: var(--cl); font-family: var(--f-disp); font-weight: 700; font-size: 16px; line-height: 30px; text-align: center; }
.mis-empty { padding: 30px 18px 28px; gap: 4px; }
.mis-empty h2 { color: var(--ink); font-size: 20px; margin-top: 6px; }

@media (max-width: 359px) {
  .wl-hero { padding: 12px 12px 46px; }
  .wl-hero > .six { width: 74px; height: 74px; margin-left: -6px; }
  .wl-hero h1 { font-size: 20px; }
  .wl-lead { font-size: 14px; }
  .wl-proof-wrap { margin-top: -50px; }
  .wl-proof b { font-size: 23px; }
  .wl-proof span { font-size: 11.5px; }
  .wl-try { padding: 12px; }
  .wl-try .stem { font-size: 19px; }
  .wl-pick { padding: 11px 12px 12px 11px; column-gap: 9px; }
  .wl-pick > .hexic { width: 40px; height: 40px; }
  .wl-pick .t1 { font-size: 18px; }
  .wl-pick .cnt b { font-size: 27px; }
  .ex-top .six { width: 66px; height: 66px; }
  .ex-top .say { font-size: 15px; }
  .ex-hero .nums b { font-size: 33px; }
  .ex-hero .btn.lg { font-size: 17px; letter-spacing: 0; padding-inline: 8px; }
  .ex-bar .chip { padding: 4px 9px; }
  .ex-bar .pos b { font-size: 25px; }
  .grid40 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .grid40.few { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .res-hero .big { font-size: 58px; }
  .res-hero > .six { width: 96px; height: 96px; }
  .res-th .t1 { font-size: 13.5px; }
  .mis-top .six { width: 70px; height: 70px; }
}
@media (prefers-reduced-motion: no-preference) {
  .wl-pick, .wl-on, .ex-past { transition: transform .06s ease, box-shadow .06s ease; }
  .wl-react { animation: pop .3s ease both; }
  .res-hero .big { animation: res-in .5s cubic-bezier(.2, .9, .3, 1.3) both; }
  @keyframes res-in { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
}

/* (end of: welcome, mock exam, result, mistakes) */

/* ---------------------------------------------------------------------------------------------------- */

/* ==== screens: study cards, words, cram sheet, recollections ==== */
/* ---- shared by these four screens: a section title with its theme hexagon and a count */
.sec-h { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 800; line-height: 1.3; }
.sec-h .hexic { width: 30px; height: 30px; }
.sec-h > b.num { flex: none; padding: 1px 9px; border-radius: 10px; background: var(--cl, var(--soft)); font-size: 15px; font-weight: 700; }

/* ---- study cards (考点速记): theme filter, the open card, the shelves */
.kf { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px 8px; }
.kf .chip { justify-content: center; gap: 5px; min-height: 42px; padding: 4px 6px; font-size: 15px; font-weight: 800; }
.kf .chip svg { width: 18px; height: 18px; color: var(--c); }
.kf .chip b { font-size: 15px; font-weight: 600; color: var(--ink2); }
.kf .chip[aria-pressed="true"] { background: var(--c, var(--g)); border-color: var(--cd, var(--g-d)); box-shadow: 0 3px 0 var(--cd, var(--g-d)); color: #fff; }
.kf .chip[aria-pressed="true"] svg, .kf .chip[aria-pressed="true"] b { color: #fff; }
.kc { min-width: 0; border-radius: var(--r-l); background: var(--card); border: 2px solid var(--c); box-shadow: 0 5px 0 var(--cd); margin-bottom: 5px; overflow: hidden; scroll-margin-top: 10px; }
.kc-head { position: relative; overflow: hidden; padding: 12px 16px 14px; background: var(--c); color: #fff; }
.kc-head .deco { position: absolute; right: -26px; top: -30px; width: 120px; height: 120px; color: #fff; opacity: .13; pointer-events: none; }
.kc-top { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.kc-th { display: inline-flex; align-items: center; gap: 6px; min-width: 0; font-size: 15px; font-weight: 800; line-height: 1.3; }
.kc-th svg { width: 18px; height: 18px; }
.kc-pos { flex: none; padding: 3px 10px; border-radius: 11px; background: #fff; color: #10302A; font-size: 13px; font-weight: 800; line-height: 1.4; white-space: nowrap; }
.kc-pos b { font-family: var(--f-disp); font-size: 16px; }
.kc-head h2 { position: relative; margin-top: 10px; font-size: 25px; line-height: 1.25; letter-spacing: .02em; text-shadow: 0 2px 0 rgba(0, 0, 0, .14); }
.kc-fr { position: relative; font-weight: 800; font-size: 16.5px; line-height: 1.4; overflow-wrap: anywhere; }
.kc-body { display: flex; flex-direction: column; gap: 14px; padding: 14px 16px 8px; min-width: 0; }
.kc-lead { font-size: 18px; font-weight: 800; line-height: 1.5; }
.kc .facts { gap: 9px; font-size: 15px; line-height: 1.6; }
.kc .facts li::before { background: var(--c); }
.kc-voc { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.kc-voc li { min-width: 0; display: flex; }
.voc { flex: 1 1 auto; display: flex; flex-direction: column; justify-content: center; min-width: 0; min-height: 38px; padding: 6px 11px; border-radius: 12px; background: var(--cl); font-size: 14px; font-weight: 600; line-height: 1.4; text-align: left; }
.voc b { font-family: var(--f-lat); font-weight: 800; font-size: 15.5px; overflow-wrap: anywhere; }
button.voc { box-shadow: 0 3px 0 var(--c); margin-bottom: 3px; }
button.voc:active { transform: translateY(2px); box-shadow: 0 1px 0 var(--c); }
.kc-src { display: block; padding: 3px 0; font-size: 12.5px; line-height: 1.5; color: var(--ink2); overflow-wrap: anywhere; }
.kc-lock { display: flex; align-items: center; gap: 12px; padding: 12px 12px 9px 14px; border-radius: var(--r); background: var(--soft); }
.kc-lock .hexic { width: 40px; height: 40px; color: var(--card); margin-bottom: 3px; }
.kc-lock .hexic > svg:not(.hx) { color: var(--ink2); }
.kc-lock p { flex: 1 1 0; min-width: 0; font-size: 15px; font-weight: 700; margin-bottom: 3px; }
.kc-lock p b { font-size: 20px; }
.kc-nav { display: flex; align-items: center; gap: 10px; padding: 6px 16px 12px; }
.ks { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.ks ul { display: flex; gap: 10px; margin: 0 -16px; padding: 2px 16px 6px; overflow-x: auto; scroll-snap-type: x proximity; scroll-padding: 0 16px; -webkit-overflow-scrolling: touch; scrollbar-width: none; }
.ks ul::-webkit-scrollbar { display: none; }
.ks li { flex: none; scroll-snap-align: start; min-width: 0; }
.ks.grid ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin: 0; padding: 0; overflow: visible; }
.kmini { display: flex; flex-direction: column; gap: 5px; width: 136px; height: 100%; min-height: 96px; padding: 8px 11px 10px; border-radius: 16px; background: var(--card); border: 2px solid var(--c); box-shadow: 0 4px 0 var(--cd); margin-bottom: 4px; text-align: left; }
.ks.grid .kmini { width: 100%; }
.kmini:active { transform: translateY(2px); box-shadow: 0 2px 0 var(--cd); }
.kmini .kn { display: flex; align-items: center; justify-content: space-between; font-family: var(--f-disp); font-weight: 700; font-size: 18px; line-height: 1.2; color: var(--ink2); }
.kmini .ct { font-size: 15px; font-weight: 800; line-height: 1.35; display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 3; overflow: hidden; }
.kmini.lk { background: var(--soft); border-color: var(--line); box-shadow: 0 4px 0 var(--line); }
.kmini.lk .ct { color: var(--ink2); }
.kmini.lk:active { box-shadow: 0 2px 0 var(--line); }
.kmini[aria-current="true"] { background: var(--c); border-color: var(--cd); box-shadow: 0 4px 0 var(--cd); color: #fff; }
.kmini[aria-current="true"] .kn, .kmini[aria-current="true"] .ct, .kmini[aria-current="true"] .lockm { color: #fff; }

/* ---- words (生词表) */
.w-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.w-n { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 6px; font-size: 15px; font-weight: 800; }
.w-n b { font-size: 30px; line-height: 1.1; }
.w-n .tag { align-self: center; }
.wl { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.wl .words { border-left: 6px solid var(--c); }
.wl .words li { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); align-items: center; gap: 10px; min-height: 50px; padding: 4px 12px 4px 8px; }
.wl .w { display: inline-flex; align-items: center; gap: 9px; min-height: 42px; text-align: left; font-size: 16px; line-height: 1.3; }
.wl .w svg { flex: none; width: 32px; height: 32px; padding: 7px; border-radius: 11px; background: var(--cl); color: var(--ink); }
.wl span.w { padding-left: 6px; }
.wl button.w:active svg { transform: translateY(1px); }
.wl .z { font-size: 15px; font-weight: 600; line-height: 1.4; }
.wl .peek { justify-self: start; min-width: 72px; min-height: 38px; border-radius: 12px; background: var(--soft); border: 2px dashed var(--line); font-family: var(--f-disp); font-size: 18px; font-weight: 700; color: var(--ink2); text-align: center; }

/* ---- cram sheet (考前一页) */
.sh-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.sh-top .link { margin-left: 4px; white-space: nowrap; }
.sh-top .chip { flex: none; }
.sh-grid { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.sh-card, .sh-tiles { display: flex; flex-direction: column; gap: 10px; min-width: 0; padding: 0; border: 0; background: none; }
.sh-rows { display: flex; flex-direction: column; background: var(--card); border: 2px solid var(--line); border-left: 6px solid var(--c); border-radius: var(--r); box-shadow: 0 3px 0 var(--line); overflow: hidden; }
.sh-rows li { display: flex; align-items: center; gap: 10px; min-height: 50px; padding: 8px 12px; min-width: 0; }
.sh-rows .grow { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 10px; }
.sh-rows li + li { border-top: 2px solid var(--line); }
.sh-rows .hexic { width: 38px; height: 38px; color: var(--cl); }
.sh-rows .hexic .sh-pic { width: 22px; height: 22px; color: var(--ink); position: relative; }
.sh-rows .k, .sh-tiles .sh-rows .k { display: block; width: fit-content; font-size: 16px; font-weight: 800; line-height: 1.4; }
.sh-rows .k.n { font-family: var(--f-disp); font-weight: 700; font-size: 19px; }
.sh-rows .k.hl, .sh-card .k.hl { padding: 0 7px; border-radius: 7px; background: var(--sun); color: var(--on-sun); }
.sh-rows .v, .sh-card .v { display: block; font-size: 14.5px; line-height: 1.5; overflow-wrap: anywhere; }
.sh-rows .v i, .sh-nums .v i { font-style: normal; font-size: 12.5px; font-weight: 700; color: var(--ink2); }
.sh-nums { display: flex; flex-wrap: wrap; gap: 10px 8px; }
.sh-nums li { flex: 1 1 28%; min-width: 0; display: flex; flex-direction: column; border-radius: 16px; overflow: hidden; background: var(--card); border: 2px solid var(--c); box-shadow: 0 4px 0 var(--cd); margin-bottom: 4px; padding: 0; }
.sh-nums .k { display: flex; align-items: center; justify-content: center; gap: 6px; padding: 5px 4px 4px; background: var(--c); color: #fff; font-family: var(--f-disp); font-weight: 700; font-size: 31px; line-height: 1.2; text-shadow: 0 2px 0 rgba(0, 0, 0, .14); white-space: nowrap; }
.sh-nums .k small { font-family: var(--f-zh); font-size: 15px; font-weight: 800; margin: 0 1px; }
.sh-nums .k.long { font-size: 24px; line-height: 1.55; }
.sh-nums .k.hl { background: var(--sun); color: var(--on-sun); text-shadow: none; border-radius: 0; padding: 5px 4px 4px; }
.sh-nums .k .sh-pic { width: 22px; height: 22px; color: inherit; }
.sh-nums .v { flex: 1 1 auto; margin: 0; padding: 6px 5px 8px; text-align: center; font-size: 13px; font-weight: 700; line-height: 1.35; overflow-wrap: anywhere; }
.sh-nums .v i { display: block; overflow-wrap: break-word; }
.sh-pic { width: 22px; height: 22px; flex: none; }
.sh-pic .p-b { fill: #2F5FD0; stroke: #2F5FD0; }
.sh-pic .p-w { fill: #fff; }
.sh-pic .p-r { fill: #E0483F; stroke: #E0483F; }
.sh-fig { margin: 0 0 5px; padding: 0; min-width: 0; border-radius: var(--r-l); background: var(--card); border: 2px solid var(--c); box-shadow: 0 5px 0 var(--cd); overflow: hidden; scroll-margin-top: 16px; }
.sh-fig figcaption { display: flex; align-items: center; gap: 8px; min-height: 54px; margin: 0; padding: 6px 9px 5px 14px; background: var(--c); color: #fff; }
.sh-fig figcaption > svg { width: 22px; height: 22px; }
.sh-fig h3 { flex: 1 1 0; min-width: 0; font-size: 18px; letter-spacing: .02em; color: #fff; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sh-zoom { position: relative; flex: none; display: inline-flex; align-items: center; gap: 5px; width: auto; height: auto; min-height: 38px; margin: 0 0 3px; padding: 4px 12px 4px 9px; border-radius: 13px; background: #fff; color: #10302A; box-shadow: 0 3px 0 rgba(0, 0, 0, .26); font-size: 14.5px; font-weight: 800; }
.sh-zoom::after { content: ""; position: absolute; inset: -5px -4px -6px; }
.sh-zoom:active { transform: translateY(2px); box-shadow: 0 1px 0 rgba(0, 0, 0, .26); }
.sh-zoom svg { width: 18px; height: 18px; }
.sh-draw { cursor: zoom-in; padding: 12px 6px 10px; }
.sh-cap { margin: 0; padding: 0 14px 12px; font-size: 12.5px; line-height: 1.55; color: var(--ink2); }
.sh-svg { display: block; width: 100%; max-width: 460px; height: auto; margin: 0 auto; }
.sh-svg text { font-family: var(--f-zh); fill: var(--ink); }
.sh-svg .v-t { font-weight: 800; }
.sh-svg .v-num { font-family: var(--f-disp); font-weight: 700; }
.sh-svg .v-2 { fill: var(--ink2); }
.sh-svg .v-b { fill: var(--water); font-weight: 800; }
.sh-svg .v-fr { font-family: var(--f-lat); font-weight: 700; fill: var(--ink2); letter-spacing: 0; }
.sh-svg .v-on { fill: var(--on-sun); }
.sh-svg .v-w { fill: #fff; }
.sh-svg .v-k { fill: var(--ink); }
.v-hl { fill: var(--sun); }
.v-e0 { --e: var(--t-principes); --el: var(--t-principes-l); }
.v-e1 { --e: var(--t-institutions); --el: var(--t-institutions-l); }
.v-e2 { --e: var(--t-droits); --el: var(--t-droits-l); }
.v-e3 { --e: var(--t-histoire); --el: var(--t-histoire-l); }
.v-e4 { --e: var(--t-societe); --el: var(--t-societe-l); }
.v-pill { fill: var(--e, var(--ink2)); }
.v-pill.v-eu { fill: var(--card); stroke: var(--water); stroke-width: 2.5; }
.v-hl.v-eu { stroke: var(--water); stroke-width: 2.5; }
.v-era { fill: var(--el); }
.v-rail { fill: none; stroke: var(--soft); stroke-width: 8; stroke-linecap: round; }
.v-span { fill: none; stroke: var(--e); stroke-width: 16; stroke-linecap: round; opacity: .32; }
.v-blk { fill: var(--e); }
.v-box { fill: var(--card); }
.v-cit { fill: var(--pop); }
.v-lab { fill: var(--card); stroke: var(--ink); stroke-width: 1.6; }
.v-arrow { fill: none; stroke: var(--ink); stroke-width: 2.8; stroke-linecap: round; stroke-linejoin: round; }
.v-arrow-b { fill: none; stroke: var(--card); stroke-width: 7.5; stroke-linecap: round; stroke-linejoin: round; }
.v-pic { fill: none; stroke: var(--g-t); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.v-pic * { fill: none; stroke: inherit; stroke-width: inherit; }
.v-pic-w { stroke: #fff; stroke-width: 1.9; }
.v-ground { fill: var(--soft); }
.v-seabg { fill: var(--water); fill-opacity: .24; }
.v-land0 { fill: var(--card); }
.v-land { fill: var(--g); fill-opacity: .3; }
.v-coast { fill: none; stroke: var(--g-d); stroke-width: 1.8; stroke-linejoin: round; stroke-linecap: round; }
.v-border { fill: none; stroke: var(--ink2); stroke-width: 1.3; stroke-dasharray: 3.5 3; stroke-linejoin: round; }
.v-river { fill: none; stroke: var(--water); stroke-width: 2; stroke-linecap: round; }
.v-peak { fill: none; stroke: var(--ink2); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.v-top { fill: var(--ink); stroke: var(--ink); stroke-width: 1.4; stroke-linejoin: round; }
.v-city { fill: var(--ink); stroke: var(--card); stroke-width: 1.2; stroke-linejoin: round; }
.v-city.v-on { fill: var(--on-sun); stroke: none; }
.v-cap { stroke: var(--sun-d); stroke-width: 1.5; stroke-linejoin: round; }
.v-dom { fill: var(--water); fill-opacity: .16; }
.sh-svg .v-sea { fill: var(--ink); letter-spacing: .14em; font-weight: 800; opacity: .82; }
.sh-svg .v-sea .v-fr { fill: var(--ink); }
.sh-svg .v-domsea { letter-spacing: .06em; }
.sh-svg .v-halo { paint-order: stroke; stroke: var(--card); stroke-opacity: .8; stroke-width: 3px; stroke-linejoin: round; }
.sh-zoomed { flex: none; overflow: auto; max-height: 64vh; border-radius: var(--r); padding: 10px; background: var(--card); border: 2px solid var(--line); -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.sh-zoomed .sh-svg { max-width: none; }
.sh-zoomed.wide .sh-svg { width: 185%; }
.sh-rule { display: flex; flex-direction: column; gap: 12px; min-width: 0; padding: 12px 14px 16px; border-radius: var(--r-l); background: var(--card); border: 2px solid var(--line); box-shadow: 0 3px 0 var(--line); scroll-margin-top: 16px; }
.sh-rule-top { display: flex; align-items: center; gap: 10px; }
.sh-rule-top .six { flex: none; width: 68px; height: 68px; margin: -4px 0 -8px -6px; }
.sh-rule h3 { font-size: 20px; }
.sh-say { position: relative; padding: 10px 13px; border-radius: 14px; background: var(--g-l); color: var(--ink); font-size: 13.5px; font-weight: 600; line-height: 1.65; }
.sh-say::before { content: ""; position: absolute; left: 22px; top: -6px; width: 14px; height: 14px; background: var(--g-l); border-radius: 3px; transform: rotate(45deg); }
.sh-rule ol { counter-reset: shr; margin: 0; display: flex; flex-direction: column; gap: 12px; }
.sh-rule ol li { counter-increment: shr; position: relative; padding-left: 42px; font-size: 14.5px; line-height: 1.65; }
.sh-rule ol li::before { content: counter(shr); position: absolute; left: 0; top: 0; width: 32px; height: 28px; text-align: center; font-family: var(--f-disp); font-weight: 700; font-size: 16px; line-height: 28px; color: #fff; background: var(--g); clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.sh-rule li b { display: block; font-size: 15.5px; font-weight: 800; line-height: 1.5; }
.sh-asof { text-align: center; }

/* ---- recollections (机经) */
.rc-note { padding: 10px 14px; border-radius: var(--r); background: var(--warm-l); color: var(--ink); font-size: 13.5px; font-weight: 600; line-height: 1.6; }
.rc-note .hex-b { display: inline-block; margin-right: 7px; padding: 1px 8px; border-radius: 7px; background: var(--card); color: var(--warm-t); font-size: 12px; font-weight: 800; }
.rc-hero { gap: 14px; }
.rc-nums { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.rc-nums li { display: flex; flex-direction: column; min-width: 0; padding: 7px 10px 9px; border-radius: 16px; background: rgba(0, 0, 0, .2); }
.rc-nums b { font-family: var(--f-disp); font-weight: 700; font-size: 36px; line-height: 1.12; color: var(--sun); text-shadow: 0 3px 0 rgba(0, 0, 0, .16); }
.rc-nums span { font-size: 13px; font-weight: 800; line-height: 1.3; }
.rc-legend { display: flex; flex-wrap: wrap; gap: 6px; }
.rc-feed { display: flex; flex-direction: column; gap: 18px; }
.rc-month { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; min-width: 0; }
.rc-m { padding: 4px 14px; border-radius: 14px; background: var(--pop); color: var(--on-pop); font-size: 15px; font-weight: 800; line-height: 1.5; letter-spacing: .02em; }
.rc-list { align-self: stretch; display: flex; flex-direction: column; gap: 10px; min-width: 0; margin-left: 8px; padding-left: 10px; border-left: 4px solid var(--line); }
.rc-s { min-width: 0; background: var(--card); border: 2px solid var(--line); border-radius: var(--r); box-shadow: 0 3px 0 var(--line); overflow: hidden; }
.rc-s .crow { min-height: 54px; padding: 9px 12px 9px 12px; }
.rc-s .crow:active { background: var(--soft); }
.rc-top { display: flex; align-items: center; gap: 9px; }
.rc-top .tag { font-size: 12.5px; padding: 5px 8px; }
.tag.lv-csp { background: var(--g-l); color: var(--g-t); }
.tag.lv-cr { background: var(--t-droits-l); color: var(--ink); }
.tag.lv-nat { background: var(--t-institutions-l); color: var(--ink); }
.rc-n { font-size: 13.5px; font-weight: 700; color: var(--ink2); }
.rc-n b { font-family: var(--f-disp); font-weight: 700; font-size: 19px; color: var(--ink); }
.rc-s .cl { margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-s.on .cl { white-space: normal; }
.rq .qrow { padding-left: 10px; padding-right: 12px; }
.rq .i { width: 26px; height: 25px; padding: 0 0 3px; border-radius: 8px; background: var(--cl); color: var(--ink); box-shadow: inset 0 -3px 0 var(--c); font-size: 13.5px; line-height: 22px; text-align: center; }
.rq-x { grid-column: 2 / -1; display: flex; flex-wrap: wrap; gap: 6px; }

@media (max-width: 359px) {
  .kf .chip svg { display: none; }
  .kc-head h2 { font-size: 22px; }
  .kc-lead { font-size: 17px; }
  .kc-body, .kc-head, .kc-nav { padding-left: 13px; padding-right: 13px; }
  .sh-fig { padding: 0; }
  .sh-draw { padding: 10px 3px 8px; }
  .sh-nums .k { font-size: 26px; }
  .sh-nums .k.long { font-size: 20px; line-height: 1.56; }
  .sh-nums .k .sh-pic, .sh-pic { width: 19px; height: 19px; }
  .sh-nums .v { font-size: 12.5px; padding-left: 2px; padding-right: 2px; }
  .sh-nums .v i { font-size: 11.5px; }
  .sh-zoom { padding-right: 10px; }
  .rc-nums b { font-size: 30px; }
  .rc-nums li { padding: 6px 8px 8px; }
  .rc-list { margin-left: 4px; padding-left: 8px; }
  .wl .w { font-size: 15px; gap: 7px; }
  .wl .z { font-size: 14px; }
}
@media (min-width: 480px) {
  .sh-grid { gap: 22px; }
  .sh-card { padding: 0; }
  .sh-rows .v, .sh-card .v { font-size: 15px; }
  .sh-fig { padding: 0; }
  .sh-draw { padding: 14px 12px 12px; }
  .kmini { width: 150px; }
  .ks.grid ul { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (hover: hover) and (pointer: fine) {
  .ks:not(.grid) ul { scrollbar-width: thin; padding-bottom: 10px; }
  .ks:not(.grid) ul::-webkit-scrollbar { display: block; height: 8px; }
  .ks:not(.grid) ul::-webkit-scrollbar-thumb { background: var(--line); border-radius: 4px; }
}
@media (prefers-reduced-motion: no-preference) {
  .kmini, .voc, .sh-zoom { transition: transform .06s ease, box-shadow .06s ease; }
  .kc { animation: pop .22s ease both; }
}

/* ---- print: only the cram sheet (.sheetpage), black on white, two columns on A4 */
@media print {
  @page { size: A4; margin: 11mm; }
  body:has(.sheetpage) { background: #fff; }
  body:has(.sheetpage)::before { display: none; }
  .sheetpage ~ .tabs, .sheetpage ~ .veil, .sheetpage .seg, .sheetpage .pagehead, .sheetpage .sh-top .link, .sheetpage .sh-top .chip, .sheetpage .sh-zoom, .sheetpage .sh-cap, .sheetpage details, .sheetpage .sh-rule .six, .sheetpage .sec-h .hexic, .sheetpage .sh-fig figcaption > svg { display: none; }
  .sheetpage, .sheetpage [class*="t-"], .sheetpage [class*="v-e"] {
    --bg: #fff; --card: #fff; --soft: #fff; --line: #8a8a8a; --ink: #000; --ink2: #222; --g: #000; --g-d: #000; --g-t: #000; --g-l: #fff; --pop: #fff; --on-pop: #000;
    --sun: #fff; --sun-d: #000; --on-sun: #000; --water: #333; --c: #000; --cd: #000; --cl: #fff; --e: #fff; --el: #fff;
  }
  .sheetpage { color: #000; max-width: none; padding: 0; gap: 8px; }
  .sheetpage * { box-shadow: none; text-shadow: none; animation: none; }
  .sheetpage .sh-grid { display: block; column-count: 2; column-gap: 12px; }
  .sheetpage .sh-card, .sheetpage .sh-tiles, .sheetpage .sh-fig { break-inside: avoid; margin: 0 0 9px; gap: 3px; }
  .sheetpage .sec-h { font-size: 12px; letter-spacing: .04em; }
  .sheetpage .sh-rows { border: 1px solid var(--line); border-radius: 6px; }
  .sheetpage .sh-rows li { min-height: 0; padding: 2px 7px; gap: 6px; }
  .sheetpage .sh-rows li + li { border-top: 1px solid #c4c4c4; }
  .sheetpage .sh-rows .hexic { width: 18px; height: 18px; }
  .sheetpage .sh-rows .hexic .hx { display: none; }
  .sheetpage .sh-rows .hexic .sh-pic { width: 16px; height: 16px; }
  .sheetpage .sh-rows .k { font-size: 12.5px; }
  .sheetpage .sh-rows .k.n { font-size: 14px; }
  .sheetpage .k.hl, .sheetpage .nums .pass b { background: none; padding: 0; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }
  .sheetpage .sh-rows .v { font-size: 11.5px; line-height: 1.4; }
  .sheetpage .sh-rows .v i, .sheetpage .sh-nums .v i { font-size: 10.5px; }
  .sheetpage .sh-nums { gap: 4px; }
  .sheetpage .sh-nums li { border: 1px solid var(--line); border-radius: 6px; margin: 0; }
  .sheetpage .sh-nums .k, .sheetpage .sh-nums .k.hl { background: none; color: #000; font-size: 19px; line-height: 1.2; padding: 3px 2px 0; }
  .sheetpage .sh-nums .k.long { font-size: 16px; line-height: 1.4; }
  .sheetpage .sh-nums .k small { font-size: 11px; }
  .sheetpage .sh-nums .k .sh-pic { width: 15px; height: 15px; }
  .sheetpage .sh-nums .v { font-size: 10.5px; padding: 1px 3px 4px; font-weight: 600; }
  .sheetpage .sh-pic .p-b { fill: #555; stroke: #000; }
  .sheetpage .sh-pic .p-r { fill: #999; stroke: #000; }
  .sheetpage .nums li { padding: 4px 2px; border: 1px solid var(--line); border-radius: 6px; }
  .sheetpage .nums b { font-size: 21px; }
  .sheetpage .nums .pass, .sheetpage .nums .pass span { background: none; color: #000; }
  .sheetpage .sh-fig { border: 1px solid var(--line); border-radius: 6px; }
  .sheetpage .sh-fig figcaption { min-height: 0; padding: 3px 8px 0; background: none; color: #000; }
  .sheetpage .sh-fig h3 { font-size: 12px; color: #000; }
  .sheetpage .sh-draw { padding: 4px 6px 6px; }
  .sheetpage .sh-svg { max-width: 100%; }
  .sheetpage .sh-svg .v-w { fill: #000; }
  .sheetpage .sh-svg .v-hl, .sheetpage .sh-svg .v-pill, .sheetpage .sh-svg .v-blk, .sheetpage .sh-svg .v-box, .sheetpage .sh-svg .v-cit, .sheetpage .sh-svg .v-era { fill: #fff; stroke: #000; stroke-width: 1; }
  .sheetpage .sh-svg .v-hl { stroke-width: 2.4; }
  .sheetpage .sh-svg .v-pill.v-eu { stroke-dasharray: 3 2; }
  .sheetpage .sh-svg .v-rail, .sheetpage .sh-svg .v-span, .sheetpage .sh-svg .v-arrow-b, .sheetpage .sh-svg .v-ground, .sheetpage .sh-svg .v-seabg, .sheetpage .sh-svg .v-land0, .sheetpage .sh-svg .v-land, .sheetpage .sh-svg .v-dom { fill: none; stroke: none; }
  .sheetpage .sh-svg .v-coast { stroke: #000; }
  .sheetpage .sh-svg .v-pic-w { stroke: #000; }
  .sheetpage .sh-svg .v-city { stroke: none; }
  .sheetpage .sh-svg .v-sea { opacity: 1; }
  .sheetpage .sh-rule { break-inside: avoid; border: 1px solid var(--line); border-radius: 6px; padding: 6px 9px 8px; gap: 4px; }
  .sheetpage .sh-rule h3 { font-size: 14px; }
  .sheetpage .sh-say { padding: 0; background: none; font-size: 11.5px; line-height: 1.5; font-weight: 400; }
  .sheetpage .sh-say::before { display: none; }
  .sheetpage .sh-rule ol { gap: 3px; }
  .sheetpage .sh-rule ol li { padding-left: 20px; font-size: 11.5px; line-height: 1.5; }
  .sheetpage .sh-rule li b { display: inline; font-size: 11.5px; }
  .sheetpage .sh-rule ol li::before { color: #000; background: none; clip-path: none; width: 16px; height: auto; font-size: 12px; line-height: 1.5; text-align: left; }
  .sheetpage .sh-top .sub, .sheetpage .small { font-size: 11px; color: #000; }
  .sheetpage .foot { font-size: 9.5px; line-height: 1.5; break-inside: avoid; color: #000; }
  .sheetpage .foot a { color: inherit; }
  .sheetpage .foot .hex-b { background: none; padding: 0; }
}

/* (end of: study cards, words, cram sheet, recollections) */

/* ---------------------------------------------------------------------------------------------------- */

/* ==== screens: registration, self-check, about, payment states ==== */
/* --- registration: seven steps, one open at a time */
.reg-own { display: flex; align-items: center; gap: 8px; padding: 8px 12px; border-radius: 14px; background: var(--g-l); color: var(--g-t); font-size: 13.5px; font-weight: 700; line-height: 1.4; }
.reg-own svg { flex: none; width: 20px; height: 20px; }
.reg .topbar .chip { flex: none; }
.reg .steps { gap: 0; background: var(--card); border: 2px solid var(--line); border-radius: var(--r-l); box-shadow: 0 3px 0 var(--line); padding: 6px 14px 6px 12px; }
.reg .steps > li { padding-left: 52px; gap: 0; align-items: stretch; }
.reg .steps > li::before { left: 0; top: 8px; width: 40px; height: 36px; font-size: 18px; background: var(--soft); color: var(--ink2); z-index: 1; pointer-events: none; }
.reg .steps > li.on::before { background: var(--g); color: #fff; }
.reg .steps > li::after { content: ""; position: absolute; left: 18px; top: 46px; bottom: -6px; width: 4px; border-radius: 2px; background: var(--soft); pointer-events: none; }
.reg .steps > li:last-child::after { display: none; }
.step-h { display: flex; align-items: center; gap: 8px; min-height: 52px; width: calc(100% + 52px); margin-left: -52px; padding-left: 52px; text-align: left; color: var(--ink); }
.step-h b { flex: 1 1 0; min-width: 0; font-size: 16.5px; font-weight: 800; line-height: 1.3; }
.step-h .chev { flex: none; width: 18px; height: 18px; color: var(--ink2); transform: rotate(90deg); }
.steps > li.on .step-h .chev { transform: rotate(-90deg); }
.steps > li.on .step-h b { color: var(--g-t); }
.step-b { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; padding: 0 0 14px; min-width: 0; }
.step-b > p { font-size: 15px; line-height: 1.55; }
.step-b > .list { align-self: stretch; border-radius: var(--r); margin: 2px 0 4px; }
.step-b > .list .lrow { min-height: 56px; padding: 8px 12px; }
.step-b > .list .t1 { font-family: var(--f-lat); font-size: 15px; }
.step-b > details { align-self: stretch; }
.step-b > details .in p { font-size: 14px; line-height: 1.6; color: var(--ink2); }
.step-b .btn svg { width: 17px; height: 17px; }
.step-n { align-self: flex-end; min-height: 40px; display: inline-flex; align-items: center; text-decoration: none; }
.go.out { font-weight: 800; font-size: 18px; line-height: 1; color: var(--g-t); }
/* --- registration: the centre finder */
.finder { gap: 12px; padding: 14px 16px 16px; scroll-margin-top: 12px; }
.fd-head { display: flex; align-items: center; gap: 10px; }
.fd-head h2 { font-size: 22px; display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; }
.fd-n { padding: 2px 9px; border-radius: 9px; background: rgba(0, 0, 0, .18); font-size: 13px; font-weight: 700; white-space: nowrap; }
.fd-n b { font-size: 16px; font-weight: 700; color: var(--sun); }
.fd-head .sub { font-size: 13.5px; line-height: 1.4; }
.fd-head .six { flex: none; width: 70px; height: 70px; margin: -8px -6px -10px 0; }
.finder .btn.white { --bt: #10302A; }
.fd-q { position: relative; }
.fd-q > svg { position: absolute; left: 15px; top: 17px; width: 24px; height: 24px; color: var(--ink2); pointer-events: none; z-index: 1; }
.fd-q input { -webkit-appearance: none; appearance: none; min-height: 58px; padding-left: 48px; font-size: 17px; border-color: transparent; border-radius: 18px; box-shadow: 0 4px 0 rgba(0, 0, 0, .16); }
.fd-q input:focus { border-color: var(--sun); box-shadow: 0 0 0 3px rgba(255, 201, 51, .55); }
.fd-q input::placeholder { font-size: 15px; }
.fd-none { display: flex; align-items: center; gap: 10px; }
.fd-none .six { flex: none; width: 46px; height: 46px; margin: -2px 0 -2px -4px; }
#ccount b { font-size: 18px; color: var(--ink); }
.reg .centres { gap: 12px; }
.reg .centre { border-radius: var(--r-l); box-shadow: 0 3px 0 var(--line); padding: 12px 14px 10px; gap: 3px; }
.c-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.centre .cc { font-family: var(--f-lat); font-size: 18px; font-weight: 800; line-height: 1.3; }
.centre .cc .num { font-size: 19px; font-weight: 700; color: var(--g-t); margin-right: 3px; }
.reg .centre .tag { flex: none; font-size: 12.5px; padding: 5px 8px; }
.reg .centre .cn { flex: none; font-family: var(--f-lat); font-size: 15px; font-weight: 800; line-height: 1.4; }
.reg .centre .cd { font-family: var(--f-lat); font-weight: 600; line-height: 1.45; overflow-wrap: anywhere; }
.c-acts { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 8px; margin-top: 9px; }
.c-acts .btn { padding: 5px 4px; gap: 5px; }
.c-acts .btn svg { width: 17px; height: 17px; }
.fd-notes .facts { font-size: 14px; line-height: 1.6; }
.fd-notes a { color: var(--g-t); font-weight: 700; }

/* --- self-check: a short quiz with 小玛 */
.chk-hi { display: flex; align-items: center; gap: 12px; }
.chk-hi .six { flex: none; width: 84px; height: 84px; margin: -6px 0 -8px -6px; }
.chk-hi .say { font-size: 15px; box-shadow: 0 3px 0 var(--line); }
.chk-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.chk-prog { display: flex; align-items: center; gap: 7px; min-height: 26px; }
.chk-prog i { flex: none; width: 22px; height: 20px; background: var(--soft); clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.chk-prog i.done { background: var(--g); }
.chk-prog i.now { width: 28px; height: 25px; background: var(--sun); }
.chk-prog .lab { margin-left: auto; font-size: 13.5px; font-weight: 700; color: var(--ink2); }
.chk-prog .lab b { font-family: var(--f-disp); font-size: 19px; color: var(--ink); padding: 0 1px; }
.chk .chk-said { flex-direction: row; flex-wrap: wrap; gap: 9px 8px; background: none; border: 0; border-radius: 0; overflow: visible; margin-top: -6px; }
.chk .chk-said li { display: block; padding: 0; min-width: 0; max-width: 100%; }
.chk .chk-said li + li { border-top: 0; }
.chk-said .chip { max-width: 100%; white-space: normal; text-align: left; padding: 5px 10px 5px 12px; gap: 8px; }
.chk-said .chip .a { font-size: 14px; font-weight: 700; line-height: 1.3; }
.chk-said .ed { flex: none; padding-left: 8px; border-left: 2px solid var(--line); color: var(--g-t); font-size: 13px; font-weight: 800; }
.chk .chk-q h2 { font-size: 22px; line-height: 1.35; }
.chk .chk-opt { min-height: 68px; }
.chk-opt .hexic { width: 38px; height: 38px; }
.chk-opt .t1, .chk-opt .t2 { display: block; }
.chk-opt .t2 { font-family: var(--f-lat); margin-top: 1px; }
.chk .chk-res { --v: var(--t-droits); --vd: var(--t-droits-d); padding: 0; gap: 0; overflow: hidden; border-color: var(--v); box-shadow: 0 4px 0 var(--vd); margin-bottom: 4px; }
.chk .chk-res.yes { --v: var(--pop); --vd: var(--sun-d); }
.chk .chk-res.no { --v: var(--g); --vd: var(--g-d); }
.chk-v { position: relative; overflow: hidden; display: flex; align-items: center; gap: 8px; padding: 14px 16px 16px 8px; background: var(--v); color: #fff; }
.chk-v > .deco { position: absolute; right: -34px; top: -40px; width: 136px; height: 136px; color: #fff; opacity: .09; pointer-events: none; }
.chk-v > .six { position: relative; flex: none; width: 92px; height: 92px; }
.chk-v > .grow { position: relative; }
.chk-v h2 { font-size: 21px; line-height: 1.3; }
.chk-v h2.solo { font-size: 30px; letter-spacing: .04em; }
.chk-v .confetti .cf:nth-child(-n+3) { display: none; }
.chk-v mark { background: none; color: var(--sun); white-space: nowrap; }
.chk .chk-res .chk-stamp { display: inline-block; margin-bottom: 5px; background: rgba(255, 255, 255, .22); color: #fff; font-size: 13px; }
.chk .chk-res.yes .chk-stamp { background: var(--sun); color: var(--on-sun); }
.chk-res .facts { padding: 14px 16px 16px; font-size: 14.5px; line-height: 1.65; }
.chk-res.yes .facts li::before { background: var(--sun-d); }
.chk-res.maybe .facts li::before { background: var(--t-droits); }
.chk-legal { display: flex; flex-direction: column; }

/* --- about: questions and short answers */
.faq { gap: 10px; }
.faq-c > summary { gap: 12px; min-height: 60px; padding: 8px 14px 8px 12px; font-size: 16.5px; }
.faq-c > summary .hexic { width: 38px; height: 38px; }
.faq-c[open] > summary .hexic { color: var(--g-l); }
.faq-c > .in { padding: 2px 16px 16px; gap: 12px; }
.faq-c > .in > p { font-size: 15px; line-height: 1.6; }
.faq-c > .in > p.small { font-size: 12.5px; }
.faq-c .facts { font-size: 14.5px; line-height: 1.6; }
.faq-c .btn { align-self: flex-start; }
.faq-c .nums li:not(.pass) { background: var(--soft); border-color: transparent; box-shadow: none; }
.faq-own { display: flex; flex-direction: column; gap: 10px; }
.faq-own li { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; align-items: start; }
.faq-own p { font-size: 14.5px; line-height: 1.55; }
.faq-own .tag { margin-top: 2px; font-size: 12px; padding: 5px 8px; }

/* --- unlock page: back from paying, not unlocked yet */
.pay-state { display: flex; flex-direction: column; gap: 12px; }
.pay-state.busy { border-color: var(--g); box-shadow: 0 3px 0 var(--g); }
.pay-state.fail { border-color: var(--red); box-shadow: 0 3px 0 var(--red-d); }
.ps-head { display: flex; align-items: center; gap: 8px; }
.ps-head .six { flex: none; width: 72px; height: 72px; margin: -8px 0 -8px -10px; }
.ps-head h2 { font-size: 19px; }
.pay-state .msg { padding: 10px 12px; border-radius: var(--r-s); font-size: 14.5px; line-height: 1.55; }
.pay-state.wait .msg.bad, .pay-state.busy .msg.bad { background: var(--soft); color: var(--ink); }
.pay-state.fail .msg.bad { background: var(--red-l); color: var(--red-t); }
.ps-bar { overflow: hidden; }
.ps-bar i { width: 100%; background: repeating-linear-gradient(-45deg, var(--g) 0 10px, var(--g-l) 10px 20px); }
.ps-bar i::after { display: none; }
.ps-help { text-align: center; overflow-wrap: anywhere; }

/* --- the "report a mistake" sheet: the number to copy stands out */
.rep-id { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 10px 14px; border-radius: var(--r); background: var(--card); border: 2px solid var(--line); }
.rep-id span { font-size: 13px; font-weight: 700; color: var(--ink2); }
.rep-id .code { font-size: 24px; }
.rep-to { overflow-wrap: anywhere; }

@media (max-width: 359px) {
  .reg .steps { padding-right: 10px; }
  .fd-head .six { width: 58px; height: 58px; }
  .fd-q input { padding-left: 44px; }
  .fd-q input::placeholder { font-size: 13.5px; }
  .c-acts { gap: 6px; }
  .c-acts .btn { font-size: 13.5px; }
  .chk-hi .six { width: 68px; height: 68px; }
  .chk-v > .six { width: 72px; height: 72px; }
  .chk-v h2 { font-size: 19px; }
  .chk .chk-q h2 { font-size: 20px; }
  .ps-head .six { width: 60px; height: 60px; }
}
@media (prefers-reduced-motion: no-preference) {
  .step-b, .chk-res { animation: pop .26s ease both; }
  .ps-bar i { width: 40%; background: var(--g); animation: ps-slide 1.8s ease-in-out infinite alternate; }
  .ps-bar i::after { display: block; }
  @keyframes ps-slide { from { transform: translateX(-20%); } to { transform: translateX(170%); } }
}

/* (end of: registration, self-check, about, payment states) */

/* ---- a short note when the phone cannot read French aloud ---- */
#saynote { position: fixed; z-index: 30; left: 12px; right: 12px; bottom: calc(92px + env(safe-area-inset-bottom, 0px)); max-width: 520px; margin: 0 auto; padding: 12px 16px; border-radius: var(--r); background: var(--ink); color: var(--bg); font-size: 14px; line-height: 1.55; box-shadow: 0 8px 24px rgba(0, 0, 0, .25); }


/* ==== screens: sign-in ==== */
.login-card h2 { font-size: 19px; }
.login-card .field input { flex: 1 1 auto; font-size: 17px; }
.linkbtn { background: none; border: 0; padding: 10px 6px; font: inherit; font-weight: 700; color: var(--g-t); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.acct { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 8px; margin: -4px 2px; }
.acct b { overflow-wrap: anywhere; }
.acct .linkbtn { padding: 6px 4px; }

/* ==== the "put it on the home screen" steps ==== */
.a2hs { display: flex; flex-direction: column; gap: 10px; padding-left: 22px; margin: 4px 0 14px; font-size: 15.5px; line-height: 1.6; }
.a2hs li { list-style: decimal; }

/* ==== the offer at the top of the home page ==== */
.pay.hot { border-color: var(--sun); box-shadow: 0 4px 0 var(--sun-d, #E0A800); }
.pay-more { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px 18px; margin: -4px 0 -2px; }
.pay-more a { padding: 6px 2px; font-size: 13.5px; font-weight: 700; color: var(--ink2); text-decoration: underline; text-underline-offset: 3px; }

/* ==== the recollections on the home page ==== */
.rc-home { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; border-color: var(--c-histoire, var(--sun)); box-shadow: 0 3px 0 var(--c-histoire, var(--sun-d)); }
.rc-home .t1 { display: block; font-size: 17px; font-weight: 800; line-height: 1.3; }
.rc-home .t2 { display: block; font-size: 13px; color: var(--ink2); font-weight: 600; }
.rc-home .go { font-size: 26px; font-weight: 800; color: var(--ink2); line-height: 1; }
