/* ml0x design system — extracted from the live v6 homepage, 2026-07-27.
   Single source of truth for every page. Light surface, hairline grids, mono display type.
   Contrast: every text token below clears WCAG AA 4.5:1 on --bg or --surface.
   The homepage comp used #BBB/#CCC for small text (1.6-1.9:1). Those are deliberately
   NOT reproduced here; --ink-faint replaces them. */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=JetBrains+Mono:wght@400;500;700&display=swap');

:root {
  --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --bg: #FAFAF9;
  --surface: #FFFFFF;
  --surface-2: #F2F2F0;
  --surface-dark: #111111;

  --ink: #1A1A1A;          /* 15.9:1 on --bg */
  --ink-2: #4A4A4A;        /* 8.4:1  */
  --ink-muted: #6a6a6a;    /* 5.3:1  */
  --ink-faint: #6E6E6E;    /* 4.88:1 on --bg, 5.10 on --surface, 4.55 on --surface-2.
                              Measured, not assumed: #767676 only reaches 4.35 on --bg. */
  --on-dark: #E8E8E8;
  --on-dark-muted: #8a8a8a;

  --line: #E8E8E6;
  --line-strong: #D8D8D6;

  --ok: #157F3B;
  --warn: #B45309;
  --bad: #C53030;

  /* categorical series for canvas + charts, all >=3:1 on --surface */
  --s1: #2563EB;
  --s2: #C53030;
  --s3: #157F3B;
  --s4: #B45309;
  --s5: #7C3AED;
  --s6: #0E7490;

  --radius: 12px;
  --radius-sm: 8px;
  --radius-pill: 980px;
  --wrap: 1080px;
  --pad-x: 40px;
  --shadow: 0 40px 100px rgba(0, 0, 0, 0.08);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}
img, svg, canvas, video { max-width: 100%; }
img, svg { height: auto; }
a { color: var(--ink); text-decoration: none; }
a:hover { color: var(--ink-muted); }
::selection { background: rgba(0, 0, 0, 0.08); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 4px; }
hr { border: 0; border-top: 1px solid var(--line); margin: 32px 0; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--ink); color: #fff; padding: 10px 16px;
  border-radius: 0 0 6px 0; font-size: 14px;
}
.skip-link:focus { left: 0; }

