/* FIXED CHROME — timecode HUD, playhead progress, topbar, footer.
   z-index scale: topbar 9500, hud 9520, playhead 9600 (grain 9000, trail 9400, lightbox 9800, leader 9900). */

/* ---------- PLAYHEAD ---------- */
#playhead {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 2px;
  z-index: 9600;
  background: var(--line);
  pointer-events: none;
}

#playhead-fill {
  display: block;
  width: 100%;
  height: 100%;
  background: var(--spectrum);
  transform: scaleX(0);
  transform-origin: left center;
  will-change: transform;
}

/* ---------- TIMECODE HUD ---------- */
#hud {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9520;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.9rem var(--gutter);
  pointer-events: none;
}

#hud .hud-left,
#hud .hud-right {
  display: flex;
  align-items: center;
  gap: 0.6em;
  white-space: nowrap;
}

#hud-marker {
  color: var(--bone);
}

#hud .hud-rec {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 0.6em;
  border-radius: 50%;
  background: var(--signal);
  animation: hud-rec-pulse 2s infinite;
}

@keyframes hud-rec-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}

@media (max-width: 720px) {
  #hud { display: none; }
}

/* ---------- TOPBAR ---------- */
#topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 9500;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem var(--gutter);
  border-bottom: 1px solid transparent;
  background: transparent;
  transition:
    background-color var(--dur-fast) var(--ease-cut),
    border-color var(--dur-fast) var(--ease-cut);
}

#topbar.scrolled {
  background: color-mix(in srgb, var(--void) 78%, transparent);
  border-bottom-color: var(--line);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

#topbar .topbar-name {
  color: var(--bone);
}

#topbar .topbar-nav {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 2.4vw, 2.2rem);
}

#topbar .topbar-nav a {
  color: var(--ash);
  transition: color var(--dur-fast) var(--ease-cut);
}

#topbar .topbar-nav a:hover,
#topbar .topbar-nav a.active {
  color: var(--bone);
}

@media (max-width: 720px) {
  #topbar .topbar-nav a:not(.topbar-contact) {
    display: none;
  }
}

/* ---------- FOOTER ---------- */
#footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  text-align: center;
  padding: 3rem var(--gutter) 2rem;
  border-top: 1px solid var(--line);
  color: var(--ash);
}

#footer .footer-note {
  color: var(--bone);
}
