/* Colour, type and radius values from the AmayaBrowser design system (tokens.json). */
:root {
  --surface-window: #ebe8e1; --surface-page: #f9f7f2; --surface-raised: #ffffff; --surface-sunken: #dedad1;
  --ink: #1a1e1c; --ink-muted: #4f5652; --ink-subtle: #5a615c;
  --border-subtle: #d3cfc5; --border-strong: #6c726d;
  --brand: #0e6556; --brand-hover: #0a5246; --on-brand: #ffffff; --brand-soft: #d3e9e3; --on-brand-soft: #0a4a3f;
  --warn: #7a4e00; --warn-soft: #f6e6c3;
  --focus-ring: #1f5fae;
  --shadow-raised: 0 1px 2px rgba(26,30,28,.06), 0 12px 32px rgba(26,30,28,.08);
  --font-ui: system-ui, -apple-system, "Segoe UI", "Ubuntu", "Cantarell", sans-serif;
  --font-display: "Newsreader", Georgia, "Times New Roman", serif;
  --font-mono: ui-monospace, "SF Mono", "Cascadia Mono", "DejaVu Sans Mono", monospace;
  --radius-sm: 6px; --radius-md: 10px; --radius-lg: 14px; --radius-pill: 999px;
  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --page: 1120px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --surface-window: #161918; --surface-page: #1d201f; --surface-raised: #272b29; --surface-sunken: #0f1110;
    --ink: #ebeae5; --ink-muted: #aab0ab; --ink-subtle: #98a09a;
    --border-subtle: #343937; --border-strong: #7b827d;
    --brand: #58c4ae; --brand-hover: #7ad3c1; --on-brand: #06241e; --brand-soft: #1c3a34; --on-brand-soft: #a6e3d5;
    --warn: #e8b04a; --warn-soft: #3b2f14;
    --focus-ring: #8db8f2;
    --shadow-raised: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.35);
  }
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--surface-page); color: var(--ink);
  font: 400 16px/1.6 var(--font-ui); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
a { color: var(--brand); text-underline-offset: 3px; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--focus-ring); outline-offset: 2px; border-radius: 4px; }
code { font: 400 0.875em/1.4 var(--font-mono); }
h1, h2, h3, p, dl, dd { margin: 0; }
.muted { color: var(--ink-muted); }
.small { font-size: 14px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.skip { position: absolute; left: -999px; top: 8px; padding: 8px 12px; background: var(--surface-raised); border-radius: var(--radius-sm); }
.skip:focus { left: 16px; z-index: 10; }

/* Header */
.site-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  max-width: var(--page); margin: 0 auto; padding: 24px 24px 0; }
.brand { display: inline-flex; align-items: center; gap: 9px; color: var(--ink); text-decoration: none;
  font: 600 19px/1 var(--font-ui); letter-spacing: -0.02em; }
.site-head nav { display: flex; flex-wrap: wrap; gap: 4px 24px; }
.site-head nav a { color: var(--ink-muted); text-decoration: none; font-size: 15px; padding: 6px 0; transition: color 150ms ease; }

main { max-width: var(--page); margin: 0 auto; padding: 0 24px; }
section { padding: 112px 0 0; }
h2 { font: 500 clamp(28px, 3.2vw, 38px)/1.15 var(--font-display); letter-spacing: -0.01em; }
.section-lede { margin-top: 12px; max-width: 40em; color: var(--ink-muted); }

/* Hero */
.hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 56px; align-items: start; padding-top: 72px; }
.eyebrow { color: var(--ink-muted); font-size: 14px; letter-spacing: 0.01em; margin-bottom: 20px; }
.hero h1 { font: 400 clamp(42px, 5.6vw, 68px)/1.02 var(--font-display); letter-spacing: -0.025em; text-wrap: balance; }
.hero h1 em { font-style: italic; color: var(--brand); }
.lede { margin-top: 24px; max-width: 34em; color: var(--ink-muted); font-size: 18px; line-height: 1.6; text-wrap: pretty; }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 0 20px;
  border: 1px solid transparent; border-radius: var(--radius-sm); font: 500 15px/1 var(--font-ui);
  text-decoration: none; cursor: pointer; transition: transform 160ms var(--ease-out), background-color 150ms ease, border-color 150ms ease; }
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--brand); color: var(--on-brand); }
.btn-quiet { color: var(--ink); border-color: var(--border-subtle); background: transparent; }
.btn-lg { min-height: 52px; padding: 0 28px; font-size: 16px; }
.btn[aria-disabled="true"], .dl-other a[aria-disabled="true"] { opacity: .5; pointer-events: none; }

