:root {
  --bg: #050403;
  --wood: #120e0a;
  --wood-lit: #1c1410;
  --amber: #c4893a;
  --amber-hot: #e0a85a;
  --blood: #8b1410;
  --cream: #e8e2d6;
  --muted: #6e6254;
  --good: #e8e2d6;
  --warn: #c49220;
  --charcoal: #2a2622;
  --font-display: "Bebas Neue", sans-serif;
  --font-scene: "Special Elite", cursive;
  --font-mono: "IBM Plex Mono", ui-monospace, monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: var(--font-mono);
  color: var(--cream);
  background: var(--bg);
  overflow: hidden;
}

.letterbox {
  position: fixed;
  left: 0;
  right: 0;
  height: clamp(6px, 1.2vh, 14px);
  background: #000;
  z-index: 60;
  pointer-events: none;
}

.letterbox.top {
  top: 0;
}

.letterbox.bottom {
  bottom: 0;
}

.audio-dock {
  position: fixed;
  right: 1rem;
  bottom: calc(clamp(6px, 1.2vh, 14px) + 0.75rem);
  z-index: 70;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.45rem 0.65rem;
  background: rgba(10, 8, 6, 0.72);
  border: 1px solid rgba(239, 228, 212, 0.15);
  backdrop-filter: blur(8px);
}

.mute-btn {
  margin: 0;
  width: 2rem;
  height: 2rem;
  padding: 0;
  display: grid;
  place-items: center;
  background: transparent;
  color: var(--cream);
  border: 1px solid rgba(239, 228, 212, 0.25);
  box-shadow: none;
  font-size: 0.95rem;
  line-height: 1;
}

.mute-btn:hover {
  transform: none;
  background: rgba(196, 137, 58, 0.15);
}

.mute-btn.muted {
  color: var(--muted);
  border-color: rgba(239, 228, 212, 0.12);
}

.vol-slider {
  -webkit-appearance: none;
  appearance: none;
  width: 96px;
  height: 4px;
  background: rgba(239, 228, 212, 0.2);
  outline: none;
  cursor: pointer;
}

.vol-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--amber);
  cursor: pointer;
}

.vol-slider::-moz-range-thumb {
  width: 12px;
  height: 12px;
  border: none;
  border-radius: 50%;
  background: var(--amber);
  cursor: pointer;
}

.hint.sub {
  margin-top: 0.45rem;
  font-size: 0.68rem;
  opacity: 0.75;
}

.grain {
  pointer-events: none;
  position: fixed;
  inset: 0;
  opacity: 0.045;
  z-index: 55;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
}

.vignette {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 54;
  background: radial-gradient(ellipse at center, transparent 52%, rgba(0, 0, 0, 0.4) 100%);
}

.room-tint {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.room-tint.warm {
  opacity: 1;
  background: radial-gradient(ellipse at 50% 30%, rgba(180, 100, 20, 0.18), transparent 60%);
}

.room-tint.rage {
  opacity: 1;
  background: radial-gradient(ellipse at 50% 25%, rgba(139, 20, 16, 0.42), transparent 55%);
  animation: rage-flicker 0.35s steps(2) infinite;
}

.flash {
  pointer-events: none;
  position: fixed;
  inset: 0;
  z-index: 58;
  background: transparent;
  opacity: 0;
}

.flash.pop {
  animation: none;
  opacity: 0;
}

@keyframes rage-flicker {
  0%,
  100% {
    opacity: 0.85;
  }
  50% {
    opacity: 1;
  }
}

@keyframes flash-pop {
  from {
    opacity: 0.35;
  }
  to {
    opacity: 0;
  }
}

#app {
  position: relative;
  z-index: 10;
  min-height: 100dvh;
  display: grid;
  place-items: center;
  padding: 0;
}

.screen {
  display: none;
  width: min(640px, 92%);
  text-align: center;
}

.screen.active {
  display: block;
  animation: fade-in 0.5s ease;
}

/* Full-bleed play surface — stage owns the viewport */
#game-screen.screen {
  width: 100%;
  max-width: none;
  height: 100dvh;
  position: relative;
  text-align: center;
}

#game-screen.screen.active {
  display: block;
}

/* Title owns the viewport with stage fantasy behind copy */
#title-screen.screen {
  width: 100%;
  max-width: none;
  min-height: 100dvh;
  position: relative;
  display: none;
  place-items: center;
  padding: clamp(2rem, 8vh, 4rem) 1.25rem;
}

#title-screen.screen.active {
  display: grid;
}

@keyframes fade-in {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

/* ——— Title ——— */
.title-stage {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
  background: #000;
}

.title-stage-hero {
  position: absolute;
  inset: -5%;
  background: url("title-hero.jpg") center 42% / cover no-repeat;
  transform: scale(1.06);
  animation: title-drift 22s ease-in-out infinite alternate;
}

.title-stage-veil {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      180deg,
      rgba(0, 0, 0, 0.42) 0%,
      rgba(0, 0, 0, 0.12) 22%,
      transparent 40%,
      transparent 52%,
      rgba(0, 0, 0, 0.45) 70%,
      rgba(0, 0, 0, 0.82) 86%,
      rgba(0, 0, 0, 0.94) 100%
    ),
    radial-gradient(ellipse 85% 50% at 50% 100%, rgba(0, 0, 0, 0.7), transparent 62%),
    linear-gradient(90deg, rgba(0, 0, 0, 0.28) 0%, transparent 18%, transparent 82%, rgba(0, 0, 0, 0.28) 100%);
}

@keyframes title-drift {
  from {
    transform: scale(1.06) translate3d(0, 0, 0);
  }
  to {
    transform: scale(1.1) translate3d(-1.4%, -0.9%, 0);
  }
}

