/* Layout concept: a field guide for gadgets. Narrow reading column, spec "tags" in mono, one tennis-ball highlight per screen. */
:root {
  --paper: #f2f4ef;
  --surface: #ffffff;
  --ink: #17201b;
  --muted: #56625b;
  --line: #d6dcd3;
  --cobalt: #2a46d8;
  --cobalt-ink: #ffffff;
  --ball: #dcef55;
  --ball-ink: #17201b;
  --good: #1f7a4a;
  --warn: #9a5b00;
  --font-display: "Bricolage Grotesque", "Avenir Next", "Segoe UI", system-ui, sans-serif;
  --font-body: "Figtree", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;
  --step--1: 0.875rem;
  --step-0: 1.0625rem;
  --step-1: 1.25rem;
  --step-2: 1.6rem;
  --step-3: 2.2rem;
  --step-4: clamp(2.4rem, 5.5vw, 3.9rem);
  --radius: 14px;
  --wrap: 1120px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #111512; --surface: #1a201c; --ink: #edf1ea; --muted: #a3aea6; --line: #2c3530;
    --cobalt: #8fa2ff; --cobalt-ink: #0e1430; --ball: #cfe34c; --ball-ink: #141a10;
    --good: #6fd29b; --warn: #f0b45a; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #111512; --surface: #1a201c; --ink: #edf1ea; --muted: #a3aea6; --line: #2c3530;
  --cobalt: #8fa2ff; --cobalt-ink: #0e1430; --ball: #cfe34c; --ball-ink: #141a10;
  --good: #6fd29b; --warn: #f0b45a; color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; animation: none !important; } }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--font-body); font-size: var(--step-0); line-height: 1.6;
}
img, svg { max-width: 100%; }
a { color: var(--cobalt); text-underline-offset: 3px; }
a:focus-visible, button:focus-visible, input:focus-visible, summary:focus-visible { outline: 3px solid var(--cobalt); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.12; text-wrap: balance; margin: 0; letter-spacing: -0.015em; }
h1 { font-size: var(--step-4); font-weight: 800; }
h2 { font-size: var(--step-3); font-weight: 750; }
h3 { font-size: var(--step-1); font-weight: 700; }
p { margin: 0; }
.wrap { max-width: var(--wrap); margin-inline: auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.prose { max-width: 68ch; display: grid; gap: 1rem; }
.eyebrow { font-family: var(--font-mono); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.mark { background: linear-gradient(transparent 55%, var(--ball) 55%, var(--ball) 92%, transparent 92%); color: inherit; padding-inline: 0.05em; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 16px; top: 16px; background: var(--surface); padding: 8px 12px; z-index: 50; }

/* Header */
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 10; background: var(--paper); }
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 9; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 1rem; justify-content: space-between; padding-block: 0.7rem; }
.brand { display: flex; align-items: center; gap: 0.55rem; text-decoration: none; color: var(--ink); font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; letter-spacing: -0.02em; }
.brand svg { width: 34px; height: 34px; flex: none; }
.brand small { font-family: var(--font-mono); font-size: 0.7rem; font-weight: 500; color: var(--muted); letter-spacing: 0.06em; }
.nav { display: flex; gap: 0.2rem; flex-wrap: wrap; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; font-size: 0.95rem; padding: 0.4rem 0.7rem; border-radius: 999px; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); }
.menu-btn { display: none; background: none; border: 1px solid var(--line); border-radius: 10px; padding: 0.45rem 0.7rem; font: 600 0.9rem var(--font-body); color: var(--ink); }
@media (max-width: 820px) {
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--paper); border-bottom: 1px solid var(--line); flex-direction: column; padding: 0.5rem max(16px, env(safe-area-inset-right, 0px)) 1rem max(16px, env(safe-area-inset-left, 0px)); }
  .nav.open { display: flex; }
  .nav a { padding: 0.7rem 0.6rem; }
}

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 0.5rem; text-decoration: none; font-weight: 700; font-size: 1rem; padding: 0.75rem 1.15rem; border-radius: 999px; background: var(--cobalt); color: var(--cobalt-ink); border: 0; cursor: pointer; font-family: var(--font-body); transition: transform .15s ease; }
.btn:hover { transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--ink); }
.btn.small { font-size: 0.9rem; padding: 0.55rem 0.95rem; }

