/* Mon Data Tools.
   One accent only: a highlighter yellow that marks the data that matters.
   Radius rule: containers 16px, buttons and chips pill, inline code 6px. */
:root {
  --paper: #f4f6f8;
  --surface: #ffffff;
  --sunk: #eceff3;
  --ink: #18202e;
  --ink-2: #3a4457;
  --muted: #5b6575;
  --rule: #e0e4ea;
  --mark: #ffe066;
  --mark-soft: #fff6cc;
  --on-ink: #f4f6f8;
  --shadow: 0 1px 2px rgb(24 32 46 / .05), 0 12px 32px -12px rgb(24 32 46 / .14);
  --r: 16px;
  --font: "Geist", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0f131a;
    --surface: #161b24;
    --sunk: #1b212c;
    --ink: #e9edf3;
    --ink-2: #c4cbd6;
    --muted: #98a2b1;
    --rule: #262d3a;
    --mark: rgb(240 200 60 / .34);
    --mark-soft: rgb(240 200 60 / .09);
    --on-ink: #10141b;
    --shadow: 0 1px 2px rgb(0 0 0 / .3), 0 12px 32px -12px rgb(0 0 0 / .5);
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 16.5px/1.62 var(--font);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration-color: color-mix(in srgb, var(--ink) 35%, transparent); text-underline-offset: 3px; text-decoration-thickness: 1px; }
a:hover { text-decoration-color: var(--ink); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 3px; border-radius: 6px; }
code { font: .86em var(--mono); background: var(--sunk); padding: .12em .4em; border-radius: 6px; overflow-wrap: anywhere; }
img { display: block; }

.wrap { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 640px) { .wrap { padding: 0 16px; } }

/* Highlighter: the one accent. Wraps across lines like a real marker. */
.hl {
  background: linear-gradient(var(--mark), var(--mark)) no-repeat 0 60% / 100% 78%;
  box-decoration-break: clone; -webkit-box-decoration-break: clone;
  color: inherit; padding: 0 .12em; border-radius: 3px;
}

/* ---------- Header ---------- */
.top { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--paper) 86%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--rule); }
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; height: 64px; }
.brand { font-weight: 650; font-size: 17px; letter-spacing: -.02em; text-decoration: none; white-space: nowrap; }
.top nav { display: flex; gap: 4px; }
.top nav a { text-decoration: none; color: var(--muted); font-size: 15px; padding: 7px 12px; border-radius: 999px; }
.top nav a:hover { color: var(--ink); background: var(--sunk); }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap;
  font-weight: 560; font-size: 15.5px; text-decoration: none; padding: 12px 22px; border-radius: 999px;
  background: var(--ink); color: var(--on-ink); border: 1px solid var(--ink);
  transition: transform .2s var(--ease), background-color .2s var(--ease);
}
.btn:hover { background: var(--ink-2); color: var(--on-ink); }
.btn:active { transform: translateY(1px) scale(.98); }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule); }
.btn.ghost:hover { background: var(--surface); border-color: color-mix(in srgb, var(--ink) 30%, transparent); }
.btn.block { display: flex; width: 100%; }

/* ---------- Home: hero ---------- */
.hero { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 48px; align-items: center; padding-top: 72px; padding-bottom: 88px; }
.hero h1 { font-size: clamp(2.4rem, 4.2vw, 3.25rem); line-height: 1.02; letter-spacing: -.045em; font-weight: 640; margin: 0 0 22px; text-wrap: balance; }
.hero .sub { font-size: 1.18rem; line-height: 1.55; color: var(--muted); margin: 0 0 32px; max-width: 34ch; }
.hero .ctas { display: flex; gap: 12px; flex-wrap: wrap; }
@media (max-width: 960px) { .hero { grid-template-columns: minmax(0, 1fr); gap: 40px; padding-top: 40px; padding-bottom: 64px; } }