.title-card {
  position: relative;
  z-index: 2;
  padding: 2.5rem 1.25rem 1.75rem;
  max-width: 52rem;
  background: transparent;
  border: none;
  box-shadow: none;
  animation: film-open 1.35s ease both;
}

@keyframes film-open {
  0% {
    opacity: 0;
    filter: brightness(0.35) contrast(1.25);
    transform: scale(1.04);
  }
  45% {
    opacity: 1;
    filter: brightness(1.08) contrast(1.1);
    transform: scale(1);
  }
  100% {
    opacity: 1;
    filter: none;
    transform: none;
  }
}

@keyframes title-settle {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.eyebrow {
  font-family: var(--font-scene);
  color: var(--amber);
  letter-spacing: 0.18em;
  font-size: 0.78rem;
  margin-bottom: 0.85rem;
  text-transform: uppercase;
  opacity: 0.9;
  animation: fade-up 0.9s ease 0.35s both;
}

h1 {
  font-family: var(--font-display);
  font-size: clamp(6.75rem, 28vw, 15rem);
  letter-spacing: 0.02em;
  line-height: 0.76;
  color: #f2ebe0;
  text-shadow:
    0 3px 0 rgba(0, 0, 0, 0.9),
    0 10px 36px rgba(0, 0, 0, 0.72),
    0 0 90px rgba(0, 0, 0, 0.55),
    0 0 2px rgba(242, 235, 224, 0.35);
  animation: title-slam 0.85s cubic-bezier(0.15, 0.85, 0.2, 1) 0.2s both;
}

@keyframes title-slam {
  from {
    opacity: 0;
    letter-spacing: 0.22em;
    filter: brightness(0.4);
    transform: scale(1.12);
  }
  55% {
    opacity: 1;
    filter: brightness(1.12);
  }
  to {
    opacity: 1;
    letter-spacing: 0.02em;
    filter: none;
    transform: none;
  }
}

@keyframes fade-up {
  from {
    opacity: 0;
    transform: translateY(8px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.tagline {
  margin-top: 0.95rem;
  color: var(--muted);
  font-size: 0.76rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  animation: fade-up 0.9s ease 0.55s both;
}

.hint {
  margin-top: 1.4rem;
  color: var(--muted);
  font-size: 0.78rem;
  animation: fade-up 0.9s ease 0.75s both;
}

.hint strong {
  color: var(--amber-hot);
  font-weight: 600;
}

kbd {
  display: inline-block;
  padding: 0.05em 0.4em;
  border: 1px solid rgba(239, 228, 212, 0.3);
  font-family: var(--font-mono);
  font-size: 0.8em;
}

button {
  margin-top: 1.75rem;
  font-family: var(--font-mono);
  font-weight: 600;
  font-size: 0.88rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: #0a0806;
  background: var(--amber);
  border: none;
  padding: 0.95rem 1.7rem;
  cursor: pointer;
  box-shadow: none;
  transition: transform 0.15s ease, background 0.15s ease, color 0.15s ease;
}

#start-btn,
.title-card button {
  color: #0a0806;
  background: #b8954a;
  border: none;
  box-shadow: none;
  animation:
    fade-up 0.9s ease 0.65s both,
    cta-beat 1.05s ease-in-out 1.7s infinite;
}

@keyframes cta-beat {
  0%,
  100% {
    transform: scale(1);
  }
  12% {
    transform: scale(1.03);
  }
  24% {
    transform: scale(1);
  }
  36% {
    transform: scale(1.015);
  }
  48% {
    transform: scale(1);
  }
}

button:hover {
  transform: translateY(-1px);
  background: var(--amber-hot);
  box-shadow: none;
}

#start-btn:hover,
.title-card button:hover {
  animation: none;
  background: #c9a65a;
  transform: translateY(-1px) scale(1.02);
  box-shadow: none;
  filter: none;
}

/* ——— Rehearsal room ——— */
.rehearsal {
  position: absolute;
  left: 0;
  right: 0;
  top: clamp(6px, 1.2vh, 14px);
  bottom: clamp(6px, 1.2vh, 14px);
  height: auto;
  width: 100%;
  overflow: hidden;
  isolation: isolate;
  background:
    radial-gradient(ellipse 90% 55% at 50% 18%, rgba(196, 137, 58, 0.14), transparent 58%),
    radial-gradient(ellipse 120% 70% at 50% 100%, rgba(0, 0, 0, 0.88), transparent 55%),
    linear-gradient(180deg, #0a0806 0%, #120e0a 38%, #0c0907 68%, #050403 100%);
  box-shadow:
    inset 0 0 100px rgba(0, 0, 0, 0.65),
    inset 0 -40px 80px rgba(0, 0, 0, 0.4);
}

.room-wall {
  position: absolute;
  inset: 0 0 52% 0;
  background:
    radial-gradient(ellipse 55% 80% at 50% -10%, rgba(100, 60, 28, 0.28), transparent 70%),
    linear-gradient(180deg, #0c0907 0%, rgba(8, 6, 5, 0.35) 70%, transparent 100%);
  pointer-events: none;
}

.overhead {
  position: absolute;
  left: 50%;
  top: -22%;
  width: 62%;
  height: 62%;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(232, 180, 100, 0.32), transparent 68%);
  pointer-events: none;
  animation: lamp 4s ease-in-out infinite;
  z-index: 4;
}

@keyframes lamp {
  0%,
  100% {
    opacity: 0.85;
  }
  50% {
    opacity: 1;
  }
}

.band-line {
  position: absolute;
  left: 8%;
  right: 8%;
  top: 7%;
  height: 100px;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  opacity: 0.58;
  pointer-events: none;
  will-change: transform;
  transition: transform 0.05s linear, opacity 0.3s ease, filter 0.3s ease;
}

.band-line.hot {
  opacity: 0.75;
  filter: saturate(1.15) brightness(1.08);
}

.band-line.pulse .horn {
  animation: horn-blip 0.18s ease;
}

@keyframes horn-blip {
  0%,
  100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-3px);
  }
}

.stand {
  position: relative;
  width: 34px;
  height: 78px;
}

.stand::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 2px;
  height: 52px;
  margin-left: -1px;
  background: #3a3228;
}

.stand::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 18px;
  width: 28px;
  height: 18px;
  margin-left: -14px;
  background: #cfc3ae;
  clip-path: polygon(0 100%, 100% 100%, 85% 0, 15% 0);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.4);
}

