:root {
  --bg: #f6f8fc;
  --surface: #ffffff;
  --surface2: #edf1f9;
  --ink: #14213d;
  --muted: #55627f;
  --line: #d6dcea;
  --accent: #1c4cb0;
  --accent-ink: #ffffff;
  --accent-weak: #e3ebfb;
  --ball: #d9520a;
  --ball-weak: #fdebdf;
  --ok: #17794a;
  --ok-weak: #e0f3e9;
  --warn: #8a5a00;
  --warn-weak: #fff3d6;
  --head: "Barlow Condensed", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --text: "Source Serif 4", Georgia, "Times New Roman", serif;
  --ui: "Barlow", "Helvetica Neue", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0d1626; --surface: #14213a; --surface2: #1a2947; --ink: #e8edf8; --muted: #98a5c3; --line: #2b3b5e;
    --accent: #7ba6ff; --accent-ink: #0d1626; --accent-weak: #1d2e56; --ball: #ff8d44; --ball-weak: #3a2616;
    --ok: #55d08f; --ok-weak: #15332a; --warn: #ffcf70; --warn-weak: #3a2f12;
    color-scheme: dark;
  }
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--text); font-size: 18px; line-height: 1.65; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 3px solid var(--ball); outline-offset: 2px; border-radius: 2px; }
img, svg { max-width: 100%; height: auto; }
.wrap { max-width: 1100px; margin-inline: auto; padding-inline: 20px; }
.prose { max-width: 720px; }

/* header */
.site-head { background: var(--surface); border-bottom: 1px solid var(--line); }
.site-head .wrap { display: flex; flex-wrap: wrap; gap: 8px 28px; align-items: center; justify-content: space-between; padding-block: 12px; }
.brand { font-family: var(--head); font-weight: 700; font-size: 1.7rem; letter-spacing: .01em; color: var(--ink); text-decoration: none; display: flex; gap: 10px; align-items: center; line-height: 1; }
.brand svg { width: 30px; height: 30px; flex: none; }
.nav { display: flex; flex-wrap: wrap; gap: 4px 20px; font-family: var(--ui); font-weight: 600; font-size: 1rem; }
.nav a { color: var(--ink); text-decoration: none; padding: 6px 0; border-bottom: 3px solid transparent; }
.nav a:hover, .nav a[aria-current] { border-bottom-color: var(--ball); }

/* headings */
h1, h2, h3, h4 { font-family: var(--head); line-height: 1.1; letter-spacing: .005em; text-wrap: balance; }
h1 { font-size: clamp(2.3rem, 5vw, 3.3rem); font-weight: 700; margin: 0 0 .5rem; }
h2 { font-size: 2rem; font-weight: 600; margin: 2.4rem 0 .6rem; }
h3 { font-size: 1.45rem; font-weight: 600; margin: 1.8rem 0 .4rem; }
h4 { font-size: 1.15rem; font-weight: 600; margin: 1.2rem 0 .3rem; }
p { margin: 0 0 1.1rem; }
.lede { font-size: 1.28rem; color: var(--muted); margin-bottom: 1.6rem; }
.crumbs { font-family: var(--ui); font-size: .9rem; color: var(--muted); padding-top: 22px; }
.crumbs a { color: var(--muted); }
.meta { font-family: var(--ui); font-size: .88rem; color: var(--muted); margin-bottom: 1.4rem; }
main { padding-block: 10px 70px; }

/* article */
.article ul, .article ol { padding-left: 1.3em; margin: 0 0 1.2rem; }
.article li { margin-bottom: .45rem; }
.article li > ul, .article li > ol { margin-top: .45rem; margin-bottom: 0; }
.article table, .tbl { width: 100%; border-collapse: collapse; font-family: var(--ui); font-size: .98rem; margin: 1rem 0 1.4rem; }
.article th, .article td, .tbl th, .tbl td { border: 1px solid var(--line); padding: 8px 10px; text-align: left; vertical-align: top; }
.article th, .tbl th { background: var(--surface2); font-weight: 600; }
.tscroll { overflow-x: auto; }
.callout { font-family: var(--ui); font-size: 1rem; border: 1px solid var(--line); border-left: 5px solid var(--accent); background: var(--surface); border-radius: 6px; padding: 12px 16px; margin: 1.4rem 0; }
.callout > :last-child { margin-bottom: 0; }
.callout.tip { border-left-color: var(--ok); background: var(--ok-weak); }
.callout.warn { border-left-color: var(--ball); background: var(--ball-weak); }
.callout.src { border-left-color: var(--muted); background: var(--surface2); font-size: .92rem; }
.callout b.t { font-family: var(--head); font-size: 1.15rem; display: block; letter-spacing: .02em; }
.toc { font-family: var(--ui); font-size: .98rem; background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 12px 18px; margin: 0 0 1.8rem; }
.toc b { font-family: var(--head); font-size: 1.15rem; }
.toc ol { margin: 6px 0 0; padding-left: 1.2em; columns: 2; column-gap: 28px; }
@media (max-width: 640px) { .toc ol { columns: 1; } }
.toc li { margin-bottom: 2px; break-inside: avoid; }
.faq details { border-top: 1px solid var(--line); padding: 10px 0; }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { font-family: var(--ui); font-weight: 600; cursor: pointer; }
.faq p { margin: 8px 0 0; }
.related { margin-top: 2.6rem; border-top: 2px solid var(--line); padding-top: 1rem; font-family: var(--ui); }
.related h2 { font-size: 1.5rem; margin-top: 0; }
.related ul { padding-left: 1.2em; }

