/* zetna.ai: one stylesheet, two fonts served from this site, no images but the marks and the state glyphs.
 *
 * ── THE IDENTITY SETTING ───────────────────────────────────────────────────────────────
 * One line decides which mark every page shows. The line below hides one of the two:
 *   .id-wordmark hidden  →  the FULL identity: the glyph lockup (Lattice v1.5)
 *   .id-full hidden      →  the WORDMARK-ONLY fallback (no glyph anywhere on the site)
 * To switch, change `.id-wordmark` to `.id-full` on the next line, or back. The site census
 * refuses the site unless exactly one such line exists. */
.id-wordmark { display: none !important; }
/* ────────────────────────────────────────────────────────────────────────────────────── */

/* The brand's two typefaces, both under the SIL Open Font License, served from this site and from no one else
 * (the census allows exactly these two files and refuses any other face). Manrope: a Latin subset, weights 400 to 700.
 * "Site Mono": a Latin subset of IBM Plex Mono Medium, renamed because the licence reserves the name "Plex" for
 * unmodified copies. The licences travel beside the files in fonts/. Until a font arrives, the reader's own fonts show. */
@font-face {
  font-family: "Manrope"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url("../fonts/manrope-latin-wght.woff2") format("woff2");
}
@font-face {
  font-family: "Site Mono"; font-style: normal; font-weight: 500; font-display: swap;
  src: url("../fonts/site-mono-medium-latin.woff2") format("woff2");
}

:root {
  --ink: #111418;
  --paper: #f7f6f2;
  --surface: #ffffff; /* white only where a small element must lift off the Paper: the open menu panel and the skip link */
  --muted: #4d535b;
  --rule: #dad8d1;
  --ring: #b9b6ae; /* the principles' empty lattice positions: decorative, never text */
  --amber: #a85a00;
  --focus: #111418;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --mono: "Site Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, "Liberation Mono", monospace;
  --measure: 46rem; /* running text never wider: long lines read badly */
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #f7f6f2;
    --paper: #111418;
    --surface: #1a1e24;
    --muted: #a3a9b1;
    --rule: #2c323a;
    --ring: #4a515a;
    --amber: #f2a43a;
    --focus: #f7f6f2;
  }
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.6;
}

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { text-decoration-thickness: 2px; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 2px; }

.skip {
  position: absolute; left: -999px; top: 0.5rem;
  background: var(--surface); padding: 0.5rem 0.75rem; border: 1px solid var(--rule);
}
.skip:focus { left: 1rem; }

.wrap { max-width: 78rem; margin: 0 auto; padding: 0 1.25rem; }

/* header */
.site-header { border-bottom: 1px solid var(--rule); }
.site-header .wrap {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 0.75rem 1.5rem; padding-top: 1.1rem; padding-bottom: 1.1rem;
}
.brand { display: inline-flex; align-items: center; text-decoration: none; padding: 0.35rem 0; }
.brand img { display: block; }
.brand .id-full img { height: 28px; width: auto; }
.brand .id-wordmark img { height: 22px; width: auto; }

.site-nav ul { display: flex; flex-wrap: wrap; gap: 0.25rem 1.25rem; list-style: none; margin: 0; padding: 0; }
.site-nav a { text-decoration: none; font-size: 0.95rem; color: var(--muted); padding: 0.25rem 0; display: inline-block; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); text-decoration: underline; }

/* the menu on a small screen: one "Menu" disclosure (<details>, no script) in place of six wrapped lines */
.nav-compact { display: none; }
.nav-compact summary {
  list-style: none; cursor: pointer; user-select: none;
  font-size: 0.95rem; line-height: 1.2; color: var(--ink);
  padding: 0.45rem 0.85rem; border: 1px solid var(--rule); border-radius: 999px;
}
.nav-compact summary::-webkit-details-marker { display: none; }
.nav-compact summary::after {
  content: ""; display: inline-block; width: 0.42em; height: 0.42em; margin-left: 0.55em;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: translateY(-0.2em) rotate(45deg);
}
.nav-compact[open] summary::after { transform: translateY(0.05em) rotate(-135deg); }
.site-nav .nav-compact ul {
  position: absolute; right: 0; top: calc(100% + 0.5rem); z-index: 10;
  display: block; width: max-content; min-width: 15rem; max-width: calc(100vw - 2.5rem);
  padding: 0.35rem 0; background: var(--surface);
  border: 1px solid var(--rule); border-radius: 6px; box-shadow: 0 10px 28px rgba(0, 0, 0, 0.14);
}
.site-nav .nav-compact a { display: block; padding: 0.55rem 1rem; color: var(--ink); }
.site-nav .nav-compact a[aria-current="page"] { font-weight: 600; box-shadow: inset 3px 0 0 var(--ink); }

