/* Pace — site styles. No framework, no build step. */

:root {
  --bg: #F6F7F6;
  --bg-2: #EEF0EF;
  --surface: #FFFFFF;
  --ink: #0F1215;
  --ink-2: #464D55;
  --ink-3: #737B84;
  --line: rgba(15, 18, 21, 0.09);
  --line-2: rgba(15, 18, 21, 0.16);
  --mint: #0E9C7C;
  --mint-ink: #0A7660;
  --mint-soft: rgba(14, 156, 124, 0.10);
  --watch: #B98500;
  --risk: #E67700;
  --limited: #E5484D;
  --code-bg: #EFF1F0;
  --shadow: 0 1px 2px rgba(15, 18, 21, .06), 0 12px 40px -12px rgba(15, 18, 21, .22);
  --radius: 18px;
  --measure: 680px;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --display: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0C0E10;
    --bg-2: #121518;
    --surface: #16191D;
    --ink: #F1F3F4;
    --ink-2: #B3BAC1;
    --ink-3: #7D858E;
    --line: rgba(255, 255, 255, 0.08);
    --line-2: rgba(255, 255, 255, 0.15);
    --mint: #4FD6AE;
    --mint-ink: #6FE3C0;
    --mint-soft: rgba(79, 214, 174, 0.12);
    --watch: #F5C451;
    --risk: #FF9F0A;
    --limited: #FF6369;
    --code-bg: #15191C;
    --shadow: 0 1px 2px rgba(0, 0, 0, .4), 0 20px 50px -16px rgba(0, 0, 0, .7);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; }
::selection { background: var(--mint-soft); }

.wrap { width: 100%; max-width: 1160px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 600px) { .wrap { padding: 0 16px; } }

/* ---------- nav */
.nav { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 82%, transparent);
  -webkit-backdrop-filter: saturate(160%) blur(16px); backdrop-filter: saturate(160%) blur(16px);
  border-bottom: 1px solid transparent; }
.nav.scrolled, .nav.solid { border-bottom-color: var(--line); }
.nav .wrap { display: flex; align-items: center; height: 60px; gap: 20px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 650; letter-spacing: -.01em; }
.brand img { width: 30px; height: 30px; }
.nav .links { margin-left: auto; display: flex; align-items: center; gap: 22px; font-size: 15px; }
.nav .links a { text-decoration: none; color: var(--ink-2); }
.nav .links a:hover { color: var(--ink); }
.nav .links a.btn { color: var(--bg); }
@media (max-width: 520px) { .nav .links .hide-sm { display: none; } }

/* ---------- buttons */
.btn { display: inline-flex; align-items: center; gap: 8px; padding: 11px 18px; border-radius: 999px;
  background: var(--ink); color: var(--bg); text-decoration: none; font-weight: 600; font-size: 15px;
  line-height: 1.2; transition: transform .15s ease, opacity .15s ease; }
.btn:hover { opacity: .9; }
.btn:active { transform: scale(.98); }
.btn.small { padding: 7px 14px; font-size: 14px; }
.btn svg { width: 16px; height: 16px; }
.link-arrow { color: var(--ink); font-weight: 600; font-size: 15px; text-decoration: none; display: inline-flex; gap: 6px; align-items: center; }
.link-arrow:hover { color: var(--mint-ink); }
.link-arrow span { transition: transform .15s ease; }
.link-arrow:hover span { transform: translateX(3px); }

/* ---------- hero */
.hero { padding: 72px 0 40px; overflow-x: clip; }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--mint-ink);
  background: var(--mint-soft); padding: 5px 11px; border-radius: 999px; margin-bottom: 22px; letter-spacing: .01em; }
.eyebrow i { width: 6px; height: 6px; border-radius: 50%; background: var(--mint); }
h1 { font: 700 clamp(42px, 6.2vw, 76px)/1.02 var(--display); letter-spacing: -.034em; margin: 0 0 22px; }
h1 .soft { color: var(--ink-3); }
.lede { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.5; color: var(--ink-2); margin: 0 0 30px; max-width: 32em; }
.cta { display: flex; align-items: center; gap: 22px; flex-wrap: wrap; }
.fine { margin-top: 18px; font-size: 13px; color: var(--ink-3); }
.fine span + span::before { content: "·"; margin: 0 8px; }

