/* SecureToolsHQ - one small stylesheet for every page. Functional minimalism: system fonts, hairline borders,
   no shadows or gradients, one accent colour. Light and dark follow the visitor's device setting. Mobile first. */
:root {
  --bg: #fafaf8;
  --surface: #ffffff;
  --surface-2: #f3f3ef;
  --line: #e2e2dc;
  --line-strong: #c4c4bc;
  --text: #14171a;
  --muted: #565c64;
  --accent: #15803d;
  --accent-strong: #166534;
  --accent-ink: #ffffff;
  --focus: #1d4ed8;
  --warn-bg: #fff8e1; --warn-line: #e6c868; --warn-text: #5a4200;
  --err-bg: #fdeeee; --err-line: #e3a3a3; --err-text: #7a1717;
  --ok-bg: #eaf6ee; --ok-line: #96cfaa; --ok-text: #0f5132;
  --info-bg: #eef2fb; --info-line: #b9c6e6; --info-text: #1f3166;
  --meter-0: #dc2626; --meter-1: #ea580c; --meter-2: #ca8a04; --meter-3: #65a30d; --meter-4: #15803d;
  --shadow: 0 1px 2px rgba(20, 23, 26, 0.06), 0 3px 10px rgba(20, 23, 26, 0.05);
  --shadow-hover: 0 2px 4px rgba(20, 23, 26, 0.08), 0 6px 16px rgba(20, 23, 26, 0.09);
  --radius: 8px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1113;
    --surface: #151a1d;
    --surface-2: #1c2226;
    --line: #272f35;
    --line-strong: #3b454d;
    --text: #e8ebed;
    --muted: #a0a9b1;
    --accent: #4ade80;
    --accent-strong: #86efac;
    --accent-ink: #04210f;
    --focus: #8ab0ff;
    --warn-bg: #2b2410; --warn-line: #6b5a1f; --warn-text: #f1dc9a;
    --err-bg: #2d1717; --err-line: #703535; --err-text: #f4b8b8;
    --ok-bg: #12261a; --ok-line: #2d6a45; --ok-text: #a9e6c0;
    --info-bg: #151f36; --info-line: #34457a; --info-text: #bccaf2;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 3px 10px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 2px 4px rgba(0, 0, 0, 0.5), 0 6px 16px rgba(0, 0, 0, 0.4);
    --meter-0: #f87171; --meter-1: #fb923c; --meter-2: #facc15; --meter-3: #a3e635; --meter-4: #4ade80;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--font); font-size: 1rem; line-height: 1.6; color: var(--text); background: var(--bg); }
img, svg { max-width: 100%; }
[hidden] { display: none !important; }
a { color: var(--accent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { color: var(--accent-strong); text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 3px; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 8px; top: -60px; z-index: 50; background: var(--text); color: var(--bg); padding: 8px 14px; border-radius: var(--radius); font-weight: 600; }
.skip:focus { top: 8px; }
.wrap { width: 100%; max-width: 960px; margin: 0 auto; padding: 0 16px; }
.narrow { max-width: 720px; }

/* Header: a single quiet row */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-header .bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 2px 20px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: inline-flex; align-items: center; gap: 8px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 1.05rem; letter-spacing: -0.01em; }
svg.mark path { stroke: var(--accent); }
svg.mark circle, svg.mark rect { fill: var(--accent); }
/* Wordmark: "SecureTools" in the brand green, "HQ" in the text colour (near-black in light mode, near-white in dark mode). */
.brand span, .foot-brand span { color: var(--accent); }
.brand b, .foot-brand b { color: var(--text); font-weight: 700; }
.brand:hover { color: var(--text); text-decoration: none; }
.nav { display: flex; flex-wrap: wrap; gap: 0 2px; margin-left: -8px; }
.nav a { color: var(--muted); text-decoration: none; padding: 6px 8px; font-size: 0.92rem; border-radius: 6px; }
.nav a:hover { color: var(--text); background: var(--surface-2); text-decoration: none; }
.nav { align-items: center; }
.nav-menu summary { list-style: none; cursor: pointer; color: var(--muted); padding: 6px 8px; font-size: 0.92rem; border-radius: 6px; display: inline-flex; align-items: center; gap: 6px; user-select: none; }
.nav-menu summary::-webkit-details-marker { display: none; }
.nav-menu summary::after { content: ""; width: 6px; height: 6px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: translateY(-2px) rotate(45deg); transition: transform 0.15s; }
.nav-menu[open] summary::after { transform: translateY(1px) rotate(-135deg); }
.nav-menu summary:hover, .nav-menu[open] summary { color: var(--text); background: var(--surface-2); }
.site-header .bar { position: relative; }
.menu { position: absolute; left: 16px; right: 16px; top: 100%; z-index: 40; display: grid; grid-template-columns: 1fr; gap: 14px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--radius); box-shadow: var(--shadow-hover); padding: 14px 10px 10px; margin-top: -2px; max-height: calc(100vh - 90px); overflow-y: auto; }
.menu-col ul { list-style: none; margin: 4px 0 0; padding: 0; }
.nav .menu-col a { display: block; padding: 4px 8px; font-size: 0.92rem; }
.nav .menu-col a.menu-cat { color: var(--text); font-weight: 650; font-family: var(--mono); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; }
@media (min-width: 560px) { .menu { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 760px) { .menu { grid-template-columns: repeat(4, 1fr); padding: 16px 12px 12px; } }

/* Page heading block: text only */
.hero { padding: 26px 0 4px; }
.hero h1 { font-size: clamp(1.7rem, 4.6vw, 2.35rem); line-height: 1.15; margin: 10px 0 12px; letter-spacing: -0.025em; font-weight: 700; text-wrap: balance; }
.hero .answer { font-size: 1.05rem; line-height: 1.6; color: var(--muted); max-width: 68ch; margin: 0 0 14px; }
.chips { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 18px; padding: 0; margin: 0; font-family: var(--mono); font-size: 0.78rem; color: var(--muted); }
.chips li { display: inline-flex; align-items: center; gap: 7px; }
.chips li::before { content: ""; width: 6px; height: 6px; background: var(--accent); border-radius: 50%; flex: none; }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 2px 0; margin: 0; padding: 0; font-size: 0.82rem; color: var(--muted); }
.crumbs li + li::before { content: "/"; margin: 0 8px; color: var(--line-strong); }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--text); text-decoration: underline; }