.horn {
  position: absolute;
  left: 50%;
  bottom: 38px;
  width: 18px;
  height: 36px;
  margin-left: -9px;
  background: linear-gradient(180deg, #2a241c, #12100c);
  clip-path: polygon(25% 0, 75% 0, 100% 100%, 0 100%);
  transform-origin: bottom center;
}

.horn::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -10px;
  width: 12px;
  height: 12px;
  margin-left: -6px;
  border-radius: 50%;
  background: #8a6a4a;
}

.horn.sax {
  height: 42px;
  background: linear-gradient(180deg, #3a2e18, #1a140c);
}

.stand.s2,
.stand.s4 {
  height: 86px;
}

.stand.s3 {
  height: 92px;
}

/* Conductor — hard key light, ink silhouette */
.fletcher {
  position: absolute;
  left: 50%;
  top: 5%;
  transform: translateX(-50%);
  width: 128px;
  height: 220px;
  z-index: 5;
  filter: drop-shadow(0 18px 22px rgba(0, 0, 0, 0.75));
}

.fletcher-shadow {
  position: absolute;
  left: 50%;
  bottom: 6px;
  width: 90px;
  height: 16px;
  margin-left: -45px;
  background: radial-gradient(ellipse, rgba(0, 0, 0, 0.78), transparent 70%);
}

.fletcher-body {
  position: relative;
  width: 100%;
  height: 100%;
}

.fletcher-head {
  position: absolute;
  left: 50%;
  top: 8px;
  width: 44px;
  height: 48px;
  margin-left: -22px;
  border-radius: 46% 46% 42% 42%;
  background:
    linear-gradient(125deg, rgba(255, 220, 170, 0.55) 0%, transparent 42%),
    linear-gradient(160deg, #c9a078 0%, #8a6248 48%, #3a2418 100%);
  box-shadow:
    10px -8px 28px rgba(232, 180, 100, 0.28),
    inset -10px -6px 14px rgba(0, 0, 0, 0.55),
    inset 3px 4px 8px rgba(255, 230, 190, 0.18);
}

.fletcher-brow {
  position: absolute;
  left: 6px;
  right: 6px;
  top: 14px;
  height: 4px;
  background: #1a120c;
  clip-path: polygon(0 100%, 100% 100%, 95% 0, 5% 0);
}

.fletcher-eyes {
  position: absolute;
  left: 8px;
  right: 8px;
  top: 20px;
  height: 6px;
  display: flex;
  justify-content: space-between;
  padding: 0 2px;
}

.fletcher-eyes span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #0a0604;
  animation: blink 4.8s ease-in-out infinite;
}

.fletcher-eyes span:last-child {
  animation-delay: 0.08s;
}

.fletcher.rage .fletcher-eyes span,
.fletcher.throwing .fletcher-eyes span {
  background: #2a0806;
  box-shadow: 0 0 4px rgba(139, 20, 16, 0.55);
}

@keyframes blink {
  0%,
  92%,
  100% {
    transform: scaleY(1);
  }
  94%,
  96% {
    transform: scaleY(0.1);
  }
}

.fletcher-mouth {
  position: absolute;
  left: 50%;
  bottom: 8px;
  width: 12px;
  height: 3px;
  margin-left: -6px;
  border-radius: 0 0 6px 6px;
  background: #5a4030;
  transform-origin: center top;
}

.fletcher.talking .fletcher-mouth {
  animation: mouth 0.14s steps(2) infinite;
}

@keyframes mouth {
  0%,
  100% {
    height: 3px;
  }
  50% {
    height: 7px;
  }
}

.fletcher-neck {
  position: absolute;
  left: 50%;
  top: 52px;
  width: 14px;
  height: 14px;
  margin-left: -7px;
  background: linear-gradient(160deg, #8a6248, #3a2418);
  box-shadow: inset -3px 0 4px rgba(0, 0, 0, 0.45);
}

.fletcher-torso {
  position: absolute;
  left: 50%;
  top: 62px;
  width: 72px;
  height: 102px;
  margin-left: -36px;
  background:
    linear-gradient(105deg, rgba(232, 180, 100, 0.12) 0%, transparent 38%),
    linear-gradient(180deg, #0c0c0c 0%, #050505 45%, #000 100%);
  clip-path: polygon(12% 0, 88% 0, 100% 100%, 0 100%);
  box-shadow:
    inset 0 16px 0 #161616,
    inset -14px 0 22px rgba(0, 0, 0, 0.85),
    inset 8px 0 16px rgba(40, 28, 16, 0.2);
}

.fletcher-arm {
  position: absolute;
  top: 68px;
  width: 16px;
  height: 78px;
  background: linear-gradient(180deg, #0a0a0a, #000);
  transform-origin: top center;
  box-shadow: inset -3px 0 6px rgba(0, 0, 0, 0.7);
}

.fletcher-arm.left {
  left: 10px;
  transform: rotate(16deg);
  will-change: transform;
}

.fletcher-arm.right {
  right: 8px;
  transform: rotate(-18deg);
}

.hand {
  position: absolute;
  left: 50%;
  bottom: -6px;
  width: 14px;
  height: 14px;
  margin-left: -7px;
  border-radius: 50%;
  background: linear-gradient(140deg, #b8926a, #5a3828);
  box-shadow:
    4px -3px 10px rgba(232, 180, 100, 0.2),
    inset -3px -2px 0 rgba(0, 0, 0, 0.35);
  z-index: 2;
}

.baton {
  position: absolute;
  left: 50%;
  top: 100%;
  width: 3px;
  height: 42px;
  margin-left: -1.5px;
  margin-top: -2px;
  background: linear-gradient(180deg, #fff4e4, #a89880);
  border-radius: 1px;
  transform-origin: top center;
  transform: rotate(-42deg);
  box-shadow: 0 0 14px rgba(239, 228, 212, 0.55);
  z-index: 1;
}

.fletcher.calm .fletcher-arm.right,
.fletcher.praise .fletcher-arm.right,
.fletcher.irritation .fletcher-arm.right {
  /* Beat-synced in JS */
  animation: none;
}

.fletcher.praise {
  filter:
    drop-shadow(0 18px 22px rgba(0, 0, 0, 0.75))
    drop-shadow(0 0 14px rgba(232, 226, 214, 0.28));
}

.fletcher.irritation {
  filter:
    drop-shadow(0 18px 22px rgba(0, 0, 0, 0.75))
    drop-shadow(0 0 12px rgba(196, 146, 32, 0.45));
}

.fletcher.irritation .fletcher-brow {
  top: 12px;
  height: 5px;
}

.fletcher.rage,
.fletcher.throwing {
  filter:
    drop-shadow(0 18px 22px rgba(0, 0, 0, 0.75))
    drop-shadow(0 0 18px rgba(139, 20, 16, 0.7));
}

.fletcher.rage {
  animation: shake 0.09s linear infinite;
}

.fletcher.rage .fletcher-brow,
.fletcher.throwing .fletcher-brow {
  top: 11px;
  background: #3a100c;
}

.fletcher.throwing .fletcher-arm.right {
  animation: throw-arm 0.32s ease-out forwards;
}

@keyframes conduct {
  0%,
  100% {
    transform: rotate(-18deg);
  }
  50% {
    transform: rotate(-48deg);
  }
}

@keyframes conduct-sharp {
  0%,
  100% {
    transform: rotate(-8deg);
  }
  50% {
    transform: rotate(-62deg);
  }
}

@keyframes tense {
  0%,
  100% {
    transform: translateX(-50%) translateY(0);
  }
  50% {
    transform: translateX(-50%) translateY(1px);
  }
}

@keyframes shake {
  0%,
  100% {
    transform: translateX(calc(-50% - 3px));
  }
  50% {
    transform: translateX(calc(-50% + 3px));
  }
}

@keyframes throw-arm {
  0% {
    transform: rotate(-12deg);
  }
  60% {
    transform: rotate(-140deg) translateY(-8px);
  }
  100% {
    transform: rotate(-110deg) translateY(-4px);
  }
}

.speech {
  position: absolute;
  left: 50%;
  bottom: calc(100% + 2px);
  transform: translateX(-50%);
  min-width: 180px;
  max-width: 300px;
  padding: 0.55rem 0.85rem;
  background: rgba(5, 4, 3, 0.82);
  color: var(--cream);
  font-family: var(--font-scene);
  font-size: 0.88rem;
  line-height: 1.4;
  letter-spacing: 0.02em;
  border: none;
  border-bottom: 1px solid rgba(196, 137, 58, 0.35);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(4px);
  animation: speech-pop 0.32s ease;
  z-index: 8;
}

.speech::after {
  content: none;
}

.speech.harsh {
  background: rgba(20, 6, 5, 0.9);
  color: #f0e8dc;
  border-bottom-color: rgba(139, 20, 16, 0.75);
  letter-spacing: 0.03em;
}

@keyframes speech-pop {
  from {
    opacity: 0;
    transform: translateX(-50%) translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateX(-50%);
  }
}

/* Folding chair */
.chair {
  position: absolute;
  left: 62%;
  top: 18%;
  width: 44px;
  height: 58px;
  opacity: 0;
  z-index: 7;
  pointer-events: none;
}

.chair::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(#5a6a78, #5a6a78) 6px 0 / 6px 34px no-repeat,
    linear-gradient(#5a6a78, #5a6a78) 32px 0 / 6px 34px no-repeat,
    linear-gradient(#6a7a88, #6a7a88) 4px 10px / 36px 5px no-repeat,
    linear-gradient(#4a5460, #4a5460) 2px 32px / 40px 8px no-repeat,
    linear-gradient(#3a424c, #3a424c) 8px 40px / 5px 16px no-repeat,
    linear-gradient(#3a424c, #3a424c) 31px 40px / 5px 16px no-repeat;
  filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.4));
}

.chair.flying {
  opacity: 1;
  animation: chair-fly 0.58s cubic-bezier(0.15, 0.7, 0.25, 1) forwards;
}

@keyframes chair-fly {
  0% {
    transform: translate(0, 0) rotate(0);
  }
  100% {
    transform: translate(-90px, 210px) rotate(-480deg) scale(1.3);
  }
}

/* Taiko lane — dominate the lower stage */
.taiko-zone {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: min(48%, 340px);
  min-height: 200px;
  padding: 0 clamp(0.75rem, 3vw, 2rem) clamp(3.6rem, 9vh, 5.5rem);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  gap: 0.45rem;
  z-index: 40;
  background: linear-gradient(
    180deg,
    transparent 0%,
    rgba(5, 4, 3, 0.35) 35%,
    rgba(5, 4, 3, 0.55) 100%
  );
}

.floor-glow {
  position: absolute;
  left: 50%;
  bottom: 38%;
  width: min(420px, 55vw);
  height: 72px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse, rgba(0, 0, 0, 0.65), transparent 70%);
  pointer-events: none;
  z-index: 4;
}

.count-call.sticks {
  color: var(--cream);
  font-size: 1.55rem;
  text-shadow: 0 0 14px rgba(239, 228, 212, 0.25);
}

.lane-progress {
  position: absolute;
  left: 0;
  right: 0;
  top: 14px;
  height: 2px;
  background: rgba(239, 228, 212, 0.08);
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

#lane-fill {
  height: 100%;
  width: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: linear-gradient(90deg, var(--amber), var(--blood));
  transition: transform 0.1s linear;
  box-shadow: 0 0 8px rgba(196, 137, 58, 0.4);
}

.rehearsal.punch,
.rehearsal.beat-flash::after {
  /* Disabled — stage overlays felt like hit flashes */
  animation: none !important;
  content: none;
  opacity: 0;
}

#accuracy.bump {
  animation: combo-bump 0.22s ease;
}

.count-call {
  position: absolute;
  left: 50%;
  top: -28px;
  transform: translateX(-50%);
  font-family: var(--font-display);
  font-size: 2rem;
  letter-spacing: 0.12em;
  color: var(--amber-hot);
  text-shadow: 0 0 20px rgba(240, 180, 90, 0.45);
  z-index: 3;
  pointer-events: none;
}

.count-call.pop {
  animation: count-pop 0.18s ease;
}

@keyframes count-pop {
  from {
    transform: translateX(-50%) scale(1.25);
    opacity: 0.4;
  }
  to {
    transform: translateX(-50%) scale(1);
    opacity: 1;
  }
}

.hit-float {
  position: absolute;
  left: 78px;
  top: 8px;
  transform: translate(-50%, 0);
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: 0.08em;
  opacity: 0;
  pointer-events: none;
  z-index: 4;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.65);
}

.hit-float.show {
  animation: hit-float-up 0.42s ease-out forwards;
}

.hit-float.perfect {
  color: var(--amber);
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.55);
}

.hit-float.great {
  color: var(--amber);
}

.hit-float.ok {
  color: var(--warn);
}

.hit-float.miss {
  color: var(--blood);
}

@keyframes hit-float-up {
  0% {
    opacity: 0;
    transform: translate(-50%, 8px) scale(0.9);
  }
  25% {
    opacity: 1;
  }
  100% {
    opacity: 0;
    transform: translate(-50%, -22px) scale(1.05);
  }
}

.taiko-lane {
  position: relative;
  width: min(1100px, 96%);
  height: 140px;
  filter: drop-shadow(0 12px 28px rgba(0, 0, 0, 0.55));
}

.taiko-lane.shake {
  animation: lane-shake 0.28s ease;
}

@keyframes lane-shake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px);
  }
  55% {
    transform: translateX(4px);
  }
  75% {
    transform: translateX(-2px);
  }
}

#taiko {
  display: block;
  width: 100%;
  height: 140px;
  border-radius: 6px;
}

.taiko-drum {
  position: absolute;
  left: 30px;
  top: 50%;
  width: 96px;
  height: 96px;
  margin: 0;
  padding: 0;
  transform: translateY(-50%);
  background: transparent;
  box-shadow: none;
  border-radius: 50%;
  z-index: 2;
  display: grid;
  place-items: center;
}

.taiko-drum:hover {
  background: transparent;
  transform: translateY(-50%);
  box-shadow: none;
}

.drum-face {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 26%, rgba(255, 246, 230, 0.55), transparent 28%),
    radial-gradient(circle at 35% 32%, #efe4d2 0%, #c9b090 42%, #8a6e52 68%, #4a3828 100%);
  box-shadow:
    inset 0 -10px 18px rgba(0, 0, 0, 0.4),
    inset 0 5px 10px rgba(255, 240, 220, 0.22),
    0 0 0 3px #1a1612,
    0 0 0 5px #3a2c22,
    0 0 0 8px #7a5a38,
    0 0 0 10px #2a2018,
    0 10px 22px rgba(0, 0, 0, 0.55);
}

.drum-ring {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid transparent;
  pointer-events: none;
  opacity: 0;
}

.taiko-drum.playing .drum-ring {
  opacity: 1;
  border-color: rgba(212, 146, 58, 0.35);
  animation: drum-breathe 0.6s ease-in-out infinite;
}

@keyframes drum-breathe {
  0%,
  100% {
    transform: scale(1);
    opacity: 0.45;
  }
  50% {
    transform: scale(1.08);
    opacity: 0.85;
  }
}

.drum-label {
  display: none;
}

.taiko-drum.hit-don .drum-face,
.taiko-drum.hit-ka .drum-face {
  animation: drum-don 0.1s ease;
  filter: none;
}

@keyframes drum-don {
  0% { transform: scale(1); }
  40% { transform: scale(0.94); }
  100% { transform: scale(1); }
}

.taiko-keys {
  display: flex;
  gap: 1.25rem;
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.04em;
}

.taiko-keys .key {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  margin-right: 0.35rem;
  vertical-align: -1px;
}

.taiko-keys .key.don {
  background: var(--blood);
  box-shadow: inset 0 0 0 2px #1a1a1a;
}

.taiko-keys .key.ka {
  background: var(--amber);
  box-shadow: inset 0 0 0 2px #1a1a1a;
}

.footer-hud {
  position: absolute;
  left: 0;
  right: 0;
  bottom: clamp(6px, 1.2vh, 14px);
  z-index: 30;
  margin: 0;
  padding: 1.4rem clamp(0.85rem, 3vw, 1.75rem) 0.55rem;
  background: linear-gradient(180deg, transparent 0%, rgba(5, 4, 3, 0.72) 42%, rgba(5, 4, 3, 0.88) 100%);
  pointer-events: none;
}

.footer-hud > * {
  pointer-events: auto;
}

.footer-hud .pocket-wrap,
.footer-hud .hit-history,
.footer-hud .pulse-cue,
.footer-hud .judge {
  max-width: 1100px;
  margin-left: auto;
  margin-right: auto;
}

.hud-row {
  display: flex;
  align-items: flex-end;
  gap: 1rem;
  max-width: 1100px;
  margin: 0 auto;
}

.mood {
  text-align: left;
  flex: 1;
}

.stat,
.combo-wrap {
  text-align: right;
  min-width: 3.2rem;
}

.take-badge {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  border: 1px solid rgba(239, 228, 212, 0.18);
  padding: 0.35rem 0.55rem;
  align-self: center;
  white-space: nowrap;
}

.take-badge[data-take="2"] {
  color: var(--amber);
  border-color: rgba(196, 137, 58, 0.4);
}

.take-badge[data-take="3"] {
  color: var(--blood);
  border-color: rgba(139, 20, 16, 0.5);
  animation: take-pulse 1.2s ease-in-out infinite;
}

.timing-bias {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 72px;
  align-self: center;
}

.bias-label {
  font-size: 0.55rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.bias-track {
  position: relative;
  flex: 1;
  height: 3px;
  background: rgba(239, 228, 212, 0.12);
  min-width: 48px;
}

.bias-needle {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 6px;
  height: 6px;
  margin: -3px 0 0 -3px;
  border-radius: 50%;
  background: var(--cream);
  transition: left 0.18s ease, background 0.2s ease;
}

.bias-needle.early {
  background: var(--amber);
}

.bias-needle.late {
  background: var(--blood);
}

.hit-history {
  display: flex;
  gap: 2px;
  justify-content: center;
  margin-top: 0.3rem;
  min-height: 4px;
  flex-wrap: wrap;
  max-width: 100%;
  opacity: 0.55;
}

.hit-history .hist {
  width: 4px;
  height: 4px;
  border-radius: 0;
  background: rgba(232, 226, 214, 0.1);
}

.hit-history .hist.perfect {
  background: rgba(232, 226, 214, 0.85);
  box-shadow: none;
}

.hit-history .hist.great {
  background: rgba(196, 137, 58, 0.7);
}

.hit-history .hist.ok {
  background: rgba(196, 146, 32, 0.55);
}

.hit-history .hist.miss {
  background: rgba(139, 20, 16, 0.75);
}

.end-best {
  margin-top: 0.55rem;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  color: var(--muted);
}

@keyframes take-pulse {
  0%,
  100% {
    opacity: 0.85;
  }
  50% {
    opacity: 1;
  }
}

#combo,
#accuracy {
  font-family: var(--font-display);
  font-size: 1.7rem;
  line-height: 1;
  display: block;
  color: var(--cream);
}

#combo.hot {
  color: #fff8f0;
  text-shadow:
    0 0 14px rgba(232, 226, 214, 0.55),
    0 0 28px rgba(196, 137, 58, 0.25);
}

