/* Built from site.json: edit brand colours and fonts there. */
:root {
  --ink: #1A2B45;
  --paper: #F5F1E8;
  --paper-2: #EAE4D6;
  --accent: #2F7A4F;
  --accent-hover: #256340;
  --accent-on-dark: #8FD3A8;
  --accent-soft: #DCEDE2;
  --muted: #5B6474;
  --line: #D8D1C0;
  --dark: #13213A;
  --warn: #9a5200;
  --head: "Familjen Grotesk", "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --body: "IBM Plex Sans", "Segoe UI", system-ui, -apple-system, Roboto, Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, Consolas, "Cascadia Mono", Menlo, monospace;
  --r: 6px;
}

/* Ditch Subscriptions site styles. Brand tokens (colours, fonts, radius) are written above this by build.py from site.json.
   Design notes: a workbench, not a brochure. Light paper, near-black ink, one teal accent used only for actions
   and state. Headings in a grotesk, body in a plain sans, numbers and file details in a mono face. */

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { transition: none !important; animation: none !important; } }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 1.0625rem/1.6 var(--body); overflow-x: hidden; }
img { max-width: 100%; height: auto; display: block; }
[hidden] { display: none !important; }
a { color: var(--accent); text-underline-offset: 3px; }
a:hover { color: var(--accent-hover); }
h1, h2, h3 { font-family: var(--head); line-height: 1.1; letter-spacing: -0.015em; margin: 0 0 0.5em; text-wrap: balance; }
h1 { font-size: clamp(2.1rem, 1.3rem + 3vw, 3.5rem); font-weight: 700; }
h2 { font-size: clamp(1.5rem, 1.1rem + 1.5vw, 2.2rem); font-weight: 700; }
h3 { font-size: clamp(1.1rem, 1rem + 0.4vw, 1.3rem); font-weight: 600; }
p { margin: 0 0 1em; }
code, .mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }
code { font-size: 0.9em; background: var(--paper-2); padding: 0 5px; border-radius: 4px; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.dark :focus-visible, .site-header :focus-visible, .site-footer :focus-visible { outline-color: var(--accent-on-dark); }
.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
.skip { position: absolute; left: 12px; top: -80px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; }
.skip:focus { top: 12px; }
.tbd { background: #ffe066; color: #000; padding: 0 4px; font-weight: 700; }
.beta-bar { background: #ffe066; color: #000; font-size: 0.9rem; padding: 8px 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- buttons and labels ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 11px 20px;
  background: var(--accent); color: #fff; border: 2px solid var(--accent); border-radius: var(--r);
  font: 600 0.95rem/1.2 var(--head); text-decoration: none; cursor: pointer;
}
.btn:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: #fff; }
.btn.ghost { background: transparent; color: var(--ink); border-color: currentColor; }
.btn.ghost:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.dark .btn.ghost, .hero .btn.ghost { color: #fff; }
.dark .btn.ghost:hover { background: #fff; color: var(--ink); }
.btn.small { min-height: 44px; padding: 6px 12px; font-size: 0.85rem; }
.btn:disabled, .btn[aria-disabled="true"] { opacity: 0.45; cursor: not-allowed; }
.btn svg { width: 18px; height: 18px; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 24px; align-items: center; }
@media (max-width: 480px) { .actions .btn { flex: 1 1 100%; } }
.label { display: inline-block; font: 600 0.74rem/1.2 var(--head); letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }
.dark .label { color: var(--accent-on-dark); }
.lead { font-size: clamp(1.08rem, 1rem + 0.4vw, 1.25rem); color: var(--muted); max-width: 62ch; }
.dark .lead { color: #c3ccd1; }
.note { font-size: 0.92rem; color: var(--muted); }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--dark); color: #fff; }
.site-header .wrap { display: flex; align-items: center; gap: 24px; min-height: 68px; }
.brand img { width: auto; height: 32px; }
.nav { margin-left: auto; }
.nav ul { list-style: none; display: flex; gap: 2px; margin: 0; padding: 0; }
.nav a { display: block; padding: 10px 12px; color: #fff; text-decoration: none; font: 600 0.95rem var(--head); white-space: nowrap; }
.nav a:hover, .nav a[aria-current] { color: var(--accent-on-dark); }
.nav-action { display: none; }
.header-cta { display: flex; align-items: center; gap: 16px; }
.menu-btn { display: none; margin-left: auto; min-height: 44px; padding: 8px 16px; background: transparent; color: #fff; border: 2px solid rgba(255,255,255,.4); border-radius: var(--r); font: 600 0.85rem var(--head); letter-spacing: 0.06em; text-transform: uppercase; cursor: pointer; }
@media (max-width: 900px) {
  .menu-btn { display: block; }
  .header-cta { display: none; }
  .nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--dark); border-top: 1px solid rgba(255,255,255,.12); }
  html:not(.js) .nav, .nav.open { display: block; }
  html:not(.js) .menu-btn { display: none; }
  .nav ul { flex-direction: column; padding: 8px 16px 16px; }
  .nav a { padding: 14px 4px; border-bottom: 1px solid rgba(255,255,255,.1); }
  .nav-action { display: block; }
}

/* ---------- sections ---------- */
.section { padding: clamp(56px, 7vw, 96px) 0; }
.section.tight { padding: clamp(36px, 5vw, 60px) 0; }
.rule-top { border-top: 1px solid var(--line); }
.dark { background: var(--dark); color: #eef1f3; }
.dark a:not(.btn) { color: #fff; }
.page-head { padding: clamp(40px, 6vw, 72px) 0 clamp(24px, 4vw, 40px); }
.page-head .lead { margin-bottom: 0; }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 72px); align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }
.prose { max-width: 70ch; }
.prose h2 { margin-top: 1.6em; }
.prose h2:first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 22px; }
.prose li { margin-bottom: 6px; }
.prose p > a, .prose li > a, .faq a, .ledger a, .note a { padding-block: 10px; }

/* ---------- hero: the drop zone is the headline ---------- */
.hero { background: var(--dark); color: #fff; padding: clamp(40px, 6vw, 80px) 0 clamp(48px, 7vw, 88px); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.hero .lead { color: #c3ccd1; }
.hero h1 { color: #fff; }
.hero .label { color: var(--accent-on-dark); }
.hero .promises { list-style: none; margin: 28px 0 0; padding: 0; display: grid; gap: 10px; font-size: 1rem; }
.hero .promises li { display: grid; grid-template-columns: 22px 1fr; gap: 10px; align-items: start; color: #e3e8ec; }
.hero .promises svg { width: 22px; height: 22px; color: var(--accent-on-dark); }
@media (max-width: 860px) { .hero .wrap { grid-template-columns: 1fr; } }
.drop {
  border: 2px dashed rgba(255,255,255,.35); border-radius: 10px; padding: clamp(28px, 4vw, 44px) 20px; text-align: center; cursor: pointer;
  display: grid; gap: 10px; justify-items: center; background: rgba(255,255,255,.04); transition: border-color .15s, background .15s;
}
.drop:hover, .drop.over, .drop:focus-visible { border-color: var(--accent-on-dark); background: rgba(95,211,220,.08); }
.drop strong { font: 600 1.25rem var(--head); }
.drop span { color: #aab4bd; font-size: 0.92rem; max-width: 36ch; }
.drop .reel { display: flex; gap: 5px; margin-bottom: 4px; }
.drop .reel i { width: 30px; height: 20px; border-radius: 3px; background: rgba(255,255,255,.18); display: block; }
.drop .reel i:nth-child(3) { background: var(--accent-on-dark); }
.drop-result { margin-top: 16px; background: rgba(255,255,255,.06); border-radius: var(--r); padding: 16px 18px; }
.drop-result p { margin: 0; }
.drop-result .actions { margin-top: 12px; }
.drop-result .btn { background: #fff; color: var(--ink); border-color: #fff; }
.drop-result .btn:hover { background: var(--accent-on-dark); border-color: var(--accent-on-dark); }
html:not(.js) .drop, html:not(.js) .drop-result { display: none; }

/* ---------- tool index ---------- */
.tool-groups { display: grid; gap: clamp(28px, 4vw, 44px); }
.tool-group h2 { font-size: 1.2rem; display: flex; align-items: baseline; gap: 12px; }
.tool-group h2 small { font: 500 0.78rem var(--mono); color: var(--muted); }
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 12px; list-style: none; margin: 0; padding: 0; }
.tool-grid a { display: grid; gap: 4px; padding: 16px 18px; min-height: 100px; border: 1px solid var(--line); border-radius: var(--r); background: #fff; color: var(--ink); text-decoration: none; }
.tool-grid a:hover { border-color: var(--accent); }
.tool-grid strong { font: 600 1.05rem var(--head); }
.tool-grid span { font-size: 0.92rem; color: var(--muted); }
.tool-grid .soon { display: grid; gap: 4px; padding: 16px 18px; min-height: 100px; border: 1px dashed var(--line); border-radius: var(--r); color: var(--muted); }
.tool-grid .soon strong { font: 600 1.05rem var(--head); color: var(--ink); }
.tool-grid .soon em { font-style: normal; font: 500 0.72rem var(--mono); color: var(--accent); text-transform: uppercase; letter-spacing: 0.08em; }

/* ---------- tool pages ---------- */
.tool-head { padding: clamp(32px, 5vw, 56px) 0 24px; }
.tool-head h1 { font-size: clamp(1.9rem, 1.2rem + 2.4vw, 2.9rem); }
.tool-head .lead { margin-bottom: 0; }
.tool { background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: clamp(16px, 3vw, 28px); display: grid; gap: 16px; }
.tool-grid2 { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 18px; align-items: start; }
@media (max-width: 820px) { .tool-grid2 { grid-template-columns: minmax(0, 1fr); } }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); padding: 16px; min-width: 0; display: grid; gap: 14px; }
.panel h2 { font: 600 0.78rem var(--head); letter-spacing: 0.09em; text-transform: uppercase; color: var(--muted); margin: 0; }
.tool .drop { border-color: var(--line); background: #fff; color: var(--ink); }
.tool .drop:hover, .tool .drop.over, .tool .drop:focus-visible { border-color: var(--accent); background: var(--accent-soft); }
.tool .drop span { color: var(--muted); }
.tool .drop .reel i { background: var(--line); }
.tool .drop .reel i:nth-child(3) { background: var(--accent); }
.tool video, .tool canvas.strip { width: 100%; max-width: 100%; border-radius: var(--r); display: block; }
.tool video { background: #000; max-height: 380px; }
.tool canvas.strip { height: 46px; background: #fff; cursor: pointer; }
.meta { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 4px 14px; font-variant-numeric: tabular-nums; }
.meta b { color: var(--ink); font-weight: 500; }
.two { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.field { display: grid; gap: 5px; min-width: 0; align-content: start; }
.field label { font-size: 0.85rem; font-weight: 600; }
.hint { font-size: 0.78rem; color: var(--muted); font-weight: 400; }
.tool input[type="number"], .tool input[type="text"], .tool input[type="url"], .tool input[type="password"], .tool select, .tool textarea {
  width: 100%; min-width: 0; font: 500 0.92rem var(--mono); color: var(--ink); background: #fff;
  border: 1px solid #8a9298; border-radius: var(--r); padding: 8px 10px; min-height: 40px;
}
.tool textarea { min-height: 90px; resize: vertical; font-family: var(--body); }
.tool input[type="range"] { width: 100%; accent-color: var(--accent); min-height: 44px; margin: 0; }
.chk input { width: 22px; height: 22px; }
.tool input[type="color"] { width: 56px; height: 44px; padding: 2px; border: 1px solid #8a9298; border-radius: var(--r); background: #fff; }
.chk { display: flex; gap: 8px; align-items: center; font-size: 0.92rem; font-weight: 500; }
.chk input { accent-color: var(--accent); width: 22px; height: 22px; flex: none; }
.chk { min-height: 44px; }
.row { display: flex; gap: 8px; align-items: center; }
.estimate { background: var(--accent-soft); border-radius: var(--r); padding: 10px 12px; font-family: var(--mono); font-size: 0.82rem; display: grid; gap: 2px; font-variant-numeric: tabular-nums; }
.estimate .warn { color: var(--warn); font-family: var(--body); }
.progress { height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; }
.progress div { height: 100%; width: 0; background: var(--accent); transition: width .1s linear; }
.status { font-size: 0.9rem; color: var(--muted); min-height: 1.4em; margin: 0; }
.status.warn { color: var(--warn); }
.result { display: grid; gap: 10px; justify-items: start; }
.result img { border-radius: var(--r); border: 1px solid var(--line); max-width: 100%; background: repeating-conic-gradient(var(--line) 0 25%, transparent 0 50%) 0 0 / 16px 16px; }
.result .mark { font-family: var(--mono); font-size: 0.8rem; }
.list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: var(--r); padding: 8px 10px; background: #fff; font-size: 0.9rem; }
.list .name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 500; }
.list .sizes { font-family: var(--mono); font-size: 0.78rem; color: var(--muted); }
.list .sizes b { color: var(--accent); font-weight: 500; }
.list .ops { display: flex; gap: 4px; }
.list .ops button { min-height: 32px; padding: 4px 9px; font-size: 0.85rem; }
.empty { border: 1px dashed var(--line); border-radius: var(--r); padding: 16px; color: var(--muted); font-size: 0.9rem; text-align: center; }
kbd { font-family: var(--mono); font-size: 0.72rem; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; padding: 0 5px; background: #fff; }
.tabs { display: inline-flex; border: 1px solid var(--line); border-radius: 7px; padding: 2px; background: #fff; }
.tabs button { border: 0; background: none; padding: 7px 12px; font: 600 0.85rem var(--head); border-radius: 5px; color: var(--ink); cursor: pointer; min-height: 44px; }
.tabs button[aria-pressed="true"] { background: var(--accent); color: #fff; }
.upsell { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; background: var(--dark); color: #eef1f3; border-radius: var(--r); padding: 18px 22px; margin-top: 18px; }
.upsell p { margin: 0; }
.upsell strong { color: #fff; font-family: var(--head); }
.upsell .btn { background: #fff; color: var(--ink); border-color: #fff; }
.upsell .btn:hover { background: var(--accent-on-dark); border-color: var(--accent-on-dark); }
@media (max-width: 640px) { .upsell { grid-template-columns: 1fr; } }
.clips { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.clip { display: grid; grid-template-columns: 96px minmax(0, 1fr) auto; gap: 10px; align-items: center; border: 1px solid var(--line); border-radius: var(--r); padding: 6px; background: #fff; }
.clip.playing { border-color: var(--accent); }
.clip .thumb { width: 96px; aspect-ratio: 16 / 9; max-width: 100%; padding: 0; border: 0; border-radius: 5px; overflow: hidden; background: var(--line); position: relative; cursor: pointer; }
.clip .thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.clip .title { font-size: 0.85rem; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.clip .tag { font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--accent); margin-left: 6px; font-weight: 600; }
.clip .times { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; font-family: var(--mono); font-size: 0.78rem; color: var(--muted); }
.clip .times input { width: 76px; min-height: 32px; padding: 3px 6px; font-size: 0.78rem; }
.clip .ops { display: flex; gap: 4px; }
.clip .ops button { min-height: 32px; padding: 3px 8px; font-size: 0.85rem; }
@media (max-width: 480px) { .clip { grid-template-columns: 72px minmax(0, 1fr); } .clip .thumb { width: 72px; } .clip .ops { grid-column: 1 / -1; justify-content: flex-end; } }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 999px; padding: 3px 4px 3px 12px; font-size: 0.85rem; background: #fff; max-width: 100%; }
.chip.active { border-color: var(--accent); background: var(--accent-soft); }
.chip .name { cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 22ch; background: none; border: 0; padding: 4px 0; font: inherit; color: inherit; }
.chip .dur { font-family: var(--mono); font-size: 0.75rem; color: var(--muted); }
.chip .x { border: 0; background: none; color: var(--muted); padding: 4px 9px; border-radius: 999px; font-size: 1rem; line-height: 1; cursor: pointer; min-height: 32px; }
.chip .x:hover { color: var(--ink); background: var(--line); }
.legend { font-size: 0.75rem; color: var(--muted); display: flex; gap: 14px; flex-wrap: wrap; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; vertical-align: -1px; margin-right: 5px; }
.marks { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.markval { font-family: var(--mono); font-size: 0.85rem; font-variant-numeric: tabular-nums; padding: 0 4px; }
.tool button.plain { font: 600 0.85rem var(--head); border-radius: var(--r); padding: 6px 11px; cursor: pointer; border: 1px solid var(--line); background: #fff; color: var(--ink); min-height: 44px; }
.tool button.plain:hover { border-color: var(--accent); }
.tool button.plain:disabled { opacity: 0.45; cursor: not-allowed; }

/* ---------- how-to and FAQ on tool pages ---------- */
.tool-copy { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: clamp(32px, 5vw, 72px); align-items: start; }
@media (max-width: 960px) { .tool-copy { grid-template-columns: 1fr; } }
.steps { list-style: none; counter-reset: step; padding: 0; display: grid; gap: 12px; }
.steps li { counter-increment: step; position: relative; padding: 14px 16px 14px 60px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); }
.steps li::before { content: counter(step); position: absolute; left: 18px; top: 12px; font: 700 1.1rem var(--head); color: var(--accent); }
.steps h3 { margin-bottom: 2px; font-size: 1rem; }
.steps p { margin: 0; color: var(--muted); font-size: 0.95rem; }
.faq { border-top: 2px solid var(--ink); margin-top: 20px; }
.qa { padding: 18px 0; border-bottom: 1px solid var(--line); }
.qa h3 { margin: 0 0 6px; font-size: 1.05rem; }
.qa p { margin: 0; color: var(--muted); }
.aside { position: sticky; top: 92px; background: var(--dark); color: #eef1f3; padding: 26px; border-radius: var(--r); }
.aside h2 { font-size: 1.25rem; color: #fff; }
.aside p { color: #c3ccd1; font-size: 0.95rem; }
.aside ul { padding-left: 18px; color: #e3e8ec; font-size: 0.95rem; margin: 0 0 16px; }
.aside .btn { width: 100%; }
.aside a:not(.btn) { color: #fff; }
@media (max-width: 960px) { .aside { position: static; } }
.related { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 2px solid var(--ink); margin-top: 20px; }
.related a { display: block; padding: 18px 20px 18px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.related strong { display: block; font: 600 1.1rem var(--head); margin-bottom: 4px; }
.related span { color: var(--muted); font-size: 0.95rem; }
.related a:hover strong { color: var(--accent); }
@media (max-width: 760px) { .related { grid-template-columns: 1fr; } }

/* ---------- pricing ---------- */
.ladder { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 14px; margin-top: 28px; }
.rung { background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: 10px; padding: 20px; display: grid; gap: 8px; align-content: start; }
.rung .note { color: var(--muted); }
.rung a:not(.btn) { color: var(--accent-hover); }
.rung.hot { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.rung .name { font: 600 0.76rem var(--head); text-transform: uppercase; letter-spacing: 0.08em; color: var(--muted); }
.rung .price { font: 700 2rem/1 var(--head); font-variant-numeric: tabular-nums; }
.rung .price small { font: 500 0.85rem var(--body); color: var(--muted); }
.rung ul { padding-left: 18px; margin: 4px 0 0; font-size: 0.93rem; }
.rung li { margin-bottom: 4px; }
.compare { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: #fff; margin-top: 24px; }
.compare table { min-width: 0; }
.callout a { color: var(--accent-hover); }
table { border-collapse: collapse; width: 100%; font-size: 0.93rem; min-width: 560px; }
th, td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font: 600 0.74rem var(--head); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); background: var(--paper); }
tr:last-child td { border-bottom: 0; }
td.num, th.num { text-align: right; font-family: var(--mono); font-variant-numeric: tabular-nums; white-space: nowrap; }
.callout { border-left: 3px solid var(--accent); background: var(--accent-soft); padding: 12px 16px; border-radius: 0 var(--r) var(--r) 0; margin: 20px 0; max-width: 70ch; }
.callout p:last-child { margin: 0; }

/* ---------- why / manifesto ---------- */
.manifesto { max-width: 66ch; font-size: clamp(1.1rem, 1rem + 0.5vw, 1.3rem); line-height: 1.6; }
.manifesto p { margin-bottom: 1.2em; }
.manifesto strong { font-family: var(--head); }
.bills { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 12px; margin: 24px 0; }
.bill { background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 14px 16px; }
.bill b { display: block; font: 700 1.5rem/1.1 var(--head); font-variant-numeric: tabular-nums; }
.bill span { font-size: 0.88rem; color: var(--muted); }

/* ---------- open-source ledger ---------- */
.ledger { list-style: none; margin: 20px 0 0; padding: 0; border-top: 2px solid var(--ink); }
.ledger li { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr) auto; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.ledger .lic { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); }
.ledger .paid { font-family: var(--mono); font-variant-numeric: tabular-nums; text-align: right; }
@media (max-width: 600px) { .ledger li { grid-template-columns: 1fr; gap: 4px; } .ledger .paid { text-align: left; } }

/* ---------- notify form ---------- */
.notify { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: end; max-width: 520px; }
.notify .field-error { grid-column: 1 / -1; }
.notify label { font-weight: 600; font-size: 0.92rem; }
.notify input { font: inherit; color: var(--ink); background: #fff; border: 1px solid #8a9298; border-radius: var(--r); padding: 11px 14px; min-height: 46px; width: 100%; }
.notify input[aria-invalid="true"] { border: 2px solid #b3261e; }
.field-error { margin: 0; font-size: 0.9rem; font-weight: 600; color: #b3261e; }
.field-error:empty { display: none; }
.form-status { margin-top: 12px; padding: 14px; background: var(--paper-2); border-left: 4px solid var(--accent); font-size: 0.95rem; }
.form-status:empty { display: none; }
@media (max-width: 520px) { .notify { grid-template-columns: 1fr; } }

/* ---------- footer ---------- */
.site-footer { background: var(--dark); color: #c3ccd1; padding: 56px 0 28px; font-size: 0.95rem; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 32px; }
.site-footer h2 { font-size: 0.74rem; letter-spacing: 0.12em; text-transform: uppercase; color: #fff; margin-bottom: 10px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 2px; overflow-wrap: anywhere; }
.site-footer li a { display: inline-block; padding: 10px 0; min-height: 44px; color: #e3e8ec; }
.site-footer a:hover { color: var(--accent-on-dark); }
.footer-logo { height: 32px; width: auto; margin-bottom: 14px; }
.footer-base { margin-top: 40px; padding-top: 18px; border-top: 1px solid rgba(255,255,255,.12); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; font-size: 0.85rem; color: #9aa4ad; }
@media (max-width: 860px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- breadcrumbs ---------- */
.crumbs { font-size: 0.85rem; margin-bottom: 16px; color: var(--muted); }
.crumbs ol { list-style: none; display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; }
.crumbs li + li::before { content: "/"; margin-right: 6px; opacity: .6; }
.crumbs a, .crumbs li[aria-current] { display: inline-block; padding: 12px 0; }

/* ---------- blog ---------- */
.post-list { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.post-list li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px 32px; padding: 20px 0; border-bottom: 1px solid var(--line); align-items: baseline; }
.post-list a { display: grid; gap: 4px; color: var(--ink); text-decoration: none; }
.post-list a strong { font: 600 1.2rem/1.25 var(--head); }
.post-list a:hover strong { color: var(--accent); }
.post-list a span { color: var(--muted); font-size: 0.95rem; max-width: 70ch; }
.post-list time { font-size: 0.8rem; color: var(--muted); white-space: nowrap; }
@media (max-width: 640px) { .post-list li { grid-template-columns: 1fr; } }
.post-meta { font-size: 0.82rem; color: var(--muted); margin: 0; }
.post > p:first-child { font-size: 1.15rem; line-height: 1.55; }
.post h3 { margin-top: 1.4em; }
.post-cta { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; margin-top: 40px; padding: 20px 22px; background: var(--dark); color: #eef1f3; border-radius: var(--r); }
.post-cta strong { font: 600 1.15rem var(--head); color: #fff; }
.post-cta p { margin: 4px 0 0; font-size: 0.95rem; color: #c3ccd1; }
.post-cta .btn { background: #fff; color: var(--ink); border-color: #fff; }
.post-cta .btn:hover { background: var(--accent-on-dark); border-color: var(--accent-on-dark); color: var(--ink); }
@media (max-width: 560px) { .post-cta { grid-template-columns: 1fr; } }
.price-tag { font-size: 0.9rem; color: var(--muted); }
.compare td a { padding-block: 8px; display: inline-block; }

/* Tables stack into cards on phones instead of scrolling sideways */
@media (max-width: 640px) {
  .compare thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .compare table, .compare tbody, .compare tr, .compare td { display: block; width: 100%; }
  .compare tr { padding: 12px 14px; border-bottom: 1px solid var(--line); }
  .compare tr:last-child { border-bottom: 0; }
  .compare td { border: 0; padding: 2px 0; }
  .compare td:first-child { font-weight: 600; }
  .compare td:empty { display: none; }
  .compare td:not(:first-child) { font-size: 0.9rem; color: var(--muted); }
}

/* ---------- tools index: large tabs with subsections ---------- */
html:not(.js) .js-only { display: none; }
.tool-find { display: grid; gap: 6px; max-width: 420px; margin-bottom: 20px; }
.tool-find label { font-weight: 600; font-size: 0.9rem; }
.tool-find input { font: inherit; color: var(--ink); background: #fff; border: 1px solid #8a9298; border-radius: var(--r); padding: 10px 14px; min-height: 46px; width: 100%; }
.tabs-nav { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 32px; }
.tab { display: inline-flex; align-items: center; gap: 8px; min-height: 52px; padding: 10px 18px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); color: var(--ink); font: 600 1.05rem var(--head); text-decoration: none; }
.tab small { font: 500 0.75rem var(--mono); color: var(--muted); }
.tab:hover { border-color: var(--accent); color: var(--ink); }
.tab[aria-current] { background: var(--dark); border-color: var(--dark); color: #fff; }
.tab[aria-current] small { color: var(--accent-on-dark); }
.tab-panels { display: grid; gap: 48px; }
.tab-panel h2 { margin-bottom: 4px; }
.tab-panel > .note { margin-bottom: 20px; }
.sub { margin-top: 24px; }
.sub h3 { font-size: 1rem; color: var(--muted); font-weight: 600; margin-bottom: 10px; }
.tool-grid li[hidden], .sub[hidden], .tab-panel[hidden] { display: none; }
@media (max-width: 560px) { .tab { flex: 1 1 calc(50% - 8px); justify-content: space-between; font-size: 0.95rem; padding: 10px 12px; } }

/* ---------- at a glance facts on tool pages ---------- */
.glance { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 0; margin: 0 0 32px; border-top: 2px solid var(--ink); }
.glance dt, .glance dd { margin: 0; padding: 10px 0; border-bottom: 1px solid var(--line); }
.glance dt { font-weight: 600; padding-right: 24px; }
.glance dd a { padding-block: 10px; }
@media (max-width: 480px) { .glance { grid-template-columns: 1fr; } .glance dt { border: 0; padding-bottom: 0; } .glance dd { padding-top: 2px; } }

/* ---------- pieces used by the newer tools ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr)); gap: 10px; }
.stats > div { background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); padding: 10px 12px; display: grid; gap: 2px; min-width: 0; }
.stats b { font: 700 1.3rem/1.15 var(--head); font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.stats span { font-size: 0.78rem; color: var(--muted); }
.shots { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.shot { display: grid; gap: 6px; justify-items: start; }
.shot img { width: 100%; border-radius: var(--r); border: 1px solid var(--line); }
.swatches { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; }
.swatch { width: 100%; min-height: 72px; border: 1px solid var(--line); border-radius: var(--r); display: grid; gap: 2px; place-content: center; font-size: 0.82rem; cursor: pointer; }
.diff { font: 0.85rem/1.5 var(--mono); border: 1px solid var(--line); border-radius: var(--r); overflow-x: auto; max-height: 520px; overflow-y: auto; }
.diff .d { display: grid; grid-template-columns: 24px 1fr; padding: 0 8px; white-space: pre-wrap; overflow-wrap: anywhere; }
.diff .add { background: #e3f3e6; }
.diff .del { background: #fde8e6; }
.hash { display: block; font-size: 0.78rem; overflow-wrap: anywhere; background: none; padding: 0; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 2px 12px; margin: 8px 0 0; font-size: 0.82rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.warn-text { color: var(--warn); font-weight: 600; }
.list .meta-item { align-items: start; }
pre.code { overflow-x: auto; background: var(--paper-2); padding: 12px 14px; border-radius: var(--r); font-size: 0.85rem; }
pre.code code { background: none; padding: 0; }

/* A section that is both the page wrapper and prose keeps the page's left edge, with a readable line length inside */
.wrap.prose { max-width: none; }
.wrap.prose > * { max-width: 70ch; }

.tool > * { min-width: 0; }
.footer-base a { display: inline-block; padding-block: 12px; color: #e3e8ec; }

.author-box { margin-top: 32px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--r); background: #fff; }
.author-box p { margin: 6px 0 0; font-size: 0.92rem; color: var(--muted); }
.post-meta a { display: inline-block; padding-block: 12px; }

.mini { margin: 0; padding-left: 20px; font-size: 0.95rem; }
.mini li { margin-bottom: 6px; }
.guided .note { margin: 0; }

/* ---------- free apps ---------- */
.free-groups { display: grid; gap: 40px; }
.free-list { list-style: none; margin: 12px 0 0; padding: 0; border-top: 2px solid var(--ink); }
.free-app { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); }
.free-app h3 { margin: 0 0 2px; }
.free-app h3 a { display: inline-block; padding-block: 6px; }
.free-app p { margin: 0; max-width: 62ch; }
@media (max-width: 560px) { .free-app { grid-template-columns: 1fr; } }
.tool-grid a.out strong::after { content: " \2197"; color: var(--muted); font-weight: 400; }

/* ---------- blog post sidebar: the post's tool, then more free tools ---------- */
.post-layout { display: grid; gap: 48px; }
.post-side { display: grid; gap: 28px; align-content: start; }
.side-tool { background: var(--dark); color: var(--paper); padding: 24px; border-radius: var(--r); }
.side-tool .label { color: var(--accent-on-dark); margin-bottom: 8px; }
.side-tool h2 { font-size: 1.3rem; color: var(--paper); margin: 0 0 8px; }
.side-tool p { color: color-mix(in srgb, var(--paper) 78%, var(--dark)); font-size: 0.95rem; margin: 0 0 14px; }
.side-tool ul { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 4px; font-size: 0.9rem; color: color-mix(in srgb, var(--paper) 90%, var(--dark)); }
.side-tool li::before { content: "✓"; color: var(--accent-on-dark); margin-right: 8px; font-weight: 700; }
.side-tool .btn { width: 100%; background: var(--paper); color: var(--ink); border-color: var(--paper); }
.side-tool .btn:hover { background: var(--accent-on-dark); border-color: var(--accent-on-dark); color: var(--ink); }
.side-tools h2 { font-size: 1rem; margin: 0 0 4px; }
.side-tools ul { list-style: none; margin: 0 0 12px; padding: 0; border-top: 2px solid var(--ink); }
.side-tools li a { display: grid; gap: 2px; padding: 12px 0; border-bottom: 1px solid var(--line); color: var(--ink); text-decoration: none; }
.side-tools li strong { font: 600 0.98rem/1.3 var(--head); }
.side-tools li span { color: var(--muted); font-size: 0.85rem; line-height: 1.4; }
.side-tools li a:hover strong { color: var(--accent); }
.side-all { display: inline-block; padding-block: 10px; font-weight: 600; }
@media (min-width: 1024px) {
  .post-layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 56px; }
  .post-side { position: sticky; top: 92px; align-self: start; max-height: calc(100vh - 110px); overflow-y: auto; }
}
@media (max-width: 1023px) { .side-tool { display: none; } }
@media (min-width: 1024px) and (max-height: 860px) { .side-tools li span { display: none; } .side-tool ul { margin-bottom: 14px; } }
.post-tool-inline { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px 16px; align-items: center; margin: 4px 0 28px; padding: 16px 18px; background: var(--dark); color: var(--paper); border-radius: var(--r); }
.post-tool-inline .label { color: var(--accent-on-dark); margin-bottom: 2px; }
.post-tool-inline strong { display: block; font: 600 1.1rem/1.25 var(--head); color: var(--paper); }
.post-tool-inline p { margin: 4px 0 0; font-size: 0.88rem; color: color-mix(in srgb, var(--paper) 78%, var(--dark)); }
.post-tool-inline .btn { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.post-tool-inline .btn:hover { background: var(--accent-on-dark); border-color: var(--accent-on-dark); color: var(--ink); }
@media (max-width: 560px) { .post-tool-inline { grid-template-columns: 1fr; } .post-tool-inline .btn { width: 100%; } }
@media (min-width: 1024px) { .post-tool-inline { display: none; } }
.alt-desk { border: 1px solid var(--line); border-radius: var(--r); padding: 18px 20px; background: var(--paper); display: grid; gap: 6px; }
.alt-desk strong { font: 600 1rem/1.35 var(--head); }
.alt-desk p { margin: 0; color: var(--muted); font-size: 0.9rem; }
.alt-desk a { font-weight: 600; padding-block: 8px; }
.post-shot { margin: 8px 0 28px; }
.post-shot img { width: 100%; height: auto; border-radius: var(--r); border: 1px solid var(--line); box-shadow: 0 8px 28px rgba(19,33,58,.10); }
.post-shot figcaption { margin-top: 8px; font-size: 0.85rem; color: var(--muted); }
.price-box { border: 1px solid var(--line); border-radius: var(--r); padding: 18px 20px; margin: 28px 0; background: var(--paper); }
.price-box ul { margin: 6px 0 8px; }
.price-box .small, .muted.small { font-size: 0.82rem; }
.muted { color: var(--muted); }
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; border: 1px solid var(--line); border-radius: var(--r); }
.price-table { width: 100%; border-collapse: collapse; font-size: 0.95rem; }
.price-table th, .price-table td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.price-table thead th { background: var(--paper-2); font: 600 0.85rem var(--head); }
.price-table td.num { font-family: var(--mono); white-space: nowrap; }
.price-table tbody th { font-weight: 600; }
.change-log { padding-left: 20px; }
.quote-ask { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); }