/* menu bar + popover mock */
.stage { position: relative; display: flex; flex-direction: column; align-items: flex-end; }
.menubar { width: 100%; height: 30px; border-radius: 10px; display: flex; align-items: center; justify-content: flex-end;
  gap: 16px; padding: 0 14px; font: 500 13px/1 var(--sans); color: var(--ink);
  background: color-mix(in srgb, var(--surface) 70%, transparent); border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(20px); backdrop-filter: blur(20px); }
.menubar .item { display: inline-flex; align-items: center; gap: 5px; font-variant-numeric: tabular-nums; }
.menubar .item.pace { padding: 3px 7px; margin: 0 -7px; border-radius: 6px; background: var(--line); }
.menubar .item svg { width: 16px; height: 16px; }
.menubar .dim { color: var(--ink-3); }
.popover { width: 340px; margin: 8px 18px 0 0; border-radius: 16px; overflow: hidden; box-shadow: var(--shadow);
  border: 1px solid var(--line); background: var(--surface); }
.popover img { width: 340px; height: auto; }
.stage::before { content: ""; position: absolute; inset: 20% -10% -6% 10%; z-index: -1; filter: blur(60px);
  background: radial-gradient(closest-side, var(--mint-soft), transparent); }

@media (max-width: 900px) {
  .hero { padding-top: 44px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .stage { align-items: center; }
  .popover { margin-right: 0; }
}
@media (max-width: 400px) {
  .popover, .popover img { width: 100%; }
  .menubar .hide-xs { display: none; }
}

/* ---------- sections */
section.block { padding: 88px 0; }
section.block.tight { padding: 56px 0; }
.kicker { font-size: 13px; font-weight: 650; letter-spacing: .08em; text-transform: uppercase; color: var(--mint-ink); margin: 0 0 12px; }
h2 { font: 700 clamp(30px, 3.6vw, 44px)/1.08 var(--display); letter-spacing: -.026em; margin: 0 0 16px; }
.section-lede { font-size: 19px; color: var(--ink-2); max-width: 36em; margin: 0 0 44px; }
h3 { font: 650 19px/1.3 var(--display); letter-spacing: -.01em; margin: 0 0 6px; }
.muted { color: var(--ink-2); }

/* pace bar explainer */
.bar-demo { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 40px 40px 36px; }
.bar-demo svg { width: 100%; height: auto; overflow: visible; }
.bar-demo .label { font: 600 13px var(--sans); fill: var(--ink-2); }
.bar-demo .value { font: 600 13px var(--sans); fill: var(--ink); font-variant-numeric: tabular-nums; }
.legend { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; margin-top: 30px; }
.legend .swatch { width: 28px; height: 8px; border-radius: 4px; margin-bottom: 12px; }
.legend p { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.55; }
.numbers { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 16px; }
.numbers div { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
.numbers b { display: block; font-size: 15px; margin-bottom: 2px; }
.numbers span { color: var(--ink-2); font-size: 15px; }
.numbers code { font-size: 13px; }
@media (max-width: 720px) {
  .bar-demo { padding: 26px 18px 22px; }
  .legend { grid-template-columns: 1fr; gap: 18px; }
  .numbers { grid-template-columns: 1fr; }
}

/* status scale */
.states { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.state { margin: 0; }
.state .shot { border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--surface); }
.state .shot img { width: 100%; height: auto; }
.state figcaption { padding: 14px 4px 0; }
.state h3 { display: flex; align-items: center; gap: 8px; font-size: 17px; }
.state h3 i { width: 8px; height: 8px; border-radius: 50%; }
.state p { margin: 0; font-size: 15px; color: var(--ink-2); line-height: 1.5; }
.dot-comfortable { background: var(--mint); }
.dot-watch { background: var(--watch); }
.dot-risk { background: var(--risk); }
.dot-limited { background: var(--limited); }
@media (max-width: 1000px) { .states { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 16px; } }
@media (max-width: 560px) {
  .states { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; margin: 0 -16px; padding: 0 16px 8px;
    scrollbar-width: none; }
  .states::-webkit-scrollbar { display: none; }
  .state { flex: 0 0 82%; scroll-snap-align: center; }
}

/* day ring */
.tint-risk, .tone-risk svg { color: var(--risk); }
.tone-ok svg { color: var(--mint); }
.tone-limited svg { color: var(--limited); }
.formula { display: inline-block; font: 600 15px var(--mono); background: var(--code-bg); color: var(--ink); padding: 8px 14px; border-radius: 10px; margin: -8px 0 28px; }
.rings { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.ring-tile { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px 20px 22px; text-align: center; }
.ring-tile svg { display: block; width: 72px; height: 72px; margin: 0 auto 18px; }
.ring-tile b { display: block; font-size: 17px; margin-bottom: 4px; }
.ring-tile span { display: block; color: var(--ink-2); font-size: 14.5px; line-height: 1.5; }
.ring-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 16px; }
.ring-pair > div { display: flex; align-items: center; gap: 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 16px 20px; }
.ring-pair svg { flex: none; width: 44px; height: 44px; }
.ring-pair p { margin: 0; color: var(--ink-2); font-size: 15px; line-height: 1.5; }
.ring-pair b { display: block; color: var(--ink); }
.fig-card .rings.compact { gap: 8px; }
.fig-card .ring-tile { border: 0; padding: 6px 4px; background: none; }
.fig-card .ring-tile svg { width: 56px; height: 56px; margin-bottom: 12px; }
.fig-card .ring-tile b { font-size: 15px; }
.fig-card .ring-tile span { font-size: 13px; }
.fig-card .ring-pair { margin-top: 18px; gap: 10px; }
.fig-card .ring-pair > div { padding: 12px 14px; background: var(--bg); }
.fig-card .ring-pair svg { width: 36px; height: 36px; }
.fig-card .ring-pair p { font-size: 14px; }
@media (max-width: 860px) { .rings { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .ring-pair { grid-template-columns: 1fr; } .ring-tile { padding: 22px 14px 18px; } }

/* dashboard */
.dash-shot { max-width: 1000px; margin: 0 auto; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); background: var(--surface); }
.dash-shot img { display: block; width: 100%; height: auto; }

/* features */
.features { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.feature { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 24px 24px; }
.feature .ico { width: 36px; height: 36px; border-radius: 10px; background: var(--mint-soft); color: var(--mint-ink);
  display: grid; place-items: center; margin-bottom: 18px; }
.feature .ico svg { width: 20px; height: 20px; }
.feature p { margin: 0; color: var(--ink-2); font-size: 15.5px; line-height: 1.55; }
.feature code, .numbers code, .privacy code, .req code { font: 0.88em var(--mono); background: var(--code-bg); padding: 1px 5px; border-radius: 5px; }
kbd { font: 600 0.9em var(--sans); border: 1px solid var(--line-2); border-bottom-width: 2px; border-radius: 6px; padding: 0 6px; background: var(--surface); }
@media (max-width: 960px) { .features { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .features { grid-template-columns: 1fr; } }

/* privacy band */
.privacy { background: #0F1215; color: #EEF1F2; border-radius: 28px; padding: 64px 56px; display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: 48px; align-items: center; }
@media (prefers-color-scheme: dark) { .privacy { background: var(--bg-2); border: 1px solid var(--line); } }
.privacy h2 { color: #F4F6F7; }
.privacy p { color: #A9B1B9; margin: 0 0 14px; }
.privacy .kicker { color: #6FE3C0; }
.privacy ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.privacy li { display: flex; gap: 12px; align-items: flex-start; color: #DDE2E5; font-size: 16px; }
.privacy li svg { flex: none; width: 20px; height: 20px; margin-top: 3px; color: #6FE3C0; }
.privacy code { background: rgba(255,255,255,.08); color: #F4F6F7; }
.terminal { background: #07090A; border: 1px solid rgba(255,255,255,.08); border-radius: 14px; padding: 18px 20px;
  font: 13px/1.7 var(--mono); color: #C9D1D6; overflow-x: auto; margin-top: 22px; }
.terminal .p { color: #6FE3C0; user-select: none; }
.terminal .c { color: #6C757D; }
@media (max-width: 860px) { .privacy { grid-template-columns: 1fr; padding: 40px 22px; border-radius: 22px; gap: 32px; } }

/* download */
.download { text-align: center; }
.download img { width: 112px; height: 112px; margin: 0 auto 22px; }
.download .section-lede { margin-left: auto; margin-right: auto; }
.req { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 26px 0 0; padding: 0; list-style: none; }
.req li { font-size: 14px; color: var(--ink-2); border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; background: var(--surface); }
.download .cta { justify-content: center; }

/* footer */
footer { border-top: 1px solid var(--line); padding: 32px 0 48px; font-size: 14px; color: var(--ink-3); }
footer .wrap { display: flex; gap: 24px; justify-content: space-between; flex-wrap: wrap; }
footer p { margin: 0; max-width: 40em; }
footer a { color: var(--ink-2); }

/* ---------- article */
.article-head { padding: 64px 0 28px; }
.article-head .wrap { max-width: 860px; }
.article-head h1 { font-size: clamp(34px, 4.6vw, 54px); line-height: 1.07; letter-spacing: -.035em; margin-bottom: 18px; }
.article-head .dek { font-size: 20px; line-height: 1.5; color: var(--ink-2); margin: 0 0 22px; }
.byline { display: flex; flex-wrap: wrap; gap: 6px 0; font-size: 14px; color: var(--ink-3); }
.byline span + span::before { content: "·"; margin: 0 10px; }

.article-grid { display: grid; grid-template-columns: 220px minmax(0, var(--measure)); gap: 64px; justify-content: center;
  padding-bottom: 96px; }
.toc { position: sticky; top: 84px; align-self: start; font-size: 14px; line-height: 1.45; max-height: calc(100vh - 100px); overflow: auto; }
.toc details > summary { list-style: none; font-size: 12px; font-weight: 650; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-3); margin-bottom: 12px; cursor: default; }
.toc details > summary::-webkit-details-marker { display: none; }
.toc ol { list-style: none; margin: 0; padding: 0; }
.toc li { margin: 0; }
.toc a { display: block; padding: 5px 0 5px 12px; border-left: 2px solid var(--line); color: var(--ink-3); text-decoration: none; }
.toc a:hover { color: var(--ink); }
.toc a.active { color: var(--ink); border-left-color: var(--mint); }
.toc ol ol a { padding-left: 24px; font-size: 13px; }

.prose { font-size: 18px; line-height: 1.7; min-width: 0; }
.prose > :first-child { margin-top: 0; }
.prose p, .prose ul, .prose ol, .prose blockquote, .prose table, .prose pre, .prose figure { margin: 0 0 1.25em; }
.prose h2 { font-size: 30px; margin: 2.2em 0 .6em; scroll-margin-top: 84px; }
.prose h3 { font-size: 21px; margin: 1.9em 0 .5em; scroll-margin-top: 84px; }
.prose h2 code, .prose h3 code { font-size: .82em; }
.prose a { color: var(--mint-ink); text-underline-offset: 3px; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li { margin: .35em 0; padding-left: .2em; }
.prose li::marker { color: var(--ink-3); }
.prose strong { font-weight: 650; }
.prose code { font: .86em var(--mono); background: var(--code-bg); border: 1px solid var(--line); padding: .08em .35em; border-radius: 6px; }
.prose pre { background: var(--code-bg); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; overflow-x: auto;
  font: 14px/1.65 var(--mono); position: relative; }
.prose pre code { background: none; border: 0; padding: 0; font-size: inherit; }
.prose pre[data-lang]::before { content: attr(data-lang); position: absolute; top: 8px; right: 12px; font: 600 11px var(--sans);
  letter-spacing: .06em; text-transform: uppercase; color: var(--ink-3); }
.prose blockquote { margin-left: 0; padding: 18px 24px; border-left: 3px solid var(--mint); background: var(--mint-soft);
  border-radius: 0 14px 14px 0; font-size: 20px; line-height: 1.5; font-weight: 550; letter-spacing: -.01em; }
.prose blockquote p { margin: 0; }
.table-wrap { overflow-x: auto; margin: 0 0 1.25em; border: 1px solid var(--line); border-radius: 14px; background: var(--surface); }
.prose table { border-collapse: collapse; width: 100%; font-size: 15.5px; margin: 0; }
.prose th, .prose td { text-align: left; padding: 11px 16px; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose tr:last-child td { border-bottom: 0; }
.prose th { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--ink-3); font-weight: 650; }
.prose td:first-child { white-space: nowrap; font-weight: 600; }
.prose figure { margin: 2em 0; }
.prose figure pre { margin: 0; }
.prose figcaption { font-size: 14px; color: var(--ink-3); margin-top: 10px; line-height: 1.5; }
.fig-card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 24px; }
.fig-states { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.fig-states img { width: 100%; height: auto; border-radius: 10px; border: 1px solid var(--line); }
.fig-shot img { width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--line); }
.article-end { border-top: 1px solid var(--line); margin-top: 3em; padding-top: 1.6em; display: flex; justify-content: space-between;
  align-items: center; gap: 16px; flex-wrap: wrap; font-size: 15px; color: var(--ink-3); }

@media (max-width: 1000px) {
  .article-grid { grid-template-columns: minmax(0, var(--measure)); gap: 0; }
  .toc { position: static; max-height: none; margin-bottom: 36px; border: 1px solid var(--line); border-radius: 14px;
    padding: 14px 18px; background: var(--surface); }
  .toc details > summary { margin: 0; cursor: pointer; display: flex; justify-content: space-between; }
  .toc details > summary::after { content: "+"; font-size: 16px; line-height: 1; }
  .toc details[open] > summary::after { content: "–"; }
  .toc details[open] > summary { margin-bottom: 10px; }
}
@media (max-width: 600px) {
  .article-head { padding-top: 40px; }
  .prose { font-size: 17px; }
  .prose h2 { font-size: 25px; }
  .prose pre { font-size: 12.5px; padding: 14px 16px; border-radius: 12px; }
  .prose blockquote { font-size: 18px; padding: 14px 18px; }
  .fig-card { padding: 16px; }
}

@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
html { scroll-behavior: smooth; }

/* pace bar (shared by the product page and the article) */
.pbar { position: relative; padding: 34px 0 40px; }
.pbar-track { position: relative; height: 14px; border-radius: 7px; background: var(--line-2); }
.pbar-proj, .pbar-used { position: absolute; left: 0; top: 0; bottom: 0; border-radius: 7px; }
.pbar-proj { background: var(--mint); opacity: .28; }
.pbar-used { background: linear-gradient(90deg, color-mix(in srgb, var(--mint) 75%, white), var(--mint)); }
.pbar-tick { position: absolute; top: -6px; bottom: -6px; width: 4px; margin-left: -2px; border-radius: 2px;
  background: var(--ink); box-shadow: 0 0 0 2px var(--surface); }
.pbar-label { position: absolute; transform: translateX(-50%); white-space: nowrap; font-size: 13px; color: var(--ink-2);
  font-variant-numeric: tabular-nums; }
.pbar-label b { color: var(--ink); font-weight: 650; margin-right: 3px; }
.pbar-label.top { top: 4px; }
.pbar-label.bottom { bottom: 6px; }
.pbar-label.bottom::before { content: ""; position: absolute; left: 50%; top: -12px; height: 8px; border-left: 1px solid var(--line-2); }
.pbar-label.top::after { content: ""; position: absolute; left: 50%; bottom: -8px; height: 6px; border-left: 1px solid var(--line-2); }
@media (max-width: 420px) { .pbar-label { font-size: 12px; } }

/* article header sits on the text column on wide screens */
@media (min-width: 1001px) {
  .article-head .wrap { max-width: none; display: grid; grid-template-columns: 220px minmax(0, var(--measure)); column-gap: 64px; justify-content: center; }
  .article-head .wrap > * { grid-column: 2; }
  .article-head h1 { font-size: 46px; }
}
