/* Layout: one centered column, hero splits copy / phone, sections stack with wide breathing room.
   Look: black and white like the logo; red is reserved for bad news. */
:root {
  --bg: #0A0A0A;
  --surface: #141414;
  --line: #262626;
  --fg: #F5F5F5;
  --muted: #A3A3A3;
  --invert: #0A0A0A;
  --bad: #FF5A5A;
  --bad-bg: #2A1414;
  --font-display: 'Space Grotesk', 'Helvetica Neue', Arial, sans-serif;
  --font-body: 'IBM Plex Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, Menlo, monospace;
  --radius: 18px;
  color-scheme: dark;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #FAFAFA; --surface: #FFFFFF; --line: #E3E3E3; --fg: #0A0A0A;
    --muted: #595959; --invert: #FFFFFF; --bad: #D42A2A; --bad-bg: #FDECEC;
    color-scheme: light;
  }
}
:root[data-theme="light"] {
  --bg: #FAFAFA; --surface: #FFFFFF; --line: #E3E3E3; --fg: #0A0A0A;
  --muted: #595959; --invert: #FFFFFF; --bad: #D42A2A; --bad-bg: #FDECEC;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
:focus-visible { outline: 2px solid var(--fg); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--font-display); line-height: 1.05; margin: 0; text-wrap: balance; letter-spacing: -0.02em; }
h2 { font-size: clamp(32px, 5vw, 52px); }
h3 { font-size: 21px; letter-spacing: -0.01em; }
p { margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding-left: max(20px, env(safe-area-inset-left, 0px));
  padding-right: max(20px, env(safe-area-inset-right, 0px));
}

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 0 22px;
  background: var(--fg); color: var(--invert);
  border: 1px solid var(--fg); border-radius: 999px;
  font: 600 16px/1 var(--font-body); text-decoration: none; cursor: pointer;
  transition: transform .15s ease, opacity .15s ease;
}
.btn:hover { opacity: .88; }
.btn:active { transform: translateY(1px); }
.btn-ghost { background: transparent; color: var(--fg); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--fg); opacity: 1; }
.btn-small { min-height: 40px; padding: 0 16px; font-size: 15px; }

