/* DOPHENS NEWS — TV on the ocean floor */
@import url('https://fonts.googleapis.com/css2?family=Share+Tech+Mono&family=Orbitron:wght@500;700&display=swap');

:root {
  --bg-deep: #021018;
  --bg-mid: #06304a;
  --bg-shallow: #0a4a6e;
  --sand: #c4a574;
  --sand-dark: #8a6d44;
  --rock: #3a4550;
  --green: #3dff9a;
  --green-dim: #1a8f55;
  --amber: #ffbf3c;
  --red: #ff4d6d;
  --cyan: #5ce1ff;
  --text: #c8f5dc;
  --muted: #6a9a82;
  --tv-bezel: #1a2228;
  --tv-plastic: #0e1418;
  --glass: #061820;
}

* { box-sizing: border-box; }

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

body {
  min-height: 100vh;
  color: var(--text);
  font-family: "Share Tech Mono", ui-monospace, monospace;
  line-height: 1.45;
  overflow-x: hidden;
  background: #010810;
}

/* —— Ocean column —— */
#ocean {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(40, 140, 200, 0.35) 0%, transparent 55%),
    radial-gradient(ellipse 60% 40% at 20% 30%, rgba(20, 90, 140, 0.4) 0%, transparent 50%),
    radial-gradient(ellipse 50% 35% at 80% 25%, rgba(30, 110, 160, 0.3) 0%, transparent 45%),
    linear-gradient(180deg,
      #0a3d5c 0%,
      #062a42 18%,
      #041e32 40%,
      #031522 65%,
      #021018 82%,
      #010810 100%);
}

#ocean .rays {
  position: absolute;
  inset: -10% 0 40% 0;
  background:
    linear-gradient(105deg, transparent 40%, rgba(180, 230, 255, 0.07) 48%, transparent 56%),
    linear-gradient(95deg, transparent 55%, rgba(140, 210, 255, 0.05) 62%, transparent 70%),
    linear-gradient(112deg, transparent 25%, rgba(200, 240, 255, 0.06) 32%, transparent 40%);
  animation: rayDrift 28s ease-in-out infinite alternate;
  mix-blend-mode: screen;
  opacity: 0.85;
}

#ocean .caustics {
  position: absolute;
  inset: 0 0 28% 0;
  background-image:
    radial-gradient(ellipse 120px 40px at 15% 20%, rgba(120, 220, 255, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 90px 30px at 45% 35%, rgba(100, 200, 240, 0.1) 0%, transparent 70%),
    radial-gradient(ellipse 110px 35px at 72% 18%, rgba(140, 230, 255, 0.11) 0%, transparent 70%),
    radial-gradient(ellipse 80px 28px at 30% 55%, rgba(90, 190, 230, 0.08) 0%, transparent 70%),
    radial-gradient(ellipse 100px 32px at 88% 48%, rgba(110, 210, 250, 0.09) 0%, transparent 70%);
  animation: causticShift 16s ease-in-out infinite alternate;
  opacity: 0.9;
}

#ocean .particles {
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(1.5px 1.5px at 8% 18%, rgba(200, 240, 255, 0.7) 0%, transparent 100%),
    radial-gradient(1px 1px at 18% 42%, rgba(180, 230, 255, 0.5) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 28% 12%, rgba(220, 250, 255, 0.6) 0%, transparent 100%),
    radial-gradient(1px 1px at 38% 58%, rgba(160, 220, 255, 0.45) 0%, transparent 100%),
    radial-gradient(2px 2px at 52% 22%, rgba(200, 240, 255, 0.55) 0%, transparent 100%),
    radial-gradient(1px 1px at 62% 68%, rgba(180, 230, 255, 0.4) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 74% 30%, rgba(210, 245, 255, 0.55) 0%, transparent 100%),
    radial-gradient(1px 1px at 84% 52%, rgba(170, 220, 255, 0.4) 0%, transparent 100%),
    radial-gradient(1px 1px at 12% 78%, rgba(190, 235, 255, 0.35) 0%, transparent 100%),
    radial-gradient(1.5px 1.5px at 92% 15%, rgba(200, 240, 255, 0.5) 0%, transparent 100%),
    radial-gradient(1px 1px at 45% 88%, rgba(160, 210, 240, 0.3) 0%, transparent 100%),
    radial-gradient(1px 1px at 66% 8%, rgba(220, 250, 255, 0.45) 0%, transparent 100%);
  animation: particleRise 40s linear infinite;
  opacity: 0.85;
}

#ocean .dolphin {
  position: absolute;
  width: min(140px, 22vw);
  height: min(48px, 8vw);
  top: 18%;
  left: -20%;
  opacity: 0.22;
  filter: blur(0.4px);
  animation: dolphinPass 48s linear infinite;
  background:
    radial-gradient(ellipse 70% 55% at 42% 55%, rgba(40, 70, 95, 0.95) 0%, transparent 72%),
    radial-gradient(ellipse 18% 40% at 78% 42%, rgba(35, 60, 85, 0.9) 0%, transparent 70%),
    radial-gradient(ellipse 12% 25% at 12% 48%, rgba(30, 55, 80, 0.85) 0%, transparent 70%);
  border-radius: 50% 40% 45% 50%;
  transform: scaleX(-1);
}