/* ---------------------------------------------------------------- nav */
.site-nav, body > header, header.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(250, 250, 249, 0.88);
  backdrop-filter: blur(20px) saturate(1.8);
  -webkit-backdrop-filter: blur(20px) saturate(1.8);
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  padding: 0;
}
.site-nav__inner {
  height: 52px; max-width: none; margin: 0;
  padding: 0 var(--pad-x);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.site-nav__left { display: flex; align-items: center; gap: 40px; min-width: 0; }
.site-nav__logo, .logo {
  font-family: var(--font-mono); font-weight: 700; font-size: 15px;
  color: var(--ink); letter-spacing: -0.5px; text-decoration: none;
}
.site-nav .site-nav__links, .site-nav > nav, .site-nav__left > nav {
  display: flex; gap: 28px; align-items: center; flex-wrap: wrap;
}
.site-nav .site-nav__links a, .site-nav > nav a, .site-nav__left > nav a {
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  color: var(--ink-muted); text-decoration: none; transition: color 0.2s;
  padding: 4px 0;
}
.site-nav .site-nav__links a:hover, .site-nav__left > nav a:hover { color: var(--ink); }
.site-nav .site-nav__links a[aria-current="page"] { color: var(--ink); }
.nav-cta, .site-nav__cta {
  font-family: var(--font-body); font-size: 13px; font-weight: 500;
  color: #fff; background: var(--ink); padding: 7px 18px;
  border-radius: var(--radius-pill); text-decoration: none;
  transition: background 0.2s; white-space: nowrap;
}
.nav-cta:hover, .site-nav__cta:hover { background: #333; color: #fff; }

/* ------------------------------------------------------------ layout */
.wrap, .container { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--pad-x); width: 100%; }
.section { padding: 72px var(--pad-x); }
.section > .wrap, .section > .container { padding: 0; }
main { display: block; }

.breadcrumb {
  font-family: var(--font-mono); font-size: 12px; color: var(--ink-faint);
  padding: 24px 0 0; margin: 0;
}
.breadcrumb a { color: var(--ink-faint); text-decoration: none; }
.breadcrumb a:hover { color: var(--ink); text-decoration: underline; }
.breadcrumb span, .breadcrumb .sep { color: var(--line-strong); margin: 0 6px; }

/* --------------------------------------------------------- page head */
.page-head, .hero { padding: 48px 0 32px; }
h1, .page-head h1, .hero h1 {
  font-family: var(--font-mono); font-weight: 700;
  font-size: clamp(28px, 3.5vw, 40px); line-height: 1.15; letter-spacing: -1.5px;
  color: var(--ink); margin: 0 0 14px;
  /* legacy dark pages painted h1 with a clipped gradient; unset it */
  background: none; -webkit-text-fill-color: currentColor;
}
h1 span { color: var(--ink); }
.page-head p, .hero p, .lede, .subhead {
  font-family: var(--font-body); font-size: 16px; color: var(--ink-muted);
  margin: 0; max-width: 62ch; line-height: 1.65;
}
h2 {
  font-family: var(--font-mono); font-weight: 700;
  font-size: clamp(22px, 2.4vw, 28px); line-height: 1.2; letter-spacing: -1px;
  color: var(--ink); margin: 48px 0 12px;
}
h3 {
  font-family: var(--font-body); font-weight: 600; font-size: 17px;
  color: var(--ink); margin: 28px 0 8px; letter-spacing: -0.2px;
}
h4 { font-family: var(--font-body); font-weight: 600; font-size: 15px; color: var(--ink); margin: 20px 0 6px; }
p { color: var(--ink-2); margin: 0 0 16px; }
strong, b { color: var(--ink); font-weight: 600; }
ul, ol { color: var(--ink-2); margin: 0 0 16px; padding-left: 22px; }
li { margin-bottom: 6px; }
small { font-size: 12px; color: var(--ink-faint); }

.eyebrow, .kicker {
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--ink-muted); text-transform: uppercase; letter-spacing: 1px;
  margin: 0 0 6px;
}

/* --------------------------------------------------------- text body */
.explainer-section, .prose { max-width: 760px; margin: 0 auto; padding: 8px 0; }
.explainer-section h2, .prose h2 { color: var(--ink); }
.explainer-section h3, .prose h3 { color: var(--ink); }
.explainer-section p, .prose p { color: var(--ink-2); }
.explainer-section ul, .explainer-section ol, .prose ul, .prose ol { color: var(--ink-2); }

pre, .explainer-section pre, .prose pre {
  background: var(--surface-dark); color: var(--on-dark);
  border: 0; border-radius: var(--radius);
  padding: 20px 22px; overflow-x: auto;
  font-family: var(--font-mono); font-size: 13px; line-height: 1.8;
  margin: 0 0 20px;
}
pre code { background: none; color: inherit; padding: 0; font-size: inherit; }
code, .explainer-section code {
  font-family: var(--font-mono); font-size: 0.9em;
  background: var(--surface-2); color: var(--ink);
  padding: 2px 6px; border-radius: 4px;
}

/* ------------------------------------------------------------- cards */
.card, .tool-card, .panel {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 24px; margin: 20px 0;
  box-shadow: none;
}
.card h2, .tool-card h2, .panel h2 { margin-top: 0; }
.card h3, .tool-card h3, .panel h3 {
  font-family: var(--font-mono); font-size: 12px; font-weight: 500;
  color: var(--ink); text-transform: uppercase; letter-spacing: 1px;
  margin: 0 0 16px; padding: 0; border: 0;
}