#combo.bump {
  animation: combo-bump 0.22s ease;
}

@keyframes combo-bump {
  0% {
    transform: scale(1);
  }
  40% {
    transform: scale(1.28);
  }
  100% {
    transform: scale(1);
  }
}

.combo-label,
.stat-label {
  display: block;
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.stat-label {
  display: inline;
  margin-left: 1px;
}

.end-stats {
  margin-top: 0.65rem;
  color: var(--muted);
  font-size: 0.8rem;
  letter-spacing: 0.04em;
}

.fletcher.talking .fletcher-head {
  animation: talk 0.16s steps(2) infinite;
}

@keyframes talk {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(1px);
  }
}

.mood-label {
  display: block;
  font-size: 0.62rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.28rem;
}

.mood-bar {
  height: 5px;
  background: rgba(239, 228, 212, 0.08);
  overflow: hidden;
}

#mood-fill {
  height: 100%;
  width: 8%;
  background: linear-gradient(90deg, var(--charcoal), var(--amber), var(--blood));
  transition: width 0.28s ease;
}

.pulse-cue {
  margin-top: 0.55rem;
  color: var(--muted);
  font-family: var(--font-scene);
  font-size: 0.95rem;
  min-height: 1.3em;
  transition: color 0.25s ease, opacity 0.25s ease;
}

