/* Clawform — clawform.thejoseki.com
 *
 * Ported from the Clawform Design System (templates/marketing-home). That
 * source is a design-tool document: every rule lives in a style attribute and
 * two runtime scripts assemble it. Neither belongs on a production page, so
 * the styling moved here and the runtime went away — the page makes no
 * external request and runs no JavaScript.
 *
 * Marketing palette: near-black canvas, white counter-sections, one saturated
 * orange doing all the pointing. This is deliberately NOT the product's slate
 * palette — that one still governs the terminal blocks below, where red means
 * blocked and amber means warned and neither may be spent on decoration.
 *
 * The one rule that is easy to break: orange NEVER carries white text. White
 * on #FF9900 measures 2.14:1 and fails everything. Orange fills carry black
 * labels; orange TEXT only appears on ink, or as --mk-orange-deep on paper.
 */

/* ── Tokens ─────────────────────────────────────────────────────────────── */

:root {
  /* Ink — the default canvas */
  --mk-ink:        #0A0A0B;
  --mk-ink-2:      #121214;
  --mk-ink-3:      #1C1C20;
  --mk-line:       #2A2A30;
  --mk-line-2:     #3A3A44;

  /* Paper — the counter-sections */
  --mk-paper:      #FFFFFF;
  --mk-paper-2:    #F7F6F4;
  --mk-paper-line: #E4E2DE;

  /* Orange — one hue, four jobs */
  --mk-orange:      #FF9900;  /* 9.24:1 on ink, both directions */
  --mk-orange-hi:   #FFAD33;
  --mk-orange-deep: #B45309;  /* 5.02:1 on paper — the only orange for text there */
  --mk-orange-tint: #FFF4E5;
  --mk-orange-edge: #F3DDB8;

  /* Text */
  --mk-on-ink:          #E9E9EC;  /* 16.33:1 on ink */
  --mk-on-ink-strong:   #FFFFFF;
  --mk-on-ink-muted:    #9A9AA5;  /*  7.11:1 on ink, 6.72:1 on ink-2 */
  --mk-on-paper:        #17171A;
  --mk-on-paper-muted:  #5A5A64;  /*  6.82:1 on paper, 6.31:1 on paper-2 */

  /* Terminal — the product palette, unchanged. Never theme these. */
  --term-bg:      #0F172A;
  --term-fg:      #E2E8F0;  /* 14.48:1 */
  --term-dim:     #94A3B8;  /*  6.96:1 */
  --term-bright:  #FFFFFF;
  --term-blocked: #F87171;  /*  6.45:1 */
  --term-warned:  #FBBF24;  /* 10.69:1 */

  /* Type. No webfont — the page makes no external request, so the type is
   * whatever the reader's machine already has. */
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas,
          "Liberation Mono", monospace;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue",
          Arial, sans-serif;

  /* Geometry */
  --r-sm: 4px;
  --r-md: 8px;
  --r-lg: 12px;
  --container: 1200px;
  --gutter: 24px;
  --band: 96px;

  /* Background motifs. Compose, never restyle: a 1px grid on 64px for the
   * "infrastructure" plane, and one orange radial. No mesh gradients, no
   * blobs, no illustration. */
  --grid-size: 64px;
  --grid-line: rgba(255, 255, 255, 0.045);
  --grid-line-paper: rgba(10, 10, 11, 0.055);
  --glow: rgba(255, 153, 0, 0.15);
}

/* The two geometry tokens tighten with the viewport, so every surface built on
 * them reflows without needing its own query. */
@media (max-width: 1024px) {
  :root { --band: 72px; --container: 100%; }
}
@media (max-width: 640px) {
  :root { --band: 56px; --gutter: 18px; --grid-size: 40px; }
}

/* ── Base ───────────────────────────────────────────────────────────────── */

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

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

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  background: var(--mk-ink);
  color: var(--mk-on-ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  /* Wide things scroll inside their own box; the page never does. */
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
h1, h2, h3 { font-family: var(--sans); text-wrap: balance; margin: 0; }
p { margin: 0; text-wrap: pretty; }
ul { margin: 0; padding: 0; list-style: none; }

/* Never removed. Keyboard users are a real part of this audience, and the
 * source design had no focus styling at all. */
:focus-visible {
  outline: 2px solid var(--mk-orange);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}
.band-paper :focus-visible,
.band-paper-2 :focus-visible,
.cta :focus-visible {
  outline-color: var(--mk-on-paper);
}

.skip {
  position: absolute;
  left: -9999px;
  font-family: var(--mono);
  font-size: 14px;
}
.skip:focus {
  left: var(--gutter);
  top: 12px;
  z-index: 60;
  background: var(--mk-orange);
  color: var(--mk-ink);
  padding: 10px 16px;
  border-radius: var(--r-md);
}

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ── Shared type ────────────────────────────────────────────────────────── */

.eyebrow {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mk-orange);
  margin-bottom: 16px;
}
.eyebrow-deep { color: var(--mk-orange-deep); }

