/* Same design system as the Umbra landing (tokens from umbra-frontend): neutral oklch
   greys, one orange accent. Source Serif 4 for headlines, ZT Nature for text, Geist Mono
   for labels. Own product, own components below the shared ones. */

@font-face {
  font-family: 'ZT Nature';
  src: url('../assets/fonts/ZT-Nature-Variable.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Source Serif 4';
  src: url('../assets/fonts/SourceSerif4-Variable.woff2') format('woff2');
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Source Serif 4';
  src: url('../assets/fonts/SourceSerif4-Italic-Variable.woff2') format('woff2');
  font-weight: 200 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Geist Mono';
  src: url('../assets/fonts/GeistMono-Variable.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: oklch(0.9911 0 0);
  --panel: oklch(0.9702 0 0);
  --ink: oklch(0.269 0 0);
  --ink2: oklch(0.36 0 0);
  --muted: oklch(0.4386 0 0);
  --rule: oklch(0.9189 0 0);
  --rule2: oklch(0.86 0 0);
  --accent: #d88d26;
  --accent-ink: oklch(0.15 0 0);
  --accent-soft: color-mix(in oklch, var(--accent) 14%, transparent);
  --hl: color-mix(in oklch, var(--accent) 35%, transparent);
  --serif: 'Source Serif 4', Georgia, serif;
  --sans: 'ZT Nature', ui-sans-serif, system-ui, sans-serif;
  --mono: 'Geist Mono', ui-monospace, monospace;
  --radius: 0.35rem;
  --column: 46rem;
  --wide: 66rem;
  --gutter: 1.5rem;

  /* Typography Scale */
  --text-micro: 0.65rem;
  --text-xs: 0.75rem;
  --text-sm: 0.875rem;
  --text-base: 1rem;
  --text-lg: 1.15rem;
  --text-xl: 1.5rem;
  --text-2xl: clamp(2.4rem, 5vw, 3.4rem);
  --text-3xl: clamp(3.6rem, 9vw, 5.8rem);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme='light']) {
    color-scheme: dark;
    --paper: oklch(0.1 0 0);
    --panel: oklch(0.15 0 0);
    --ink: oklch(0.97 0 0);
    --ink2: oklch(0.85 0 0);
    --muted: oklch(0.66 0 0);
    --rule: oklch(0.252 0 0);
    --rule2: oklch(0.32 0 0);
    --accent: #e8a445;
  }
}
:root[data-theme='dark'] {
  color-scheme: dark;
  --paper: oklch(0.1 0 0);
  --panel: oklch(0.15 0 0);
  --ink: oklch(0.97 0 0);
  --ink2: oklch(0.85 0 0);
  --muted: oklch(0.66 0 0);
  --rule: oklch(0.252 0 0);
  --rule2: oklch(0.32 0 0);
  --accent: #e8a445;
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  text-rendering: geometricPrecision;
}

a {
  color: inherit;
}

::selection {
  background: var(--hl);
}

code {
  font-family: var(--mono);
  font-size: var(--text-sm);
  background: var(--accent-soft);
  padding: 0.1em 0.35em;
  border-radius: var(--radius);
}

/* ---------- shared pieces ---------- */