.judge {
  height: 1.5em;
  margin-top: 0.15rem;
  font-family: var(--font-display);
  font-size: 1.55rem;
  letter-spacing: 0.08em;
  opacity: 0;
}

.judge.show {
  opacity: 1;
  animation: judge-in 0.22s ease;
}

.judge.perfect {
  color: var(--amber);
  text-shadow: none;
}

.judge.great {
  color: var(--amber);
}

.judge.ok {
  color: var(--warn);
}

.judge.miss {
  color: var(--blood);
}

@keyframes judge-in {
  from {
    transform: translateY(6px) scale(1.12);
    opacity: 0;
  }
  to {
    transform: none;
    opacity: 1;
  }
}

.choice-card {
  padding: 2.4rem 1.25rem;
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(139, 20, 16, 0.22), transparent 60%),
    linear-gradient(180deg, rgba(8, 5, 4, 0.2), transparent);
  border: none;
  border-top: 1px solid rgba(139, 20, 16, 0.35);
  border-bottom: 1px solid rgba(139, 20, 16, 0.2);
  box-shadow: none;
  animation: film-open 0.9s ease both;
}

.choice-prompt {
  font-family: var(--font-scene);
  color: var(--blood);
  margin-bottom: 0.75rem;
}

.choice-title {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 9vw, 3.4rem);
  letter-spacing: 0.04em;
}

