/* Otnel — Geist / ink-on-canvas system */

:root {
  /* Surface */
  --canvas: #0a0a0a;
  --elevated: #101010;
  --hairline: #262626;
  --hairline-soft: #151515;

  /* Text */
  --ink: #ededed;
  --body: #a1a1a1;
  --mute: #7d7d7d;
  --faint: #8a8a8a;

  /* Accent */
  --link: #3291ff;
  --link-deep: #0070f3;
  --cyan: #50e3c2;
  --violet: #7928ca;
  --pink: #ff0080;
  --magenta: #eb367f;
  --amber: #f9cb28;
  --red: #ff4d4d;

  /* Radius */
  --r-sm: 6px;
  --r-md: 12px;
  --r-lg: 16px;
  --pill: 100px;

  /* Spacing */
  --s-1: 4px;
  --s-2: 8px;
  --s-3: 12px;
  --s-4: 16px;
  --s-5: 24px;
  --s-6: 32px;
  --s-7: 40px;
  --s-8: 64px;
  --s-9: 96px;
  --s-10: 128px;

  /* Depth */
  --shadow-whisper: 0 1px 1px rgba(0, 0, 0, .4);
  --shadow-float: 0 2px 2px rgba(0, 0, 0, .3), 0 10px 24px -8px rgba(0, 0, 0, .6);

  /* Motion */
  --ease: cubic-bezier(.2, .7, .3, 1);
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: var(--canvas);
  color: var(--body);
  font-family: "Geist", Inter, -apple-system, "Segoe UI", Arial, sans-serif;
  font-size: 14px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  color-scheme: dark;
}

h1, h2, h3, p, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }

a {
  color: inherit;
  text-decoration: none;
}

:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 3px;
  border-radius: 2px;
}

::selection { background: #1c3f66; color: #ffffff; }

.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: absolute;
  left: 16px; top: -60px;
  z-index: 100;
  background: var(--ink);
  color: var(--canvas);
  padding: 10px 14px;
  border-radius: var(--r-sm);
}
.skip:focus { top: 12px; }

/* ---------- Layout ---------- */

.shell {
  width: min(1200px, 100% - 48px);
  margin-inline: auto;
}

.band { padding-block: var(--s-10); }
.band-tight { padding-block: var(--s-9); }
.band-soft { background: var(--hairline-soft); }

/* ---------- Type ---------- */

.h-lg {
  font-size: clamp(26px, 3.1vw, 32px);
  font-weight: 600;
  line-height: 1.18;
  letter-spacing: -1.1px;
  color: var(--ink);
  max-width: 20ch;
}

.h-md {
  font-size: 20px;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -.4px;
  color: var(--ink);
}

.mono-eyebrow {
  font-family: "Geist Mono", "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  font-weight: 500;
  line-height: 16px;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--mute);
}

.mono { font-family: "Geist Mono", "JetBrains Mono", ui-monospace, monospace; }

.text-link {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  transition: color .15s var(--ease);
}
.text-link:hover { color: #6cb2ff; }
.body-sm { font-size: 12px; line-height: 1.5; }
.muted { color: var(--mute); }

.lead {
  font-size: 17px;
  line-height: 1.55;
  color: var(--body);
  max-width: 58ch;
}

.section-head { max-width: 720px; }
.section-head .mono-eyebrow { margin-bottom: var(--s-4); }
.section-head .h-lg { max-width: 24ch; }

.section-lead {
  margin-top: var(--s-4);
  font-size: 16px;
  line-height: 1.55;
  color: var(--body);
  max-width: 62ch;
}
.section-lead-left { max-width: 48ch; }

/* ---------- Nav ---------- */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--canvas);
  border-bottom: 1px solid var(--hairline);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: var(--s-5);
  min-height: 60px;
}

.brand {
  display: inline-flex;
  align-items: center;
  color: var(--ink);
}
.brand-logo {
  height: 28px;
  width: auto;
}
.footer .brand-logo { height: 32px; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  margin-left: var(--s-5);
}
.nav-links a {
  color: var(--body);
  padding: 8px 12px;
  border-radius: 9999px;
  transition: color .15s var(--ease), background-color .15s var(--ease);
}
.nav-links a:hover { color: var(--ink); background: var(--hairline-soft); }