/* Layout */
.content { padding-top: 6px; padding-bottom: 48px; }
.tool { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 18px; margin-top: 18px; position: relative; }
.tool-title { font-size: 0.78rem; font-weight: 600; font-family: var(--mono); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin: 0 0 16px; }
.privacy-note { display: flex; gap: 8px; align-items: flex-start; font-size: 0.86rem; color: var(--muted); margin: 18px 0 0; padding-top: 12px; border-top: 1px solid var(--line); }
.privacy-note svg { flex: none; margin-top: 3px; color: var(--accent); }
.hub-page .content, .info-page .content { padding-top: 22px; }

/* Prose */
.prose { max-width: 720px; margin: 40px auto 0; }
.prose h2 { font-size: 1.35rem; line-height: 1.25; margin: 2.2rem 0 0.6rem; letter-spacing: -0.015em; font-weight: 700; text-wrap: balance; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-size: 1.04rem; margin: 1.3rem 0 0.3rem; font-weight: 650; }
.prose p, .prose li { color: var(--text); }
.prose ul, .prose ol { padding-left: 1.3rem; }
.prose li { margin: 0.3rem 0; }
.prose code, code.inline { font-family: var(--mono); font-size: 0.88em; background: var(--surface-2); border: 1px solid var(--line); padding: 0 4px; border-radius: 4px; overflow-wrap: anywhere; }
.prose pre { background: var(--surface-2); border: 1px solid var(--line); color: var(--text); padding: 14px; border-radius: var(--radius); overflow-x: auto; font-size: 0.86rem; line-height: 1.5; }
.prose pre code { background: none; border: 0; padding: 0; color: inherit; }
.steps { counter-reset: s; list-style: none; padding-left: 0 !important; }
.steps li { counter-increment: s; position: relative; padding-left: 36px; margin: 0.7rem 0; }
.steps li::before { content: counter(s, decimal-leading-zero); position: absolute; left: 0; top: 0.12em; font-family: var(--mono); font-size: 0.82rem; font-weight: 600; color: var(--accent); }
.example { background: var(--surface-2); border: 1px solid var(--line); border-left: 3px solid var(--accent); padding: 12px 16px; border-radius: 0 var(--radius) var(--radius) 0; margin: 1rem 0; }
.example p:first-child { margin-top: 0; }
.example p:last-child { margin-bottom: 0; }
.faq h3 { border-top: 1px solid var(--line); padding-top: 1rem; }
.faq h3:first-of-type { border-top: 0; padding-top: 0; }
.job-list { list-style: none; margin: 1rem 0 0; padding: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); box-shadow: var(--shadow); }
.prose .job-list { padding-left: 0; }
.job-list li + li { border-top: 1px solid var(--line); }
.job-list a { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2px 16px; padding: 0.8rem 1rem; color: var(--text); text-decoration: none; }
.job-list a:hover { background: var(--surface-2); text-decoration: none; }
.job-list span { flex: 1 1 18rem; }
.job-list strong { color: var(--accent); font-weight: 650; }
.related, .sources { margin-top: 3rem; }
.sources { padding-top: 1.6rem; border-top: 1px solid var(--line); }
.sources ul { font-size: 0.92rem; }

