@property --red-hot {
  syntax: "<color>";
  inherits: false;
  initial-value: #e03030;
}

:root {
  --bg: #000000;
  --text: #ffffff;
  --text-muted: #a3a3a3;
  --accent: #6b1a1a;
  --accent-intense: #e03030;
  --accent-outline: #3d0f0f;
  --border: #1a1a1a;
  --blue: #2b5ce6;

  --font-display: "Bricolage Grotesque", system-ui, sans-serif;
  --font-body: "DM Sans", system-ui, sans-serif;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 6rem;
  --page-pad: clamp(1.25rem, 4vw, 3rem);
  --content-max: 72rem;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: clamp(1rem, 1.1vw, 1.125rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
  text-underline-offset: 0.2em;
}

img {
  display: block;
  max-width: 100%;
}

/* Header */

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  padding: var(--space-sm) var(--page-pad);
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  border-bottom-color: var(--border);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.wordmark:hover {
  text-decoration: none;
}

.wordmark:hover .wordmark__breach {
  color: #8f2a2a;
}

.wordmark__mark {
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 50%;
  object-fit: cover;
}

.wordmark__runtime {
  color: var(--text);
}

.wordmark__breach {
  color: var(--accent);
  transition: color 0.2s ease;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-sm) var(--space-md);
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.site-nav a:hover {
  color: var(--blue);
  text-decoration: none;
}

/* Hero */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 4rem);
  max-width: var(--content-max);
  margin: 0 auto;
  padding: clamp(4rem, 12vh, 8rem) var(--page-pad) var(--space-xl);
}

.hero__content {
  min-width: 0;
}

.hero__eyebrow {
  margin: 0 0 var(--space-sm);
  font-family: var(--font-display);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.hero__title {
  margin: 0 0 var(--space-md);
  max-width: 11ch;
  font-family: var(--font-display);
  font-size: clamp(2.75rem, 6.5vw, 4.25rem);
  font-weight: 700;
  letter-spacing: -0.035em;
  line-height: 1.02;
}

.hero__lead {
  margin: 0;
  max-width: 38ch;
  color: var(--text-muted);
  font-size: clamp(1.0625rem, 1.6vw, 1.1875rem);
  line-height: 1.65;
}

.hero__visual {
  justify-self: center;
  width: min(100%, 16rem);
  border: 1px solid #2a2a2a;
  border-radius: 0.75rem;
  overflow: hidden;
  line-height: 0;
  background: #0a0a0a;
}

.hero__mascot {
  display: block;
  width: 100%;
  height: auto;
  object-fit: contain;
}

/* Section labels */

.section-label {
  margin: 0 0 var(--space-lg);
  font-family: var(--font-display);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-align: center;
  text-transform: uppercase;
}

/* Process — signature block */

.process {
  padding: var(--space-xl) var(--page-pad);
  border-top: 1px solid var(--border);
}

.process__stage {
  max-width: var(--content-max);
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: clamp(4rem, 9vw, 7rem);
}

.pillar {
  container-type: inline-size;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.5rem, 4vw, 3rem);
  align-items: center;
  min-height: clamp(11rem, 18vw, 15rem);
}

.display-word {
  --fill-stop: 100%;
  margin: 0;
  font-family: var(--font-display);
  font-size: clamp(3.5rem, 10vw, 8.5rem);
  font-weight: 700;
  line-height: 0.9;
  letter-spacing: -0.04em;
  text-transform: uppercase;
  background-image: linear-gradient(
    90deg,
    var(--red-hot) 0%,
    var(--red-hot) var(--fill-stop),
    var(--accent) var(--fill-stop),
    var(--accent) 100%
  );
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
  user-select: none;
  pointer-events: none;
}

@media (prefers-reduced-motion: no-preference) {
  .display-word {
    animation: word-alive 4s ease-in-out infinite;
  }

  .pillar--permit .display-word {
    animation-duration: 3.8s;
  }

  .pillar--probe .display-word {
    animation-duration: 4.2s;
    animation-delay: 0.7s;
  }

  .pillar--report .display-word {
    animation-duration: 4.6s;
    animation-delay: 1.4s;
  }
}

@keyframes word-alive {
  0%,
  100% {
    --red-hot: #e03030;
    filter: drop-shadow(0 0 6px rgba(224, 48, 48, 0.1));
  }

  50% {
    --red-hot: #ff4242;
    filter: drop-shadow(0 0 16px rgba(255, 66, 66, 0.22));
  }
}

.pillar__copy {
  max-width: 26rem;
}

.pillar__copy h3 {
  margin: 0 0 var(--space-xs);
  font-family: var(--font-display);
  font-size: clamp(1.125rem, 2vw, 1.5rem);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.3;
}

.pillar__copy p {
  margin: 0;
  color: var(--text-muted);
}

.pillar--permit .display-word {
  --fill-stop: 25%;
  grid-column: 1;
  justify-self: start;
}

.pillar--permit .pillar__copy {
  grid-column: 2;
  justify-self: end;
}

.pillar--probe .pillar__copy {
  grid-column: 1;
  grid-row: 1;
  justify-self: start;
}

.pillar--probe .display-word {
  --fill-stop: 70%;
  grid-column: 2;
  grid-row: 1;
  justify-self: end;
}

.pillar--report .display-word {
  --fill-stop: 100%;
  grid-column: 1;
  justify-self: start;
}

.pillar--report .pillar__copy {
  grid-column: 2;
  justify-self: end;
}

/* Scope */

.scope {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: var(--space-xl) var(--page-pad);
  border-top: 1px solid var(--border);
  text-align: center;
}