/* Header */
.site-header {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 10;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.header-row { display: flex; align-items: center; gap: 24px; padding-block: 12px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font: 700 22px var(--font-display); letter-spacing: -0.02em; }
.mark { width: 34px; height: 34px; fill: var(--fg); }
.mark-line { fill: none; stroke: var(--fg); stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; }
.mark-mask { fill: var(--bg); }
.nav { display: flex; gap: 22px; margin-left: auto; font-size: 15px; }
.nav a { text-decoration: none; color: var(--muted); }
.nav a:hover { color: var(--fg); }
@media (max-width: 640px) { .nav { display: none; } .header-row .btn { margin-left: auto; } }

/* Hero */
.hero { padding-block: clamp(48px, 9vw, 110px) clamp(56px, 8vw, 100px); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: 56px; align-items: center; }
@media (max-width: 860px) { .hero-grid { grid-template-columns: minmax(0, 1fr); } }
.hero-copy { display: flex; flex-direction: column; gap: 22px; min-width: 0; }
.eyebrow { font: 500 13px var(--font-mono); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
.hero h1 { font-size: clamp(52px, 9vw, 104px); letter-spacing: -0.045em; line-height: .95; }
.lede { font-size: clamp(18px, 2.2vw, 21px); color: var(--muted); max-width: 32em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.fineprint { font-size: 14px; color: var(--muted); }

/* Phone mockup */
.phone { margin: 0; justify-self: center; display: flex; flex-direction: column; align-items: center; gap: 10px; width: 100%; max-width: 320px; }
.phone figcaption { font: 500 12px var(--font-mono); color: var(--muted); letter-spacing: .08em; text-transform: uppercase; }
.phone-screen {
  width: 100%; border: 1px solid var(--line); border-radius: 40px;
  background: var(--bg); padding: 22px 16px 20px;
  display: flex; flex-direction: column; gap: 12px;
  box-shadow: 0 30px 80px -30px rgba(0,0,0,.6);
}
.p-top { display: flex; justify-content: space-between; align-items: center; }
.p-brand { font: 700 17px var(--font-display); }
.p-chip { font-size: 12px; border: 1px solid var(--line); border-radius: 999px; padding: 5px 10px; }
.p-card { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px; display: flex; flex-direction: column; gap: 10px; }
.p-meta, .p-label { font-size: 12px; color: var(--muted); }
.p-label { font-weight: 600; color: var(--fg); }
.p-verdict { display: flex; align-items: center; gap: 12px; }
.p-grade { width: 52px; height: 52px; flex: none; border-radius: 14px; background: var(--fg); color: var(--invert); display: grid; place-items: center; font: 700 26px var(--font-display); }
.p-verdict-text { font: 700 20px/1.15 var(--font-display); }
.p-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; }
.p-stats div { background: var(--bg); border-radius: 10px; padding: 8px; display: flex; flex-direction: column; }
.p-stats span { font-size: 10.5px; color: var(--muted); }
.p-stats b { font: 600 15px var(--font-body); font-variant-numeric: tabular-nums; }
.p-why { font-size: 13px; line-height: 1.5; }
.p-alert { display: flex; align-items: center; gap: 10px; font-size: 12.5px; line-height: 1.4; background: var(--bad-bg); border: 1px solid color-mix(in srgb, var(--bad) 40%, transparent); border-radius: 14px; padding: 10px 12px; }
.p-dot { width: 8px; height: 8px; flex: none; border-radius: 50%; background: var(--bad); }
.bad { color: var(--bad); }

/* Sections */
.section { padding-block: clamp(64px, 9vw, 110px); border-top: 1px solid var(--line); }
.section h2 { margin-bottom: 14px; }
.section-lede { font-size: 19px; color: var(--muted); max-width: 34em; }

/* Steps: a real sequence, so numbered */
.steps { list-style: none; padding: 0; margin: 40px 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
@media (max-width: 760px) { .steps { grid-template-columns: minmax(0, 1fr); } }
.steps li { display: flex; flex-direction: column; gap: 10px; padding-top: 18px; border-top: 2px solid var(--fg); }
.step-n { font: 500 14px var(--font-mono); color: var(--muted); }
.steps p { color: var(--muted); }

/* Features */
.features { margin-top: 40px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
@media (max-width: 900px) { .features { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .features { grid-template-columns: minmax(0, 1fr); } }
.feature { background: var(--bg); padding: 28px; display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.feature p { color: var(--muted); font-size: 16px; }
.feature-wide { grid-column: span 3; display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 40px; row-gap: 10px; align-items: center; }
.feature-wide h3 { grid-column: 1; }
.feature-wide p { grid-column: 1; max-width: 36em; }
.grade-row { grid-column: 2; grid-row: 1 / span 2; display: flex; gap: 10px; }
@media (max-width: 900px) { .feature-wide { grid-column: span 2; } }
@media (max-width: 600px) {
  .feature-wide { grid-column: span 1; grid-template-columns: minmax(0, 1fr); }
  .grade-row { grid-column: 1; grid-row: auto; margin-top: 8px; }
}
.g { width: 72px; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 0; border: 1px solid var(--line); border-radius: 14px; }
.g-v { font: 500 12px var(--font-mono); color: var(--muted); }
.g-l { font: 700 28px var(--font-display); }
.g-now { background: var(--fg); color: var(--invert); border-color: var(--fg); }
.g-now .g-v { color: var(--invert); opacity: .7; }

/* Pricing */
.pricing-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 20px; }
.toggle { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 4px; gap: 4px; }
.toggle-btn { font: 500 14px var(--font-body); color: var(--muted); background: transparent; border: 0; border-radius: 999px; min-height: 40px; padding: 0 16px; cursor: pointer; }
.toggle-btn.is-on { background: var(--fg); color: var(--invert); }
.plans { margin-top: 36px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
@media (max-width: 900px) { .plans { grid-template-columns: minmax(0, 1fr); max-width: 460px; } }
.plan { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; gap: 12px; background: var(--bg); }
.plan-main { border: 2px solid var(--fg); background: var(--surface); }
.plan-badge { align-self: flex-start; font: 500 12px var(--font-mono); text-transform: uppercase; letter-spacing: .1em; background: var(--fg); color: var(--invert); padding: 4px 10px; border-radius: 999px; }
.price { display: flex; align-items: baseline; gap: 4px; }
.amount { font: 700 48px/1 var(--font-display); letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.per { color: var(--muted); }
.plan-for { color: var(--muted); font-size: 15px; }
.plan ul { list-style: none; padding: 0; margin: 8px 0 12px; display: flex; flex-direction: column; gap: 10px; flex-grow: 1; font-size: 15.5px; }
.plan li { display: flex; gap: 10px; }
.plan li::before { content: ""; flex: none; width: 14px; height: 8px; margin-top: 7px; border-left: 2px solid var(--fg); border-bottom: 2px solid var(--fg); transform: rotate(-45deg); }

/* FAQ */
.faq-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 40px; }
@media (max-width: 760px) { .faq-wrap { grid-template-columns: minmax(0, 1fr); gap: 16px; } }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; padding-block: 20px; font: 600 18px var(--font-body); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font: 500 22px/1 var(--font-mono); color: var(--muted); }
.faq details[open] summary::after { content: "−"; }
.faq details p { color: var(--muted); padding-bottom: 20px; max-width: 38em; }

/* Join */
.join-inner { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 14px; }
.join-form { margin-top: 14px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; width: 100%; max-width: 520px; }
.join-form input[type="email"] {
  flex: 1 1 240px; min-width: 0; min-height: 48px; padding: 0 18px;
  background: var(--surface); color: var(--fg); border: 1px solid var(--line); border-radius: 999px;
  font: 16px var(--font-body);
}
.join-form input::placeholder { color: var(--muted); }
.join-msg { min-height: 1.6em; font-size: 15px; }
.join-msg.is-error { color: var(--bad); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 28px; font-size: 14px; color: var(--muted); }
.footer-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; }

/* Compare page */
.compare-hero { padding-block: clamp(48px, 8vw, 90px) 32px; }
.compare-hero .wrap { display: flex; flex-direction: column; gap: 16px; }
.compare-title { font-size: clamp(44px, 7vw, 80px); letter-spacing: -0.04em; line-height: .95; }
.plan-strip { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; padding-block: 8px 40px; }
@media (max-width: 640px) { .plan-strip { grid-template-columns: minmax(0, 1fr); } }
.mini-plan { border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 6px; }
.mini-plan h2 { font-size: 22px; }
.mini-plan p { color: var(--muted); font-size: 15px; }
.mini-plan .mini-price { color: var(--fg); font: 700 34px/1.1 var(--font-display); letter-spacing: -0.03em; }
.mini-price span { font: 400 15px var(--font-body); color: var(--muted); letter-spacing: 0; }
.mini-main { border: 2px solid var(--fg); background: var(--surface); }
.compare-table-section { padding-block: 0 clamp(64px, 9vw, 110px); }
.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); }
.compare { width: 100%; min-width: 520px; border-collapse: collapse; font-size: 15.5px; }
.compare th, .compare td { padding: 14px 16px; border-bottom: 1px solid var(--line); text-align: center; vertical-align: middle; }
.compare th[scope="row"], .compare thead th:first-child { text-align: left; font-weight: 500; width: 46%; }
.compare thead th { font: 700 18px var(--font-display); padding-block: 18px; position: sticky; top: 0; background: var(--bg); }
.compare td { color: var(--fg); font-variant-numeric: tabular-nums; }
.compare .col-main { background: var(--surface); }
.compare thead .col-main { background: var(--surface); }
.compare .group th { text-align: left; font: 500 12px var(--font-mono); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); padding-top: 26px; padding-bottom: 10px; background: var(--bg); }
.compare tbody tr:last-child th, .compare tbody tr:last-child td { border-bottom: 1px solid var(--line); }
.compare tfoot th, .compare tfoot td { border-bottom: 0; padding-block: 20px; }
.yes { display: inline-block; width: 14px; height: 8px; border-left: 2px solid var(--fg); border-bottom: 2px solid var(--fg); transform: translateY(-3px) rotate(-45deg); }
.no { color: var(--muted); }
.compare-note { margin-top: 16px; font-size: 15px; color: var(--muted); }
.pricing-more { margin-top: 20px; font-size: 15px; }

/* Everything list */
.all-grid { margin-top: 40px; display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); gap: 36px 32px; }
.all-group { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.all-group h3 { font-size: 18px; padding-bottom: 10px; border-bottom: 1px solid var(--line); }
.all-group ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; color: var(--muted); font-size: 15.5px; line-height: 1.45; }
#everything .section-lede a { color: var(--fg); }