/* Tables */
.table-wrap { overflow-x: auto; margin: 1.2rem 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { border-collapse: collapse; width: 100%; font-size: 0.92rem; }
caption { text-align: left; font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--line); }
th, td { padding: 8px 12px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
thead th { background: var(--surface-2); font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-family: var(--mono); font-weight: 600; }
tbody tr:last-child th, tbody tr:last-child td { border-bottom: 0; }
tbody th { font-weight: 600; white-space: nowrap; }

/* Tiles: icon, text, arrow at the right edge. A soft shadow lifts them off the page. */
.cards { list-style: none; padding: 0; margin: 1rem 0 0; display: grid; grid-template-columns: 1fr; gap: 12px; }
@media (min-width: 640px) { .cards { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 900px) { .cards.cols-3 { grid-template-columns: repeat(3, 1fr); } }
.cards a { display: flex; align-items: center; gap: 14px; height: 100%; padding: 14px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); text-decoration: none; color: var(--text); transition: border-color 0.15s, box-shadow 0.15s; }
.cards a:hover { border-color: var(--accent); box-shadow: var(--shadow-hover); color: var(--text); text-decoration: none; }
.cards a::after { content: ""; flex: none; width: 8px; height: 8px; margin: 0 4px 0 auto; border-top: 2px solid var(--muted); border-right: 2px solid var(--muted); transform: rotate(45deg); transition: transform 0.15s, border-color 0.15s; }
.cards a:hover::after { border-color: var(--accent); transform: translateX(3px) rotate(45deg); }
.cards .ic { flex: none; width: 40px; height: 40px; display: grid; place-items: center; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--line); color: var(--accent); }
.cards .txt { min-width: 0; }
.cards strong { display: block; font-weight: 650; margin-bottom: 2px; }
.cards .txt span { color: var(--muted); font-size: 0.92rem; display: block; }
.prose .cards { padding-left: 0; }
.prose .cards li { margin: 0; }