.nav-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: auto;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  height: 32px;
  padding: 0 10px;
  margin-left: auto;
  background: var(--elevated);
  border: 1px solid var(--hairline);
  border-radius: var(--r-sm);
  color: var(--ink);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
}
.nav-toggle-bars,
.nav-toggle-bars::before {
  display: block;
  width: 14px;
  height: 1.5px;
  background: var(--ink);
  content: "";
  transition: transform .2s var(--ease);
}
.nav-toggle-bars::before { transform: translateY(-5px); }
.nav.is-open .nav-toggle-bars { transform: rotate(45deg); }
.nav.is-open .nav-toggle-bars::before { transform: rotate(-90deg); }

/* Buttons */
.btn-sm {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 32px;
  padding: 0 10px;
  border-radius: var(--r-sm);
  font-size: 14px;
  font-weight: 500;
  border: 1px solid transparent;
  transition: background-color .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease);
}
.btn-ink { background: var(--ink); color: var(--canvas); }
.btn-ink:hover { background: #ffffff; }
.btn-ghost { background: var(--elevated); border-color: var(--hairline); color: var(--ink); }
.btn-ghost:hover { border-color: #3a3a3a; }

.pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  padding: 0 18px;
  border-radius: var(--pill);
  font-size: 16px;
  font-weight: 500;
  border: 1px solid transparent;
  transition: background-color .18s var(--ease), border-color .18s var(--ease), transform .18s var(--ease);
}
.pill:active { transform: translateY(1px); }
.pill-ink { background: var(--ink); color: var(--canvas); }
.pill-ink:hover { background: #ffffff; }
.pill-outline { background: var(--elevated); color: var(--ink); border-color: var(--hairline); }
.pill-outline:hover { border-color: #3a3a3a; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding-block: 104px 88px;
  border-bottom: 1px solid var(--hairline);
}

.mesh {
  position: absolute;
  inset: -40% 0 auto 0;
  height: 720px;
  pointer-events: none;
  opacity: .32;
  mix-blend-mode: screen;
  filter: blur(56px) saturate(120%);
  background:
    radial-gradient(38% 46% at 22% 52%, var(--cyan) 0%, transparent 70%),
    radial-gradient(34% 44% at 40% 34%, #007cf0 0%, transparent 72%),
    radial-gradient(34% 44% at 60% 46%, var(--violet) 0%, transparent 70%),
    radial-gradient(30% 40% at 76% 34%, var(--magenta) 0%, transparent 70%),
    radial-gradient(30% 38% at 88% 58%, var(--amber) 0%, transparent 72%);
  animation: drift 26s var(--ease) infinite alternate;
}

@keyframes drift {
  from { transform: translate3d(-2%, 0, 0) scale(1); }
  to { transform: translate3d(3%, 1.5%, 0) scale(1.06); }
}

.hero-inner {
  position: relative;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero h1 {
  margin-top: var(--s-5);
  font-size: clamp(38px, 6.2vw, 68px);
  font-weight: 600;
  line-height: 1.02;
  letter-spacing: -2.4px;
  color: var(--ink);
  text-wrap: balance;
}

.hero .lead {
  margin-top: var(--s-5);
  max-width: 52ch;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
  margin-top: var(--s-6);
}

.hero-meta {
  margin-top: var(--s-7);
  font-size: 12px;
  color: var(--mute);
  letter-spacing: .02em;
}

/* ---------- Ecosystem strip ---------- */

.strip {
  padding-block: var(--s-6);
  border-bottom: 1px solid var(--hairline);
}
.strip-title { margin-bottom: var(--s-5); }

.wordmarks {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--s-7);
  color: var(--mute);
}
.wordmarks li {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: .01em;
  white-space: nowrap;
  transition: color .2s var(--ease);
}
.wordmarks li:hover { color: var(--body); }

.strip-note {
  margin-top: var(--s-4);
  font-size: 12px;
  color: var(--faint);
}

/* ---------- Split ---------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--s-8);
  align-items: start;
  margin-bottom: var(--s-8);
}
.split-head .mono-eyebrow { margin-bottom: var(--s-4); }
.split-body p { font-size: 16px; line-height: 1.6; color: var(--body); max-width: 54ch; }
.split-body p + p { margin-top: var(--s-4); }

/* ---------- Cards ---------- */

.card-grid {
  display: grid;
  gap: var(--s-4);
}
.card-grid.three { grid-template-columns: repeat(3, 1fr); }
.card-grid.four { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--elevated);
  border: 1px solid var(--hairline);
  border-radius: var(--r-md);
  padding: var(--s-5);
  box-shadow: var(--shadow-whisper);
  transition: border-color .2s var(--ease), box-shadow .2s var(--ease), transform .2s var(--ease);
}
.card:hover {
  border-color: #383838;
  box-shadow: var(--shadow-float);
  transform: translateY(-2px);
}

.card-art {
  margin: calc(var(--s-5) * -1) calc(var(--s-5) * -1) var(--s-5);
  padding: var(--s-4);
  border-bottom: 1px solid var(--hairline);
  color: var(--ink);
  background: var(--elevated);
  border-radius: var(--r-md) var(--r-md) 0 0;
}
.card-art svg { width: 100%; height: 132px; opacity: .88; }

.card .mono-eyebrow { margin-bottom: var(--s-3); }
.card-text { margin-top: var(--s-3); font-size: 14px; line-height: 1.55; color: var(--body); }
.card-quiet { padding-block: var(--s-6); }

/* ---------- Figures ---------- */

.figures { border-block: 1px solid var(--hairline); }
.figures-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--s-6);
  padding-block: var(--s-7);
}
.figure-number {
  font-size: 30px;
  font-weight: 600;
  letter-spacing: -1.2px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.figure-label {
  margin-top: 4px;
  font-size: 13px;
  color: var(--mute);
  max-width: 22ch;
}

/* ---------- Code band ---------- */

.code-split {
  display: grid;
  grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr);
  gap: var(--s-8);
  align-items: start;
}
.code-split .mono-eyebrow { margin-bottom: var(--s-4); }
.code-split .h-md { margin-bottom: var(--s-5); }