@media (hover: hover) and (pointer: fine) {
  .site-head nav a:hover { color: var(--ink); }
  .btn-primary:hover { background: var(--brand-hover); }
  .btn-quiet:hover { border-color: var(--border-strong); }
  .netlog-list li:hover { background: var(--surface-page); }
  .copy:hover { border-color: var(--border-strong); }
}

/* Network log */
.netlog { margin: 0; background: var(--surface-raised); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-raised); overflow: hidden; }
.netlog figcaption { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap;
  padding: 20px 20px 16px; border-bottom: 1px solid var(--border-subtle); }
.netlog-title { font: 600 15px/1.4 var(--font-ui); }
.netlog-sub { color: var(--ink-muted); font-size: 13px; margin-top: 2px; font-variant-numeric: tabular-nums; }

.segment { display: inline-flex; padding: 3px; border-radius: 8px; background: var(--surface-sunken); flex: none; }
.segment button { height: 30px; padding: 0 12px; border: 0; border-radius: 6px; background: none; color: var(--ink-muted);
  font: 500 13px/1 var(--font-ui); cursor: pointer; transition: background-color 150ms ease, color 150ms ease, transform 160ms var(--ease-out); }
.segment button:active { transform: scale(0.97); }
.segment button[aria-pressed="true"] { background: var(--surface-raised); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.12); }

.netlog-list { list-style: none; margin: 0; padding: 6px; min-height: 420px; transition: opacity 180ms ease, filter 180ms ease; }
.netlog-list.is-swapping { opacity: 0; filter: blur(2px); }
.netlog-list li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; align-items: baseline; gap: 12px;
  padding: 9px 14px; border-radius: 8px; transition: background-color 150ms ease; }
.netlog-list .t { color: var(--ink-subtle); font: 400 12px/1.4 var(--font-mono); font-variant-numeric: tabular-nums; }
.netlog-list .host { display: block; font: 400 13px/1.4 var(--font-mono); color: var(--ink); overflow-wrap: anywhere; }
.netlog-list .why { display: block; color: var(--ink-muted); font-size: 13px; line-height: 1.4; margin-top: 1px; }
.tag { font: 500 11.5px/1 var(--font-ui); padding: 5px 8px; border-radius: var(--radius-pill); white-space: nowrap; }
.tag-gone { color: var(--warn); background: var(--warn-soft); }
.tag-keep { color: var(--on-brand-soft); background: var(--brand-soft); }
.netlog-list li.is-end { grid-template-columns: 52px minmax(0, 1fr); }
.netlog-list li.is-end .why { font-style: italic; }
.netlog-foot { padding: 14px 20px 18px; border-top: 1px solid var(--border-subtle); color: var(--ink-muted); font-size: 13px; }

/* Differences */
.differences h2 { max-width: 14em; }
.numbered { list-style: none; counter-reset: n; margin: 40px 0 0; padding: 0;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 56px; }
.numbered li { counter-increment: n; position: relative; padding: 24px 0 28px 52px; border-top: 1px solid var(--border-subtle); }
.numbered li::before { content: counter(n, decimal-leading-zero); position: absolute; left: 0; top: 27px;
  color: var(--brand); font: 400 13px/1 var(--font-mono); font-variant-numeric: tabular-nums; }
.numbered h3 { font: 600 17px/1.35 var(--font-ui); letter-spacing: -0.005em; }
.numbered p { margin-top: 6px; color: var(--ink-muted); font-size: 15px; max-width: 32em; }

/* Compare */
.table-wrap { margin-top: 36px; overflow-x: auto; border: 1px solid var(--border-subtle); border-radius: var(--radius-lg);
  background: var(--surface-raised); box-shadow: var(--shadow-raised); }
.compare-table { width: 100%; min-width: 760px; border-collapse: collapse; font-size: 14px; }
.compare-table th, .compare-table td { padding: 14px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--border-subtle); }
.compare-table tbody tr:last-child > * { border-bottom: 0; }
.compare-table thead th { font: 600 14px/1.3 var(--font-ui); color: var(--ink); padding-top: 18px; }
.compare-table tbody th { font-weight: 500; color: var(--ink); width: 24%; }
.compare-table td { color: var(--ink-muted); width: 15.2%; line-height: 1.35; }
.compare-table .is-amaya { background: color-mix(in srgb, var(--brand-soft) 45%, transparent); }
.compare-table thead .is-amaya { color: var(--brand); }
.compare-table td > span { display: block; font-weight: 600; color: var(--ink); }
.compare-table .yes::before, .compare-table .no::before, .compare-table .part::before {
  content: ""; display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; vertical-align: 1px; }
.compare-table .yes::before { background: var(--brand); }
.compare-table .part::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--ink-muted); }
.compare-table .no::before { background: transparent; box-shadow: inset 0 0 0 1.5px var(--border-strong); width: 7px; height: 1.5px; border-radius: 0; vertical-align: 3px; }

