/* ============================================================
   TOKENS — palette based on the HEAT (1995) poster's black/
   white/crimson scheme, extended with the film's signature
   cold blue night-time grade for bar randomization.
   Red stays reserved for the hairlines only.
   ============================================================ */
:root {
  --heat-black:     #0a0a0a;
  --heat-red:       #c81414;

  --page-bg:        #ffffff;
  --ink:            #111111;

  --bar-zone-height: clamp(90px, 20vh, 260px);

  --font-display: 'Helvetica Neue', Helvetica, Arial, sans-serif;

  /* faster + tighter range than before = more chaotic, still smooth
     rather than sporadic/jarring ("entrancing" not jumpy) */
  --glitch-speed: 0.75s;
  --glitch-pause-min: 450ms;
  --glitch-pause-max: 1100ms;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--page-bg);
  color: var(--ink);
  font-family: var(--font-display);
  overflow-x: hidden;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

@media (prefers-reduced-motion: reduce) {
  :root { --glitch-speed: 0.01ms; }
}

/* ============================================================
   TOP BAR ZONE — pure white background, no gray wash.
   ============================================================ */
.bar-zone {
  position: relative;
  width: 100%;
  height: var(--bar-zone-height);
  flex: 0 0 auto;
  overflow: hidden;
  background: var(--page-bg);
  isolation: isolate;
}

.bars {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-evenly;
  padding: 0 3vw;
}

.slot {
  position: relative;
  height: 100%;
  width: 7%;
  display: flex;
  justify-content: center;
}

/* ---- Shared base for anything that lives in a slot ---- */
.shape {
  transform-origin: top center;
}

/* ============================================================
   RED HAIRLINES — part of the same slot-swap system as the bars
   (they still randomly swap places around the zone), but with no
   glitch/flicker choreography at all: no fade-out before a swap,
   no flash animation. They simply reposition, always solid,
   opaque, flat --heat-red.
   ============================================================ */
.line {
  width: 2px;
  height: 92%;
  background: var(--heat-red);
  opacity: 1;
  filter: drop-shadow(0 0 1px rgba(200, 20, 20, 0.5));
  transition:
    height var(--glitch-speed) cubic-bezier(.2,.8,.2,1),
    transform 0.3s cubic-bezier(.2,.8,.2,1),
    filter 0.22s ease;
}

.line.active-solo {
  filter: drop-shadow(0 0 5px rgba(200, 20, 20, 0.85));
}

/* ============================================================
   BARS — flattened, plain-color panels: no gradient, blur, grain,
   sheen, border, or shadow. Just the HEAT-poster tint (set per-bar
   from script.js's BAR_TINTS, in the same grayscale + night-blue
   family as before) at half opacity.
   ============================================================ */
.bar {
  --bar-tint-rgb: 51, 51, 51;
  position: relative;
  width: 65%;
  background: rgb(var(--bar-tint-rgb));
  opacity: 0.15;
  transition:
    height var(--glitch-speed) cubic-bezier(.2,.8,.2,1),
    width var(--glitch-speed) cubic-bezier(.2,.8,.2,1),
    background 0.3s ease,
    opacity 0.3s ease,
    transform 0.3s cubic-bezier(.2,.8,.2,1);
  will-change: height, width, transform, opacity, background-color;
}

.bar.glitch-out {
  opacity: 0;
  transform: scaleY(0.4) translateY(-6px);
}

.bar.glitch-flicker {
  animation: flicker 0.21s steps(2, jump-none) 2;
}

.bar.active-solo {
  opacity: 0.5;
}

@keyframes flicker {
  0%   { opacity: 1;    filter: none; }
  25%  { opacity: 0.25; filter: brightness(2) contrast(1.4); }
  50%  { opacity: 0.85; filter: none; }
  75%  { opacity: 0.35; filter: brightness(1.8); }
  100% { opacity: 1;    filter: none; }
}

/* ============================================================
   HOVER "PIANO" MODE — whichever shape the pointer is currently
   over (anywhere in its slot column) keeps glitching/re-tinting in
   place; every other shape disappears completely, instantly, with
   no drag/click needed.
   ============================================================ */
.shape.frozen {
  transition: none !important;
  opacity: 0;
  pointer-events: none;
}

.shape.active-solo {
  z-index: 6;
}

/* Film grain overlay — fine speckle via 'multiply', not a flat gray wash */
.grain {
  position: absolute;
  inset: -20%;
  width: 140%;
  height: 140%;
  pointer-events: none;
  z-index: 5;
  opacity: 0.16;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='matrix' 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>");
  background-size: 160px 160px;
  animation: grain-shift 0.5s steps(4) infinite;
}

@keyframes grain-shift {
  0%   { transform: translate(0, 0); }
  25%  { transform: translate(-2%, 1%); }
  50%  { transform: translate(1%, -2%); }
  75%  { transform: translate(-1%, -1%); }
  100% { transform: translate(0, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .grain { animation: none; }
}

/* ============================================================
   CENTERED CONTENT
   Bar zone is fixed-height at the top; the footer is pinned and
   removed from flow, so this area takes all remaining space and
   centers its contents both horizontally and vertically within it.
   ============================================================ */
.content {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: clamp(8px, 2vh, 24px) 5vw clamp(12px, 3vh, 32px);
}

.video-frame {
  display: block;
  height: clamp(70px, 16vh, 190px);
  width: auto;
  max-width: 60vw;
  aspect-ratio: 4 / 3;
  background: var(--heat-black);
  overflow: hidden;
  border: none;
  box-shadow: 0 0 0 1px rgba(0,0,0,0.06);
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.bio-caption {
  margin: clamp(4px, 0.8vh, 10px) 0 0;
  font-size: clamp(0.75rem, 1.6vh, 0.9rem);
  font-style: italic;
  font-weight: 400;
  color: #333;
}

.track-list {
  margin-top: clamp(12px, 3vh, 36px);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(6px, 1.6vh, 20px);
}

.track {
  font-size: clamp(0.95rem, 2.1vh, 1.5rem);
  font-weight: 500;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: 0.2px;
  transition: opacity 0.2s ease;
}

.track:hover { opacity: 0.55; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 640px) {
  .video-frame {
    max-width: 68vw;
  }

}
/* ============================================================
   SITE-WIDE COPYRIGHT MARK — bottom-left on every page
   ============================================================ */
.site-copyright {
  position: fixed;
  left: 16px;
  bottom: 12px;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  color: #000000;
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  pointer-events: none;
}

.site-copyright img {
  width: 20px;
  height: 20px;
  display: block;
  object-fit: contain;
  aspect-ratio: 1 / 1;
  opacity: 0.6;
}