.code-card {
  background: var(--elevated);
  border: 1px solid var(--hairline);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-whisper);
  overflow: hidden;
}
.code-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--hairline);
  background: var(--canvas);
}
.dot {
  width: 8px; height: 8px;
  border-radius: 50%;
  background: #333333;
}
.code-name {
  margin-left: auto;
  font-size: 11px;
  color: var(--mute);
  letter-spacing: .02em;
}
.code {
  margin: 0;
  padding: var(--s-5);
  overflow-x: auto;
  font-family: "Geist Mono", "JetBrains Mono", ui-monospace, monospace;
  font-size: 12.5px;
  line-height: 1.75;
  color: var(--ink);
  tab-size: 2;
}
.c-key { color: var(--link); font-weight: 500; }
.c-prop { color: #b98cf0; }
.c-str { color: var(--ink); }
.c-num { color: var(--magenta); }

/* ---------- Product panel ---------- */

.product-grid {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.1fr) minmax(0, .8fr);
  gap: var(--s-6);
  align-items: start;
}
.panel-caption { margin-top: var(--s-5); }

.panel {
  background: var(--elevated);
  border: 1px solid var(--hairline);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--shadow-float);
}
.panel-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: var(--s-4);
  padding: var(--s-4) var(--s-5);
  border-bottom: 1px solid var(--hairline);
  background: var(--canvas);
}
.panel-title { font-size: 14px; font-weight: 600; color: var(--ink); }
.panel-sub { margin-top: 2px; font-size: 12px; color: var(--mute); }
.panel-total {
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.panel-rows { padding: 0; position: relative; }
.panel-rows.is-loading > .panel-row { visibility: hidden; }
.panel[aria-busy="true"] .panel-total,
.panel[aria-busy="true"] .panel-foot { visibility: hidden; }
.panel-skeleton {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: grid;
  align-content: center;
  gap: var(--s-4);
  padding: var(--s-4) var(--s-5);
  background: var(--elevated);
  list-style: none;
  --dh-well: var(--hairline);
  --dh-raised: #3a3a3a;
}
.panel-skeleton .dh-skeleton { width: 100%; }
.panel-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: var(--s-3);
  padding: var(--s-3) var(--s-5);
  border-bottom: 1px solid var(--hairline);
}
.panel-id { font-size: 12px; color: var(--faint); }
.panel-who { font-size: 13.5px; color: var(--ink); display: flex; flex-direction: column; gap: 2px; }
.panel-items { font-size: 12px; color: var(--mute); }
.panel-amount {
  font-size: 13.5px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border: 1px solid var(--hairline);
  border-radius: 64px;
  font-size: 11.5px;
  color: var(--body);
  white-space: nowrap;
}
.status.is-live { color: var(--ink); border-color: #3a3a3a; }
.status-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); }

