/* /talk — slide reel + quote wall */

.talk-intro {
  padding-block: var(--space-6);
  border-bottom: 1px solid var(--border);
}

.talk-intro__head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
}

.talk-intro__head h1 {
  margin: 0;
  font-size: var(--fs-2xl);
}

.talk-intro__meta {
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: var(--fs-xs);
  color: var(--accent);
}

.talk-intro__lede {
  max-width: 60ch;
  color: var(--fg-soft);
}

.act-rail {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  margin-top: var(--space-3);
  font-size: var(--fs-xs);
  font-family: var(--font-mono);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.act-rail a {
  color: var(--muted);
  text-decoration: none;
  border: 1px solid var(--border-strong);
  padding: 0.2rem 0.5rem;
}

.act-rail a:hover,
.act-rail a:focus-visible {
  color: var(--accent);
  border-color: var(--accent);
}

/* ------------------------------------------------------------------
   SLIDE REEL — grid of slide tiles. Featured slides (1, 12, 15) span
   two columns to break the rhythm.
   ------------------------------------------------------------------ */

.reel {
  padding-block: var(--space-5);
}

.reel__act {
  margin-bottom: var(--space-6);
}

.reel__act-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
  border-bottom: 2px solid var(--accent);
  padding-bottom: var(--space-2);
}

.reel__act-name {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  margin: 0;
}

.reel__act-meta {
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
}

.reel__grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
  gap: var(--space-3);
  list-style: none;
  padding: 0;
  margin: 0;
}

.tile {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  overflow: hidden;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  text-align: left;
  font-family: inherit;
  color: inherit;
  padding: 0;
  transition: transform 160ms var(--ease-snap),
    border-color 160ms var(--ease-snap),
    box-shadow 160ms var(--ease-snap);
}

.tile:hover,
.tile:focus-visible {
  transform: translate(-2px, -2px);
  border-color: var(--accent);
  box-shadow: 4px 4px 0 var(--accent);
  outline: none;
}

.tile--featured {
  grid-column: span 2;
  aspect-ratio: 16 / 9;
}

@media (max-width: 720px) {
  .tile--featured {
    grid-column: span 1;
    aspect-ratio: 4 / 3;
  }
}

.tile__img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.tile__placeholder {
  position: absolute;
  inset: 0;
  z-index: 0;
  background-color: var(--bg-elevated);
  background-image: radial-gradient(
    circle,
    rgba(225, 29, 46, 0.22) 1px,
    transparent 1.5px
  );
  background-size: 8px 8px;
}

.tile__placeholder::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.5 0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  opacity: 0.16;
  mix-blend-mode: overlay;
}

.tile__num {
  position: absolute;
  top: var(--space-2);
  right: var(--space-2);
  z-index: 2;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.18em;
  color: var(--accent);
  background: rgba(10, 10, 10, 0.75);
  padding: 0.2rem 0.5rem;
}

.tile__body {
  position: relative;
  z-index: 2;
  padding: var(--space-3);
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(10, 10, 10, 0.85) 60%,
    rgba(10, 10, 10, 0.95) 100%
  );
}

.tile__title {
  font-family: var(--font-display);
  font-size: var(--fs-md);
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin: 0;
  color: var(--fg);
}

.tile--featured .tile__title {
  font-size: var(--fs-lg);
}

.tile__quote {
  margin: var(--space-2) 0 0;
  font-size: var(--fs-xs);
  color: var(--fg-soft);
  font-style: italic;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tile__frame {
  position: absolute;
  top: var(--space-2);
  left: var(--space-2);
  z-index: 2;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.18em;
  color: var(--accent-ink);
  background: var(--accent);
  padding: 0.2rem 0.5rem;
  text-transform: uppercase;
}

.tile__audio {
  position: absolute;
  bottom: var(--space-2);
  right: var(--space-2);
  z-index: 3;
  width: 2rem;
  height: 2rem;
  border: 1px solid var(--accent);
  background: rgba(10, 10, 10, 0.8);
  color: var(--accent);
  font: inherit;
  font-size: var(--fs-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
}

.tile__audio:hover,
.tile__audio:focus-visible {
  background: var(--accent);
  color: var(--accent-ink);
  outline: none;
}

.tile__audio[data-state="playing"] {
  background: var(--accent);
  color: var(--accent-ink);
}

.lightbox__audio {
  border-color: var(--accent);
  color: var(--accent);
}

.lightbox__audio:hover,
.lightbox__audio:focus-visible {
  background: var(--accent);
  color: var(--accent-ink);
  outline: none;
}

/* ------------------------------------------------------------------
   LIGHTBOX
   ------------------------------------------------------------------ */

.lightbox {
  border: 0;
  padding: 0;
  background: transparent;
  color: var(--fg);
  max-width: min(96vw, 80rem);
  width: 100%;
  max-height: 96vh;
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(2px);
}

.lightbox__inner {
  background: var(--bg);
  border: 1px solid var(--accent);
  display: grid;
  grid-template-rows: auto 1fr auto;
  max-height: 96vh;
}

.lightbox__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-2) var(--space-3);
  border-bottom: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.lightbox__num {
  color: var(--accent);
}

.lightbox__act {
  color: var(--muted);
}

.lightbox__close {
  background: transparent;
  border: 1px solid var(--border-strong);
  color: var(--fg);
  font: inherit;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.18em;
  padding: 0.3rem 0.6rem;
  cursor: pointer;
}

.lightbox__close:hover,
.lightbox__close:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.lightbox__stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #050505;
  min-height: 30vh;
  padding: var(--space-3);
}

