/* Papers - PPT slide */
body { overflow: hidden; }

.stage {
  height: 100dvh;
  overflow: hidden;
}

.stage__bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 75% 55% at 88% 12%, rgba(212, 137, 74, 0.15), transparent 55%),
    radial-gradient(ellipse 50% 45% at 8% 78%, rgba(90, 110, 130, 0.12), transparent 50%),
    linear-gradient(155deg, #121417 0%, #0a0b0d 48%, #0d0f12 100%);
}

.frame {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-rows: auto 1fr auto;
  height: 100%;
  padding: clamp(1.15rem, 2.8vw, 2rem) clamp(1.25rem, 4vw, 3.25rem);
}

.board {
  position: relative;
  min-height: 0;
  height: 100%;
  align-self: stretch;
  opacity: 0;
  transform: translateY(18px);
  animation: rise 0.9s var(--ease) 0.25s forwards;
}

/* Title stays top; does not steal vertical space from centering */
.identity {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 2;
  pointer-events: none;
}

.identity .name,
.identity .lede,
.identity .techs,
.identity .out-links {
  pointer-events: auto;
}

.identity .name {
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  font-size: clamp(2.6rem, 5.8vw, 4.25rem);
  line-height: 1;
  letter-spacing: -0.03em;
}

.accent {
  width: 0;
  height: 2px;
  margin: 0.9rem 0 0.75rem;
  background: linear-gradient(90deg, var(--copper), transparent);
  animation: draw 1s var(--ease) 0.6s forwards;
}

.lede {
  color: var(--muted);
  font-size: clamp(0.95rem, 1.6vw, 1.08rem);
  max-width: 42ch;
}

/* Center body in the FULL board (nav→footer), not leftover under title */
.deck {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
}

.deck__body {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: clamp(1.35rem, 3.8vh, 2.4rem);
}

/* Narrative beats - not equal cards */
.beats {
  --beat-gap: clamp(0.85rem, 2vw, 1.5rem);
  list-style: none;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--beat-gap);
  position: relative;
  padding: 0;
  margin: 0;
}

.beat {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  min-width: 0;
  padding-top: 0.15rem;
  opacity: 0;
  transform: translateY(10px);
  animation: rise 0.7s var(--ease) forwards;
}

.beat:nth-child(1) { animation-delay: 0.32s; }
.beat:nth-child(2) { animation-delay: 0.42s; }
.beat:nth-child(3) { animation-delay: 0.52s; }
.beat:nth-child(4) { animation-delay: 0.62s; }

.beat__head {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  position: relative;
  padding-bottom: 0.75rem;
  margin-bottom: 0.95rem;
}

.beat__head::after {
  content: "";
  position: absolute;
  left: 0;
  right: calc(-1 * var(--beat-gap));
  bottom: 0;
  height: 1.5px;
  background: rgba(212, 137, 74, 0.7);
}

.beat:last-child .beat__head::after {
  right: 0;
}

.beat__n {
  font-family: "Outfit", sans-serif;
  font-size: clamp(1rem, 1.6vw, 1.2rem);
  font-weight: 600;
  letter-spacing: 0.1em;
  color: rgba(212, 137, 74, 0.85);
}

.beat__label {
  font-family: "Outfit", sans-serif;
  font-size: clamp(1.25rem, 2.3vw, 1.65rem);
  font-weight: 600;
  letter-spacing: 0.06em;
  color: var(--ink);
}

.beat__line {
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  font-size: clamp(1.4rem, 2.4vw, 1.85rem);
  line-height: 1.25;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.beat__sub {
  font-size: clamp(0.98rem, 1.4vw, 1.12rem);
  line-height: 1.5;
  color: var(--muted);
  max-width: 34ch;
}

.beat--peak .beat__label {
  color: var(--copper);
}

.beat--peak .beat__head::after {
  background: var(--copper);
}

.beat--peak .beat__line {
  font-size: clamp(1.65rem, 2.9vw, 2.15rem);
  color: var(--copper);
}

.beat--peak .beat__sub {
  color: rgba(236, 233, 227, 0.78);
}

.split {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1.1rem;
  margin: 0.35rem 0 0.15rem;
  opacity: 0;
  animation: rise 0.65s var(--ease) 0.75s forwards;
}

.split__stem,
.split__arms {
  height: 1.5px;
  background: linear-gradient(90deg, transparent, rgba(212, 137, 74, 0.7), transparent);
}

.split__core {
  text-align: center;
  max-width: 36rem;
  padding: 0.55rem 0.85rem;
  border-top: 1px solid rgba(212, 137, 74, 0.35);
  border-bottom: 1px solid rgba(212, 137, 74, 0.35);
}

.split__text {
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  font-size: clamp(1.15rem, 2vw, 1.45rem);
  line-height: 1.4;
  letter-spacing: -0.02em;
  color: var(--ink);
  white-space: nowrap;
}

.split__text em {
  font-style: normal;
  color: #c67a3a;
}

.fork {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(1rem, 2.5vw, 1.75rem);
  flex: 0 0 auto;
  align-items: stretch;
  opacity: 0;
  animation: rise 0.75s var(--ease) 0.88s forwards;
}

.leaf {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  padding: clamp(1.05rem, 2vw, 1.35rem) clamp(1.1rem, 2vw, 1.4rem);
  background: linear-gradient(160deg, rgba(236, 233, 227, 0.06), rgba(236, 233, 227, 0.02));
  border-left: 2px solid var(--copper);
  min-height: 0;
  transition: transform 0.25s var(--ease), background 0.25s ease;
}

.leaf:hover {
  transform: translateY(-2px);
  background: linear-gradient(160deg, rgba(236, 233, 227, 0.09), rgba(236, 233, 227, 0.03));
}

.leaf__tag {
  display: inline-block;
  width: fit-content;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #1a1410;
  background: var(--copper-soft);
  padding: 0.15rem 0.45rem;
}

.leaf__title {
  font-family: "Outfit", sans-serif;
  font-weight: 600;
  font-size: clamp(1.05rem, 1.7vw, 1.28rem);
  line-height: 1.3;
  letter-spacing: -0.015em;
}

.leaf__desc {
  font-size: 0.92rem;
  line-height: 1.45;
  color: var(--muted);
}

.leaf__meta {
  margin-top: auto;
  padding-top: 0.55rem;
  border-top: 1px solid rgba(236, 233, 227, 0.08);
  font-size: 0.8rem;
  letter-spacing: 0.03em;
  color: var(--muted);
}

@keyframes draw {
  to { width: 6.5rem; }
}

@media (max-width: 980px) {
  body { overflow: auto; }
  .stage { height: auto; min-height: 100dvh; overflow: visible; }
  .frame { height: auto; min-height: 100dvh; }
  .board { height: auto; position: relative; }
  .identity { position: relative; }
  .deck {
    position: relative;
    inset: auto;
    display: block;
    padding-top: 1.5rem;
  }
  .beats {
    grid-template-columns: 1fr;
    gap: 1.35rem;
  }
  .beat__head::after {
    right: 0;
  }
  .beat__sub { max-width: 40ch; }
  .fork { grid-template-columns: 1fr; }
  .split__text { white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  .board, .beat, .split, .fork, .accent, .split__core {
    opacity: 1;
    transform: none;
    animation: none;
  }
  .accent { width: 6.5rem; }
  .leaf:hover { transform: none; }
}


a.leaf {
  text-decoration: none;
  color: inherit;
  cursor: pointer;
}