.panel-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--s-4);
  padding: var(--s-3) var(--s-5);
  font-size: 12px;
  color: var(--mute);
  background: var(--canvas);
}
.panel-foot .mono { font-size: 11px; letter-spacing: .02em; }

/* ---------- Timeline ---------- */

.timeline {
  margin-top: var(--s-7);
  border-top: 1px solid var(--hairline);
}
.tl-row {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr);
  gap: var(--s-5);
  padding: var(--s-5) 0;
  border-bottom: 1px solid var(--hairline);
}
.tl-time {
  font-family: "Geist Mono", "JetBrains Mono", ui-monospace, monospace;
  font-size: 12.5px;
  color: var(--mute);
  padding-top: 3px;
  font-variant-numeric: tabular-nums;
}
.tl-text { font-size: 15px; line-height: 1.6; color: var(--body); max-width: 74ch; }
.tl-text strong { color: var(--ink); font-weight: 500; }

/* ---------- Statement ---------- */

.statement-block {
  margin-top: var(--s-8);
  padding-top: var(--s-6);
  border-top: 1px solid var(--hairline);
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .8fr);
  gap: var(--s-6);
  align-items: end;
}
.statement {
  font-size: clamp(23px, 2.6vw, 32px);
  font-weight: 500;
  line-height: 1.22;
  letter-spacing: -1px;
  color: var(--ink);
  max-width: 22ch;
}
.statement-note { font-size: 14px; line-height: 1.6; color: var(--mute); max-width: 40ch; }

.contact-line { margin-top: var(--s-3); font-size: 15px; color: var(--body); }

/* ---------- Table ---------- */

.table-wrap {
  margin-top: var(--s-7);
  border: 1px solid var(--hairline);
  border-radius: var(--r-md);
  background: var(--elevated);
  overflow-x: auto;
}

.price-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  min-width: 680px;
}
.price-table th,
.price-table td {
  text-align: left;
  padding: 14px var(--s-5);
  border-bottom: 1px solid var(--hairline);
  font-variant-numeric: tabular-nums;
}
.price-table thead th {
  font-family: "Geist Mono", "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--mute);
  background: var(--canvas);
}
.price-table tbody th { color: var(--ink); font-weight: 500; }
.price-table tbody td { color: var(--body); }
.price-table tbody tr:last-child th,
.price-table tbody tr:last-child td { border-bottom: 0; }
.price-table tbody tr { transition: background-color .15s var(--ease); }
.price-table tbody tr:hover { background: var(--hairline-soft); }

/* ---------- Company card ---------- */

.company-card {
  position: relative;
  overflow: hidden;
  padding: var(--s-7);
  background:
    radial-gradient(60% 60% at 0% 0%, rgba(50, 145, 255, .06), transparent 70%),
    var(--elevated);
  border: 1px solid var(--hairline);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-whisper);
}
.company-card::before {
  position: absolute;
  inset: 0 auto 0 0;
  z-index: 3;
  width: 2px;
  background: linear-gradient(180deg, var(--link) 0%, var(--link) 42%, #7c3aed 70%, #ff6a3d 100%);
  content: "";
}
.company-card::after {
  position: absolute;
  right: -90px;
  bottom: -140px;
  z-index: 0;
  width: 420px;
  height: 340px;
  background: radial-gradient(closest-side, rgba(255, 106, 61, .20), rgba(255, 77, 77, .08) 55%, transparent 78%);
  pointer-events: none;
  content: "";
}
.company-card .split {
  position: relative;
  z-index: 2;
  margin-bottom: 0;
}
.company-card .split-body p {
  max-width: 54ch;
  color: var(--body);
  font-size: 15px;
  line-height: 1.6;
}
.company-card .split-body p:first-child {
  max-width: 38ch;
  color: var(--ink);
  font-size: 20px;
  line-height: 1.4;
  letter-spacing: -.2px;
}
.company-card .split-body p + p { margin-top: var(--s-4); }
.company-card .text-link::after {
  color: inherit;
  content: " →";
  white-space: nowrap;
}
.company-card-mark {
  position: absolute;
  right: -40px;
  bottom: -60px;
  z-index: 1;
  width: 260px;
  opacity: .05;
  pointer-events: none;
}
.company-card-mark img { width: 100%; height: auto; }
.company-card + .contact-band { margin-top: var(--s-6); }
@media (max-width: 768px) {
  .company-card { padding: var(--s-5); }
  .company-card-mark { width: 180px; right: -24px; bottom: -30px; }
  .company-card .split-body p:first-child { font-size: 18px; }
}

/* ---------- Plans ring ---------- */

.plans-controls {
  display: flex;
  align-items: flex-end;
  gap: var(--s-5);
  flex-wrap: wrap;
  margin-top: var(--s-6);
  margin-bottom: var(--s-5);

  /* Segmented control — project tokens */
  --dh-fg: var(--ink);
  --dh-bg: var(--canvas);
  --dh-muted: var(--body);
  --dh-faint: var(--faint);
  --dh-well: var(--canvas);
  --dh-raised: #1f1f1f;
  --dh-edge: #363636;
  --dh-accent: var(--link);
  --dh-on-accent: #ffffff;
}
.plans-controls .fieldset { margin: 0; }
.plans-note {
  max-width: 46ch;
  padding-bottom: 8px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--mute);
}
.plans-ring { margin-top: var(--s-5); }
.plans-ring .dh-ring-frame { border-radius: var(--r-lg); }
.plans-ring .dh-ring-figure strong {
  font-size: 48px;
  line-height: 1;
}
.plans-ring .dh-ring-figure sup {
  margin-top: 6px;
  font-size: 16px;
  line-height: 1;
}
.plans-ring .dh-ring-card[data-text] .dh-ring-figure strong {
  font-size: 32px;
  letter-spacing: -0.02em;
}
.plans-ring .dh-ring-card footer {
  font-size: 13px;
  line-height: 18px;
}
@media (max-width: 640px) {
  .plans-ring .dh-ring-figure strong { font-size: 36px; }
  .plans-ring .dh-ring-figure sup { font-size: 13px; }
  .plans-ring .dh-ring-card[data-text] .dh-ring-figure strong { font-size: 26px; }
}

