/* LL106 · 绝密航天实验舱。规则仅作用于本玩法。 */
.fw-water-game .fw-play { grid-template-columns: minmax(0, .9fr) minmax(0, 1.2fr); }
.fw-water-game .fw-stage { position: static; height: auto; min-width: 0; padding: 0; border: 0; background: transparent; box-shadow: none; overflow: visible; }
.fw-water-game .fw-entry { min-width: 0; }
.fw-water { position: relative; isolation: isolate; padding: 24px; overflow: visible; overflow-wrap: anywhere; color: #dceafa; border: 1px solid #6ab6d34a; border-radius: 24px; background: radial-gradient(ellipse at 80% 0, #163751, transparent 65%), linear-gradient(145deg, #111f35, #071222 75%); box-shadow: inset 0 1px #b8e5ff20, 0 16px 38px #07162635; }
.fw-water::before { content: ''; position: absolute; z-index: -1; inset: 0; pointer-events: none; opacity: .2; background: repeating-linear-gradient(0deg, transparent 0 3px, #90c8f21c 3px 4px), linear-gradient(#89d3ec22 1px, transparent 1px), linear-gradient(90deg, #89d3ec22 1px, transparent 1px); background-size: auto, 32px 32px, 32px 32px; }
.fw-water .fw-section-title { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 8px; border-bottom: 1px solid #80c6e32b; padding-bottom: 16px; }
.fw-water .fw-section-title h3 { margin: 0; color: #edf5ff; font-size: 22px; font-weight: 750; }
.fw-water .fw-section-title h3::before { content: ''; display: inline-block; width: 8px; height: 18px; border: 1px solid #97edff; border-radius: 3px; margin-right: 10px; vertical-align: -2px; box-shadow: 0 0 12px #67ceff60, inset 0 0 7px #67ceff40; }
.fw-water-stats { display: flex; align-items: stretch; flex-wrap: wrap; gap: 7px; margin: 18px 0 20px; font-size: 11px; font-variant-numeric: tabular-nums; }
.fw-water-stats > span { position: relative; display: flex; align-items: center; min-height: 32px; padding: 6px 11px; border: 1px solid #6db6dd33; border-radius: 16px; color: #a8c4dc; background: #79b9e609; }
.fw-water-stats > span:first-child { flex-direction: column; align-items: flex-start; justify-content: center; min-width: 88px; overflow: hidden; color: #a7e7f8; background: #58d8f114; border-color: #7bdff455; }
.fw-water-stats [data-water-balance] { display: block; height: 32px; line-height: 32px; font-size: 28px; color: #e0faff; font-weight: 700; }
.fw-water-stats [data-water-balance].counting { color: transparent; }
.fw-water-counter { position: absolute; left: 11px; top: 22px; height: 32px; line-height: 32px; overflow: hidden; font-size: 28px; font-weight: 700; color: #e0faff; pointer-events: none; }
.fw-water-digits { display: block; }
.fw-water-digits > span { display: block; height: 32px; line-height: 32px; }
.fw-water-stats .fw-water-state { flex: 1 1 100%; color: #93dbcc; border-color: #7cddbd3b; background: #5fe0ae0b; }
.fw-water-stats .fw-water-state.closed { color: #f1bd88; border-color: #f1b36755; background: #f1b3670e; }
.fw-water-stages { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 7px; list-style: none; padding: 0; margin: 0 0 12px; }
.fw-water-stages[hidden] { display: none; }
.fw-water-stages li { display: flex; align-items: center; gap: 7px; padding: 10px 8px; border: 1px solid #6db6dd33; border-radius: 12px; background: #79b9e609; color: #91abc4; font-size: 12px; }
.fw-water-stages b { display: grid; place-items: center; width: 23px; height: 23px; flex-shrink: 0; border: 1px solid #7dbada48; border-radius: 50%; font-size: 11px; }
.fw-water-stages small { display: block; margin-top: 4px; font-size: 10px; }
.fw-water-stages .current { border-color: #9cecf4; background: #58d8f114; color: #d7f9ff; }
.fw-water-stages .complete { border-color: #7cddbd66; color: #93dbcc; background: #5fe0ae16; }
.fw-water-tubes { position: relative; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 9px; padding: 80px 0 8px; }
.fw-water-tube { --water-color: #79d6ee; --glass-max: 62px; --tube-pad: 3px; position: relative; display: flex; flex-direction: column; align-items: center; gap: 12px; min-width: 44px; min-height: 44px; padding: 10px var(--tube-pad) 26px; border: 0; border-radius: 16px; background: transparent; color: #b6d2ec; cursor: pointer; transition: transform 160ms, filter 160ms; }
.fw-water-glass { position: relative; display: flex; flex-direction: column-reverse; width: 100%; max-width: var(--glass-max); height: 144px; padding: 4px; overflow: hidden; box-sizing: border-box; border: 2px solid #aed8ee66; border-radius: 7px 7px 25px 25px; background: linear-gradient(90deg, #c4eaff22, #5a99c00b 45%, #b6e3ff1c); box-shadow: inset 3px 0 4px #bdefff30, inset -3px 0 4px #03132380, 0 7px 15px #00000038; }
.fw-water-glass::before { content: ''; position: absolute; z-index: 3; left: 5px; top: 7px; bottom: 13px; width: 3px; border-radius: 4px; background: linear-gradient(#e8faff80, #ddf6ff20); pointer-events: none; }
.fw-water-glass::after { content: ''; position: absolute; z-index: 3; left: 0; right: 0; top: 0; height: 6px; border-bottom: 1px solid #ddf5ff90; background: linear-gradient(#def4ff55, #abc8e622); pointer-events: none; }
.fw-water-layer, .fw-water-ghost { --liquid: #79d6ee; display: block; position: relative; flex: 0 0 25%; width: 100%; border-top: 1px solid #ffffff38; background: linear-gradient(180deg, color-mix(in srgb, var(--liquid), white 18%), var(--liquid) 40%, color-mix(in srgb, var(--liquid), #17213c 26%)); transform-origin: bottom; }
.fw-water-layer[data-c="R"], .fw-water-ghost[data-c="R"] { --liquid: #e85570; }
.fw-water-layer[data-c="G"], .fw-water-ghost[data-c="G"] { --liquid: #ecb746; }
.fw-water-layer[data-c="B"], .fw-water-ghost[data-c="B"] { --liquid: #428fdd; }
.fw-water-layer[data-c="P"], .fw-water-ghost[data-c="P"] { --liquid: #9666d7; }
.fw-water-layer:last-of-type::before { content: ''; position: absolute; z-index: 2; top: -2px; left: -3%; width: 106%; height: 6px; border: 1px solid #ffffff6b; border-radius: 50%; background: #ffffff25; animation: fw-water-wave 2300ms ease-in-out infinite; }
.fw-water-placeholder { margin: auto; color: #94b8d4; font-size: 10px; white-space: nowrap; }
.fw-water-placeholder::before { content: ''; position: absolute; left: 7px; right: 7px; top: 12px; height: 2px; border-radius: 3px; background: #8ee1ff; box-shadow: 0 0 10px #79d4ff; animation: fw-water-scan 2500ms ease-in-out infinite; }
.fw-water-tube > b { min-width: 28px; padding: 2px 8px; border: 1px solid #85c2e83b; border-radius: 5px; font: 600 12px/20px Consolas, monospace; color: #a8c9e5; background: #18354c; }
.fw-water-tube.selected { transform: translateY(-14px); }
.fw-water-tube.selected .fw-water-glass { border-color: #a2eaf4; box-shadow: inset 3px 0 4px #bdefff50, 0 0 20px #74d7fa38; }
.fw-water-tube.can-drop .fw-water-glass { border-color: #8eecdf; box-shadow: 0 0 18px #8eecdf55, inset 3px 0 4px #bdefff30; }
.fw-water-tube.unavailable { filter: saturate(.65); }
.fw-water.inactive .fw-water-tubes { filter: saturate(.55); }
.fw-water-tube.pouring { transition: none; transform: none; }
.fw-water-tube.sealed { filter: none; }
.fw-water-tube.sealed .fw-water-glass { border-color: var(--water-color); box-shadow: 0 0 24px color-mix(in srgb, var(--water-color), transparent 65%), inset 3px 0 4px #bdefff30; }
/* 盖子跟随瓶身宽度（两侧各多 2px）；层级低于倒水动画画布（z 5），封盖动画时临时提到上层。 */
.fw-water-cap { position: absolute; z-index: 4; top: 6px; width: min(calc(100% - 2 * var(--tube-pad) + 4px), calc(var(--glass-max) + 4px)); box-sizing: border-box; height: 16px; border: 1px solid #d9ecf4a0; border-radius: 5px 5px 3px 3px; background: linear-gradient(#cbdce8, #6b849c 45%, #d3e0eb 55%, #6d8ba5); box-shadow: 0 3px 5px #00000055; color: #183046; font: 10px/14px sans-serif; }
.fw-water-cap::before { content: ''; position: absolute; inset: 2px 4px auto; height: 2px; border-radius: 2px; background: #ffffffa0; }
.fw-water-cap::after { content: ''; position: absolute; left: calc(50% - 3px); top: 5px; width: 6px; height: 6px; border-radius: 1px; background: #233e52; box-shadow: 0 -3px 0 -1px #a8bfce, 0 -3px 0 0 #233e52; }
.fw-water-tube small { position: absolute; bottom: 2px; color: #aad8e9; font-size: 10px; }
.fw-water-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 15px; }
.fw-water-actions .fw-button { min-height: 44px; max-width: 100%; white-space: normal; border: 1px solid #7dbada48; border-radius: 11px; background: #183047; color: #c5dfec; font-size: 12px; box-shadow: inset 0 1px #dcfaff0a; }
.fw-water-actions .fw-button:hover { background: #21425c; border-color: #90d9ed80; }
.fw-water-game .fw-water-actions .fw-button[data-action="water-draw"] { flex: 1; border-color: #9cecf4; background: linear-gradient(130deg, #a0e6ef, #63b7d6) !important; color: #08223a !important; font-size: 14px; font-weight: 700; box-shadow: 0 0 24px #76defa35, inset 0 1px #ffffff90; }
.fw-water-actions .fw-button:disabled { opacity: .4; cursor: default; }
.fw-water-actions [hidden] { display: none; }
.fw-water-tip { min-height: 40px; margin: 16px 0 12px; color: #a9c7de; font-size: 12px; line-height: 1.7; }
.fw-water-tip.bad { color: #ffb2bd; }
.fw-water-log { border-top: 1px solid #83bcdb30; color: #96b6d0; font-size: 11px; line-height: 1.8; }
.fw-water-log summary { min-height: 44px; padding: 12px 0; cursor: pointer; color: #c1dbef; }
.fw-water-log ol { max-height: 170px; overflow: auto; padding-left: 22px; margin-top: 0; scrollbar-width: thin; }
.fw-water-log li { padding: 6px 4px; border-bottom: 1px solid #83bcdb16; }
.fw-water-log time { display: block; color: #799bb8; font-size: 10px; }
.fw-water-log .voided { color: #7890a6; text-decoration: line-through; opacity: .65; }
.fw-water-tube:focus-visible, .fw-water-actions .fw-button:focus-visible, .fw-water-log summary:focus-visible { outline: 2px solid #b4f0ff; outline-offset: 3px; }
.fw-water-canvas { position: absolute; visibility: hidden; }
.fw-water-canvas.fw-water-stream { visibility: visible; }
.fw-water-canvas.fw-water-warm { visibility: visible; opacity: 0; pointer-events: none; }
.fw-water-stream { position: absolute; z-index: 5; margin: 0; border-radius: inherit; pointer-events: none; }
.fw-water .fw-water-layer { border-top: 0; background-size: 100% calc(var(--run, 1) * 100%); background-position: 0 calc(var(--slice, 0) * 100% / max(1, var(--run, 1) - 1)); }
.fw-water-ghost { position: absolute; left: 4px; right: 4px; width: auto; height: 25%; z-index: 1; }
.fw-water-ring { position: absolute; z-index: 7; inset: 15px -5px 36px; border: 2px solid; border-radius: 50%; pointer-events: none; }
.fw-water-float { position: absolute; z-index: 8; top: -18px; left: 50%; margin-left: -50px; width: 100px; text-align: center; color: #ffe9b1; font-size: 12px; font-weight: 700; white-space: nowrap; text-shadow: -1px -1px #071222, 1px -1px #071222, -1px 1px #071222, 1px 1px #071222, 0 2px 8px #071222; pointer-events: none; }
.fw-water-particle { position: absolute; z-index: 9; width: 18px; height: 18px; background: currentColor; clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 94%, 50% 72%, 21% 94%, 32% 57%, 2% 35%, 39% 35%); pointer-events: none; }
@keyframes fw-water-wave { 0%, 100% { transform: translateX(-1px) scaleY(.8); opacity: .65; } 50% { transform: translateX(1px) scaleY(1.1); opacity: .95; } }
@keyframes fw-water-scan { 0%, 100% { transform: translateY(0); opacity: .25; } 50% { transform: translateY(126px); opacity: .9; } }
@keyframes fw-water-breathe { 0%, 100% { opacity: .25; } 50% { opacity: .85; } }
@media (max-width: 760px) {
  .fw-water-game .fw-play { grid-template-columns: minmax(0, 1fr); }
  .fw-water { padding: 18px 14px; border-radius: 18px; }
  .fw-water .fw-section-title h3 { font-size: 20px; }
  .fw-water-tubes { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 3px; padding-top: 60px; }
  .fw-water-glass { height: 100px; }
  .fw-water-tube { --glass-max: 48px; --tube-pad: 1px; min-width: 40px; gap: 7px; padding: 8px var(--tube-pad) 21px; }
  .fw-water-tube > b { min-width: 23px; padding: 1px 3px; }
  .fw-water-stats { margin: 8px 0 4px; gap: 4px; }
  .fw-water-stages { gap: 4px; margin-bottom: 6px; }
  .fw-water-stages li { flex-direction: column; gap: 6px; text-align: center; padding: 9px 4px; font-size: 11px; }
  .fw-water-actions .fw-button { flex: 1 1 120px; }
  .fw-water-placeholder::before { animation-name: fw-water-scan-small; }
}
@keyframes fw-water-scan-small { 0%, 100% { transform: translateY(0); opacity: .25; } 50% { transform: translateY(90px); opacity: .9; } }
@media (prefers-reduced-motion: reduce) {
  .fw-water *, .fw-water *::before, .fw-water *::after { animation: none !important; transition: none !important; }
  .fw-water-tube.selected { transform: none; }
}

.fw-water-glass.rendered { overflow: visible; background: transparent; border-color: transparent !important; box-shadow: none !important; }
.fw-water-glass.rendered::before, .fw-water-glass.rendered::after { display: none; }
.fw-water-glass.rendered > .fw-water-layer { opacity: 0; }
.fw-water-still { position: absolute; left: -2px; top: -2px; pointer-events: none; }

.fw-water-effects { position: absolute; inset: 0; z-index: 10; pointer-events: none; overflow: visible; }
.fw-water-effects .fw-water-ring { width: 58px; height: 58px; margin: 30px 0 0 -29px; inset: auto; }
.fw-water-effects .fw-water-float { margin: -18px 0 0 -50px; top: auto; }
.fw-water-banner { position: absolute; z-index: 10; left: 50%; top: 36%; transform: translateX(-50%); max-width: 90%; padding: 13px 20px; border: 1px solid #91e9edab; border-radius: 14px; background: #102d43f2; color: #d9ffff; box-shadow: 0 12px 35px #0008, 0 0 26px #71dfeb44; font-size: 16px; font-weight: 700; white-space: nowrap; }
.fw-water-warning, .fw-water-close { margin: 12px 0 0; padding: 12px 14px; border: 1px solid #f2a7808a; border-radius: 12px; background: #773e2b42; color: #ffe0c9; font-size: 12px; line-height: 1.6; }
.fw-water-warning[hidden], .fw-water-close[hidden], .fw-water-finish[hidden] { display: none; }
.fw-water-close { border-color: #80dcbc77; background: #287c6840; color: #d0ffea; }
.fw-water-finish { position: absolute; z-index: 10; top: 34%; left: 50%; transform: translateX(-50%); padding: 10px 15px; border: 1px solid #95e9e9; border-radius: 12px; background: #10304bed; color: #dcffff; font-size: 13px; white-space: nowrap; pointer-events: none; }
.fw-water-actions .fw-water-attn { border-color: #ffd19b; box-shadow: 0 0 18px #ffb66966; }
.fw-water-guide .fw-water-glass { animation: fw-water-guide 900ms cubic-bezier(.22,.65,.3,1) 2; }
@keyframes fw-water-guide { 50% { filter: brightness(1.55); box-shadow: 0 0 22px #a0eeff88; } }
@media (max-width: 400px) { .fw-water { padding: 14px 10px; } .fw-water-stages { gap: 3px; } .fw-water-stages li { padding: 5px 2px; gap: 2px; font-size: 10px; } .fw-water-stages small { font-size: 8px; } .fw-water-tubes { gap: 1px; padding-top: 52px; } .fw-water-tube { min-width: 40px; } }

/* 横幅坐标由飞行带实测。 */
.fw-water-banner, .fw-water-finish { box-sizing: border-box; width: max-content; max-width: calc(100% - 24px); white-space: nowrap; line-height: 1.4; text-align: center; }
.fw-water-stages li { position: relative; overflow: hidden; }
.fw-water-stages li > b, .fw-water-stages li > span { position: relative; z-index: 1; }
.fw-water-awarded::before { content: ''; position: absolute; inset: 0; background: linear-gradient(90deg, #5fe0ae55, #a0f8d855); transform-origin: left; opacity: 0; animation: fw-water-award 360ms ease-out; }
@keyframes fw-water-award { 0% { transform: scaleX(0); opacity: .8; } 80% { transform: scaleX(1); opacity: .5; } 100% { transform: scaleX(1); opacity: 0; } }
@media (max-width: 760px) {
  .fw-water-stages li { flex-direction: row; justify-content: center; gap: 3px; height: 42px; padding: 4px 2px; font-size: 10px; }
  .fw-water-stages b { width: 18px; height: 18px; font-size: 10px; }
  .fw-water-stages span { white-space: nowrap; }
  .fw-water-stages small { margin-top: 2px; font-size: 8px; }
  .fw-water-stages .complete small { font-size: 0; }
  .fw-water-stages .complete small::after { content: '已获'; font-size: 8px; }
  .fw-water-actions .fw-button { flex: 1 1 0; padding: 8px 5px; font-size: 11px; white-space: nowrap; }
  .fw-water-actions .fw-button span { line-height: 18px; white-space: nowrap; }
  .fw-water-banner { padding: 10px 12px; font-size: 13px; }
}
@media (max-width: 340px) {
  .fw-water-stages li { height: 40px; font-size: 9px; }
  .fw-water-stages b { width: 16px; height: 16px; }
  .fw-water-stats > span { min-height: 26px; padding: 4px 7px; font-size: 10px; }
  .fw-water-tubes { padding-top: 44px; }
  .fw-water-actions { margin-top: 8px; }
}

@media (max-width: 400px) { .fw-water-banner, .fw-water-finish { white-space: normal; } }

/* 撤销/修改对局前的追回提示（弹窗在倒水盘外，按玩法限定）。 */
.fw-overlay[data-entry="LL106"] .fw-void-impact { margin: 10px 0 14px; padding: 10px 12px; border: 1px solid #e8a15f; border-radius: 10px; background: #fff4e6; color: #8a4b12; font-size: 13px; line-height: 1.7; }
.fw-water-log .reclaimed { color: #c99a6b; }