/* Forms */
.field { margin: 0 0 14px; }
.field > label, .label, legend { display: block; font-weight: 600; font-size: 0.9rem; margin-bottom: 5px; }
fieldset { border: 0; padding: 0; margin: 0 0 14px; min-width: 0; }
legend { padding: 0; }
input[type="text"], input[type="number"], input[type="password"], input[type="search"], input[type="url"], input[type="email"], select, textarea {
  width: 100%; font: inherit; color: var(--text); background: var(--bg); padding: 9px 11px; border: 1px solid var(--line-strong); border-radius: 6px;
}
input::placeholder, textarea::placeholder { color: var(--muted); opacity: 0.8; }
input:focus, select:focus, textarea:focus { border-color: var(--accent); }
textarea { min-height: 110px; resize: vertical; font-family: var(--mono); font-size: 0.92rem; }
textarea[wrap="off"] { font-size: 0.82rem; white-space: pre; overflow-x: auto; }
input[type="color"] { width: 3.2rem; height: 2.4rem; padding: 2px; border: 1px solid var(--line-strong); border-radius: 6px; background: var(--bg); cursor: pointer; }
input[type="range"] { width: 100%; accent-color: var(--accent); }
input[type="checkbox"], input[type="radio"] { accent-color: var(--accent); width: 18px; height: 18px; margin: 0; flex: none; }
.check { display: flex; align-items: center; gap: 9px; font-weight: 500; margin: 6px 0; cursor: pointer; }
.check label { cursor: pointer; margin: 0; font-weight: 500; }
.row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; }
.row > .field { flex: 1 1 160px; margin-bottom: 8px; }
.grid-2 { display: grid; grid-template-columns: 1fr; gap: 0 20px; }
@media (min-width: 720px) { .grid-2 { grid-template-columns: 1fr 1fr; } }
.hint { font-size: 0.84rem; color: var(--muted); margin: 4px 0 0; }
.inline-val { font-weight: 700; font-family: var(--mono); }

/* Buttons: one filled style, one outline */
.btn { font: inherit; font-weight: 600; display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 9px 16px; border-radius: 6px; border: 1px solid transparent; cursor: pointer; text-decoration: none; line-height: 1.2; min-height: 40px; }
.btn-primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-strong); border-color: var(--accent-strong); color: var(--accent-ink); text-decoration: none; }
.btn-secondary { background: var(--surface); color: var(--text); border-color: var(--line-strong); }
.btn-secondary:hover { border-color: var(--text); color: var(--text); text-decoration: none; }
.btn-sm { padding: 5px 11px; min-height: 32px; font-size: 0.86rem; }
.btn[disabled] { opacity: 0.5; cursor: not-allowed; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0; }

/* Segmented tabs */
.seg { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 16px; padding: 0; list-style: none; }
.seg button { font: inherit; font-weight: 500; font-size: 0.9rem; padding: 6px 12px; border-radius: 6px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--text); cursor: pointer; }
.seg button:hover { border-color: var(--text); }
.seg button[aria-selected="true"], .seg button[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }

/* Output boxes */
.output { font-family: var(--mono); font-size: 1rem; background: var(--surface-2); color: var(--text); border: 1px solid var(--line); padding: 11px 13px; border-radius: 6px; overflow-wrap: anywhere; word-break: break-all; line-height: 1.5; min-height: 46px; user-select: all; }
.output.light { background: var(--surface-2); }
.out-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.out-item { display: flex; gap: 8px; align-items: stretch; }
.out-item .output { flex: 1; min-width: 0; }
.out-item .btn { flex: none; }
.out-item > div { flex: 1; min-width: 0; }
.out-label { display: block; font-size: 0.74rem; font-weight: 600; letter-spacing: 0.06em; text-transform: uppercase; color: var(--muted); font-family: var(--mono); margin-bottom: 3px; }
.out-item.labeled { align-items: flex-end; }
.big-value { font-family: var(--mono); font-size: clamp(1.4rem, 5vw, 2.1rem); font-weight: 600; overflow-wrap: anywhere; letter-spacing: -0.01em; }