h2 {
  font-size: clamp(1.9rem, 3vw, 2.6rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--mk-on-ink-strong);
  margin-bottom: 18px;
}
.band-paper h2, .band-paper-2 h2 { color: var(--mk-on-paper); }
h2.tight { max-width: 22ch; }
h2.mb-lg { margin-bottom: 40px; }

.section-lead {
  font-size: 17px;
  line-height: 1.6;
  color: var(--mk-on-ink-muted);
  margin-bottom: 44px;
  max-width: 62ch;
}
.band-paper .section-lead, .band-paper-2 .section-lead { color: var(--mk-on-paper-muted); }
.section-lead.narrow { max-width: 56ch; margin-bottom: 16px; }
.section-lead.small { font-size: 15px; margin-bottom: 0; max-width: 52ch; }

.note {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--mk-on-ink-muted);
  margin-top: 18px;
}
.note-center { text-align: center; margin-top: 12px; }
.band-paper .note { color: var(--mk-on-paper-muted); }

.kicker {
  font-family: var(--mono);
  font-size: 15px;
  color: var(--mk-on-ink-strong);
}

code {
  font-family: var(--mono);
  font-size: 0.9em;
}

/* ── Buttons ────────────────────────────────────────────────────────────── */

.btn {
  display: inline-block;
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 15px 24px;
  border-radius: var(--r-md);
  transition: background-color 150ms ease-out, color 150ms ease-out;
}
/* Black label on orange, always: white would be 2.14:1. */
.btn-orange { background: var(--mk-orange); color: var(--mk-ink); }
.btn-orange:hover { background: var(--mk-orange-hi); }

.btn-ghost { border: 1px solid var(--mk-line-2); color: var(--mk-on-ink); padding: 14px 22px; }
.btn-ghost:hover { border-color: var(--mk-on-ink-muted); }

.btn-ink { background: var(--mk-ink); color: var(--mk-paper); font-size: 15px; padding: 17px 28px; }
.btn-ink:hover { background: var(--mk-ink-3); }

.btn-sm { font-size: 13px; padding: 11px 18px; }
.btn-block { display: block; text-align: center; font-size: 14px; padding: 15px 20px; }

/* ── Header ─────────────────────────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(10, 10, 11, 0.88);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--mk-line);
}
.header-inner {
  height: 68px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.wordmark {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
}
.wordmark span {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mk-on-ink-strong);
}
.wordmark img { border-radius: 6px; }

.site-nav {
  display: flex;
  align-items: center;
  gap: 24px;
  min-width: 0;
  overflow: hidden;
}
.site-nav a {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--mk-on-ink-muted);
  white-space: nowrap;
  transition: color 150ms ease-out;
}
.site-nav a:hover { color: var(--mk-on-ink-strong); }

.header-cta { margin-left: auto; flex: 0 0 auto; white-space: nowrap; }

/* ── Background motifs ──────────────────────────────────────────────────── */

.bg-grid, .bg-glow { position: absolute; pointer-events: none; }

