:root {
  color-scheme: light;
  --night: #0b1a30;
  --dusk: #163a66;
  --horizon: #4f8fcf;
  --star: #5cc0ff;
  --paper: #f6f8fb;
  --sky-pale: #e3eef9;
  --ink: #0d1b2e;
  --muted: #4b5b70;
  --line: #d6dee8;
  --link: #1f5fbf;
  --danger: #b42318;
  --ok: #067647;
  --measure: 62ch;
  --font: "Bricolage Grotesque", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 1.5rem; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 1.0625rem;
  font-variation-settings: "opsz" 14;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: var(--link); text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { color: var(--ink); }

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

h1, h2, h3 { margin: 0; line-height: 1.1; text-wrap: balance; font-variation-settings: "opsz" 72; }
h2 { font-size: 1.75rem; font-weight: 700; letter-spacing: -0.02em; }
p { margin: 0; text-wrap: pretty; }

.skip-link {
  position: absolute; left: 1rem; top: -4rem; z-index: 20;
  padding: 0.6rem 1rem; background: #fff; color: var(--ink); border-radius: 8px;
}
.skip-link:focus { top: 1rem; }
.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;
}

.wrap {
  width: 100%;
  max-width: 68rem;
  margin: 0 auto;
  padding-inline: max(1rem, env(safe-area-inset-left)) max(1rem, env(safe-area-inset-right));
}
@media (min-width: 48rem) { .wrap { padding-inline: 2rem; } }

