/* netkittools.studio — one stylesheet for every page.
   Built from the "Modernist" design system in design_handoff_netkit_tools/_ds/:
   one typeface (Archivo), a single red accent on an off-white ground, zero corner
   radius, 2px rules between sections, everything flush left. The token values match
   the iOS app's theme, so change both together. */

/* Archivo, self-hosted (latin subset, variable weight 400–800) so no visitor IP goes
   to Google and the CSP can stay font-src 'self'. Licence: /fonts/Archivo-OFL.txt */
@font-face {
  font-family: "Archivo";
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url("/fonts/archivo.woff2") format("woff2");
}

:root {
  --color-bg: #f3f2f2;
  --color-surface: #eae9e9;
  --color-text: #201e1d;
  /* The design's red is #ec3013, but white text on it is only 4.2:1. The site uses
     the next step down, #dd2b0f (4.7:1 with white), as its accent. Red text at body
     size on the light ground uses accent-700 (6.4:1); accent itself is 4.25:1 there,
     so it's kept for fills, large type and graphics. The app icon keeps #ec3013. */
  --color-accent: #dd2b0f;
  --color-accent-400: #ff9783;
  --color-accent-700: #ae1800;
  --color-accent-800: #7c1405;
  --color-divider: color-mix(in srgb, #201e1d 40%, transparent);
  --color-divider-on-red: color-mix(in srgb, #fff 45%, transparent);
  --color-neutral-700: #605d5d;
  --color-neutral-800: #444141;

  --font: "Archivo", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: clamp(20px, 4vw, 48px);
  --rule: 2px solid var(--color-divider);
  --rule-thin: 1px solid var(--color-divider);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
}

h1, h2, h3, h4 {
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0;
}

p { margin: 0; }
img, svg { display: block; max-width: 100%; }

a { color: var(--color-accent-700); text-underline-offset: 3px; }
a:hover { color: var(--color-accent-800); }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }
::selection { background: color-mix(in srgb, var(--color-accent) 30%, transparent); }

.num, .tabular { font-variant-numeric: tabular-nums; }

.skip {
  position: absolute; left: var(--gutter); top: -100px; z-index: 10;
  background: var(--color-text); color: var(--color-bg);
  padding: 10px 16px; font-weight: 600;
}
.skip:focus { top: 12px; color: var(--color-bg); }

.kicker {
  display: block;
  font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
}
.kicker-accent { color: var(--color-accent-700); }
.kicker-muted { color: var(--color-neutral-700); font-weight: 400; }

/* The brand motif: tool numbers 01–08 in red (accent-700: small text, see :root). */
.num {
  font-size: 13px; font-weight: 800; color: var(--color-accent-700);
}

/* ── Header: red field. The nav sits on it; the hero continues it. ────────────── */

.site-head { background: var(--color-accent); color: #fff; }
.site-head a { color: #fff; }
.site-head a:hover { color: #fff; text-decoration-thickness: 2px; }
.site-head :focus-visible { outline-color: #fff; }

.nav {
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 32px;
  padding: 20px var(--gutter);
  border-bottom: 2px solid var(--color-divider-on-red);
}
.nav a { font-size: 15px; font-weight: 600; }
.nav a[aria-current="page"] { text-decoration: underline; }
.nav .brand {
  display: flex; align-items: center; gap: 10px; margin-right: auto;
  font-size: 18px; font-weight: 800; text-decoration: none;
}
.nav .brand svg { width: 28px; height: 28px; flex: none; }

.hero {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr));
  gap: 40px 48px; align-items: end;
  padding: clamp(56px, 8vw, 96px) var(--gutter) clamp(48px, 6vw, 72px);
}
.hero-title { display: flex; flex-direction: column; gap: 20px; grid-column: span 2; min-width: 0; }
.hero h1 {
  font-size: clamp(56px, 10vw, 128px); line-height: 0.92; letter-spacing: -0.04em; color: #fff;
}
.hero-side { display: flex; flex-direction: column; gap: 20px; align-items: flex-start; }
.hero-side p { font-size: 18px; text-wrap: pretty; }

/* A single-column grid can't span 2; let the title fall back to one column. */
@media (max-width: 719px) { .hero-title { grid-column: auto; } }

.page-hero {
  display: flex; flex-direction: column; gap: 16px;
  padding: clamp(48px, 6vw, 80px) var(--gutter) 48px;
}
.page-hero h1 {
  font-size: clamp(48px, 8vw, 96px); line-height: 0.95; letter-spacing: -0.04em; color: #fff;
}
.page-hero p { font-size: 18px; max-width: 560px; text-wrap: pretty; }
.page-hero p.small { font-size: 16px; }

/* ── Buttons: flush-left labels, square corners. ─────────────────────────────── */

.btn {
  display: inline-flex; align-items: center; justify-content: flex-start;
  font-family: var(--font); font-weight: 800; font-size: 16px; line-height: 1.2;
  text-decoration: none; border: 2px solid transparent; border-radius: 0;
  padding: 12px 20px; min-height: 44px; cursor: pointer;
}
.site-head .btn:hover { text-decoration: none; }
.btn-outline-light { background: transparent; color: #fff; border-color: #fff; }
.btn-outline-light:hover { background: color-mix(in srgb, #fff 14%, transparent); }

/* ── Sections ────────────────────────────────────────────────────────────────── */

.section {
  padding: 56px var(--gutter);
  border-bottom: var(--rule);
  display: flex; flex-direction: column; gap: 24px;
}
.section:last-of-type { border-bottom: 0; }
.section h2 { font-size: clamp(32px, 4vw, 48px); }
.section h2.h2-sm { font-size: clamp(28px, 3.5vw, 40px); }

.section-head {
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 12px;
}
.section-head p { font-size: 15px; color: var(--color-neutral-700); }

/* A grid of numbered cells under a 2px rule: tools, common fixes. */
.cells {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr));
  border-top: var(--rule);
  margin: 0; padding: 0; list-style: none;
}
.cells.cells-wide { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.cell {
  display: flex; flex-direction: column; gap: 8px;
  padding: 24px 24px 32px 0;
  border-bottom: var(--rule-thin);
}
.cell h3 { font-size: 24px; letter-spacing: -0.015em; }
.cells-wide .cell h3 { font-size: 19px; }
.cell p { font-size: 15px; color: var(--color-neutral-800); text-wrap: pretty; }
.cell .use { font-size: 13px; color: var(--color-neutral-700); }
.cell.later h3, .cell.later p { color: var(--color-neutral-700); }

.tag {
  align-self: flex-start;
  font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 3px 8px; border: 1px solid var(--color-accent-700); color: var(--color-accent-700);
}

/* ── The NetKit pair: light half and ink half. ───────────────────────────────── */

.pair {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  border-bottom: var(--rule);
}
.pair > div {
  display: flex; flex-direction: column; gap: 12px;
  padding: clamp(40px, 5vw, 64px) var(--gutter);
}
.pair .name { font-size: clamp(32px, 4vw, 48px); font-weight: 800; line-height: 1.02; letter-spacing: -0.015em; }
.pair p { font-size: 17px; max-width: 480px; color: var(--color-neutral-800); text-wrap: pretty; }
.pair .ink { background: var(--color-text); color: var(--color-bg); }
.pair .ink .kicker { color: var(--color-accent-400); }
.pair .ink p { color: var(--color-bg); }
.pair .ink a { color: var(--color-bg); font-weight: 800; margin-top: 8px; }
.pair .ink a:hover { color: var(--color-accent-400); }
.pair .ink :focus-visible { outline-color: var(--color-accent-400); }

/* ── Pricing ─────────────────────────────────────────────────────────────────── */

.plans {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  border-top: var(--rule);
}
.plan {
  display: flex; flex-direction: column; gap: 8px;
  padding: 28px 28px 32px;
  border-bottom: var(--rule-thin); border-right: var(--rule-thin);
}
.plan .plan-name { font-size: 28px; font-weight: 800; line-height: 1.12; }
.plan .price { font-size: 40px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.plan p { font-size: 15px; text-wrap: pretty; }
.plan-feature { background: var(--color-accent); color: #fff; border-right: 0; }
.note { font-size: 14px; color: var(--color-neutral-700); }

/* ── Key/value list: privacy summary. ────────────────────────────────────────── */

.split {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr));
  gap: 24px 48px;
}
.split-intro { display: flex; flex-direction: column; gap: 16px; align-items: flex-start; }
.split-intro a { font-weight: 800; }

.kv { margin: 0; border-top: var(--rule); }
.kv div {
  display: grid; grid-template-columns: minmax(0, 160px) minmax(0, 1fr); gap: 16px;
  padding: 14px 0; border-bottom: var(--rule-thin); font-size: 15px;
}
.kv dt { font-weight: 600; }
.kv dd { margin: 0; color: var(--color-neutral-800); text-wrap: pretty; }

/* ── FAQ ─────────────────────────────────────────────────────────────────────── */

.faq { border-top: var(--rule); max-width: 880px; }
.faq details { border-bottom: var(--rule-thin); }
.faq summary {
  display: grid; grid-template-columns: 40px 1fr auto; gap: 8px;
  padding: 18px 0; font-size: 18px; font-weight: 600;
  list-style: none; cursor: pointer;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary .num { padding-top: 4px; }
.faq summary .plus { color: var(--color-accent); font-weight: 800; }
.faq details[open] .plus { transform: rotate(45deg); }
.faq details p {
  margin: 0 0 20px 48px; max-width: 680px;
  font-size: 16px; color: var(--color-neutral-800); text-wrap: pretty;
}

/* ── Details strip ───────────────────────────────────────────────────────────── */

.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  border-top: var(--rule); margin: 0;
}
.facts div {
  display: flex; flex-direction: column; gap: 4px;
  padding: 16px 16px 20px 0; border-bottom: var(--rule-thin);
}
.facts dt { font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-neutral-700); }
.facts dd { margin: 0; font-size: 17px; font-weight: 600; overflow-wrap: anywhere; }

/* ── Support ─────────────────────────────────────────────────────────────────── */

.contact { display: flex; flex-direction: column; gap: 8px; }
.contact .email {
  font-size: clamp(24px, 3vw, 36px); font-weight: 800; color: var(--color-text);
  overflow-wrap: anywhere; line-height: 1.2;
}
.contact .email:hover { color: var(--color-accent-700); }
.contact p { font-size: 15px; color: var(--color-neutral-700); }

.checklist { display: flex; flex-direction: column; gap: 10px; border-top: var(--rule); padding-top: 16px; }
.checklist h2 { font-size: 17px; letter-spacing: 0; }
.checklist ol { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.checklist li {
  display: grid; grid-template-columns: 32px 1fr;
  padding: 6px 0; border-bottom: var(--rule-thin); font-size: 15px;
  counter-increment: step;
}
.checklist li::before {
  content: counter(step, decimal-leading-zero);
  font-weight: 800; color: var(--color-accent-700); font-variant-numeric: tabular-nums;
}

/* ── Policy pages: summary table and numbered sections. ──────────────────────── */

.table-scroll { max-width: 960px; overflow-x: auto; }
.table { width: 100%; min-width: 560px; border-collapse: collapse; font-size: 15px; }
.table th {
  text-align: left; font-size: 11px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--color-neutral-700);
  padding: 8px; border-bottom: var(--rule);
}
.table td { padding: 8px; border-bottom: var(--rule-thin); vertical-align: top; }
.table td:first-child { font-weight: 600; }
.table td:last-child { color: var(--color-neutral-700); }
.table th:first-child, .table td:first-child { padding-left: 0; }

.clauses {
  padding: 48px var(--gutter) 64px;
  max-width: calc(880px + 2 * var(--gutter));
}
.clauses > p { font-size: 16px; line-height: 1.6; color: var(--color-neutral-800); padding-bottom: 24px; }
.clause {
  display: grid; grid-template-columns: 48px minmax(0, 1fr); gap: 8px;
  padding: 24px 0; border-top: var(--rule);
}
.clause > .num { font-size: 14px; padding-top: 6px; }
.clause-body { display: flex; flex-direction: column; gap: 10px; }
.clause h2 { font-size: 22px; }
.clause h3 { font-size: 17px; letter-spacing: 0; margin-top: 6px; }
.clause p, .clause li { font-size: 16px; line-height: 1.6; color: var(--color-neutral-800); text-wrap: pretty; }
.clause ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; }

/* A fact still missing before launch. CI fails while any [bracketed] one remains. */
mark.fill { background: var(--color-accent-400); color: var(--color-text); padding: 0 4px; }

/* ── Footer: ink. ────────────────────────────────────────────────────────────── */

.site-foot {
  background: var(--color-text); color: var(--color-bg);
  padding: 40px var(--gutter);
  display: flex; flex-wrap: wrap; gap: 24px 48px; justify-content: space-between; align-items: flex-start;
}
.site-foot a { color: var(--color-bg); }
.site-foot a:hover { color: var(--color-accent-400); }
.site-foot :focus-visible { outline-color: var(--color-accent-400); }
.foot-id { display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.foot-id .foot-name { font-weight: 800; font-size: 16px; }
.foot-id .foot-legal { opacity: 0.7; }
.foot-links { display: flex; flex-wrap: wrap; gap: 12px 24px; font-size: 14px; font-weight: 600; }
.foot-links a { padding: 4px 0; }

@media (prefers-reduced-motion: no-preference) {
  .faq .plus { transition: transform 0.15s ease; }
}

/* Hostnames and file names inside policy text. */
code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 0.92em; overflow-wrap: anywhere; }