.lightbox__stage img {
  max-width: 100%;
  max-height: 70vh;
  object-fit: contain;
}

.lightbox__placeholder {
  width: 100%;
  max-width: 60rem;
  aspect-ratio: 16 / 9;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--bg-elevated);
  background-image: radial-gradient(
    circle,
    rgba(225, 29, 46, 0.28) 1px,
    transparent 1.5px
  );
  background-size: 12px 12px;
}

.lightbox__placeholder p {
  font-family: var(--font-display);
  font-size: var(--fs-2xl);
  text-align: center;
  margin: 0 var(--space-4);
  max-width: 30ch;
  color: var(--fg);
}

.lightbox__nav {
  position: absolute;
  inset: 0;
  display: flex;
  justify-content: space-between;
  pointer-events: none;
  padding: 0 var(--space-2);
}

.lightbox__nav button {
  pointer-events: auto;
  width: 3rem;
  height: 3rem;
  align-self: center;
  border: 1px solid var(--border-strong);
  background: rgba(10, 10, 10, 0.7);
  color: var(--fg);
  font: inherit;
  font-size: var(--fs-lg);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lightbox__nav button:hover,
.lightbox__nav button:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.lightbox__body {
  padding: var(--space-3) var(--space-4) var(--space-4);
  border-top: 1px solid var(--border);
  display: grid;
  gap: var(--space-2);
}

.lightbox__title {
  font-family: var(--font-display);
  font-size: var(--fs-xl);
  margin: 0;
}

.lightbox__quotes {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: var(--space-2);
}

.lightbox__quotes li {
  border-left: 3px solid var(--accent);
  padding: var(--space-1) var(--space-2);
  font-family: var(--font-display);
  font-size: var(--fs-md);
  line-height: 1.3;
  color: var(--fg-soft);
}

/* ------------------------------------------------------------------
   QUOTE WALL
   ------------------------------------------------------------------ */

.quote-wall {
  padding-block: var(--space-6);
  border-top: 1px solid var(--border);
}

.quote-wall__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}

.quote-wall__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-3);
}

.quote {
  display: grid;
  grid-template-columns: 6rem 1fr;
  gap: var(--space-3);
  padding: var(--space-3);
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  scroll-margin-top: var(--space-6);
}

.quote:target {
  border-color: var(--accent);
  box-shadow: 0 0 0 1px var(--accent);
}

.quote__thumb {
  position: relative;
  background: var(--bg);
  border: 1px solid var(--border-strong);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  letter-spacing: 0.18em;
  color: var(--accent);
  text-decoration: none;
  text-align: center;
  padding: var(--space-1);
  aspect-ratio: 4 / 3;
}

.quote__thumb img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.quote__thumb-num {
  position: absolute;
  bottom: 0;
  left: 0;
  background: var(--accent);
  color: var(--accent-ink);
  padding: 0 0.3rem;
  font-size: var(--fs-xs);
  letter-spacing: 0.16em;
}

.quote__body {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.quote__text {
  font-family: var(--font-display);
  font-size: var(--fs-lg);
  line-height: 1.25;
  margin: 0;
  color: var(--fg);
}

.quote__meta {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
  font-size: var(--fs-xs);
  font-family: var(--font-mono);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--muted);
}

.quote__meta a {
  color: var(--muted);
}

.quote__actions {
  display: flex;
  gap: var(--space-2);
  margin-top: auto;
}

.quote__actions button,
.quote__actions a {
  font: inherit;
  font-family: var(--font-mono);
  font-size: var(--fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.14em;
  padding: 0.3rem 0.5rem;
  border: 1px solid var(--border-strong);
  background: transparent;
  color: var(--fg-soft);
  cursor: pointer;
  text-decoration: none;
}

.quote__actions button:hover,
.quote__actions button:focus-visible,
.quote__actions a:hover,
.quote__actions a:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
  outline: none;
}

.quote__actions [data-copied="true"] {
  border-color: var(--accent);
  color: var(--accent);
}