/* cards */
.hero { padding-block: 44px 28px; }
.hero h1 { max-width: 16ch; }
.hero .lede { max-width: 40ch; }
.btnrow { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.btn { display: inline-block; font-family: var(--ui); font-weight: 600; text-decoration: none; padding: 10px 20px; border-radius: 8px; border: 2px solid var(--accent); color: var(--accent); background: transparent; cursor: pointer; font-size: 1rem; }
.btn.pri { background: var(--accent); color: var(--accent-ink); }
.btn.hot { background: var(--ball); border-color: var(--ball); color: #fff; }
.btn:hover { filter: brightness(1.1); }
.grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); margin: 1rem 0 2rem; padding: 0; list-style: none; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 16px 18px; font-family: var(--ui); display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.card h3 { margin: 0; font-size: 1.4rem; }
.card h3 a { color: var(--ink); text-decoration: none; }
.card h3 a:hover { color: var(--accent); }
.card p { margin: 0; font-size: .98rem; color: var(--muted); }
.card .go { margin-top: auto; font-weight: 600; font-size: .95rem; }
.sechead { display: flex; justify-content: space-between; align-items: baseline; flex-wrap: wrap; gap: 8px; margin-top: 2.4rem; }
.sechead h2 { margin: 0; }
.band { background: var(--surface2); border-block: 1px solid var(--line); padding-block: 30px; margin-block: 30px; }
.steps { counter-reset: s; list-style: none; padding: 0; display: grid; gap: 14px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); font-family: var(--ui); }
.steps li { counter-increment: s; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px 14px 16px; }
.steps li::before { content: counter(s); font-family: var(--head); font-weight: 700; font-size: 1.6rem; color: var(--ball); display: block; line-height: 1; margin-bottom: 4px; }

/* tools */
.tool { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 20px; margin: 1rem 0 2rem; font-family: var(--ui); }
.fields { display: grid; gap: 14px 18px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); }
.fields label { display: flex; flex-direction: column; gap: 4px; font-size: .88rem; font-weight: 600; color: var(--muted); }
.fields input, .fields select { font: inherit; font-size: 1rem; padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--bg); color: var(--ink); width: 100%; min-width: 0; }
.result { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 16px; }
.stats { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 150px), 1fr)); margin-bottom: 14px; }
.stat { background: var(--surface2); border-radius: 8px; padding: 10px 12px; }
.stat b { display: block; font-family: var(--head); font-size: 2rem; line-height: 1.05; font-variant-numeric: tabular-nums; }
.stat span { font-size: .85rem; color: var(--muted); }
.check { display: flex; gap: 10px; align-items: flex-start; padding: 6px 0; font-family: var(--ui); font-size: 1rem; }
.check input { margin-top: 5px; flex: none; width: 18px; height: 18px; }
.check.done span { text-decoration: line-through; color: var(--muted); }
.check span small { display: block; color: var(--muted); font-size: .88rem; }