/* signature hairline grid: 1px gap over --line, children on --surface */
.hairline-grid {
  display: grid; gap: 1px; background: var(--line);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  margin: 24px 0;
}
.hairline-grid > * { background: var(--surface); padding: 24px; margin: 0; }
.cols-2 { grid-template-columns: repeat(2, 1fr); }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cols-4 { grid-template-columns: repeat(4, 1fr); }

.card-grid, .tool-grid, .grid-2, .grid-3 {
  display: grid; gap: 20px; margin: 24px 0;
}
.card-grid, .grid-2, .tool-grid { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.card-grid > .card, .tool-grid > .card { margin: 0; }

.link-card {
  display: block; background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; text-decoration: none;
  transition: border-color 0.2s, background 0.2s;
}
.link-card:hover { border-color: var(--line-strong); background: var(--surface-2); }
.link-card__title {
  font-family: var(--font-mono); font-size: 14px; font-weight: 700;
  color: var(--ink); margin-bottom: 6px;
}
.link-card__desc { font-family: var(--font-body); font-size: 13px; color: var(--ink-muted); line-height: 1.5; }

/* ------------------------------------------------------------- forms */
label, .control-group label, .param-group label, .input-group label {
  display: block; font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.8px;
  margin-bottom: 6px;
}
input[type="text"], input[type="number"], input[type="email"], select, textarea,
.control-group select, .control-group input, .param-group select, .param-group input {
  width: 100%; min-height: 44px;
  background: var(--surface); border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm); color: var(--ink);
  font-family: var(--font-body); font-size: 16px; /* 16px keeps iOS from zooming */
  padding: 10px 12px; transition: border-color 0.15s, box-shadow 0.15s;
  font-variant-numeric: tabular-nums;
}
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(26, 26, 26, 0.08);
}
select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%236a6a6a' d='M0 0l5 6 5-6z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
  padding-right: 34px;
}
.control-row, .flex-row, .control-bar {
  display: flex; gap: 16px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 16px;
}
.control-group, .param-group, .input-group { display: flex; flex-direction: column; margin-bottom: 16px; min-width: 0; }
.slider-group, .slider-container { flex: 1; min-width: 200px; }
.slider-container { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.slider-container input[type="range"] { flex: 1 1 140px; width: auto; }

input[type="range"] {
  width: 100%; appearance: none; -webkit-appearance: none;
  /* inside .slider-container (a flex row) width:100% forces the value readout onto its
     own line, so shrink there instead */
  height: 6px; background: var(--line-strong); border-radius: 3px; outline: none;
  padding: 0; min-height: 0; border: 0;
}
input[type="range"]::-webkit-slider-thumb {
  appearance: none; -webkit-appearance: none;
  width: 22px; height: 22px; background: var(--ink);
  border: 2px solid var(--surface); border-radius: 50%; cursor: pointer;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
}
input[type="range"]::-moz-range-thumb {
  width: 22px; height: 22px; background: var(--ink);
  border: 2px solid var(--surface); border-radius: 50%; cursor: pointer;
}
input[type="checkbox"], input[type="radio"] {
  width: 20px; height: 20px; min-height: 0; accent-color: var(--ink); margin: 0 8px 0 0;
}
.slider-value, .value-readout {
  font-family: var(--font-mono); font-size: 13px; font-weight: 500;
  color: var(--ink); font-variant-numeric: tabular-nums; min-width: 3ch;
}

.btn, button, .btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 11px 22px;
  background: var(--ink); color: #fff; border: 1px solid var(--ink);
  border-radius: var(--radius-pill);
  font-family: var(--font-body); font-size: 14px; font-weight: 500;
  cursor: pointer; transition: background 0.2s, border-color 0.2s;
  text-decoration: none; box-shadow: none;
}
.btn:hover, button:hover, .btn-primary:hover { background: #333; border-color: #333; color: #fff; transform: none; }
.btn-secondary, .btn-outline, .btn-ghost {
  background: var(--surface); color: var(--ink); border: 1px solid var(--line-strong);
}
.btn-secondary:hover, .btn-outline:hover, .btn-ghost:hover { background: var(--surface-2); color: var(--ink); border-color: var(--ink); }
.btn:disabled, button:disabled { opacity: 0.45; cursor: not-allowed; }

/* -------------------------------------------------------------- data */
/* auto-fit grid: the last row is often partly empty, so the hairlines are drawn
   as rings on the cells themselves rather than as a gap over a grey container.
   An empty track then stays white instead of showing a grey block. */
.stat-grid, .stats-grid, .metrics-grid, .result-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  margin: 24px 0;
}
.stat-card, .stat, .metric-card, .stat-box, .stat-item {
  background: var(--surface); border: 0; border-radius: 0;
  padding: 20px; text-align: left;
  box-shadow: 0 0 0 1px var(--line);
}
.stat-card .label, .stat-card .stat-label, .stat .label, .metric-card .label {
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.8px;
  margin: 0 0 6px; order: -1;
}
.stat-card .value, .stat-card .stat-value, .stat .value, .metric-card .value {
  font-family: var(--font-mono); font-size: 24px; font-weight: 700;
  color: var(--ink); letter-spacing: -0.5px; font-variant-numeric: tabular-nums;
  line-height: 1.2;
}
.stat-card .value.pos, .value.good { color: var(--ok); }
.stat-card .value.neg, .value.bad { color: var(--bad); }
.stat-card .value.warn, .value.warn { color: var(--warn); }