/* Messages */
.msg { padding: 9px 13px; border-radius: 6px; border: 1px solid; font-size: 0.92rem; margin: 10px 0; }
.msg.warn { background: var(--warn-bg); border-color: var(--warn-line); color: var(--warn-text); }
.msg.err { background: var(--err-bg); border-color: var(--err-line); color: var(--err-text); }
.msg.ok { background: var(--ok-bg); border-color: var(--ok-line); color: var(--ok-text); }
.msg.info { background: var(--info-bg); border-color: var(--info-line); color: var(--info-text); }
.test-label { display: inline-block; background: var(--warn-bg); color: var(--warn-text); border: 1px solid var(--warn-line); font-weight: 600; font-size: 0.78rem; padding: 2px 9px; border-radius: 4px; font-family: var(--mono); letter-spacing: 0.02em; }

/* Meters and stats */
.meter { height: 6px; border-radius: 3px; background: var(--surface-2); border: 1px solid var(--line); overflow: hidden; margin: 8px 0; }
.meter > i { display: block; height: 100%; width: 0; background: var(--meter-0); transition: width 0.2s, background 0.2s; }
.meter[data-level="1"] > i { background: var(--meter-1); }
.meter[data-level="2"] > i { background: var(--meter-2); }
.meter[data-level="3"] > i { background: var(--meter-3); }
.meter[data-level="4"] > i { background: var(--meter-4); }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 12px 0; }
.stat { background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 9px 12px; }
.stat b { display: block; font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-family: var(--mono); font-weight: 600; }
.stat span { font-size: 1.05rem; font-weight: 600; }
.stat .mono-break { font-family: var(--mono); font-size: 0.82rem; font-weight: 600; word-break: break-all; }

/* Drop zone */
.label.drop, label.drop { display: block; }
.drop:focus-within { outline: 2px solid var(--focus); outline-offset: 2px; }
.drop { border: 1px dashed var(--line-strong); border-radius: var(--radius); padding: 26px 14px; text-align: center; background: var(--surface-2); cursor: pointer; }
.drop.over { border-color: var(--accent); border-style: solid; }
.drop p { margin: 4px 0; }

/* Code previews stay on white so scanners and printers get a clean code in both themes */
.qr-stage { display: grid; place-items: center; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; min-height: 260px; }
.qr-stage canvas, .qr-stage svg { max-width: 100%; height: auto; image-rendering: pixelated; }
/* The preview always occupies the same square whatever the pixel size of the code, so drawing it never moves the page. */
.qr-stage canvas { width: min(100%, 320px); aspect-ratio: 1 / 1; }
.barcode-preview { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; text-align: center; margin: 12px 0; overflow-x: auto; }
.barcode-preview svg { max-width: 100%; height: auto; display: inline-block; }
.preview-box { border: 1px dashed var(--line-strong); border-radius: var(--radius); min-height: 220px; background: var(--surface-2); position: relative; overflow: hidden; }

.mono { font-family: var(--mono); }
.mt-sm { margin-top: 6px; }
.mt-md { margin-top: 14px; }
.mt-lg { margin-top: 22px; }
.mb-0 { margin-bottom: 0; }
.copy-ok { color: var(--accent); font-weight: 700; }
.input-row { display: flex; gap: 8px; align-items: stretch; flex-wrap: wrap; }
.input-row input { flex: 1 1 14rem; min-width: 0; }
.input-row .btn { flex: 0 0 auto; }
.result-list { margin: 6px 0 12px; padding-left: 1.2em; }
.result-list li { margin: 4px 0; }
.inline-field { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
.inline-field label { margin: 0; font-weight: 600; font-size: 0.9rem; }
.inline-field select { width: auto; }
.link-btn { font: inherit; color: inherit; background: none; border: 0; padding: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.link-btn:hover { text-decoration-thickness: 2px; }

/* Cookie choice */
.consent { position: fixed; left: 12px; right: 12px; bottom: 12px; max-width: 44rem; margin: 0 auto; z-index: 60; background: var(--surface); color: var(--text); border: 1px solid var(--line-strong); border-radius: var(--radius); padding: 12px 14px; display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; justify-content: space-between; }
.consent p { margin: 0; flex: 1 1 18rem; font-size: 0.88rem; }
.consent-actions { display: flex; gap: 8px; }

/* Contact */
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.contact-form { margin: 0 0 2rem; padding: 18px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); color: var(--muted); padding: 32px 0 24px; margin-top: 24px; font-size: 0.9rem; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--text); text-decoration: underline; }
.foot-grid { display: grid; gap: 24px; grid-template-columns: 1fr; }
@media (min-width: 760px) { .foot-grid { grid-template-columns: 1.3fr 1.5fr 1fr; } }
.foot-brand { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--text); font-size: 1rem; margin: 0 0 8px; }
.foot-copy { margin: 0; }
.foot-h { font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); margin: 0 0 8px; font-family: var(--mono); font-weight: 600; }
.foot-list { list-style: none; padding: 0; margin: 0 0 16px; }
.foot-list li { margin: 4px 0; }
@media (min-width: 520px) { .foot-list.two { columns: 2; column-gap: 20px; } }
.foot-note { border-top: 1px solid var(--line); margin: 14px 0 0; padding-top: 14px; font-size: 0.8rem; }