.bg-grid {
  inset: 0;
  background-image:
    linear-gradient(to right, var(--grid-line) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line) 1px, transparent 1px);
  background-size: var(--grid-size) var(--grid-size);
  -webkit-mask-image: radial-gradient(115% 85% at 50% 0%, #000 25%, transparent 78%);
          mask-image: radial-gradient(115% 85% at 50% 0%, #000 25%, transparent 78%);
}
/* Vertical rules only, fading downward. */
.bg-grid-v {
  background-image: linear-gradient(to right, var(--grid-line) 1px, transparent 1px);
  background-size: var(--grid-size) 100%;
  -webkit-mask-image: linear-gradient(to bottom, #000, transparent 85%);
          mask-image: linear-gradient(to bottom, #000, transparent 85%);
}
.bg-grid-paper {
  background-image:
    linear-gradient(to right, var(--grid-line-paper) 1px, transparent 1px),
    linear-gradient(to bottom, var(--grid-line-paper) 1px, transparent 1px);
  -webkit-mask-image: radial-gradient(100% 70% at 50% 0%, #000 20%, transparent 80%);
          mask-image: radial-gradient(100% 70% at 50% 0%, #000 20%, transparent 80%);
}

.bg-glow {
  top: -220px;
  left: 50%;
  transform: translateX(-50%);
  width: 1000px;
  height: 600px;
  background: radial-gradient(50% 50% at 50% 50%, var(--glow), rgba(255, 90, 31, 0) 70%);
}

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

.hero, .band { position: relative; overflow: hidden; }
.hero { border-bottom: 1px solid var(--mk-line); }

.band > .container { position: relative; }
.band { padding-block: var(--band); }
.band-ink { border-bottom: 1px solid var(--mk-line); }
.band-paper { background: var(--mk-paper); color: var(--mk-on-paper); }
.band-paper-2 { background: var(--mk-paper-2); color: var(--mk-on-paper); }
.band.bordered { border-top: 1px solid var(--mk-paper-line); }
.band.split { border-top: 1px solid var(--mk-line); }

.hero-inner {
  position: relative;
  padding-block: 84px 92px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 56px;
  align-items: center;
}

.split-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 56px;
  align-items: center;
}
.split-start { align-items: start; gap: 48px; }

/* ── Hero content ───────────────────────────────────────────────────────── */

.pill {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid var(--mk-line-2);
  border-radius: 999px;
  padding: 6px 14px 6px 11px;
  margin-bottom: 26px;
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mk-on-ink-muted);
}
.pill-dot { width: 6px; height: 6px; background: var(--mk-orange); display: block; }

h1 {
  font-size: clamp(2.4rem, 4.6vw, 3.7rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -0.035em;
  color: var(--mk-on-ink-strong);
  margin-bottom: 22px;
}
h1 em { color: var(--mk-orange); font-style: normal; }

.lead {
  font-size: 19px;
  line-height: 1.55;
  color: var(--mk-on-ink-muted);
  margin-bottom: 32px;
  max-width: 52ch;
}

.actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }

/* ── Terminal ───────────────────────────────────────────────────────────── */

.term {
  margin: 0;
  background: var(--term-bg);
  border: 1px solid var(--mk-line-2);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.hero .term { box-shadow: 0 40px 80px -40px rgba(0, 0, 0, 0.9); }

.term-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 11px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}
.dot { width: 9px; height: 9px; border-radius: 2px; background: #3A3A44; display: block; }
.dot-live { background: var(--mk-orange); }
.dot-warn { background: var(--term-warned); }
.term-title {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--term-dim);
  margin-left: 6px;
}

.term pre {
  margin: 0;
  padding: 20px;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.6;
  color: var(--term-fg);
  /* No wrapping: wrapped terminal output stops looking like terminal output.
   * The box scrolls instead, and tabindex makes that reachable by keyboard. */
  white-space: pre;
  overflow-x: auto;
}
.term .dim { color: var(--term-dim); }
.term .bright { color: var(--term-bright); }
/* Status is never colour alone — each carries a glyph and the "[clawform hook]"
 * label. ✕ (U+2715) has no emoji presentation; ⚠ (U+26A0) does, which is why
 * the warned state uses a plain "!". */
.term .blocked { color: var(--term-blocked); font-weight: 700; }
.term .warned { color: var(--term-warned); font-weight: 700; }

/* ── Stats ──────────────────────────────────────────────────────────────── */

.stats { background: var(--mk-ink-2); border-bottom: 1px solid var(--mk-line); }
.stats-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
}
.stats-inner > div {
  padding: 34px 28px;
  border-right: 1px solid var(--mk-line);
}
.stats-inner > div:first-child { padding-left: 0; }
.stats-inner > div:last-child { padding-right: 0; border-right: 0; }

.stat-n {
  display: block;
  font-family: var(--mono);
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--mk-orange);
}
.stat-l {
  display: block;
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--mk-on-ink-muted);
  margin-top: 6px;
}

/* ── Grids and cards ────────────────────────────────────────────────────── */

.grid { display: grid; }
/* 260, not the design's 280. The container is 1200 with 24px gutters, so four
 * columns need a minimum of (1152 - 3×20) / 4 = 273px. At 280 the row breaks
 * to three and a section titled "Four mistakes" renders as 3 + 1. */
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 20px; }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); gap: 24px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: 24px; }

.card {
  background: var(--mk-ink-2);
  border: 1px solid var(--mk-line);
  border-radius: var(--r-lg);
  padding: 26px;
}
.card-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.card-head .x { font-family: var(--mono); font-size: 14px; font-weight: 700; color: var(--mk-orange); }
.card-head code {
  font-size: 14px;
  color: var(--mk-on-ink-strong);
  background: var(--mk-ink-3);
  padding: 3px 7px;
  border-radius: var(--r-sm);
}
.card-sub { font-family: var(--mono); font-size: 14px; color: var(--mk-on-ink); margin-bottom: 10px; }
.card-body { font-size: 15px; line-height: 1.55; color: var(--mk-on-ink-muted); }