/* ---------- Plans ring edges ---------- */

.plans-ring .dh-ring-card[data-at="left"] {
  transform: translateX(-104%) rotateY(-180deg) scale(.85);
  clip-path: polygon(0 4%, 15% 2%, 40% 0, 70% 0, 100% 0, 100% 100%, 70% 100%, 40% 100%, 15% 98%, 0 96%);
}
.plans-ring .dh-ring-card[data-at="right"] {
  transform: translateX(104%) rotateY(180deg) scale(.85);
  clip-path: polygon(0 0, 30% 0, 60% 0, 85% 2%, 100% 4%, 100% 96%, 85% 98%, 60% 100%, 30% 100%, 0 100%);
}
.plans-ring .dh-ring-card[data-at="left"] .dh-ring-face::after,
.plans-ring .dh-ring-card[data-at="right"] .dh-ring-face::after {
  position: absolute;
  top: 0;
  bottom: 0;
  z-index: 2;
  width: 1px;
  background: linear-gradient(180deg, transparent, var(--dh-ring-b) 30%, var(--dh-ring-b) 70%, transparent);
  box-shadow: 0 0 14px var(--dh-ring-b);
  pointer-events: none;
  content: "";
}
.plans-ring .dh-ring-card[data-at="left"] .dh-ring-face::after { left: 0; }
.plans-ring .dh-ring-card[data-at="right"] .dh-ring-face::after { right: 0; }

/* ---------- Estimator ---------- */

.estimator {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .8fr);
  gap: var(--s-8);
  margin-top: var(--s-5);
  padding: var(--s-6);
  background: var(--elevated);
  border: 1px solid var(--hairline);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-whisper);

  /* Segmented control — project tokens */
  --dh-fg: var(--ink);
  --dh-bg: var(--canvas);
  --dh-muted: var(--body);
  --dh-faint: var(--faint);
  --dh-well: var(--canvas);
  --dh-raised: #1f1f1f;
  --dh-edge: #363636;
  --dh-accent: var(--link);
  --dh-on-accent: #ffffff;
}
.estimator .mono-eyebrow { margin-bottom: var(--s-3); }
.estimator .h-md { margin-bottom: var(--s-5); }

.fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 var(--s-5);
}
.field-label {
  display: block;
  padding: 0;
  margin-bottom: var(--s-2);
  font-size: 12px;
  color: var(--mute);
}

.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip input {
  position: absolute;
  opacity: 0;
  width: 1px; height: 1px;
  margin: 0;
}
.chip span {
  display: inline-flex;
  align-items: center;
  height: 36px;
  padding: 0 14px;
  border-radius: 64px;
  border: 1px solid var(--hairline);
  background: var(--elevated);
  color: var(--ink);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: background-color .15s var(--ease), border-color .15s var(--ease), color .15s var(--ease);
}
.chip span:hover { border-color: #3a3a3a; }
.chip input:checked + span {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--canvas);
}
.chip input:focus-visible + span {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}