/* Home */
.home-hero { padding: 40px 0 8px; }
.home-hero h1 { font-size: clamp(2rem, 6vw, 3rem); max-width: 20ch; letter-spacing: -0.03em; }
.home-hero .answer { font-size: 1.1rem; }
.home-section { margin-top: 34px; }
.home-section h2 { font-size: 1.2rem; margin: 0 0 4px; letter-spacing: -0.01em; }
.home-section > p { color: var(--muted); margin: 0 0 8px; }
.value-grid { display: grid; gap: 18px; grid-template-columns: 1fr; margin-top: 12px; }
@media (min-width: 760px) { .value-grid { grid-template-columns: repeat(3, 1fr); } }
.value { border-top: 1px solid var(--text); padding-top: 10px; }
.value h3 { margin: 0 0 4px; font-size: 1rem; }
.value p { margin: 0; color: var(--muted); font-size: 0.94rem; }

/* Guides: the interactive and visual parts. Every part reads well as plain HTML; guide.js only adds behaviour. */
.guide { max-width: 760px; }
.guide-page .prose h2 { scroll-margin-top: 16px; }
.byline { font-size: 0.86rem; color: var(--muted); margin: 0 0 12px; }
.byline a { color: var(--muted); }
.part-title { font-family: var(--mono); font-size: 0.74rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); margin: 0 0 10px; }
.prose h3.part-title { font-size: 0.74rem; margin: 0 0 10px; font-weight: 600; }
.takeaways { background: var(--ok-bg); border: 1px solid var(--ok-line); border-radius: var(--radius); padding: 14px 18px; margin: 0 0 22px; color: var(--ok-text); }
.takeaways .part-title { color: var(--ok-text); }
.takeaways ul { margin: 0; padding-left: 1.2rem; }
.takeaways li { color: var(--ok-text); margin: 0.35rem 0; }
.toc { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 12px 18px; margin: 0 0 8px; }
.toc ol { margin: 0; padding-left: 1.3rem; columns: 1; }
@media (min-width: 640px) { .toc ol { columns: 2; column-gap: 28px; } }
.toc li { margin: 0.2rem 0; break-inside: avoid; }
.guide-section { margin-top: 2.4rem; }
.myths { margin-bottom: 1.2rem; }
.guide-group h2 { font-size: 1.15rem; margin: 26px 0 0; }

