:root {
  color-scheme: dark;
  --bg: #080a07;
  --bg-soft: #10140d;
  --paper: #f3efe5;
  --paper-2: #ded8c9;
  --ink: #f6f2e8;
  --muted: #a8b09d;
  --acid: #b7ff37;
  --cyan: #6fd5ff;
  --amber: #ffbd63;
  --red: #ff6868;
  --line: rgba(246, 242, 232, 0.14);
  --line-strong: rgba(246, 242, 232, 0.3);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
  margin: 0;
  background: var(--bg);
  color: var(--ink);
}

body {
  overflow: hidden;
}

a {
  color: inherit;
}

.deck-frame {
  position: fixed;
  z-index: 30;
  top: 0;
  left: 0;
  right: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  pointer-events: none;
}

.deck-wordmark,
.deck-frame__meta,
.deck-link,
.deck-lab {
  pointer-events: auto;
}

.deck-wordmark {
  color: var(--ink);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0;
  text-decoration: none;
}

.deck-frame__meta {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.deck-link {
  display: inline-flex;
  min-height: 2rem;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 0.72rem;
  color: var(--ink);
  text-decoration: none;
}

.deck-lab {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.deck-link:hover,
.deck-link:focus-visible {
  border-color: var(--cyan);
  outline: none;
}

.deck-progress {
  position: fixed;
  z-index: 25;
  top: 50%;
  right: 1.25rem;
  display: grid;
  gap: 0.5rem;
  transform: translateY(-50%);
}

.deck-progress button {
  width: 0.75rem;
  height: 0.75rem;
  border: 0;
  border-radius: 999px;
  background: rgba(246, 242, 232, 0.18);
  cursor: pointer;
  transition: background 180ms ease, transform 180ms ease;
}

.deck-progress button.is-active {
  background: var(--acid);
  transform: scale(1.35);
}

.deck {
  height: 100svh;
  overflow-y: auto;
  scroll-behavior: smooth;
  scroll-snap-type: y mandatory;
}

.slide {
  position: relative;
  min-height: 100svh;
  scroll-snap-align: start;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(246, 242, 232, 0.045) 1px, transparent 1px),
    linear-gradient(rgba(246, 242, 232, 0.035) 1px, transparent 1px),
    linear-gradient(135deg, #0a0d08 0%, #14180f 54%, #080a07 100%);
  background-size: 7rem 7rem, 7rem 7rem, auto;
  color: var(--ink);
  isolation: isolate;
}

.slide::after {
  content: "";
  position: absolute;
  inset: auto -10vw -22vh -10vw;
  height: 45vh;
  background: linear-gradient(90deg, rgba(215, 183, 108, 0.12), rgba(128, 214, 255, 0.1), rgba(241, 168, 91, 0.08));
  transform: skewY(-4deg);
  pointer-events: none;
  z-index: -1;
}

.slide--dark {
  background:
    linear-gradient(90deg, rgba(215, 183, 108, 0.06) 1px, transparent 1px),
    linear-gradient(rgba(128, 214, 255, 0.045) 1px, transparent 1px),
    #050604;
  background-size: 6rem 6rem, 6rem 6rem, auto;
}

.slide--accent {
  background:
    linear-gradient(90deg, rgba(8, 10, 7, 0.08) 1px, transparent 1px),
    linear-gradient(rgba(8, 10, 7, 0.08) 1px, transparent 1px),
    linear-gradient(135deg, #b7ff37 0%, #e4ffad 56%, #f3efe5 100%);
  background-size: 6rem 6rem, 6rem 6rem, auto;
  color: #11140e;
}

.slide--closing,
.slide--cover {
  background:
    linear-gradient(90deg, rgba(246, 242, 232, 0.05) 1px, transparent 1px),
    linear-gradient(rgba(246, 242, 232, 0.035) 1px, transparent 1px),
    linear-gradient(150deg, #020302 0%, #0f140b 54%, #1d2612 100%);
  background-size: 8rem 8rem, 8rem 8rem, auto;
}

.slide__inner {
  position: relative;
  width: min(1180px, calc(100vw - 6rem));
  min-height: 100svh;
  margin: 0 auto;
  padding: 6.5rem 0 4.5rem;
}

.slide__eyebrow {
  margin: 0 0 1rem;
  color: var(--acid);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.slide--accent .slide__eyebrow {
  color: #33410c;
}

h1,
h2,
p {
  margin-top: 0;
}

h1 {
  max-width: 14ch;
  margin-bottom: 1.25rem;
  font-size: clamp(3.1rem, 6.7vw, 5.65rem);
  line-height: 0.92;
  letter-spacing: 0;
}

h2 {
  max-width: 14ch;
  margin-bottom: 1.1rem;
  font-size: clamp(2.4rem, 5.2vw, 4.8rem);
  line-height: 0.94;
  letter-spacing: 0;
}

.cover-lede,
.slide-statement,
.slide-support {
  max-width: 52rem;
  color: var(--paper-2);
  font-size: clamp(1.15rem, 2vw, 1.65rem);
  line-height: 1.35;
}

.slide--accent .slide-support {
  color: rgba(17, 20, 14, 0.72);
}

.cover-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) 24rem;
  align-items: center;
  gap: 4rem;
}

.cover-signal {
  border-top: 4px solid var(--acid);
  padding-top: 1.2rem;
}

.cover-signal span,
.metric-wall span,
.gate-stack span,
.operator-command span {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.cover-signal strong {
  display: block;
  margin: 0.35rem 0 0.7rem;
  color: var(--acid);
  font-size: 2.2rem;
  line-height: 1;
}

.cover-signal p {
  color: var(--paper-2);
  line-height: 1.5;
}

.thesis-layout {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  align-items: center;
  gap: 4rem;
}

.signal-ribbon {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.signal-ribbon span {
  min-height: 6.2rem;
  display: flex;
  align-items: center;
  border-right: 1px solid var(--line);
  color: var(--ink);
  font-size: clamp(1rem, 2vw, 1.45rem);
  font-weight: 900;
}

.signal-ribbon span:last-child {
  border-right: 0;
}

.metric-wall {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  margin: 3rem 0 1.5rem;
}

.metric-wall article {
  min-height: 13rem;
  border-top: 3px solid var(--line-strong);
  padding-top: 1rem;
}

.metric-wall article:first-child {
  border-top-color: var(--acid);
}

.metric-wall strong {
  display: block;
  margin: 0.65rem 0 0.8rem;
  color: var(--ink);
  font-size: clamp(2rem, 4.6vw, 4.3rem);
  line-height: 0.95;
}

.metric-wall p,
.slide-note,
.loop-diagram p,
.operator-command code {
  color: var(--muted);
  line-height: 1.45;
}

.slide-note {
  max-width: 54rem;
  font-size: 1rem;
}

.loop-diagram {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1px;
  margin-top: 3.5rem;
  background: var(--line);
}

.loop-diagram div {
  min-height: 22rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  background: rgba(8, 10, 7, 0.72);
  padding: 1.2rem;
}

.loop-diagram span {
  color: var(--acid);
  font-size: 3.2rem;
  font-weight: 900;
  line-height: 1;
}

.loop-diagram strong {
  display: block;
  color: var(--ink);
  font-size: 1.55rem;
  line-height: 1.08;
}

.gate-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 31rem;
  align-items: center;
  gap: 4rem;
}

.gate-stack {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: rgba(17, 20, 14, 0.18);
}

.gate-stack div {
  min-height: 8.4rem;
  background: rgba(255, 255, 255, 0.32);
  padding: 1rem;
}

.gate-stack strong {
  display: block;
  color: #11140e;
  font-size: 3.25rem;
  line-height: 0.95;
}

.gate-stack span {
  margin-top: 0.65rem;
  color: rgba(17, 20, 14, 0.7);
}

.demo-layout,
.operator-layout,
.closing-layout {
  display: grid;
  align-content: center;
}

.demo-actions,
.closing-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 2rem 0;
}

.deck-button {
  min-height: 3.2rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--acid);
  border-radius: 999px;
  padding: 0 1.25rem;
  background: var(--acid);
  color: #11140e;
  font-weight: 900;
  text-decoration: none;
}

.deck-button--secondary {
  border-color: var(--cyan);
  background: transparent;
  color: var(--cyan);
}

.api-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

code {
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.45rem 0.55rem;
  background: rgba(255, 255, 255, 0.05);
  color: var(--paper);
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 0.88rem;
}

.operator-command {
  display: grid;
  gap: 0.75rem;
  max-width: 62rem;
  margin-top: 2rem;
}

.operator-command code {
  display: block;
  width: 100%;
  overflow-wrap: anywhere;
}

.closing-layout h2 {
  max-width: 16ch;
}

@media (max-width: 980px) {
  .slide__inner {
    width: min(100vw - 2rem, 720px);
    padding-top: 6rem;
  }

  .cover-grid,
  .thesis-layout,
  .gate-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  h1 {
    font-size: clamp(3.2rem, 15vw, 5.3rem);
  }

  h2 {
    font-size: clamp(2.5rem, 12vw, 4.6rem);
  }

  .metric-wall,
  .loop-diagram,
  .signal-ribbon {
    grid-template-columns: 1fr;
  }

  .signal-ribbon span,
  .loop-diagram div {
    min-height: auto;
    padding: 1.25rem 0;
  }

  .metric-wall article {
    min-height: auto;
  }

  .deck-frame {
    align-items: flex-start;
  }

  .deck-frame__meta {
    flex-wrap: wrap;
  }

  .deck-progress {
    display: none;
  }
}

@media (max-width: 640px) {
  .deck-link {
    min-height: 1.8rem;
    padding: 0 0.55rem;
  }

  .deck-frame {
    padding: 0.75rem;
  }

  .deck-frame__meta {
    gap: 0.4rem;
    font-size: 0.72rem;
  }

  .gate-stack {
    grid-template-columns: 1fr;
  }
}