#ocean .dolphin::after {
  content: "";
  position: absolute;
  right: 8%;
  top: -35%;
  width: 28%;
  height: 70%;
  background: radial-gradient(ellipse at 40% 80%, rgba(35, 60, 85, 0.9) 0%, transparent 70%);
  border-radius: 50% 50% 20% 80%;
  transform: rotate(-25deg);
}

#ocean .weed {
  position: absolute;
  bottom: 18%;
  width: 10px;
  transform-origin: bottom center;
  animation: weedSway 7s ease-in-out infinite alternate;
}
#ocean .weed.a {
  left: 6%;
  height: 14vmax;
  background: linear-gradient(180deg, transparent 0%, #0a5a48 20%, #086048 100%);
  border-radius: 40% 40% 10% 10%;
  opacity: 0.55;
}
#ocean .weed.b {
  left: 11%;
  height: 10vmax;
  background: linear-gradient(180deg, transparent 0%, #0a6850 15%, #075540 100%);
  border-radius: 40% 40% 10% 10%;
  opacity: 0.45;
  animation-delay: -2s;
  animation-duration: 9s;
}
#ocean .weed.c {
  right: 8%;
  left: auto;
  height: 12vmax;
  background: linear-gradient(180deg, transparent 0%, #0a5a48 20%, #086048 100%);
  border-radius: 40% 40% 10% 10%;
  opacity: 0.5;
  animation-delay: -4s;
}
#ocean .weed.d {
  right: 14%;
  left: auto;
  height: 8vmax;
  background: linear-gradient(180deg, transparent 0%, #0a6850 15%, #075540 100%);
  border-radius: 40% 40% 10% 10%;
  opacity: 0.4;
  animation-delay: -1s;
  animation-duration: 8s;
}

#ocean .anemone {
  position: absolute;
  bottom: 16%;
  width: 28px;
  height: 36px;
  border-radius: 50% 50% 40% 40%;
  opacity: 0.4;
  filter: blur(0.5px);
}
#ocean .anemone.l {
  left: 18%;
  background:
    radial-gradient(circle at 50% 80%, #1a6a5a 0%, transparent 60%),
    radial-gradient(circle at 30% 40%, rgba(255, 120, 160, 0.35) 0%, transparent 50%),
    radial-gradient(circle at 70% 35%, rgba(255, 160, 100, 0.3) 0%, transparent 50%);
}
#ocean .anemone.r {
  right: 20%;
  left: auto;
  background:
    radial-gradient(circle at 50% 80%, #1a5a6a 0%, transparent 60%),
    radial-gradient(circle at 40% 30%, rgba(100, 200, 255, 0.3) 0%, transparent 50%),
    radial-gradient(circle at 60% 45%, rgba(180, 100, 220, 0.25) 0%, transparent 50%);
}

/* Seabed */
#seabed {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  height: min(32vh, 280px);
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 40% 60% at 15% 70%, rgba(50, 55, 60, 0.85) 0%, transparent 70%),
    radial-gradient(ellipse 35% 50% at 85% 75%, rgba(45, 50, 58, 0.8) 0%, transparent 70%),
    radial-gradient(ellipse 25% 40% at 70% 90%, rgba(55, 58, 62, 0.7) 0%, transparent 65%),
    linear-gradient(180deg,
      transparent 0%,
      rgba(120, 95, 55, 0.15) 18%,
      rgba(140, 110, 65, 0.55) 45%,
      #9a7a4a 70%,
      #7a6038 100%);
  box-shadow: inset 0 30px 40px rgba(2, 20, 35, 0.45);
}

#seabed::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(3px 2px at 12% 40%, rgba(180, 150, 100, 0.5) 0%, transparent 100%),
    radial-gradient(2px 2px at 28% 55%, rgba(160, 130, 80, 0.4) 0%, transparent 100%),
    radial-gradient(4px 3px at 48% 35%, rgba(190, 160, 110, 0.45) 0%, transparent 100%),
    radial-gradient(2px 2px at 65% 60%, rgba(150, 120, 70, 0.4) 0%, transparent 100%),
    radial-gradient(3px 2px at 82% 42%, rgba(175, 145, 95, 0.4) 0%, transparent 100%),
    radial-gradient(2px 2px at 38% 72%, rgba(140, 110, 65, 0.35) 0%, transparent 100%);
  opacity: 0.7;
}

#seabed .rock {
  position: absolute;
  bottom: 8%;
  background: linear-gradient(160deg, #4a5560 0%, #2a323a 60%, #1a2028 100%);
  border-radius: 40% 50% 35% 45%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
  opacity: 0.85;
}
#seabed .rock.a { left: 4%; width: 70px; height: 42px; }
#seabed .rock.b { left: 14%; width: 45px; height: 28px; bottom: 14%; opacity: 0.7; }
#seabed .rock.c { right: 6%; width: 80px; height: 48px; }
#seabed .rock.d { right: 18%; width: 38px; height: 24px; bottom: 16%; opacity: 0.65; }