.choice-or {
  margin-top: 0.35rem;
  font-family: var(--font-scene);
  color: var(--amber);
  font-size: 1.15rem;
}

.choice-row {
  display: flex;
  gap: 0.75rem;
  justify-content: center;
  flex-wrap: wrap;
}

.choice-row button {
  min-width: 140px;
  background: transparent;
  color: var(--cream);
  border: 1px solid rgba(239, 228, 212, 0.35);
  box-shadow: none;
}

.choice-row button:hover {
  background: var(--blood);
  border-color: var(--blood);
  color: #fff;
  box-shadow: 0 8px 28px rgba(139, 20, 16, 0.4);
}

.choice-row button kbd {
  margin-left: 0.45rem;
  opacity: 0.65;
  font-size: 0.72em;
  border-color: rgba(239, 228, 212, 0.35);
  vertical-align: 1px;
}

.choice-row button:hover kbd {
  border-color: rgba(255, 255, 255, 0.45);
  color: #fff;
}

.end-grade {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.65rem;
}

.end-grade.win {
  color: var(--cream);
}

.end-card {
  padding: 2.5rem 1.4rem;
  background:
    radial-gradient(ellipse 70% 45% at 50% 0%, rgba(196, 137, 58, 0.12), transparent 55%),
    linear-gradient(180deg, rgba(8, 6, 5, 0.15), transparent);
  border: none;
  border-top: 1px solid rgba(232, 226, 214, 0.12);
  border-bottom: 1px solid rgba(232, 226, 214, 0.08);
  box-shadow: none;
  animation: film-open 1s ease both;
}

