/* v7 base: fonts, the site's short token names, base elements, layout, type roles, buttons and
   links. Every page loads tokens.css, then this, then its own sheet.

   Colour comes only from tokens.css, which is generated from the LeoPrevent design system, so this
   file names tokens and never holds a colour of its own. The site is light by decision; a page or a
   band opts into the dark values with data-tone="dark", which tokens.css restates every token for. */

/* Geist and Geist Mono are the design skill's own files (leotrace-design assets, 2026-10-07), the build the
   prototype was drawn with. The query string changes whenever the files do, so no browser keeps a stale one. */
@font-face {
  font-family: "Geist";
  src: url("../../fonts/Geist-Variable.woff2?v=skill-2026-10-07") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Geist Mono";
  src: url("../../fonts/GeistMono-Variable.woff2?v=skill-2026-10-07") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* ── Short names ──────────────────────────────────────────────────────────────
   The names the page sheets use, each bound to one semantic token. They are declared on every
   mode block, not only on :root, because a var() inside a custom property resolves where it is
   declared: an alias set once on :root would carry its light value into a dark band. */

:root, [data-tone] {
  --bg: var(--lt-background-canvas);
  --bg-soft: var(--lt-background-sidebar);
  --bg-sunken: var(--lt-background-sunken);
  --surface: var(--lt-container-raised);
  --chip: var(--lt-container-chip);
  --hover: var(--lt-container-hover);
  --selected: var(--lt-container-selected);

  --fg-strong: var(--lt-foreground-primary-strong);
  --fg: var(--lt-foreground-primary);
  --fg-2: var(--lt-foreground-secondary);
  --fg-3: var(--lt-foreground-tertiary);
  --fg-4: var(--lt-foreground-quaternary);
  --fg-disabled: var(--lt-foreground-disabled);

  --line-faint: var(--lt-outline-faint);
  --line: var(--lt-outline-subtle);
  --line-strong: var(--lt-outline-default);
  --line-interactive: var(--lt-outline-interactive);
  --focus: var(--lt-outline-focus);

  --shadow-menu: var(--lt-shadow-overlay);

  background: var(--bg);
  color: var(--fg);
}

:root {
  --sans: var(--lt-font-sans);
  --mono: var(--lt-font-mono);
  --content: 1200px;
  /* The one page gutter: 20px on a phone, growing to 40px by 1000px, never inside the safe area. The
     nav, footer, .wrap and every framed column read it, so all their left edges line up. */
  --gutter: max(20px, env(safe-area-inset-left, 0px), min(40px, 4vw));
  --gutter-r: max(20px, env(safe-area-inset-right, 0px), min(40px, 4vw));
  --nav-h: 56px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

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

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--nav-h) + 24px); }
/* Smooth only once the page has loaded (js/v7/core.js), so arriving at /about/#team lands, never rides 3,600px */
html.is-smooth { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 24px;
  text-rendering: optimizeLegibility;
}
.site { min-height: 100vh; display: flex; flex-direction: column; }
.site > main { flex: 1; }
a { color: inherit; text-decoration: none; }
img, svg, canvas, video { max-width: 100%; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
h1, h2, h3, h4, p { margin: 0; }
h1, h2, h3 { text-wrap: balance; }
p { text-wrap: pretty; }

.wrap {
  width: 100%;
  max-width: calc(var(--content) + 2 * 40px);
  margin-inline: auto;
  padding-left: var(--gutter);
  padding-right: var(--gutter-r);
}

/* ── Type roles ───────────────────────────────────────────────────────────────
   The website standard's roles (11 Nov): display type is Medium with negative tracking, the web's one
   exception to the system's zero letter spacing, and only on 24px and up. Geist for anything a person
   wrote and Geist Mono for labels only; the two line device pairs tertiary with primary. Caps are typed
   into the copy, never applied with text-transform. */

.t-display { font-weight: 540; font-size: clamp(40px, 6vw, 64px); line-height: 1; letter-spacing: var(--tr-display); }
.t-title { font-weight: 520; font-size: clamp(32px, 4.2vw, 48px); line-height: 1.04; letter-spacing: var(--tr-headline); }
.t-heading { font-weight: 600; font-size: 24px; line-height: 32px; }
.t-lead { font-size: 18px; line-height: 30px; color: var(--fg-3); max-width: 640px; }
.t-body { font-size: 16px; line-height: 24px; color: var(--fg-3); }
.t-small { font-size: 14px; line-height: 20px; color: var(--fg-3); }
.t-eyebrow { font-family: var(--mono); font-size: 12px; line-height: 16px; color: var(--fg-4); letter-spacing: 0; }
.tone-2 { color: var(--fg-3); }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; }