@keyframes rayDrift {
  from { transform: translateX(-2%) skewX(-2deg); opacity: 0.75; }
  to { transform: translateX(3%) skewX(1deg); opacity: 0.95; }
}
@keyframes causticShift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(2%, 1.5%) scale(1.04); }
}
@keyframes particleRise {
  from { transform: translateY(8%); }
  to { transform: translateY(-12%); }
}
@keyframes dolphinPass {
  0% { left: -22%; top: 22%; transform: scaleX(-1) translateY(0); }
  40% { top: 14%; transform: scaleX(-1) translateY(-8px); }
  50% { left: 105%; top: 16%; transform: scaleX(-1) translateY(0); }
  50.01% { left: -22%; opacity: 0; }
  55% { opacity: 0.22; }
  100% { left: -22%; top: 22%; }
}
@keyframes weedSway {
  from { transform: rotate(-6deg); }
  to { transform: rotate(7deg); }
}

/* —— Page chrome over ocean —— */
.wrap {
  position: relative;
  z-index: 3;
  max-width: 920px;
  margin: 0 auto;
  padding: 1rem 1rem 8.5rem;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.topbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--cyan);
  text-shadow: 0 0 12px rgba(92, 225, 255, 0.35);
  margin-bottom: 0.5rem;
}
.topbar .brand {
  font-family: Orbitron, sans-serif;
  font-weight: 700;
  color: var(--green);
  letter-spacing: 0.14em;
}
.blink {
  color: var(--red);
  animation: blink 1.4s steps(2, end) infinite;
}
@keyframes blink {
  50% { opacity: 0.25; }
}

/* —— Stage: TV sits on floor —— */
.stage {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-end;
  padding-bottom: 0.5rem;
  min-height: min(70vh, 640px);
}

.tv-set {
  position: relative;
  width: min(100%, 720px);
  z-index: 4;
  filter: drop-shadow(0 18px 28px rgba(0, 8, 20, 0.65));
}

.tv-bezel {
  background:
    linear-gradient(160deg, #2a343c 0%, #141c22 40%, #0a1014 100%);
  border-radius: 18px 18px 12px 12px;
  padding: 1.1rem 1.15rem 1.4rem;
  border: 2px solid #3a4650;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    inset 0 -2px 8px rgba(0, 0, 0, 0.5),
    0 0 0 3px #0a0e12,
    0 0 40px rgba(61, 255, 154, 0.08);
}

.tv-chrome {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.55rem;
  font-size: 0.62rem;
  letter-spacing: 0.16em;
  color: #8aa;
  font-family: Orbitron, sans-serif;
}
.tv-chrome .on-air {
  color: var(--red);
  text-shadow: 0 0 8px rgba(255, 77, 109, 0.6);
}
.tv-chrome .ch {
  color: var(--amber);
}

.tv-screen {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--glass);
  border-radius: 6px;
  overflow: hidden;
  border: 3px solid #05080a;
  box-shadow:
    inset 0 0 60px rgba(0, 0, 0, 0.55),
    inset 0 0 0 1px rgba(92, 225, 255, 0.15),
    0 0 24px rgba(61, 255, 154, 0.12);
}

.tv-glass {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 50% 40%, rgba(20, 60, 50, 0.35) 0%, transparent 65%),
    linear-gradient(180deg, #0a1a18 0%, #061210 100%);
}

.tv-glass::before {
  /* scanlines */
  content: "";
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(
    0deg,
    transparent 0px,
    transparent 2px,
    rgba(0, 0, 0, 0.18) 2px,
    rgba(0, 0, 0, 0.18) 3px
  );
  pointer-events: none;
  z-index: 6;
  mix-blend-mode: multiply;
  opacity: 0.7;
}

.tv-glass::after {
  /* vignette + CRT curve hint */
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 85% 75% at 50% 45%, transparent 40%, rgba(0, 0, 0, 0.55) 100%);
  pointer-events: none;
  z-index: 7;
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.45);
}

.channel-bug {
  position: absolute;
  top: 0.55rem;
  right: 0.65rem;
  z-index: 8;
  font-family: Orbitron, sans-serif;
  font-size: 0.58rem;
  letter-spacing: 0.14em;
  color: rgba(200, 245, 220, 0.9);
  background: rgba(0, 20, 15, 0.55);
  border: 1px solid rgba(61, 255, 154, 0.35);
  padding: 0.2rem 0.4rem;
  text-shadow: 0 0 6px rgba(61, 255, 154, 0.4);
}

.date-bug {
  position: absolute;
  top: 0.55rem;
  left: 0.65rem;
  z-index: 8;
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  color: var(--cyan);
  background: rgba(0, 15, 25, 0.5);
  padding: 0.2rem 0.4rem;
  border: 1px solid rgba(92, 225, 255, 0.25);
}

.broadcast {
  position: relative;
  z-index: 4;
  height: 100%;
  display: flex;
  flex-direction: column;
  padding: 2.2rem 0.75rem 2.4rem;
  overflow: hidden;
}