#end-screen h2 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 10vw, 4rem);
  letter-spacing: 0.06em;
  color: var(--blood);
  text-shadow: 0 0 48px rgba(139, 20, 16, 0.55);
  animation: end-slam 0.55s cubic-bezier(0.2, 0.9, 0.2, 1);
}

#end-screen h2.win {
  color: var(--cream);
  text-shadow:
    0 0 40px rgba(232, 226, 214, 0.35),
    0 0 60px rgba(196, 137, 58, 0.2);
}

@keyframes end-slam {
  from {
    opacity: 0;
    transform: scale(1.2);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

#end-sub {
  margin-top: 1rem;
  font-family: var(--font-scene);
  font-size: 1.05rem;
  line-height: 1.45;
  color: var(--cream);
}

.rehearsal.impact {
  animation: impact 0.45s ease;
}

@keyframes impact {
  0%,
  100% {
    transform: none;
  }
  20% {
    transform: translate(-8px, 4px) rotate(-0.5deg);
  }
  45% {
    transform: translate(7px, -3px) rotate(0.4deg);
  }
  70% {
    transform: translate(-3px, 2px);
  }
}

@media (max-width: 560px) {
  #title-screen.screen {
    padding: 1.5rem 1rem 2rem;
  }

  .title-card h1,
  #title-screen h1 {
    font-size: clamp(5rem, 24vw, 8rem);
  }

  .title-stage-hero {
    background-position: center 38%;
  }

  .band-line {
    opacity: 0.3;
    top: 8%;
  }

  .fletcher {
    top: 3%;
    width: 100px;
    height: 175px;
  }

  .speech {
    min-width: 160px;
    font-size: 0.82rem;
  }

  .taiko-zone {
    height: min(52%, 300px);
    min-height: 180px;
    padding-bottom: clamp(4.2rem, 14vh, 5.8rem);
  }

  .taiko-lane {
    width: 100%;
    height: 120px;
  }

  #taiko {
    height: 120px;
  }

  .hud-row {
    flex-wrap: wrap;
    gap: 0.55rem 0.75rem;
  }

  .timing-bias {
    order: 5;
    flex: 1 1 100%;
    justify-content: center;
    min-width: 0;
  }

  .bias-track {
    max-width: 120px;
  }

  .taiko-drum {
    width: 84px;
    height: 84px;
    left: 36px;
  }

  .hit-float {
    left: 78px;
  }

  .footer-hud {
    padding: 1rem 0.65rem 0.4rem;
  }

  #combo,
  #accuracy {
    font-size: 1.4rem;
  }

  .audio-dock {
    right: 0.5rem;
    padding: 0.35rem 0.5rem;
  }

  .vol-slider {
    width: 72px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* Bridge overlays — always on top when active */
#bridge-practice.screen.active,
#bridge-finale.screen.active,
#choice-screen.screen.active,
#end-screen.screen.active,
#title-screen.screen.active {
  position: relative;
  z-index: 20;
}

/* ——— Bridges ——— */
.bridge-card {
  padding: 2.6rem 1.5rem;
  background:
    radial-gradient(ellipse 70% 40% at 50% 0%, rgba(196, 137, 58, 0.08), transparent 55%),
    linear-gradient(180deg, rgba(5, 4, 3, 0.2), transparent);
  border: none;
  border-top: 1px solid rgba(232, 226, 214, 0.1);
  border-bottom: 1px solid rgba(232, 226, 214, 0.06);
  box-shadow: none;
  animation: film-open 1s ease both;
}

.bridge-card.practice-bridge {
  background:
    radial-gradient(ellipse 80% 45% at 50% 0%, rgba(190, 200, 185, 0.07), transparent 55%),
    linear-gradient(180deg, rgba(6, 7, 6, 0.25), transparent);
  border-top-color: rgba(190, 200, 185, 0.14);
  border-bottom-color: rgba(190, 200, 185, 0.08);
}

.bridge-card.finale-bridge {
  background:
    radial-gradient(ellipse 80% 45% at 50% 0%, rgba(196, 137, 58, 0.16), transparent 55%),
    radial-gradient(ellipse 60% 30% at 50% 100%, rgba(139, 20, 16, 0.12), transparent 50%),
    linear-gradient(180deg, rgba(8, 5, 3, 0.2), transparent);
  border-top-color: rgba(196, 137, 58, 0.28);
  border-bottom-color: rgba(196, 137, 58, 0.12);
}

.bridge-card h2 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 10vw, 3.8rem);
  letter-spacing: 0.1em;
  margin-top: 0.35rem;
  text-shadow: 0 0 40px rgba(0, 0, 0, 0.5);
}