.column {
  max-width: var(--column);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.label {
  font-family: var(--mono);
  font-size: var(--text-xs);
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.column > .label,
.hero .label,
.manifesto .label {
  display: block;
  font-family: var(--mono);
  font-size: var(--text-xs);
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.75rem;
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-optical-sizing: auto;
  font-weight: 560;
  letter-spacing: -0.02em;
  color: var(--ink);
  text-wrap: balance;
}

h1 {
  font-size: var(--text-3xl);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin-bottom: 1.75rem;
}

h2 {
  font-size: var(--text-2xl);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: 1.75rem;
}

h3 {
  font-size: var(--text-xl);
  line-height: 1.25;
  letter-spacing: -0.015em;
  margin-bottom: 0.9rem;
}

p {
  font-size: var(--text-base);
  line-height: 1.65;
}

.prose p {
  font-size: var(--text-base);
  color: var(--ink2);
}
.prose p + p {
  margin-top: 1em;
}
.prose em {
  font-style: normal;
  color: var(--ink);
  box-shadow: inset 0 -0.45em 0 var(--accent-soft);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.8rem;
  border: 1px solid var(--rule2);
  border-radius: var(--radius);
  background: transparent;
  color: var(--ink);
  font-family: var(--mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background 0.2s ease-out, border-color 0.2s ease-out, color 0.2s ease-out;
}
.btn:hover,
.btn:focus-visible {
  border-color: var(--accent);
  background: var(--accent);
  color: var(--accent-ink);
}
.btn--large {
  padding: 0.9rem 1.4rem;
  font-size: var(--text-xs);
}
.btn--solid {
  border-color: var(--ink);
  background: var(--ink);
  color: var(--paper);
}

/* A margin note: 2px accent border on the panel colour. */
.note {
  margin-top: 1.5rem;
  padding: 1rem 1.25rem;
  border-left: 2px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--panel);
  max-width: 34rem;
}
.note + .note {
  margin-top: 0.75rem;
}
.note .label {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--accent);
}
.note p {
  color: var(--ink);
  font-size: var(--text-sm);
  line-height: 1.6;
}

/* ---------- header ---------- */

.site-head {
  position: sticky;
  top: 0;
  z-index: 10;
  height: 3.5rem;
  border-bottom: 1px solid var(--rule);
  background: color-mix(in oklch, var(--paper) 90%, transparent);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}
.site-head-inner {
  max-width: var(--wide);
  height: 100%;
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.nav-path {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--mono);
  font-size: var(--text-xs);
  color: var(--muted);
  text-decoration: none;
}
.nav-path .brand {
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.02em;
  font-size: 1.2rem;
  line-height: 1;
}
.nav-sep {
  opacity: 0.45;
}
.site-head .actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.theme-toggle {
  width: 2rem;
  height: 2rem;
  display: grid;
  place-items: center;
  border: 1px solid var(--rule2);
  border-radius: var(--radius);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
}
.theme-toggle:hover {
  color: var(--ink);
  border-color: var(--ink2);
}
.theme-toggle svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 1.5;
}
.icon-sun {
  display: none;
}
:root[data-theme='dark'] .icon-sun {
  display: block;
}
:root[data-theme='dark'] .icon-moon {
  display: none;
}

/* ---------- hero ---------- */

.hero {
  padding-top: max(7.5rem, calc(50dvh - 12rem));
  padding-bottom: clamp(6rem, 12vh, 9rem);
}
.hero h1 {
  font-size: var(--text-3xl);
  font-weight: 560;
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin-bottom: 1.75rem;
}
.hero h1 span {
  color: var(--accent);
  font-style: italic;
  font-weight: 500;
}
.lede {
  font-size: var(--text-lg);
  line-height: 1.6;
  color: var(--ink2);
  max-width: 36rem;
}
.hero-cta .label {
  margin: 0;
}
.hero-cta {
  margin-top: 2.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1rem 1.25rem;
}

/* ---------- sections ---------- */

.section {
  padding: 6rem 0;
  border-top: 1px solid var(--rule);
}
.section--panel {
  background: var(--panel);
}

.contrast {
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--rule2);
  border-radius: var(--radius);
  overflow: hidden;
}
.contrast > div {
  padding: 1.4rem 1.5rem;
  background: var(--paper);
}
.contrast > div + div {
  border-left: 1px solid var(--rule2);
  box-shadow: inset 0 2px 0 var(--accent);
}
.contrast .label {
  display: block;
  margin-bottom: 0.5rem;
}
.contrast .us .label {
  color: var(--accent);
}
.contrast p {
  font-size: var(--text-base);
  line-height: 1.5;
}
.contrast .them p {
  color: var(--muted);
}

/* ---------- closing ---------- */

.closing {
  text-align: center;
}
.closing .prose {
  max-width: 36rem;
  margin: 0 auto;
}
.closing-line {
  margin-top: 2.5rem;
  font-family: var(--mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
}
.closing .btn {
  margin-top: 1.25rem;
}

/* The send form: builds a mailto link, no backend. */
#send {
  scroll-margin-top: 3.5rem;
}
.send-form {
  max-width: 34rem;
  margin: 2.5rem auto 0;
  text-align: left;
}
.field {
  display: block;
  margin-bottom: 1.25rem;
  border: 0;
}
.field > label,
.field legend {
  display: block;
  margin-bottom: 0.4rem;
  font-family: var(--mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--ink2);
}
.field legend span {
  color: var(--muted);
}
.send-form textarea,
.send-form input[type='email'],
.send-form input[type='text'] {
  display: block;
  width: 100%;
  padding: 0.7rem 0.8rem;
  border: 1px solid var(--rule2);
  border-radius: var(--radius);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--text-base);
  line-height: 1.5;
}
.send-form textarea {
  resize: vertical;
  min-height: 7rem;
}
.send-form textarea:focus,
.send-form input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
  border-color: var(--accent);
}
.send-form ::placeholder {
  color: var(--muted);
  opacity: 0.8;
}
.closing .send-form .btn {
  margin-top: 0.25rem;
}
.form-note,
.form-done,
.form-error,
.form-fallback {
  font-size: var(--text-sm);
  color: var(--ink2);
}
.form-note {
  margin-top: 1rem;
}
.form-done,
.form-error {
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  border-left: 2px solid var(--accent);
  background: var(--paper);
  color: var(--ink);
}
.form-fallback {
  margin-top: 2rem;
  text-align: center;
}
.send-form [hidden] {
  display: none;
}