.broadcast h1 {
  margin: 0 0 0.35rem;
  font-family: Orbitron, sans-serif;
  font-size: clamp(0.95rem, 3.2vw, 1.35rem);
  letter-spacing: 0.12em;
  color: var(--green);
  text-shadow: 0 0 14px rgba(61, 255, 154, 0.45);
  text-align: center;
}

.broadcast .tagline {
  margin: 0 0 0.75rem;
  text-align: center;
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  color: var(--muted);
}

.cards {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  padding-right: 0.15rem;
  scrollbar-width: thin;
  scrollbar-color: var(--green-dim) transparent;
}

.card {
  display: block;
  text-decoration: none;
  color: inherit;
  padding: 0.45rem 0.55rem;
  border-left: 2px solid rgba(61, 255, 154, 0.5);
  background: rgba(8, 28, 24, 0.72);
  border-top: 1px solid rgba(61, 255, 154, 0.12);
  transition: background 0.15s, border-color 0.15s;
}
.card:hover {
  background: rgba(12, 40, 34, 0.9);
  border-left-color: var(--cyan);
}
.card .src {
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  color: var(--amber);
  margin-bottom: 0.15rem;
}
.card strong {
  display: block;
  font-size: 0.78rem;
  color: var(--text);
  margin-bottom: 0.2rem;
  font-weight: 500;
}
.card .sum {
  font-size: 0.68rem;
  color: var(--muted);
  line-height: 1.35;
}

.signal-lost {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
  font-family: Orbitron, sans-serif;
  font-size: clamp(0.75rem, 2.5vw, 1rem);
  letter-spacing: 0.14em;
  color: var(--amber);
  text-shadow: 0 0 12px rgba(255, 191, 60, 0.4);
  animation: staticFlicker 2.8s steps(3, end) infinite;
}
@keyframes staticFlicker {
  0%, 100% { opacity: 1; }
  40% { opacity: 0.85; }
  55% { opacity: 0.55; }
  70% { opacity: 0.92; }
}

.crawl-wrap {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 8;
  height: 1.55rem;
  background: rgba(0, 12, 10, 0.88);
  border-top: 1px solid rgba(61, 255, 154, 0.35);
  overflow: hidden;
}
.crawl {
  display: inline-block;
  white-space: nowrap;
  padding: 0.28rem 0;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  color: var(--green);
  animation: crawl 55s linear infinite;
}
.crawl span { margin-right: 2.5rem; color: var(--text); }
.crawl .pipe { color: var(--amber); margin: 0 0.35rem; }
@keyframes crawl {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.tv-legs {
  display: flex;
  justify-content: space-between;
  padding: 0 12% 0;
  margin-top: -2px;
}
.tv-legs span {
  width: 18px;
  height: 22px;
  background: linear-gradient(180deg, #2a3238, #12181c);
  border-radius: 0 0 4px 4px;
  box-shadow: 0 4px 0 #1a1510;
}

.tv-base-sand {
  position: relative;
  height: 18px;
  margin: 0 8% -4px;
  background:
    radial-gradient(ellipse 50% 100% at 50% 0%, rgba(180, 150, 90, 0.55) 0%, transparent 70%),
    linear-gradient(180deg, rgba(140, 110, 65, 0.5), transparent);
  border-radius: 50%;
  filter: blur(1px);
  z-index: 2;
}

.remote-strip {
  margin-top: 0.85rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  justify-content: center;
  align-items: center;
}
.remote-strip .ch-btn {
  font-family: Orbitron, sans-serif;
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  padding: 0.35rem 0.55rem;
  border: 1px solid rgba(92, 225, 255, 0.35);
  background: rgba(6, 24, 36, 0.75);
  color: var(--cyan);
  border-radius: 4px;
  cursor: default;
}
.remote-strip .ch-btn.active {
  border-color: rgba(61, 255, 154, 0.65);
  color: var(--green);
  box-shadow: 0 0 10px rgba(61, 255, 154, 0.2);
}
.remote-strip .hint {
  width: 100%;
  text-align: center;
  font-size: 0.62rem;
  color: var(--muted);
  letter-spacing: 0.08em;
  margin-top: 0.25rem;
}

.desk-note {
  margin-top: 0.75rem;
  text-align: center;
  font-size: 0.68rem;
  color: rgba(106, 154, 130, 0.85);
  letter-spacing: 0.06em;
  max-width: 36rem;
}

footer.bay-foot {
  margin-top: 1.25rem;
  text-align: center;
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.08em;
}
footer.bay-foot a {
  color: var(--cyan);
  text-decoration: none;
}
footer.bay-foot a:hover { color: var(--green); }
footer.bay-foot .obs {
  color: var(--amber);
  letter-spacing: 0.12em;
  display: block;
  margin-bottom: 0.25rem;
}

/* Soft water tint over chrome (not TV glass) */
.wrap::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 100% 40% at 50% 100%, rgba(2, 20, 35, 0.35) 0%, transparent 50%),
    linear-gradient(180deg, rgba(10, 60, 90, 0.12) 0%, transparent 30%, rgba(2, 16, 28, 0.2) 100%);
}