.estimator-result {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: var(--s-5);
  border-radius: var(--r-md);
  background: var(--canvas);
  border: 1px solid var(--hairline);
}
.result-price {
  font-size: 40px;
  font-weight: 600;
  letter-spacing: -2px;
  line-height: 1.1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.result-cadence { margin-top: 4px; font-size: 14px; color: var(--body); }
.result-note { margin-top: var(--s-4); font-size: 13px; color: var(--body); }
.result-fine { margin-top: 6px; color: var(--mute); }

/* ---------- Rules ---------- */

.rules {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--s-7);
  margin-top: var(--s-8);
}
.rule { border-top: 1px solid var(--hairline); padding-top: var(--s-4); }
.rule p { margin-top: var(--s-3); font-size: 14px; line-height: 1.6; color: var(--body); max-width: 40ch; }

/* ---------- Contact / CTA ---------- */

.contact-band {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: var(--s-6);
  flex-wrap: wrap;
  margin-top: var(--s-8);
  padding-top: var(--s-6);
  border-top: 1px solid var(--hairline);
}
.contact-actions { padding-bottom: 4px; }

.cta-band {
  border-top: 1px solid var(--hairline);
  padding-block: var(--s-9);
}
.cta-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: var(--s-4);
}
.cta-inner .section-lead { margin-top: 0; max-width: 46ch; }
.cta-inner .pill { margin-top: var(--s-2); }

/* ---------- Footer ---------- */