/* Hero */
.hero { padding-block: clamp(2.5rem, 6vw, 4.5rem) 2.5rem; }
.hero .wrap { display: grid; grid-template-columns: 1.25fr 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); align-items: center; }
.hero-copy { display: grid; gap: 1.25rem; min-width: 0; }
.hero-copy p.lede { font-size: var(--step-1); color: var(--muted); max-width: 46ch; }
.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; }
.tag-card { position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding: 1.4rem 1.4rem 1.2rem; box-shadow: 0 18px 40px -24px rgba(20, 30, 25, 0.35); transform: rotate(-2deg); min-width: 0; }
.tag-card::before { content: ""; position: absolute; top: -13px; left: 50%; width: 26px; height: 26px; margin-left: -13px; border-radius: 50%; border: 5px solid var(--ink); background: var(--paper); }
.tag-card h3 { font-size: 1.05rem; margin-top: 0.5rem; }
.spec { display: grid; grid-template-columns: auto 1fr; gap: 0.35rem 1rem; margin: 0.9rem 0 0; font-family: var(--font-mono); font-size: 0.82rem; }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; }
.pill { display: inline-block; font-family: var(--font-mono); font-size: 0.72rem; font-weight: 500; letter-spacing: 0.04em; text-transform: uppercase; padding: 0.2rem 0.55rem; border-radius: 999px; border: 1px solid currentColor; white-space: nowrap; }
.pill.yes { color: var(--warn); }
.pill.no { color: var(--good); }
.pill.opt { color: var(--muted); }
.pill.pick { background: var(--ball); color: var(--ball-ink); border-color: var(--ball); }
@media (max-width: 760px) { .hero .wrap { grid-template-columns: 1fr; } .tag-card { transform: none; } }

/* Sections */
section.block { padding-block: clamp(2.5rem, 6vw, 4rem); }
section.block.alt { background: var(--surface); border-block: 1px solid var(--line); }
.section-head { display: grid; gap: 0.6rem; margin-bottom: 1.75rem; max-width: 62ch; }
.section-head p { color: var(--muted); }

/* Guide grid */
.guides { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; }
@media (max-width: 1000px) { .guides { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .guides { grid-template-columns: 1fr; } }
.guide-card { display: grid; grid-template-rows: auto auto 1fr auto; gap: 0.6rem; padding: 1.3rem; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--ink); transition: border-color .15s ease, transform .15s ease; }
.guide-card:hover { border-color: var(--cobalt); transform: translateY(-2px); }
.guide-card svg { width: 44px; height: 44px; color: var(--cobalt); }
.guide-card p { color: var(--muted); font-size: 0.95rem; }
.guide-card .go { font-weight: 700; color: var(--cobalt); font-size: 0.95rem; }