@media (max-width: 560px) {
  .wrap { padding-bottom: 7.5rem; }
  .tv-bezel { padding: 0.75rem 0.7rem 1rem; }
  .broadcast { padding: 2rem 0.5rem 2.2rem; }
  .card strong { font-size: 0.72rem; }
}

/* Path bar clearance */
body.hab-path-on .wrap {
  padding-bottom: 9.5rem;
}

/* —— Pod: dolphins, balls, fish bucket —— */
.pod {
  position: fixed;
  inset: 0;
  /* Above seabed (1), below .wrap/TV (3+) so fauna stay in water, not over CRT text */
  z-index: 2;
  pointer-events: none;
  overflow: hidden;
}

.pod-dolphin {
  position: absolute;
  width: min(168px, 26vw);
  height: min(58px, 9vw);
  /* Keep the pod readable against the deep-water background. */
  opacity: 0.96;
  filter: drop-shadow(0 0 8px rgba(140, 225, 255, 0.65));
}
.pod-dolphin .body {
  position: absolute;
  inset: 16% 8% 20% 12%;
  background: radial-gradient(ellipse 70% 60% at 45% 50%, rgba(140, 190, 220, 0.98) 0%, rgba(70, 120, 155, 0.92) 55%, rgba(35, 70, 100, 0.75) 100%);
  border-radius: 50% 42% 48% 50%;
  box-shadow: inset 0 -4px 8px rgba(20, 40, 60, 0.35);
}
.pod-dolphin .beak {
  position: absolute;
  left: 0;
  top: 38%;
  width: 18%;
  height: 22%;
  background: rgba(95, 145, 180, 0.95);
  border-radius: 40% 60% 50% 40%;
}
.pod-dolphin .fin {
  position: absolute;
  right: 28%;
  top: -8%;
  width: 22%;
  height: 55%;
  background: rgba(85, 135, 170, 0.95);
  border-radius: 50% 50% 20% 70%;
  transform: rotate(-28deg);
}
.pod-dolphin .tail {
  position: absolute;
  right: -2%;
  top: 28%;
  width: 16%;
  height: 45%;
  background: rgba(80, 130, 165, 0.95);
  border-radius: 10% 60% 60% 10%;
  clip-path: polygon(0 40%, 100% 0, 100% 100%);
}
/* Keep all three dolphins in the open water beside the set. */
.pod-dolphin.d1 {
  top: 13%;
  left: max(10px, 2.5vw);
  animation: dolphinBob 6.5s ease-in-out infinite;
}
.pod-dolphin.d2 {
  top: 30%;
  left: max(10px, 3vw);
  width: min(140px, 22vw);
  height: min(48px, 7.5vw);
  opacity: 0.92;
  animation: dolphinBob 7.5s ease-in-out -2.2s infinite;
}
.pod-dolphin.d3 {
  top: 42%;
  right: max(10px, 3vw);
  width: min(152px, 24vw);
  height: min(52px, 8vw);
  opacity: 0.94;
  animation: dolphinBobRight 8.5s ease-in-out -3s infinite;
}

@keyframes dolphinBob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-9px); }
}
@keyframes dolphinBobRight {
  0%, 100% { transform: scaleX(-1) translateY(0); }
  50% { transform: scaleX(-1) translateY(-9px); }
}

