@font-face { font-family: InterVar; src: local("Inter"); font-display: swap; }

:root {
  --bg: oklch(97% 0.012 80);
  --surface: oklch(99% 0.005 80);
  --fg: oklch(20% 0.02 60);
  --muted: oklch(48% 0.015 60);
  --dim: oklch(58% 0.012 60);
  --border: oklch(89% 0.012 80);
  --accent: oklch(58% 0.16 35);
  --dark: oklch(20% 0.02 60);
  --on-dark: oklch(99% 0.005 80);

  --font-display: 'Iowan Old Style', 'Charter', Georgia, serif;
  --font-body: InterVar, -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', 'IBM Plex Mono', ui-monospace, Menlo, monospace;

  --container: 1180px;
  --gutter: clamp(14px, 4vw, 40px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    linear-gradient(90deg, color-mix(in oklch, var(--border), transparent 65%) 1px, transparent 1px),
    linear-gradient(180deg, color-mix(in oklch, var(--border), transparent 74%) 1px, transparent 1px),
    var(--bg);
  background-size: 64px 64px;
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.55;
}

a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible, input:focus-visible, textarea:focus-visible, select:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}
p { color: var(--muted); line-height: 1.68; }
img, svg { max-width: 100%; }

.page { min-height: 100vh; }
.shell,
.section {
  width: min(var(--container), calc(100% - var(--gutter)));
  margin-inline: auto;
}
.mono,
.eyebrow,
.meta {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.eyebrow { color: var(--accent); margin: 0 0 16px; }
.label, .meta { color: var(--muted); }

.masthead,
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 22px 0;
  border-bottom: 1px solid var(--border);
}
.brand {
  display: grid;
  gap: 1px;
  font-weight: 500;
}
.wordmark {
  font-family: var(--font-display);
  font-size: 24px;
  line-height: .95;
  letter-spacing: 0;
}
.nav,
.footer-links,
.links {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 22px;
  color: var(--muted);
  font-size: 14px;
}
.nav a:hover,
.footer-links a:hover,
.links a:hover,
.nav a.is-active { color: var(--fg); }
.nav a.is-active:not(.nav-cta) { box-shadow: inset 0 -1px 0 var(--accent); }
.nav-cta.is-active { background: var(--fg); color: var(--surface); }
.nav-cta,
.nav a:last-child {
  color: var(--fg);
  border: 1px solid var(--fg);
  padding: 8px 12px;
}
.nav-cta.is-active { background: var(--fg); color: var(--surface); }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, .95fr);
  gap: 56px;
  padding: 72px 0 56px;
  align-items: end;
  border-bottom: 1px solid var(--border);
}
.hero h1,
h1 {
  margin: 0;
  max-width: 860px;
  font-family: var(--font-display);
  font-size: clamp(54px, 8.6vw, 132px);
  line-height: .86;
  font-weight: 500;
  letter-spacing: 0;
  text-wrap: balance;
}
.deck {
  max-width: 640px;
  margin: 28px 0 0;
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 38px);
  line-height: 1.14;
  color: color-mix(in oklch, var(--fg), var(--muted) 18%);
  text-wrap: pretty;
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}
.button,
button {
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 11px 16px;
  border: 1px solid var(--fg);
  background: transparent;
  color: var(--fg);
  border-radius: 0;
  font: inherit;
  font-weight: 650;
  transition: transform .18s ease, background .18s ease, color .18s ease, border-color .18s ease;
}
.button:hover,
button:hover { transform: translateY(-1px); }
.button.primary { background: var(--fg); color: var(--surface); }
.button.secondary { background: transparent; color: var(--fg); }
.button.primary:hover { background: var(--accent); border-color: var(--accent); }
.button.secondary:hover,
.nav-cta:hover { background: var(--fg); color: var(--surface); }

.signal-card {
  background: var(--surface);
  border: 1px solid var(--fg);
  min-height: 470px;
  padding: 24px;
  position: relative;
  overflow: hidden;
  display: grid;
  align-content: space-between;
}
.signal-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 18%, color-mix(in oklch, var(--accent), transparent 76%), transparent 26%),
    repeating-linear-gradient(112deg, transparent 0 9px, color-mix(in oklch, var(--fg), transparent 92%) 10px 11px),
    linear-gradient(180deg, transparent, color-mix(in oklch, var(--bg), transparent 12%));
  opacity: .9;
}
.signal-card > * { position: relative; z-index: 1; }
.signal-top {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
}
.signal-svg { width: 100%; height: 230px; margin: 42px 0 30px; }
.signal-svg path,
.signal-svg line,
.signal-svg circle { vector-effect: non-scaling-stroke; }
.signal-caption {
  display: grid;
  grid-template-columns: 82px 1fr;
  gap: 16px;
  align-items: start;
  font-size: 14px;
  color: var(--muted);
  border-top: 1px solid var(--border);
  padding-top: 18px;
}
.signal-caption strong {
  display: block;
  font-family: var(--font-display);
  font-size: 28px;
  line-height: .95;
  color: var(--fg);
  font-weight: 500;
}

