:root {
  --ink: #f4f4ef;
  --paper: #050505;
  --paper-soft: #10100f;
  --chrome: #777771;
  --static: rgba(255, 255, 255, 0.08);
  --red: #df1e17;
  --season-1: #df1e17;
  --season-2: #f5f3ec;
  --season-3: #050505;
  --blue-note: #8caac0;
  --scroll: 0;
  color-scheme: dark;
  font-family: "Trebuchet MS", "Lucida Grande", Arial, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 50% 0%, rgba(82, 82, 76, 0.42), rgba(20, 20, 19, 0.8) 34%, rgba(0, 0, 0, 0.98) 78%),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06), transparent 15%, transparent 85%, rgba(255, 255, 255, 0.06));
  overflow-x: hidden;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -4;
  content: "";
  background:
    linear-gradient(rgba(255, 255, 255, 0.035) 50%, rgba(0, 0, 0, 0.12) 50%) 0 0 / 100% 4px,
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 5px);
  mix-blend-mode: screen;
  pointer-events: none;
}

a {
  color: inherit;
}

button {
  font: inherit;
}

.loader {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  background: #050505;
  transition: opacity 520ms ease, visibility 520ms ease;
}

.loader.is-hidden {
  visibility: hidden;
  opacity: 0;
}

.loader__screen {
  width: min(520px, calc(100vw - 32px));
  padding: 34px;
  color: var(--ink);
  text-align: center;
  background: linear-gradient(#101010, #050505);
  border: 1px solid rgba(255, 255, 255, 0.38);
  box-shadow:
    inset 0 0 0 2px rgba(0, 0, 0, 0.7),
    0 18px 40px rgba(255, 255, 255, 0.1);
}

.loader__mark {
  display: inline-grid;
  grid-template-columns: 18px 44px 18px;
  gap: 8px;
  align-items: end;
  height: 78px;
}

.loader__mark i {
  display: block;
  width: 100%;
  background: #fff;
}

.loader__mark i:nth-child(1) {
  height: 48px;
}

.loader__mark i:nth-child(2) {
  height: 78px;
  background: var(--red);
  transform: skew(-5deg);
}

.loader__mark i:nth-child(3) {
  height: 58px;
}

.loader__barcode {
  width: min(310px, 78vw);
  height: 90px;
  margin: 20px auto 14px;
  background:
    linear-gradient(90deg,
      #000 0 5px, transparent 5px 8px,
      #000 8px 18px, transparent 18px 23px,
      #000 23px 27px, transparent 27px 33px,
      #000 33px 50px, transparent 50px 55px,
      #000 55px 60px, transparent 60px 65px,
      #000 65px 78px, transparent 78px 84px,
      #000 84px 89px, transparent 89px 98px,
      #000 98px 119px, transparent 119px 125px,
      #000 125px 132px, transparent 132px 139px,
      #000 139px 156px, transparent 156px 164px,
      #000 164px 171px, transparent 171px 178px,
      #000 178px 198px, transparent 198px 205px,
      #000 205px 211px, transparent 211px 220px,
      #000 220px 248px, transparent 248px 255px,
      #000 255px 262px, transparent 262px 100%);
  filter: invert(1);
  animation: barcodeLoad 900ms steps(8) infinite;
}

.loader p {
  margin: 0;
  font-family: "Courier New", monospace;
  font-size: 0.82rem;
  text-transform: uppercase;
}

.noise {
  position: fixed;
  inset: 0;
  z-index: -1;
  opacity: 0.2;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 20% 10%, #fff 0 1px, transparent 1px),
    radial-gradient(circle at 80% 70%, #777 0 1px, transparent 1px);
  background-size: 7px 9px, 11px 13px;
  animation: snow 280ms steps(2) infinite;
}

.barcode-field {
  position: fixed;
  inset: 76px 0 0;
  z-index: -2;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: clamp(2px, 0.48vw, 9px);
  width: min(78vw, 780px);
  margin-inline: auto;
  opacity: calc(0.08 + var(--scroll) * 0.44);
  pointer-events: none;
  filter: blur(calc((1 - var(--scroll)) * 1.3px));
}

.barcode-line {
  width: var(--w);
  height: calc((12vh + (var(--scroll) * 78vh)) * var(--h));
  min-height: 24px;
  background: rgba(255, 255, 255, calc(0.24 + var(--scroll) * 0.62));
  transform: translateY(calc(var(--offset) * (1 - var(--scroll)))) scaleY(calc(0.18 + var(--scroll) * 0.82));
  transform-origin: top center;
  transition: height 160ms linear, opacity 160ms linear, transform 160ms linear;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 64px;
  padding: 12px clamp(16px, 4vw, 54px);
  background: rgba(5, 5, 5, 0.58);
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
  backdrop-filter: blur(12px);
}

.site-mark {
  display: inline-grid;
  grid-template-columns: 12px 28px 16px;
  gap: 5px;
  align-items: end;
  width: 66px;
  height: 38px;
  text-decoration: none;
}

.site-mark span {
  display: block;
  width: 100%;
  background: #fff;
  box-shadow: 0 0 12px rgba(255, 255, 255, 0.2);
}

.site-mark span:nth-child(1) {
  height: 22px;
}

.site-mark span:nth-child(2) {
  height: 38px;
  background: var(--red);
  transform: skew(-5deg);
}

.site-mark span:nth-child(3) {
  height: 28px;
}

.nav-blur {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
}

.nav-blur a {
  display: inline-flex;
  align-items: center;
  width: clamp(50px, 9vw, 96px);
  min-height: 30px;
  padding: 5px 10px;
  overflow: hidden;
  color: rgba(255, 255, 255, 0.4);
  font-size: 0.76rem;
  text-decoration: none;
  text-transform: uppercase;
  border: 1px solid rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
  filter: blur(1.7px);
  transition: filter 180ms ease, color 180ms ease, transform 180ms ease;
}

.nav-blur a span {
  display: block;
  width: 100%;
  height: 8px;
  background: rgba(255, 255, 255, 0.48);
}

.nav-blur a:hover,
.nav-blur a:focus-visible {
  color: var(--ink);
  filter: blur(0);
  transform: translateY(-1px);
}

main {
  position: relative;
}

.eyebrow {
  margin: 0 0 12px;
  font-family: "Courier New", monospace;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--red);
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

.graph-section,
.ghost-zone,
.ending {
  width: min(1320px, calc(100vw - 32px));
  margin: 0 auto;
}

.graph-section {
  min-height: 100svh;
  padding: clamp(18px, 4vw, 58px) 0 clamp(34px, 6vw, 80px);
}

.section-heading {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 24px;
  min-height: 42px;
  margin-bottom: 0;
}

.graph-title,
.section-heading h2,
.ending h2 {
  margin: 0;
  font-family: "Arial Black", Impact, sans-serif;
  font-size: clamp(2rem, 6vw, 5.2rem);
  line-height: 0.9;
  text-transform: uppercase;
  text-shadow: 2px 2px 0 #fff;
}

.season-key {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 8px;
  font-family: "Courier New", monospace;
  font-size: 0.76rem;
  text-transform: uppercase;
}

.season-key span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 26px;
  padding: 4px 8px;
  color: rgba(255, 255, 255, 0.72);
  background: rgba(255, 255, 255, 0.055);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
}

.key {
  width: 12px;
  height: 12px;
  border: 1px solid rgba(255, 255, 255, 0.42);
}

.key--one {
  background: var(--season-1);
}

.key--two {
  background: var(--season-2);
}

.key--three {
  background: var(--season-3);
}

.graph-shell {
  position: relative;
  min-height: clamp(620px, 82svh, 860px);
  overflow: visible;
  background:
    radial-gradient(circle at 49% 46%, rgba(255, 255, 255, 0.12), transparent 42%),
    repeating-linear-gradient(0deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 34px),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.025) 0 1px, transparent 1px 34px);
  border: 0;
  box-shadow: none;
  animation: graphBreath 7s ease-in-out infinite;
}