.enrich-ball {
  position: absolute;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  box-shadow:
    inset -3px -3px 5px rgba(0, 0, 0, 0.35),
    inset 2px 2px 4px rgba(255, 255, 255, 0.35),
    0 2px 6px rgba(0, 10, 20, 0.4);
  opacity: 0.7;
}
.enrich-ball.b1 {
  left: 22%;
  top: 42%;
  background: radial-gradient(circle at 30% 28%, #ff8aa0, #c03050 70%);
  animation: ballBob 5.5s ease-in-out infinite;
}
.enrich-ball.b2 {
  left: 68%;
  top: 34%;
  width: 18px;
  height: 18px;
  background: radial-gradient(circle at 30% 28%, #7ef0ff, #2080a0 70%);
  animation: ballBob 7s ease-in-out infinite;
  animation-delay: -2s;
}
.enrich-ball.b3 {
  left: 40%;
  top: 52%;
  width: 16px;
  height: 16px;
  background: radial-gradient(circle at 30% 28%, #ffe08a, #c09020 70%);
  animation: ballBob 6.2s ease-in-out infinite;
  animation-delay: -3.5s;
}
.enrich-ball.b4 {
  left: 78%;
  top: 48%;
  width: 20px;
  height: 20px;
  background: radial-gradient(circle at 30% 28%, #a8ff9a, #308040 70%);
  animation: ballBob 8s ease-in-out infinite;
  animation-delay: -1s;
}
@keyframes ballBob {
  0%, 100% { transform: translate(0, 0); }
  25% { transform: translate(6px, -14px); }
  50% { transform: translate(-4px, -6px); }
  75% { transform: translate(8px, -18px); }
}

.fish-bucket {
  position: absolute;
  right: max(4%, calc(50% - 420px));
  bottom: min(26vh, 220px);
  width: 56px;
  height: 62px;
  z-index: 3;
  transform-origin: 70% 90%;
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
  pointer-events: auto;
}
.fish-bucket:focus-visible {
  outline: 2px solid #7ef0ff;
  outline-offset: 5px;
  border-radius: 8px;
}
.fish-bucket .pail {
  position: absolute;
  bottom: 0;
  left: 8px;
  width: 40px;
  height: 44px;
  background: linear-gradient(160deg, #6a7a88 0%, #3a4854 55%, #2a343c 100%);
  border-radius: 6px 6px 10px 10px;
  border: 2px solid #8a9aa8;
  box-shadow: inset 0 8px 10px rgba(255, 255, 255, 0.12), 0 4px 8px rgba(0, 0, 0, 0.35);
}
.fish-bucket .pail::before {
  content: "";
  position: absolute;
  top: -10px;
  left: 6px;
  right: 6px;
  height: 14px;
  border: 2px solid #9aabb8;
  border-bottom: none;
  border-radius: 50% 50% 0 0;
}
.fish-bucket .fish-peek {
  position: absolute;
  bottom: 28px;
  left: 14px;
  width: 28px;
  height: 14px;
  background: linear-gradient(90deg, #e07040, #f0a050);
  border-radius: 40% 60% 50% 50%;
  opacity: 0.85;
}
.fish-bucket .fish-peek::after {
  content: "";
  position: absolute;
  right: -4px;
  top: 2px;
  border: 5px solid transparent;
  border-left-color: #e07040;
}

.fish-bucket.feeding {
  animation: bucketTip 2.4s ease-in-out;
}
@keyframes bucketTip {
  0%, 100% { transform: rotate(0deg); }
  30% { transform: rotate(-38deg); }
  55% { transform: rotate(-42deg); }
  80% { transform: rotate(-10deg); }
}

.fish-spray {
  position: absolute;
  right: max(6%, calc(50% - 380px));
  bottom: min(30vh, 260px);
  width: 120px;
  height: 100px;
  pointer-events: none;
  opacity: 0;
  z-index: 3;
}
.fish-spray.on {
  opacity: 1;
  animation: sprayFade 2.6s ease-out forwards;
}
.fish-spray i {
  position: absolute;
  width: 14px;
  height: 7px;
  background: linear-gradient(90deg, #d86838, #f0b060);
  border-radius: 40% 60% 50% 50%;
  opacity: 0;
}
.fish-spray.on i:nth-child(1) { left: 10%; top: 40%; animation: fishArc1 2.2s ease-out; }
.fish-spray.on i:nth-child(2) { left: 30%; top: 30%; animation: fishArc2 2.3s ease-out 0.1s; }
.fish-spray.on i:nth-child(3) { left: 50%; top: 35%; animation: fishArc3 2.1s ease-out 0.15s; }
.fish-spray.on i:nth-child(4) { left: 20%; top: 50%; animation: fishArc2 2.4s ease-out 0.05s; }
.fish-spray.on i:nth-child(5) { left: 45%; top: 45%; animation: fishArc1 2.0s ease-out 0.2s; }
@keyframes fishArc1 {
  0% { opacity: 0; transform: translate(0, 0) rotate(0); }
  15% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50px, -70px) rotate(-40deg); }
}
@keyframes fishArc2 {
  0% { opacity: 0; transform: translate(0, 0) rotate(0); }
  15% { opacity: 1; }
  100% { opacity: 0; transform: translate(-30px, -90px) rotate(20deg); }
}
@keyframes fishArc3 {
  0% { opacity: 0; transform: translate(0, 0) rotate(0); }
  15% { opacity: 1; }
  100% { opacity: 0; transform: translate(20px, -60px) rotate(-15deg); }
}
@keyframes sprayFade {
  0%, 70% { opacity: 1; }
  100% { opacity: 0; }
}

/* One fish travels from the bucket to the right-hand dolphin. */
.feed-fish {
  position: fixed;
  z-index: 4;
  width: 24px;
  height: 12px;
  margin: -6px 0 0 -12px;
  pointer-events: none;
  opacity: 0;
}
.feed-fish::before {
  content: "";
  position: absolute;
  inset: 1px 5px 1px 0;
  background: linear-gradient(90deg, #f2a45a, #df663a);
  border-radius: 50% 42% 48% 50%;
  box-shadow: 0 0 6px rgba(255, 166, 88, 0.75);
}
.feed-fish::after {
  content: "";
  position: absolute;
  right: 0;
  top: 1px;
  border: 5px solid transparent;
  border-right-color: #df663a;
}
.feed-fish span {
  position: absolute;
  left: 5px;
  top: 4px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #18303d;
  z-index: 1;
}
.feed-fish.flying {
  animation: fishToDolphin 1.25s cubic-bezier(.2, .75, .3, 1) forwards;
}
@keyframes fishToDolphin {
  0% { opacity: 0; transform: translate(0, 0) rotate(-8deg) scale(.75); }
  12% { opacity: 1; }
  62% { opacity: 1; transform: translate(var(--feed-mid-x), var(--feed-mid-y)) rotate(-2deg) scale(1); }
  100% { opacity: 0; transform: translate(var(--feed-dx), var(--feed-dy)) rotate(8deg) scale(.7); }
}

/* The receiving dolphin gives the fish a tiny nibble and happy wiggle. */
.pod-dolphin.reacting .body {
  transform-origin: 12% 50%;
  animation: dolphinNibble 1.6s ease-in-out;
}
.pod-dolphin.reacting .tail {
  transform-origin: 0 50%;
  animation: tailWiggle 1.6s ease-in-out;
}
@keyframes dolphinNibble {
  0%, 100% { transform: scale(1); }
  25% { transform: scale(1.05, .94) translateX(-3px); }
  45% { transform: scale(.98, 1.03) translateX(2px); }
  65% { transform: scale(1.04, .96) translateX(-2px); }
}
@keyframes tailWiggle {
  0%, 100% { transform: rotate(0); }
  25% { transform: rotate(16deg); }
  45% { transform: rotate(-12deg); }
  65% { transform: rotate(9deg); }
}

.feed-timer {
  position: relative;
  z-index: 4;
  margin: 0.35rem auto 0;
  text-align: center;
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  color: rgba(92, 225, 255, 0.75);
  text-shadow: 0 0 8px rgba(20, 80, 120, 0.5);
}
.feed-timer.feeding-now {
  color: var(--amber);
}

/* Ambient dock — music-only pattern */
#yt-bg-wrap {
  position: fixed;
  width: 1px;
  height: 1px;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
  overflow: hidden;
}
#yt-bg-wrap.on { /* keep offscreen */ }
#ambient {
  position: fixed;
  left: 50%;
  transform: translateX(-50%);
  bottom: 3.4rem;
  z-index: 20;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  max-width: 92vw;
}
#ambient .song-label {
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  text-align: center;
}
#ambient-toggle {
  font-family: "Share Tech Mono", ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  padding: 0.45rem 0.85rem;
  border: 1px solid rgba(92, 225, 255, 0.4);
  background: rgba(4, 20, 32, 0.88);
  color: var(--cyan);
  border-radius: 4px;
  cursor: pointer;
}
#ambient-toggle.playing {
  border-color: rgba(61, 255, 154, 0.55);
  color: var(--green);
  box-shadow: 0 0 12px rgba(61, 255, 154, 0.2);
}
#ambient-toggle:hover {
  border-color: var(--green);
}