/* ── Buttons ──────────────────────────────────────────────────────────────────
   The design system's .lt-btn, state for state: primary moves its fill and brightens as it is
   pressed, the others take the alpha overlay so one value steps correctly on any surface. Large
   is .btn, Medium is .btn--sm. */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--lt-space-2);
  height: 40px;
  padding-inline: var(--lt-space-6);
  border-radius: 10px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 500;
  line-height: 20px;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 120ms ease, border-color 120ms ease, color 120ms ease;
}
.btn::after {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: inherit;
  background: transparent;
  pointer-events: none;
  transition: background-color 120ms ease;
}
.btn--sm { height: 32px; padding-inline: var(--lt-space-5); border-radius: 8px; }

.btn--primary { background: var(--lt-foreground-secondary); color: var(--lt-container-base); }
.btn--primary:hover { background: var(--lt-foreground-secondary-strong); }
.btn--primary:active { background: var(--lt-foreground-primary); }

.btn--secondary { background: var(--lt-container-raised); color: var(--lt-foreground-primary); }

.btn--tertiary { border-color: var(--lt-outline-default); color: var(--lt-foreground-secondary); }
.btn--tertiary:hover { border-color: var(--lt-outline-interactive); color: var(--lt-foreground-primary); }

.btn--ghost { color: var(--lt-foreground-secondary); padding-inline: var(--lt-space-3); }
.btn--ghost:hover { color: var(--lt-foreground-primary); }

.btn--secondary:hover::after, .btn--tertiary:hover::after, .btn--ghost:hover::after { background: var(--lt-container-hover); }
.btn--secondary:active::after, .btn--tertiary:active::after, .btn--ghost:active::after { background: var(--lt-container-selected); }

.btn .ico { width: 16px; height: 16px; transition: transform 150ms var(--ease); }
.btn:hover .ico--arrow, .link-arrow:hover .ico--arrow { transform: translateX(2px); }
.btn-row { display: flex; flex-wrap: wrap; align-items: center; gap: var(--lt-space-3); }

/* ── Links, icons and chips ───────────────────────────────────────────────── */

.link-arrow { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; font-weight: 500; color: var(--fg-2); transition: color 120ms ease; }
.link-arrow:hover { color: var(--fg); }
.link-arrow .ico { width: 16px; height: 16px; transition: transform 150ms var(--ease); }

.ico { display: block; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

/* The eyebrow as a pill that links somewhere, the one place an eyebrow is a control */
.chip-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  height: 28px;
  padding: 0 10px 0 4px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 13px;
  color: var(--fg-2);
  background: var(--bg);
  transition: border-color 120ms ease, background-color 120ms ease;
}
.chip-link:hover { border-color: var(--line-strong); background: var(--bg-soft); }
.chip-link__tag { font-family: var(--mono); font-size: 12px; line-height: 20px; padding-inline: 8px; border-radius: 999px; background: var(--bg-sunken); color: var(--fg-2); }
.chip-link .ico { width: 14px; height: 14px; color: var(--fg-4); transition: transform 150ms var(--ease); }

/* A section's eyebrow, set on a recessed chip */
.label-chip { display: inline-flex; align-items: center; height: 24px; padding-inline: 8px; border-radius: 6px; background: var(--bg-sunken); border: 1px solid var(--line); font-family: var(--mono); font-size: 12px; line-height: 16px; color: var(--fg-2); }

/* ── Status and control names the page sheets use ─────────────────────────────
   Each is one semantic token. Restated on every mode block for the reason given at the top. */