/* ── Sky band ──────────────────────────────────────────── */
.sky {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(180deg, var(--night) 0%, var(--dusk) 62%, var(--horizon) 100%);
}
.sky .stars { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.sky a { color: #fff; }
.sky > .wrap { position: relative; }

.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  min-height: 4.5rem;
}
.brand {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-weight: 700; font-size: 1.125rem; letter-spacing: -0.01em; text-decoration: none;
}
.brand img { width: 3.25rem; height: 2.25rem; object-fit: cover; }
.nav { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; }
.nav a { color: rgba(255, 255, 255, 0.78); text-decoration: none; font-weight: 500; padding-block: 0.4rem; }
.nav a:hover, .nav a[aria-current="page"] { color: #fff; text-decoration: underline; }

/* Home hero */
.hero-home { padding-top: clamp(2.5rem, 7vw, 5rem); }
.hero-home .lead { max-width: 30ch; font-size: clamp(1.25rem, 1rem + 1vw, 1.6rem); line-height: 1.35; color: rgba(255, 255, 255, 0.86); }
.hero-mark {
  position: absolute;
  right: max(-2rem, 2vw);
  top: clamp(-1rem, 2vw, 1.5rem);
  width: clamp(11rem, 34vw, 26rem);
  aspect-ratio: 3 / 2;
  object-fit: cover;
  opacity: 0.95;
  pointer-events: none;
  animation: shoot 1.4s cubic-bezier(0.2, 0.7, 0.2, 1) both;
}
@keyframes shoot {
  from { opacity: 0; transform: translate(-18%, 22%) scale(0.9); }
  to   { opacity: 0.95; transform: none; }
}
.wordmark {
  display: block;
  margin-top: clamp(2.5rem, 8vw, 5rem);
  margin-bottom: -0.1em;
  font-size: clamp(5rem, 21vw, 16rem);
  font-weight: 800;
  font-variation-settings: "opsz" 96, "wdth" 80;
  letter-spacing: -0.03em;
  line-height: 0.8;
  color: var(--paper);
}

/* Subpage hero */
.hero-page { padding-block: clamp(2.5rem, 7vw, 4.5rem) clamp(2.5rem, 6vw, 4rem); }
.hero-page h1 {
  font-size: clamp(2.6rem, 6vw + 0.5rem, 4.75rem);
  font-weight: 800;
  font-variation-settings: "opsz" 96, "wdth" 88;
  letter-spacing: -0.025em;
}
.hero-page .lead { margin-top: 1.25rem; max-width: 44ch; font-size: 1.25rem; line-height: 1.45; color: rgba(255, 255, 255, 0.86); }
.hero-product { display: grid; grid-template-columns: auto 1fr; gap: 1.5rem; align-items: center; }
.hero-product .tile { width: clamp(4.5rem, 10vw, 6.5rem); height: clamp(4.5rem, 10vw, 6.5rem); }

/* ── Buttons ───────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 2.875rem; padding: 0.7rem 1.35rem;
  font: inherit; font-weight: 650; line-height: 1.2;
  color: #fff; background: var(--ink); border: 1px solid var(--ink); border-radius: 999px;
  text-decoration: none; cursor: pointer; touch-action: manipulation;
  transition: background-color 0.15s, color 0.15s, border-color 0.15s;
}
.btn:hover { background: var(--dusk); border-color: var(--dusk); color: #fff; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }
.btn-ghost { color: var(--ink); background: transparent; border-color: var(--line); }
.btn-ghost:hover { color: var(--ink); background: var(--sky-pale); border-color: var(--sky-pale); }
.sky .btn { color: var(--night); background: #fff; border-color: #fff; }
.sky .btn:hover { background: var(--sky-pale); border-color: var(--sky-pale); color: var(--night); }
.sky .btn-ghost { color: #fff; background: transparent; border-color: rgba(255, 255, 255, 0.4); }
.sky .btn-ghost:hover { color: #fff; background: rgba(255, 255, 255, 0.12); border-color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }

/* ── Logo tiles ────────────────────────────────────────── */
.tile {
  flex: none;
  width: 4rem; height: 4rem;
  border-radius: 22%;
  overflow: hidden;
  background: var(--night);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}
.tile img { width: 100%; height: 100%; object-fit: cover; }
.tile-light { background: #fff; box-shadow: inset 0 0 0 1px var(--line); }
.tile-light img { object-fit: contain; padding: 4%; }

/* ── Directory (home) ──────────────────────────────────── */
.directory { padding-block: clamp(3rem, 7vw, 5rem) 1rem; }
.group { display: grid; gap: 1rem 3rem; padding-block: 2rem; border-top: 1px solid var(--line); }
.group:first-child { border-top: 0; padding-top: 0; }
@media (min-width: 52rem) { .group { grid-template-columns: 11rem 1fr; } }
.group h2 { font-size: 1.125rem; font-weight: 600; color: var(--muted); letter-spacing: 0; padding-top: 1.1rem; }

.entries { list-style: none; margin: 0; padding: 0; }
.entries li + li { border-top: 1px solid var(--line); }
.entry {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 0.25rem 1.25rem;
  align-items: center;
  padding: 1rem 0;
  color: inherit;
  text-decoration: none;
}
.entry:hover { color: inherit; }
.entry-name {
  display: block;
  font-size: clamp(1.5rem, 1.1rem + 1.4vw, 2.1rem);
  font-weight: 700;
  font-variation-settings: "opsz" 72, "wdth" 90;
  letter-spacing: -0.025em;
  line-height: 1.1;
  transition: color 0.15s;
}
.entry:hover .entry-name { color: var(--link); }
.entry-desc { display: block; margin-top: 0.15rem; color: var(--muted); }
.entry-domain { color: var(--muted); font-size: 0.95rem; white-space: nowrap; }
.entry-new {
  display: inline-block; margin-left: 0.5rem; padding: 0.1rem 0.55rem;
  font-size: 0.8rem; font-weight: 600; vertical-align: 0.45em;
  color: var(--night); background: var(--sky-pale); border-radius: 999px;
}
@media (max-width: 40rem) {
  .entry { grid-template-columns: auto minmax(0, 1fr); }
  .entry-domain { display: none; }
  .tile { width: 3.25rem; height: 3.25rem; }
}

/* ── Newsletter ────────────────────────────────────────── */
.newsletter {
  margin-top: clamp(2rem, 5vw, 3rem);
  padding: clamp(1.75rem, 4vw, 2.75rem);
  background: var(--sky-pale);
  border-radius: 24px;
  display: grid;
  gap: 1.5rem 3rem;
}
@media (min-width: 52rem) { .newsletter { grid-template-columns: 1fr 1fr; align-items: end; } }
.newsletter p { margin-top: 0.5rem; color: var(--muted); max-width: 40ch; }

/* ── Forms ─────────────────────────────────────────────── */
label { display: block; margin: 1.25rem 0 0.4rem; font-weight: 600; font-size: 0.97rem; }
input, textarea {
  width: 100%; padding: 0.75rem 0.95rem;
  font: inherit; color: var(--ink); background: #fff;
  border: 1px solid #bfcad7; border-radius: 12px;
  transition: border-color 0.15s, box-shadow 0.15s;
}
textarea { min-height: 12rem; resize: vertical; }
input::placeholder, textarea::placeholder { color: #75849a; }
input:focus-visible, textarea:focus-visible {
  outline: none; border-color: var(--link); box-shadow: 0 0 0 3px rgba(31, 95, 191, 0.25);
}
.inline-form { display: flex; flex-wrap: wrap; gap: 0.6rem; }
.inline-form input { flex: 1 1 14rem; min-width: 0; border-radius: 999px; padding-inline: 1.15rem; }
.note { min-height: 1.5em; margin-top: 0.75rem; font-size: 0.97rem; color: var(--muted); }
.note[data-type="success"] { color: var(--ok); }
.note[data-type="error"] { color: var(--danger); }

/* ── Product features ──────────────────────────────────── */
.features-section { padding-block: clamp(3rem, 7vw, 5rem) 0; }
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 0 3rem;
  margin: 1.5rem 0 0; padding: 0; list-style: none;
}
.features li { padding: 1.25rem 0; border-top: 1px solid var(--line); }
.features strong { display: block; font-size: 1.2rem; font-weight: 700; letter-spacing: -0.01em; }
.features span { display: block; margin-top: 0.2rem; color: var(--muted); }

/* ── Legal prose ───────────────────────────────────────── */
.prose { max-width: var(--measure); padding-top: clamp(2.5rem, 6vw, 4rem); line-height: 1.7; }
.prose h2 { margin-top: 2.75rem; font-size: 1.4rem; }
.prose p, .prose ul { margin-top: 0.75rem; }
.prose ul { padding-left: 1.25rem; }
.prose li + li { margin-top: 0.35rem; }
.prose .summary { padding: 1.5rem 1.75rem; background: var(--sky-pale); border-radius: 20px; }
.prose .summary h2 { margin-top: 0; font-size: 1.2rem; }

/* ── Staff ─────────────────────────────────────────────── */
.staff-grid { display: grid; gap: 2rem; grid-template-columns: minmax(0, 1fr); padding-top: clamp(2rem, 5vw, 3rem); }
@media (min-width: 62rem) { .staff-grid.has-preview { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: start; } }
.panel { padding: clamp(1.25rem, 3vw, 2rem); background: #fff; border: 1px solid var(--line); border-radius: 20px; }
.panel h2 { font-size: 1.4rem; }
.panel label:first-of-type { margin-top: 1rem; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; }
.panel-head p { margin-top: 0.25rem; color: var(--muted); font-size: 0.97rem; font-variant-numeric: tabular-nums; }
.preview-frame { width: 100%; height: 38rem; margin-top: 1rem; border: 1px solid var(--line); border-radius: 12px; background: #f5f6f8; }
.is-hidden { display: none !important; }

/* ── 404 ───────────────────────────────────────────────── */
.hero-404 .wordmark { margin-top: clamp(1.5rem, 5vw, 3rem); }
.hero-404 .lead { margin-top: 1rem; }

/* ── Footer ────────────────────────────────────────────── */
.site-footer { margin-top: clamp(3.5rem, 8vw, 6rem); padding-block: 1.75rem 2.5rem; border-top: 1px solid var(--line); color: var(--muted); font-size: 0.95rem; }
.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1.5rem; }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; }
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: var(--ink); }

@media (max-width: 36rem) {
  .actions .btn { flex: 1 1 100%; }
  .inline-form .btn { flex: 1 1 100%; }
  .site-header .wrap { gap: 0.75rem; }
  .brand img { width: 2.5rem; height: 1.75rem; }
  .nav { flex-wrap: nowrap; gap: 0.85rem; font-size: 0.95rem; }
  .hero-home { padding-top: 6.5rem; }
  .hero-mark { top: -0.5rem; right: -1.5rem; width: 10rem; }
}

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