/* 《潜水艇》主题覆盖 — 青蓝潜望镜 */
:root {
  --accent: #3d9baa;
  --accent-hover: #2e7f8c;
  --blue: var(--accent);
  --link: #3d9baa;
  --link-dark: #7ed7e4;
  --fin-icon: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%27%20viewBox%3D%270%200%2028%2016%27%20fill%3D%27none%27%3E%3Cellipse%20cx%3D%2714%27%20cy%3D%278%27%20rx%3D%2711%27%20ry%3D%275.2%27%20fill%3D%27%23fff%27%2F%3E%3Ccircle%20cx%3D%2714%27%20cy%3D%278%27%20r%3D%273.2%27%20fill%3D%27%231a6b7a%27%2F%3E%3Ccircle%20cx%3D%2714%27%20cy%3D%278%27%20r%3D%271.4%27%20fill%3D%27%237ed7e4%27%2F%3E%3C%2Fsvg%3E");
}
.nav-buy,
.btn-pill,
.transport button:not(.ghost),
.floating-dock a.primary {
  background: var(--accent) !important;
}
.nav-buy:hover,
.btn-pill:hover,
.transport button:not(.ghost):hover,
.floating-dock a.primary:hover {
  background: var(--accent-hover) !important;
}
.shark-seg__thumb {
  background: rgba(61, 155, 170, 0.95) !important;
}
.sync-block.is-on {
  border-left: 3px solid var(--accent);
  padding-left: 12px;
}
.sync-progress {
  height: 2px;
  background: rgba(255,255,255,.12);
  border-radius: 2px;
  margin: 0 0 10px;
  overflow: hidden;
}
.sync-progress span {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #3d9baa, #7ed7e4);
  transition: width .12s linear;
}
.sync-block:not(.is-on) .sync-progress { opacity: .25; }
.now-playing {
  margin-top: 12px;
  font-size: 13px;
  letter-spacing: .06em;
  color: rgba(126, 215, 228, .9);
}
.mood-rail a.is-on {
  outline: 2px solid #fff;
  outline-offset: 2px;
  opacity: 1;
  transform: scale(1.25);
}

/* —— 行级歌词追踪 —— */
.lyric-lines {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 4px;
}
.lyric-line {
  display: grid;
  grid-template-columns: 42px 1fr;
  gap: 10px;
  align-items: baseline;
  width: 100%;
  margin: 0;
  padding: 6px 8px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: rgba(255, 255, 255, 0.38);
  font: inherit;
  font-size: 19px;
  line-height: 1.55;
  text-align: left;
  cursor: pointer;
  transition: color .25s ease, background .25s ease, transform .25s ease;
}
.lyric-line .lyric-time {
  font-size: 11px;
  letter-spacing: .04em;
  color: rgba(255, 255, 255, 0.28);
  font-variant-numeric: tabular-nums;
}
.lyric-line.is-past {
  color: rgba(255, 255, 255, 0.48);
}
.lyric-line.is-on {
  color: #fff;
  background: rgba(61, 155, 170, 0.18);
  transform: translateX(4px);
}
.lyric-line.is-on .lyric-time {
  color: rgba(126, 215, 228, 0.9);
}
.lyric-line:hover {
  color: rgba(255, 255, 255, 0.82);
  background: rgba(255, 255, 255, 0.05);
}
.sync-block:not(.is-on) .lyric-line {
  opacity: 0.55;
}
.sync-block.is-on .lyric-line {
  opacity: 1;
}