.tag-rail,
.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.tag-rail {
  padding: 22px 0;
  border-bottom: 1px solid var(--border);
}
.tag {
  border: 1px solid var(--border);
  background: color-mix(in oklch, var(--surface), transparent 22%);
  padding: 8px 10px;
  color: var(--muted);
  font-size: 13px;
  border-radius: 0;
  transition: color .18s ease, border-color .18s ease, background .18s ease;
}
.tag:hover,
.tag.is-hot { color: var(--fg); border-color: var(--fg); }

.section {
  padding: 58px 0;
  border-bottom: 1px solid var(--border);
}
.section-head {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 36px;
  margin-bottom: 28px;
}
.section-kicker { color: var(--muted); padding-top: 7px; }
h2 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(34px, 4vw, 58px);
  line-height: .98;
  font-weight: 500;
  text-wrap: balance;
}
h3 {
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.02;
  font-weight: 500;
  text-wrap: balance;
}
.grid,
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--fg);
  border-left: 1px solid var(--fg);
  gap: 0;
}
.grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  border: 0;
  gap: 24px;
}
.card,
.post-card {
  min-height: 260px;
  padding: 22px;
  border-right: 1px solid var(--fg);
  border-bottom: 1px solid var(--fg);
  background: color-mix(in oklch, var(--surface), transparent 10%);
  display: grid;
  align-content: space-between;
  gap: 24px;
  transition: background .18s ease, color .18s ease;
}
.card:hover,
.post-card:hover { background: color-mix(in oklch, var(--accent), var(--surface) 90%); }
.card .meta,
.post-card .meta {
  display: flex;
  justify-content: space-between;
  gap: 16px;
}
.meta span + span::before { content: '/ '; opacity: .55; }
.card .meta span + span::before,
.post-card .meta span + span::before { content: ''; }
.project-list .meta { justify-content: flex-start; gap: 12px; }
.project-list .meta span + span::before { content: '/ '; opacity: .55; }
.card h3,
.post-card h3 { font-size: 30px; }
.card p,
.post-card p { margin: 12px 0 0; color: var(--muted); }
.takeaway {
  color: var(--fg) !important;
  border-left: 2px solid var(--accent);
  padding-left: 1rem;
}
.stack {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--fg);
  border-left: 1px solid var(--fg);
}
.stack > .card,
.stack > .post-card { min-height: 190px; }

.project-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 24px;
}
.project-log {
  background: var(--fg);
  color: var(--surface);
  padding: 28px;
  min-height: 390px;
  display: grid;
  align-content: space-between;
}
.project-log .mono,
.project-log .meta { color: color-mix(in oklch, var(--surface), transparent 18%); }
.project-log p { color: color-mix(in oklch, var(--surface), transparent 20%); }
.project-log .risk-note { color: var(--fg); }
.project-log .tag {
  color: color-mix(in oklch, var(--surface), transparent 18%);
  border-color: color-mix(in oklch, var(--surface), transparent 68%);
  background: transparent;
}
.project-log .tag:hover { color: var(--surface); border-color: var(--surface); }
.project-log h3 {
  max-width: 640px;
  font-size: clamp(38px, 5vw, 72px);
  line-height: .94;
}
.timeline {
  border-left: 1px solid color-mix(in oklch, var(--surface), transparent 58%);
  margin-top: 36px;
  display: grid;
  gap: 18px;
}
.log-item {
  padding-left: 18px;
  color: color-mix(in oklch, var(--surface), transparent 16%);
}
.log-item strong { color: var(--surface); display: block; }
.video-card {
  border: 1px solid var(--fg);
  background: var(--surface);
  min-height: 390px;
  padding: 20px;
  display: grid;
  gap: 18px;
}
.video-window {
  min-height: 220px;
  border: 1px solid var(--fg);
  background:
    linear-gradient(90deg, var(--fg) 0 1px, transparent 1px 100%),
    linear-gradient(180deg, var(--fg) 0 1px, transparent 1px 100%),
    color-mix(in oklch, var(--border), var(--surface) 62%);
  background-size: 28px 28px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}
.play-mark {
  width: 74px;
  height: 74px;
  border: 1px solid var(--fg);
  background: var(--surface);
  clip-path: polygon(30% 18%, 30% 82%, 82% 50%);
}
.video-card h3 { font-size: 32px; }
.company-strip {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--fg);
  border: 1px solid var(--fg);
}
.company {
  background: var(--surface);
  padding: 24px;
  min-height: 210px;
}
.company:hover { background: color-mix(in oklch, var(--accent), var(--surface) 90%); }
.company h3 {
  margin: 0 0 42px;
  font-size: 38px;
  line-height: .95;
}
.resource-list {
  display: grid;
  gap: 1px;
  background: var(--border);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}