.chart, .diagram, .calc, .try, .checklist, .quiz { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin: 1.4rem 0; }
.chart figcaption { margin: 0 0 12px; }
.bars { list-style: none; margin: 0; padding: 0 !important; display: grid; gap: 10px; }
.bars li { display: grid; grid-template-columns: 1fr; gap: 3px; margin: 0; }
@media (min-width: 560px) { .bars li { grid-template-columns: 11rem 1fr 6.5rem; align-items: center; gap: 12px; } }
.bar-label { font-size: 0.9rem; }
.bar-track { display: block; height: 14px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 7px; overflow: hidden; }
.bar-fill { display: block; height: 100%; background: var(--line-strong); }
.bar-fill.accent { background: var(--accent); }
.bar-value { font-family: var(--mono); font-size: 0.84rem; color: var(--muted); }
@media (min-width: 560px) { .bar-value { text-align: right; } }
.chart-note { font-size: 0.86rem; color: var(--muted); margin: 10px 0 0; }
.chart-data { margin-top: 10px; }
.chart-data summary, .qz-why summary, .myths summary { cursor: pointer; font-size: 0.9rem; }
.chart-data .table-wrap { margin: 8px 0 0; }
.graph svg { width: 100%; height: auto; display: block; }
.g-grid { stroke: var(--line); stroke-width: 1; }
.g-label { fill: var(--muted); font-size: 10.5px; font-family: var(--font); }
.g-line { stroke-width: 2.5; stroke-linejoin: round; }
.g-line.s1, .key.s1 { stroke: var(--meter-0); background: var(--meter-0); }
.g-line.s2, .key.s2 { stroke: var(--meter-2); background: var(--meter-2); }
.g-line.s3, .key.s3 { stroke: var(--accent); background: var(--accent); }
.g-dot.s1 { fill: var(--meter-0); } .g-dot.s2 { fill: var(--meter-2); } .g-dot.s3 { fill: var(--accent); }
.legend { list-style: none; display: flex; flex-wrap: wrap; gap: 4px 18px; padding: 0 !important; margin: 8px 0 0; font-size: 0.86rem; }
.legend li { display: inline-flex; align-items: center; gap: 7px; margin: 0; }
.key { width: 18px; height: 4px; border-radius: 2px; flex: none; }

.flow { list-style: none; margin: 0; padding: 0 !important; display: grid; gap: 10px; counter-reset: f; }
@media (min-width: 720px) { .flow { grid-auto-flow: column; grid-auto-columns: 1fr; } }
.flow-step { counter-increment: f; margin: 0; position: relative; background: var(--surface-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; display: flex; flex-direction: column; gap: 4px; font-size: 0.9rem; }
.flow-step::before { content: counter(f); font-family: var(--mono); font-size: 0.74rem; font-weight: 600; color: var(--accent); }
.flow-step.accent { border-color: var(--accent); }
.flow-step span { color: var(--muted); }
@media (min-width: 720px) { .flow-step:not(:last-child)::after { content: ""; position: absolute; right: -9px; top: 50%; width: 8px; height: 8px; border-top: 2px solid var(--line-strong); border-right: 2px solid var(--line-strong); transform: translateY(-50%) rotate(45deg); background: transparent; } }

.myths details { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 10px 14px; margin: 8px 0; }
.myths p { margin: 8px 0 0; }
.tag { display: inline-block; font-family: var(--mono); font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; padding: 1px 7px; border-radius: 4px; margin-right: 6px; }
.tag.myth { background: var(--err-bg); color: var(--err-text); border: 1px solid var(--err-line); }
.tag.fact { background: var(--ok-bg); color: var(--ok-text); border: 1px solid var(--ok-line); }

.tabs { margin: 1.4rem 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); padding: 14px 18px; position: relative; }
.tabs > input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.tab-labels { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 12px; padding: 0 !important; }
.tab-labels li { margin: 0; }
.tab-labels label { display: inline-block; cursor: pointer; font-size: 0.9rem; padding: 6px 12px; border-radius: 6px; border: 1px solid var(--line-strong); background: var(--surface); }
.tab-panel { display: none; }
.tab-panel h3 { margin-top: 0; }
.tabs > input:nth-of-type(1):checked ~ .tab-panel:nth-of-type(1),
.tabs > input:nth-of-type(2):checked ~ .tab-panel:nth-of-type(2),
.tabs > input:nth-of-type(3):checked ~ .tab-panel:nth-of-type(3),
.tabs > input:nth-of-type(4):checked ~ .tab-panel:nth-of-type(4) { display: block; }
.tabs > input:nth-of-type(1):checked ~ .tab-labels li:nth-child(1) label,
.tabs > input:nth-of-type(2):checked ~ .tab-labels li:nth-child(2) label,
.tabs > input:nth-of-type(3):checked ~ .tab-labels li:nth-child(3) label,
.tabs > input:nth-of-type(4):checked ~ .tab-labels li:nth-child(4) label { background: var(--text); color: var(--bg); border-color: var(--text); }
.tabs > input:focus-visible ~ .tab-labels label { outline: 2px solid var(--focus); outline-offset: 2px; }