:root, [data-tone] {
  --green: var(--lt-green-accent);
  --green-accent: var(--lt-green-accent);
  --green-fg: var(--lt-green-fg-status);
  --green-muted: var(--lt-green-fg-status);
  --green-fill: var(--lt-green-fill-status);
  --red-accent: var(--lt-red-accent);
  --red-muted: var(--lt-red-fg-status);
  --red-fill: var(--lt-red-fill-status);
  --violet: var(--lt-purple-accent);
  --violet-fg: var(--lt-purple-fg-status);
  --violet-fill: var(--lt-purple-fill-status);
  --recessed: var(--lt-container-recessed);
  --btn-bg: var(--lt-foreground-secondary);
  --btn-bg-hover: var(--lt-foreground-secondary-strong);
  --btn-bg-active: var(--lt-foreground-primary);
  --btn-fg: var(--lt-container-base);
  --nav-glass: color-mix(in srgb, var(--lt-background-canvas) 88%, transparent);
  /* A window's three dots are the system's own status accents, not the macOS colours */
  --dot-red: var(--lt-red-accent);
  --dot-yellow: var(--lt-yellow-accent);
  --dot-green: var(--lt-green-accent);
}

/* ── The website standard ─────────────────────────────────────────────────────
   Agreed 6 November: Attio's framed column with Linear's keylines. A page opts in with data-std on
   .site. The marketing type scale lives here as font shorthands, with each display role's tracking
   beside it (--tr-*): a rule that sets one of these fonts sets its tracking too. Johnny's 11 Nov roles:
   Display 540 64/64, Headline 520 48/50, Column headline 520 28/34, the close 520 40/42, Lead 18/27,
   Title 500 16/22; under 24px the tracking is zero. */

:root {
  --cell: 40px;
  --t-display: 540 64px/64px var(--sans);
  --t-headline: 520 48px/50px var(--sans);
  --t-headline-col: 520 28px/34px var(--sans);
  --t-close: 520 40px/42px var(--sans);
  --t-lead: 400 18px/27px var(--sans);
  --t-figure: 700 48px/56px var(--sans);
  --t-title: 500 16px/22px var(--sans);
  --tr-display: -0.022em;
  --tr-headline: -0.02em;
  --tr-headline-col: -0.015em;
  --t-body: 400 15px/24px var(--sans);
  --t-small: 400 14px/20px var(--sans);
  --t-action: 500 14px/20px var(--sans);
  --t-eyebrow: 400 12px/16px var(--mono);
  --t-meta: 400 12px/16px var(--mono);
  --t-code: 400 13px/20px var(--mono);
}
@media (max-width: 760px) {
  :root { --cell: 20px; --t-display: 540 40px/42px var(--sans); --t-headline: 520 32px/34px var(--sans); --t-headline-col: 520 24px/30px var(--sans); --t-close: 520 30px/32px var(--sans); --t-lead: 400 17px/25px var(--sans); --t-title: 500 15px/21px var(--sans); --t-figure: 700 32px/40px var(--sans); --tr-display: -0.02em; }
}

/* A small phone (320 to 360) takes one step down, so a display line keeps three or four words */
@media (max-width: 360px) {
  :root { --t-display: 540 34px/36px var(--sans); --t-headline: 520 28px/30px var(--sans); }
  .t-display { font-size: 34px; }
}

[data-std] .t-display { font: var(--t-display); letter-spacing: var(--tr-display); }
[data-std] .t-lead { font: var(--t-lead); color: var(--fg-3); max-width: 560px; }
[data-std] .label-chip { font: var(--t-eyebrow); }
[data-std] .btn, [data-std] .link-arrow { font: var(--t-action); }

/* Sections rising in as they arrive (js/v7/core.js lowers only what starts below the fold) */
/* The settle (the standard's M2): 500ms on one curve, a 12px rise */
:root { --settle: cubic-bezier(0.44, 0, 0.56, 1); }
.reveal { transition: opacity 500ms var(--settle), transform 500ms var(--settle); }
.reveal.is-pre { opacity: 0; transform: translateY(12px); }
/* An H1 marked data-resolve resolves word by word (js/v7/core.js), the one headline that moves */
/* The fill runs backwards only, so a settled word carries no filter at all, and once the last word lands the
   script marks the heading resolved and the animation comes off every word. Holding the final frame left Safari
   on a phone with a word stuck mid blur ("every" on Home, where the grey half is an inline-block) */
