/* Naumachia (battleship): the page's own look (loaded only on its page, after app.css and t21.css, whose panels, time
   bar and messages it shares). Two seas on a chart table: the water moves (two layers of waves drift over it, light
   plays on it), the ships are drawn from above, a miss throws up a column of spray and leaves a ring, a hit a blast and
   a fire that keeps burning. Three seas (.nvs-*) and three kinds of ships (.nvk-*): the admin's, or each player's own. */

/* ---------- the seas ---------- */
.nvs-aegean { --w1: #1c86ad; --w2: #0d557f; --w3: #062f4f; --sky: rgba(255,255,255,.22); --sky2: rgba(120,220,255,.18); --streak: .5; --spark: .55;
  --line: rgba(220,245,255,.16); --fr1: #233544; --fr2: #0e1822; --lab: #bfe3f2; --foam: #f4fbff; }
.nvs-sunset { --w1: #3a5f86; --w2: #1d3557; --w3: #0c1a33; --sky: rgba(255,150,70,.38); --sky2: rgba(255,90,60,.16); --streak: .42; --spark: .7;
  --line: rgba(255,220,180,.14); --fr1: #3a2a2a; --fr2: #1a1014; --lab: #ffd9b0; --foam: #fff4e6; }
.nvs-storm { --w1: #33495a; --w2: #1a2b37; --w3: #0a131a; --sky: rgba(190,215,240,.12); --sky2: rgba(140,170,200,.08); --streak: .6; --spark: .3;
  --line: rgba(200,220,240,.12); --fr1: #222a31; --fr2: #0c1014; --lab: #c6d3df; --foam: #e6eef5; }

/* the water: deep colour, long streaks of waves and a sparkle of light, both drifting; the sky's light over it */
.nv-water { position: absolute; inset: 0;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='420' height='220'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='turbulence' baseFrequency='.006 .05' numOctaves='2' seed='5' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  2.6 0 0 0 -1.12'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E") 0 0 / 420px 220px,
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.035' numOctaves='2' seed='9' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  4.2 0 0 0 -2.55'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E") 0 0 / 260px 260px,
    radial-gradient(120% 80% at 78% 6%, var(--sky), transparent 55%),
    radial-gradient(90% 70% at 15% 95%, var(--sky2), transparent 60%),
    linear-gradient(165deg, var(--w1), var(--w2) 55%, var(--w3));
  animation: nvSea 38s linear infinite; }
.nv-water::before { content: ''; position: absolute; inset: -20%; opacity: var(--streak); mix-blend-mode: overlay; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='160'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='turbulence' baseFrequency='.01 .07' numOctaves='3' seed='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  2 0 0 0 -.7'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E") 0 0 / 300px 160px;
  animation: nvSwell 21s linear infinite; }
.nv-water::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: var(--spark);
  background: radial-gradient(60% 40% at 30% 30%, rgba(255,255,255,.18), transparent 70%); animation: nvGlint 9s ease-in-out infinite alternate; }
@keyframes nvSea { to { background-position: 420px 30px, -260px 260px, 0 0, 0 0, 0 0; } }
@keyframes nvSwell { to { transform: translate(-300px, 0); } }
@keyframes nvGlint { to { transform: translate(40%, 30%) scale(1.3); opacity: calc(var(--spark) * .5); } }
/* the storm: rain, and lightning now and then */
.nvs-storm .nv-field::after { content: ''; position: absolute; inset: 0; z-index: 7; pointer-events: none;
  background: repeating-linear-gradient(105deg, rgba(220,235,255,.07) 0 1px, transparent 1px 9px); background-size: 100% 100%; animation: nvRain .5s linear infinite, nvBolt 11s step-end infinite; }
@keyframes nvRain { to { background-position: -9px 18px; } }
@keyframes nvBolt { 0%, 93%, 95.5%, 100% { box-shadow: none; } 93.5%, 96% { box-shadow: inset 0 0 0 999px rgba(210,230,255,.16); } }
/* the chart's lines: one square a tenth of the sea */
.nv-lines { position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to right, var(--line) 1px, transparent 1px) 0 0 / 10% 100%, linear-gradient(to bottom, var(--line) 1px, transparent 1px) 0 0 / 100% 10%; }

/* ---------- the ships (drawn in naumachia.js): seen from above, with their shadow on the water ---------- */
.nv-ship { position: absolute; z-index: 2; pointer-events: none; transition: left .25s cubic-bezier(.3,1.2,.5,1), top .25s cubic-bezier(.3,1.2,.5,1), transform .25s cubic-bezier(.3,1.3,.5,1); }
.nv-ship.down { transform: rotate(90deg); }
.nv-shipsvg { display: block; width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 2px 2px rgba(0,0,0,.35)); }
.nv-ship::after { content: ''; position: absolute; left: 6%; right: -2%; top: 18%; bottom: 18%; z-index: -1; border-radius: 50%;
  box-shadow: 0 0 10px 3px rgba(255,255,255,.18); opacity: .7; animation: nvWake 3.4s ease-in-out infinite; }
@keyframes nvWake { 50% { opacity: .35; transform: scaleX(1.03); } }
.nv-ship.wreck .nv-shipsvg { filter: grayscale(.7) brightness(.45) sepia(.45) contrast(1.15) drop-shadow(0 2px 2px rgba(0,0,0,.4)); }
.nv-ship.wreck { opacity: .88; animation: nvSinkIn 1.2s ease-out; }
.nv-ship.wreck::after { box-shadow: 0 0 12px 4px rgba(20,20,20,.45); animation: none; }
@keyframes nvSinkIn { from { opacity: 1; filter: brightness(1.6); } 30% { filter: brightness(1.3); } }
.nv-ship.shown { opacity: .78; }
.nv-ship.nope { animation: nvNope .4s; }
@keyframes nvNope { 25% { translate: -4px 0; } 75% { translate: 4px 0; } }