@media (max-width: 540px) {
  .quote {
    grid-template-columns: 1fr;
  }
  .quote__thumb {
    aspect-ratio: 16 / 9;
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .tile,
  .lightbox__nav button,
  .lightbox__close,
  .quote__actions button,
  .quote__actions a {
    transition: none;
  }
  .tile:hover,
  .tile:focus-visible {
    transform: none;
  }
}

/* ------------------------------------------------------------------
   PUNK VARIANT — Phase 5b.5
   /talk hero gets the full title-detail slide as background.
   Quote wall: each <li> becomes a taped paper card scattered with rotation.
   Reel: per-slide thumbnails get torn / staple / tape variants.
   ------------------------------------------------------------------ */

/* Hero — replaces the basic punk-tile overlay with a fuller slide-01 still.
   The existing punk-tile rule already injects a low-opacity overlay; this
   bumps it to a more dominant treatment. */
.talk-intro {
  position: relative;
  isolation: isolate;
}
.talk-intro::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--punk-title-detail);
  background-size: cover;
  background-position: center;
  opacity: 0.32;
  mix-blend-mode: screen;
  filter: grayscale(100%) contrast(1.1);
  pointer-events: none;
  z-index: -1;
}
.talk-intro::before {
  /* override the default punk-tile to higher contrast */
  content: "";
  position: absolute;
  inset: 0;
  background-image: var(--punk-title-detail);
  background-size: cover;
  background-position: center;
  opacity: 0.45;
  mix-blend-mode: lighten;
  filter: grayscale(100%) contrast(0.9);
  pointer-events: none;
  z-index: -2;
}
/* Big ransom title transformation on the hero h1 — wrap each word in
   a span via JS later if desired; for now apply directly */
.talk-intro__head h1 {
  font-family: var(--font-display);
  font-style: italic;
  font-weight: 700;
  font-size: clamp(3rem, 9vw, 6rem);
  line-height: 0.9;
  letter-spacing: -0.02em;
}

/* Slide reel — each slide thumb gets per-nth treatment for a paste-up feel */
#slide-reel .reel__slide,
#slide-reel article {
  position: relative;
  transform-origin: top left;
  transition: transform 200ms var(--ease-snap),
    box-shadow 200ms var(--ease-snap);
}
#slide-reel article:nth-of-type(3n + 1) {
  transform: rotate(-0.5deg);
}
#slide-reel article:nth-of-type(3n + 2) {
  transform: rotate(0.4deg);
}
#slide-reel article:nth-of-type(3n + 3) {
  transform: rotate(0.8deg);
}
#slide-reel article:hover {
  transform: rotate(0) translate(-2px, -2px);
  box-shadow: 5px 5px 0 var(--accent);
  z-index: 2;
}

/* Quote wall — each quote becomes a taped card on cream paper */
#quote-wall {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  align-items: stretch;
}
#quote-wall > * {
  flex: 1 1 22rem;
  position: relative;
  background: var(--paper-bright);
  color: var(--paper-ink);
  padding: var(--space-4);
  box-shadow: 6px 6px 0 var(--accent),
    0 1px 0 rgba(0, 0, 0, 0.4) inset;
  transform-origin: top left;
  transition: transform 200ms var(--ease-snap),
    box-shadow 200ms var(--ease-snap);
}
#quote-wall > *::before {
  content: "";
  position: absolute;
  top: -10px;
  right: 18px;
  width: 86px;
  height: 28px;
  background: var(--paper-bright);
  border: 1px solid rgba(0, 0, 0, 0.18);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.45);
  transform: rotate(7deg);
  opacity: 0.78;
  pointer-events: none;
  z-index: 4;
}
#quote-wall > :nth-child(4n + 1) {
  transform: rotate(-1deg);
}
#quote-wall > :nth-child(4n + 2) {
  transform: rotate(0.5deg);
  box-shadow: 6px 6px 0 var(--accent-pink),
    0 1px 0 rgba(0, 0, 0, 0.4) inset;
}
#quote-wall > :nth-child(4n + 3) {
  transform: rotate(1.2deg);
}
#quote-wall > :nth-child(4n + 4) {
  transform: rotate(-0.6deg);
  box-shadow: 6px 6px 0 var(--accent-pink),
    0 1px 0 rgba(0, 0, 0, 0.4) inset;
}
#quote-wall > *:hover {
  transform: rotate(0) translate(-3px, -3px);
  box-shadow: 8px 8px 0 var(--accent);
  z-index: 3;
}
/* Quote text inside the cream card */
#quote-wall > * blockquote,
#quote-wall > * .quote {
  color: var(--ink-marker) !important;
  font-family: var(--font-display);
  font-style: italic;
}
#quote-wall > * cite,
#quote-wall > * .cite,
#quote-wall > * footer {
  color: var(--accent-red-deep) !important;
  font-family: var(--font-mono);
  font-style: normal;
  font-size: var(--fs-xs);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

@media (prefers-reduced-motion: reduce) {
  #slide-reel article,
  #slide-reel article:hover,
  #quote-wall > *,
  #quote-wall > *:hover {
    transform: none !important;
  }
}
