/* Pastel Apple theme for the site's own pages (home, worked solutions, about, privacy, register, 404).
   Values and treatments come from the pastel-apple-design skill (assets/pastel-apple.css): same tokens,
   type scale, radii, frosted nav, surface panels with voice pills, tinted tiles, ink CTAs.
   Loaded after site.css and wif.css; it re-points their tokens and restyles their components, so the
   worked-solutions project builds unchanged. Lesson pages do not load it (they carry base.css). */
:root{
  /* Pastel Apple tokens */
  --bg:#ffffff; --surface:#f5f5f7; --card:#ffffff; --ink:#1d1d1f; --ink-2:#6e6e73; --line:#e3e3e8;
  --sky:#ddeeff; --sky-ink:#1f68c4; --mint:#dcf6e8; --mint-ink:#1c7a4c; --lav:#ebe5fd; --lav-ink:#5b45c9;
  --peach:#ffe6d6; --peach-ink:#b8531f; --butter:#fff4c9; --butter-ink:#8a6d00; --rose:#ffe0ea; --rose-ink:#bf3563;
  --grad:linear-gradient(90deg,#8a6cff,#3d9bff 50%,#2fbf85);
  --font:-apple-system,BlinkMacSystemFont,"SF Pro Display","SF Pro Text","Inter","Segoe UI","Noto Sans Math","Cambria Math",system-ui,sans-serif;
  --shadow:0 1px 2px rgba(0,0,0,.04),0 8px 28px rgba(0,0,0,.06);
}
@media (prefers-color-scheme:dark){:root:not([data-theme="light"]){
  --bg:#000000; --surface:#1c1c1e; --card:#161618; --ink:#f5f5f7; --ink-2:#a1a1a6; --line:#2c2c2e;
  --sky:#10223a; --sky-ink:#8cc4ff; --mint:#12291e; --mint-ink:#86e3b3; --lav:#1f1a36; --lav-ink:#b9a8ff;
  --peach:#2f1c12; --peach-ink:#ffb48a; --butter:#2b2410; --butter-ink:#f2d36b; --rose:#2f1520; --rose-ink:#ff9dbc;
  --grad:linear-gradient(90deg,#b9a8ff,#8cc4ff 50%,#86e3b3); --shadow:none; color-scheme:dark}}
:root[data-theme="dark"]{
  --bg:#000000; --surface:#1c1c1e; --card:#161618; --ink:#f5f5f7; --ink-2:#a1a1a6; --line:#2c2c2e;
  --sky:#10223a; --sky-ink:#8cc4ff; --mint:#12291e; --mint-ink:#86e3b3; --lav:#1f1a36; --lav-ink:#b9a8ff;
  --peach:#2f1c12; --peach-ink:#ffb48a; --butter:#2b2410; --butter-ink:#f2d36b; --rose:#2f1520; --rose-ink:#ff9dbc;
  --grad:linear-gradient(90deg,#b9a8ff,#8cc4ff 50%,#86e3b3); --shadow:none; color-scheme:dark}

/* site.css and wif.css tokens mapped onto the Pastel Apple ones. The :not(#…) raises specificity above
   site.css's own dark-mode blocks; the values are var() references, so they still follow the theme. */
:root:not(#pa-map){
  /* site.css tokens mapped onto them */
  --paper:var(--card); --soft:var(--surface);
  --navy:var(--sky-ink); --navy-soft:var(--sky); --blue:var(--sky-ink);
  --gold:var(--butter-ink); --gold-soft:var(--butter); --green:var(--mint-ink); --green-soft:var(--mint);
  --violet:var(--lav-ink); --violet-soft:var(--lav); --rose-soft:var(--rose); --hl:var(--butter);
  --serif:var(--font); --sans:var(--font); --radius:24px;
  /* wif.css tokens */
  --wif-ink:var(--ink); --wif-ink2:var(--ink-2); --wif-line:var(--line); --wif-card:var(--card); --wif-soft:var(--surface);
  --wif-accent:var(--sky-ink); --wif-ok:var(--mint-ink); --wif-bad:var(--rose-ink);
}

/* ---------- type ---------- */
body{font-family:var(--font);font-size:18px;line-height:1.55}
a{color:var(--sky-ink)}
:focus-visible{outline-color:var(--sky-ink);border-radius:6px}
h1,h2,h3,h4{color:var(--ink);font-weight:700;letter-spacing:-.02em}
p,li{max-width:65ch}
.g{background:var(--grad);-webkit-background-clip:text;background-clip:text;color:transparent}
.kicker{font-size:14px;font-weight:600;color:var(--sky-ink);letter-spacing:.02em;text-transform:none}

/* ---------- nav (frosted, like the skill's <nav>) ---------- */
.top{background:color-mix(in srgb,var(--bg) 78%,transparent);backdrop-filter:saturate(180%) blur(20px);-webkit-backdrop-filter:saturate(180%) blur(20px);top:env(safe-area-inset-top,0px)}
.top .in{padding:12px 20px;font-size:14px}
.wif-home .top .in{max-width:1000px}
.brand{color:var(--ink);font-weight:600;letter-spacing:0}
.brand span{color:inherit}
.crumbs,.crumbs a{color:var(--ink-2)}

/* ---------- layout ---------- */
/* solution pages keep site.css's 1180px wrap with the 300px rail; the plain pages use the skill's 1000px container */
.wif-home .wrap{max-width:1000px}

/* ---------- problem page ---------- */
.ph{padding:48px 0 8px}
.ph h1{font-size:clamp(32px,5vw,48px);letter-spacing:-.03em;line-height:1.08}
.ph .meta{font-size:14.5px}
.tag{font-size:12.5px;font-weight:700;letter-spacing:.04em;padding:3px 10px;background:var(--sky);color:var(--sky-ink)}
.tag.t-ex{background:var(--lav);color:var(--lav-ink)}
.tag.t-misc{background:var(--butter);color:var(--butter-ink)}
.tag.t-mcq{background:var(--rose);color:var(--rose-ink)}

/* boxes become surface panels with a voice pill (skill: .explain + .voice) */
.box{background:var(--surface);border:0;border-left:0;border-radius:24px;padding:22px 26px;margin:22px 0;box-shadow:none}
.box .lbl{display:inline-block;font-size:12.5px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;
  padding:4px 10px;border-radius:999px;margin-bottom:10px;background:var(--sky);color:var(--sky-ink)}
.q{background:var(--card);border:1px solid var(--line)}
.idea .lbl{background:var(--butter);color:var(--butter-ink)}
.gfa{background:var(--surface)}
.gfa dt{color:var(--sky-ink);font-weight:600}
.result{background:var(--mint);color:var(--mint-ink)}
.result .lbl{background:var(--card);color:var(--mint-ink)}
.take .lbl{background:var(--lav);color:var(--lav-ink)}
.pit .lbl{background:var(--rose);color:var(--rose-ink)}
.check .lbl{background:var(--mint);color:var(--mint-ink)}

/* section headings: a sentence-sized heading, no rule (the skill separates with space) */
h2.sec{font-size:clamp(24px,3.2vw,30px);letter-spacing:-.025em;line-height:1.15;border-bottom:0;padding-bottom:0;margin:52px 0 16px}

/* basics you need */
.needs{gap:12px}
.need{background:var(--surface);border:0;border-radius:18px;padding:14px 18px}
.need .n{background:var(--sky-ink);color:var(--bg);font-weight:700}
.need p{font-size:17px}

/* steps */
ol.steps>li::before{font-weight:700;font-size:13px;letter-spacing:.08em;text-transform:uppercase;color:var(--ink-2)}
ol.steps h3{font-size:21px;letter-spacing:-.02em}
.why,.basic{background:var(--surface);border-radius:18px;padding:12px 16px;font-size:17px}
.why::before,.basic::before{display:inline-block;font-size:12px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;
  padding:2px 9px;border-radius:999px;margin-right:8px;vertical-align:1px}
.why::before{content:"Why";background:var(--butter);color:var(--butter-ink)}
.basic::before{content:"Basic behind it";background:var(--sky);color:var(--sky-ink)}
.hl{background:var(--butter);color:inherit}

/* figures and tables (skill: figure panels on --surface, .tablewrap) */
figure.fig{background:var(--surface);border:0;border-radius:28px;padding:18px}
figure.fig figcaption{font-style:normal;font-size:14.5px}
.tw{background:var(--surface);border-radius:20px}
table.t{background:transparent}
table.t th,table.t td{padding:12px 16px;border-bottom:0}
table.t th{font-size:13px;font-weight:600;letter-spacing:.03em;border-bottom:0}
table.t tr+tr td,table.t tr+tr th{border-top:1px solid var(--line);border-bottom:0}

/* side rail */
.rail{top:84px;font-size:14.5px}
.rail .box{background:var(--surface);border:0;border-radius:24px;padding:18px 20px;margin:0}
.rail h4{font-size:13px;font-weight:700;letter-spacing:.08em;color:var(--ink-2)}
.rail a:hover,.rail li.on>a{color:var(--sky-ink)}

/* previous / next, problem lists */
.pn a{background:var(--surface);border:0;border-radius:24px;padding:16px 20px}
.pn a:hover{background:var(--sky);color:var(--sky-ink)}
.plist{gap:8px}
.plist a,.plist span.x{background:var(--surface);border:0;border-radius:18px;padding:13px 18px;font-size:15.5px}
.plist a:hover{background:var(--sky)}
.plist .pid{color:var(--sky-ink);font-weight:700}

/* buttons: the skill's .cta (ink pill) and .cta.alt (surface pill) */
.btn{background:var(--ink);color:var(--bg);font-weight:600;font-size:15px;padding:10px 18px;border:0}
.btn:hover{opacity:.88}
.btn.alt{background:var(--surface);color:var(--ink);border:0}
.lessonlinks{gap:10px}

footer.foot{text-align:center;font-size:14px;padding:40px 0 48px}

/* ---------- home ---------- */
.wif-home .hero{text-align:center;padding:72px 0 8px}
.wif-home .hero .kicker{font-size:14px}
.wif-home .hero h1{font-size:clamp(44px,7vw,72px);line-height:1.04;letter-spacing:-.035em;margin:.2em 0 .25em}
.wif-home .hero .lead{font-size:clamp(19px,2.4vw,24px);line-height:1.4;max-width:40ch;margin:0 auto;text-wrap:balance}
.wif-home .ctas{display:flex;flex-wrap:wrap;gap:10px;justify-content:center;margin-top:26px}
.wif-home .cta{display:inline-flex;align-items:center;gap:8px;background:var(--ink);color:var(--bg);text-decoration:none;font-weight:600;font-size:16px;padding:11px 20px;border-radius:999px}
.wif-home .cta:hover{opacity:.88}
.wif-home .cta.alt{background:var(--surface);color:var(--ink)}
.wif-pills{justify-content:center;gap:8px;margin:26px 0 0}
.wif-pills+.wif-pills{margin-top:8px}
.wif-pill{font-size:14.5px;font-weight:400;padding:7px 14px;background:var(--surface);border:0;color:var(--ink-2)}
.wif-pill b{color:var(--ink);font-weight:600}
.wif-prose .hero{text-align:left;padding:56px 0 8px}
.wif-prose .hero h1,.wif-home .hero.plain h1{font-size:clamp(36px,6vw,56px);letter-spacing:-.03em}
.wif-prose h2{font-size:clamp(24px,3.2vw,30px);letter-spacing:-.025em}

/* chapter tiles, grouped by the two NCERT books; rows always fill (no lone tile) */
.wif-book{margin-top:64px}
.wif-book .part{font-size:13px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--ink-2);margin-bottom:8px}
.wif-book h2{font-size:clamp(32px,5vw,48px);letter-spacing:-.03em;line-height:1.08;margin:0 0 6px;text-wrap:balance}
.wif-book .sub{color:var(--ink-2);font-size:20px;max-width:62ch;margin:0}
.chgrid{grid-template-columns:repeat(3,minmax(0,1fr));gap:16px;margin:24px 0 0}
@media (max-width:860px){.chgrid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:560px){.chgrid{grid-template-columns:minmax(0,1fr)}}
.wif-ch{border:0;border-radius:24px;padding:24px;gap:8px;background:var(--c-bg);transition:transform .2s}
.wif-ch:hover{transform:translateY(-3px)}
.wif-ch .no{font-size:13px;font-weight:600;letter-spacing:.04em;color:var(--c-ink)}
.wif-ch h3{font-size:22px;line-height:1.2;letter-spacing:-.02em}
.wif-ch h3 a{color:var(--ink)}
.wif-ch p{font-size:15.5px;line-height:1.5;color:var(--ink);opacity:.75}
.wif-ch .acts{margin-top:auto;padding-top:8px;gap:6px}
.wif-ch .acts .btn{background:var(--c-ink);color:var(--bg);font-size:13.5px;padding:7px 12px;white-space:nowrap}
.wif-ch .acts .btn.alt{background:var(--card);color:var(--c-ink)}
.wif-ch .acts .soon{font-size:14px;color:var(--c-ink);opacity:.85}
.wif-ch.t-sky{--c-bg:var(--sky);--c-ink:var(--sky-ink)}
.wif-ch.t-lav{--c-bg:var(--lav);--c-ink:var(--lav-ink)}
.wif-ch.t-mint{--c-bg:var(--mint);--c-ink:var(--mint-ink)}
.wif-ch.t-peach{--c-bg:var(--peach);--c-ink:var(--peach-ink)}
.wif-ch.t-butter{--c-bg:var(--butter);--c-ink:var(--butter-ink)}
.wif-ch.t-rose{--c-bg:var(--rose);--c-ink:var(--rose-ink)}
/* Book II has 7 chapters: the first and last tiles span two columns so every row is full (3 columns),
   and in 2 columns the first spans the row */
@media (min-width:861px){.chgrid.seven>.wif-ch:first-child,.chgrid.seven>.wif-ch:last-child{grid-column:span 2}}
@media (min-width:561px) and (max-width:860px){.chgrid.seven>.wif-ch:first-child{grid-column:span 2}}
@media (prefers-reduced-motion:reduce){.wif-ch{transition:none}.wif-ch:hover{transform:none}}

/* registration card (skill: bordered card like .recipe, ink CTA) */
.wif-upd{border-radius:24px;box-shadow:none;padding:26px 26px 20px;margin-top:64px}
.wif-upd h3{font-size:22px;letter-spacing:-.02em}
.wif-form input[type=text],.wif-form input[type=email]{border-radius:12px;background:var(--surface);border-color:transparent}
.wif-form button{background:var(--ink);color:var(--bg);font-weight:600;font-size:16px;padding:11px 20px}
.wif-acct .wif-join{background:var(--ink);color:var(--bg);font-weight:600}
.fbask .lbl{background:var(--butter);color:var(--butter-ink)}

/* exam answer | full explanation switch (worked solutions) */
.vswitch{background:var(--surface);border:0;padding:4px;border-radius:999px}
.vswitch button{font-family:var(--font);font-weight:600;color:var(--ink-2)}
.vswitch button[aria-pressed="true"]{background:var(--ink);color:var(--bg)}
.exam{background:var(--card);border:1px solid var(--line);box-shadow:none}
.exam .lbl{background:var(--mint);color:var(--mint-ink)}
.exam .note{font-family:var(--font);color:var(--ink-2);border-top-color:var(--line)}
.vmore{font-family:var(--font);color:var(--ink-2)}
.vmore button{font-family:var(--font);color:var(--sky-ink)}
@media (max-width:640px){.exam{padding:16px 12px 16px 14px}}
/* a long formula in a problem title cannot wrap: draw title maths a little smaller on phones */
@media (max-width:480px){.ph h1 .katex{font-size:.86em}}

/* ============ two learning paths: rounded display type, colour tints, illustrations ============ */
:root{--round:ui-rounded,"SF Pro Rounded","Nunito",var(--font)}
.t-sky{--c-bg:var(--sky);--c-ink:var(--sky-ink)}.t-lav{--c-bg:var(--lav);--c-ink:var(--lav-ink)}
.t-mint{--c-bg:var(--mint);--c-ink:var(--mint-ink)}.t-peach{--c-bg:var(--peach);--c-ink:var(--peach-ink)}
.t-butter{--c-bg:var(--butter);--c-ink:var(--butter-ink)}.t-rose{--c-bg:var(--rose);--c-ink:var(--rose-ink)}
/* the mode decides which wording shows: m-x on Go for it, m-f otherwise */
.m-x{display:none}html[data-view="exam"] .m-x{display:inline}html[data-view="exam"] .m-f{display:none}

/* hero: text + picture */
.home2 .hero.hero2{display:grid;grid-template-columns:minmax(0,1.05fr) minmax(0,1fr);gap:24px;align-items:center;text-align:left;padding:56px 0 8px}
.home2 .hero2 h1{font-family:var(--round);font-weight:800;font-size:clamp(42px,6.4vw,68px);letter-spacing:-.025em;line-height:1.02;text-wrap:balance}
.home2 .hero2 .lead{margin:0;max-width:34ch}
.home2 .hero2 .wif-pills,.home2 .hero2 .ctas{justify-content:flex-start}
.home2 .hero2 .kicker{color:var(--mint-ink)}
.hero-pic{min-width:0}
.hero-art{display:block;width:100%;height:auto;max-width:560px;margin-inline:auto;overflow:visible}
@media (max-width:820px){
  .home2 .hero.hero2{grid-template-columns:minmax(0,1fr);text-align:center;padding-top:28px;gap:8px}
  .home2 .hero2 .lead{margin:0 auto}
  .home2 .hero2 .wif-pills,.home2 .hero2 .ctas{justify-content:center}
  .hero-pic{order:-1}.hero-art{max-width:380px}}
/* illustration parts (all colours from the tokens, so dark mode follows) */
.b-sky{fill:var(--sky)}.b-lav{fill:var(--lav)}.b-mint{fill:var(--mint)}.b-peach{fill:var(--peach)}
.card-g{filter:drop-shadow(0 6px 14px rgba(0,0,0,.08))}
.c-card{fill:var(--card);stroke:var(--line);stroke-width:1.5}
.c-axis{fill:none;stroke:var(--ink-2);stroke-width:2;opacity:.45;stroke-linecap:round}
.c-area{fill:var(--mint);opacity:.9}
.c-curve{fill:none;stroke:var(--sky-ink);stroke-width:4.5;stroke-linecap:round}
.c-dot{fill:var(--rose-ink)}
.c-ink{fill:none;stroke:var(--lav-ink);stroke-width:4;stroke-linecap:round;stroke-linejoin:round}
.c-int{stroke:var(--peach-ink);stroke-width:6}
.c-t{fill:var(--ink);font:800 25px var(--round);text-anchor:middle}
.c-s{fill:var(--peach-ink);font:italic 700 20px var(--round)}
.c-die{fill:var(--butter);stroke:var(--butter-ink);stroke-width:2}.c-pip{fill:var(--butter-ink)}
.spark path{fill:var(--butter-ink);opacity:.75}
@keyframes wif-float{50%{translate:0 -7px}}
.hero-art .card-g{animation:wif-float 6s ease-in-out infinite}
.hero-art .card-g:nth-of-type(2){animation-delay:-1.5s}.hero-art .card-g:nth-of-type(3){animation-delay:-3s}.hero-art .card-g:nth-of-type(4){animation-delay:-4.5s}

/* the two paths */
.paths{margin-top:56px;scroll-margin-top:80px}
.paths>h2{font-family:var(--round);font-weight:800;font-size:clamp(32px,5vw,46px);letter-spacing:-.02em;line-height:1.08;margin:0 0 6px;text-align:center;text-wrap:balance}
.paths>.sub{color:var(--ink-2);font-size:19px;text-align:center;margin:0 auto;max-width:52ch}
.path-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-top:26px}
@media (max-width:700px){.path-grid{grid-template-columns:minmax(0,1fr)}}
.path{position:relative;display:flex;flex-direction:column;gap:8px;background:var(--c-bg);border-radius:28px;padding:22px 26px 26px;
  outline:3px solid transparent;outline-offset:-3px;transition:outline-color .2s}
.path-art{width:180px;max-width:60%;height:auto;align-self:center;overflow:visible}
.path-kick{font-size:13px;font-weight:700;letter-spacing:.06em;text-transform:uppercase;color:var(--c-ink)}
.path h3{font-family:var(--round);font-weight:900;font-size:clamp(32px,4.4vw,42px);letter-spacing:-.02em;line-height:1;margin:0;color:var(--ink)}
.path ul{list-style:none;padding:0;margin:4px 0 10px;display:grid;gap:6px}
.path li{position:relative;padding-left:28px;font-size:17px;line-height:1.4}
.path li::before{content:"✓";position:absolute;left:0;top:0;width:20px;height:20px;border-radius:50%;background:var(--card);color:var(--c-ink);
  font-size:12px;font-weight:800;display:grid;place-items:center;margin-top:2px}
.path-go{margin-top:auto;align-self:flex-start;font:800 17px var(--round);letter-spacing:.01em;border:0;cursor:pointer;
  background:var(--c-ink);color:var(--bg);padding:13px 22px;border-radius:999px}
.path-go:hover{opacity:.9}
.path-go:focus-visible{outline:3px solid var(--ink);outline-offset:2px}
.path-on{display:none;position:absolute;top:16px;right:16px;font:800 13px var(--round);background:var(--c-ink);color:var(--bg);padding:5px 11px;border-radius:999px}
html[data-view="exam"] .path.p-x,html[data-view="full"] .path.p-f{outline-color:var(--c-ink)}
html[data-view="exam"] .path.p-x .path-on,html[data-view="full"] .path.p-f .path-on{display:inline-block}
.path-note{display:none;text-align:center;margin:16px auto 0;color:var(--ink-2);font-size:16px}
html[data-view] .path-note{display:block}
.p-road{fill:none;stroke:var(--card);stroke-width:14;stroke-linecap:round}
.p-dash{fill:none;stroke:var(--mint-ink);stroke-width:2.5;stroke-dasharray:6 7;stroke-linecap:round;opacity:.6}
.p-flag{stroke:var(--ink-2);stroke-width:3;stroke-linecap:round}.p-flagc{fill:var(--mint-ink)}
.p-ok{fill:var(--mint-ink)}.p-tick{fill:none;stroke:var(--card);stroke-width:3;stroke-linecap:round;stroke-linejoin:round}
.p-sheet{fill:var(--card);stroke:var(--line);stroke-width:1.5}.p-sheet.s2{opacity:.8}.p-sheet.s3{opacity:.55}
.p-curve{fill:none;stroke:var(--lav-ink);stroke-width:3.5;stroke-linecap:round}
.p-lens{fill:var(--lav);fill-opacity:.55;stroke:var(--lav-ink);stroke-width:5}.p-handle{stroke:var(--lav-ink);stroke-width:9;stroke-linecap:round}

/* chapter cards: icon, rounded title, buttons that follow the chosen path */
.home2 .wif-book h2{font-family:var(--round);font-weight:800;letter-spacing:-.02em}
.home2 .wif-book{scroll-margin-top:70px}
.ch-top{display:flex;align-items:center;gap:10px}
.ch-ico{width:40px;height:40px;padding:8px;border-radius:13px;background:var(--card);fill:none;stroke:var(--c-ink);stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round;flex:none;box-sizing:border-box}
.home2 .wif-ch h3{font-family:var(--round);font-weight:800;font-size:23px}
.home2 .wif-ch .acts{display:flex;flex-wrap:wrap;align-items:center;gap:6px}
.home2 .wif-ch .acts .btn{background:var(--card);color:var(--c-ink);font-weight:700;font-size:13px;padding:7px 11px}
.home2 .wif-ch .acts .b-l{background:var(--c-ink);color:var(--bg)}
/* Go for it: quick lesson first (or exam answers when a chapter has none yet); the interactive lesson becomes a small link */
html[data-view="exam"] .home2 .wif-ch .b-q{background:var(--c-ink);color:var(--bg);order:1}
html[data-view="exam"] .home2 .wif-ch .b-s{order:2}
html[data-view="exam"] .home2 .wif-ch:not(.has-q) .b-s{background:var(--c-ink);color:var(--bg)}
html[data-view="exam"] .home2 .wif-ch .b-l{order:3;background:none;color:var(--c-ink);padding:7px 4px;text-decoration:underline;text-underline-offset:3px;font-weight:600}
/* Go deeper: interactive lesson first, worked solutions next, the quick lesson as a small link */
html[data-view="full"] .home2 .wif-ch .b-l{order:1}
html[data-view="full"] .home2 .wif-ch .b-s{order:2}
html[data-view="full"] .home2 .wif-ch .b-q{order:3;background:none;padding:7px 4px;text-decoration:underline;text-underline-offset:3px;font-weight:600}

/* ============ quick lesson ("Go for it") pages ============ */
.q-banner{display:block;background:var(--mint);color:var(--mint-ink);border-radius:20px;padding:14px 20px;margin:18px 0;text-decoration:none;font-size:17px;line-height:1.45}
.q-banner b{font-family:var(--round);font-weight:800}
.q-banner:hover{filter:saturate(1.2)}
.q-hero{padding:44px 0 4px}
.q-hero .kicker{color:var(--mint-ink)}
.q-hero h1{font-family:var(--round);font-weight:900;font-size:clamp(36px,6vw,58px);letter-spacing:-.025em;line-height:1.04;margin:.15em 0 .25em;text-wrap:balance}
.q-lead{font-size:clamp(18px,2.2vw,21px);color:var(--ink-2);max-width:56ch;margin:0}
.q-sec{margin-top:52px;scroll-margin-top:80px}
.q-eyebrow{display:inline-block;font-size:12.5px;font-weight:800;letter-spacing:.07em;text-transform:uppercase;padding:4px 11px;border-radius:999px;background:var(--sky);color:var(--sky-ink)}
.q-sec:nth-of-type(6n+2) .q-eyebrow{background:var(--mint);color:var(--mint-ink)}
.q-sec:nth-of-type(6n+3) .q-eyebrow{background:var(--lav);color:var(--lav-ink)}
.q-sec:nth-of-type(6n+4) .q-eyebrow{background:var(--peach);color:var(--peach-ink)}
.q-sec:nth-of-type(6n+5) .q-eyebrow{background:var(--butter);color:var(--butter-ink)}
.q-sec:nth-of-type(6n) .q-eyebrow{background:var(--rose);color:var(--rose-ink)}
.q-sec h2{font-family:var(--round);font-weight:800;font-size:clamp(27px,4vw,36px);letter-spacing:-.02em;line-height:1.12;margin:.35em 0 .2em;text-wrap:balance}
.q-sub{color:var(--ink-2);font-size:18px;margin:0 0 14px}
.q-glance{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(150px,100%),1fr));gap:12px;margin-top:16px}
.q-g{background:var(--surface);border-radius:20px;padding:16px 18px;display:flex;flex-direction:column;gap:2px}
.q-g b{font:900 30px/1.1 var(--round);color:var(--sky-ink)}
.q-g:nth-child(4n+2) b{color:var(--mint-ink)}.q-g:nth-child(4n+3) b{color:var(--lav-ink)}.q-g:nth-child(4n) b{color:var(--peach-ink)}
.q-g span{font-size:15px;color:var(--ink-2);line-height:1.35}
.q-tiles{display:grid;grid-template-columns:repeat(auto-fill,minmax(min(290px,100%),1fr));gap:14px;margin-top:16px}
.q-tile{background:var(--c-bg,var(--surface));border-radius:22px;padding:16px 18px;min-width:0}
.q-tile .katex-display{margin:.45em 0;overflow-x:auto;overflow-y:hidden;padding:2px 0}
.q-k{font:800 15px var(--round);color:var(--c-ink,var(--ink));letter-spacing:.01em}
.q-tile p{font-size:15px;line-height:1.45;margin:.2em 0 0;color:var(--ink)}
.q-type{background:var(--card);border:1px solid var(--line);border-radius:26px;padding:22px 24px;margin:16px 0;min-width:0}
.q-type h3{font-family:var(--round);font-weight:800;font-size:clamp(20px,2.6vw,24px);letter-spacing:-.01em;line-height:1.2;margin:0 0 10px}
.q-spot{background:var(--butter);border-radius:16px;padding:10px 14px;margin:0 0 12px;font-size:16.5px;max-width:none}
.q-spot b{color:var(--butter-ink)}
.q-do{list-style:none;counter-reset:qd;padding:0;margin:0 0 12px;display:grid;gap:7px}
.q-do li{counter-increment:qd;position:relative;padding-left:36px;font-size:17px;line-height:1.45}
.q-do li::before{content:counter(qd);position:absolute;left:0;top:1px;width:25px;height:25px;border-radius:50%;background:var(--mint);color:var(--mint-ink);font:800 13.5px/25px var(--round);text-align:center}
.q-mini{background:var(--surface);border-radius:18px;padding:12px 16px;overflow-x:auto;min-width:0}
.q-mini::before{content:"Worked example";display:inline-block;font-size:11.5px;font-weight:800;letter-spacing:.07em;text-transform:uppercase;padding:3px 9px;border-radius:999px;background:var(--sky);color:var(--sky-ink);margin-bottom:4px}
.q-mini .katex-display{margin:.5em 0;text-align:left}
.q-mini .katex-display>.katex{text-align:left}
.q-links{font-size:15px;margin:12px 0 0;color:var(--ink-2)}
.q-links a{font-weight:700;text-decoration:none}
.q-links a:hover{text-decoration:underline}
a[data-deeper]{color:var(--lav-ink)}
.q-tips,.q-mist{list-style:none;padding:0;margin:14px 0 0;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:10px}
@media (max-width:700px){.q-tips,.q-mist{grid-template-columns:minmax(0,1fr)}}
.q-tips li,.q-mist li{position:relative;background:var(--surface);border-radius:18px;padding:12px 14px 12px 46px;font-size:16px;line-height:1.45;max-width:none;min-width:0}
.q-tips li::before,.q-mist li::before{position:absolute;left:12px;top:12px;width:24px;height:24px;border-radius:50%;font:800 13px/24px var(--round);text-align:center}
.q-tips li::before{content:"✓";background:var(--mint);color:var(--mint-ink)}
.q-mist li::before{content:"✗";background:var(--rose);color:var(--rose-ink)}
.q-practice{list-style:none;counter-reset:qp;padding:0;margin:14px 0 0;display:grid;gap:8px}
.q-practice li{counter-increment:qp;display:flex;flex-wrap:wrap;align-items:baseline;gap:4px 12px;background:var(--surface);border-radius:18px;padding:12px 16px;max-width:none}
.q-practice li::before{content:counter(qp);font:900 15px var(--round);color:var(--sky-ink);min-width:1.4em}
.q-practice a{font-weight:700;text-decoration:none}
.q-practice span{color:var(--ink-2);font-size:15.5px}
@media (max-width:560px){.q-type{padding:18px 16px}.q-tile{padding:14px 15px}}
@media (prefers-reduced-motion:reduce){.hero-art .card-g{animation:none}.path{transition:none}}
/* the quick lesson reads in the same 1000px column as the home page */
body.quick .wrap,body.quick .top .in{max-width:1000px}
.q-ans{font-weight:700;color:var(--mint-ink);margin:.5em 0 .1em;max-width:none}
.q-marks{list-style:none;padding:0;margin:14px 0 0;display:grid;gap:8px}
.q-marks li{position:relative;background:var(--butter);border-radius:18px;padding:12px 16px 12px 46px;font-size:16.5px;line-height:1.45;max-width:none}
.q-marks li::before{content:"★";position:absolute;left:13px;top:12px;width:24px;height:24px;border-radius:50%;background:var(--card);color:var(--butter-ink);font:800 13px/24px var(--round);text-align:center}

/* ---------- Past papers tab ---------- */
.tag.t-pp{background:var(--peach);color:var(--peach-ink)}
body.pp .q .or{font-weight:700;text-align:center;color:var(--ink-2);margin:.4em 0}
body.pp .pp-note{background:var(--butter);border-radius:14px;padding:8px 14px;font-size:15px;color:var(--butter-ink)}
body.pp .opts{padding-left:1.4em}
a.tag.t-ch{background:var(--lav);color:var(--lav-ink)}
.box.from .lbl{background:var(--lav);color:var(--lav-ink)}
.ppfacts li{background:var(--surface);border:0;color:var(--ink-2)}
.pptab th,.pptab td{border-bottom-color:var(--line)}
.box.ppbox .lbl{background:var(--peach);color:var(--peach-ink)}
.pptab th,.pptab td,.pptab tr{background:none;box-shadow:none}
details.stepwhy>summary{color:var(--lav-ink);background:var(--lav)}
.why-b{background:var(--surface);border-left-color:var(--lav-ink)}
.whyall{background:var(--bg);border-color:var(--line)}
details.q-pp{margin:10px 0 0}
.q-pp .why-b{font-size:14.5px;color:var(--ink-2);line-height:1.7}
.q-pp a{font-weight:600;text-decoration:none;white-space:nowrap}
.q-pp a:hover{text-decoration:underline}
.qtype .qt a{font-weight:700}