.bridge-sub {
  margin-top: 0.95rem;
  font-family: var(--font-scene);
  color: var(--cream);
  line-height: 1.5;
  font-size: 1.02rem;
  opacity: 0.92;
}

.bridge-stats {
  margin-top: 0.75rem;
  color: var(--muted);
  font-size: 0.74rem;
  letter-spacing: 0.08em;
}

/* ——— Practice room mode ——— */
.rehearsal.practice-room {
  background:
    radial-gradient(ellipse 100% 40% at 50% -5%, rgba(210, 220, 205, 0.1), transparent 50%),
    radial-gradient(ellipse 90% 50% at 50% 100%, rgba(0, 0, 0, 0.85), transparent 55%),
    linear-gradient(180deg, #0b0c0a 0%, #080907 42%, #060605 100%);
  box-shadow:
    inset 0 0 140px rgba(0, 0, 0, 0.75),
    inset 0 80px 100px rgba(190, 205, 185, 0.04);
}

.rehearsal.practice-room .band-line,
.rehearsal.practice-room .fletcher,
.rehearsal.practice-room .audience,
.rehearsal.practice-room .overhead {
  display: none !important;
}

.rehearsal.practice-room .room-wall {
  background:
    radial-gradient(ellipse 70% 55% at 50% 0%, rgba(200, 210, 195, 0.09), transparent 65%),
    linear-gradient(180deg, #090a08, transparent);
}

.rehearsal.practice-room .floor-glow {
  background: radial-gradient(ellipse, rgba(180, 190, 170, 0.08), transparent 70%);
}

/* ——— Finale stage mode ——— */
.rehearsal.finale-stage {
  background:
    radial-gradient(ellipse 70% 45% at 50% 12%, rgba(232, 170, 80, 0.22), transparent 55%),
    radial-gradient(ellipse 110% 55% at 50% 100%, rgba(0, 0, 0, 0.92), transparent 50%),
    linear-gradient(180deg, #080604 0%, #140e08 36%, #0a0705 70%, #030201 100%);
  box-shadow:
    inset 0 0 140px rgba(0, 0, 0, 0.8),
    inset 0 -60px 90px rgba(139, 20, 16, 0.08);
}

.rehearsal.finale-stage .metronome {
  display: none !important;
}

.rehearsal.finale-stage .audience {
  display: block;
}

.audience {
  display: none;
  position: absolute;
  left: 0;
  right: 0;
  bottom: 36%;
  height: 32%;
  background:
    radial-gradient(ellipse 100% 80% at 50% 100%, rgba(20, 12, 8, 0.9), transparent 70%),
    repeating-linear-gradient(
      90deg,
      transparent 0 9px,
      rgba(0, 0, 0, 0.4) 9px 13px
    ),
    linear-gradient(180deg, transparent 10%, rgba(0, 0, 0, 0.75) 100%);
  clip-path: polygon(0 40%, 5% 20%, 12% 45%, 20% 15%, 28% 42%, 38% 10%, 48% 40%, 58% 12%, 68% 44%, 78% 18%, 88% 42%, 95% 22%, 100% 40%, 100% 100%, 0 100%);
  opacity: 0.65;
  pointer-events: none;
  z-index: 1;
  filter: blur(0.3px);
}

.rehearsal.finale-stage .overhead {
  background: radial-gradient(ellipse at center, rgba(255, 200, 120, 0.38), transparent 65%);
  width: 72%;
  height: 62%;
}

.rehearsal.finale-stage .room-wall {
  background:
    radial-gradient(ellipse 60% 70% at 50% -5%, rgba(180, 100, 30, 0.2), transparent 65%),
    linear-gradient(180deg, #0a0704, transparent);
}

/* ——— Metronome ——— */
.metronome {
  position: absolute;
  right: 8%;
  top: 14%;
  z-index: 6;
  text-align: center;
}

.metro-body {
  position: relative;
  width: 56px;
  height: 90px;
  margin: 0 auto;
}

.metro-arm {
  position: absolute;
  left: 50%;
  bottom: 18px;
  width: 3px;
  height: 70px;
  margin-left: -1.5px;
  background: linear-gradient(180deg, var(--blood), var(--cream));
  transform-origin: bottom center;
  transform: rotate(-22deg);
  border-radius: 2px;
  box-shadow: 0 0 8px rgba(139, 20, 16, 0.4);
  transition: transform 0.08s ease-out;
}

.metro-arm.tick {
  animation: metro-tick 0.12s ease;
}

@keyframes metro-tick {
  0% {
    transform: rotate(-22deg);
  }
  50% {
    transform: rotate(22deg);
  }
  100% {
    transform: rotate(-22deg);
  }
}

.metro-base {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 42px;
  height: 16px;
  margin-left: -21px;
  background: #2a241c;
  clip-path: polygon(10% 0, 90% 0, 100% 100%, 0 100%);
}

.metro-bpm {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  color: rgba(232, 226, 214, 0.55);
}

/* ——— Pocket meter ——— */
.pocket-wrap {
  display: flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.45rem;
}

.pocket-wrap[hidden] {
  display: none !important;
}

.pocket-label {
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
  min-width: 3.2rem;
}

.pocket-bar {
  flex: 1;
  height: 7px;
  background: rgba(239, 228, 212, 0.08);
  overflow: hidden;
}

#pocket-fill {
  height: 100%;
  width: 100%;
  background: linear-gradient(90deg, var(--blood), var(--amber), var(--cream));
  transform-origin: left center;
  transition: width 0.15s ease;
}

#pocket-fill.low {
  animation: pocket-warn 0.45s steps(2) infinite;
}

@keyframes pocket-warn {
  50% {
    filter: brightness(1.35);
  }
}

.pocket-val {
  font-family: var(--font-display);
  font-size: 1.1rem;
  min-width: 1.6rem;
  text-align: right;
  color: var(--cream);
}

.mood.hidden-mood {
  visibility: hidden;
}