body.hab-path-on #ambient {
  bottom: 3.8rem;
}

/* —— Background school and occasional visitors —— */
.fish-school {
  position: absolute;
  top: 30%;
  left: -12%;
  width: 240px;
  height: 96px;
  opacity: 0.88;
  filter: drop-shadow(0 0 4px rgba(140, 230, 255, 0.45));
  animation: schoolPass 36s linear infinite;
  animation-delay: -10s; /* mid-school on load */
}
.fish-school i {
  position: absolute;
  width: 28px;
  height: 13px;
  border-radius: 55% 45% 48% 52%;
  background: linear-gradient(180deg, #e8fbff 0%, #9ee8f8 35%, #5ec8e0 70%, #3a9bb8 100%);
  box-shadow: 0 0 8px rgba(150, 235, 255, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.55);
}
.fish-school i::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 2px;
  width: 10px;
  height: 9px;
  background: linear-gradient(90deg, #7ad4ec, #4aa8c4);
  clip-path: polygon(100% 50%, 0 0, 18% 50%, 0 100%);
}
.fish-school i::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 3px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #062838;
  box-shadow: 0 0 0 1px rgba(230, 250, 255, 0.5);
}
.fish-school i:nth-child(1) { left: 4%; top: 34%; transform: scale(1); }
.fish-school i:nth-child(2) { left: 18%; top: 12%; transform: scale(0.88); }
.fish-school i:nth-child(3) { left: 28%; top: 52%; transform: scale(1.08); }
.fish-school i:nth-child(4) { left: 42%; top: 24%; transform: scale(0.95); }
.fish-school i:nth-child(5) { left: 54%; top: 58%; transform: scale(1); }
.fish-school i:nth-child(6) { left: 64%; top: 6%; transform: scale(0.85); }
.fish-school i:nth-child(7) { left: 76%; top: 38%; transform: scale(0.98); }
.fish-school i:nth-child(8) { left: 88%; top: 20%; transform: scale(0.9); }
@keyframes schoolPass {
  0% { left: -28%; transform: translateY(4px) scaleX(1); }
  22% { transform: translateY(-10px) scaleX(1); }
  44% { left: 106%; transform: translateY(6px) scaleX(1); }
  44.01% { left: 106%; transform: translateY(6px) scaleX(-1); }
  66% { transform: translateY(-8px) scaleX(-1); }
  88% { left: -28%; transform: translateY(4px) scaleX(-1); }
  88.01%, 100% { left: -28%; transform: translateY(4px) scaleX(1); }
}