@media (max-width: 58rem) { /* below the width the logo and six links need on one line */
  .site-header .wrap { flex-wrap: nowrap; }
  .site-nav .nav-wide { display: none; }
  .nav-compact { display: block; position: relative; }
}

/* main */
main { padding: 3rem 0 4rem; }
main .wrap > * { max-width: var(--measure); }
main .wrap > .wide { max-width: none; }

h1, h2, h3 { line-height: 1.2; font-weight: 600; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw, 2.9rem); margin: 0 0 1.25rem; }
h2 { font-size: 1.5rem; margin: 3rem 0 0.75rem; }
h3 { font-size: 1.1rem; margin: 0 0 0.4rem; }
p { margin: 0 0 1rem; }
.lead { font-size: 1.25rem; line-height: 1.5; }
.muted { color: var(--muted); }

.eyebrow {
  font-family: var(--mono); font-weight: 500; font-size: 0.78rem; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--muted); margin: 0 0 0.75rem;
}

.actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.75rem 0 0; padding: 0; list-style: none; }
.cta {
  display: inline-block; padding: 0.7rem 1.1rem; border: 1.5px solid var(--ink); border-radius: 8px;
  text-decoration: none; font-weight: 600; font-size: 0.98rem;
}
.cta.primary { background: var(--ink); color: var(--paper); }
.cta:hover { text-decoration: underline; }

/* the hero: the copy left, the product visual right; one column below 56rem */
.hero { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 3rem; align-items: center; margin-bottom: 1rem; }
main .wrap > .hero { max-width: none; }
.hero-copy > * { max-width: var(--measure); }
.hero-visual { margin: 0; }
.hero-visual img, .hero-visual video { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--rule); }
.hero-visual .hero-glyph { aspect-ratio: 16 / 10; padding: 13% 24%; object-fit: contain; }
.hero-visual figcaption { font-size: 0.85rem; color: var(--muted); margin-top: 0.5rem; }
.hero-steps { list-style: none; margin: 0; padding: 1.25rem; background: transparent; border: 1px solid var(--rule); border-radius: 12px;
  font-family: var(--mono); font-size: 0.9rem; display: grid; gap: 0.5rem; }
.hero-steps li::before { content: "·"; margin-right: 0.6rem; color: var(--muted); }

/* cards: the three gaps, the two pillars, the four categories; transparent on the Paper, with a hairline rule */
.gaps, .cards { list-style: none; padding: 0; margin: 1rem 0 1.25rem; display: grid; gap: 0.75rem; }
main .wrap > .gaps, main .wrap > .cards { max-width: none; }
.gaps { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.gaps li { padding: 0.8rem 1rem; background: transparent; border: 1px solid var(--rule); border-radius: 8px; }
.cards { grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr)); }
.cards > li { background: transparent; border: 1px solid var(--rule); border-radius: 10px; padding: 1.25rem 1.25rem 0.5rem; }
.cards p { font-size: 0.98rem; }
.cards.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* status tags: plain ink, never amber (amber is the halted state only) */
.tag { display: inline-block; font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.08em; text-transform: uppercase;
  border: 1px solid var(--muted); border-radius: 4px; padding: 0.05rem 0.4rem; margin-right: 0.35rem; vertical-align: 0.1em;
  color: var(--muted); white-space: nowrap; }
.tag.built { border-color: var(--ink); color: var(--ink); }

/* rows: the interop map and the four categories; stacked cards, so a phone never scrolls sideways */
.rows { list-style: none; padding: 0; margin: 1rem 0 1.5rem; border-top: 1px solid var(--rule); }
main .wrap > .rows { max-width: 60rem; }
.rows > li { padding: 1rem 0; border-bottom: 1px solid var(--rule); display: grid; grid-template-columns: 14rem minmax(0, 1fr); gap: 0.25rem 1.5rem; }
.rows h3 { margin: 0; }
.rows p { margin: 0 0 0.4rem; }