.graph-shell::after {
  position: absolute;
  inset: 0;
  content: "";
  background:
    linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.07), transparent),
    radial-gradient(circle at 50% 48%, transparent 0 48%, rgba(0, 0, 0, 0.16) 76%, rgba(0, 0, 0, 0.42) 100%);
  pointer-events: none;
}

.graph-toolbar {
  position: absolute;
  top: 8px;
  left: 0;
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  max-width: calc(100% - 28px);
}

.chip {
  min-height: 32px;
  padding: 6px 10px;
  color: rgba(255, 255, 255, 0.78);
  font-family: "Courier New", monospace;
  font-size: 0.74rem;
  font-weight: 700;
  text-transform: uppercase;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 0 22px rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(12px);
}

.chip.is-active {
  color: #050505;
  background: #f5f3ec;
}

.quote-graph {
  display: block;
  width: 100%;
  height: clamp(620px, 82svh, 860px);
  overflow: visible;
  filter: drop-shadow(0 0 28px rgba(255, 255, 255, 0.08));
}

.quote-card {
  position: absolute;
  right: 0;
  bottom: 0;
  z-index: 4;
  width: min(390px, calc(100% - 28px));
  max-height: 230px;
  padding: 16px;
  overflow: auto;
  color: rgba(255, 255, 255, 0.88);
  background: rgba(5, 5, 5, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.18);
  box-shadow: 0 0 30px rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px);
}