/* Turtle and octopus stay readable in the open water beside the set. */
.rare-octopus,
.rare-turtle {
  position: absolute;
  pointer-events: none;
  will-change: transform, opacity;
}
.rare-octopus {
  top: 48%;
  right: max(12px, 4vw);
  width: 96px;
  height: 82px;
  opacity: 0.94;
  filter: drop-shadow(0 0 10px rgba(230, 150, 225, 0.62));
  /* Always visible, with a negative delay so it is already moving on load. */
  animation: octopusHover 18s ease-in-out -7s infinite;
}
.rare-octopus .head {
  position: absolute;
  left: 24px;
  top: 0;
  width: 48px;
  height: 50px;
  border-radius: 50% 50% 42% 42%;
  background: radial-gradient(circle at 35% 30%, #f0b8dc, #c060a8 45%, #6a3068 100%);
  box-shadow: inset -5px -4px 8px rgba(34, 14, 54, 0.38), 0 0 16px rgba(200, 120, 200, 0.35);
}
.rare-octopus .head::before,
.rare-octopus .head::after {
  content: "";
  position: absolute;
  top: 20px;
  width: 6px;
  height: 7px;
  border-radius: 50%;
  background: #fff6c8;
  box-shadow: 0 0 0 2px rgba(53, 22, 67, 0.7);
}
.rare-octopus .head::before { left: 12px; }
.rare-octopus .head::after { right: 12px; }
.rare-octopus .arm {
  position: absolute;
  top: 38px;
  width: 16px;
  height: 44px;
  border-radius: 45% 45% 55% 55%;
  background: linear-gradient(90deg, #7a3580, #d070b0);
  transform-origin: top center;
}
.rare-octopus .a1 { left: 6px; transform: rotate(28deg); }
.rare-octopus .a2 { left: 22px; transform: rotate(10deg); }
.rare-octopus .a3 { left: 38px; transform: rotate(-2deg); }
.rare-octopus .a4 { left: 52px; transform: rotate(-16deg); }
.rare-octopus .a5 { left: 66px; transform: rotate(-32deg); }
@keyframes octopusHover {
  0%, 100% { opacity: 0.88; transform: translateY(8px); }
  50% { opacity: 1; transform: translate(-18px, -14px); }
}

.rare-turtle {
  top: 20%;
  left: 8%;
  width: 120px;
  height: 66px;
  opacity: 0.82;
  filter: drop-shadow(0 0 8px rgba(120, 200, 160, 0.4));
  animation: turtleDrift 72s linear infinite;
  animation-delay: -18s; /* already drifting on-screen at load */
}
.rare-turtle .shell {
  position: absolute;
  left: 26px;
  top: 10px;
  width: 64px;
  height: 42px;
  border-radius: 50%;
  background: radial-gradient(ellipse at 35% 30%, #c8e898, #6aab70 50%, #2e6a58 100%);
  border: 2px solid rgba(200, 230, 150, 0.75);
  box-shadow: inset -5px -5px 8px rgba(10, 40, 49, 0.42), 0 0 14px rgba(100, 200, 150, 0.3);
}
.rare-turtle .shell::after {
  content: "";
  position: absolute;
  inset: 7px 10px;
  border: 1px solid rgba(220, 240, 170, 0.5);
  border-radius: 50%;
}
.rare-turtle .head {
  position: absolute;
  right: 4px;
  top: 22px;
  width: 24px;
  height: 18px;
  border-radius: 55% 50% 45% 45%;
  background: #8ec88a;
  box-shadow: inset -3px -2px 4px rgba(22, 67, 63, 0.38);
}
.rare-turtle .head::after {
  content: "";
  position: absolute;
  right: 4px;
  top: 5px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #1a3020;
  box-shadow: 0 0 0 1px rgba(230, 245, 180, 0.5);
}
.rare-turtle .flipper {
  position: absolute;
  width: 34px;
  height: 13px;
  border-radius: 70% 30% 60% 40%;
  background: #6ab090;
}
.rare-turtle .f1 { left: 8px; top: 4px; transform: rotate(-24deg); }
.rare-turtle .f2 { left: 8px; top: 44px; transform: rotate(24deg); }
.rare-turtle .f3 { right: 14px; top: 2px; transform: rotate(25deg); }
.rare-turtle .f4 { right: 14px; top: 46px; transform: rotate(-25deg); }
/* Always mid-opacity; slow continuous back-and-forth (on-screen most of the time) */
@keyframes turtleDrift {
  0% { left: -14%; top: 20%; transform: translateY(0) scaleX(-1); opacity: 0.82; }
  45% { left: 102%; top: 26%; transform: translateY(14px) scaleX(-1); opacity: 0.82; }
  45.01% { left: 102%; top: 26%; transform: translateY(14px) scaleX(1); opacity: 0.82; }
  90% { left: -14%; top: 20%; transform: translateY(0) scaleX(1); opacity: 0.82; }
  90.01%, 100% { left: -14%; top: 20%; transform: translateY(0) scaleX(-1); opacity: 0.82; }
}

/* On narrow screens the chrome spans the water column, so use the open band
   between the headline panel and the TV instead of hiding the pod behind it. */
@media (max-width: 560px) {
  .pod-dolphin.d1 { top: 40%; left: 8px; }
  .pod-dolphin.d2 { top: 42%; left: calc(50% - 43px); }
  .pod-dolphin.d3 { top: 44%; right: 8px; }
  .rare-octopus { top: 36%; right: 8px; }
}