/* Real output preview */
.preview { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r); box-shadow: var(--shadow); overflow: hidden; }
.preview-head { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-bottom: 1px solid var(--rule); }
.preview-head img { width: 32px; height: 32px; border-radius: 8px; }
.preview-head strong { display: block; font-size: 14.5px; font-weight: 600; line-height: 1.3; }
.preview-head span { font-size: 13px; color: var(--muted); }
.preview-head .count { margin-left: auto; font-size: 13px; color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.preview ol { list-style: none; margin: 0; padding: 6px 0; }
.preview li { display: grid; grid-template-columns: 52px minmax(0, 1fr) auto; gap: 14px; align-items: baseline; padding: 11px 18px; font-size: 15px; }
.preview li + li { border-top: 1px solid var(--rule); }
.preview .fmt { font-size: 12.5px; color: var(--muted); }
.preview .days { font-variant-numeric: tabular-nums; color: var(--ink-2); white-space: nowrap; font-size: 14px; }
.preview .days small { color: var(--muted); font-size: 12.5px; }
.preview-caption { font-size: 13.5px; color: var(--muted); margin: 14px 4px 0; }

/* ---------- Section heads ---------- */
.section { padding: 88px 0; border-top: 1px solid var(--rule); }
.section > .wrap > h2, .section h2.head { font-size: clamp(1.8rem, 3.2vw, 2.6rem); line-height: 1.08; letter-spacing: -.035em; font-weight: 620; margin: 0 0 12px; text-wrap: balance; }
.section .intro { color: var(--muted); font-size: 1.08rem; margin: 0 0 40px; max-width: 60ch; }
@media (max-width: 640px) { .section { padding: 64px 0; } }

/* ---------- Tools bento: 9 tools, 9 cells ---------- */
.bento { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 14px; }
.cell { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r); padding: 22px; display: flex; flex-direction: column; gap: 10px; min-width: 0; transition: border-color .25s var(--ease); }
.cell:hover { border-color: color-mix(in srgb, var(--ink) 22%, transparent); }
.cell.w2 { grid-column: span 2; } .cell.w3 { grid-column: span 3; } .cell.w4 { grid-column: span 4; }
.cell.tall { grid-row: span 2; }
.cell.feature { background: var(--mark-soft); }
.cell .id { display: flex; align-items: center; gap: 12px; }
.cell .id img { width: 40px; height: 40px; border-radius: 10px; flex: none; }
.cell .src { font-size: 13px; color: var(--muted); }
.cell h3 { font-size: 1.12rem; line-height: 1.25; letter-spacing: -.015em; font-weight: 620; margin: 4px 0 0; }
.cell .what { color: var(--muted); font-size: 15px; margin: 0; }
.cell .foot { margin-top: auto; padding-top: 10px; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; font-size: 14.5px; }
.cell .price { font-weight: 600; font-variant-numeric: tabular-nums; margin-right: auto; }
.cell .foot a { font-weight: 500; }
.cell .sample { list-style: none; padding: 0; margin: 8px 0 0; background: var(--surface); border: 1px solid var(--rule); border-radius: 12px; overflow: hidden; }
.cell .sample li { display: flex; justify-content: space-between; gap: 14px; padding: 10px 14px; font-size: 14.5px; }
.cell .sample li + li { border-top: 1px solid var(--rule); }
.cell .sample .n { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; font-size: 13.5px; }
.cell .record { margin: 8px 0 0; background: var(--surface); border: 1px solid var(--rule); border-radius: 12px; padding: 6px 16px; }
.cell .record div { display: grid; grid-template-columns: 136px minmax(0, 1fr); gap: 14px; padding: 8px 0; font-size: 14.5px; }
.cell .record div + div { border-top: 1px solid var(--rule); }
.cell .record dt { font: 12.5px/1.9 var(--mono); color: var(--muted); }
.cell .record dd { margin: 0; }
@media (max-width: 640px) { .cell .record div { grid-template-columns: minmax(0, 1fr); gap: 0; } }
.chips { list-style: none; padding: 0; margin: 6px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.chips li { font-size: 13.5px; padding: 5px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--rule); }
.cell blockquote { margin: 6px 0 0; padding: 14px 16px; background: var(--sunk); border-radius: 12px; font-size: 15px; }
.cell blockquote p { margin: 0 0 4px; }
.cell blockquote footer { font-size: 13px; color: var(--muted); }
@media (max-width: 1024px) {
  .bento { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cell.w2, .cell.w3, .cell.w4 { grid-column: span 1; }
  .cell.tall { grid-column: span 2; grid-row: auto; }
}
@media (max-width: 640px) {
  .bento { grid-template-columns: minmax(0, 1fr); }
  .cell .price { flex-basis: 100%; }
  .cell.tall { grid-column: auto; }
}

/* ---------- How it works: a real sequence ---------- */
.flow { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; counter-reset: s; border-top: 2px solid var(--ink); }
.flow li { counter-increment: s; padding: 22px 28px 0 0; }
.flow li::before { content: counter(s); display: grid; place-items: center; width: 34px; height: 34px; border-radius: 999px; background: var(--ink); color: var(--on-ink); font-weight: 600; font-size: 15px; margin: -40px 0 18px; }
.flow h3 { font-size: 1.15rem; letter-spacing: -.015em; margin: 0 0 6px; font-weight: 620; }
.flow p { margin: 0; color: var(--muted); max-width: 34ch; }
@media (max-width: 768px) {
  .flow { grid-template-columns: minmax(0, 1fr); border-top: 0; border-left: 2px solid var(--ink); gap: 28px; }
  .flow li { padding: 0 0 0 28px; position: relative; }
  .flow li::before { position: absolute; left: -18px; top: -4px; margin: 0; }
}

/* ---------- Guide list ---------- */
.guides { list-style: none; padding: 0; margin: 0; }
.guides li + li { border-top: 1px solid var(--rule); }
.guides a { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 20px; align-items: center; padding: 24px 0; text-decoration: none; }
.guides img { width: 44px; height: 44px; border-radius: 10px; }
.guides h3 { font-size: clamp(1.15rem, 2vw, 1.45rem); letter-spacing: -.025em; font-weight: 600; margin: 0 0 4px; line-height: 1.25; }
.guides p { margin: 0; color: var(--muted); font-size: 15px; }
.guides .go { font-size: 15px; font-weight: 500; padding: 9px 18px; border: 1px solid var(--rule); border-radius: 999px; white-space: nowrap; transition: background-color .2s var(--ease); }
.guides a:hover .go { background: var(--ink); color: var(--on-ink); border-color: var(--ink); }
.guides a:hover h3 { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
@media (max-width: 640px) { .guides a { grid-template-columns: 40px minmax(0, 1fr); } .guides .go { display: none; } }

/* ---------- Guide pages ---------- */
.crumb { font-size: 14px; color: var(--muted); margin: 0 0 18px; }
.crumb a { color: var(--muted); }
.guide { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 64px; padding-top: 56px; padding-bottom: 96px; }
@media (max-width: 960px) { .guide { grid-template-columns: minmax(0, 1fr); gap: 32px; padding-top: 32px; } }
article { min-width: 0; }
article > * { max-width: 66ch; }
article > .data, article > .fields { max-width: none; }
article h1 { font-size: clamp(2.1rem, 4.2vw, 3.3rem); line-height: 1.04; letter-spacing: -.04em; font-weight: 640; margin: 0 0 20px; text-wrap: balance; }
.lede { font-size: 1.15rem; color: var(--muted); margin: 0 0 36px; }
article h2 { font-size: 1.55rem; line-height: 1.2; letter-spacing: -.03em; font-weight: 620; margin: 64px 0 16px; }
article p, article li { margin: 0 0 14px; }

.data { margin: 0 0 10px; border: 1px solid var(--rule); border-radius: var(--r); background: var(--surface); overflow-x: auto; box-shadow: var(--shadow); }
.data table { border-collapse: collapse; width: 100%; font-size: 15px; }
.data th, .data td { text-align: left; padding: 12px 16px; vertical-align: top; }
.data tbody tr + tr td { border-top: 1px solid var(--rule); }
.data th { font-weight: 500; font-size: 13px; color: var(--muted); white-space: nowrap; border-bottom: 1px solid var(--rule); }
.data td.num, .data th.num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.data td.nowrap { white-space: nowrap; color: var(--ink-2); }
.data td.text { min-width: 280px; }
.caption { font-size: 14px; color: var(--muted); margin: 0 0 8px; }

ol.steps { list-style: none; padding: 0; counter-reset: step; }
ol.steps li { counter-increment: step; position: relative; padding-left: 48px; margin-bottom: 20px; }
ol.steps li::before { content: counter(step); position: absolute; left: 0; top: -1px; width: 30px; height: 30px; border-radius: 999px; background: var(--ink); color: var(--on-ink); font-weight: 600; font-size: 14px; display: grid; place-items: center; }

.fields { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0; }
.fields div { background: var(--surface); border: 1px solid var(--rule); border-radius: 12px; padding: 14px 16px; }
.fields dt { font: 13.5px var(--mono); margin-bottom: 4px; overflow-wrap: anywhere; }
.fields dd { margin: 0; color: var(--muted); font-size: 15px; }
@media (max-width: 640px) { .fields { grid-template-columns: minmax(0, 1fr); } }

.note { background: var(--mark-soft); border-radius: 12px; padding: 14px 18px; }

details { padding: 16px 0; max-width: 66ch; }
details + details { border-top: 1px solid var(--rule); }
summary { cursor: pointer; font-weight: 560; }
summary::marker { color: var(--muted); }
details p { margin: 10px 0 0; color: var(--muted); }

.panel { position: sticky; top: 88px; align-self: start; border: 1px solid var(--rule); border-radius: var(--r); background: var(--surface); padding: 24px; box-shadow: var(--shadow); }
.panel img { width: 48px; height: 48px; border-radius: 12px; margin-bottom: 14px; }
.panel h2 { font-size: 1.05rem; line-height: 1.3; margin: 0; font-weight: 620; letter-spacing: -.01em; }
.panel .price { font-size: 2rem; font-weight: 640; letter-spacing: -.04em; margin: 14px 0 0; font-variant-numeric: tabular-nums; }
.panel .price small { font-size: .9rem; font-weight: 400; letter-spacing: 0; color: var(--muted); }
.panel ul { padding-left: 18px; margin: 14px 0 20px; color: var(--muted); font-size: 15px; }
.panel li { margin-bottom: 6px; }
.panel .small { font-size: 13.5px; color: var(--muted); margin: 12px 0 0; }
@media (max-width: 960px) { .panel { display: none; } }

.inline-cta { display: none; }
@media (max-width: 960px) {
  .inline-cta { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 12px 14px; align-items: center; border: 1px solid var(--rule); border-radius: var(--r); background: var(--surface); padding: 16px; margin: 22px 0 8px; }
  .inline-cta img { width: 40px; height: 40px; border-radius: 10px; }
  .inline-cta p { margin: 0; font-size: 15px; }
  .inline-cta .btn { grid-column: 1 / -1; }
}

/* ---------- Footer ---------- */
.foot-site { border-top: 1px solid var(--rule); padding: 40px 0 56px; color: var(--muted); font-size: 14px; }
.foot-site .wrap { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 24px; }
.foot-site p { margin: 0 0 8px; max-width: 70ch; }
.foot-site .brand { color: var(--ink); display: inline-block; margin-bottom: 10px; }
@media (max-width: 640px) { .foot-site .wrap { grid-template-columns: minmax(0, 1fr); } }

/* ---------- Motion: one load moment on home, one reveal per data table ----------
   Only runs when JS marks the page and the reader has not asked for reduced motion. */
@media (prefers-reduced-motion: no-preference) {
  .js .preview li { opacity: 0; transform: translateY(10px); animation: rise .7s var(--ease) forwards; animation-delay: calc(250ms + var(--i) * 90ms); }
  .js .preview .hl, .js .data .hl { background-size: 0% 78%; }
  .js .preview .hl { animation: sweep .7s var(--ease) forwards; animation-delay: calc(700ms + var(--i) * 110ms); }
  .js .data.on .hl { animation: sweep .7s var(--ease) forwards; animation-delay: calc(150ms + var(--i) * 110ms); }
  .js .hero-copy > * { opacity: 0; transform: translateY(12px); animation: rise .8s var(--ease) forwards; }
  .js .hero-copy > :nth-child(2) { animation-delay: 80ms; }
  .js .hero-copy > :nth-child(3) { animation-delay: 160ms; }
}
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes sweep { to { background-size: 100% 78%; } }
