/* Shell Song: the beach at the cove, seven singing shells. */
.scene > video { z-index: 1; }
.bubbles { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.bubbles i { position: absolute; width: 1.1%; aspect-ratio: 1; border-radius: 50%; border: 2px solid rgba(255,255,255,.9); background: rgba(255,255,255,.18); }

/* the shells: an arc on the sand (wide screens) or two rows (tall phones) */
.shells { position: absolute; inset: 0; z-index: 8; pointer-events: none; }
.shell {
  position: absolute; width: var(--s); aspect-ratio: 1; transform: translate(-50%, -50%); pointer-events: auto;
  border: 0; padding: 0; background: none; cursor: pointer; border-radius: 40%;
  transition: transform .35s cubic-bezier(.3, .7, .3, 1), filter .35s ease;
}
.shell .stk { width: 100%; }
.shell .stk b { font-size: calc(var(--s) * .34); top: 60%; }
.shell:focus-visible { outline: 4px solid rgba(255,255,255,.95); outline-offset: 2px; }
.shell.is-sing { transform: translate(-50%, -58%) scale(1.08); filter: drop-shadow(0 0 18px rgba(255, 236, 160, .95)) brightness(1.06); }
.shell.is-glow { animation: glow 1.8s ease-in-out infinite; }
.shell.is-shimmer { animation: shimmer 1.2s ease-in-out infinite; }
@keyframes glow { 50% { filter: drop-shadow(0 0 22px rgba(255, 232, 140, 1)) brightness(1.08); transform: translate(-50%, -54%) scale(1.05); } }
@keyframes shimmer { 0%, 100% { filter: drop-shadow(0 0 4px rgba(255,255,255,.6)); } 50% { filter: drop-shadow(0 0 16px rgba(255, 240, 190, 1)) brightness(1.1); } }

.prompt { top: calc(max(12px, env(safe-area-inset-top)) + 64px); }
.big--start { left: 50%; top: 52%; transform: translate(-50%, -50%); background: radial-gradient(circle at 40% 35%, #F9B8C8, #E58FA6); }
.big--start::before { content: ""; position: absolute; inset: -14px; border-radius: 50%; border: 3px solid rgba(255,255,255,.7); animation: halo 2.8s ease-in-out infinite; }
.big--start.is-hiding { transform: translate(-50%, -50%) scale(.9); }
@keyframes halo { 50% { transform: scale(1.08); opacity: .4; } }

/* narrow phones: the prompt sits under the level row */
@media (max-width: 520px) {
  .prompt { top: calc(max(12px, env(safe-area-inset-top)) + 124px); }
}
@media (prefers-reduced-motion: reduce) {
  .shell.is-glow, .shell.is-shimmer { animation: none; filter: drop-shadow(0 0 16px rgba(255, 232, 140, 1)); }
  .big--start::before, .lvl.is-new { animation: none; }
  .shell { transition: filter .3s ease; }
  .shell.is-sing { transform: translate(-50%, -50%); }
}
@media (min-width: 1400px) and (min-height: 800px) {
  .prompt { top: calc(max(12px, env(safe-area-inset-top)) + 58px); }
}

/* ---------- My song (11/7) ---------- */
.lvl--mine svg { fill: #F7C9D4; stroke: #C2577A; stroke-width: 2.6; stroke-linejoin: round; }
.songbar {
  position: absolute; z-index: 14; left: 50%; top: calc(max(12px, env(safe-area-inset-top)) + 64px); transform: translateX(-50%);
  display: grid; grid-template-columns: repeat(12, 1fr); gap: 4px; width: min(86vw, 640px); padding: 6px 10px; box-sizing: border-box;
  border-radius: 999px; background: rgba(255, 252, 240, .82); border: 2px solid #fff; box-shadow: 0 6px 18px rgba(46, 50, 83, .16);
}
.songbar__slot { aspect-ratio: 1; border-radius: 50%; background: rgba(46, 50, 83, .07); display: grid; place-items: center; transition: transform .2s ease, background .2s ease; }
.songbar__slot img { width: 100%; height: 100%; object-fit: contain; filter: drop-shadow(0 2px 2px rgba(80, 50, 30, .2)); }
.songbar__slot.is-full { background: none; }
.songbar__slot.is-lit { transform: scale(1.35); background: rgba(255, 236, 160, .9); }
.big--play { background: radial-gradient(circle at 40% 35%, #F9B8C8, #E58FA6); opacity: 0; transform: scale(.8); }
.big--play.is-ready { opacity: 1; transform: scale(1); }
.big--play.is-glow { animation: playglow 1.6s ease-in-out infinite; }
@keyframes playglow { 50% { box-shadow: 0 0 0 10px rgba(247, 201, 212, .6), 0 0 34px rgba(229, 143, 166, .9); } }
.beat .drum { fill: #F7C9D4; }
.beat .tip { fill: var(--navy); stroke: none; }
.beat[aria-pressed="false"] { opacity: .5; }
.beat[aria-pressed="false"] .drum { fill: none; }

/* sea friends popping up out of the water */
.friends-pop { position: absolute; inset: 0; z-index: 6; pointer-events: none; }
.pop { position: fixed; transform: translate(-50%, -50%); opacity: 0; }
.pop img { width: 100%; height: auto; display: block; filter: drop-shadow(0 4px 6px rgba(20, 60, 80, .3)); }

@media (max-width: 520px) {
  .songbar { top: calc(max(12px, env(safe-area-inset-top)) + 124px); gap: 2px; padding: 5px 7px; }
}
@media (min-width: 1400px) and (min-height: 800px) {
  .songbar { top: calc(max(12px, env(safe-area-inset-top)) + 64px); }
}
@media (prefers-reduced-motion: reduce) {
  .big--play.is-glow { animation: none; box-shadow: 0 0 0 8px rgba(247, 201, 212, .7); }
}