/* footer */
.site-foot { background: var(--surface); border-top: 1px solid var(--line); font-family: var(--ui); font-size: .95rem; padding-block: 30px; color: var(--muted); }
.site-foot .cols { display: grid; gap: 24px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); }
.site-foot h2 { font-size: 1.15rem; margin: 0 0 6px; color: var(--ink); }
.site-foot ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 4px; }
.site-foot a { color: var(--muted); }
.site-foot .fine { margin-top: 22px; font-size: .85rem; }
.notice { position: fixed; inset-inline: 12px; bottom: 12px; z-index: 30; max-width: 640px; margin-inline: auto; background: var(--ink); color: var(--bg); border-radius: 10px; padding: 12px 16px; font-family: var(--ui); font-size: .92rem; display: flex; gap: 14px; align-items: center; flex-wrap: wrap; box-shadow: 0 6px 24px rgba(0,0,0,.3); }
.notice button { font: inherit; font-weight: 600; background: var(--ball); color: #fff; border: 0; border-radius: 6px; padding: 6px 14px; cursor: pointer; }
.notice a { color: inherit; }

/* printable pages */
.sheet { background: #fff; color: #111; border: 1px solid var(--line); border-radius: 6px; padding: 20px; margin: 1rem 0 2rem; font-family: var(--ui); font-size: .95rem; }
.sheet h2, .sheet h3 { color: #111; margin-top: 0; }
.sheet table { border-collapse: collapse; width: 100%; }
.sheet th, .sheet td { border: 1px solid #555; padding: 6px 8px; text-align: left; }
.sheet .blank { height: 2.1em; }
.cs { columns: 2; column-gap: 28px; }
@media (max-width: 760px) { .cs { columns: 1; } }
.cs section { break-inside: avoid; margin-bottom: 14px; }
.cs h3 { margin: 0 0 4px; font-size: 1.25rem; border-bottom: 2px solid #111; }
.cs ul { margin: 0; padding-left: 1.1em; }
.cs li { margin-bottom: 2px; }
.pagebreak { break-after: page; }
@media print {
  .site-head, .site-foot, .crumbs, .noprint, .notice, .related, .btnrow { display: none !important; }
  body { background: #fff; color: #000; font-size: 11.5pt; }
  .sheet { border: 0; padding: 0; margin: 0 0 12px; }
  .wrap { max-width: none; padding-inline: 0; }
  main { padding: 0; }
  a { color: inherit; text-decoration: none; }
}

@font-face{font-family:"Source Serif 4";font-style:normal;font-weight:400;font-display:swap;src:url(fonts/source-serif-4-latin-400-normal.woff2) format("woff2")}
@font-face{font-family:"Source Serif 4";font-style:italic;font-weight:400;font-display:swap;src:url(fonts/source-serif-4-latin-400-italic.woff2) format("woff2")}
@font-face{font-family:"Source Serif 4";font-style:normal;font-weight:600;font-display:swap;src:url(fonts/source-serif-4-latin-600-normal.woff2) format("woff2")}
@font-face{font-family:"Barlow";font-style:normal;font-weight:400;font-display:swap;src:url(fonts/barlow-latin-400-normal.woff2) format("woff2")}
@font-face{font-family:"Barlow";font-style:normal;font-weight:600;font-display:swap;src:url(fonts/barlow-latin-600-normal.woff2) format("woff2")}
@font-face{font-family:"Barlow Condensed";font-style:normal;font-weight:600;font-display:swap;src:url(fonts/barlow-condensed-latin-600-normal.woff2) format("woff2")}
@font-face{font-family:"Barlow Condensed";font-style:normal;font-weight:700;font-display:swap;src:url(fonts/barlow-condensed-latin-700-normal.woff2) format("woff2")}
.eq{border-top:1px solid var(--line);margin-top:1.6rem}.eq .why{font-weight:600}.eqtip{font-family:var(--ui);font-size:.95rem;background:var(--surface2);border-radius:6px;padding:8px 12px}.buy{margin:1rem 0}.fine{font-size:.9rem;color:var(--muted)}
.skip{position:absolute;left:-999px;top:0;background:var(--ink);color:var(--bg);padding:8px 14px;z-index:50}.skip:focus{left:8px;top:8px}
.prose.wide{max-width:none}
.fig{margin:1.4rem 0;font-family:var(--ui);font-size:.9rem;color:var(--muted)}.fig svg{width:100%;max-width:640px;height:auto;color:var(--ink)}
.sheet svg{width:100%;height:auto;color:#111}
.gloss dt{font-family:var(--head);font-weight:600;font-size:1.3rem;margin-top:1rem}.gloss dd{margin:0 0 .4rem}
.mistakes{padding-left:0;list-style:none;counter-reset:m}.mistakes li{counter-increment:m;border-top:1px solid var(--line);padding-top:.4rem}.mistakes h2{font-size:1.5rem;margin:.6rem 0 .3rem}.mistakes h2::before{content:counter(m) ". ";color:var(--ball)}
.tool h3 small{font-weight:400;color:var(--muted);font-size:1rem}
.hero h1{max-width:20ch}
.sheet{overflow-x:auto}
.hero .btnrow .btn{width:250px;text-align:center}
.btn.dark{background:var(--ink);border-color:var(--ink);color:var(--bg)}
@media (max-width:640px){.hero .btnrow .btn{width:100%}}
.feature{background:var(--ink);color:var(--bg);border-radius:14px;padding:26px 28px;margin:1.4rem 0 2.2rem;border-left:8px solid var(--ball)}
.feature h2{color:inherit;margin:.4rem 0 .4rem;font-size:2.4rem}.feature .fl{font-size:1.2rem;margin-bottom:1rem}
.feature .badge{display:inline-block;background:var(--ball);color:#fff;font-family:var(--ui);font-weight:600;font-size:.82rem;letter-spacing:.06em;text-transform:uppercase;border-radius:20px;padding:3px 12px}
.feature .ticks{font-family:var(--ui);padding-left:1.2em;margin:0 0 1rem}.feature .ticks li{margin-bottom:.45rem}
.feature .btn{border-color:var(--bg);color:var(--bg)}.feature .btn.hot{background:var(--ball);border-color:var(--ball);color:#fff}