.quote-card:has(> span:only-child),
.quote-card:has(> span:nth-child(3)) {
  display: grid;
  gap: 9px;
}

.quote-card > span:not(.quote-card__season) {
  display: block;
  height: 14px;
  background: linear-gradient(90deg, rgba(255,255,255,0.08), rgba(255,255,255,0.28), rgba(255,255,255,0.08));
  animation: shimmer 2.4s ease-in-out infinite;
}

.quote-card > span:not(.quote-card__season):nth-child(1) {
  width: 42%;
}

.quote-card > span:not(.quote-card__season):nth-child(2) {
  width: 82%;
}

.quote-card > span:not(.quote-card__season):nth-child(3) {
  width: 65%;
}

.quote-card__season {
  display: inline-flex;
  margin-bottom: 8px;
  padding: 3px 7px;
  color: white;
  font-family: "Courier New", monospace;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  background: var(--red);
}

.quote-card h3 {
  margin: 0 0 8px;
  font-family: "Arial Black", Impact, sans-serif;
  font-size: 1.35rem;
  letter-spacing: 0;
  text-transform: uppercase;
}

.quote-card p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.45;
}

.graph-link {
  stroke: rgba(255, 255, 255, 0.35);
  stroke-width: 1.3;
  transition: opacity 180ms ease, stroke 180ms ease;
  animation: linePulse 5.6s ease-in-out infinite;
}

.graph-link.is-season {
  stroke-width: 2;
}

.graph-link.is-muted,
.graph-node.is-muted,
.graph-label.is-muted {
  opacity: 0.13;
}

.graph-node {
  cursor: pointer;
  stroke: rgba(255, 255, 255, 0.88);
  stroke-width: 2.2;
  filter: drop-shadow(0 0 13px rgba(255, 255, 255, 0.18));
  transition: opacity 180ms ease, r 180ms ease;
}

.graph-node:hover,
.graph-node.is-selected {
  stroke: #fff;
  stroke-width: 3;
}

.graph-label {
  font-family: "Courier New", monospace;
  font-size: 11px;
  font-weight: 700;
  text-anchor: middle;
  dominant-baseline: central;
  pointer-events: none;
  fill: white;
  paint-order: stroke;
  stroke: rgba(0, 0, 0, 0.76);
  stroke-width: 3px;
  transition: opacity 180ms ease;
}

.graph-label.label--light {
  fill: #050505;
  stroke: rgba(255, 255, 255, 0.82);
}

.ghost-zone {
  display: grid;
  align-content: center;
  min-height: 92svh;
  padding: clamp(42px, 7vw, 94px) 0;
}

.ghost-heading {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 20px;
  font-family: "Courier New", monospace;
  text-transform: uppercase;
}

.ghost-heading span {
  color: var(--red);
  font-weight: 700;
}

.ghost-heading strong {
  color: rgba(0, 0, 0, 0.38);
  filter: blur(1.4px);
}

.ghost-grid {
  display: grid;
  grid-template-columns: 1fr 0.8fr;
  gap: 16px;
}

.ghost-card,
.ghost-panel,
.ghost-strip i,
.ghost-lines span {
  position: relative;
  overflow: hidden;
  background:
    linear-gradient(110deg, transparent, rgba(255, 255, 255, 0.14), transparent) -40% 0 / 45% 100% no-repeat,
    rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.1);
  animation: shimmer 2.1s ease-in-out infinite;
}

.ghost-card {
  min-height: 220px;
}

.ghost-card.tall {
  min-height: 460px;
  grid-row: span 2;
}

.ghost-card.wide {
  min-height: 220px;
  border-left: 12px solid rgba(223, 30, 23, 0.52);
}

.ghost-zone--split {
  grid-template-columns: minmax(0, 1fr) minmax(240px, 0.74fr);
  gap: 22px;
  align-items: center;
}