/* ---------- footer ---------- */

.site-foot {
  border-top: 1px solid var(--rule);
  padding: 2rem 0;
}
.site-foot-inner {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 var(--gutter);
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.site-foot .brand {
  font-family: var(--serif);
  font-weight: 600;
  letter-spacing: -0.02em;
  font-size: 1.1rem;
  color: var(--ink);
}

/* ---------- product pieces ---------- */

.hero-shot {
  max-width: var(--wide);
  margin: 0 auto;
  padding: 0 var(--gutter) 6rem;
}
.steps {
  list-style: none;
  counter-reset: step;
  margin-top: 0.5rem;
}
.steps li {
  display: grid;
  grid-template-columns: 4rem minmax(0, 1fr);
  padding: 2rem 0;
  border-top: 1px solid var(--rule);
}
.steps li:first-child {
  border-top: 0;
  padding-top: 0;
}
.steps li::before {
  counter-increment: step;
  content: '0' counter(step);
  font-family: var(--mono);
  font-size: var(--text-xs);
  color: var(--accent);
  padding-top: 0.45rem;
}
.steps h3 {
  margin-bottom: 0.5rem;
}
.steps p {
  color: var(--ink2);
}

.contrast-figure {
  display: block;
  margin-bottom: 0.6rem;
  font-family: var(--serif);
  font-size: var(--text-xl);
  font-weight: 560;
  letter-spacing: -0.015em;
  line-height: 1.2;
  color: var(--ink);
}
.contrast .them .contrast-figure {
  color: var(--muted);
}
.contrast .us .contrast-figure {
  color: var(--accent);
}

.example > div {
  display: grid;
  grid-template-columns: 8rem minmax(0, 1fr);
  gap: 1rem;
  padding: 1.25rem 0;
  border-top: 1px solid var(--rule2);
}
.example > div:first-child {
  border-top: 0;
  padding-top: 0;
}
.example dt {
  font-family: var(--mono);
  font-size: var(--text-xs);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent);
  padding-top: 0.25rem;
}
.example dd {
  color: var(--ink2);
}

/* The product mock: contextual.cc's panes (Umbra app-v3 tokens, PanelShell's spine with its
   vertical mono title, hairline cards on a grey desk). All drawn here, so it follows the theme. */