/* —— 歌词卡：泡在水里 —— */
.lyric-card-stage .tarot-frame {
  isolation: isolate;
  position: relative;
}
.lyric-card-stage .tarot-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  border-radius: inherit;
  background:
    radial-gradient(ellipse 80% 50% at 20% 10%, rgba(126, 215, 228, 0.22), transparent 55%),
    radial-gradient(ellipse 60% 40% at 80% 30%, rgba(61, 155, 170, 0.18), transparent 50%),
    linear-gradient(180deg, rgba(180, 230, 240, 0.12) 0%, transparent 28%, rgba(10, 40, 55, 0.28) 100%);
  mix-blend-mode: soft-light;
  animation: waterCaustic 7s ease-in-out infinite alternate;
}
.lyric-card-stage .water-glass {
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  border-radius: inherit;
  box-shadow:
    inset 0 0 40px rgba(90, 180, 210, 0.25),
    inset 0 -20px 50px rgba(8, 30, 45, 0.35);
  background: linear-gradient(
    125deg,
    rgba(255, 255, 255, 0.18) 0%,
    transparent 28%,
    transparent 62%,
    rgba(255, 255, 255, 0.06) 100%
  );
}
.lyric-card-stage .bubbles {
  position: absolute;
  inset: 0;
  z-index: 5;
  pointer-events: none;
  overflow: hidden;
  border-radius: inherit;
}
.lyric-card-stage .bubbles span {
  position: absolute;
  bottom: -12%;
  border-radius: 50%;
  border: 1px solid rgba(200, 240, 255, 0.55);
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.55), rgba(126, 215, 228, 0.12) 45%, transparent 70%);
  opacity: 0;
  animation: bubbleRise linear infinite;
}
.lyric-card-stage .bubbles span:nth-child(1) { left: 12%; width: 10px; height: 10px; animation-duration: 7.2s; animation-delay: 0s; }
.lyric-card-stage .bubbles span:nth-child(2) { left: 28%; width: 6px; height: 6px; animation-duration: 5.6s; animation-delay: 1.1s; }
.lyric-card-stage .bubbles span:nth-child(3) { left: 44%; width: 14px; height: 14px; animation-duration: 8.4s; animation-delay: 0.4s; }
.lyric-card-stage .bubbles span:nth-child(4) { left: 58%; width: 8px; height: 8px; animation-duration: 6.1s; animation-delay: 2.2s; }
.lyric-card-stage .bubbles span:nth-child(5) { left: 72%; width: 11px; height: 11px; animation-duration: 7.8s; animation-delay: 0.8s; }
.lyric-card-stage .bubbles span:nth-child(6) { left: 84%; width: 5px; height: 5px; animation-duration: 5.2s; animation-delay: 1.7s; }
.lyric-card-stage .bubbles span:nth-child(7) { left: 36%; width: 7px; height: 7px; animation-duration: 9s; animation-delay: 3s; }
.lyric-card-stage .bubbles span:nth-child(8) { left: 66%; width: 9px; height: 9px; animation-duration: 6.7s; animation-delay: 2.6s; }

@keyframes waterCaustic {
  0% { opacity: 0.75; filter: hue-rotate(0deg); }
  100% { opacity: 1; filter: hue-rotate(12deg); }
}
@keyframes bubbleRise {
  0% { transform: translate3d(0, 0, 0) scale(0.7); opacity: 0; }
  12% { opacity: 0.7; }
  70% { opacity: 0.45; }
  100% { transform: translate3d(12px, -120%, 0) scale(1.05); opacity: 0; }
}

/* 章节页卡片也略带水感 */
.chapter-card {
  position: relative;
}
.chapter-card::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(180, 230, 240, 0.1), transparent 35%, rgba(8, 30, 45, 0.18));
  box-shadow: inset 0 0 28px rgba(61, 155, 170, 0.2);
}

@media (prefers-reduced-motion: reduce) {
  .lyric-card-stage .tarot-frame::before,
  .lyric-card-stage .bubbles span {
    animation: none !important;
  }
  .lyric-card-stage .bubbles span { opacity: 0.35; bottom: 18%; }
}

/* —— 主页 Hero：水流 + 模糊渐清 —— */
.hero--water .hero-media {
  overflow: hidden;
}
.hero-water {
  position: absolute;
  inset: -4%;
  width: 108%;
  height: 108%;
}
.hero-water img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 35%;
  display: block;
}
.hero--water .hero-media img {
  /* 覆盖 motion.css 的 scale，避免打断水流渐清 */
  transition:
    filter 2.8s cubic-bezier(0.22, 0.61, 0.36, 1),
    transform 3.2s cubic-bezier(0.22, 0.61, 0.36, 1),
    opacity 2.4s ease;
}
.hero--water .hero-water__blur {
  filter: blur(22px) saturate(1.15) brightness(0.85);
  transform: scale(1.12);
  opacity: 1;
}
.hero--water .hero-water__clear {
  filter: blur(16px);
  opacity: 0;
  transform: scale(1.08);
}
.hero--water.is-ready .hero-water__blur {
  filter: blur(6px) saturate(1.05);
  transform: scale(1.05);
  opacity: 0.35;
}
.hero--water.is-ready .hero-water__clear {
  filter: blur(2px);
  opacity: 0.85;
  transform: scale(1.03);
}
.hero--water.is-clear .hero-water__blur {
  filter: blur(0);
  opacity: 0;
  transform: scale(1);
}
.hero--water.is-clear .hero-water__clear {
  filter: blur(0);
  opacity: 1;
  transform: scale(1);
}