/* the nine principles, set as the lattice: three rows of three, one theme per row, each card a dot */
.lattice { margin: 1.25rem 0 0; counter-reset: p; }
main .wrap > .lattice { max-width: none; }
.lattice-row { display: grid; grid-template-columns: 9rem minmax(0, 1fr); gap: 1rem; align-items: start; margin-bottom: 1rem; }
.lattice-row > h3 { font-family: var(--mono); font-size: 0.8rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted);
  font-weight: 500; margin: 1.3rem 0 0; }
.dots { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.dots > li { counter-increment: p; background: transparent; border: 1px solid var(--rule); border-radius: 10px; padding: 1.1rem 1.2rem 0.4rem;
  display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: 0.7rem; align-items: center; align-content: start; }
.dots > li > * { grid-column: 1 / -1; }
/* each card's mark: the 3 × 3 lattice, this principle's position in ink and the other eight as light rings (CSS only, and
 * decorative: an empty generated box that assistive technology does not announce). --c is the column, --r the row. */
.dots > li::before {
  content: ""; grid-row: 1; grid-column: 1; width: 24px; height: 24px; margin-bottom: 0.7rem;
  background:
    radial-gradient(circle closest-side, var(--ink) 2.6px, transparent 3.1px) calc(var(--c) * 8px) calc(var(--r) * 8px) / 8px 8px no-repeat,
    radial-gradient(circle closest-side, transparent 1.6px, var(--ring) 1.9px 2.6px, transparent 2.9px) 0 0 / 8px 8px repeat;
}
.dots > li::after {
  content: counter(p); content: counter(p) / ""; grid-row: 1; grid-column: 2; margin-bottom: 0.7rem;
  font-family: var(--mono); font-weight: 500; font-size: 0.8rem; line-height: 1; color: var(--muted);
}
.dots > li:nth-child(1) { --c: 0; } .dots > li:nth-child(2) { --c: 1; } .dots > li:nth-child(3) { --c: 2; }
.lattice-row:nth-child(1) .dots { --r: 0; } .lattice-row:nth-child(2) .dots { --r: 1; } .lattice-row:nth-child(3) .dots { --r: 2; }
.dots h4 { font-size: 1.05rem; line-height: 1.25; margin: 0 0 0.35rem; font-weight: 600; }
.dots p { font-size: 0.97rem; }

/* principles */
.principles {
  list-style: none; padding: 0; margin: 1.25rem 0 0; counter-reset: p;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr)); gap: 1rem;
}
.principles > li {
  counter-increment: p; background: transparent; border: 1px solid var(--rule); border-radius: 10px;
  padding: 1.25rem 1.25rem 0.5rem;
}
.principles > li::before {
  content: counter(p); display: block; font-family: var(--mono); font-size: 0.8rem; color: var(--muted);
  margin-bottom: 0.4rem;
}
.principles p { font-size: 0.98rem; }
.limit { color: var(--muted); }

/* the one picture */
.strip {
  list-style: none; padding: 0; margin: 1.5rem 0 2.5rem; display: flex; flex-wrap: wrap; gap: 0.5rem 0;
  font-family: var(--mono); font-size: 0.82rem; letter-spacing: 0.04em;
}
.strip li { display: inline-flex; align-items: center; }
.strip li span { border: 1.5px solid var(--ink); border-radius: 6px; padding: 0.35rem 0.6rem; background: transparent; }
.strip li:not(:last-child)::after { content: "→"; padding: 0 0.45rem; color: var(--muted); }
.strip li.halt span { border-color: var(--amber); color: var(--amber); }