.ghost-panel {
  min-height: 520px;
  box-shadow: 11px 11px 0 rgba(255, 255, 255, 0.04);
}

.ghost-lines {
  display: grid;
  gap: 18px;
}

.ghost-lines span {
  display: block;
  height: 52px;
}

.ghost-lines span:nth-child(2) {
  width: 82%;
}

.ghost-lines span:nth-child(3) {
  width: 64%;
}

.ghost-lines span:nth-child(4) {
  width: 72%;
}

.ghost-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.ghost-strip i {
  min-height: 310px;
}

.ending {
  display: grid;
  place-items: center;
  min-height: 100svh;
  padding: clamp(42px, 8vw, 100px) 0;
}

.ending__mark {
  position: relative;
  display: grid;
  place-items: end center;
  min-height: 520px;
}

.ending__barcode {
  position: absolute;
  top: 62px;
  left: 50%;
  display: flex;
  align-items: end;
  justify-content: center;
  gap: 4px;
  width: min(330px, 72vw);
  height: 310px;
  transform: translateX(-50%);
}

.ending__barcode i {
  display: block;
  width: var(--w);
  height: var(--h);
  background: #fff;
}

.ending__barcode::before,
.ending__barcode::after {
  position: absolute;
  bottom: -72px;
  width: 4px;
  height: 78px;
  content: "";
  background: #fff;
}

.ending__barcode::before {
  left: 0;
}

.ending__barcode::after {
  right: 0;
  border-radius: 0 0 18px 18px;
}

.ending__block {
  position: relative;
  z-index: 1;
  width: min(220px, 56vw);
  height: 74px;
  margin-top: 305px;
  background:
    linear-gradient(90deg, transparent 0 22%, var(--red) 22% 46%, transparent 46% 100%),
    repeating-linear-gradient(90deg, #fff 0 10px, transparent 10px 18px);
  filter: drop-shadow(0 0 22px rgba(255, 255, 255, 0.18));
}

.ending p {
  max-width: 58ch;
  margin: 18px 0 0;
  font-size: clamp(1rem, 2vw, 1.2rem);
  line-height: 1.55;
}

.site-foot {
  padding: 28px 16px 36px;
  color: white;
  text-align: center;
  background: #000;
}

.site-foot a {
  font-family: "Courier New", monospace;
  font-size: 0.82rem;
  text-transform: uppercase;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.site-foot a:hover,
.site-foot a:focus-visible {
  color: var(--red);
}

@keyframes snow {
  to {
    transform: translate3d(3px, -2px, 0);
  }
}

@keyframes shimmer {
  0% {
    background-position: -80% 0, 0 0;
  }

  100% {
    background-position: 180% 0, 0 0;
  }
}

@keyframes graphBreath {
  0%,
  100% {
    filter: contrast(1) brightness(1);
    transform: scale(1);
  }

  50% {
    filter: contrast(1.08) brightness(1.12);
    transform: scale(1.006);
  }
}

@keyframes linePulse {
  0%,
  100% {
    stroke-opacity: 0.32;
  }

  50% {
    stroke-opacity: 0.72;
  }
}

@keyframes barcodeLoad {
  50% {
    filter: invert(1);
  }
}

@media (max-width: 860px) {
  .topbar {
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-blur {
    justify-content: flex-start;
  }

  .ending,
  .ghost-zone--split {
    grid-template-columns: 1fr;
  }

  .graph-title {
    font-size: clamp(1.85rem, 12vw, 4rem);
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .season-key {
    justify-content: flex-start;
  }

  .quote-card {
    position: relative;
    right: auto;
    bottom: auto;
    width: calc(100% - 28px);
    margin: -118px 14px 14px;
  }

  .ghost-grid,
  .ghost-strip {
    grid-template-columns: 1fr;
  }

  .ghost-card.tall {
    min-height: 310px;
  }

  .ending__mark {
    min-height: 470px;
  }
}

@media (max-width: 520px) {
  .barcode-field {
    width: 92vw;
  }

  .graph-shell,
  .quote-graph {
    min-height: 620px;
  }

  .graph-toolbar {
    position: relative;
    top: auto;
    left: auto;
    padding: 12px;
  }

  .quote-graph {
    height: 620px;
    margin-top: -18px;
  }

  .quote-card {
    max-height: 260px;
    margin-top: -80px;
  }
}

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