/* Finder */
.finder { display: grid; gap: 1.25rem; background: var(--ink); color: var(--paper); border-radius: 22px; padding: clamp(1.4rem, 4vw, 2.4rem); }
.finder h2 { color: var(--paper); }
.finder fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
.finder legend { font-family: var(--font-mono); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; opacity: 0.75; margin-bottom: 0.5rem; }
.chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.chips input { position: absolute; opacity: 0; pointer-events: none; }
.chips label { cursor: pointer; padding: 0.55rem 0.95rem; border-radius: 999px; border: 1.5px solid color-mix(in srgb, var(--paper) 40%, transparent); font-weight: 600; font-size: 0.95rem; }
.chips input:checked + label { background: var(--ball); color: var(--ball-ink); border-color: var(--ball); }
.chips input:focus-visible + label { outline: 3px solid var(--ball); outline-offset: 2px; }
.finder-result { border-top: 1px solid color-mix(in srgb, var(--paper) 25%, transparent); padding-top: 1.1rem; display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
.finder-result p { max-width: 52ch; }
.finder-result strong { color: var(--ball); }
.finder .btn { background: var(--ball); color: var(--ball-ink); }

/* Tables */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { border-collapse: collapse; width: 100%; min-width: 620px; font-size: 0.95rem; }
th, td { text-align: left; padding: 0.8rem 1rem; border-bottom: 1px solid var(--line); vertical-align: middle; }
th { font-family: var(--font-mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.07em; color: var(--muted); font-weight: 500; }
tr:last-child td { border-bottom: 0; }
td.num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

/* Method */
.method { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 1.5rem 2rem; }
.method div { display: grid; gap: 0.4rem; align-content: start; }
.method p { color: var(--muted); font-size: 0.97rem; }

/* Newsletter */
.signup { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem 2.5rem; align-items: center; }
.signup form { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.signup input[type="email"] { flex: 1 1 220px; min-width: 0; font: inherit; padding: 0.75rem 1rem; border-radius: 999px; border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); }
.form-note { font-size: 0.88rem; color: var(--muted); flex-basis: 100%; }
@media (max-width: 760px) { .signup { grid-template-columns: 1fr; } }

/* Guide pages */
.page-head { padding-block: 2.5rem 1.5rem; border-bottom: 1px solid var(--line); }
.page-head .wrap { display: grid; gap: 1rem; }
.crumbs { font-size: 0.9rem; color: var(--muted); }
.crumbs a { color: var(--muted); }
.meta-row { display: flex; flex-wrap: wrap; gap: 0.5rem 1.25rem; font-family: var(--font-mono); font-size: 0.8rem; color: var(--muted); }
.disclose { font-size: 0.9rem; color: var(--muted); background: var(--surface); border: 1px dashed var(--line); border-radius: 10px; padding: 0.7rem 0.9rem; max-width: 68ch; }
.lede { font-size: var(--step-1); color: var(--muted); max-width: 60ch; }
.guide-body { display: grid; gap: 3rem; padding-block: 2.5rem 4rem; }
.guide-body > * { min-width: 0; }
.product { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 1.5rem 2.5rem; padding-top: 2.5rem; border-top: 1px solid var(--line); scroll-margin-top: 90px; }
.product:first-of-type { border-top: 0; padding-top: 0; }
.product-main { display: grid; gap: 0.9rem; align-content: start; min-width: 0; }
.product-main .label-row { display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center; }
.product-main h3 { font-size: var(--step-2); }
.pc { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.pc h4 { font-family: var(--font-mono); font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; margin: 0 0 0.4rem; font-weight: 500; }
.pc ul { margin: 0; padding-left: 1.1rem; display: grid; gap: 0.3rem; font-size: 0.97rem; }
.pc .pros h4 { color: var(--good); }
.pc .cons h4 { color: var(--warn); }
.product-side { align-self: start; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.2rem; display: grid; gap: 1rem; min-width: 0; }
.product-side .spec { margin: 0; }
.product-side .btn { justify-content: center; }
.side-note { font-size: 0.8rem; color: var(--muted); }
@media (max-width: 760px) { .product, .pc { grid-template-columns: 1fr; } }
.faq { display: grid; gap: 0.6rem; max-width: 68ch; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 0.9rem 1.1rem; }
.faq summary { cursor: pointer; font-weight: 700; }
.faq details p { margin-top: 0.6rem; color: var(--muted); }
.related { display: flex; flex-wrap: wrap; gap: 0.6rem; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 2.5rem 2rem; font-size: 0.92rem; color: var(--muted); }
.site-footer .wrap { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 1.5rem 2rem; }
.site-footer h4 { font-family: var(--font-mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--ink); margin: 0 0 0.6rem; font-weight: 500; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.35rem; }
.site-footer a { color: var(--muted); }
.fine { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 1rem; font-size: 0.82rem; }
@media (max-width: 760px) { .site-footer .wrap { grid-template-columns: 1fr; } }

/* Cookie banner */
.linkish { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.prose .linkish { color: var(--cobalt); }
.cookie-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; background: var(--surface); border-top: 1px solid var(--line); box-shadow: 0 -12px 30px -18px rgba(20, 30, 25, 0.4); padding-bottom: env(safe-area-inset-bottom, 0px); }
.cookie-inner { max-width: var(--wrap); margin-inline: auto; display: flex; flex-wrap: wrap; gap: 0.9rem 1.5rem; align-items: center; justify-content: space-between; padding-block: 1rem; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.cookie-inner p { flex: 1 1 420px; min-width: 0; font-size: 0.95rem; }
.cookie-actions { display: flex; gap: 0.6rem; }
.cookie-actions .btn { min-width: 7.5rem; justify-content: center; }

/* Illustrations */
.card-art { border-radius: 12px; overflow: hidden; border: 1px solid var(--line); aspect-ratio: 16 / 10; max-width: 100%; }
.card-art svg, .head-art svg { display: block; width: 100%; height: auto; }
.guide-card { grid-template-rows: auto auto 1fr auto; }
.head-grid { grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); align-items: center; column-gap: 2.5rem; }
.head-copy { display: grid; gap: 1rem; min-width: 0; }
.head-art { border-radius: 20px; overflow: hidden; border: 1px solid var(--line); max-width: 420px; justify-self: end; width: 100%; }
@media (max-width: 760px) { .head-grid { grid-template-columns: 1fr; } .head-art { display: none; } }

/* Jump nav */
.jump { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 0.4rem 0.5rem; align-items: center; margin-top: 0.5rem; }
.jump .eyebrow { margin-right: 0.25rem; }
.jump a { font-size: 0.88rem; font-weight: 600; text-decoration: none; color: var(--ink); background: var(--surface); border: 1px solid var(--line); padding: 0.3rem 0.7rem; border-radius: 999px; }
.jump a:hover { border-color: var(--cobalt); color: var(--cobalt); }

/* Product photos (drop files in src/images/products) */
.product-photo { width: 100%; height: auto; aspect-ratio: 4 / 3; object-fit: contain; background: #fff; border-radius: 10px; border: 1px solid var(--line); }

/* Sticky top pick bar on phones */
.pick-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: var(--ink); color: var(--paper); padding-bottom: env(safe-area-inset-bottom, 0px); }
.pick-inner { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; padding-block: 0.65rem; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.pick-name { display: grid; min-width: 0; line-height: 1.25; }
.pick-name .eyebrow { color: var(--ball); font-size: 0.68rem; }
.pick-name strong { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-size: 0.95rem; }
.pick-bar .btn { background: var(--ball); color: var(--ball-ink); flex: none; }
@media (min-width: 761px) { .pick-bar { display: none !important; } }

/* Calculator */
.calc-callout { margin-top: 0.9rem; font-size: 0.95rem; color: var(--muted); }
.calc-promo { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.25rem 2rem; background: var(--surface); border: 1px solid var(--line); border-radius: 22px; padding-block: clamp(1.4rem, 4vw, 2.2rem); }
.calc-promo { padding-left: max(clamp(1.2rem, 4vw, 2.4rem), env(safe-area-inset-left, 0px)); padding-right: max(clamp(1.2rem, 4vw, 2.4rem), env(safe-area-inset-right, 0px)); }
.calc { display: grid; gap: 1.25rem; }
.calc-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 680px) { .calc-cols { grid-template-columns: 1fr; } }
.calc-col { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 1.1rem 1.2rem 1.3rem; margin: 0; display: grid; gap: 0.35rem; min-width: 0; }
.calc-col legend { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; padding: 0 0.3rem; }
.calc-col label { font-size: 0.88rem; font-weight: 600; color: var(--muted); margin-top: 0.45rem; }
.calc-col input, .calc-col select { font: inherit; padding: 0.6rem 0.8rem; border-radius: 10px; border: 1.5px solid var(--line); background: var(--paper); color: var(--ink); width: 100%; min-width: 0; }
.calc-years { border: 0; padding: 0; margin: 0; }
.calc-years legend { font-family: var(--font-mono); font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin-bottom: 0.5rem; }
.chips.light label { border-color: var(--line); background: var(--surface); }
.chips.light input:checked + label { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.calc-out { display: grid; gap: 1rem; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.3rem; }
.bars { display: grid; gap: 0.9rem; }
.bar-row { display: grid; gap: 0.35rem; }
.bar-label { display: flex; justify-content: space-between; gap: 1rem; font-weight: 600; flex-wrap: wrap; }
.bar-label .num { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }
.bar-track { height: 18px; border-radius: 999px; background: var(--paper); border: 1px solid var(--line); overflow: hidden; }
.bar-fill { height: 100%; border-radius: 999px; background: var(--cobalt); transition: width .3s ease; }
.bar-row.cheaper .bar-fill { background: var(--good); }
.bar-sub { font-size: 0.85rem; color: var(--muted); font-family: var(--font-mono); }
.calc-verdict { font-size: var(--step-1); font-weight: 600; }