table { width: 100%; border-collapse: collapse; font-family: var(--font-body); font-size: 14px; }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); margin: 24px 0; }
.table-scroll > table { border: 0; }
th {
  text-align: left; padding: 13px 18px;
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.5px;
  background: var(--surface-2); border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
td {
  padding: 13px 18px; color: var(--ink-2);
  border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums;
}
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--surface-2); }
caption { caption-side: bottom; padding: 12px 18px; font-size: 12px; color: var(--ink-faint); text-align: left; }

.badge, .tag, .chip {
  display: inline-block; font-family: var(--font-mono); font-size: 11px;
  color: var(--ink-muted); border: 1px solid var(--line);
  padding: 4px 12px; border-radius: var(--radius-pill); background: var(--surface);
  text-decoration: none;
}
.badge:hover, .tag:hover, .chip:hover { border-color: var(--line-strong); color: var(--ink); }
.note, .callout, .info-box {
  background: var(--surface-2); border: 1px solid var(--line);
  border-left: 3px solid var(--ink); border-radius: var(--radius-sm);
  padding: 16px 20px; margin: 24px 0; color: var(--ink-2); font-size: 14px;
}
.note p:last-child, .callout p:last-child { margin-bottom: 0; }

/* ------------------------------------------------------------ canvas */
.canvas-wrap, .chart-wrap, .viz-wrap {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px; margin: 20px 0;
  overflow-x: auto;
}
canvas { display: block; max-width: 100%; background: var(--surface); border-radius: var(--radius-sm); }

.legend { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 12px 0 0; }
.legend-item { display: inline-flex; align-items: center; gap: 7px; font-family: var(--font-mono); font-size: 11px; color: var(--ink-muted); }
.legend-swatch { width: 10px; height: 10px; border-radius: 2px; flex: 0 0 auto; }