.flow { list-style: none; padding: 0; margin: 0; counter-reset: step; }
.flow > li {
  counter-increment: step; position: relative; padding: 0 0 2rem 3.25rem;
}
/* the home page's four steps: the words left, each moment's state glyph right; stacked below 56rem */
main .wrap > .flow.states { max-width: none; }
.flow.states > li { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr); gap: 1rem 3.5rem; align-items: start; }
.flow.states > li > div:first-child > :last-child { margin-bottom: 0; }
.state {
  display: flex; align-items: center; gap: 1.1rem; flex-wrap: wrap; min-height: 6.5rem;
  border: 1px solid var(--rule); border-radius: 12px; padding: 1rem 1.25rem; background: transparent;
}
.state img { display: block; flex: none; }
.state .g-lg { width: 64px; height: auto; }
.state .g-sm { width: 40px; height: auto; }
.state .device { width: 26px; height: auto; }
.state .wire { flex: none; width: 2.25rem; border-top: 1.5px dashed var(--muted); }
.state .pair { display: flex; align-items: center; gap: 0.9rem; }
.state .split { flex: none; align-self: stretch; width: 1px; background: var(--rule); }
.state.once .split { display: none; } /* the two glyphs share one line only where the card is wide enough (below) */
@media (min-width: 75rem) {
  .state.once { flex-wrap: nowrap; gap: 0.9rem; }
  .state.once .split { display: block; }
  .state.once .label.quiet { white-space: nowrap; }
}
.state p { margin: 0; font-size: 0.92rem; line-height: 1.45; color: var(--muted); }
.state .label { font-family: var(--mono); font-weight: 500; font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink); margin-bottom: 0.25rem; }
.state .label.quiet { color: var(--muted); margin: 0; }
.receipt { flex: 1 1 13rem; min-width: 0; }
.receipt .head { display: flex; justify-content: space-between; gap: 1rem; }
.receipt dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0.1rem 1rem; margin: 0.35rem 0 0;
  font-family: var(--mono); font-weight: 500; font-size: 0.8rem; line-height: 1.6; }
.receipt dt { color: var(--muted); }
.receipt dd { margin: 0; overflow-wrap: anywhere; }
.receipt .quiet { color: var(--muted); }
.flow > li::before {
  content: counter(step); position: absolute; left: 0; top: 0;
  width: 2.1rem; height: 2.1rem; border-radius: 50%; border: 1.5px solid var(--ink); background: var(--paper);
  display: flex; align-items: center; justify-content: center; font-family: var(--mono); font-size: 0.85rem;
}
.flow > li:not(:last-child)::after {
  content: ""; position: absolute; left: 1.05rem; top: 2.3rem; bottom: 0.2rem; width: 1.5px; background: var(--rule);
}
.flow > li.halt::before { border-color: var(--amber); color: var(--amber); }
.flow h3 { padding-top: 0.3rem; }
.flow p { margin-bottom: 0.5rem; }

/* lists and the criteria */
.plain { padding-left: 1.2rem; }
.plain li { margin-bottom: 0.5rem; }
.weeks { list-style: none; padding: 0; margin: 1rem 0; display: grid; gap: 0.75rem; }
.weeks li { background: transparent; border: 1px solid var(--rule); border-radius: 8px; padding: 0.9rem 1rem; }
.criteria { list-style: none; padding: 0; margin: 1rem 0; border-top: 1px solid var(--rule); }
.criteria li { padding: 0.8rem 0; border-bottom: 1px solid var(--rule); }
.criteria strong { font-family: var(--mono); font-weight: 500; font-size: 0.85rem; letter-spacing: 0.02em; margin-right: 0.35rem; }

.ask { background: transparent; border: 1.5px solid var(--ink); border-radius: 10px; padding: 1.25rem 1.25rem 0.5rem; }
.ask .email { font-family: var(--mono); font-size: 1rem; word-break: break-all; }

.limits { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: 1rem; }
.limits li { border-left: 3px solid var(--rule); padding: 0.1rem 0 0.1rem 1rem; }

/* SITE-5: the "what an operator gets" line on the products page */
.gets { border-top: 1px solid var(--rule); padding-top: 0.75rem; }
h4 { font-size: 1rem; margin: 1.25rem 0 0.4rem; }

/* SITE-5: the "Why Zetna" page: the formula, the three pillars, the four "because" lines */
.formula { font-family: var(--mono); font-weight: 500; font-size: 1rem; letter-spacing: 0.02em; color: var(--muted); margin: -0.5rem 0 1.5rem; }
.cards.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cards > li > h2 { font-size: 1.2rem; margin: 0 0 0.5rem; }
.because { list-style: none; padding: 0; margin: 1rem 0 1.5rem; border-top: 1px solid var(--rule); }
.because li { padding: 0.8rem 0; border-bottom: 1px solid var(--rule); }
@media (max-width: 56rem) { .cards.three { grid-template-columns: minmax(0, 1fr); } }

