/* =====================================================================
   Basira AI: basira.css
   Matches basirahanalytics.com exactly: the fonts, tokens, buttons, header
   and footer are copied from the site's assets/css/styles.css. Libre Caslon
   Display for headings, IBM Plex Sans for text, IBM Plex Mono for labels,
   Archivo for the logo wordmark only. Self-hosted, with size-matched local
   fallback faces so text does not jump when a web font arrives.
   ===================================================================== */
@font-face {
  font-family: "Libre Caslon Display";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/static/fonts/libre-caslon-display-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Libre Caslon Display";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/static/fonts/libre-caslon-display-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 100 700;
  font-display: swap;
  src: url("/static/fonts/ibm-plex-sans-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 100 700;
  font-display: swap;
  src: url("/static/fonts/ibm-plex-sans-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/ibm-plex-mono-500-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("/static/fonts/ibm-plex-mono-500-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/static/fonts/archivo-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/static/fonts/archivo-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Caslon Fallback";
  src: local("Georgia");
  size-adjust: 83.08%;
  ascent-override: 116.75%;
  descent-override: 32.02%;
  line-gap-override: 0.00%;
}
@font-face {
  font-family: "Plex Sans Fallback";
  src: local("Arial");
  size-adjust: 101.26%;
  ascent-override: 101.23%;
  descent-override: 27.16%;
  line-gap-override: 0.00%;
}
@font-face {
  font-family: "Plex Mono Fallback";
  src: local("Courier New");
  size-adjust: 99.98%;
  ascent-override: 102.52%;
  descent-override: 27.50%;
  line-gap-override: 0.00%;
}

/* =====================================================================
   The site's tokens and base, copied from basirahanalytics.com
   (assets/css/styles.css). Light only: no dark-mode switch.
   ===================================================================== */
:root {
  color-scheme: light;
  --paper: #f3f1eb; --paper-2: #e7e4dc; --ink: #11110f; --ink-2: #1a1a17;
  --text: #151513; --muted: #56564f; --line: #cbc7bc; --field: #8d897e;
  --accent: #c62e18; --accent-2: #a92311; --accent-text: #a92311; --accent-bright: #f25c43;
  --night-line: #3a3934; --night-muted: #c3c0b7; --white: #f6f4ef;
  --max: 1420px; --pad: clamp(20px, 4.5vw, 72px);
  --serif: "Libre Caslon Display", "Caslon Fallback", serif;
  --sans: "IBM Plex Sans", "Plex Sans Fallback", sans-serif;
  --mono: "IBM Plex Mono", "Plex Mono Fallback", monospace;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --dur: .2s;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--paper); color: var(--text); font: 400 18px/1.62 var(--sans);
  overflow-x: hidden;
}
main { flex: 1; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3, p, ul, ol, dl, dd, figure, fieldset { margin: 0; }
ul, ol { padding: 0; }
fieldset { padding: 0; min-width: 0; }
svg { display: block; }
[hidden] { display: none !important; }
.wrap { width: min(var(--max), calc(100% - var(--pad) * 2)); margin-inline: auto; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0;
}
.mono, .label { font: 500 13px/1.3 var(--mono); text-transform: uppercase; letter-spacing: .1em; }
.kicker { display: flex; align-items: center; gap: 11px; margin: 0 0 20px; color: var(--muted); }
.kicker::before { content: ""; width: 22px; height: 2px; background: var(--accent); flex: none; }
h1, h2, h3 { font-family: var(--serif); font-weight: 400; letter-spacing: -.04em; text-wrap: balance; }
h1:focus { outline: none; }
.lead { font-size: clamp(18px, 1.7vw, 23px); line-height: 1.55; color: var(--muted); max-width: 64ch; }

/* Focus: the site's ring, dark red on paper and bright red on ink. */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, summary:focus-visible {
  outline: 3px solid var(--accent-text); outline-offset: 4px;
}
.band-dark a:focus-visible, .band-dark button:focus-visible, .band-dark select:focus-visible,
.site-footer a:focus-visible { outline-color: var(--accent-bright); }
.skip-link {
  position: fixed; left: 16px; top: -80px; z-index: 100; padding: 10px 14px;
  background: var(--accent); color: #fff; font-weight: 600;
}
.skip-link:focus { top: 12px; }

/* Links written inside a sentence, and text buttons that act like them. */
.link, .link-btn {
  color: inherit; text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px;
}
.link-btn { display: inline-flex; align-items: center; min-height: 44px; font-size: inherit; }
.link:hover, .link-btn:hover { color: var(--accent-text); }
.band-dark .link:hover, .band-dark .link-btn:hover { color: var(--white); text-decoration-thickness: 2px; }

/* ── Bands ─────────────────────────────────────────────────────────────── */
.band-dark { background: var(--ink); color: var(--white); }
.band-dark .lead, .band-dark p { color: var(--night-muted); }
.band-dark .kicker { color: var(--night-muted); }
.band-light { background: var(--paper); color: var(--text); }

/* ── Buttons: the site's square buttons ────────────────────────────────── */
.btn {
  min-height: 52px; display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  padding: 0 21px; border: 1px solid currentColor; background: transparent;
  font: 600 15px/1.3 var(--sans); text-align: center; cursor: pointer;
  transition: background var(--dur), color var(--dur), border-color var(--dur);
}
.btn svg { width: 16px; height: 16px; transition: transform var(--dur); }
.btn:hover svg { transform: translateX(4px); }
.btn:disabled { opacity: .55; cursor: not-allowed; }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-2); border-color: var(--accent-2); }
.btn-ink { background: var(--ink); border-color: var(--ink); color: var(--white); }
.btn-ink:hover { background: #2b2b26; }
.btn-outline { color: var(--text); }
.btn-outline:hover { background: var(--paper-2); }
.btn-outline-dark { color: var(--white); border-color: var(--night-muted); }
.btn-outline-dark:hover { background: var(--ink-2); border-color: var(--white); }
.reassure { margin: 14px 0 0; font-size: 14px; line-height: 1.5; color: var(--muted); }
.band-dark .reassure { color: var(--night-muted); }

/* ── Header: the site's bar, our logo, the tool's name, one red action ─── */
.site-header {
  position: sticky; top: 0; z-index: 60; border-bottom: 1px solid var(--line);
  background: rgba(243, 241, 235, .94);
  background: color-mix(in srgb, var(--paper) 94%, transparent);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.header-inner { height: 68px; display: flex; align-items: center; gap: 18px; }
.brand {
  flex: none; display: inline-flex; align-items: center; gap: .6rem; min-height: 44px;
  color: var(--text); transition: opacity var(--dur);
}
.brand:hover { opacity: .72; }
.brand-mark { flex: none; width: 30px; height: 30px; }
.brand-text { display: flex; flex-direction: column; line-height: 1; font-family: "Archivo", system-ui, sans-serif; }
.brand-name { font-size: 1.1875rem; font-weight: 900; letter-spacing: -.03em; }
.brand-sub { margin-top: .18em; font-size: .5625rem; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
.brand-dot { fill: #EC3013; }   /* the logo keeps Signal Red exactly */
.tool-name { padding-left: 18px; border-left: 1px solid var(--line); color: var(--muted); }
.header-right { margin-left: auto; display: flex; align-items: center; gap: clamp(18px, 2.2vw, 34px); }
.nav-link { position: relative; min-height: 44px; display: inline-flex; align-items: center; font-size: 14px; font-weight: 500; }
.nav-link::after { content: ""; position: absolute; left: 0; right: 100%; bottom: 3px; height: 2px; background: var(--accent); transition: right var(--dur); }
.nav-link:hover::after { right: 0; }
.btn-header { min-height: 44px; padding: 0 18px; font-size: 14px; }

/* ── Upload: the site's Basira AI page head ────────────────────────────── */
.landing { padding-block: clamp(56px, 8vw, 120px); }
.landing-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(40px, 7vw, 110px); align-items: center; }
.hero-title { font-size: clamp(46px, 6.4vw, 96px); line-height: .94; max-width: 12ch; }
.landing .lead { margin: 26px 0 0; max-width: 40ch; }
.drop {
  padding: clamp(20px, 3vw, 28px); background: var(--ink-2); border: 1px dashed #6d6a60;
  color: var(--white); text-align: center; transition: border-color var(--dur);
}
.drop.is-dragging { border-color: var(--white); border-style: solid; }
.drop-mark { width: 40px; height: 40px; margin: 8px auto 20px; color: var(--night-muted); }
.drop-title { font-size: clamp(30px, 3vw, 42px); line-height: 1.02; color: var(--white); }
.drop .sub { margin-top: 10px; font-size: 17px; }
#drop-empty .btn-primary { margin-top: 24px; }
.drop .limits { margin-top: 20px; font: 500 13px/1.5 var(--mono); letter-spacing: .06em; }
.drop .sample { margin-top: 20px; padding-top: 12px; border-top: 1px solid var(--night-line); font-size: 17px; }
.drop .sample .link-btn, .promise-more .link-btn { color: var(--white); }
.file-list { list-style: none; display: grid; text-align: left; border-top: 1px solid var(--night-line); }
.file-item { display: flex; align-items: center; gap: 12px; padding: 8px 0 8px 2px; border-bottom: 1px solid var(--night-line); }
.file-name { color: var(--white); font-weight: 600; font-size: 16px; overflow-wrap: anywhere; }
.file-size { margin-left: auto; color: var(--night-muted); font: 500 13px/1.3 var(--mono); white-space: nowrap; }
.file-remove { width: 44px; height: 44px; flex: none; color: var(--night-muted); font-size: 22px; line-height: 1; }
.file-remove:hover { color: var(--white); background: var(--night-line); }
.drop-actions { margin-top: 20px; display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.progress { text-align: left; }
.progress-now { color: var(--white) !important; font: 400 clamp(26px, 2.4vw, 32px)/1.1 var(--serif); letter-spacing: -.03em; }
.progress-steps { list-style: none; margin-top: 18px; display: grid; border-top: 1px solid var(--night-line); }
.progress-steps li { display: flex; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--night-line); font-size: 16px; color: var(--night-muted); }
.progress-steps li::before { content: ""; width: 7px; height: 7px; border: 1px solid var(--night-muted); flex: none; }
.progress-steps li.is-done::before { background: var(--night-muted); }
.progress-steps li.is-now { color: var(--white); font-weight: 600; }
.progress-steps li.is-now::before { background: var(--accent-bright); border-color: var(--accent-bright); }
@media (prefers-reduced-motion: no-preference) {
  .progress-steps li.is-now::before { animation: pulse 1.2s var(--ease) infinite alternate; }
  @keyframes pulse { from { opacity: 1; } to { opacity: .35; } }
}
.error-card {
  margin-bottom: 22px; padding: 16px 18px; display: flex; gap: 14px; text-align: left;
  background: var(--ink); border: 1px solid var(--night-line); border-left: 2px solid var(--accent-bright);
}
.error-card .mk { display: none; }
.error-card b { display: block; color: var(--white); font: 400 clamp(22px, 2vw, 26px)/1.15 var(--serif); letter-spacing: -.03em; overflow-wrap: anywhere; }
.error-card p { margin-top: 6px; font-size: 16px; line-height: 1.55; }
.promise { margin-top: 24px; list-style: none; display: grid; border-top: 1px solid var(--night-line); }
.promise li { display: flex; gap: 12px; align-items: baseline; padding: 12px 0; border-bottom: 1px solid var(--night-line); color: var(--night-muted); font-size: 17px; line-height: 1.5; }
.promise li::before { content: ""; width: 7px; height: 7px; background: var(--night-muted); flex: none; transform: translateY(-2px); }
.promise-more { margin-top: 6px; font-size: 17px; }

/* ── Questions and picking: paper, one question at a time ──────────────── */
.step { padding-block: clamp(56px, 8vw, 110px); }
.step-card { max-width: 820px; }
.step .count { color: var(--muted); }
.step h1 { font-size: clamp(38px, 5vw, 68px); line-height: .98; overflow-wrap: anywhere; }
.q-mark { display: none; }
.step .why { margin-top: 20px; font-size: clamp(18px, 1.7vw, 21px); line-height: 1.55; color: var(--muted); max-width: 56ch; }
.choices { margin-top: 32px; display: grid; border-top: 1px solid var(--line); }
.choice {
  display: flex; gap: 18px; align-items: flex-start; width: 100%; min-height: 64px; padding: 18px 8px;
  text-align: left; color: var(--text); border-bottom: 1px solid var(--line); transition: background var(--dur);
}
.choice:hover { background: var(--paper-2); }
.choice-title { display: block; font: 400 clamp(22px, 2vw, 27px)/1.15 var(--serif); letter-spacing: -.03em; }
.choice-sub { display: block; margin-top: 4px; font-size: 16px; line-height: 1.5; color: var(--muted); }
.choice-key {
  flex: none; width: 30px; height: 30px; margin-top: 2px; display: grid; place-items: center;
  border: 1px solid var(--field); font: 500 13px var(--mono); color: var(--muted);
}
.choice:hover .choice-key { border-color: var(--text); color: var(--text); }
.step-foot { margin-top: 26px; display: flex; gap: 10px 24px; flex-wrap: wrap; align-items: center; font-size: 16px; color: var(--muted); }
.step-foot .link-btn { color: var(--text); }
.file-chip {
  display: inline-flex; gap: 8px; align-items: center; min-height: 32px; padding: 4px 10px; margin: 0 6px 6px 0;
  border: 1px solid var(--line); font: 500 13px/1.3 var(--mono); letter-spacing: .04em; color: var(--muted);
}
.file-chip b { color: var(--text); font-weight: 500; }
.pair { margin-top: 26px; display: grid; gap: 12px; }
.pair-row { display: grid; gap: 12px; grid-template-columns: 1fr; }
@media (min-width: 700px) { .pair-row { grid-template-columns: 1fr auto 1fr; align-items: center; } }
.pair-file { padding: 16px 18px; border: 1px solid var(--line); background: var(--white); }
.pair-file b { display: block; font-size: 17px; overflow-wrap: anywhere; }
.pair-file span { font: 500 13px/1.3 var(--mono); letter-spacing: .06em; color: var(--muted); }
.pair-link { text-align: center; font-size: 15px; color: var(--muted); }
.pair-link b { color: var(--text); font-weight: 600; }
.derive-cols { margin-top: 18px; display: flex; gap: 12px; flex-wrap: wrap; align-items: center; font-size: 16px; color: var(--muted); }
.derive-cols label { display: inline-flex; gap: 8px; align-items: center; }
.derive-cols select {
  min-height: 44px; padding: 8px 12px; font: 400 16px/1.4 var(--sans); color: var(--text);
  background: var(--paper); border: 1px solid var(--field); border-radius: 0;
}
.derive-toggle { margin-top: 12px; color: var(--text); }
.pick { border: 0; margin-top: 30px; border-top: 1px solid var(--line); }
.pick-option {
  display: flex; gap: 16px; align-items: center; min-height: 64px; padding: 14px 8px;
  border-bottom: 1px solid var(--line); cursor: pointer; transition: background var(--dur);
}
.pick-option:hover { background: var(--paper-2); }
.pick-option:has(input:checked) { background: var(--white); box-shadow: inset 2px 0 0 var(--text); }
.pick-option input { accent-color: var(--text); width: 20px; height: 20px; flex: none; }
.pick-option b { font: 400 clamp(21px, 1.9vw, 25px)/1.15 var(--serif); letter-spacing: -.03em; overflow-wrap: anywhere; }
.pick-option span { margin-left: auto; font: 500 13px/1.3 var(--mono); letter-spacing: .06em; color: var(--muted); white-space: nowrap; }
.pick-detail { margin-top: 18px; font-size: 17px; color: var(--muted); max-width: 60ch; }
.aside-line { margin-top: 36px; padding-top: 12px; border-top: 1px solid var(--line); font-size: 17px; color: var(--muted); }
.aside-line a { color: var(--text); display: inline-flex; align-items: center; min-height: 44px; }

/* ── Results: the answer first ─────────────────────────────────────────── */
.results { padding-top: clamp(40px, 5vw, 72px); padding-bottom: clamp(56px, 7vw, 100px); }
.res-head { display: flex; flex-wrap: wrap; gap: 8px 32px; align-items: flex-end; justify-content: space-between; }
.res-head h1 { font-size: clamp(36px, 4.4vw, 64px); line-height: .98; max-width: 22ch; }
.res-again { font-size: 16px; color: var(--text); }
.res-meta { margin-top: 12px; font: 500 13px/1.5 var(--mono); letter-spacing: .06em; color: var(--muted); }
.note {
  margin-top: 14px; display: flex; gap: 12px; align-items: baseline; padding: 12px 16px;
  font-size: 16px; line-height: 1.5; background: var(--white); border: 1px solid var(--line);
}
.note::before { content: ""; width: 7px; height: 7px; background: var(--muted); flex: none; transform: translateY(-2px); }
/* Key figures: the site's hairline-divided figures, set in Caslon. */
.kpis { margin-top: 32px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.kpi { min-width: 0; padding: 18px 16px 20px 0; display: flex; flex-direction: column; border-bottom: 1px solid var(--line); }
.kpi:nth-child(2n) { padding-left: 16px; border-left: 1px solid var(--line); }
@media (min-width: 900px) {
  .kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .kpi { border-bottom: 0; padding: 22px 20px 4px 0; }
  .kpi:nth-child(2n) { padding-left: 0; border-left: 0; }
  .kpi + .kpi { padding-left: 20px; border-left: 1px solid var(--line); }
}
.k-label { order: 2; margin-top: 10px; font-size: 15px; line-height: 1.4; color: var(--muted); }
.k-value { order: 1; font: 400 clamp(34px, 3.6vw, 56px)/1 var(--serif); letter-spacing: -.03em; overflow-wrap: anywhere; }
.k-value.is-text { font-size: clamp(26px, 2.6vw, 38px); line-height: 1.05; overflow-wrap: normal; hyphens: auto; }
.k-context { order: 3; margin-top: 6px; font-size: 14px; line-height: 1.4; color: var(--muted); }
.says-head { margin-top: clamp(44px, 5vw, 64px); font-size: clamp(30px, 3vw, 42px); line-height: 1.02; }
.says { margin-top: 18px; list-style: none; border-top: 1px solid var(--line); }
.says li { display: flex; gap: 14px; align-items: baseline; padding: 16px 0; border-bottom: 1px solid var(--line); font-size: 18px; line-height: 1.55; }
.says .mk { width: 7px; height: 7px; background: var(--muted); flex: none; transform: translateY(-2px); }
.says .mk.is-unusual { background: var(--accent); }
.charts { margin-top: 28px; display: grid; gap: 20px; grid-template-columns: minmax(0, 1fr); }
@media (min-width: 1000px) {
  .charts.has-3 { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) minmax(0, 1fr); }
  .charts.has-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .charts-more { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.chart { min-width: 0; padding: 20px 20px 16px; background: var(--paper); border: 1px solid var(--line); }
.chart h3 { font-size: clamp(22px, 1.9vw, 26px); line-height: 1.1; letter-spacing: -.03em; }
.chart .c-sub { margin-top: 6px; font-size: 15px; line-height: 1.45; color: var(--muted); }
.chart .c-plot { margin-top: 14px; min-height: 180px; }
.chart .c-foot { margin-top: 10px; font-size: 14px; line-height: 1.45; color: var(--muted); }

/* More details: the site's hairline list */
.more { margin-top: clamp(44px, 5vw, 64px); border-top: 1px solid var(--line); }
.more-item { border-bottom: 1px solid var(--line); }
.more-h { font: inherit; letter-spacing: normal; }
.more-row { display: flex; align-items: center; gap: 18px; width: 100%; min-height: 64px; padding: 16px 4px; text-align: left; color: var(--text); }
.more-row:hover .more-name { color: var(--accent-text); }
.more-name { font: 400 clamp(22px, 2vw, 28px)/1.12 var(--serif); letter-spacing: -.03em; white-space: nowrap; transition: color var(--dur); }
.more-row .desc { font-size: 16px; color: var(--muted); }
.more-row .chev {
  margin-left: auto; width: 10px; height: 10px; flex: none; border-right: 1.5px solid var(--text); border-bottom: 1.5px solid var(--text);
  transform: rotate(45deg) translateY(-3px); transition: transform var(--dur) var(--ease);
}
.more-row[aria-expanded="true"] .chev { transform: rotate(-135deg) translateY(-2px); }
.more-panel { padding: 4px 4px 28px; }
.panel-note { margin-top: 12px; font-size: 16px; color: var(--muted); }
.panel-h { margin: 22px 0 10px; font: 500 13px/1.3 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.panel-h:first-child { margin-top: 4px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  min-height: 44px; padding: 0 16px; display: inline-flex; align-items: center;
  font-size: 15px; font-weight: 500; color: var(--text); border: 1px solid var(--field);
  transition: background var(--dur), color var(--dur), border-color var(--dur);
}
.chip:hover { background: var(--paper-2); }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--white); border-color: var(--ink); }
.chip.is-loading { opacity: .6; }
.filter-group { margin-top: 14px; }
.filter-group:first-child { margin-top: 4px; }
.filter-label { display: block; margin-bottom: 8px; font-size: 15px; font-weight: 600; }
#clear-filters-btn { margin-top: 16px; }
.ask { margin-top: 18px; }
.ask-label { display: block; margin-bottom: 8px; font-size: 15px; font-weight: 600; }
.ask-row { display: flex; gap: 10px; flex-wrap: wrap; }
.ask-row input {
  flex: 1 1 16rem; min-width: 0; min-height: 52px; padding: 12px 14px; font: 400 16px/1.4 var(--sans);
  color: var(--text); background: var(--paper); border: 1px solid var(--field); border-radius: 0;
}
.ask-row input::placeholder { color: var(--muted); }
.ask-row input:focus-visible { outline-offset: 2px; }
.charts-more { margin-top: 20px; }
.check-list { list-style: none; display: grid; border-top: 1px solid var(--line); }
.check-item { padding: 16px 0; border-bottom: 1px solid var(--line); }
.check-item b { font-weight: 600; }
.check-item .how { margin-top: 4px; font-size: 16px; color: var(--muted); }
details.query { margin-top: 8px; }
details.query summary { width: fit-content; min-height: 44px; display: flex; align-items: center; cursor: pointer; font-size: 15px; font-weight: 600; }
pre.sql {
  margin: 6px 0 0; padding: 14px 16px; background: var(--paper-2); border: 1px solid var(--line);
  font: 13px/1.6 var(--mono); color: var(--text); white-space: pre-wrap; overflow-wrap: anywhere;
}
.table-wrap { overflow-x: auto; border: 1px solid var(--line); }
table.data { width: 100%; border-collapse: collapse; font-size: 15px; }
table.data th, table.data td { text-align: left; padding: 10px 14px; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.data th { font: 500 12px/1.3 var(--mono); letter-spacing: .08em; text-transform: uppercase; color: var(--muted); background: var(--paper-2); }
table.data tr:last-child td { border-bottom: 0; }
.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.stat { padding: 14px 16px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.stat-label { font-size: 14px; color: var(--muted); }
.stat-value { font: 400 26px/1.1 var(--serif); letter-spacing: -.03em; }
.notes-list { list-style: none; display: grid; gap: 8px; }
.notes-list li { display: flex; gap: 12px; align-items: baseline; font-size: 17px; }
.notes-list li::before { content: ""; width: 7px; height: 7px; background: var(--muted); flex: none; transform: translateY(-2px); }
.toggle-group { display: inline-flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.download-row { display: flex; gap: 10px; flex-wrap: wrap; }

/* Closing band: the site's route-cta */
.cta { padding-block: clamp(70px, 9vw, 126px); }
.cta-inner { display: grid; grid-template-columns: 1.3fr .7fr; gap: clamp(38px, 8vw, 120px); align-items: end; }
.cta h2 { font-size: clamp(44px, 6vw, 88px); line-height: .94; }
.cta p { margin: 0 0 25px; font-size: 18px; line-height: 1.62; }
.cta p.reassure { margin: 14px 0 0; font-size: 14px; line-height: 1.5; }

/* ── Footer: the site's footer ─────────────────────────────────────────── */
.site-footer { background: var(--ink); color: var(--night-muted); border-top: 1px solid var(--night-line); padding-top: clamp(56px, 7vw, 96px); }
.site-footer .brand { color: var(--white); }
.site-footer .brand-sub { color: var(--night-muted); }
.foot-grid { display: grid; grid-template-columns: 1.5fr repeat(4, minmax(0, 1fr)); gap: 40px clamp(24px, 3vw, 48px); }
.foot-brand .brand-mark { width: 38px; height: 38px; }
.foot-brand .brand-name { font-size: 1.4375rem; }
.foot-brand .brand-sub { font-size: .625rem; }
.foot-tagline { margin: 22px 0 0; max-width: 18ch; font: 400 clamp(26px, 2.4vw, 34px)/1.08 var(--serif); letter-spacing: -.03em; color: var(--white); }
.foot-h { margin: 0 0 12px; color: var(--night-muted); }
.foot-h::before { content: ""; display: inline-block; width: 18px; height: 2px; margin-right: 10px; vertical-align: middle; background: var(--accent); }
.foot-col ul { margin: 0; padding: 0; list-style: none; }
.foot-col li { font-size: 16px; }
.foot-col li a, .foot-col li span { display: inline-flex; align-items: center; min-height: 44px; color: var(--night-muted); overflow-wrap: anywhere; }
.foot-col li a { text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; transition: color var(--dur), text-decoration-color var(--dur); }
.foot-col li a:hover { color: var(--white); text-decoration-color: currentColor; }
.foot-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: clamp(40px, 5vw, 64px); padding: 22px 0 28px; border-top: 1px solid var(--night-line); }
.foot-base p { margin: 0; font: 500 14px/1.4 var(--mono); letter-spacing: .1em; text-transform: uppercase; color: var(--night-muted); }
.foot-base .foot-claim { max-width: 60ch; font: 400 15px/1.5 var(--sans); letter-spacing: 0; text-transform: none; }

/* ── Dialog ────────────────────────────────────────────────────────────── */
.dialog {
  margin: auto; width: 100%; max-width: min(42rem, calc(100vw - 2rem)); padding: 0;
  background: var(--paper); color: var(--text); border: 1px solid var(--line); border-radius: 0;
}
.dialog::backdrop { background: rgba(17, 17, 15, .72); }
.dialog-inner { padding: clamp(22px, 4vw, 36px); }
.dialog h2 { margin-bottom: 18px; font-size: clamp(30px, 3vw, 42px); line-height: 1.02; }
.dialog p { margin-top: 12px; font-size: 16px; line-height: 1.6; }
.dialog-actions { margin-top: 26px; display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; }
.dialog-actions .link { display: inline-flex; align-items: center; min-height: 44px; }
body.is-locked { overflow: hidden; }

/* ── Smaller screens ───────────────────────────────────────────────────── */
@media (max-width: 1100px) { .foot-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .foot-brand { grid-column: 1 / -1; } }
@media (max-width: 980px) {
  .landing-grid, .cta-inner { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  .tool-name, .header-right .nav-link { display: none; }
  .header-inner { gap: 10px; }
}
@media (max-width: 640px) {
  .more-row { flex-wrap: wrap; row-gap: 2px; }
  .more-row .desc { order: 3; width: 100%; }
  .more-name { white-space: normal; }
}
@media (max-width: 520px) {
  :root { --pad: 18px; }
  .foot-grid { grid-template-columns: 1fr; gap: 32px; }
  #drop-empty .btn-primary, .drop-actions .btn, .cta .btn { width: 100%; }
}
@media (max-width: 420px) {
  .btn-header { max-width: 132px; min-height: 44px; padding: 5px 10px; font-size: 12.5px; line-height: 1.15; }
  .brand-text .brand-name { font-size: 1.0625rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