/* Log in / Sign up area */
.auth { display: flex; gap: 8px; align-items: center; }
@media (max-width: 640px) { .auth { margin-left: auto; } }
[hidden] { display: none !important; }
@media (max-width: 420px) {
  .header-row { gap: 10px; }
  .brand span { font-size: 19px; }
  .auth .btn-small { padding: 0 12px; }
}

/* Three-line menu */
.menu-btn { width: 44px; height: 44px; flex: none; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 12px; background: transparent; color: var(--fg); cursor: pointer; }
.menu-btn svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.site-menu-backdrop { position: fixed; inset: 0; z-index: 40; background: rgba(0,0,0,.5); }
.site-menu {
  position: fixed; top: 0; right: 0; bottom: 0; z-index: 41; width: min(320px, 86vw); overflow-y: auto;
  background: var(--surface); border-left: 1px solid var(--line);
  padding: calc(16px + env(safe-area-inset-top, 0px)) max(18px, env(safe-area-inset-right, 0px)) calc(24px + env(safe-area-inset-bottom, 0px)) 18px;
  display: flex; flex-direction: column; gap: 12px;
}
.site-menu-top { display: flex; justify-content: space-between; align-items: center; }
.brand-text { font: 700 22px var(--font-display); letter-spacing: -0.02em; }
.site-menu nav { display: flex; flex-direction: column; gap: 4px; }
.site-menu-title { font: 500 11px var(--font-mono); text-transform: uppercase; letter-spacing: .12em; color: var(--muted); margin-top: 14px; }
.site-menu ul { list-style: none; margin: 0; padding: 0; }
.site-menu a { display: flex; align-items: center; min-height: 44px; padding: 0 10px; border-radius: 10px; text-decoration: none; font-size: 16px; }
.site-menu a:hover { background: var(--bg); }
@media (max-width: 420px) { .auth [data-when="out"].btn-ghost { display: none; } }

/* Free tools + live page */
.tools-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
@media (min-width: 820px) { .tools-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tool-card { border: 1px solid var(--line); border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 12px; background: var(--surface, #fff); }
.tool-card h2 { margin: 0; font-size: 22px; }
.tool-card label { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; }
.tool-input { font: inherit; font-size: 16px; padding: 10px 12px; border-radius: 12px; border: 1px solid var(--line); background: transparent; color: inherit; }
.tool-result { font-size: 20px; font-weight: 700; margin: 0; }
.tool-note { margin: 0; font-size: 14px; opacity: .75; }
.tool-cta { margin-top: 32px; border-radius: 18px; padding: 24px; background: var(--fg, #0A0A0A); color: var(--bg, #fff); display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.tool-cta h2 { margin: 0; }
.tool-cta .btn { background: var(--bg, #fff); color: var(--fg, #0A0A0A); }
.tool-cta .btn-ghost { background: transparent; color: inherit; border-color: currentColor; }
.live-big { font-size: clamp(56px, 18vw, 120px); font-weight: 700; margin: 8px 0; line-height: 1; font-family: var(--font-display, inherit); }
.live-label { font-size: 20px; font-weight: 500; opacity: .7; }