.ck-list { list-style: none; margin: 0; padding: 0 !important; }
.ck-list li { margin: 0; border-top: 1px solid var(--line); }
.ck-list li:first-child { border-top: 0; }
.ck-list label { display: flex; gap: 12px; align-items: flex-start; padding: 10px 2px; cursor: pointer; }
.ck-list input { margin-top: 3px; }
.ck-list input:checked + span { color: var(--muted); text-decoration: line-through; text-decoration-thickness: 1px; }
.ck-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.ck-foot:not([hidden]) { display: flex; }
.ck-bar { flex: 1 1 140px; height: 8px; accent-color: var(--accent); }
.ck-count { font-size: 0.88rem; color: var(--muted); font-family: var(--mono); }

.qz-list { list-style: none; margin: 0; padding: 0 !important; counter-reset: q; }
.qz-q { counter-increment: q; margin: 0 0 18px; }
.qz-q legend { font-weight: 600; margin-bottom: 8px; }
.qz-q legend::before { content: counter(q) ". "; color: var(--accent); font-family: var(--mono); }
.qz-opt { display: flex; gap: 10px; align-items: flex-start; padding: 8px 12px; margin: 6px 0; border: 1px solid var(--line); border-radius: 6px; cursor: pointer; background: var(--bg); }
.qz-opt:hover { border-color: var(--line-strong); }
.qz-opt input { margin-top: 3px; }
.qz-opt.right { border-color: var(--ok-line); background: var(--ok-bg); color: var(--ok-text); }
.qz-opt.wrong { border-color: var(--err-line); background: var(--err-bg); color: var(--err-text); }
.qz-fb { font-weight: 600; margin: 6px 0; }
.qz-why { margin-top: 4px; }
.qz-why p { margin: 6px 0 0; font-size: 0.94rem; }
.qz-foot:not([hidden]) { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; padding-top: 10px; border-top: 1px solid var(--line); }
.qz-score { margin: 0; font-weight: 700; }

.calc-form { display: grid; gap: 0 16px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .calc-form { grid-template-columns: 1fr 1fr; } }
.calc-out, .try-out { display: grid; gap: 10px; grid-template-columns: 1fr; margin: 6px 0 12px; }
@media (min-width: 640px) { .calc-out { grid-template-columns: repeat(2, 1fr); } }
.calc-out > div, .try-out > div { background: var(--surface-2); border: 1px solid var(--line); border-radius: 6px; padding: 9px 12px; min-width: 0; }
.calc-out dt, .try-out dt { font-family: var(--mono); font-size: 0.72rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); }
.calc-out dd, .try-out dd { margin: 2px 0 0; font-size: 1.1rem; font-weight: 650; overflow-wrap: anywhere; }
.try-out dd.hash { font-family: var(--mono); font-size: 0.8rem; font-weight: 500; word-break: break-all; }
.try-out mark { background: var(--warn-bg); color: var(--warn-text); border-radius: 2px; }
.calc-msg { color: var(--warn-text); background: var(--warn-bg); border: 1px solid var(--warn-line); border-radius: 6px; padding: 8px 12px; }
.calc-form .wide { grid-column: 1 / -1; }
.calc h4 { margin: 1rem 0 0.2rem; font-size: 0.98rem; }
.guide-note { margin-top: 2rem; }
.guide-tools, .related-guides { margin-top: 3rem; }

@media (prefers-reduced-motion: reduce) { * { transition: none !important; } .cards a:hover::after { transform: rotate(45deg); } }
@media print { .site-header, .site-footer, .chips, .consent { display: none; } body { background: #fff; color: #000; } }