.footer {
  background: var(--canvas);
  padding-block: var(--s-8) var(--s-6);
}
.footer-card {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.95fr);
  gap: var(--s-8);
  padding: var(--s-8);
  overflow: hidden;
  isolation: isolate;
  background: #171717;
  border: 1px solid rgb(255 255 255 / 0.05);
  border-radius: 24px;
}
.footer-card::before {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-image: url("data:image/svg+xml,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20viewBox%3D%220%200%201200%20360%22%20preserveAspectRatio%3D%22none%22%3E%3Crect%20x%3D%220.00%22%20y%3D%22250%22%20width%3D%22133.93%22%20height%3D%22110%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.028%22%2F%3E%3Crect%20x%3D%22133.33%22%20y%3D%22190%22%20width%3D%22133.93%22%20height%3D%22170%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.03%22%2F%3E%3Crect%20x%3D%22266.67%22%20y%3D%22130%22%20width%3D%22133.93%22%20height%3D%22230%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.032%22%2F%3E%3Crect%20x%3D%22400.00%22%20y%3D%2270%22%20width%3D%22133.93%22%20height%3D%22290%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.036%22%2F%3E%3Crect%20x%3D%22533.33%22%20y%3D%2230%22%20width%3D%22133.93%22%20height%3D%22330%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.04%22%2F%3E%3Crect%20x%3D%22666.67%22%20y%3D%2270%22%20width%3D%22133.93%22%20height%3D%22290%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.036%22%2F%3E%3Crect%20x%3D%22800.00%22%20y%3D%22130%22%20width%3D%22133.93%22%20height%3D%22230%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.032%22%2F%3E%3Crect%20x%3D%22933.33%22%20y%3D%22190%22%20width%3D%22133.93%22%20height%3D%22170%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.03%22%2F%3E%3Crect%20x%3D%221066.67%22%20y%3D%22250%22%20width%3D%22133.93%22%20height%3D%22110%22%20fill%3D%22%23fff%22%20fill-opacity%3D%220.028%22%2F%3E%3C%2Fsvg%3E");
  background-position: bottom center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  -webkit-mask-image:
    linear-gradient(to top, #000 0%, #000 58%, transparent 100%),
    linear-gradient(to right, transparent 0%, #000 12%, #000 88%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(to top, #000 0%, #000 58%, transparent 100%),
    linear-gradient(to right, transparent 0%, #000 12%, #000 88%, transparent 100%);
  mask-composite: intersect;
  pointer-events: none;
  content: "";
}
.footer-card::after {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: radial-gradient(ellipse 70% 60% at 50% 100%, rgb(255 255 255 / 0.03), transparent 72%);
  pointer-events: none;
  content: "";
}
.footer-brand {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.footer .brand-logo { height: 34px; }
.footer-description {
  max-width: 42ch;
  margin-top: var(--s-5);
  color: var(--body);
  font-size: 15px;
  line-height: 1.65;
}
.footer-social {
  display: flex;
  gap: 10px;
  margin-top: var(--s-6);
}
.footer-social a {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 50%;
  background: color-mix(in srgb, var(--ink) 8%, transparent);
  color: var(--body);
  transition: color .15s var(--ease), border-color .15s var(--ease), background-color .15s var(--ease);
}
.footer-social a:hover {
  color: var(--ink);
  border-color: #3a3a3a;
  background: var(--hairline-soft);
}
.footer-social a:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 2px;
}
.footer-social svg { width: 17px; height: 17px; }

.footer-cols {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--s-7);
}
.footer-col {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}
.footer-head {
  margin: 0 0 4px;
  color: var(--ink);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0;
  text-transform: none;
}
.footer-col a {
  width: fit-content;
  color: var(--body);
  font-size: 14px;
  transition: color .15s var(--ease);
}
.footer-col a:hover {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.footer-bottom {
  margin-top: var(--s-7);
  color: var(--mute);
  font-size: 12px;
  text-align: center;
}
.footer-bottom p { margin: 0; }
@media (max-width: 1024px) {
  .footer-card {
    grid-template-columns: 1fr;
    gap: var(--s-6);
    padding: var(--s-7);
  }
}
@media (max-width: 640px) {
  .footer-card {
    padding: var(--s-6);
    border-radius: 24px;
  }
  .footer-cols {
    grid-template-columns: 1fr 1fr;
    gap: var(--s-5);
  }
}

/* ---------- Motion ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition:
    opacity .55s var(--ease) var(--d, 0ms),
    transform .55s var(--ease) var(--d, 0ms);
}
.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .mesh { animation: none; }
  .js .reveal { opacity: 1; transform: none; transition: none; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}

/* ---------- Responsive ---------- */

@media (max-width: 1024px) {
  .card-grid.four { grid-template-columns: repeat(2, 1fr); }
  .split { grid-template-columns: 1fr; gap: var(--s-5); }
  .product-grid { grid-template-columns: 1fr; gap: var(--s-6); }
  .statement-block { grid-template-columns: 1fr; gap: var(--s-4); align-items: start; }
  .estimator { grid-template-columns: 1fr; gap: var(--s-5); }
  .nav-links { display: none; }
  .nav-toggle { display: inline-flex; }
  .nav-actions { margin-left: 0; }
  .nav { position: relative; }
  .nav.is-open .nav-links {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    position: absolute;
    top: 100%; left: 0; right: 0;
    margin: 0;
    padding: var(--s-3) var(--s-5) var(--s-4);
    background: var(--elevated);
    border-bottom: 1px solid var(--hairline);
    box-shadow: var(--shadow-float);
  }
  .nav.is-open .nav-links a { padding: 10px 12px; border-radius: var(--r-sm); }
}

@media (max-width: 768px) {
  .band, .band-tight { padding-block: var(--s-8); }
  .band-tight { padding-block: var(--s-7); }
  .hero { padding-block: 72px 64px; }
  .hero h1 { letter-spacing: -1.6px; }
  .figures-grid { grid-template-columns: repeat(2, 1fr); gap: var(--s-5); }
  .card-grid.three { grid-template-columns: 1fr; }
  .rules { grid-template-columns: 1fr; gap: var(--s-5); margin-top: var(--s-6); }
  .wordmarks { gap: var(--s-5); }
  .split { margin-bottom: var(--s-6); }
  .contact-band { align-items: flex-start; }
  .footer-cols { gap: var(--s-6); }
}

/* ---------- Contact form placement ---------- */

.contact-head { margin-bottom: var(--s-7); }
#contacto .dh-contact { padding-top: 0; padding-bottom: 0; }

/* The vanilla port keeps the section's h2 and demotes the card titles to h3,
   so the supplied stylesheet's h2 typography is repeated here for h3. */
#contacto .dh-contact-body > h3,
#contacto .dh-contact-done > h3 {
  margin: 0;
  padding: 0 20px;
  font-size: 16px;
  font-weight: 500;
  line-height: 24px;
  letter-spacing: -.02em;
}
#contacto .dh-contact-done > h3 { outline: none; }

.dh-contact-noscript {
  max-width: 440px;
  margin: 16px auto 0;
  font-size: 13px;
  line-height: 1.55;
  color: var(--body);
}
.dh-contact-noscript a { color: var(--link); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Dither button tokens ---------- */

.site-dither {
  --dh-accent: var(--ink);
  --dh-on-accent: var(--canvas);
  --dh-fg: var(--ink);
  --dh-bg: var(--canvas);
  --dh-muted: var(--body);
  --dh-faint: var(--faint);
  --dh-well: var(--canvas);
  --dh-raised: var(--elevated);
  --dh-edge: var(--hairline);
}

@media (max-width: 640px) {
  .shell { width: min(1200px, 100% - 32px); }
  .hero-actions { width: 100%; flex-direction: column; }
  .hero-actions .pill { width: 100%; }
  .hero-actions .dh-dbutton { width: 100%; justify-content: space-between; }
  .card-grid.four { grid-template-columns: 1fr; }
  .nav-actions { display: none; }
  .estimator { padding: var(--s-5); }
  .result-price { font-size: 34px; }
  .cta-band { padding-block: var(--s-8); }
  .footer-bottom { flex-direction: column; gap: 6px; }
}

/* ---------- App hub ---------- */

#arquitectura { padding-block: var(--s-8); }
.architecture-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: var(--s-7);
  align-items: center;
}
.architecture-grid .section-head { max-width: 46ch; }
.architecture-grid .app-hub {
  margin-top: 0;
  width: 100%;
  max-width: 560px;
  justify-self: end;
}
.app-hub {
  --dh-accent: var(--ink);
  --dh-on-accent: var(--canvas);
  --dh-fg: var(--ink);
  --dh-bg: var(--canvas);
  --dh-muted: var(--body);
  --dh-faint: var(--faint);
  --dh-well: var(--canvas);
  --dh-raised: var(--elevated);
  --dh-edge: var(--hairline);
  margin-top: var(--s-6);
  background: transparent;
}
.app-hub .dh-hub {
  background: transparent;
  border-radius: 0;
}
.app-hub .dh-hub-map {
  --dh-hub-size: clamp(44px, 8cqw, 56px);
  font-size: 10.5px;
}
.app-hub .dh-hub-logo img { mix-blend-mode: screen; }
.app-hub .dh-hub-wire {
  stroke: var(--hairline);
  animation: none;
  stroke-dasharray: none;
}
.app-hub .dh-hub-wire[data-on] { stroke: var(--body); }
.app-hub .dh-hub-spark { display: none; }
.app-hub .dh-hub-logo::before { display: none; }
.app-hub .dh-hub-logo::after {
  box-shadow: inset 0 0 0 1px var(--hairline);
}
.app-hub .dh-hub-core::before { display: none; }
.app-hub .dh-hub-core strong { color: var(--ink); }
.app-hub .dh-hub-tile {
  background: var(--elevated);
  box-shadow: inset 0 0 0 1px var(--hairline);
}
@media (max-width: 1024px) {
  .architecture-grid { grid-template-columns: 1fr; gap: var(--s-6); }
  .architecture-grid .app-hub { justify-self: center; max-width: 560px; }
}
  --dh-accent: var(--link);
  --dh-on-accent: var(--canvas);
  --dh-fg: var(--ink);
  --dh-bg: var(--canvas);
  --dh-muted: var(--body);
  --dh-faint: var(--faint);
  --dh-well: var(--canvas);
  --dh-raised: var(--elevated);
  --dh-edge: var(--hairline);
  margin-top: var(--s-6);
  border-radius: var(--r-lg);
  overflow: hidden;
}
.app-hub .dh-hub { border-radius: inherit; }
.app-hub .dh-hub-logo img { mix-blend-mode: screen; }

/* ---------- Contact dialog ---------- */

.contact-dialog {
  --dh-raised: #141414;
  --dh-fg: #ededed;
  --dh-muted: #a1a1a1;
  --dh-faint: #8a8a8a;
  --dh-well: #0a0a0a;
  --dh-edge: #363636;
  --dh-accent: #ededed;
  --dh-on-accent: #0a0a0a;
  --accent: var(--dh-accent);
  --line: color-mix(in srgb, var(--dh-fg) 9%, transparent);
  --ring: 0 0 0 1px var(--line), 0 1px 2px color-mix(in srgb, var(--dh-fg) 10%, transparent);
}
.contact-dialog .dh-dialog input:focus-visible {
  outline: none;
  box-shadow: 0 0 0 2px var(--dh-faint);
}
.contact-clear {
  padding: 0 1.2308em 1.2308em;
}