/* 持续水流层：斜向焦散扫过 */
.hero-water__flow {
  position: absolute;
  inset: -20%;
  pointer-events: none;
  background:
    linear-gradient(
      115deg,
      transparent 20%,
      rgba(126, 215, 228, 0.08) 38%,
      rgba(255, 255, 255, 0.14) 48%,
      rgba(61, 155, 170, 0.1) 58%,
      transparent 72%
    );
  background-size: 220% 220%;
  mix-blend-mode: soft-light;
  opacity: 0.55;
  animation: waterFlowDrift 9s linear infinite;
}
.hero-water__caustic {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse 40% 28% at 30% 18%, rgba(180, 240, 255, 0.22), transparent 60%),
    radial-gradient(ellipse 35% 24% at 68% 28%, rgba(90, 190, 210, 0.16), transparent 55%),
    radial-gradient(ellipse 50% 30% at 50% 0%, rgba(255, 255, 255, 0.12), transparent 50%);
  mix-blend-mode: screen;
  opacity: 0.35;
  animation: waterCausticPulse 5.5s ease-in-out infinite alternate;
}
.hero-water__bubbles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
.hero-water__bubbles span {
  position: absolute;
  bottom: -8%;
  border-radius: 50%;
  border: 1px solid rgba(200, 240, 255, 0.45);
  background: radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.45), rgba(126, 215, 228, 0.08) 50%, transparent 70%);
  opacity: 0;
  animation: heroBubbleRise linear infinite;
}
.hero-water__bubbles span:nth-child(1) { left: 8%; width: 9px; height: 9px; animation-duration: 8s; animation-delay: 0.2s; }
.hero-water__bubbles span:nth-child(2) { left: 18%; width: 5px; height: 5px; animation-duration: 6.5s; animation-delay: 1.4s; }
.hero-water__bubbles span:nth-child(3) { left: 32%; width: 12px; height: 12px; animation-duration: 9.5s; animation-delay: 0.6s; }
.hero-water__bubbles span:nth-child(4) { left: 48%; width: 7px; height: 7px; animation-duration: 7.2s; animation-delay: 2.1s; }
.hero-water__bubbles span:nth-child(5) { left: 62%; width: 10px; height: 10px; animation-duration: 8.8s; animation-delay: 1s; }
.hero-water__bubbles span:nth-child(6) { left: 74%; width: 6px; height: 6px; animation-duration: 6.8s; animation-delay: 2.8s; }
.hero-water__bubbles span:nth-child(7) { left: 84%; width: 14px; height: 14px; animation-duration: 10s; animation-delay: 0.4s; }
.hero-water__bubbles span:nth-child(8) { left: 92%; width: 5px; height: 5px; animation-duration: 7.6s; animation-delay: 1.8s; }

@keyframes waterFlowDrift {
  0% { background-position: 0% 40%; transform: translate3d(-2%, 1%, 0) rotate(-2deg); }
  50% { background-position: 60% 55%; transform: translate3d(2%, -1%, 0) rotate(1deg); }
  100% { background-position: 120% 40%; transform: translate3d(-2%, 1%, 0) rotate(-2deg); }
}
@keyframes waterCausticPulse {
  0% { opacity: 0.28; transform: scale(1) translateY(0); }
  100% { opacity: 0.5; transform: scale(1.04) translateY(-1.5%); }
}
@keyframes heroBubbleRise {
  0% { transform: translate3d(0, 0, 0) scale(0.7); opacity: 0; }
  15% { opacity: 0.55; }
  80% { opacity: 0.25; }
  100% { transform: translate3d(18px, -115vh, 0) scale(1.1); opacity: 0; }
}

/* 文案在水流揭开后再更清晰浮现 */
.hero--water .hero-copy {
  opacity: 0;
  filter: blur(8px);
  transform: translateY(18px);
  transition:
    opacity 1.2s ease 0.9s,
    filter 1.6s ease 0.9s,
    transform 1.4s cubic-bezier(0.22, 0.61, 0.36, 1) 0.9s;
  animation: none;
}
.hero--water.is-ready .hero-copy {
  opacity: 1;
  filter: blur(0);
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  .hero-water__blur,
  .hero-water__clear,
  .hero-water__flow,
  .hero-water__caustic,
  .hero-water__bubbles span,
  .hero--water .hero-copy {
    animation: none !important;
    transition: none !important;
    filter: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  .hero-water__blur { display: none; }
}