.versus { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 32px; margin-top: 40px; }
.versus dt { font: 600 16px/1.4 var(--font-ui); }
.versus dd { margin-top: 8px; color: var(--ink-muted); font-size: 15px; }

/* Download */
.download-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px 24px; flex-wrap: wrap; }
.download-head .muted { font-size: 15px; font-variant-numeric: tabular-nums; }
.download-main { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 32px; margin-top: 32px; }
.dl-primary { display: flex; flex-direction: column; align-items: flex-start; gap: 16px; padding: 28px;
  background: var(--surface-raised); border: 1px solid var(--border-subtle); border-radius: var(--radius-lg); box-shadow: var(--shadow-raised); }
.dl-label { font-weight: 600; }
.cmd { display: flex; align-items: center; gap: 8px; width: 100%; padding: 6px 6px 6px 14px;
  background: var(--surface-sunken); border-radius: var(--radius-sm); }
.cmd code { flex: 1; min-width: 0; overflow-wrap: anywhere; font-size: 13px; }
.copy { flex: none; min-width: 76px; height: 32px; padding: 0 12px; border: 1px solid var(--border-subtle); border-radius: 6px;
  background: var(--surface-raised); color: var(--ink); font: 500 13px/1 var(--font-ui); cursor: pointer;
  transition: transform 160ms var(--ease-out), border-color 150ms ease; }
.copy:active { transform: scale(0.97); }
.copy-label { display: inline-block; transition: opacity 160ms ease, filter 160ms ease; }
.copy-label.is-swapping { opacity: 0; filter: blur(2px); }
.dl-other { list-style: none; margin: 0; padding: 0; align-self: start; }
.dl-other li { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 18px 0;
  border-bottom: 1px solid var(--border-subtle); font-size: 15px; }
.dl-other li:first-child { border-top: 1px solid var(--border-subtle); }
.dl-other a { font-weight: 500; white-space: nowrap; }
.soon { color: var(--ink-muted); font-size: 13px; white-space: nowrap; }

/* Roadmap */
.timeline { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.timeline li { padding-top: 18px; border-top: 2px solid var(--border-subtle); }
.timeline li.is-now { border-top-color: var(--brand); }
.timeline span { color: var(--ink-muted); font: 500 13px/1 var(--font-ui); }
.timeline li.is-now span { color: var(--brand); }
.timeline p { margin-top: 10px; font-size: 15px; line-height: 1.5; }

/* Footer */
.site-foot { max-width: var(--page); margin: 120px auto 0; padding: 32px 24px 48px; border-top: 1px solid var(--border-subtle);
  display: grid; grid-template-columns: auto 1fr auto; gap: 16px; align-items: center; color: var(--ink-muted); font-size: 13px; }

/* Entrance: once, on load. Movement is dropped for reduced motion. */
@media (prefers-reduced-motion: no-preference) {
  [data-enter] { animation: enter 600ms var(--ease-out) both; }
  .hero-copy [data-enter]:nth-child(2) { animation-delay: 60ms; }
  .hero-copy [data-enter]:nth-child(3) { animation-delay: 120ms; }
  .hero-copy [data-enter]:nth-child(4) { animation-delay: 180ms; }
  .netlog[data-enter] { animation-delay: 160ms; }
  @keyframes enter { from { opacity: 0; transform: translateY(10px); } }
}
@media (prefers-reduced-motion: reduce) {
  .btn, .copy, .segment button { transition: background-color 150ms ease, color 150ms ease; }
  .btn:active, .copy:active, .segment button:active { transform: none; }
  .netlog-list, .copy-label { transition: opacity 120ms ease; }
  .netlog-list.is-swapping, .copy-label.is-swapping { filter: none; }
}

/* Narrow screens */
@media (max-width: 900px) {
  .hero, .download-main { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .numbered, .versus { grid-template-columns: minmax(0, 1fr); }
  .versus { gap: 24px; }
  .timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .netlog-list { min-height: 0; }
}
@media (max-width: 560px) {
  main, .site-head { padding-left: 16px; padding-right: 16px; }
  section { padding-top: 80px; }
  .hero { padding-top: 48px; }
  .netlog-list li { grid-template-columns: minmax(0, 1fr) auto; }
  .netlog-list .t { display: none; }
  .netlog-list li.is-end { grid-template-columns: minmax(0, 1fr); }
  .site-head nav { gap: 4px 16px; }
  .site-head nav a { font-size: 14px; }
  .numbered li { padding-left: 40px; }
  .timeline { grid-template-columns: minmax(0, 1fr); }
  .site-foot { grid-template-columns: minmax(0, 1fr); padding-left: 16px; padding-right: 16px; }
  .dl-primary { padding: 20px; }
}