/* ------------------------------------------------------------ footer */
.site-footer, body > footer {
  background: var(--surface-dark); padding: 28px var(--pad-x); margin-top: 96px;
  border: 0;
}
.footer-links-seo {
  max-width: var(--wrap); margin: 0 auto 20px; padding: 0 0 20px;
  display: flex; flex-wrap: wrap; gap: 8px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.footer-links-seo a {
  font-family: var(--font-body); font-size: 12px; color: var(--on-dark-muted);
  text-decoration: none; transition: color 0.2s; padding: 3px 0;
}
.footer-links-seo a:hover { color: #ccc; }
.site-footer__inner {
  max-width: var(--wrap); margin: 0 auto;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.site-footer__brand { display: flex; align-items: center; gap: 12px; }
.site-footer__logo { font-family: var(--font-mono); font-weight: 700; font-size: 13px; color: var(--on-dark-muted); }
.site-footer__meta, .site-footer p { font-family: var(--font-body); font-size: 11px; color: var(--on-dark-muted); margin: 0; }
.site-footer a { color: var(--on-dark-muted); text-decoration: none; }
.site-footer a:hover { color: #ccc; }
.site-footer__links { display: flex; gap: 20px; }
.site-footer__links a { font-family: var(--font-body); font-size: 11px; }

/* ------------------------------------------- legacy class vocabulary
   The 58 pre-redesign pages carry these names in their markup. Mapping them
   here means the markup does not have to be rewritten to pick up the system. */
.header-inner {
  height: 52px; max-width: none; margin: 0; padding: 0 var(--pad-x);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
}
.nav-right { display: flex; align-items: center; gap: 16px; margin-left: auto; }
.section-title {
  font-family: var(--font-mono); font-weight: 700; font-size: clamp(20px, 2.2vw, 26px);
  letter-spacing: -0.8px; color: var(--ink); margin: 44px 0 12px;
}
.sub-title, .subtitle {
  font-family: var(--font-body); font-size: 16px; color: var(--ink-muted);
  margin: 0 0 20px; max-width: 62ch;
}
.metric-label, .stat-item .label {
  font-family: var(--font-mono); font-size: 11px; font-weight: 500;
  color: var(--ink-muted); text-transform: uppercase; letter-spacing: 0.8px;
}
.metric-value, .stat-item .value {
  font-family: var(--font-mono); font-size: 22px; font-weight: 700; color: var(--ink);
  letter-spacing: -0.5px; font-variant-numeric: tabular-nums;
}
.stat-item { background: var(--surface); padding: 18px; }
.input-hint, .hint, .help-text {
  font-family: var(--font-body); font-size: 12px; color: var(--ink-faint);
  margin-top: 5px; text-transform: none; letter-spacing: 0;
}
.form-group { display: flex; flex-direction: column; margin-bottom: 16px; }
.param-tag {
  display: inline-block; font-family: var(--font-mono); font-size: 11px;
  color: var(--ink-muted); background: var(--surface-2); border: 1px solid var(--line);
  padding: 3px 9px; border-radius: 5px; margin: 0 6px 6px 0;
}
.results-box, .output-box, .result-box, .tool-output, .code-out {
  background: var(--surface-2); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; margin: 20px 0;
  overflow-x: auto; color: var(--ink-2);
}
.viz-container {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); margin: 20px 0; overflow: hidden; padding: 12px;
}
.viz-container canvas { display: block; width: 100%; }
.related-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px; margin: 16px 0;
}
.related-card {
  display: block; padding: 18px; background: var(--surface);
  border: 1px solid var(--line); border-radius: var(--radius);
  color: var(--ink); transition: border-color 0.2s, background 0.2s;
}
.related-card:hover { border-color: var(--line-strong); background: var(--surface-2); text-decoration: none; }
.related-card .related-title { font-family: var(--font-mono); font-size: 13px; font-weight: 700; color: var(--ink); margin-bottom: 5px; }
.related-card .related-desc { font-size: 13px; color: var(--ink-muted); line-height: 1.5; }
.algo-card, .use-card, .method-card {
  background: var(--surface); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 20px; margin: 0;
}
.algo-type, .when-to-use, .complexity, .params {
  font-family: var(--font-mono); font-size: 12px; color: var(--ink-muted);
}
.faq-section { max-width: 760px; margin: 40px auto 0; }
details { border-bottom: 1px solid var(--line); padding: 16px 0; }
details:first-of-type { border-top: 1px solid var(--line); }
summary {
  font-weight: 600; color: var(--ink); cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  min-height: 32px;
}
summary::-webkit-details-marker { display: none; }
summary::after { content: '+'; color: var(--ink-muted); font-family: var(--font-mono); font-size: 18px; }
details[open] summary::after { content: '\2212'; }
details p { color: var(--ink-2); padding-top: 10px; margin-bottom: 0; }
.last-updated { font-family: var(--font-mono); font-size: 12px; color: var(--ink-faint); margin: 24px auto; max-width: 760px; }
.data-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.data-table th { color: var(--ink-muted); border-bottom: 1px solid var(--line); }
.data-table td { border-bottom: 1px solid var(--line); }
.badge-green { background: rgba(21, 127, 59, 0.10); color: var(--ok); border-color: rgba(21, 127, 59, 0.25); }
.badge-blue { background: rgba(37, 99, 235, 0.10); color: var(--s1); border-color: rgba(37, 99, 235, 0.25); }
.badge-orange { background: rgba(180, 83, 9, 0.10); color: var(--warn); border-color: rgba(180, 83, 9, 0.25); }
.badge-red { background: rgba(197, 48, 48, 0.10); color: var(--bad); border-color: rgba(197, 48, 48, 0.25); }
.checklist { list-style: none; padding: 0; }
.checklist li {
  padding: 13px 16px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  margin-bottom: 8px; display: flex; align-items: center; gap: 12px;
  cursor: pointer; background: var(--surface); transition: background 0.15s;
}
.checklist li:hover { background: var(--surface-2); }
.checklist li.checked { opacity: 0.55; }
.check-icon { font-size: 18px; flex-shrink: 0; color: var(--ok); }
.blog-list { list-style: none; padding: 0; }
.blog-list li { border-bottom: 1px solid var(--line); padding: 20px 0; }
.blog-list h3 { margin: 0 0 6px; }
.blog-list .meta { color: var(--ink-faint); font-size: 13px; }

/* --------------------------------- legacy chrome, V14 footer + network */
.site-footer {
  background: #111111;
  border-top: 0;
  margin-top: 96px;
}
/* the legacy centred footer supplies its own padding via .footer-inner; only zero the
   outer padding when that markup is actually present */
.site-footer:has(> .footer-inner) { padding: 0; }
.footer-inner {
  max-width: 620px;
  margin: 0 auto;
  padding: 44px 32px 28px;
  text-align: center;
  flex-direction: column;
  display: block;
}
.footer-brand {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: #E8E8E8;
  letter-spacing: -0.3px;
}
.footer-tagline {
  font-size: 13px;
  color: #8a8a8a;
  margin: 5px 0 22px;
}
.footer-cta {
  display: inline-block;
  min-height: 44px;
  padding: 12px 26px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 980px;
  color: #E8E8E8;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s;
}
.footer-cta:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff;
  text-decoration: none;
}
.footer-copy {
  font-size: 11px;
  color: #8a8a8a;
  margin-top: 20px;
}
.footer-copy a { color: inherit; text-decoration: none; }
.footer-copy a:hover { text-decoration: underline; color: #ccc; }

.zovo-network {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 28px 32px 40px;
  text-align: center;
}
.zovo-network-inner { max-width: 720px; margin: 0 auto; }
.zovo-network-title {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  color: #C4C4C4;
  text-transform: none;
  letter-spacing: 0;
  margin-bottom: 14px;
}
.zovo-network-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 20px;
}
.zovo-network-links a {
  font-size: 12px;
  color: #8a8a8a;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s;
  line-height: 1.9;
}
.zovo-network-links a:hover { color: #ccc; }

/* PoW builder identity strip */
.pow-strip {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 12px 32px;
  text-align: center;
}
.pow-strip-inner {
  max-width: 720px; margin: 0 auto;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 4px 18px;
}
.pow-label { font-size: 11px; color: #8a8a8a; font-weight: 600; }
.pow-strip-inner a { font-size: 11px; color: #8a8a8a; text-decoration: none; }
.pow-strip-inner a:hover { color: #ccc; }

/* ------------------------------------------------------------- nav V5 */
.nav-pro {
  background: #1A1A1A;
  color: #fff !important;
  padding: 8px 16px;
  border-radius: 980px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.2s;
  white-space: nowrap;
}
.nav-pro:hover { background: #333; opacity: 1; }
.nav-zovo {
  color: #6a6a6a !important;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  white-space: nowrap;
}
.nav-zovo:hover { color: #1A1A1A !important; }

/* --------------------------------------------------------- pro nudge */
.pro-nudge {
  margin-top: 24px;
  padding: 16px 20px;
  background: #F2F2F0;
  border: 1px solid #E8E8E6;
  border-left: 3px solid #1A1A1A;
  border-radius: 8px;
}
.pro-nudge-inner { display: flex; align-items: flex-start; gap: 12px; }
.pro-nudge-icon { font-size: 17px; flex-shrink: 0; line-height: 1.4; }
.pro-nudge-text { font-size: 14px; color: #4A4A4A; line-height: 1.6; }
.pro-nudge-text strong { color: #1A1A1A; }
.pro-nudge-text a { color: #1A1A1A; font-weight: 600; text-decoration: underline; }

/* ------------------------------------------- mobile overflow guards */
pre, code, samp, kbd { overflow-x: auto; max-width: 100%; }
.output-box, .result-box, .tool-output, .code-block { overflow-x: auto; max-width: 100%; }
main, .tool-container, .research-content, .article-content { max-width: 100%; }

@media (max-width: 767px) {
  body { overflow-x: hidden; }
  .footer-inner { padding: 34px 20px 20px; }
  .zovo-network { padding: 22px 20px 32px; }
  .zovo-network-links { gap: 4px 14px; }
  .zovo-network-links a { font-size: 11px; }
  pre, code, samp { overflow-x: auto; max-width: 100%; }
  table { font-size: 13px; }
  .output-box, .result-box, .tool-output { font-size: 13px; overflow-wrap: break-word; }
}

/* ------------------------------------------------------- responsive */
@media (max-width: 1023px) {
  .cols-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3, .cols-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
  :root { --pad-x: 20px; }
  body { font-size: 15px; }
  /* must match the base rule's specificity or higher, or the nav never collapses */
  .site-nav .site-nav__links, .site-nav > nav, .site-nav__left > nav { display: none; }
  .site-nav__inner { padding: 0 20px; }
  .nav-cta { padding: 12px 16px; }
  .section { padding: 48px 20px; }
  .page-head, .hero { padding: 32px 0 24px; }
  h1, .page-head h1, .hero h1 { font-size: 30px; letter-spacing: -1.2px; }
  h2 { font-size: 22px; letter-spacing: -0.7px; margin-top: 36px; }
  .cols-2, .cols-3, .cols-4, .card-grid, .tool-grid, .grid-2, .grid-3 { grid-template-columns: 1fr; }
  .stat-grid, .stats-grid, .metrics-grid, .result-grid { grid-template-columns: repeat(2, 1fr); }
  .control-row, .flex-row, .control-bar { flex-direction: column; align-items: stretch; gap: 12px; }
  .slider-group, .slider-container { min-width: 0; }
  .card, .tool-card, .panel { padding: 18px; }
  .hairline-grid > * { padding: 18px; }
  .site-footer__inner { flex-direction: column; align-items: flex-start; }
  pre { padding: 16px; font-size: 12px; }
  th, td { padding: 11px 14px; }
  .btn, button { width: 100%; }
  .btn-inline { width: auto; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
@media print {
  .site-nav, .site-footer { display: none; }
  body { background: #fff; }
}
