/* ============================================================================
   DVP Home — "The Showreel Wall" (Idea 2)
   A streaming-platform coverflow hero: one center piece plays muted-on-loop,
   flanked by a 3D perspective wall of the other work. Click / arrow / auto-
   advance brings a piece to center. Only the active card loads video.
   Additive layer; load AFTER home.css. Styles the .showreel hero only.
   ========================================================================== */

.showreel {
  position: relative;
  min-height: 100svh;
  overflow: hidden;
  isolation: isolate;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(10px, 2vh, 22px);
  padding: clamp(88px, 12vh, 120px) clamp(12px, 3vw, 40px) clamp(28px, 5vh, 52px);
  background:
    radial-gradient(ellipse 62% 46% at 50% 38%, rgba(255, 115, 56, .16), transparent 62%),
    radial-gradient(ellipse 40% 40% at 84% 80%, rgba(255, 45, 120, .12), transparent 64%),
    linear-gradient(180deg, #020306 0%, #04070d 58%, #010204 100%);
}

/* faint grain to match the rest of the site handled by body::before in home.css */

.showreel-head { text-align: center; z-index: 5; }
.showreel-eyebrow {
  font-family: var(--font-mono);
  letter-spacing: .42em;
  text-transform: uppercase;
  font-size: clamp(9px, 1.4vw, 12px);
  color: rgba(247, 239, 225, .66);
  margin: 0 0 8px;
}
.showreel-eyebrow b { color: #ff7338; font-weight: 600; }
.showreel-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: clamp(26px, 5vw, 60px);
  line-height: .95;
  letter-spacing: .01em;
  margin: 0;
  color: #f7efe1;
  max-width: min(720px, 92vw);   /* wrap to ~2 lines instead of overflowing the flex column */
  text-wrap: balance;
}
.showreel-title span { color: #ff7338; }

/* ---- the 3D stage ---- */
.sw-stage {
  position: relative;
  width: 100%;
  height: min(60vh, 600px);
  perspective: 1900px;
  z-index: 3;
}
.sw-track {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
}
.sw-card {
  position: absolute;
  top: 50%; left: 50%;
  width: min(58vw, 880px);
  aspect-ratio: 16 / 9;
  transform: translate(-50%, -50%);
  transform-origin: center center;
  transition: transform .6s cubic-bezier(.16, 1, .3, 1), opacity .5s ease, filter .5s ease, box-shadow .5s ease;
  cursor: pointer;
  border-radius: 16px;
  overflow: hidden;
  background: #05080d;
  border: 1px solid rgba(255, 255, 255, .06);
  box-shadow: 0 30px 70px rgba(0, 0, 0, .55);
  padding: 0;
  -webkit-appearance: none; appearance: none;
  color: inherit; font: inherit; text-align: left;
}
.sw-media { position: absolute; inset: 0; overflow: hidden; }
.sw-media img { width: 100%; height: 100%; object-fit: cover; display: block; }
/* the center piece breathes even when it's showing a still (e.g. Vimeo) */
.sw-card.is-active .sw-media img { animation: swKenBurns 16s ease-in-out infinite alternate; }
@keyframes swKenBurns { from { transform: scale(1.02); } to { transform: scale(1.11); } }
@media (prefers-reduced-motion: reduce) { .sw-card.is-active .sw-media img { animation: none; } }
.sw-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; }

/* non-active cards read as a dim wall */
.sw-card:not(.is-active) { filter: brightness(.55) saturate(.85); }
.sw-card:not(.is-active)::after {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(2,3,6,.15), rgba(2,3,6,.55));
}
.sw-card.is-active {
  box-shadow: 0 44px 120px rgba(255, 115, 56, .22), 0 0 0 1px rgba(255, 115, 56, .32);
}

/* title/label badge on the active card */
.sw-badge {
  position: absolute;
  left: 16px; bottom: 14px;
  z-index: 3;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .45s ease .1s, transform .45s ease .1s;
  pointer-events: none;
}
.sw-card.is-active .sw-badge { opacity: 1; transform: none; }
.sw-badge b {
  display: block;
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(14px, 1.7vw, 20px);
  color: #fff; text-shadow: 0 2px 12px rgba(0,0,0,.7);
}
.sw-badge small {
  font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: .2em; text-transform: uppercase; color: #ff9a5c;
}

/* center play affordance on the active card */
.sw-play {
  position: absolute;
  right: 16px; bottom: 16px;
  z-index: 4;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 16px 9px 13px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, .25);
  background: rgba(6, 9, 14, .55);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  color: #fff; font-family: var(--font-mono); font-size: 11px;
  letter-spacing: .16em; text-transform: uppercase;
  opacity: 0; transition: opacity .4s ease, background .2s;
  pointer-events: none;
}
.sw-card.is-active .sw-play { opacity: 1; pointer-events: auto; }
.sw-play:hover { background: rgba(255, 115, 56, .9); border-color: transparent; }
.sw-play::before { content: "▶"; font-size: 9px; }

/* ---- controls row ---- */
.sw-controls {
  display: flex; align-items: center; justify-content: center;
  gap: clamp(16px, 3vw, 32px);
  z-index: 5;
}
.sw-nav {
  width: 52px; height: 52px; flex: none;
  border-radius: 50%;
  border: 1px solid rgba(255, 115, 56, .32);
  background: rgba(6, 9, 14, .55);
  color: #fff; font-size: 20px; line-height: 1;
  cursor: pointer;
  transition: background .2s, border-color .2s, transform .2s;
}
.sw-nav:hover { background: rgba(255, 115, 56, .16); border-color: #ff7338; transform: scale(1.06); }
.sw-caption { text-align: center; min-width: min(60vw, 320px); }
.sw-caption b {
  display: block;
  font-family: var(--font-display); font-weight: 800;
  font-size: clamp(15px, 2vw, 22px); color: #f7efe1;
}
.sw-caption small {
  font-family: var(--font-mono); font-size: 11px;
  letter-spacing: .22em; text-transform: uppercase; color: #ff7338;
}
.sw-counter {
  font-family: var(--font-mono); font-size: 12px; letter-spacing: .14em;
  color: rgba(247, 239, 225, .5); margin-top: 4px;
}

/* rail reused from home.css look, sits at the very bottom */
.showreel .bay-rail { margin-top: clamp(8px, 2vh, 18px); z-index: 5; }

@media (max-width: 720px) {
  .sw-card { width: 84vw; border-radius: 12px; }
  .sw-stage { height: 44vh; }
  .sw-nav { width: 44px; height: 44px; }
}

@media (prefers-reduced-motion: reduce) {
  .sw-card { transition: none; }
}