.js-resolve h1[data-resolve] .wd { display: inline-block; white-space: nowrap; animation: h1-resolve 500ms var(--settle) backwards; animation-delay: calc(var(--i) * 60ms); }
.js-resolve h1[data-resolve].is-resolved .wd { animation: none; }
@keyframes h1-resolve { from { opacity: 0; filter: blur(6px); transform: translateY(8px); } to { opacity: 1; filter: blur(0); transform: none; } }

/* ── Touch ────────────────────────────────────────────────────────────────────
   Every target a finger hits is at least 44px tall. A text link keeps its look and gains an invisible
   hit area; buttons grow to 44 on a phone, and a pair of them shares the row evenly or stacks full width. */

.link-arrow { position: relative; }
.link-arrow::before { content: ''; position: absolute; inset: -12px 0; }
@media (max-width: 760px) {
  .btn { height: 44px; }
}
@media (max-width: 480px) {
  .btn-row > .btn { flex: 1 1 auto; }
}
/* The linked eyebrow may wrap on a small phone: the pill grows with it rather than spilling */
@media (max-width: 400px) {
  .chip-link { height: auto; min-height: 28px; padding-block: 3px; padding-right: 8px; gap: 6px; border-radius: 14px; font-size: 12px; }
  .chip-link__tag { white-space: nowrap; }
}

/* ── Section strip (js/v7/sectionbar.js) ─────────────────────────────────────
   Where the contents list is hidden (a phone or a tablet), a sticky row of chips built from it jumps
   between sections and marks the one being read. Snap scrolling, a fade at the right edge to say there
   is more, 40px targets. With no script there is no strip. Shared by every
   page whose contents list carries data-sectionbar. */
.sectionbar { display: none; }
@media (max-width: 1023px) {
  .sectionbar { display: block; position: sticky; top: calc(var(--nav-h) + env(safe-area-inset-top, 0px)); z-index: 20; margin-inline: calc(-1 * var(--gutter)) calc(-1 * var(--gutter-r)); border-bottom: 1px solid var(--line); background: var(--nav-glass); -webkit-backdrop-filter: saturate(180%) blur(16px); backdrop-filter: saturate(180%) blur(16px); }
  .sectionbar__track { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; scroll-snap-type: x proximity; scroll-padding-inline: var(--gutter); padding: 6px calc(var(--gutter-r) + 32px) 6px var(--gutter); -webkit-mask-image: linear-gradient(90deg, black calc(100% - 48px), transparent); mask-image: linear-gradient(90deg, black calc(100% - 48px), transparent); }
  .sectionbar__track::-webkit-scrollbar { display: none; }
  .sectionbar__chip { flex: none; display: inline-flex; align-items: center; height: 40px; padding-inline: 12px; border-radius: 8px; font: var(--t-action); color: var(--fg-3); white-space: nowrap; scroll-snap-align: start; transition: color 120ms ease, background-color 120ms ease; }
  .sectionbar__chip[aria-current='true'] { color: var(--fg); background: var(--selected); }
}
@media (max-width: 1023px) and (hover: hover) {
  .sectionbar__chip:hover { color: var(--fg); background: var(--hover); }
}

@media (prefers-color-scheme: dark) {
  :is(img[src*="/logos/si/"],
  img[src$="/bitbucket.svg"],
  img[src$="/copilot.svg"],
  img[src$="/cursor.svg"],
  img[src$="/devin.svg"],
  img[src$="/gemini.svg"],
  img[src$="/github.svg"],
  img[src$="/twinpath.svg"],
  img[src$="/outward.svg"],
  img[src$="/jira.svg"],
  img[src$="/openai.svg"],
  img[src$="/opencode.svg"],
  img[src$="/windsurf.svg"],
  img[src$="/amazon-inspector.svg"],
  img[src$="/codacy.svg"],
  img[src$="/hackerone.svg"],
  img[src$="/intigriti.svg"],
  img[src$="/prisma-cloud.svg"],
  img[src$="/sonatype.svg"]) { filter: invert(1) hue-rotate(180deg); }
}