/* SITE-5: the header's pilot button, and the tokens figure on "Why Zetna" (inline SVG, drawn in the page's own colours) */
.site-nav { margin-left: auto; }
.header-cta { padding: 0.45rem 0.85rem; font-size: 0.9rem; }
.tokens { margin: 1.5rem 0 2rem; }
main .wrap > .tokens { max-width: 60rem; }
.tokens .panes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.tokens .pane { border: 1px solid var(--rule); border-radius: 10px; padding: 0.75rem 0.9rem 0.25rem; }
.tokens .pane-title { font-family: var(--mono); font-weight: 500; font-size: 0.78rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--muted); margin: 0 0 0.25rem; }
.tokens svg { display: block; width: 100%; height: auto; }
.tokens .box { fill: none; stroke: var(--ink); stroke-width: 1.5; }
.tokens .box.strong { stroke-width: 2.5; }
.tokens .box.refused { stroke-dasharray: 4 3; }
.tokens .line { fill: none; stroke: var(--ink); stroke-width: 1.5; }
.tokens .line.dash { stroke-dasharray: 5 4; }
.tokens .head { fill: var(--ink); }
.tokens .t { fill: var(--ink); font-family: var(--sans); font-size: 13px; font-weight: 600; }
.tokens .s { fill: var(--muted); font-family: var(--sans); font-size: 12px; }
.tokens .m { fill: var(--muted); font-family: var(--mono); font-size: 12px; }
.tokens .q { font-style: italic; }
.tokens figcaption { font-size: 0.9rem; color: var(--muted); margin-top: 0.6rem; }
@media (max-width: 40rem) {
  .tokens .panes { grid-template-columns: minmax(0, 1fr); }
  .site-header .wrap { gap: 0.5rem; }
  .brand .id-full img { height: 24px; }
  .header-cta { padding: 0.35rem 0.6rem; font-size: 0.85rem; white-space: nowrap; }
  .nav-compact summary { padding: 0.4rem 0.7rem; }
}

/* footer */
.site-footer { border-top: 1px solid var(--rule); font-size: 0.9rem; color: var(--muted); }
.site-footer .wrap {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.75rem 1.5rem;
  padding-top: 1.5rem; padding-bottom: 2rem;
}
.site-footer p { margin: 0; }
.site-footer .id-full img { height: 20px; width: auto; display: block; }
.site-footer .id-wordmark img { height: 16px; width: auto; display: block; }

@media (max-width: 56rem) {
  .hero, .gaps, .cards.two, .dots, .flow.states > li { grid-template-columns: minmax(0, 1fr); }
  .hero { gap: 1.75rem; }
  .lattice-row { grid-template-columns: minmax(0, 1fr); gap: 0.5rem; }
  .lattice-row > h3 { margin-top: 0.5rem; }
  .rows > li { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 40rem) {
  body { font-size: 1rem; }
  main { padding: 2rem 0 3rem; }
  h2 { margin-top: 2.25rem; }
  .lead { font-size: 1.12rem; }
  .flow > li { padding-left: 2.9rem; }
  .state .g-lg { width: 52px; }
}

@media print {
  .site-nav, .skip, .actions { display: none; }
  body { background: #fff; color: #000; }
}

/* SITE-6: the home page's one strong line, and the One Credential page's code sample */
.strong-line { font-size: 1.6rem; font-weight: 700; line-height: 1.25; letter-spacing: -0.01em; margin: 0.5rem 0 1rem; }
.strong-line a { color: var(--ink); text-decoration-thickness: 2px; text-underline-offset: 0.2em; }
pre.code { font-family: var(--mono); font-size: 0.85rem; line-height: 1.55; max-width: var(--measure); margin: 1rem 0 1.5rem;
  padding: 1rem 1.25rem; border: 1px solid var(--rule); border-radius: 10px; overflow-x: auto; white-space: pre; }
pre.code code { font-family: inherit; }