/* ---------- where the shots fell: a ring on the water (a miss); fire and smoke (a hit) ---------- */
.nv-marks { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.nv-mk { position: absolute; left: var(--x); top: var(--y); width: 6.4%; height: 6.4%; transform: translate(-50%, -50%); border-radius: 50%; }
.nv-mk.m { background: radial-gradient(circle, rgba(255,255,255,.85) 0 16%, transparent 19% 40%, rgba(255,255,255,.55) 43% 50%, transparent 53%);
  filter: drop-shadow(0 0 2px rgba(255,255,255,.4)); }
.nv-mk.m::after { content: ''; position: absolute; inset: -30%; border-radius: 50%; border: 1px solid rgba(255,255,255,.35); animation: nvRipple 3.2s ease-out infinite; }
@keyframes nvRipple { from { transform: scale(.4); opacity: .9; } to { transform: scale(1.5); opacity: 0; } }
.nv-mk.h { width: 8%; height: 8%; background: radial-gradient(circle, rgba(255,210,120,.95) 0 14%, rgba(255,110,30,.75) 30%, rgba(160,30,10,.0) 62%);
  box-shadow: 0 0 10px 4px rgba(255,120,40,.45); animation: nvEmber 1.1s ease-in-out infinite alternate; }
.nv-mk.h::before { content: ''; position: absolute; left: 18%; right: 18%; bottom: 38%; height: 105%; border-radius: 50% 50% 45% 45% / 70% 70% 30% 30%;
  background: radial-gradient(ellipse at 50% 85%, #fff6c8 0 12%, #ffc23a 30%, #ff6a1a 55%, rgba(200,40,10,0) 75%); transform-origin: 50% 100%;
  animation: nvFlame .42s ease-in-out infinite alternate; filter: blur(.4px); }
.nv-mk.h::after { content: ''; position: absolute; left: 10%; top: -150%; width: 80%; height: 120%; border-radius: 50%;
  background: radial-gradient(circle, rgba(40,40,44,.55), rgba(40,40,44,0) 70%); animation: nvSmoke 2.6s ease-out infinite; }
@keyframes nvEmber { to { box-shadow: 0 0 14px 6px rgba(255,140,50,.55); } }
@keyframes nvFlame { from { transform: scale(.85, .9) rotate(-4deg); } to { transform: scale(1.1, 1.18) rotate(5deg); } }
@keyframes nvSmoke { from { transform: translate(0, 60%) scale(.5); opacity: .8; } to { transform: translate(18%, -40%) scale(1.7); opacity: 0; } }

/* ---------- the effects: the shell, the splash of a miss, the blast of a hit ---------- */
.nv-fx { position: absolute; inset: -10%; z-index: 6; pointer-events: none; }
.nv-field > .nv-fx { inset: 0; overflow: visible; }
.nv-shell { position: absolute; width: 1.6%; height: 1.6%; min-width: 5px; min-height: 5px; border-radius: 50%; background: #fffbe6;
  box-shadow: 0 0 6px 3px rgba(255,220,140,.9), 0 0 16px 6px rgba(255,150,60,.45); z-index: 8; }
.nv-splash, .nv-boom { position: absolute; width: 10%; height: 10%; transform: translate(-50%, -50%); }
.nv-splash b { position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--foam); opacity: 0; animation: nvRing 1.3s ease-out forwards; }
.nv-splash .r2 { animation-delay: .18s; } .nv-splash .r3 { animation-delay: .38s; border-width: 1px; }
@keyframes nvRing { 0% { transform: scale(.2); opacity: .95; } 100% { transform: scale(2.6); opacity: 0; } }
.nv-splash .col { position: absolute; left: 22%; right: 22%; bottom: 40%; height: 220%; border-radius: 45% 45% 30% 30%; transform-origin: 50% 100%;
  background: radial-gradient(ellipse at 50% 100%, #fff 0 25%, rgba(230,245,255,.85) 45%, rgba(230,245,255,0) 72%); opacity: 0; animation: nvColumn 1s ease-out forwards; }
@keyframes nvColumn { 0% { transform: scaleY(.1); opacity: 0; } 15% { opacity: 1; } 40% { transform: scaleY(1); opacity: .95; } 100% { transform: scaleY(.25) scaleX(1.6); opacity: 0; } }
.nv-splash i { position: absolute; left: 50%; top: 50%; width: 3px; height: 3px; margin: -1.5px; border-radius: 50%; background: var(--foam); opacity: 0;
  animation: nvDrop var(--t) cubic-bezier(.2,.7,.5,1) .12s forwards; }
@keyframes nvDrop { 0% { transform: rotate(var(--a)) translate(0); opacity: 1; } 100% { transform: rotate(var(--a)) translate(var(--d)); opacity: 0; } }
.nv-splash.small b { border-width: 1px; animation-duration: .9s; }
.nv-boom b { position: absolute; border-radius: 50%; }
.nv-boom .flash { inset: -60%; background: radial-gradient(circle, rgba(255,255,240,.95), rgba(255,220,120,.6) 30%, rgba(255,160,60,0) 65%); animation: nvFlash .35s ease-out forwards; }
.nv-boom .ball { inset: -20%; background: radial-gradient(circle, #fff3b0 0 15%, #ffb02e 35%, #f0521a 55%, rgba(120,20,10,.0) 75%);
  transform: scale(calc(.3 * var(--k))); animation: nvBall .9s ease-out forwards; }
.nv-boom .ring { inset: -10%; border: 2px solid rgba(255,240,210,.8); opacity: 0; animation: nvShock .6s ease-out forwards; }
@keyframes nvFlash { from { transform: scale(.2); opacity: 1; } to { transform: scale(1.4); opacity: 0; } }
@keyframes nvBall { 0% { transform: scale(.2); opacity: 1; } 40% { transform: scale(calc(1.5 * var(--k))); opacity: 1; } 100% { transform: scale(calc(1.9 * var(--k))); opacity: 0; } }
@keyframes nvShock { 0% { transform: scale(.3); opacity: .9; } 100% { transform: scale(calc(3.2 * var(--k))); opacity: 0; } }
.nv-boom i { position: absolute; left: 50%; top: 50%; width: 4px; height: 2px; margin: -1px -2px; border-radius: 2px; background: #ffe28a; box-shadow: 0 0 4px #ff9a3a;
  opacity: 0; animation: nvSpark var(--t) ease-out forwards; }
@keyframes nvSpark { 0% { transform: rotate(var(--a)) translate(0) scaleX(1); opacity: 1; } 100% { transform: rotate(var(--a)) translate(calc(var(--d) * var(--k))) scaleX(2.5); opacity: 0; } }
.nv-boom em { position: absolute; left: 0; top: 0; width: 100%; height: 100%; border-radius: 50%; background: radial-gradient(circle, rgba(46,44,44,.75), rgba(46,44,44,0) 70%);
  opacity: 0; animation: nvPuff 2.2s ease-out forwards; animation-delay: calc(.15s + var(--i) * .18s); }
@keyframes nvPuff { 0% { transform: translate(0, 0) scale(.5); opacity: 0; } 20% { opacity: .85; } 100% { transform: translate(var(--dx), -120%) scale(2.6); opacity: 0; } }
@media (prefers-reduced-motion: reduce) {
  .nv-water, .nv-water::before, .nv-water::after, .nv-mk.m::after, .nv-mk.h, .nv-mk.h::before, .nv-mk.h::after, .nv-ship::after, .nvs-storm .nv-field::after { animation: none !important; }
}

/* ---------- a sea on its chart table: the numbers on top, the letters on the left ---------- */
.nv-sea { position: relative; display: flex; flex-direction: column; gap: 6px; }
.nv-sea.them { --sz: var(--s1, 420px); } .nv-sea.me { --sz: var(--s2, 260px); }
.nv-box.placing .nv-sea.me { --sz: var(--s1, 420px); }
.nv-sea.hidden { display: none; }
.nv-sea-name { display: flex; align-items: center; gap: 8px; padding-left: 26px; font-size: 11px; font-weight: 900; letter-spacing: 1.4px; text-transform: uppercase; color: var(--muted); }
.nv-sea-name i { width: 8px; height: 8px; border-radius: 50%; background: #ff5a4e; box-shadow: 0 0 8px #ff5a4e; }
.nv-sea.me .nv-sea-name i { background: #5fd1f0; box-shadow: 0 0 8px #5fd1f0; }
.nv-frame { display: grid; grid-template-columns: 22px var(--sz); grid-template-rows: 22px var(--sz); gap: 4px; padding: 10px 12px 12px 8px; border-radius: 16px;
  background: linear-gradient(160deg, var(--fr1), var(--fr2)); box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 0 0 1px rgba(0,0,0,.5), 0 20px 40px -18px rgba(0,0,0,.9); }
.nv-cols { grid-column: 2; grid-row: 1; display: grid; grid-template-columns: repeat(10, 1fr); }
.nv-rows { grid-column: 1; grid-row: 2; display: grid; grid-template-rows: repeat(10, 1fr); }
.nv-cols i, .nv-rows i { display: grid; place-items: center; font-style: normal; font-size: clamp(9px, calc(var(--sz) / 30), 13px); font-weight: 800; color: var(--lab); opacity: .8;
  font-variant-numeric: tabular-nums; }
.nv-field { grid-column: 2; grid-row: 2; position: relative; width: var(--sz); height: var(--sz); border-radius: 6px; overflow: hidden; isolation: isolate;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), inset 0 0 30px rgba(0,0,0,.45); touch-action: manipulation; user-select: none; -webkit-user-select: none; }
.nv-ships { position: absolute; inset: 0; z-index: 2; }
.nv-sea.shake .nv-field { animation: nvShake .5s; }
@keyframes nvShake { 20% { transform: translate(-3px, 2px); } 40% { transform: translate(3px, -2px); } 60% { transform: translate(-2px, -1px); } 80% { transform: translate(2px, 1px); } }
/* aiming: a mouse over the other's sea (or a finger's first tap) shows the sights on the square */
.nv-box.can-fire .nv-sea.them .nv-field { cursor: crosshair; box-shadow: inset 0 0 0 2px rgba(255,90,78,.55), inset 0 0 30px rgba(0,0,0,.45), 0 0 26px -6px rgba(255,90,78,.6); }
.nv-aim { position: absolute; z-index: 5; width: 10%; height: 10%; pointer-events: none; }
.nv-aim.hidden { display: none; }
.nv-aim::before { content: ''; position: absolute; inset: 6%; border-radius: 50%; border: 2px solid #ff5a4e; box-shadow: 0 0 10px rgba(255,90,78,.8); animation: nvAim 1s ease-in-out infinite; }
.nv-aim::after { content: ''; position: absolute; inset: -14%;
  background: linear-gradient(#ff5a4e, #ff5a4e) 50% 0 / 2px 26% no-repeat, linear-gradient(#ff5a4e, #ff5a4e) 50% 100% / 2px 26% no-repeat,
              linear-gradient(#ff5a4e, #ff5a4e) 0 50% / 26% 2px no-repeat, linear-gradient(#ff5a4e, #ff5a4e) 100% 50% / 26% 2px no-repeat; }
.nv-aim i { position: absolute; left: 50%; top: 50%; width: 5px; height: 5px; margin: -2.5px; border-radius: 50%; background: #ffd0c8; box-shadow: 0 0 6px #ff5a4e; }
@keyframes nvAim { 50% { transform: scale(.82); } }
/* the square fired at, until the shell lands: four corners close in and lock, a red pulse, a light sweeping round */
.nv-lock { position: absolute; z-index: 7; width: 10%; height: 10%; pointer-events: none; }
.nv-lock b { position: absolute; width: 34%; height: 34%; border: 2.5px solid #ff4d3d; filter: drop-shadow(0 0 4px rgba(255,77,61,.9)); animation: nvLockIn .32s cubic-bezier(.3,1.5,.5,1) both; }
.nv-lock .c1 { left: 0; top: 0; border-right: 0; border-bottom: 0; border-top-left-radius: 4px; --fx: -60%; --fy: -60%; }
.nv-lock .c2 { right: 0; top: 0; border-left: 0; border-bottom: 0; border-top-right-radius: 4px; --fx: 60%; --fy: -60%; }
.nv-lock .c3 { left: 0; bottom: 0; border-right: 0; border-top: 0; border-bottom-left-radius: 4px; --fx: -60%; --fy: 60%; }
.nv-lock .c4 { right: 0; bottom: 0; border-left: 0; border-top: 0; border-bottom-right-radius: 4px; --fx: 60%; --fy: 60%; }
@keyframes nvLockIn { from { transform: translate(var(--fx), var(--fy)); opacity: 0; } }
.nv-lock .p { position: absolute; inset: 0; border-radius: 4px; background: radial-gradient(circle, rgba(255,77,61,.55), rgba(255,77,61,.12) 60%, transparent 72%);
  animation: nvLockP .55s ease-in-out .3s infinite alternate; }
@keyframes nvLockP { from { opacity: .35; transform: scale(.7); } to { opacity: 1; transform: scale(1.05); } }
.nv-lock .sw { position: absolute; inset: 8%; border-radius: 50%; background: conic-gradient(from 0deg, rgba(255,140,120,.75), transparent 30%);
  -webkit-mask: radial-gradient(circle, transparent 38%, #000 40%); mask: radial-gradient(circle, transparent 38%, #000 40%); animation: nvLockSw .7s linear infinite; }
@keyframes nvLockSw { to { transform: rotate(360deg); } }
.nv-lock .dot { position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: #fff; box-shadow: 0 0 6px #fff, 0 0 12px #ff4d3d;
  animation: nvLockD .4s ease-in-out infinite alternate; }
@keyframes nvLockD { to { transform: scale(1.6); } }
@media (prefers-reduced-motion: reduce) { .nv-lock b, .nv-lock .p, .nv-lock .sw, .nv-lock .dot { animation: none; } }

/* ---------- placing the fleet: the ships still to place, where a ship would go, the buttons ---------- */
.nv-box.placing .nv-sea.me .nv-ship { pointer-events: auto; cursor: grab; }
.nv-box.placing .nv-sea.me .nv-ship.last .nv-shipsvg { filter: drop-shadow(0 0 6px rgba(255,216,102,.85)); }
.nv-box.locked .nv-sea.me .nv-ship { pointer-events: none; cursor: default; }
.nv-ghost { position: absolute; z-index: 3; border-radius: 6px; pointer-events: none; background: rgba(125,255,168,.22); box-shadow: inset 0 0 0 2px #7dffa8, 0 0 16px rgba(125,255,168,.55); }
.nv-ghost.bad { background: rgba(255,77,94,.24); box-shadow: inset 0 0 0 2px #ff4d5e, 0 0 16px rgba(255,77,94,.6); }
.nv-ghost.hidden { display: none; }
.nv-drag { position: fixed; z-index: 90; pointer-events: none; opacity: .92; filter: drop-shadow(0 14px 16px rgba(0,0,0,.6)); }
.nv-drag .nv-shipsvg { width: 100%; height: 100%; }
.nv-place { display: flex; flex-direction: column; gap: 10px; width: 236px; min-width: 0; }
.nv-place.hidden { display: none; }
.nv-place-h { display: flex; flex-direction: column; gap: 3px; }
.nv-place-h b { font-size: 15px; font-weight: 900; }
.nv-place-h small { font-size: 12px; color: var(--muted); line-height: 1.35; }
.nv-tray { display: flex; flex-direction: column; gap: 7px; }
.nv-tr { position: relative; display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 14px; cursor: grab; text-align: left; color: var(--text); touch-action: none;
  background: linear-gradient(160deg, rgba(30,25,72,.85), rgba(18,15,46,.82)); border: 1px solid var(--stroke); transition: border-color .2s, opacity .2s, transform .15s; }
.nv-tr:hover { border-color: rgba(255,255,255,.35); transform: translateX(2px); }
.nv-tr.sel { border-color: #ffd866; box-shadow: 0 0 0 1px #ffd866, 0 0 18px -4px rgba(255,216,102,.7); }
.nv-tr.placed { opacity: .5; }
.nv-tr:disabled { cursor: default; opacity: .4; }
.nv-tr-ship { flex: none; width: calc(var(--n) * 17px); height: 17px; }
.nv-tr-ship .nv-shipsvg { width: 100%; height: 100%; }
.nv-tr-t { display: flex; flex-direction: column; min-width: 0; }
.nv-tr-t b { font-size: 12.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nv-tr-t small { font-size: 11px; color: var(--muted); }
.nv-tr-ok { position: absolute; right: 10px; font-style: normal; font-weight: 900; color: #7dffa8; }
.nv-place-bar { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; }
.nv-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 38px; padding: 0 12px; border-radius: 12px; cursor: pointer;
  font: 800 12.5px 'Inter', system-ui, sans-serif; color: #f1ecff; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.18); transition: background .2s, border-color .2s; }
.nv-btn:hover { background: rgba(255,255,255,.14); }
.nv-btn.on { border-color: #ffd866; color: #ffe7a3; background: rgba(255,216,102,.12); }
.nv-btn svg.i { width: 16px; height: 16px; flex: none; }
.nv-btn.hidden { display: none; }
.nv-btn.ready { grid-column: 1 / -1; min-height: 46px; font-size: 14px; letter-spacing: .5px; text-transform: uppercase; }
.nv-btn.ready.go { color: #2a1800; border: 0; background: linear-gradient(180deg, #fff1b8, #ffd866 40%, #e5a92e); box-shadow: inset 0 2px 0 rgba(255,255,255,.6), 0 4px 0 #7a4c10, 0 12px 20px -10px rgba(0,0,0,.8); }
.nv-btn.ready:disabled { opacity: .45; cursor: default; }
.nv-btn.fire { width: 100%; min-height: 46px; margin-top: 10px; color: #fff; border: 0; font-size: 14px; letter-spacing: .6px; text-transform: uppercase;
  background: linear-gradient(180deg, #ff8a7a, #e8382a 45%, #a81d14); box-shadow: inset 0 2px 0 rgba(255,255,255,.35), 0 4px 0 #5e0d07, 0 12px 20px -10px rgba(0,0,0,.8); }

/* ---------- the table: the seas on the left (the most room), one column on the right, nothing scrolls ---------- */
html:has(body.game-naumachia[data-page="table"]) { overflow: hidden; }
body.game-naumachia[data-page="table"] .site-foot { display: none; }
body.game-naumachia[data-page="table"] #table.page { max-width: none; height: calc(100dvh - var(--top)); box-sizing: border-box; overflow: hidden; padding: 10px 14px; }
body.game-naumachia[data-page="table"] .chat-fab { display: none !important; }
/* on top only the seas; under them one panel with everything else */
.nv-wrap { display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto auto; grid-template-areas: "box" "deck"; align-content: start;
  gap: 10px; height: 100%; }
.nv-tools { display: flex; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 8px; }
.nv-tool { position: relative; display: inline-flex; align-items: center; justify-content: center; gap: 7px; width: 40px; height: 40px; padding: 0; flex: none;
  border-radius: 13px; cursor: pointer; color: #f1ecff; font: 800 13px 'Inter', system-ui, sans-serif;
  background: linear-gradient(180deg, rgba(255,255,255,.13), rgba(255,255,255,.04)), linear-gradient(160deg, rgba(36,30,84,.95), rgba(18,15,46,.95));
  border: 1px solid rgba(255,255,255,.16); box-shadow: inset 0 1px 0 rgba(255,255,255,.14), 0 8px 18px -10px rgba(0,0,0,.9); transition: border-color .2s, transform .15s; }
.nv-tool:hover { border-color: rgba(255,216,102,.55); }
.nv-tool:active { transform: translateY(1px) scale(.97); }
.nv-tool svg.i { width: 18px; height: 18px; flex: none; }
.nv-tool.wide { width: auto; padding: 0 15px; }
.nv-tool.hidden { display: none; }
.nv-tool > b { position: absolute; top: -6px; right: -6px; min-width: 19px; height: 19px; padding: 0 5px; box-sizing: border-box; border-radius: 10px; display: grid; place-items: center;
  font-size: 11px; font-weight: 900; color: #fff; background: #ff4d6d; box-shadow: 0 0 0 2px #15123a; }
.nv-tool > b.hidden { display: none; }
.nv-mute .tv-snd-off { display: none; }
body.tv-muted .nv-mute .tv-snd-off { display: inline; } body.tv-muted .nv-mute .tv-snd-on { display: none; }
.nv-box { grid-area: box; position: relative; display: flex; align-items: flex-start; justify-content: center; min-width: 0; min-height: 0; overflow: hidden; }
.nv-seas { display: flex; align-items: flex-start; justify-content: center; gap: var(--gap, 22px); }
/* the panel: you (under your sea), your move and the time, the other (under theirs), the buttons */
.nv-deck { grid-area: deck; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr) minmax(0, 1fr) auto; align-items: center; gap: 10px;
  padding: 10px; border-radius: 22px; min-width: 0;
  background: linear-gradient(180deg, rgba(255,255,255,.06), rgba(255,255,255,0) 40%), linear-gradient(160deg, rgba(30,25,72,.92), rgba(14,12,38,.94));
  border: 1px solid rgba(255,255,255,.14); box-shadow: inset 0 1px 0 rgba(255,255,255,.1), 0 -2px 0 rgba(95,209,240,.08), 0 18px 34px -18px rgba(0,0,0,.9); }
.nv-deck .nv-tools { flex-wrap: nowrap; }
.nv-pl { position: relative; display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 18px; min-width: 0;
  background: linear-gradient(160deg, rgba(30,25,72,.85), rgba(18,15,46,.82)); border: 1px solid var(--stroke); transition: border-color .3s, box-shadow .3s; }
.nv-pl.turn { border-color: rgba(255,216,102,.55); box-shadow: 0 0 0 3px rgba(255,216,102,.1), 0 16px 30px -18px rgba(255,216,102,.5); }
.nv-av { position: relative; width: 46px; height: 46px; flex: none; border-radius: 50%; padding: 3px; box-sizing: border-box; }
.nv-ring { position: absolute; inset: 0; border-radius: 50%; background: rgba(255,255,255,.14); }
.nv-pl.turn .nv-ring { background: conic-gradient(#ffd866 calc(var(--k, 1) * 360deg), rgba(255,255,255,.12) 0); }
.nv-avi { position: relative; display: grid; place-items: center; width: 100%; height: 100%; border-radius: 50%; overflow: hidden; color: #fff; font-weight: 900; font-size: 17px;
  background: radial-gradient(circle at 35% 28%, rgba(255,255,255,.5), transparent 42%), var(--bg); box-shadow: 0 0 0 2px #17153a; }
.nv-avi svg.i { width: 22px; height: 22px; } .nv-avi .ava-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.nv-pn { display: flex; flex-direction: column; gap: 3px; min-width: 0; width: 100%; }
.nv-pn b { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nv-pn small { font-size: 11.5px; color: var(--muted); font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* each player's fleet: a bar for every ship, struck out once sunk */
.nv-fl { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.nv-fl i { position: relative; display: block; width: calc(var(--n) * 8px); height: 7px; border-radius: 4px 7px 7px 4px; background: linear-gradient(180deg, #b7c3cf, #6d7884); }
.nv-fl i.sunk { background: linear-gradient(180deg, #6b3a2e, #3a1c16); }
.nv-fl i.sunk::after { content: ''; position: absolute; left: -2px; right: -2px; top: 50%; height: 2px; margin-top: -1px; background: #ff5a4e; transform: rotate(-12deg); }
.nv-dock { display: block; margin: 0; padding: 14px 14px 12px; min-width: 0; overflow: hidden; }
.nv-dock .turnlbl { flex-direction: column; gap: 3px; margin-bottom: 10px; }
.nv-dock .turnlbl b { white-space: normal; line-height: 1.3; overflow-wrap: anywhere; }
.nv-dock .turnlbl span { text-align: left; color: #ffd38a; }
.nv-dock.my-turn { border-color: rgba(255,216,102,.5); }
.nv-panel.nv-logp { flex: 1; min-height: 0; display: flex; flex-direction: column; }
.nv-logp .log21 { flex: 1; min-height: 0; max-height: none; }
.nv-foot { display: flex; }
.nv-foot .nv-leave { flex: 1; min-width: 0; height: auto; min-height: 42px; padding: 8px 12px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; white-space: normal; text-align: center; line-height: 1.2; font-size: 12.5px; }
.nv-foot .nv-leave svg.i { flex: none; width: 16px; height: 16px; }
/* the message, whose turn, the end */
.nv-box > .nv-banner { position: absolute; left: 50%; top: 2px; z-index: 30; transform: translateX(-50%); width: max-content; max-width: min(92%, 560px);
  padding: 6px 16px; border-radius: 999px; font-size: 13.5px; font-weight: 800; line-height: 1.3; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  background: rgba(8,10,18,.78); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); border: 1px solid rgba(255,216,102,.35);
  box-shadow: 0 6px 16px -6px rgba(0,0,0,.8); animation: nvBanIn .35s ease-out; pointer-events: none; }
.nv-box > .nv-banner.blank { display: none; }
.nv-box > .nv-banner.good { border-color: rgba(125,255,168,.55); } .nv-box > .nv-banner.bad { border-color: rgba(255,90,78,.6); }
.nv-box > .nv-banner.gold { border-color: rgba(255,216,102,.7); color: #ffe7a3; }
@keyframes nvBanIn { from { opacity: 0; transform: translate(-50%, -8px); } }
.nv-turn { position: absolute; left: 50%; bottom: 2px; z-index: 20; transform: translateX(-50%); display: flex; align-items: baseline; gap: 8px; padding: 5px 14px; border-radius: 999px;
  font-size: 12.5px; font-weight: 800; background: rgba(8,10,18,.7); border: 1px solid rgba(255,255,255,.14); pointer-events: none; white-space: nowrap; }
.nv-turn.me { border-color: rgba(255,216,102,.55); color: #ffe7a3; }
.nv-turn.low small { color: #ff8b95; }
.nv-turn.hidden { display: none; }
.nv-box > .paused21 { z-index: 25; }
.nv-end { position: absolute; inset: 0; z-index: 40; display: grid; place-items: center; padding: 16px; background: rgba(4,8,20,.5); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); }
.nv-end.hidden { display: none; }
.nv-end-in { position: relative; width: min(440px, 100%); padding: 34px 20px 18px; border-radius: 24px; text-align: center; color: #fff;
  background: linear-gradient(170deg, rgba(34,30,78,.97), rgba(16,14,40,.97)); border: 1px solid rgba(255,255,255,.14); box-shadow: 0 30px 70px -20px rgba(0,0,0,.95);
  animation: nvBox .45s cubic-bezier(.3,1.3,.5,1); }
.nv-end-in.won { border-color: rgba(255,216,102,.6); }
@keyframes nvBox { from { transform: translateY(20px) scale(.94); opacity: 0; } }
.nv-end .he-hero { position: relative; display: inline-grid; place-items: center; width: 66px; height: 66px; border-radius: 50%; background: var(--bg); box-shadow: 0 0 0 3px #ffd866, 0 0 26px rgba(255,216,102,.5); }
.nv-end .he-hav { display: grid; place-items: center; width: 100%; height: 100%; border-radius: 50%; overflow: hidden; color: #fff; font-weight: 900; font-size: 24px; }
.nv-end .he-hav svg.i { width: 30px; height: 30px; } .nv-end .he-hav .ava-img { width: 100%; height: 100%; object-fit: cover; }
.nv-end .he-crown { position: absolute; left: 50%; top: -24px; width: 36px; transform: translateX(-50%) rotate(-8deg); }
.nv-end .he-crown svg { display: block; width: 100%; }
.nv-end h3 { margin: 12px 0 4px; font-size: 21px; font-weight: 900; }
.nv-why { margin: 0 0 12px; font-size: 13px; color: var(--muted); }
.nv-end-tab { display: grid; gap: 6px; }
.nv-end-row { display: grid; grid-template-columns: minmax(0, 1fr) auto auto auto; gap: 10px; align-items: center; padding: 8px 12px; border-radius: 12px; background: rgba(255,255,255,.05);
  font-size: 12.5px; text-align: left; }
.nv-end-row span { font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nv-end-row em { font-style: normal; color: var(--muted); white-space: nowrap; }
.nv-end-row b { color: #ffd866; font-variant-numeric: tabular-nums; }
.nv-end-row.win { box-shadow: inset 0 0 0 1px rgba(255,216,102,.5); }

/* ---------- home: a corner of the sea, the look, the fleet ---------- */
.logo-nv { position: relative; width: 36px; height: 36px; flex: none; }
.logo-nv svg { width: 36px; height: 36px; display: block; filter: drop-shadow(0 3px 5px rgba(0,0,0,.45)); }
.hero-nv .nv-art { position: relative; display: flex; justify-content: center; align-items: center; padding: 6px 0 12px; }
.nv-mini { position: relative; width: min(300px, 92%); aspect-ratio: 300 / 150; border-radius: 14px; overflow: hidden; isolation: isolate;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.12), 0 18px 30px -12px rgba(0,0,0,.8); }
.nv-mini .nv-lines { background-size: 5% 100%, 100% 10%; }
.nv-mini .nv-ship { z-index: 2; }
.nv-mini .nv-mk { width: 8%; height: 16%; }
.nv-mini .nv-mk.h { width: 9%; height: 18%; }
.nv-artfx { position: absolute; z-index: 5; width: 10%; height: 20%; border-radius: 50%; pointer-events: none; }
.nv-artfx.s { left: 62%; top: 62%; border: 2px solid var(--foam); animation: nvArtRing 3.6s ease-out infinite; }
.nv-artfx.b { left: 22%; top: 18%; background: radial-gradient(circle, #fff3b0 0 15%, #ffb02e 35%, #f0521a 55%, rgba(120,20,10,0) 75%); animation: nvArtBoom 3.6s ease-out 1.8s infinite; opacity: 0; }
@keyframes nvArtRing { 0%, 55% { transform: scale(.2); opacity: 0; } 60% { opacity: .9; } 100% { transform: scale(2.4); opacity: 0; } }
@keyframes nvArtBoom { 0%, 70% { transform: scale(.2); opacity: 0; } 76% { transform: scale(1.4); opacity: 1; } 100% { transform: scale(2); opacity: 0; } }
.nv-fleet { display: grid; grid-template-columns: 1fr 1fr; }
.nv-fleet button { font-size: 13px; font-weight: 900; }
.nv-mylook { display: flex; align-items: center; gap: 12px; width: 100%; padding: 10px 12px; border-radius: 16px; cursor: pointer; text-align: left; color: var(--text);
  background: rgba(255,255,255,.04); border: 1px solid var(--stroke); transition: background .2s, border-color .2s; }
.nv-mylook:hover { background: rgba(255,255,255,.07); border-color: rgba(255,216,102,.4); }
.nv-mylook > svg.i { width: 18px; height: 18px; color: var(--muted); flex: none; }
.nv-ml-t { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.nv-ml-t b { font-size: 14px; } .nv-ml-t small { font-size: 12px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nv-ml-prev, .nv-lk-prev { position: relative; flex: none; display: grid; place-items: center; width: 74px; height: 50px; border-radius: 10px; overflow: hidden; isolation: isolate;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.18), 0 6px 12px -6px rgba(0,0,0,.8); }
.nv-ml-ship { position: relative; z-index: 2; width: 54px; height: 22px; }
.nv-ml-ship .nv-shipsvg { width: 100%; height: 100%; }
.nv-lk-prev .nv-lines { background-size: 12.5% 100%, 100% 25%; }
.nv-modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 16px; background: rgba(4,3,14,.6); animation: fade .2s; }
.nv-modal.hidden { display: none; }
.nv-lk-box { width: min(520px, 100%); max-height: 90dvh; overflow-x: hidden; overflow-y: auto; box-sizing: border-box; padding: 20px; border-radius: 24px;
  background: linear-gradient(165deg, rgba(42,31,100,.98), rgba(17,13,44,.98)); border: 1px solid rgba(255,255,255,.14); box-shadow: 0 30px 80px -20px rgba(0,0,0,.9); }
.nv-lk-box h3 { margin: 0 0 4px; font-size: 19px; font-weight: 900; }
.nv-lk-note { margin: 0 0 12px; font-size: 12.5px; color: var(--muted); line-height: 1.4; }
.nv-lk-h { margin: 12px 0 8px; font-size: 11px; font-weight: 900; letter-spacing: 1.2px; text-transform: uppercase; color: var(--muted); }
.nv-lk-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(140px, 100%), 1fr)); gap: 8px; min-width: 0; }
.nv-lk { display: flex; flex-direction: column; align-items: center; gap: 7px; min-width: 0; overflow: hidden; padding: 9px 8px; border-radius: 14px; cursor: pointer; color: var(--text);
  font: 700 12.5px 'Inter', system-ui, sans-serif; text-align: center; background: rgba(255,255,255,.04); border: 1px solid var(--stroke); }
.nv-lk > span:last-child { width: 100%; line-height: 1.25; overflow-wrap: anywhere; hyphens: auto; }
.nv-lk .nv-lk-prev { width: 100%; height: 64px; }
.nv-lk.on { border-color: #ffd866; background: rgba(255,216,102,.1); box-shadow: 0 0 0 1px #ffd866 inset; }
.nv-lk-acts { display: flex; justify-content: flex-end; margin-top: 14px; }

/* ---------- the panel's parts; smaller screens ---------- */
.nv-deck > .nv-pl.me { grid-area: me; } .nv-deck > #nvOpp { grid-area: opp; } .nv-deck > .nv-dock, .nv-deck > .nv-result { grid-area: dock; }
.nv-deck > .nv-tools { grid-area: tools; }
.nv-deck { grid-template-areas: "me dock opp tools"; }
.nv-deck .nv-dock { margin: 0; padding: 9px 14px; border-radius: 16px; }
.nv-deck .nv-dock .turnlbl { flex-direction: row; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 2px 10px; margin-bottom: 7px; }
.nv-deck .nv-btn.fire { margin-top: 8px; min-height: 40px; }
.nv-deck:has(.nv-result:not(.hidden)) .nv-dock { display: none; }
.nv-place-bar { display: grid; grid-template-columns: auto auto auto minmax(0, 1fr); gap: 6px; margin-top: 8px; }
.nv-place-bar.hidden { display: none; }
.nv-place-bar .nv-btn.ready { grid-column: auto; min-height: 38px; font-size: 13px; }
@media (max-width: 1500px) { .nv-place-bar .nv-btn:not(.ready) span { display: none; } .nv-place-bar .nv-btn:not(.ready) { padding: 0 11px; } }
.nv-leave svg.i { transform: none; }
.nv-tool.nv-leave:hover { border-color: rgba(255,90,78,.6); color: #ffb3ab; }
/* the result: one card in the panel, in the place of your move */
.nv-result .nv-end-in { display: grid; grid-template-columns: auto minmax(0, 1fr); grid-template-areas: "hero h" "hero why" "tab tab"; gap: 2px 12px; align-items: center;
  width: auto; padding: 10px 12px; border-radius: 16px; text-align: left; }
.nv-result .he-hero { grid-area: hero; width: 44px; height: 44px; margin-top: 12px; }
.nv-result .he-crown { top: -17px; width: 26px; }
.nv-result h3 { grid-area: h; margin: 0; font-size: 15px; }
.nv-result .nv-why { grid-area: why; margin: 0; }
.nv-result .nv-end-tab { grid-area: tab; margin-top: 8px; grid-template-columns: 1fr 1fr; }
/* your fleet while placing: in the other's place, the size of a sea */
.nv-box.placing .nv-place { width: calc(var(--s1) + 40px); max-height: calc(var(--s1) + 54px); overflow-y: auto; overscroll-behavior: contain; padding-right: 2px; }
.nv-box > .nv-banner { top: auto; bottom: 6px; }
.nv-box > .nv-turn { display: none !important; }
/* a narrow window: you and the other side by side, your move under you both, the buttons under that */
@media (max-width: 760px) and (min-height: 521px) {
  .nv-deck { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); grid-template-areas: "me opp" "dock dock" "tools tools"; }
  .nv-deck .nv-tools { justify-content: center; }
}
/* a phone sideways: the seas on top as large as they fit, a thin panel under them */
@media (orientation: landscape) and (max-height: 520px) {
  body.game-naumachia[data-page="table"] .top, body.game-naumachia[data-page="table"] .site-foot { display: none; }
  body.game-naumachia[data-page="table"] #table.page { height: 100dvh; margin: 0; padding: max(4px, env(safe-area-inset-top)) max(6px, env(safe-area-inset-right)) max(4px, env(safe-area-inset-bottom)) max(6px, env(safe-area-inset-left)); }
  .nv-wrap { gap: 5px; }
  .nv-sea-name { display: none; }
  .nv-sea { gap: 0; }
  .nv-frame { padding: 4px 6px 6px 3px; grid-template-columns: 15px var(--sz); grid-template-rows: 15px var(--sz); gap: 2px; border-radius: 11px; }
  .nv-deck { gap: 6px; padding: 5px 6px; border-radius: 14px; }
  .nv-tool { width: 30px; height: 30px; border-radius: 10px; } .nv-tool.wide { padding: 0 9px; font-size: 11px; } .nv-tool svg.i { width: 15px; height: 15px; }
  .nv-deck .nv-tools { gap: 5px; }
  .nv-pl { padding: 4px 7px; gap: 6px; border-radius: 12px; } .nv-av { width: 26px; height: 26px; padding: 2px; }
  .nv-pn { gap: 1px; } .nv-pn b { font-size: 11px; } .nv-pn small { font-size: 9.5px; }
  .nv-fls { width: calc(var(--n) * 8px); height: 8px; } .nv-fl { gap: 2px 4px; margin-top: 1px; }
  .nv-deck .nv-dock { padding: 4px 9px; border-radius: 12px; }
  .nv-deck .nv-dock .turnlbl { font-size: 11px; margin-bottom: 3px; }
  .nv-deck .nv-dock .turnlbl b { font-size: 11.5px; }
  .nv-deck .nv-btn.fire { margin-top: 4px; min-height: 30px; font-size: 12px; }
  .nv-place-bar { gap: 4px; margin-top: 4px; }
  .nv-place-bar .nv-btn { min-height: 30px; padding: 0 8px; border-radius: 10px; }
  .nv-place-bar .nv-btn:not(.ready) span { display: none; }
  .nv-place-bar .nv-btn.ready { min-height: 30px; font-size: 11.5px; }
  .nv-box.placing .nv-place { width: calc(var(--s1) + 24px); max-height: calc(var(--s1) + 25px); gap: 5px; }
  .nv-place-h b { font-size: 12px; } .nv-place-h small { font-size: 10px; }
  .nv-tray { gap: 4px; } .nv-tr { padding: 3px 7px; gap: 7px; border-radius: 10px; } .nv-tr-ship { width: calc(var(--n) * 12px); height: 12px; }
  .nv-tr-t b { font-size: 11px; } .nv-tr-t small { font-size: 9.5px; }
  .nv-result .nv-end-in { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); grid-template-areas: "h tab" "why tab"; padding: 5px 9px; gap: 1px 8px; border-radius: 12px; }
  .nv-result .he-hero { display: none; }
  .nv-result h3 { font-size: 12.5px; } .nv-result .nv-why { font-size: 10px; }
  .nv-result .nv-end-tab { margin: 0; grid-template-columns: 1fr; gap: 3px; }
  .nv-result .nv-end-row { padding: 2px 7px; font-size: 10px; gap: 6px; border-radius: 8px; }
  .nv-box > .nv-banner { font-size: 11.5px; padding: 4px 12px; }
}
/* full screen: the table on one screen, nothing scrolls */
body.game-fs .nv-wrap { height: 100%; }
/* ================= (2026-10) a truer sea, fire and smoke, a churned-water mark for a miss, a sunk ship that burns
   out low in the water, the hover on the enemy's sea, the ships in the column, the result beside the seas ================= */
/* the sea: deep colour and the sky's light; fine ripples and a slow play of light over it — slow, never dizzying */
.nv-water { animation: none;
  background: radial-gradient(130% 90% at 72% -12%, var(--sky), transparent 60%), radial-gradient(100% 80% at 10% 110%, var(--sky2), transparent 60%),
    linear-gradient(170deg, var(--w1), var(--w2) 55%, var(--w3)); }
/* (the ripples and the light drift as whole layers, bigger than the sea by one tile, moved — not their background redrawn
   in a new place every frame, which drew the whole sea again each time) */
.nv-water { overflow: hidden; }
.nv-water::before { inset: -120px 0 0 -240px; opacity: .5; mix-blend-mode: soft-light; transform: none; will-change: transform;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='turbulence' baseFrequency='.03 .075' numOctaves='3' seed='11' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  2.6 0 0 0 -1.05'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E") 0 0 / 240px 240px;
  animation: nvRip 70s linear infinite; }
.nv-water::after { inset: -260px -520px 0 0; opacity: .32; mix-blend-mode: screen; transform: none; will-change: transform;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='520' height='520'%3E%3Cfilter id='f'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.011' numOctaves='3' seed='4' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  3.6 0 0 0 -2.05'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23f)'/%3E%3C/svg%3E") 0 0 / 520px 520px;
  animation: nvLight 160s linear infinite; }
@keyframes nvRip { from { transform: translate(0, 0); } to { transform: translate(240px, 120px); } }
@keyframes nvLight { from { transform: translate(0, 0); } to { transform: translate(-520px, 260px); } }
.nvs-storm .nv-field::after { animation: nvRain .6s linear infinite, nvBolt 14s step-end infinite; opacity: .7; }
.nv-lines { background: linear-gradient(to right, rgba(255,255,255,.09) 1px, transparent 1px) 0 0 / 10% 100%, linear-gradient(to bottom, rgba(255,255,255,.09) 1px, transparent 1px) 0 0 / 100% 10%; }
/* a miss: churned water — a patch of foam and bubbles that rise and break, slowly settling (no ring) */
.nv-mk.m { width: 10.5%; height: 10.5%; filter: blur(.3px);
  background: radial-gradient(closest-side, rgba(250,253,255,.95) 0 22%, rgba(226,244,252,.62) 45%, rgba(190,228,245,.22) 72%, rgba(160,205,228,0) 100%); }
.nv-mk.m::after { inset: -45%; border: 0; border-radius: 50%; background: radial-gradient(closest-side, rgba(205,236,250,.18), rgba(205,236,250,0));
  animation: nvFoam 5s ease-in-out infinite; animation-delay: calc(var(--k) * -5s); }
@keyframes nvFoam { 50% { transform: scale(1.18); opacity: .55; } }
.nv-mk.m b { position: absolute; width: 15%; height: 15%; border-radius: 50%; background: rgba(255,255,255,.8); box-shadow: 0 0 2px rgba(255,255,255,.6);
  animation: nvBubble 2.6s ease-in infinite; opacity: 0; }
.nv-mk.m b:nth-child(1) { left: 22%; top: 40%; animation-delay: calc(var(--k) * -2.6s); }
.nv-mk.m b:nth-child(2) { left: 60%; top: 30%; width: 9%; height: 9%; animation-delay: calc(var(--k) * -2.6s - .7s); }
.nv-mk.m b:nth-child(3) { left: 48%; top: 62%; animation-delay: calc(var(--k) * -2.6s - 1.4s); }
.nv-mk.m b:nth-child(4) { left: 70%; top: 58%; width: 8%; height: 8%; animation-delay: calc(var(--k) * -2.6s - 2s); }
@keyframes nvBubble { 0% { transform: scale(.3); opacity: 0; } 30% { opacity: .9; } 80% { transform: scale(1.1); opacity: .5; } 100% { transform: scale(1.5); opacity: 0; } }
/* a hit: the glow of the fire on the water and the hull, flames that move, smoke that rises and drifts */
.nv-mk.h { width: 10%; height: 10%; box-shadow: none; animation: nvGlow 1.6s ease-in-out infinite alternate; animation-delay: calc(var(--k) * -1.6s);
  background: radial-gradient(closest-side, rgba(255,170,70,.6), rgba(255,100,30,.22) 45%, rgba(255,80,20,0) 100%); }
.nv-mk.h::before, .nv-mk.h::after { content: none; }
@keyframes nvGlow { to { opacity: .75; transform: translate(-50%, -50%) scale(1.12); } }
.nv-mk .fl { position: absolute; left: 50%; bottom: 38%; width: 42%; height: 92%; transform-origin: 50% 100%; border-radius: 50% 50% 42% 42% / 72% 72% 28% 28%;
  background: radial-gradient(ellipse at 50% 92%, #fffbe2 0 9%, #ffd84d 22%, #ff8d22 44%, rgba(228,58,14,.85) 62%, rgba(140,24,6,0) 80%);
  filter: blur(.55px); mix-blend-mode: screen; animation: nvFlame1 .46s ease-in-out infinite alternate; }
.nv-mk .fl.f2 { left: 32%; width: 32%; height: 70%; animation-duration: .38s; animation-delay: -.2s; }
.nv-mk .fl.f3 { left: 66%; width: 30%; height: 64%; animation-duration: .52s; animation-delay: -.1s; }
.nv-mk .fl.f4 { left: 50%; width: 22%; height: 110%; bottom: 46%; opacity: .7; animation-name: nvFlame2; animation-duration: .6s; }
@keyframes nvFlame1 { from { transform: translateX(-50%) scale(.82, .78) skewX(-7deg); } to { transform: translateX(-50%) scale(1.06, 1.12) skewX(6deg); } }
@keyframes nvFlame2 { from { transform: translateX(-50%) scale(.7, .9) skewX(9deg); opacity: .4; } to { transform: translateX(-50%) scale(1, 1.2) skewX(-8deg); opacity: .8; } }
.nv-mk .sm { position: absolute; left: 50%; bottom: 62%; width: 72%; height: 72%; border-radius: 50%; filter: blur(1.6px); opacity: 0;
  background: radial-gradient(closest-side, rgba(42,40,40,.62), rgba(70,66,64,.28) 55%, rgba(80,76,72,0) 100%); animation: nvSmk 3.2s linear infinite; }
.nv-mk .sm.s2 { animation-delay: -1.07s; } .nv-mk .sm.s3 { animation-delay: -2.13s; }
@keyframes nvSmk { 0% { transform: translate(-50%, 0) scale(.35); opacity: 0; } 14% { opacity: .9; } 100% { transform: translate(-10%, -280%) scale(2.7); opacity: 0; } }
/* the squares of a ship that went down: charred, a thin smoke still rising, no flames */
.nv-mk.h.dead { animation: none; background: radial-gradient(closest-side, rgba(26,20,16,.6), rgba(26,20,16,0)); }
.nv-mk.h.dead .sm { background: radial-gradient(closest-side, rgba(110,106,104,.45), rgba(110,106,104,0)); animation-duration: 4.6s; width: 54%; height: 54%; }
/* a sunk ship: burnt dark, its bow going under, an oil slick round it */
.nv-ship.wreck { opacity: 1; rotate: -2deg; }
.nv-ship.wreck .nv-shipsvg { filter: grayscale(.85) brightness(.42) sepia(.5) contrast(1.2);
  -webkit-mask-image: linear-gradient(90deg, #000 0 32%, rgba(0,0,0,.55) 72%, rgba(0,0,0,.18)); mask-image: linear-gradient(90deg, #000 0 32%, rgba(0,0,0,.55) 72%, rgba(0,0,0,.18)); }
.nv-ship.wreck::after { left: -8%; right: -8%; top: -22%; bottom: -22%; box-shadow: none; animation: none; opacity: 1;
  background: radial-gradient(ellipse closest-side, rgba(8,8,12,.6), rgba(40,30,64,.36) 45%, rgba(56,118,108,.18) 66%, rgba(0,0,0,0) 100%); }
/* the other's ships still afloat at the end: shown clear, with a red edge */
.nv-ship.shown { opacity: 1; }
.nv-ship.shown .nv-shipsvg { filter: drop-shadow(0 0 3px rgba(255,90,78,.95)) drop-shadow(0 2px 2px rgba(0,0,0,.35)); }
/* the splash: the column as it was, and the water spreading wide round it (a stone thrown into the sea) */
.nv-splash b { border-width: 1.5px; border-color: rgba(240,250,255,.85); animation-name: nvRing2; animation-duration: 1.6s; }
@keyframes nvRing2 { 0% { transform: scale(.2); opacity: .9; } 100% { transform: scale(3.6, 3); opacity: 0; } }
.nv-splash .crown { position: absolute; left: 50%; top: 50%; width: 100%; height: 100%; border-radius: 50%; transform: translate(-50%, -50%) scale(.3); opacity: 0;
  background: radial-gradient(closest-side, rgba(240,250,255,0) 42%, rgba(240,250,255,.75) 64%, rgba(240,250,255,0) 82%); animation: nvCrown 1.3s ease-out forwards; }
@keyframes nvCrown { 0% { transform: translate(-50%, -50%) scale(.3); opacity: .95; } 100% { transform: translate(-50%, -50%) scale(3.4, 2.6); opacity: 0; } }
/* the blast on a ship: more fire and debris, a ring over the water */
.nv-boom s { position: absolute; left: 50%; top: 50%; width: 70%; height: 70%; margin: -35%; border-radius: 50%; opacity: 0;
  background: radial-gradient(closest-side, #fff2b0, #ffae2e 35%, #ef4f17 60%, rgba(90,20,10,0)); animation: nvPuffFire 1.1s ease-out forwards; }
@keyframes nvPuffFire { 0% { transform: translate(0, 0) scale(.3); opacity: 1; } 40% { opacity: 1; } 100% { transform: translate(var(--px), var(--py)) scale(calc(2.2 * var(--k))); opacity: 0; filter: brightness(.4); } }
.nv-boom u { position: absolute; left: 50%; top: 50%; width: 5px; height: 3px; margin: -1.5px -2.5px; background: #1c1712; border-radius: 1px; opacity: 0;
  animation: nvDebris var(--t) cubic-bezier(.2,.6,.4,1) forwards; }
@keyframes nvDebris { 0% { transform: rotate(var(--a)) translate(0) rotate(0); opacity: 1; } 100% { transform: rotate(var(--a)) translate(var(--d)) rotate(540deg); opacity: 0; } }
/* the mouse over the other's sea: the square lights up (gold when you can fire there) */
.nv-hov { position: absolute; z-index: 5; width: 10%; height: 10%; border-radius: 4px; pointer-events: none;
  background: rgba(255,255,255,.07); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.45), inset 0 0 12px rgba(255,255,255,.18); }
.nv-hov.live { background: rgba(255,216,102,.14); box-shadow: inset 0 0 0 2px #ffd866, inset 0 0 16px rgba(255,216,102,.4), 0 0 14px rgba(255,216,102,.45); }
.nv-hov.done { background: rgba(0,0,0,.12); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.2); }
.nv-hov.hidden { display: none; }
/* each player's fleet in the column: the ships themselves, small; a sunk one burnt, its bow under */
.nv-fl { gap: 3px 6px; margin-top: 2px; }
.nv-fls { position: relative; display: block; width: calc(var(--n) * 11px); height: 11px; }
.nv-fls .nv-shipsvg { width: 100%; height: 100%; filter: drop-shadow(0 1px 1px rgba(0,0,0,.5)); }
.nv-fls.sunk .nv-shipsvg { filter: grayscale(.9) brightness(.38) sepia(.5); -webkit-mask-image: linear-gradient(90deg, #000 30%, rgba(0,0,0,.25)); mask-image: linear-gradient(90deg, #000 30%, rgba(0,0,0,.25)); }
/* the result: a card in the column (the seas stay free to see) */
.nv-result.hidden { display: none; }
.nv-result .nv-end-row { grid-template-columns: minmax(0, 1fr) auto auto; font-size: 11.5px; padding: 6px 9px; }
.nv-result .nv-end-row em:nth-of-type(1) { display: none; }
.nv-result { min-width: 0; }
.nv-result .he-hero { position: relative; display: inline-grid; place-items: center; border-radius: 50%; background: var(--bg); box-shadow: 0 0 0 3px #ffd866, 0 0 22px rgba(255,216,102,.5); }
.nv-result .he-hav { display: grid; place-items: center; width: 100%; height: 100%; border-radius: 50%; overflow: hidden; color: #fff; font-weight: 900; font-size: 18px; }
.nv-result .he-hav svg.i { width: 22px; height: 22px; } .nv-result .he-hav .ava-img { width: 100%; height: 100%; object-fit: cover; }
.nv-result .he-crown { position: absolute; left: 50%; transform: translateX(-50%) rotate(-8deg); }
.nv-result .he-crown svg { display: block; width: 100%; }
.nv-result h3 { font-weight: 900; line-height: 1.2; }
.nv-result .nv-why { font-size: 12px; }
/* phones held upright: turn the phone (both seas fit only sideways) */
.nv-rotate { display: none; position: fixed; inset: 0; z-index: 90; place-items: center; padding: 24px; background: rgba(8,7,26,.94); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); }
.nv-rotate .tv-rot-box { display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; max-width: 320px; }
.nv-rotate .tv-rot-box b { font-size: 20px; font-weight: 900; }
.nv-rotate .tv-rot-box span { color: var(--muted); font-size: 14px; line-height: 1.5; }
.nv-rotate .tv-rot-phone { width: 64px; height: 104px; border-radius: 14px; border: 4px solid #d8d4f0; position: relative; margin-bottom: 8px; animation: nvTurnPh 2.4s ease-in-out infinite; }
.nv-rotate .tv-rot-phone i { position: absolute; left: 50%; bottom: 6px; width: 16px; height: 4px; margin-left: -8px; border-radius: 3px; background: #d8d4f0; }
.nv-rotate .tv-rot-phone::before { content: ''; position: absolute; inset: 10px 6px 16px; border-radius: 4px; background: linear-gradient(160deg, #1c86ad, #062f4f); }
@keyframes nvTurnPh { 0%, 20% { transform: rotate(0); } 55%, 80% { transform: rotate(-90deg); } 100% { transform: rotate(0); } }
@media (orientation: portrait) and (max-width: 820px) and (pointer: coarse) { body.game-naumachia[data-page="table"] .nv-rotate { display: grid; } }
@media (prefers-reduced-motion: reduce) {
  .nv-mk .fl, .nv-mk .sm, .nv-mk.m b, .nv-mk.m::after, .nv-mk.h, .nv-rotate .tv-rot-phone { animation: none !important; }
  .nv-mk .sm { opacity: .5; }
}
/* home: the little sea */
.nv-mini .nv-mk.m { width: 9%; height: 18%; } .nv-mini .nv-mk.h { width: 9%; height: 18%; }
.nv-mini .nv-splash, .nv-mini .nv-boom { width: 9%; height: 18%; }
.nv-mini .nv-splash.loop b, .nv-mini .nv-splash.loop .col, .nv-mini .nv-splash.loop .crown { animation-iteration-count: infinite; animation-duration: 4s; }
.nv-mini .nv-boom.loop b, .nv-mini .nv-boom.loop s, .nv-mini .nv-boom.loop em { animation-iteration-count: infinite; animation-duration: 4s; animation-delay: 2s; }
.nv-wake { position: absolute; z-index: 1; pointer-events: none; border-radius: 50%; filter: blur(1.5px);
  background: radial-gradient(ellipse at 100% 50%, rgba(240,250,255,.55), rgba(240,250,255,.18) 45%, rgba(240,250,255,0) 72%); animation: nvWakeA 3s ease-in-out infinite; }
@keyframes nvWakeA { 50% { opacity: .6; transform: scaleX(1.12); } }
/* ================= (2026-10, b) moving a ship with a finger; what to do while placing; a miss that shows on any sea;
   a fire burning on the deck (seen from above, blown by the wind), not out of the water ================= */
/* (a finger on a ship drags it, the page does not take it for a scroll) */
.nv-box.placing .nv-sea.me .nv-field, .nv-box.placing .nv-sea.me .nv-ship { touch-action: none; }
.nv-box.placing:not(.locked) .nv-sea.me .nv-ship:not(.last) .nv-shipsvg { filter: drop-shadow(0 0 2px rgba(255,255,255,.55)) drop-shadow(0 2px 2px rgba(0,0,0,.35)); }
.nv-deck .nv-dock.hint .turnlbl { flex-direction: column; align-items: flex-start; gap: 3px; }
.nv-deck .nv-dock.hint .turnlbl span { white-space: normal; text-align: left; line-height: 1.35; font-weight: 700; color: #ffe08a; }
/* a miss: dark churned water, lighter round it, a few bubbles — it stands out on a light sea and on a dark one */
.nv-mk.m { width: 9.5%; height: 9.5%; filter: none;
  background: radial-gradient(closest-side, rgba(3,14,30,.82) 0 34%, rgba(6,26,48,.55) 52%, rgba(120,190,220,.28) 70%, rgba(120,190,220,0) 100%); }
.nv-mk.m::after { inset: -12%; background: radial-gradient(closest-side, rgba(150,210,235,0) 60%, rgba(150,210,235,.2) 78%, rgba(150,210,235,0) 100%); }
.nv-mk.m b { width: 12%; height: 12%; background: rgba(190,235,255,.85); box-shadow: 0 0 2px rgba(190,235,255,.7); }
.nv-mini .nv-mk.m { width: 8%; height: 16%; }
/* a hit: a scorched patch on the deck with the light of the fire round it; the flames on top of it, leaning with the
   wind, a bright core; the smoke going off with the wind */
.nv-mk.h { width: 10%; height: 10%; animation: none;
  background: radial-gradient(ellipse 48% 40% at 46% 54%, rgba(18,10,6,.92), rgba(44,22,10,.62) 58%, rgba(44,22,10,0) 100%),
              radial-gradient(closest-side, rgba(255,150,50,.38), rgba(255,110,30,0)); }
.nv-mk .fl { left: 50%; top: 50%; bottom: auto; width: 34%; height: 76%; margin: -76% 0 0 -17%; transform-origin: 50% 100%; mix-blend-mode: normal; opacity: 1;
  border-radius: 50% 50% 46% 46% / 66% 66% 34% 34%; --rot: 34deg;
  background: radial-gradient(ellipse at 50% 86%, #fffbe6 0 12%, #ffe06a 27%, #ff9a2a 48%, rgba(230,70,16,.85) 66%, rgba(150,30,8,0) 84%);
  filter: blur(.35px) drop-shadow(0 0 3px rgba(255,150,40,.9)); animation: nvTongue .5s ease-in-out infinite alternate; }
.nv-mk .fl.f2 { left: 50%; width: 26%; height: 58%; margin: -58% 0 0 -13%; --rot: 8deg; animation-duration: .38s; animation-delay: -.2s; }
.nv-mk .fl.f3 { left: 50%; width: 24%; height: 50%; margin: -50% 0 0 -12%; --rot: 62deg; animation-duration: .44s; animation-delay: -.1s; }
.nv-mk .fl.f4 { left: 50%; width: 44%; height: 44%; margin: -22% 0 0 -22%; bottom: auto; border-radius: 50%; transform-origin: 50% 50%; opacity: 1;
  background: radial-gradient(closest-side, #fffef2 0 20%, #ffd84d 48%, rgba(255,120,30,.6) 72%, rgba(255,120,30,0)); animation: nvCore .3s ease-in-out infinite alternate; }
@keyframes nvTongue { from { transform: rotate(var(--rot)) scale(.84, .78) skewX(-7deg); } to { transform: rotate(calc(var(--rot) + 7deg)) scale(1.06, 1.16) skewX(6deg); } }
@keyframes nvCore { from { transform: scale(.86); opacity: .85; } to { transform: scale(1.08); opacity: 1; } }
.nv-mk .sm { left: 50%; top: 50%; bottom: auto; width: 70%; height: 70%; margin: -35% 0 0 -35%; }
@keyframes nvSmk { 0% { transform: translate(0, 0) scale(.4); opacity: 0; } 14% { opacity: .9; } 100% { transform: translate(150%, -210%) scale(2.6); opacity: 0; } }
/* ================= (2026-10, c) a real fire rising from the ship, a real blast; the panel under the seas of one fixed
   height (nothing in it changes the size of the seas) ================= */
/* the fire: flames rising from the hit, their edges torn by the moving noise, the light of it on the ship */
.nv-mk.h { overflow: visible; }
.nv-fire { position: absolute; left: -25%; width: 150%; height: 225%; bottom: 30%; overflow: visible; pointer-events: none; }
.nv-fire .glow { transform-box: fill-box; transform-origin: center; animation: nvFGlow 1.3s ease-in-out infinite alternate; animation-delay: calc(var(--k) * -1.3s); }
.nv-fire .t1, .nv-fire .t2, .nv-fire .t3 { transform-box: fill-box; transform-origin: 50% 100%; }
.nv-fire .t1 { animation: nvFT1 .7s ease-in-out infinite alternate; animation-delay: calc(var(--k) * -.7s); }
.nv-fire .t2 { animation: nvFT2 .45s ease-in-out infinite alternate; animation-delay: calc(var(--k) * -.45s); }
.nv-fire .t3 { animation: nvFT2 .3s ease-in-out infinite alternate; }
@keyframes nvFGlow { from { opacity: .7; transform: scale(.92); } to { opacity: 1; transform: scale(1.08); } }
@keyframes nvFT1 { from { transform: scale(.94, .88) skewX(-4deg); } to { transform: scale(1.04, 1.08) skewX(4deg); } }
@keyframes nvFT2 { from { transform: scale(.9, .84) skewX(5deg); } to { transform: scale(1.06, 1.12) skewX(-5deg); } }
.nv-mk.h .sm { left: 50%; top: -95%; bottom: auto; width: 80%; height: 80%; margin: -40% 0 0 -40%; filter: blur(2px); animation: nvSmk3 3.4s linear infinite; }
.nv-mk.h .sm.s2 { animation-delay: -1.13s; } .nv-mk.h .sm.s3 { animation-delay: -2.26s; }
@keyframes nvSmk3 { 0% { transform: translate(0, 30%) scale(.45); opacity: 0; } 15% { opacity: .85; } 100% { transform: translate(55%, -190%) scale(2.6); opacity: 0; } }
.nv-mk.h.dead .sm { top: 50%; }
/* the blast: a ball of fire that swells and goes to black smoke, the flash before it, a ring over the water */
.nv-boom .nv-xp { position: absolute; left: -110%; top: -110%; width: 320%; height: 320%; overflow: visible; pointer-events: none; transform: scale(var(--k)); }
.nv-xp .xp-fire { transform-box: fill-box; transform-origin: center; animation: xpFire 1.05s cubic-bezier(.2,.8,.3,1) forwards; }
.nv-xp .xp-smoke { transform-box: fill-box; transform-origin: center; opacity: 0; animation: xpSmoke 2.4s ease-out .15s forwards; }
@keyframes xpFire { 0% { transform: scale(.12); opacity: 1; } 22% { transform: scale(1); opacity: 1; } 62% { opacity: .7; } 100% { transform: translateY(-10%) scale(1.25); opacity: 0; } }
@keyframes xpSmoke { 0% { transform: scale(.4); opacity: 0; } 22% { opacity: .92; } 100% { transform: translateY(-30%) scale(1.9); opacity: 0; } }
.nv-boom .flash { inset: -45%; animation-duration: .22s; }
.nv-boom .ring { inset: -5%; border-width: 1.5px; border-color: rgba(230,240,255,.55); }
.nv-boom i { width: 3px; height: 2px; background: #ffd27a; box-shadow: 0 0 3px #ff8a2a; }
.nv-mini .nv-boom.loop .xp-fire, .nv-mini .nv-boom.loop .xp-smoke, .nv-mini .nv-boom.loop .flash, .nv-mini .nv-boom.loop .ring { animation-iteration-count: infinite; animation-duration: 4s; animation-delay: 2s; }
@media (prefers-reduced-motion: reduce) { .nv-fire *, .nv-xp *, .nv-mk.h .sm { animation: none !important; } }
/* what to do while placing: plain, in your fleet's panel */
.nv-place-h small { font-size: 13px; font-weight: 700; color: #ffe08a; line-height: 1.4; }
/* the panel: one fixed height; your move on the left of it, the placing buttons on its right */
.nv-deck { height: 92px; box-sizing: border-box; overflow: hidden; }
.nv-deck .nv-dock { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "lbl bar" "tb bar"; align-items: center; gap: 6px 10px; }
.nv-deck .nv-dock .turnlbl { grid-area: lbl; flex-direction: row; flex-wrap: nowrap; margin: 0; }
.nv-deck .nv-dock .turnlbl b, .nv-deck .nv-dock .turnlbl span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nv-deck .nv-dock .tbar { grid-area: tb; height: 10px; }
.nv-deck .nv-place-bar { grid-area: bar; margin: 0; display: flex; gap: 6px; }
.nv-deck .nv-place-bar.hidden { display: none; }
.nv-deck .nv-place-bar .nv-btn.ready { min-width: 96px; }
.nv-deck .nv-btn.fire { display: none !important; }
.nv-result .nv-end-in { grid-template-columns: auto minmax(0, 1fr) minmax(0, 1.25fr); grid-template-areas: "hero h tab" "hero why tab"; padding: 6px 12px; gap: 2px 12px; }
.nv-result .he-hero { margin-top: 10px; }
.nv-result .nv-end-tab { margin: 0; grid-template-columns: 1fr; gap: 4px; }
.nv-result .nv-end-row { padding: 4px 9px; }
@media (max-width: 760px) and (min-height: 521px) { .nv-deck { height: auto; } }
@media (orientation: landscape) and (max-height: 520px) {
  .nv-deck { height: 50px; padding: 4px 6px; grid-template-columns: minmax(0, .85fr) minmax(0, 1.6fr) minmax(0, .85fr) auto; }
  .nv-deck .nv-dock { padding: 3px 8px; gap: 3px 6px; }
  .nv-deck .nv-dock .tbar { height: 6px; }
  .nv-deck .nv-place-bar { gap: 4px; }
  .nv-deck .nv-place-bar .nv-btn { min-height: 28px; }
  .nv-deck .nv-place-bar .nv-btn.ready { min-width: 0; padding: 0 10px; }
  .nv-pl { padding: 3px 6px; }
  .nv-place-h small { font-size: 11px; }
  .nv-result .nv-end-in { grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr) minmax(0, 1.3fr); grid-template-areas: "h tab tab"; padding: 3px 8px; }
  .nv-result .nv-why, .nv-result .he-hero { display: none; }
  .nv-result .nv-end-tab { grid-template-columns: 1fr 1fr; }
}
/* ================= (2026-10, d) the fire and the blasts drawn on a canvas over each sea: the mark of a hit is only
   the scorched patch, centred on its square; the fire rises from the middle of it ================= */
.nv-cv { position: absolute; inset: 0; z-index: 4; width: 100%; height: 100%; display: block; pointer-events: none; }
.nv-mk.h { width: 9%; height: 9%;
  background: radial-gradient(closest-side, rgba(14,8,5,.92) 0 38%, rgba(34,18,9,.65) 64%, rgba(34,18,9,0) 100%); }
.nv-mk.h.dead { background: radial-gradient(closest-side, rgba(14,10,8,.85) 0 40%, rgba(30,22,18,.5) 66%, rgba(30,22,18,0) 100%); }
.nv-mini .nv-mk.h { width: 5%; height: 10%; }
.nv-boom .flash { inset: -30%; }
/* ================= (2026-10, e) a phone sideways: if the seas come out larger so, the panel's parts beside the seas —
   you and your move on the left, the other and the buttons on the right (sizeSeas decides, class nv-sidelay) ========= */
@media (orientation: landscape) and (max-height: 520px) {
  body.game-naumachia[data-page="table"] main { height: 100dvh; overflow: hidden; }
  .nv-wrap.nv-sidelay { grid-template-columns: 104px minmax(0, 1fr) 104px; grid-template-rows: auto minmax(0, 1fr); grid-template-areas: "me box opp" "dock box tools";
    column-gap: 6px; row-gap: 5px; align-content: stretch; }
  .nv-wrap.nv-sidelay .nv-box { align-self: start; }
  .nv-wrap.nv-sidelay .nv-deck { display: contents; }
  .nv-wrap.nv-sidelay .nv-deck > .nv-dock, .nv-wrap.nv-sidelay .nv-deck > .nv-result, .nv-wrap.nv-sidelay .nv-deck > .nv-tools { align-self: start; min-width: 0; }
  .nv-wrap.nv-sidelay .nv-pl { align-self: start; flex-wrap: wrap; }
  .nv-wrap.nv-sidelay .nv-deck .nv-dock { grid-template-columns: minmax(0, 1fr); grid-template-areas: "lbl" "tb" "bar"; gap: 5px; padding: 6px 7px; border-radius: 12px; }
  .nv-wrap.nv-sidelay .nv-deck .nv-dock .turnlbl { flex-direction: column; align-items: flex-start; gap: 2px; }
  .nv-wrap.nv-sidelay .nv-deck .nv-dock .turnlbl b, .nv-wrap.nv-sidelay .nv-deck .nv-dock .turnlbl span { white-space: normal; line-height: 1.25; }
  .nv-wrap.nv-sidelay .nv-deck .nv-place-bar { flex-wrap: wrap; }
  .nv-wrap.nv-sidelay .nv-deck .nv-place-bar .nv-btn { flex: 1 1 0; padding: 0; }
  .nv-wrap.nv-sidelay .nv-deck .nv-place-bar .nv-btn.ready { flex: 1 0 100%; }
  .nv-wrap.nv-sidelay .nv-deck > .nv-tools { display: flex; flex-wrap: wrap; justify-content: center; gap: 5px; padding: 6px; border-radius: 12px;
    background: linear-gradient(160deg, rgba(30,25,72,.92), rgba(14,12,38,.94)); border: 1px solid rgba(255,255,255,.14); }
  .nv-wrap.nv-sidelay .nv-result .nv-end-in { grid-template-columns: minmax(0, 1fr); grid-template-areas: "h" "tab"; padding: 6px 7px; }
  .nv-wrap.nv-sidelay .nv-result .nv-end-tab { grid-template-columns: 1fr; }
  .nv-wrap.nv-sidelay .nv-result .nv-end-row { grid-template-columns: minmax(0, 1fr) auto; }
  .nv-wrap.nv-sidelay .nv-result .nv-end-row em { display: none; }
}
/* ================= (2026-10, f) a phone sideways: the panel as tall as what is in it (nothing in it cut), at the very
   bottom of the screen with a pixel or two under it; the seas on top take the rest ================= */
@media (orientation: landscape) and (max-height: 520px) {
  body.game-naumachia[data-page="table"] #table.page { padding-bottom: max(2px, env(safe-area-inset-bottom)); }
  .nv-wrap:not(.nv-sidelay) { align-content: space-between; }
  .nv-deck { height: auto; overflow: visible; align-items: center; }
  .nv-deck .nv-pl { padding: 3px 6px; min-width: 0; }
  .nv-deck .nv-pn b, .nv-deck .nv-pn small { line-height: 1.2; }
  .nv-deck .nv-fl { flex-wrap: nowrap; gap: 3px; overflow: hidden; }
  .nv-deck .nv-fls { width: calc(var(--n) * 6px); height: 6px; flex: none; }
}
/* (2026-10) the storm: rain only, no lightning */
.nvs-storm .nv-field::after { animation: nvRain .6s linear infinite; box-shadow: none; }
/* the look window (2026-10-18): larger, the seas and ships drawn larger */
.nv-lk-box { width: min(760px, 100%); padding: 22px; }
.nv-lk-grid { grid-template-columns: repeat(auto-fill, minmax(min(170px, 100%), 1fr)); gap: 10px; }
.nv-lk { gap: 9px; padding: 10px 8px; font-size: 12.5px; }
.nv-lk .nv-lk-prev { height: 104px; }
.nv-lk .nv-lk-prev .nv-ml-ship { zoom: 1.45; }
@media (max-width: 600px) { .nv-lk-box { padding: 16px 12px; } .nv-lk-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; } .nv-lk .nv-lk-prev { height: 86px; } }

/* the looks window always under the site's bar (it was centred: a tall one went under the bar); where the bar is hidden, the whole height */
.nv-modal { padding-top: calc(var(--top) + 12px); }
.nv-lk-box { max-height: calc(100dvh - var(--top) - 28px); }
body.game-fs .nv-modal { padding-top: 16px; } body.game-fs .nv-lk-box { max-height: calc(100dvh - 32px); }
@media (orientation: landscape) and (max-height: 520px) { body[data-page="table"] .nv-modal { padding-top: 16px; } body[data-page="table"] .nv-lk-box { max-height: calc(100dvh - 32px); } }