.mock {
  --m-desk: oklch(0.955 0 0);
  --m-card: oklch(1 0 0);
  --m-text: oklch(0.21 0 0);
  --m-muted: oklch(0.556 0 0);
  --m-border: oklch(0.922 0 0);
  --m-fill: oklch(0.97 0 0);
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: 0.6rem;
  padding: 0.6rem;
  border-radius: 0.9rem;
  background: var(--m-desk);
  box-shadow: 0 24px 60px -30px color-mix(in oklch, var(--ink) 35%, transparent);
}
:root[data-theme='dark'] .mock {
  --m-desk: oklch(0.125 0 0);
  --m-card: oklch(0.065 0 0);
  --m-text: oklch(0.97 0 0);
  --m-muted: oklch(0.6 0 0);
  --m-border: oklch(0.252 0 0);
  --m-fill: oklch(0.15 0 0);
}
.mock-pane {
  display: flex;
  min-width: 0;
  border: 1px solid var(--m-border);
  border-radius: 0.5rem;
  background: var(--m-card);
  color: var(--m-text);
  overflow: hidden;
}
.mock-spine {
  flex: none;
  width: 2.25rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 0;
  border-right: 1px solid var(--m-border);
}
.mock-spine-rule {
  width: 1.25rem;
  height: 1px;
  background: var(--m-border);
}
.mock-title {
  writing-mode: vertical-rl;
  font-family: var(--mono);
  font-size: var(--text-micro);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--m-muted);
}
.mock-body {
  flex: 1;
  min-width: 0;
  padding: clamp(1.25rem, 3vw, 2.5rem);
}
.mock-kicker {
  display: block;
  margin-bottom: 1rem;
  font-family: var(--mono);
  font-size: var(--text-micro);
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--m-muted);
}
.mock-kicker--accent {
  color: var(--accent);
}
.mock-link {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--m-border);
  border-radius: var(--radius);
  background: var(--m-fill);
  font-family: var(--mono);
  font-size: var(--text-xs);
}
.mock-link span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.mock-link svg {
  flex: none;
  width: 14px;
  height: 14px;
  fill: none;
  stroke: var(--m-muted);
  stroke-width: 1.6;
  stroke-linecap: round;
}
.mock-lines {
  list-style: none;
  margin: 1.5rem 0;
}
.mock-lines li {
  padding: 0.35rem 0;
}
.mock-lines i {
  display: block;
  height: 0.4rem;
  border-radius: 1rem;
  background: var(--m-border);
}
.mock-chip {
  display: inline-block;
  padding: 0.2rem 0.65rem;
  border: 1px solid var(--m-border);
  border-radius: 1rem;
  font-size: var(--text-xs);
  color: var(--m-muted);
}
.mock-address {
  font-size: var(--text-xl);
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.2;
}
.mock-town {
  margin-top: 0.15rem;
  font-size: var(--text-sm);
  color: var(--m-muted);
}
.mock-map {
  display: block;
  width: 100%;
  height: auto;
  margin: 1.25rem 0;
  border: 1px solid var(--m-border);
  border-radius: var(--radius);
  background: var(--m-fill);
}
.mock-plots path {
  fill: var(--m-card);
  stroke: var(--m-border);
  stroke-width: 1;
}
.mock-plots .mock-plot-found {
  fill: var(--accent-soft);
  stroke: var(--accent);
  stroke-width: 1.25;
}
.mock-street {
  fill: none;
  stroke: var(--m-border);
  stroke-width: 7;
}
.mock-pin-halo {
  fill: color-mix(in oklch, var(--accent) 25%, transparent);
}
.mock-pin-dot {
  fill: var(--accent);
}
.mock-confidence {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: var(--text-sm);
}
.mock-dots {
  display: inline-flex;
  gap: 0.25rem;
}
.mock-dots i {
  width: 0.45rem;
  height: 0.45rem;
  border-radius: 50%;
  background: var(--m-border);
}
.mock-dots .on {
  background: var(--accent);
}

/* ---------- responsive ---------- */

@media (max-width: 640px) {
  body {
    font-size: 15px;
  }
  :root {
    --gutter: 1rem;
  }
  .hero {
    padding-top: max(4.5rem, calc(42dvh - 7rem));
    padding-bottom: 4rem;
  }
  .hero-shot {
    padding-bottom: 4rem;
  }
  .section {
    padding: 4rem 0;
  }
  .steps li {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.4rem;
    padding: 1.6rem 0;
  }
  .steps li::before {
    padding-top: 0;
  }
  .contrast {
    grid-template-columns: minmax(0, 1fr);
  }
  .contrast > div + div {
    border-left: 0;
    border-top: 1px solid var(--rule2);
  }
  .example > div {
    grid-template-columns: minmax(0, 1fr);
    gap: 0.25rem;
  }
  .mock {
    grid-template-columns: minmax(0, 1fr);
  }
  .mock-pane--in .mock-lines {
    display: none;
  }
  .mock-pane--in .mock-chip {
    margin-top: 0.75rem;
  }
  .site-head .request {
    display: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .btn {
    transition: none;
  }
}

/* ---------- v3: sample and tool links ---------- */

.links {
  list-style: none;
  margin-top: 2.5rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  border: 1px solid var(--rule2);
  border-radius: var(--radius);
  overflow: hidden;
}
.links li + li {
  border-left: 1px solid var(--rule2);
}
.links a {
  display: block;
  height: 100%;
  padding: 1.2rem 1.5rem;
  background: var(--paper);
  text-decoration: none;
  transition: background 0.15s ease;
}
.links a:hover {
  background: var(--accent-soft);
}
.links a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}
.links .label {
  display: block;
  margin-bottom: 0.35rem;
  color: var(--accent);
}
.links b {
  font-family: var(--serif);
  font-size: var(--text-lg);
  font-weight: 560;
  line-height: 1.3;
}
.links b::after {
  content: '\00a0→';
  color: var(--accent);
}
.steps + .links {
  margin-top: 1rem;
}

@media (max-width: 640px) {
  .links {
    grid-template-columns: minmax(0, 1fr);
  }
  .links li + li {
    border-left: 0;
    border-top: 1px solid var(--rule2);
  }
}
.prose + .steps {
  margin-top: 2rem;
}