.layer {
  border: 1px solid var(--mk-paper-line);
  border-top: 3px solid var(--mk-orange);
  border-radius: var(--r-lg);
  background: var(--mk-paper);
  padding: 28px;
}
.layer-n {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  color: var(--mk-orange-deep);
  margin-bottom: 14px;
}
.layer h3 {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--mk-on-paper);
  margin-bottom: 10px;
}
.layer p { font-size: 15px; line-height: 1.6; color: var(--mk-on-paper-muted); }

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }
.chips li {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--mk-on-paper-muted);
  border: 1px solid var(--mk-paper-line);
  border-radius: 999px;
  padding: 7px 13px;
}

.fit {
  background: var(--mk-paper);
  border: 1px solid var(--mk-paper-line);
  border-left: 3px solid var(--mk-on-paper);
  border-radius: var(--r-lg);
  padding: 28px;
}
.fit p:last-child { font-size: 17px; line-height: 1.6; color: var(--mk-on-paper); }
.fit-label {
  font-family: var(--mono);
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--mk-on-paper-muted);
  margin-bottom: 12px;
}
/* Disqualifying is a service to the reader, so it carries the same weight as
 * qualifying — not a footnote. */
.fit-no {
  background: var(--mk-orange-tint);
  border-color: var(--mk-orange-edge);
  border-left-color: var(--mk-orange);
}
.fit-no .fit-label { color: var(--mk-orange-deep); }

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

.price {
  border: 1px solid var(--mk-on-paper);
  border-radius: var(--r-lg);
  overflow: hidden;
  background: var(--mk-paper);
}
.price-head {
  background: var(--mk-orange);
  color: var(--mk-ink);
  padding: 14px 26px;
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.price-body { padding: 28px 26px; }
.price-figure {
  font-family: var(--mono);
  font-size: 38px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--mk-on-paper);
  margin-bottom: 20px;
}
.price-list { display: grid; gap: 11px; margin-bottom: 26px; }
.price-list li {
  display: flex;
  gap: 11px;
  align-items: flex-start;
  font-size: 15px;
  line-height: 1.6;
  color: var(--mk-on-paper);
}
.price-list li::before {
  content: "→";
  font-family: var(--mono);
  font-size: 13px;
  color: var(--mk-orange-deep);
  flex: 0 0 auto;
}
.price-list code {
  font-size: 13px;
  background: var(--mk-paper-2);
  padding: 2px 6px;
  border-radius: var(--r-sm);
}

/* ── CTA band ───────────────────────────────────────────────────────────── */

.cta { background: var(--mk-orange); color: var(--mk-ink); }
.cta-inner {
  padding-block: 72px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 32px;
  align-items: center;
}
.cta h2 {
  font-size: clamp(1.7rem, 2.6vw, 2.3rem);
  color: var(--mk-ink);
  margin-bottom: 10px;
}
/* 4.99:1 on orange — the lightest this text may go. */
.cta p { font-size: 17px; line-height: 1.55; color: rgba(10, 10, 11, 0.78); max-width: 48ch; }
.cta-action { justify-self: end; }

/* ── Footer ─────────────────────────────────────────────────────────────── */

.site-footer { background: var(--mk-ink); border-top: 1px solid var(--mk-line); }
.footer-cols {
  padding-block: 64px 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(45%, 200px), 1fr));
  gap: 40px;
}
.footer-cols .wordmark { margin-bottom: 14px; }
.footer-cols .wordmark span { font-size: 13px; }
.footer-blurb { font-size: 14px; line-height: 1.6; color: var(--mk-on-ink-muted); max-width: 30ch; }

.footer-h {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--mk-on-ink-muted);
  margin-bottom: 14px;
}
.footer-cols nav { display: grid; align-content: start; gap: 9px; }
.footer-cols nav a {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--mk-on-ink);
  transition: color 150ms ease-out;
}
.footer-cols nav a:hover { color: var(--mk-orange); }

.footer-legal {
  padding-block: 22px 44px;
  border-top: 1px solid var(--mk-line);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}
.footer-legal p { font-size: 12px; line-height: 1.6; color: var(--mk-on-ink-muted); max-width: 70ch; }
.colophon {
  font-family: var(--mono);
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

/* ── Responsive ─────────────────────────────────────────────────────────── */

@media (max-width: 1024px) {
  .site-nav a:nth-child(3), .site-nav a:nth-child(4) { display: none; }
  .stats-inner > div {
    border-right: 0;
    border-bottom: 1px solid var(--mk-line);
    padding-inline: 0;
  }
  .stats-inner > div:last-child { border-bottom: 0; }
}

@media (max-width: 820px) {
  .site-nav { display: none; }
  .cta-action { justify-self: start; }
}

@media (max-width: 640px) {
  h1 { font-size: 2.15rem; }
  .hero-inner { padding-block: 56px 60px; gap: 36px; }
  .term pre { font-size: 12px; padding: 16px; }
  .footer-cols { gap: 28px; }
}