.scope__list {
  margin: 0 auto var(--space-md);
  max-width: 52rem;
  font-family: var(--font-display);
  font-size: clamp(1rem, 2vw, 1.25rem);
  font-weight: 500;
  line-height: 1.7;
  letter-spacing: -0.01em;
}

.scope__note {
  margin: 0 auto;
  max-width: 40ch;
  color: var(--text-muted);
}

/* CTA */

.cta {
  max-width: var(--content-max);
  margin: 0 auto;
  padding: var(--space-xl) var(--page-pad) clamp(5rem, 12vh, 8rem);
  border-top: 1px solid var(--border);
  text-align: center;
}

.cta__title {
  margin: 0 0 var(--space-sm);
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.cta__text {
  margin: 0 auto var(--space-md);
  max-width: 36ch;
  color: var(--text-muted);
}

.cta__button {
  display: inline-block;
  padding: 0.875rem 1.75rem;
  border: 1px solid var(--text);
  font-family: var(--font-display);
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: -0.01em;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.cta__button:hover {
  background: var(--text);
  color: var(--bg);
  text-decoration: none;
}

.cta__button:focus-visible {
  outline: 2px solid var(--blue);
  outline-offset: 3px;
}

/* Footer */

.site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-sm);
  max-width: var(--content-max);
  margin: 0 auto;
  padding: var(--space-md) var(--page-pad) var(--space-lg);
  border-top: 1px solid var(--border);
}

.site-footer__copy {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.site-footer__mascot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  opacity: 0.9;
}

/* Scroll reveal */

.reveal {
  opacity: 0;
  transform: translateY(1.5rem);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.pillar--probe.reveal.is-visible {
  transition-delay: 0.1s;
}

.pillar--report.reveal.is-visible {
  transition-delay: 0.2s;
}

/* Mobile */

@media (max-width: 900px) {
  .hero {
    grid-template-columns: 1fr;
    gap: clamp(1.5rem, 5vw, 2.5rem);
    padding-top: clamp(2.5rem, 8vh, 5rem);
    padding-bottom: clamp(2.5rem, 6vh, 4rem);
    text-align: center;
  }

  .hero__content {
    order: 1;
  }

  .hero__visual {
    order: 0;
    width: min(60vw, 14rem);
    margin: 0 auto;
  }

  .hero__eyebrow,
  .hero__title,
  .hero__lead {
    margin-left: auto;
    margin-right: auto;
  }

  .hero__title {
    max-width: 14ch;
  }

  .pillar {
    grid-template-columns: 1fr;
    min-height: 0;
    gap: var(--space-sm);
  }

  .pillar--permit .display-word,
  .pillar--probe .display-word,
  .pillar--report .display-word,
  .pillar--permit .pillar__copy,
  .pillar--probe .pillar__copy,
  .pillar--report .pillar__copy {
    grid-column: 1;
    grid-row: auto;
    justify-self: stretch;
    text-align: left;
    max-width: none;
  }

  .process__stage {
    gap: clamp(2.5rem, 8vw, 4rem);
  }
}

@media (max-width: 640px) {
  .site-header {
    align-items: flex-start;
    padding-top: 0.75rem;
    padding-bottom: 0.75rem;
  }

  .site-nav {
    gap: 0.625rem 1rem;
    font-size: 0.6875rem;
    letter-spacing: 0.06em;
  }

  .wordmark {
    font-size: 0.9375rem;
  }

  .wordmark__mark {
    width: 1.5rem;
    height: 1.5rem;
  }

  .hero {
    padding-top: 2rem;
    padding-bottom: 2.5rem;
  }

  .hero__eyebrow {
    font-size: 0.6875rem;
  }

  .hero__title {
    font-size: clamp(1.875rem, 8.5vw, 2.5rem);
    max-width: none;
    line-height: 1.08;
  }

  .hero__lead {
    font-size: 1rem;
    max-width: 32ch;
  }

  .hero__visual {
    width: min(56vw, 12rem);
  }

  .process {
    padding-top: 3rem;
    padding-bottom: 3rem;
  }

  .section-label {
    margin-bottom: 2rem;
  }

  .display-word {
    width: 100%;
    font-size: clamp(2.5rem, 14vw, 3.5rem);
    margin-bottom: 0.25rem;
  }

  @container (max-width: 360px) {
    .display-word {
      font-size: 2.25rem;
    }
  }

  .pillar__copy h3 {
    font-size: 1.125rem;
  }

  .scope {
    padding-top: 3rem;
    padding-bottom: 3rem;
  }

  .scope__list {
    font-size: 0.9375rem;
    line-height: 1.85;
    max-width: 100%;
    padding: 0 0.25rem;
  }

  .cta {
    padding-top: 3rem;
    padding-bottom: 4rem;
  }

  .cta__title {
    font-size: clamp(1.5rem, 7vw, 2rem);
  }

  .cta__button {
    display: block;
    width: fit-content;
    max-width: 100%;
    margin: 0 auto;
    padding: 0.75rem 1.25rem;
    font-size: 0.8125rem;
    overflow-wrap: anywhere;
  }

  .site-footer {
    flex-direction: column;
    text-align: center;
    padding-bottom: calc(var(--space-lg) + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 380px) {
  .site-nav a {
    letter-spacing: 0.04em;
  }

  .display-word {
    font-size: 2rem;
    letter-spacing: -0.03em;
  }

  .hero__visual {
    width: min(52vw, 11rem);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .display-word {
    animation: none;
    filter: none;
    --red-hot: #e03030;
  }
}