.resource {
  display: grid;
  grid-template-columns: 160px 1fr 110px;
  gap: 24px;
  align-items: center;
  background: color-mix(in oklch, var(--surface), transparent 16%);
  padding: 20px 0;
}
.resource h3 { font-size: 28px; line-height: 1; }
.resource h3 a { color: inherit; }
.resource h3 a:hover,
.resource > a:hover { color: var(--accent); }
.resource p { margin: 6px 0 0; color: var(--muted); }
.cta {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 40px;
  background: var(--fg);
  color: var(--surface);
  padding: 34px;
  align-items: end;
}
.cta h2 { max-width: 780px; color: var(--surface); }
.cta p { margin: 18px 0 0; max-width: 660px; color: color-mix(in oklch, var(--surface), transparent 22%); }
.cta .button {
  border-color: var(--surface);
  color: var(--fg);
  background: var(--surface);
  width: 100%;
}
.cta .button:hover { background: var(--accent); border-color: var(--accent); color: var(--surface); }

.page-hero { padding-top: clamp(58px, 10vw, 118px); }
.page-hero > p:not(.eyebrow):not(.deck) { max-width: 760px; }
.project-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
}
.project-list > article:first-child:last-child { grid-column: 1 / -1; }
.risk-note {
  margin: 24px 0 0;
  padding: 14px 16px;
  border: 1px solid color-mix(in oklch, var(--accent), transparent 35%);
  color: var(--fg);
  background: color-mix(in oklch, var(--accent), var(--surface) 88%);
  font-size: .95rem;
}
.article { max-width: 820px; }
.article-wide { max-width: var(--container); }
.article h1 { font-size: clamp(42px, 7vw, 82px); line-height: .94; }
.article h2 { margin-top: 3rem; font-size: clamp(30px, 4vw, 48px); }
.article p,
.article li { font-size: 1.08rem; color: var(--muted); line-height: 1.78; }
.article ul,
.article ol { color: var(--muted); }
.article-meta-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--fg);
  border-left: 1px solid var(--fg);
  margin: 32px 0 22px;
}
.article-meta-grid.compact { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.article-meta-grid > div {
  padding: 16px;
  border-right: 1px solid var(--fg);
  border-bottom: 1px solid var(--fg);
  background: color-mix(in oklch, var(--surface), transparent 12%);
}
.article-meta-grid span { display: block; color: var(--muted); margin-bottom: 8px; }
.article-meta-grid strong {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1;
  font-weight: 500;
  color: var(--fg);
}
.content-panel {
  margin-top: 32px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
}
.content-panel :first-child { margin-top: 0; }
.embed { border: 1px solid var(--fg); overflow: hidden; background: var(--surface); margin: 2rem 0; }
.embed iframe { width: 100%; aspect-ratio: 16/9; border: 0; display: block; }
.embed.tiktok { padding: 1.2rem; }
.embed-label { color: var(--accent); margin: 0; }
.embed-note { font-size: .9rem; color: var(--dim); margin-bottom: 0; }
.form { display: grid; gap: .8rem; }
input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--fg);
  background: color-mix(in oklch, var(--surface), transparent 12%);
  color: var(--fg);
  padding: .9rem 1rem;
  border-radius: 0;
  font: inherit;
}
textarea { min-height: 9rem; }
.site-footer {
  padding: 34px 0 44px;
  display: flex;
  justify-content: space-between;
  gap: 28px;
  color: var(--muted);
}
.site-footer strong { color: var(--fg); }
.site-footer p { margin: 6px 0 0; max-width: 520px; }

@media (max-width: 880px) {
  body { background-size: 48px 48px; }
  .masthead, .site-header { align-items: start; }
  .nav { display: none; }
  .hero,
  .section-head,
  .project-grid,
  .project-list,
  .article-meta-grid,
  .cta,
  .grid.two { grid-template-columns: 1fr; }
  .hero { padding-top: 48px; gap: 34px; }
  .signal-card { min-height: 390px; }
  .grid,
  .grid-3,
  .company-strip { grid-template-columns: 1fr; }
  .resource { grid-template-columns: 1fr; gap: 8px; padding: 18px 0; }
  .site-footer { display: grid; }
}

@media (max-width: 560px) {
  :root { --gutter: 28px; }
  .hero-actions { display: grid; }
  .section { padding: 42px 0; }
  .signal-caption { grid-template-columns: 1fr; }
  .card,
  .post-card,
  .company,
  .project-log,
  .cta { padding: 20px; }
  .hero h1,
  h1 { font-size: clamp(48px, 18vw, 86px); }
  .deck { font-size: clamp(22px, 8vw, 32px); }
}

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