/* 07c-cabin.css: det sidste CSS-lag (delt fra 07b-cabin.css 2026-11-21, da 07b blev over 120 KB). Indlæses lige efter 07b,
   så rækkefølgen er den samme som før. Nye regler sidst her. */

/* 2026-11-19 (brugerens valg): toasten i E2 som kampskiltene: symbol + få ord, intet bånd, mørk kontur. Farven siger hvad slags
   (10 TOAST_E2): .info creme, .good guld, .bad orange, .no blågrå (ordren kan ikke udføres) */
html body #toast .t.tx2 { display: inline-flex; align-items: center; gap: 0.4em; padding: 2px 0; background: none; -webkit-mask: none; mask: none;
  font: 700 1.12rem/1.15 var(--body); letter-spacing: 0.01em; color: #f3e9d2; text-align: left;
  text-shadow: 0 0 2px #050b10, 0 1px 2px #050b10, 0 0 10px rgba(5, 11, 16, 0.8); }
html body #toast .t.tx2.good { color: #ffd98a; }
html body #toast .t.tx2.bad { color: #f08a5d; }
html body #toast .t.tx2.no { color: #b8c6d2; }
html body #toast .t.tx2 em { font-style: normal; }
html body #toast .t.tx2 .tm { font-weight: 600; color: #e2d5bb; }
html body #toast .t.tx2 .fi { flex: none; width: 1.3em; height: 1.3em; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round;
  filter: drop-shadow(0 0 1.5px #050b10) drop-shadow(0 1px 1px #050b10); }
html body #toast .t.tx2 .fi.fs { fill: currentColor; stroke: none; }

/* 2026-11-19 (brugerens ønske): intet mærke over fjendeskibet i hovedvisningen: hverken navn, livsbjælke, afstand eller sigte (#enemyTag, 10 updateHUD) */
html body #enemyTag { display: none !important; }
/* 2026-11-20: Bomb bed i våbenkammeret (16b afsnit W): lejet på skibstegningen og en egen plads over lasten, og lejets kort i kanonlisten */
#arBedBox[hidden] { display: none; }
#arBedBox .arBedRow { display: grid; grid-template-columns: minmax(200px, 260px) 1fr; gap: 12px; align-items: center; }
html body #armory #arBedBox .arBedSlot { position: relative; display: flex; }
html body #armory #arBedBox .arBedSlot > .wc { width: 100%; }
#arBedBox .arBedNote { margin: 0; font: 0.88rem/1.4 var(--body); color: #e6d8ba; }
.arShip .arBedMark { cursor: pointer; }
.arShip .arBedMark .arPlus { stroke: #f0cd78; stroke-width: 2; fill: none; }
.arShip .arBedMark:hover .arHit, .arShip .arBedMark.hot .arHit, .arShip .arBedMark.over .arHit { fill: rgba(255, 240, 192, 0.16); stroke: rgba(255, 240, 192, 0.85); }
.arShip .arBedMark.sel .arHit { fill: rgba(255, 214, 110, 0.26); stroke: #fff0c0; stroke-width: 2.2; filter: drop-shadow(0 0 5px rgba(255, 220, 130, 0.9)); }
#armory.moving .arShip .arBedMark:not(.sel) .arHit { stroke: #ffe08a; stroke-dasharray: 5 3; }
#gunList .gcard.bedCard { cursor: default; box-shadow: inset 0 0 0 1px rgba(240, 205, 120, 0.45); }
#gunList .gcard.bedCard .bedTag { display: grid; place-items: center; width: 22px; height: 22px; font-style: normal; }
#gunList .gcard.bedCard .bedTag .px { width: 20px; height: 20px; }
#gunList .gcard.bedCard .r-bed { color: #f0cd78; }
#gunList .gcard.bedCard.off { opacity: 0.6; }
#gunList .gcard.bedCard.off .gbar { visibility: hidden; }
/* 2026-11-20 (brugerens ønske: ilden på hendes poster flimrede voldsomt, også på pause): de brændende felter i fjendepanelet blinker
   ikke længere (05 zoneBurn skiftede hvert 0,8 s), men står i et roligt, fast orange skær; og på pause står alle brandens
   CSS-animationer stille (glødekanten, hendes skrogbjælke og brandtallet), så intet bevæger sig, når spillet står */
body #enemyPanel .eOver .vz.burning:not(.aimed), .eOver .vz.burning:not(.aimed) { animation: none; fill: rgba(255, 128, 40, 0.34); }
body.paused :is(#hellVig, #epHullWrap.burnGlow, #epHullWrap .burnRate, .eOver .vz, .eBadges .vb) { animation-play-state: paused !important; }
body.paused #hellVig::after { animation-play-state: paused !important; }
/* TRAILEREN SOM INTRO (2026-11-20, 17d3): tekstkortene i smal antikva over bjælken; filmens kolde farvestik (lidt mindre mætning) */
#intro .trCard { position: absolute; left: 4vw; right: 4vw; bottom: calc(var(--inBar) + 9vh); text-align: center; opacity: 0; pointer-events: none; }
#intro .trCard span { font-family: "IM Fell English", Georgia, serif; font-size: clamp(18px, 2.3vw, 44px); letter-spacing: .42em; margin-right: -.42em; color: #f1ece2;
  text-shadow: 0 2px 14px rgba(0, 0, 0, .7); white-space: nowrap; }
html.trFilm #scene { filter: saturate(.74) contrast(1.04); }
/* trailerens montage (17d4): spillets banner, bossens bjælke, brevet på pergament, akt II, matrosens navn */
#intro .trBan { position: absolute; left: 50%; top: 40%; transform: translate(-50%, -50%); text-align: center; opacity: 0; pointer-events: none; white-space: nowrap; }
#intro .trBan b { display: block; font: 400 clamp(26px, 4.6vw, 64px)/1 "Pirata One", var(--display), serif; letter-spacing: .05em; color: var(--brass-l, #f0d89a);
  text-shadow: 0 2px 0 #3a2008, 0 4px 0 rgba(0, 0, 0, .35), 0 6px 22px rgba(0, 0, 0, .75); }
#intro .trBan.bad b { color: #ff9a7a; }
#intro .trBan small { display: inline-block; margin-top: 8px; padding: 5px 34px 6px; font: 600 clamp(10px, .95vw, 15px) Georgia, serif; letter-spacing: .22em; text-transform: uppercase; color: var(--brass-l, #f0d89a);
  background: linear-gradient(90deg, transparent, rgba(40, 22, 10, .9) 14%, rgba(40, 22, 10, .9) 86%, transparent); }
#intro .trBoss { position: absolute; left: 50%; top: calc(var(--inBar) + 3.5vh); transform: translateX(-50%); width: min(46vw, 640px); text-align: center; opacity: 0; pointer-events: none; }
#intro .trBoss i { display: block; font: 400 clamp(16px, 1.9vw, 28px) "Pirata One", serif; font-style: normal; letter-spacing: .18em; color: #f0d89a; text-shadow: 0 2px 8px rgba(0, 0, 0, .8); }
#intro .trBoss em { display: block; height: 10px; margin: 6px 0 5px; border: 1px solid #8a6a3a; background: rgba(20, 10, 4, .75); box-shadow: 0 0 10px rgba(0, 0, 0, .6); }
#intro .trBoss em span { display: block; height: 100%; background: linear-gradient(#d0443a, #8a1c16); }
#intro .trBoss small { display: block; font: italic clamp(13px, 1.3vw, 20px) "IM Fell English", Georgia, serif; letter-spacing: .12em; color: #ff9a7a; text-shadow: 0 2px 8px rgba(0, 0, 0, .9); }
#intro .trLetter { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(58vw, 760px); opacity: 0; pointer-events: none; }
#intro .trLetter div { padding: 4.2vh 4.4vw 3.6vh; color: #3a2614; font: clamp(15px, 1.55vw, 24px)/1.5 "IM Fell English", Georgia, serif;
  background: radial-gradient(ellipse at 50% 40%, #f3e6c4 0%, #e6d2a2 62%, #c9ab72 100%); box-shadow: 0 0 0 1px rgba(90, 60, 20, .5), 0 18px 60px rgba(0, 0, 0, .75), inset 0 0 60px rgba(120, 80, 30, .35); }
#intro .trLetter p { margin: 0 0 .7em; }
#intro .trLetter .last { font-size: 1.22em; color: #5a1a10; }
#intro .trLetter .sig { margin: 1em 0 0; text-align: right; font-style: italic; font-size: .85em; }
#intro .trAct { position: absolute; left: 0; right: 0; bottom: calc(var(--inBar) + 9vh); text-align: center; opacity: 0; pointer-events: none; }
#intro .trAct span { font: clamp(20px, 2.6vw, 48px) "IM Fell English", Georgia, serif; letter-spacing: .6em; margin-right: -.6em; color: #e8dcff; text-shadow: 0 0 18px rgba(176, 112, 255, .7), 0 2px 14px rgba(0, 0, 0, .8); }
#intro .trSay { position: absolute; left: 0; right: 0; bottom: calc(var(--inBar) + 6vh); text-align: center; opacity: 0; pointer-events: none; }
#intro .trSay span { font: italic clamp(15px, 1.5vw, 26px) "IM Fell English", Georgia, serif; letter-spacing: .06em; color: #e8e4dc; text-shadow: 0 2px 10px rgba(0, 0, 0, .9); }

/* INFAMY 5: SKROGTAVLEN BRÆNDER v2 (2026-11-20, 10-hud INF_FIRE): partikelilden i to lærreder (#infFireB bag tavlen,
   #infFireF foran), en kant af flydende glød (#infRim), et åndende skær udenom (::after) og forkullede kanter (#hullPlank::after).
   Den gamle flisekant fra 06c er slået fra. */
@property --infA { syntax: "<angle>"; inherits: false; initial-value: 0deg; }
html body #hullFrame.inf5 { filter: drop-shadow(0 10px 12px rgba(0, 0, 0, 0.6)) !important; }
html body #hullFrame.inf5 #hullPlank::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none; padding: 0; background: none !important; filter: none; animation: none !important;
  -webkit-mask: none; mask: none; border-radius: 0;
  box-shadow: inset 0 0 16px 4px rgba(34, 6, 0, 0.78), inset 0 0 3px 1px rgba(255, 128, 40, 0.55), inset 0 -10px 18px -6px rgba(255, 90, 20, 0.35);
  opacity: 0; transition: opacity 1.4s ease;
}
html body #hullFrame.inf5.infFire #hullPlank::after { opacity: 1; }
#infFireB, #infFireF { position: absolute; pointer-events: none; display: block; }
#infFireB { z-index: -1; }
#infFireF { z-index: 6; }
#infRim {
  position: absolute; inset: -2px; z-index: 5; pointer-events: none; box-sizing: border-box; padding: 2px; border-radius: 3px;
  background: conic-gradient(from var(--infA), rgba(255, 70, 8, 0.15) 0deg, #ff6a14 38deg, #ffd88a 64deg, #ff4a0c 104deg, rgba(255, 60, 8, 0.35) 150deg,
    #ff7a1e 206deg, #ffe7a6 236deg, #ff4a0c 278deg, rgba(255, 70, 8, 0.15) 360deg);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: 0; transition: opacity 1.4s ease; animation: infRimSpin 7s linear infinite paused;
}
html body #hullFrame.infFire #infRim { opacity: 1; animation-play-state: running; }
@keyframes infRimSpin { to { --infA: 360deg; } }
html body #hullFrame.infFire::after {
  content: "" !important; display: block !important; position: absolute; inset: 0; top: 0; bottom: 0; width: auto; z-index: -1; pointer-events: none;
  background: none; border-radius: 4px;
  box-shadow: 0 0 14px 3px rgba(255, 110, 24, 0.5), 0 0 40px 10px rgba(255, 60, 10, 0.22), 0 18px 34px 6px rgba(255, 70, 10, 0.18);
  animation: infBreath 2.8s ease-in-out infinite;
}
@keyframes infBreath { 0%, 100% { opacity: 0.72; } 50% { opacity: 1; } }
html body #hullFrame.inf5 .brand #shipName { animation: infName2 2.4s ease-in-out infinite !important; }
@keyframes infName2 { 0%, 100% { text-shadow: 0 1px 0 #2a0402, 0 0 6px #ff6a1a, 0 0 14px rgba(255, 70, 14, 0.75); } 50% { text-shadow: 0 1px 0 #2a0402, 0 0 8px #ffb040, 0 0 22px rgba(255, 110, 30, 0.95); } }
html.calm body #hullFrame.infFire #infRim, html.calm body #hullFrame.infFire::after, html.calm body #hullFrame.inf5 .brand #shipName { animation: none !important; }
@media (prefers-reduced-motion: reduce) {
  html body #hullFrame.infFire #infRim, html body #hullFrame.infFire::after, html body #hullFrame.inf5 .brand #shipName { animation: none !important; }
}

/* CHASE GUNS I KANONLISTEN (2026-11-20, 16b chaseGunCardHTML): drejebasserne på kaptajnens ræling har egne kort i Guns
   (før små mærker i Battle orders' top), med en kold blå kant, så de skilles fra batteriernes kanoner */
#gunList .gcard.chaseCard { cursor: default; box-shadow: inset 0 0 0 1px rgba(150, 196, 240, 0.45); }
#gunList .gcard.chaseCard .chaseTag { display: grid; place-items: center; width: 22px; height: 22px; font-style: normal; }
#gunList .gcard.chaseCard .chaseTag .px { width: 20px; height: 20px; }
#gunList .gcard.chaseCard .r-chase { color: #a9d2f5; }
#gunList .gcard.chaseCard .chSide { font-style: italic; font-size: 0.86em; opacity: 0.8; }
#gunList .gcard.chaseCard.idle { opacity: 0.6; }

/* TVILLINGESLANGERNES HOVEDMÅL (2026-11-20, 18b twinTabsUI): to faner over fjendepanelets målere; den valgte lyser,
   en sænket slange er grå. Skadens spøgelse i skrogbjælken skjules (bjælken viser kun hovedmålets halvdel). */
#twinTabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 6px 0 4px; align-items: stretch; }
#twinTabs[hidden] { display: none; }
#twinTabs .ttHead { grid-column: 1 / -1; font: 700 10px/1 var(--body, sans-serif); letter-spacing: 0.14em; text-transform: uppercase; color: #d9b98a; opacity: 0.85; }
#twinTabs .ttHead kbd { font: 700 9px/1 var(--body, sans-serif); padding: 2px 4px; margin-left: 4px; border-radius: 3px; background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(255, 220, 160, 0.35); color: #ffe7b8; letter-spacing: 0; }
#twinTabs button { display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto 6px; gap: 4px 8px; align-items: center; padding: 6px 9px 7px; text-align: left; cursor: pointer;
  border-radius: 4px; border: 1px solid rgba(120, 30, 40, 0.7); background: linear-gradient(180deg, rgba(40, 8, 14, 0.85), rgba(18, 4, 8, 0.9)); color: #e6cfc4;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06); transition: border-color 0.25s, box-shadow 0.25s, transform 0.15s, opacity 0.3s; }
#twinTabs button b { font: 700 12px/1.1 var(--body, sans-serif); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#twinTabs button em { font: 600 10px/1 var(--body, sans-serif); font-style: normal; color: #c9a6a0; white-space: nowrap; }
#twinTabs .ttBar { grid-column: 1 / -1; display: block; height: 6px; border-radius: 3px; background: rgba(0, 0, 0, 0.55); overflow: hidden; box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.7); }
#twinTabs .ttBar i { display: block; height: 100%; background: linear-gradient(180deg, #ff6a5a, #b0142a); transition: width 0.4s ease; }
#twinTabs button:hover:not(:disabled) { border-color: rgba(255, 150, 120, 0.8); transform: translateY(-1px); }
#twinTabs button.on { border-color: #ffcf7a; color: #fff3dc; background: linear-gradient(180deg, rgba(90, 20, 26, 0.95), rgba(40, 8, 12, 0.95));
  box-shadow: 0 0 0 1px rgba(255, 207, 122, 0.35), 0 0 12px rgba(255, 120, 60, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12); }
#twinTabs button.on b::before { content: "◎ "; color: #ffcf7a; }
#twinTabs button.dead { opacity: 0.45; cursor: default; filter: grayscale(0.8); }
#twinTabs button:focus-visible { outline: 2px solid #f0c060; outline-offset: 2px; }
#enemyPanel.twinView .hpGhost { display: none !important; }
#enemyPanel.twinSwap #ePlan { animation: twinSwapIn 0.45s ease-out; }
@keyframes twinSwapIn { from { opacity: 0.35; filter: brightness(1.6); } to { opacity: 1; filter: none; } }
html.calm #enemyPanel.twinSwap #ePlan { animation: none; }

/* 2026-11-20 (18b srIcon): slangernes egne poster (tvillingerne, vogteren, redens mor): giftgrønne mærker, som krakens er rosa */
.sti.sr { color: #c6dc8e; }
body #enemyPanel .eBadges .vb .sti.sr { color: #cfe39a; }

/* =============================== Startskærmen v4 (2026-11-20) ===============================
   Tre tekstlinks: How to play, Sails, Settings. Settings åbner pausemenuen over startskærmen (#escMenu.inMenu, 12f):
   Voyage-fanen og det frie kamera skjules. How to play har fire faner (.htTabs/.htPage, 17) og tasterne fra Controls. */
html body #escMenu.inMenu { z-index: 40; background-color: rgba(4, 6, 11, 0.62); }
#escMenu.inMenu #btnTabVoyage, #escMenu.inMenu #btnFreeCam { display: none !important; }
html.cab body #escMenu.inMenu > .panel { animation: popIn 0.25s ease-out; }
html.cab body #menu #btnMenuSet[aria-expanded="true"] { color: var(--cb-brass); text-decoration-color: var(--cb-brass); }
/* How to play: bredere end knapperne, faner øverst, én side ad gangen */
html.cab body #menu #howTo { width: min(760px, calc(100vw - 32px)); max-width: none; display: grid; gap: 12px; align-content: start; padding: 18px 22px 20px; }
html.cab body #menu #howTo h2 { margin: 0; display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 12px; font: 400 1.5rem "IM Fell English", Georgia, serif; color: var(--cb-cream); }
html.cab body #menu #howTo h2 small { font: 500 0.82rem var(--body); color: var(--cb-soft); }
#howTo .htTabs { display: flex; flex-wrap: wrap; gap: 4px 6px; border-bottom: 1px solid rgba(251, 243, 223, 0.22); }
/* fanerne: se MENUERNE 2026-11-22 sidst i filen (samme faner som skibsvinduet) */
#howTo .htPage { display: grid; gap: 10px; animation: mmFade 0.2s ease-out both; }
#howTo .htPage[hidden] { display: none !important; }
html.cab body #menu #howTo .htLead { margin: 0; font: italic 400 1.08rem/1.45 "IM Fell English", Georgia, serif; color: var(--cb-cream); }
html.cab body #menu #howTo ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 7px; font-size: 0.95rem; line-height: 1.5; color: var(--cb-soft); }
html.cab body #menu #howTo li { padding: 7px 10px 8px; border-radius: 3px; background: rgba(251, 243, 223, 0.04); box-shadow: inset 2px 0 0 rgba(240, 205, 120, 0.45); }
html.cab body #menu #howTo li > b:first-child { margin-right: 6px; color: var(--cb-cream); letter-spacing: 0.02em; }
html.cab body #menu #howTo kbd {
  display: inline-block; min-width: 1.7em; padding: 0 6px; margin: 0 1px; box-sizing: border-box; text-align: center; vertical-align: 1px;
  font: 700 0.78rem/1.55 var(--body); color: var(--cb-cream); border-radius: 3px; background: rgba(251, 243, 223, 0.1); box-shadow: inset 0 0 0 1px rgba(251, 243, 223, 0.38), 0 1px 0 rgba(0, 0, 0, 0.5);
}
@media (max-width: 560px) { html.cab body #menu #howTo .htTabs button { padding: 0 9px; font-size: 0.84rem; } }
@media (prefers-reduced-motion: reduce) { #howTo .htPage { animation: none; } }
html.calm #howTo .htPage { animation: none; }

/* =====================================================================
   STARTSKÆRMENS LOGO OG INDGANG (2026-11-21): logoet (.mmLogo.lgBox, samme som introens) i stedet for titlen i tekst.
   #menu.mmIn sættes hver gang menuen vises (showMenu, 17): logoet bygges op (havørnen, så navnet, så glans og glimt), og
   navnefeltet, knapperne og linkene kommer op ét ad gangen. #menu.fromIntro: introens logo glider herop (introFly, 17d);
   startskærmens eget logo er skjult, til det lander (.landed), og resten kommer, mens det sorte toner ud.
   ===================================================================== */
html.cab body #menu .mmVh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
html.cab body #menu .mmLogo { width: min(60vw, 320px, 33vh); }
html.cab body #menu .mmLogo .lgText { filter: drop-shadow(0 2px 2px rgba(20, 8, 4, .8)) drop-shadow(0 6px 16px rgba(0, 0, 0, .75)); }
/* indgangen */
html.cab body #menu.mmIn .mmLogo .lgEmbImg { animation: lgEmbIn 1.1s var(--lgE) .1s both; }
html.cab body #menu.mmIn .mmLogo .l1 .lgIn { animation: lgDown .85s var(--lgE) .5s both; }
html.cab body #menu.mmIn .mmLogo .l2 .lgIn { animation: lgSpread .95s var(--lgIO) .66s both; }
html.cab body #menu.mmIn .mmLogo .l3 .lgIn { animation: lgUp .95s var(--lgE) .74s both; }
html.cab body #menu.mmIn .mmLogo .lgEmb > .lgSheen { animation: lgSheen 1.25s ease-in-out 1.55s both, var(--lgIdle); --lgIdle: lgShimmer 8.5s ease-in-out 9s infinite; }
html.cab body #menu.mmIn .mmLogo .l1 .lgSheen { animation: lgSheen 1.2s ease-in-out 1.66s both, var(--lgIdle); --lgIdle: lgShimmer 8.5s ease-in-out 9.12s infinite; }
html.cab body #menu.mmIn .mmLogo .l2 .lgSheen { animation: lgSheen 1.2s ease-in-out 1.72s both, var(--lgIdle); --lgIdle: lgShimmer 8.5s ease-in-out 9.18s infinite; }
html.cab body #menu.mmIn .mmLogo .l3 .lgSheen { animation: lgSheen 1.2s ease-in-out 1.78s both, var(--lgIdle); --lgIdle: lgShimmer 8.5s ease-in-out 9.24s infinite; }
html.cab body #menu.mmIn .mmLogo .lgStar { animation: lgStar 1.05s ease-out 2.05s both, var(--lgIdle); --lgIdle: lgTwinkle 5.3s ease-out 4.4s infinite; }
html.cab body #menu.mmIn .mmLogo .lgStar.s2 { animation: lgStar .9s ease-out 2.45s both, var(--lgIdle); --lgIdle: lgTwinkle 6.7s ease-out 5.9s infinite; }
/* glitteret bagefter (2026-11-21, brugerens ønske): en glans hen over logoet hvert 8,5 s og fire glimt i hver sin takt, så de
   sjældent falder sammen (s3 ved SEA EAGLE's sidste E og s4 i solens guld findes kun i startskærmens logo) */
html.cab body #menu.mmIn .mmLogo .lgStar.s3 { animation: lgTwinkle 7.9s ease-out 3.3s infinite; }
html.cab body #menu.mmIn .mmLogo .lgStar.s4 { animation: lgTwinkle 9.7s ease-out 7.6s infinite; }
.lgBox .lgStar.s3 { left: 96.5%; top: 59%; width: 6%; }
.lgBox .lgStar.s4 { left: 16%; top: 75%; width: 11%; }
@keyframes lgShimmer { 0% { background-position: 100% 0; } 16% { background-position: 0 0; } 100% { background-position: 0 0; } }
@keyframes lgTwinkle { 0% { opacity: 0; transform: translate(-50%, -50%) scale(0) rotate(0deg); } 6% { opacity: 1; transform: translate(-50%, -50%) scale(.85) rotate(40deg); }
  14% { opacity: 0; transform: translate(-50%, -50%) scale(0) rotate(110deg); } 100% { opacity: 0; transform: translate(-50%, -50%) scale(0) rotate(110deg); } }
/* fra introen: logoet kommer flyvende, startskærmens eget står klar på pladsen; ingen opbygning, kun glitteret (som starter senere) */
html.cab body #menu.mmIn.fromIntro .mmLogo :is(.lgEmbImg, .lgIn) { animation: none; }
html.cab body #menu.mmIn.fromIntro .mmLogo .lgSheen, html.cab body #menu.mmIn.fromIntro .mmLogo .lgStar:is(:not(.s3, .s4)) { animation: var(--lgIdle); }
html.cab body #menu.fromIntro:not(.landed) .mmLogo { opacity: 0; }
/* navnefeltet, knapperne og linkene: op ét ad gangen (translate, så knappernes egen transform ved hover ikke røres);
   kun bagud (backwards), så sejlvalget bagefter kan skjule dem med almindelige regler */
@keyframes mmItem { from { opacity: 0; translate: 0 16px; } to { opacity: 1; translate: 0 0; } }
html.cab body #menu.mmIn .mmName,
html.cab body #menu.mmIn .mmBtns > button { animation: mmItem .7s var(--cb-ease, cubic-bezier(.2, .7, .2, 1)) backwards; }
html.cab body #menu.mmIn .mmName { animation-delay: .75s; }
html.cab body #menu.mmIn .mmBtns > button:nth-child(1) { animation-delay: .9s; }
html.cab body #menu.mmIn .mmBtns > button:nth-child(2) { animation-delay: 1s; }
html.cab body #menu.fromIntro .mmName { animation-delay: 1.05s; }
html.cab body #menu.fromIntro .mmBtns > button:nth-child(1) { animation-delay: 1.2s; }
html.cab body #menu.fromIntro .mmBtns > button:nth-child(2) { animation-delay: 1.3s; }
html.calm body #menu .mmLogo *,
html.calm body #menu .mmName,
html.calm body #menu .mmBtns > button { animation: none !important; }
@media (prefers-reduced-motion: reduce) { html.cab body #menu .mmLogo *,
 html.cab body #menu .mmName,
 html.cab body #menu .mmBtns > button { animation: none !important; } }

/* =====================================================================
   SEJLVALGET I SIDEN (2026-11-21, 17 sailDock): på brede skærme glider sejlfeltet hurtigt fra sin plads midt over knapperne ud i
   venstre side (højst skærmens højde); logo og knapper viger, traileren bag den kører uændret videre (skibet ses ved siden af).
   Lukkes det (#sailsMenu.closing, 0,25 s), glider det ud til venstre. Grænserne skal følge sailDock i 17.
   ===================================================================== */
html.cab body #menu .mmHead { transition: opacity .45s ease, translate .6s cubic-bezier(.2, .7, .2, 1); }
@media (min-width: 900px) and (min-aspect-ratio: 23/20) {
  html.cab body #menu #sailsMenu {
    /* bredt nok til elleve sejl pr. række, så alt står uden at rulle; fliserne (--tc) og billederne (--ti) følger skærmens højde */
    --sdL: clamp(20px, 3vw, 48px); --tc: clamp(82px, 3vh + 52px, 100px); --ti: clamp(36px, 5vh, 62px); --sdW: min(calc(11 * var(--tc) + 10 * 6px + 36px), calc(100vw - 2 * var(--sdL)));
    padding: 14px 18px 16px;
    position: fixed; z-index: 3; left: var(--sdL); top: var(--sdT); width: var(--sdW); max-height: calc(100vh - 2 * var(--sdT)); order: 0; --sdT: clamp(14px, 3vh, 40px);
    animation: sdIn .42s cubic-bezier(.22, 1, .36, 1) both;
  }
  html.cab body #menu #sailsMenu.closing { animation: sdOut .25s cubic-bezier(.5, 0, .9, .4) both; pointer-events: none; }
  html.cab body #menu .mm:has(#sailsMenu:not([hidden]):not(.closing)) .mmHead { opacity: 0; translate: 0 -18px; pointer-events: none; }
  /* navnefelt, knapper og links viger også (feltet har sin egen Done-knap); de kommer igen, når feltet lukkes */
  html.cab body #menu .mmDeck > :is(.mmName, .mmBtns, .mmLinks) { transition: opacity .4s ease, translate .5s cubic-bezier(.2, .7, .2, 1), visibility 0s; }
  html.cab body #menu .mm:has(#sailsMenu:not([hidden]):not(.closing)) .mmDeck > :is(.mmName, .mmBtns, .mmLinks) { opacity: 0; translate: 0 24px; visibility: hidden; pointer-events: none;
    transition: opacity .35s ease, translate .45s ease, visibility 0s .45s; }
  html.cab body #menu #sailsMenu button.sdDone { display: inline-flex; }
  html.cab body #menu #sailsMenu .sailGrid { grid-template-columns: repeat(11, minmax(0, 1fr)); gap: 6px; }
  html.cab body #menu #sailsMenu .sailOpt { min-height: 0; gap: 3px; padding: 6px 3px 5px !important; font-size: clamp(0.66rem, 0.9vh + 0.2rem, 0.8rem) !important; }
  html.cab body #menu #sailsMenu .sailOpt img, html.cab body #menu #sailsMenu .sailOpt.ach img { width: var(--ti); height: calc(var(--ti) * 1.15); }
  html.cab body #menu #sailsMenu .sailOpt.locked::before { top: calc(6px + var(--ti) * 0.575 - var(--ti) * 0.19); width: calc(var(--ti) * 0.3); height: calc(var(--ti) * 0.37); }
}
/* ind: fra midten (hvor det plejer at åbne) ud til venstre; ud: videre ud over kanten */
/* lavere skærme (2026-11-21, 41 optjente sejl): fliserne viser kun billedet og niveauet; navnet og hvordan står i #sailInfo, når man peger */
@media (min-width: 900px) and (min-aspect-ratio: 23/20) and (max-height: 980px) {
  html.cab body #menu #sailsMenu { --tc: clamp(56px, 7.4vh, 76px); }
  html.cab body #menu #sailsMenu .sailOpt em { font-size: 0.52rem; letter-spacing: 0.01em; }
  html.cab body #menu #sailsMenu .sailOpt > span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
}
@keyframes sdIn { 0% { opacity: 0; translate: calc(50vw - var(--sdL) - var(--sdW) / 2) 0; scale: .96; } 25% { opacity: 1; } 100% { opacity: 1; translate: 0 0; scale: 1; } }
@keyframes sdOut { from { opacity: 1; translate: 0 0; } to { opacity: 0; translate: -60px 0; } }
html.calm body #menu #sailsMenu { animation: mmFade .25s ease-out both !important; }
/* Done: kun når feltet står i venstre side */
html.cab body #menu #sailsMenu .sdDone { display: none; position: absolute; top: 14px; right: 14px; align-items: center; min-height: 34px; padding: 0 14px; cursor: pointer;
  font: 500 0.86rem var(--body); letter-spacing: 0.12em; text-transform: uppercase; color: var(--cb-cream); clip-path: none !important; filter: none !important; text-shadow: none !important;
  background: rgba(251, 243, 223, 0.06) !important; border: 1px solid rgba(251, 243, 223, 0.4) !important; border-radius: 2px !important; box-shadow: none !important; transition: color .15s, border-color .15s, background-color .15s; }
html.cab body #menu #sailsMenu .sdDone:hover { color: #14100a; background: var(--cb-brass) !important; border-color: var(--cb-brass) !important; }
html.cab body #menu #sailsMenu .sdDone:focus-visible { outline: 2px solid var(--cb-brass-hi); outline-offset: 3px; }
@media (prefers-reduced-motion: reduce) { html.cab body #menu #sailsMenu { animation: mmFade .25s ease-out both !important; } }

/* 2026-11-21: LÆKKER V2 (js/08b). En mand ude ved en læk: grå og "væk" i sin egen række, og i lækkens række en grå mand med
   en prop, der optager pladsen. Hullerne kan klikkes (send en mand); et hul, ingen er på, gløder rødt. Hendes rum: mærket "Leak". */
#stationList .cc.away { opacity: 0.4; filter: grayscale(0.9); }
#stationList .cc.away img { opacity: 0.85; }
#stationList .sc[data-act] .cc.away::before, #stationList .sc[data-act] .cc.away::after,
#stationList .sc[data-act] .cc.plug::before, #stationList .sc[data-act] .cc.plug::after { display: none !important; }
#stationList .cc.plug { position: relative; filter: grayscale(1) brightness(0.82); opacity: 0.85; box-shadow: 0 0 0 1.5px #6fb3d6; border-style: dashed; }
#stationList .cc.plug.moving { opacity: 0.55; }
#stationList .cc.plug .plugB { position: absolute; right: -3px; bottom: -3px; width: 9px; height: 9px; border-radius: 50%; background: #b98a4e; border: 1.5px solid #1a0e05; box-shadow: 0 0 0 1px #6fb3d6; filter: none; }
#stationList .slk .lk { pointer-events: auto; cursor: pointer; width: 20.4px; height: 28.8px; }   /* 11-21: 20 % større (var 17 × 24, 06e) */
#stationList .slk .lk.lone svg { animation: lkLone 1s ease-in-out infinite; }
@keyframes lkLone { 0%, 100% { filter: drop-shadow(0 1px 1px rgba(0, 0, 0, 0.6)); } 50% { filter: drop-shadow(0 0 3px #ff5a3a) drop-shadow(0 0 1px #ff5a3a); } }
html.calm #stationList .slk .lk.lone svg { animation: none; filter: drop-shadow(0 0 2px #ff5a3a); }
@media (prefers-reduced-motion: reduce) { #stationList .slk .lk.lone svg { animation: none; filter: drop-shadow(0 0 2px #ff5a3a); } }
.chip.leak.plg { background: #9cc2d8; color: #10202e; }
body #enemyPanel .eBadges .vb.leaking:not(.burning) .sti { filter: drop-shadow(0 0 5px #4fb4ff) drop-shadow(0 1px 2px #000); }
body #enemyPanel .eBadges .vb.leaking::before { content: ""; position: absolute; right: 1px; bottom: 6px; width: 13px; height: 17px; pointer-events: none;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 13 17'%3E%3Cpath d='M6.5 1C8.8 4.6 11.6 7.6 11.6 10.9a5.1 5.1 0 0 1-10.2 0C1.4 7.6 4.2 4.6 6.5 1z' fill='%235fb4ec' stroke='%2310202e' stroke-width='1.3'/%3E%3Cpath d='M4.4 11.4a2.2 2.2 0 0 0 1.8 2.2' fill='none' stroke='%23e6f6ff' stroke-width='1.2' stroke-linecap='round'/%3E%3C/svg%3E") center / contain no-repeat;
  filter: drop-shadow(0 1px 2px #000); animation: vbDrip 1.1s ease-in-out infinite; }
@keyframes vbDrip { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(2px); } }
html.calm body #enemyPanel .eBadges .vb.leaking::before { animation: none; }

/* 2026-11-21 (brugerens ønske): hændelsens valg under musen/fokus lyser tydeligt op, rykker frem med et lille fjedrende
   ryk, kanten og guldstregen gløder, og et lysglimt stryger én gang hen over (særlige valg beholder deres egen glans).
   Lyden: Sound.choiceHover (15). Rolig tilstand og reduceret bevægelse: kun lyset, ingen bevægelse */
html body #eventBox .choices button.evc { transition: transform 0.24s cubic-bezier(0.2, 1.5, 0.4, 1), box-shadow 0.18s ease, filter 0.18s ease, color 0.15s ease; }
html body #eventBox .choices button.evc:not(:disabled):is(:hover, :focus-visible) {
  transform: translateX(10px) scale(1.012); filter: brightness(1.16) saturate(1.08); color: #fffaf0;
  box-shadow: inset 0 0 0 1.5px var(--gold-l, #f2cf7a), inset 0 0 0 3px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(255, 214, 130, 0.4), 0 0 24px rgba(255, 196, 100, 0.5), 0 7px 14px rgba(0, 0, 0, 0.45);
}
html body #eventBox .choices button.evc:not(.special):not(:disabled):is(:hover, :focus-visible) {
  background-image: linear-gradient(90deg, rgba(255, 214, 140, 0.24), rgba(255, 214, 140, 0) 62%), repeating-linear-gradient(178deg, rgba(255, 222, 170, 0.06) 0 1px, transparent 1px 4px, rgba(0, 0, 0, 0.1) 4px 5px, transparent 5px 9px), linear-gradient(180deg, #7a4a22, #55311a);
}
html body #eventBox .choices button.evc:not(:disabled):is(:hover, :focus-visible)::before { transform: scaleY(1); opacity: 1; width: 5px; box-shadow: 0 0 12px rgba(255, 210, 120, 0.95); }
html body #eventBox .choices button.evc:not(:disabled):is(:hover, :focus-visible) .evIco { transform: scale(1.16); transition: transform 0.2s cubic-bezier(0.2, 1.6, 0.4, 1); }
html body #eventBox .choices button.evc:not(:disabled):active { transform: translateX(10px) scale(0.985); transition-duration: 0.06s; }
html body #eventBox .choices button.evc:not(.special)::after {
  content: ""; position: absolute; top: 0; bottom: 0; left: -45%; width: 38%; pointer-events: none; opacity: 0;
  background: linear-gradient(100deg, transparent, rgba(255, 238, 196, 0.3), transparent); transform: skewX(-18deg);
}
html body #eventBox .choices button.evc:not(.special):not(:disabled):is(:hover, :focus-visible)::after { animation: evcSheen 0.6s ease-out; }
@keyframes evcSheen { 0% { left: -45%; opacity: 1; } 100% { left: 112%; opacity: 0; } }
html.calm body #eventBox .choices button.evc:not(:disabled):is(:hover, :focus-visible) { transform: none; }
html.calm body #eventBox .choices button.evc::after { animation: none !important; }
@media (prefers-reduced-motion: reduce) {
  html body #eventBox .choices button.evc:not(:disabled):is(:hover, :focus-visible), html body #eventBox .choices button.evc:not(:disabled):active { transform: none; }
  html body #eventBox .choices button.evc::after { animation: none !important; }
}

/* 2026-11-21: guldet tælles op (10-hud goldHudTick): tallet gløder guld, mens det stiger, rødligt når det falder;
   byttetavlens tal (14-battle-ui haulCountTick) lyser, mens de tæller */
html body #hullPlank > .chips .chip2 b { transition: color 0.3s ease, text-shadow 0.3s ease; font-variant-numeric: tabular-nums; }
html body #hullPlank > .chips .chip2.gUp b { color: #ffe9a0; text-shadow: 0 0 8px rgba(255, 196, 80, 0.95), 0 1px 0 #1a0e05; }
html body #hullPlank > .chips .chip2.gDn b { color: #ffab8a; text-shadow: 0 0 6px rgba(255, 90, 50, 0.6), 0 1px 0 #1a0e05; }
html body #hullPlank > .chips .chip2.gUp :is(.px, svg, img, canvas) { animation: goldPop 0.45s cubic-bezier(0.2, 1.6, 0.4, 1); }
@keyframes goldPop { 40% { transform: scale(1.3) rotate(-8deg); } }
#haulBoard li b.cnt { color: #fff3c4; text-shadow: 0 0 10px rgba(255, 200, 90, 0.85); }
html.calm #hullPlank .chip2.gUp :is(.px, svg, img, canvas) { animation: none; }
@media (prefers-reduced-motion: reduce) { #hullPlank .chip2.gUp :is(.px, svg, img, canvas) { animation: none; } }

/* Settings > Sound: stereo/mono (15) */
#escSound .stereoRow .stHint { font-size: 0.8rem; opacity: 0.7; }

/* 2026-11-21: FORLISET SOM SCENE (08b sinkScene). HUD'et toner langsomt ud (body.sinkScene, samme liste som hudOff);
   #sinkCard: kanterne mørkner (veil), titlen og årsagen toner frem i trailerens skrift (txt) og ud igen (out),
   og regnskabet (#gameover.fromSink) toner roligt frem bagefter */
body.sinkFade > :not(#scene):not(#flash):not(#fade):not(#gameover):not(#sinkCard):not(#padCursor), body.sinkFade > #topleft > * { transition: opacity 1.4s ease !important; }
body.sinkScene > :not(#scene):not(#flash):not(#fade):not(#gameover):not(#sinkCard):not(#padCursor), body.sinkScene > #topleft > * { opacity: 0 !important; pointer-events: none !important; }
#sinkCard { position: fixed; inset: 0; z-index: 44; pointer-events: none; display: grid; place-items: center; opacity: 0; transition: opacity 3s ease;
  background: radial-gradient(ellipse at 50% 46%, transparent 38%, rgba(4, 8, 12, 0.55) 78%, rgba(2, 4, 6, 0.85) 100%), linear-gradient(180deg, rgba(0, 0, 0, 0.25), transparent 30%, transparent 70%, rgba(0, 0, 0, 0.35)); }
#sinkCard.veil { opacity: 1; }
#sinkCard .skTx { display: flex; flex-direction: column; align-items: center; gap: 0.9em; max-width: min(860px, 86vw); text-align: center; opacity: 0; transform: translateY(8px); transition: opacity 1.6s ease, transform 2.4s cubic-bezier(0.2, 0.7, 0.2, 1); }
#sinkCard.txt .skTx { opacity: 1; transform: none; }
#sinkCard.out .skTx { opacity: 0; transform: translateY(-6px); transition-duration: 0.9s; }
#sinkCard .skTx b { font: 400 clamp(26px, 3.6vw, 58px)/1.1 "IM Fell English", Georgia, serif; letter-spacing: 0.24em; margin-right: -0.24em; text-transform: uppercase; color: #f1ece2; text-shadow: 0 2px 18px rgba(0, 0, 0, 0.85); }
#sinkCard .skTx span { font: italic 400 clamp(16px, 1.7vw, 26px)/1.4 "IM Fell English", Georgia, serif; color: #d9cfbd; text-shadow: 0 1px 10px rgba(0, 0, 0, 0.9); }
html body #gameover.fromSink { animation: fadeIn 1.2s ease-out; }
html body #gameover.fromSink .panel { animation: popIn 1.1s cubic-bezier(0.2, 0.7, 0.2, 1) 0.15s backwards; }
html.calm #sinkCard, html.calm #sinkCard .skTx { transition-duration: 0.6s; }
/* Det frie kamera (2026-11-21, brugerens ønske): ingen pausefarver på scenen (05: body.paused #scene), så man ser de rigtige farver, også når spillet er pauset */
html body.fcOn #scene { filter: none !important; }

/* =====================================================================
   MENUERNE 2026-11-22 (brugerens ønske): hjælpen, slutskærmen, Ship's log, How to play og Sails i samme kahyt-stil som
   skibsvinduet; skibsvinduet lidt større. Den fælles ramme med messingsøm (som de store vinduer, B3 i 07) gives her
   til paneler, der ellers får HUD-panelernes søm-løse ramme.
   ===================================================================== */
html.cab body :is(#shipLog, #gameover) > .panel, html.cab body #menu .mmDeck > :is(#howTo, #sailsMenu) {
  --rope-frame:
    var(--cb-nail) 9px 9px / 14px 14px no-repeat, var(--cb-nail) calc(100% - 9px) 9px / 14px 14px no-repeat,
    var(--cb-nail) 9px calc(100% - 9px) / 14px 14px no-repeat, var(--cb-nail) calc(100% - 9px) calc(100% - 9px) / 14px 14px no-repeat,
    var(--cb-frame-plain) !important;
  --wood-bg: var(--rope-frame), var(--planks) !important;
}
/* fordybningen (tjære) og faner som skibsvinduets (06d .shipTab), uden at være .shipTab (shipBookSync tæller dem) */
html.cab body :is(#shipLog .logBody, #gameover .goStat, #gameover .goRouteBox, #menu #howTo .htPage, #menu #sailsMenu .sailGrid, #menu #sailsMenu #sailInfo) {
  background: linear-gradient(180deg, rgba(22, 13, 6, 0.93), rgba(28, 17, 9, 0.9));
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.7), inset 0 0 0 2px rgba(240, 205, 120, 0.22), inset 0 6px 14px rgba(0, 0, 0, 0.5), 0 1px 0 rgba(255, 220, 160, 0.14);
  border-radius: 6px;
}
html body :is(.logTabs .logTab, #menu #howTo .htTabs button) {
  position: relative; display: inline-flex; align-items: center; gap: 8px; min-width: 0; min-height: 46px; margin: 0;
  padding: 6px 14px 6px 10px !important; cursor: pointer; clip-path: none !important; border: 0 !important; border-radius: 8px 8px 0 0 !important;
  font: 400 1.12rem "IM Fell English", "Iowan Old Style", Georgia, serif !important; letter-spacing: 0.01em; white-space: nowrap; text-decoration: none;
  color: #e6d8ba !important; text-shadow: 0 1px 0 #100803 !important;
  background: linear-gradient(180deg, #33200f, #1c1109) !important;
  box-shadow: inset 0 0 0 1px rgba(240, 205, 120, 0.4), inset 0 -8px 10px -6px rgba(0, 0, 0, 0.7) !important;
  transform: none !important; filter: none !important; transition: background-color 0.12s ease, color 0.12s ease;
}
html body :is(.logTabs .logTab, #menu #howTo .htTabs button):hover:not([aria-selected="true"]) { color: #fff !important; background: linear-gradient(180deg, #553619, #2e1b0c) !important; box-shadow: inset 0 0 0 1.5px #fff0c0 !important; }
html body :is(.logTabs .logTab, #menu #howTo .htTabs button)[aria-selected="true"] {
  cursor: default; min-height: 52px; color: #2a180a !important; text-shadow: none !important;
  background: linear-gradient(180deg, #fff0c0, #f0cd78 60%, #d9ad55) !important;
  box-shadow: inset 0 0 0 1px #6a4a14, inset 0 2px 0 rgba(255, 255, 255, 0.55), 0 -2px 10px rgba(255, 220, 130, 0.25) !important;
}
html body :is(.logTabs .logTab, #menu #howTo .htTabs button):focus-visible { outline: 3px solid #fff !important; outline-offset: 2px !important; }
html body .logTabs .logTab b { font: inherit; }
html body .logTabs .logTab .stIco { flex: none; box-sizing: border-box; width: 30px; height: 30px; padding: 5px; border-radius: 50%; color: #f0cd78; background: #100803; box-shadow: 0 0 0 1.5px #b98a3c; }
html body .logTabs .logTab[aria-selected="true"] .stIco { color: #fff0c0; background: #2a180a; box-shadow: 0 0 0 1.5px #6a4a14; }
/* fanerækken står på en messinglinje, som i skibsvinduet */
html body :is(.logTabs, #menu #howTo .htTabs) { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 6px; border-bottom: 3px solid #f0cd78 !important; box-shadow: 0 2px 0 rgba(0, 0, 0, 0.55); }

/* ---------- 1. Hjælpen (H): til venstre for knaprækken (--hbX, 10 placeHudBtns) og aldrig ud over bunden ---------- */
html body #help:not([hidden]) {
  top: calc(var(--gt, 8px) + 2px) !important; right: calc(100vw - var(--hbX, calc(100vw - 34px)) + 38px) !important; left: auto !important;
  width: min(430px, calc(100vw - 120px)) !important; max-height: calc(100dvh - var(--gt, 8px) - 18px) !important; overflow-y: auto !important; box-sizing: border-box;
  padding: 16px 18px 18px !important;
}
html.txl body #help:not([hidden]) {
  top: calc((var(--gt, 8px) + 2px) / var(--uiz, 1)) !important; right: calc((100vw - var(--hbX, calc(100vw - 34px)) + 38px) / var(--uiz, 1)) !important;
  max-height: calc((100dvh - var(--gt, 8px) - 18px) / var(--uiz, 1)) !important; width: min(430px, calc((100vw - 120px) / var(--uiz, 1))) !important;
}
html body #help li span:first-child { width: 76px; }
html body #help ul { gap: 8px; }

/* ---------- 3. Slutskærmen (forlis og sejr; #goSummary fra 17): bred, med tal i fordybninger og knappen nederst til højre ---------- */
html body #gameover .panel {
  width: min(860px, calc(100vw - 32px)) !important; max-width: none !important; box-sizing: border-box; max-height: calc(100dvh - 32px) !important;
  padding: 26px 30px 24px !important; gap: 12px !important; align-items: stretch !important;
}
html body #gameover h2 { font: 400 clamp(1.9rem, 2.4vw, 2.6rem)/1.1 "IM Fell English", Georgia, serif !important; color: var(--cb-brass-hi, #fff0c0) !important; text-align: center; text-shadow: 0 2px 0 #100803, 0 3px 12px rgba(0, 0, 0, 0.6) !important; }
html body #gameover #goReason { text-align: center; font: italic 400 1.15rem/1.4 "IM Fell English", Georgia, serif; color: var(--cb-cream, #fbf3df); text-shadow: 0 1px 0 #100803; }
html body #gameover #goStats { text-align: center; font: 600 0.95rem var(--body); color: var(--cb-soft, #e6d8ba); text-shadow: 0 1px 0 #100803; }
html body #gameover .goSum { gap: 10px; }
html body #gameover .goShip { text-align: center; font-size: 1rem; text-shadow: 0 1px 0 #100803; }
html body #gameover .goSum h3 { margin: 8px 0 0; font-size: 0.78rem; color: var(--cb-brass-hi, #fff0c0); text-shadow: 0 1px 0 #100803; }
html body #gameover .goRouteBox { padding: 8px 6px 4px; }
html body #gameover .goStats { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
html body #gameover .goStat { padding: 10px 12px; gap: 2px; }
html body #gameover .goStat b { font: 400 1.7rem/1 "IM Fell English", Georgia, serif; color: var(--cb-cream, #fbf3df); }
html body #gameover .goStat span { font: 600 0.8rem var(--body); color: var(--cb-soft, #e6d8ba); }
html body #gameover .goArts, html body #gameover .goFallen, html body #gameover .goCrew { padding: 8px 10px; border-radius: 6px; background: rgba(16, 9, 4, 0.7); box-shadow: inset 0 0 0 1px rgba(240, 205, 120, 0.2); }
html body #gameover #btnRestart { align-self: flex-end; min-width: 200px; min-height: 46px; margin-top: 6px; font-size: 1.05rem; }

/* ---------- 5. Ship's log: fast størrelse som skibsvinduet, faner med ikon øverst, Done nederst ---------- */
html body #shipLog { background: rgba(8, 5, 2, 0.72); padding: 16px; }
html body #shipLog > .panel {
  width: min(1240px, 100%) !important; height: min(900px, calc(100dvh - 32px)); max-height: calc(100dvh - 32px) !important; box-sizing: border-box;
  display: flex; flex-direction: column; gap: 0; padding: 20px 24px 0 !important; overflow: hidden;
}
html.txl body #shipLog > .panel { zoom: var(--uiz, 1); height: min(900px, calc((100dvh - 32px) / var(--uiz, 1))); max-height: calc((100dvh - 32px) / var(--uiz, 1)) !important; }
html body #shipLog .logHead { flex: none; display: flex; flex-direction: column; gap: 8px; }
html body #shipLog h2 { margin: 0; display: flex; align-items: baseline; gap: 12px; font: 400 1.7rem "IM Fell English", Georgia, serif !important; color: var(--cb-brass-hi, #fff0c0) !important; text-shadow: 0 1px 0 #100803, 0 2px 3px rgba(0, 0, 0, 0.55); }
html body #shipLog h2 small { flex: none; font: 600 0.85rem var(--body); color: var(--cb-soft, #e6d8ba); letter-spacing: 0.02em; }
html body #shipLog .logBody { flex: 1 1 auto; min-height: 0; margin: 12px 0 0; padding: 14px 16px 16px; border-top: 0; overflow-y: auto; }
html body #shipLog .logTbl thead th { background: #1c1109; }
html body #shipLog .logNote { color: var(--cb-soft, #e6d8ba); font-size: 0.86rem; }
html body #shipLog .logFoot {
  flex: none; display: flex; align-items: center; gap: 12px; margin: 12px -24px 0; padding: 12px 24px 20px;
  border-top: 1.5px solid var(--cb-brass-d, #b98a3c);
  background:
    var(--cb-nail) 9px calc(100% - 9px) / 14px 14px no-repeat, var(--cb-nail) calc(100% - 9px) calc(100% - 9px) / 14px 14px no-repeat,
    var(--cb-rope-x) bottom / 100% 6px no-repeat, var(--cb-rope-y) left / 6px 100% no-repeat, var(--cb-rope-y) right / 6px 100% no-repeat,
    linear-gradient(180deg, #46290f, #2e1a09);
  box-shadow: 0 -12px 18px -10px rgba(0, 0, 0, 0.65);
}
html body #shipLog .lfHint { flex: 1 1 auto; color: var(--cb-soft, #e6d8ba); font-size: 0.88rem; text-shadow: 0 1px 0 #100803; }
html body #shipLog .lfHint kbd, html body #menu #howTo .htFoot kbd { padding: 1px 6px; font: 800 0.78rem/1.5 var(--body); color: #1a1206; background: #f0cd78; border: 0; border-radius: 3px; box-shadow: inset 0 0 0 1px #6a4a14; }
html body #shipLog #btnLogClose { min-width: 120px; min-height: 40px; font-size: 0.95rem; }
/* Ship-fanen: fire grupper, hver i sin egen kasse */
html body #shipLog .logShipGrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 520px), 1fr)); gap: 12px; align-items: start; }
html body #shipLog .logGroup { padding: 10px 12px 8px; border-radius: 6px; background: rgba(58, 37, 19, 0.35); box-shadow: inset 0 0 0 1px rgba(240, 205, 120, 0.22); }
html body #shipLog .logGroup h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 6px; font: 400 1.2rem "IM Fell English", Georgia, serif; color: var(--cb-brass-hi, #fff0c0); }
html body #shipLog .logGroup h3 .lgIco { width: 22px; height: 22px; color: #f0cd78; }
html body #shipLog .logGroup .logTbl tbody th { width: 38%; white-space: normal; }
html body #shipLog .logGroup .logTbl td:nth-child(2) { white-space: nowrap; font-weight: 700; color: var(--cb-cream, #fbf3df); font-variant-numeric: tabular-nums; }
html body #shipLog .logGroup .logTbl tr:last-child > * { border-bottom: 0; }
@media (max-width: 1100px) { html body .logTabs .logTab { padding: 6px 10px 6px 8px !important; font-size: 1rem !important; } html body .logTabs .logTab .stIco { width: 24px; height: 24px; padding: 4px; } }
@media (max-width: 760px) { html body .logTabs .logTab b { display: none; } }

/* ---------- 6. Startskærmen: How to play er et vindue midt på skærmen (logo og knapper bliver, hvor de er); Sails i træ ---------- */
html.cab body #menu .mmDeck > .panel#howTo {
  position: fixed; z-index: 40; left: 50%; top: 50%; translate: -50% -50%; order: 0;
  width: min(860px, calc(100vw - 32px)); max-height: calc(100dvh - 48px); box-sizing: border-box;
  display: flex; flex-direction: column; gap: 0; padding: 24px 28px 0; overflow: hidden; color: var(--cb-soft);
  box-shadow: var(--wood-edge), 0 0 0 100vmax rgba(4, 6, 11, 0.62) !important; animation: popIn 0.25s ease-out;
}
html.txl body #menu .mmDeck > .panel#howTo { max-height: calc((100dvh - 48px) / var(--uiz, 1)); }
html.cab body #menu #howTo h2 { flex: none; margin: 0 0 10px; font: 400 1.8rem "IM Fell English", Georgia, serif; color: var(--cb-brass-hi); text-shadow: 0 1px 0 var(--cb-ink), 0 2px 3px rgba(0, 0, 0, 0.55); }
html.cab body #menu #howTo h2 small { color: var(--cb-soft); font-size: 0.86rem; text-shadow: 0 1px 0 var(--cb-ink); }
html.cab body #menu #howTo .htTabs { flex: none; }
html.cab body #menu #howTo .htPage { flex: 1 1 auto; min-height: 0; overflow-y: auto; margin-top: 12px; padding: 14px 16px 16px; }
html.cab body #menu #howTo .htPage[hidden] { display: none !important; }
html.cab body #menu #howTo li { background: rgba(251, 243, 223, 0.05); }
html.cab body #menu #howTo .htFoot {
  flex: none; display: flex; align-items: center; gap: 12px; margin: 14px -28px 0; padding: 12px 28px 20px;
  border-top: 1.5px solid var(--cb-brass-d);
  background:
    var(--cb-nail) 9px calc(100% - 9px) / 14px 14px no-repeat, var(--cb-nail) calc(100% - 9px) calc(100% - 9px) / 14px 14px no-repeat,
    var(--cb-rope-x) bottom / 100% 6px no-repeat, var(--cb-rope-y) left / 6px 100% no-repeat, var(--cb-rope-y) right / 6px 100% no-repeat,
    linear-gradient(180deg, #46290f, #2e1a09);
}
html.cab body #menu #howTo .htFoot > span { flex: 1 1 auto; font: 500 0.88rem var(--body); color: var(--cb-soft); }
html.cab body #menu #howTo .htDone { min-width: 120px; min-height: 40px; padding: 0 18px; font: 800 0.95rem var(--body); }
/* Sails: træ som de andre vinduer; fliserne og beskrivelsen står i fordybninger. Pladsen i venstre side (sailDock) er uændret */
html.cab body #menu .mmDeck > #sailsMenu { padding: 20px 22px 18px; color: var(--cb-soft); box-shadow: var(--wood-edge) !important; }
html.cab body #menu #sailsMenu h2 { font: 400 1.7rem "IM Fell English", Georgia, serif; color: var(--cb-brass-hi); text-shadow: 0 1px 0 var(--cb-ink), 0 2px 3px rgba(0, 0, 0, 0.55); }
html.cab body #menu #sailsMenu #sailLockNote { color: var(--cb-cream); text-shadow: 0 1px 0 var(--cb-ink); }
html.cab body #menu #sailsMenu .sailGrid { padding: 10px 12px 12px; }
html.cab body #menu #sailsMenu #sailInfo { padding: 10px 14px; border: 0; }
html.cab body #menu #sailsMenu .sdDone { color: var(--cb-cream); background: linear-gradient(180deg, #4a2f17, #2a190b) !important; border: 1px solid var(--cb-brass-d) !important; border-radius: 4px !important; }

/* ---------- Skibsvinduet lidt større (06d: 1400 × 980): op til 1580 × 1100, men fri af knaprækken til højre, når skærmen er bred nok ---------- */
html body :is(#armory, #workshop, #inventory) { padding: max(12px, env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px)) max(12px, env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px)) !important; }
html body :is(#armory, #workshop, #inventory) > .panel { width: min(1580px, 100%, max(calc(100vw - 160px), 1400px)) !important; height: min(1100px, calc(100dvh - 24px)) !important; max-height: calc(100dvh - 24px) !important; }
html.txl body :is(#armory, #workshop, #inventory) > .panel { height: min(1100px, calc((100dvh - 24px) / var(--uiz, 1))) !important; max-height: calc((100dvh - 24px) / var(--uiz, 1)) !important; }

/* 11-22c (brugerens ønske): introens logo toner hurtigere ind (alle tider ca. 0,55 af 07b's); filmen er kortere (17d3 TR_TITLE) */
#intro.over .inLogo { transition: opacity .5s ease; }
#intro.over::before { transition: opacity .9s ease; }
#intro.logo .lgEmbImg { animation-duration: .85s; animation-delay: 0s; }
#intro.logo .lgHalo { animation-duration: 1.3s; animation-delay: .05s; }
#intro.logo .lgRing { animation-duration: .9s; animation-delay: .2s; }
#intro.logo .lgEmb { animation-duration: .7s; animation-delay: .55s; }
#intro.logo .l1 .lgIn { animation-duration: .65s; animation-delay: .82s; }
#intro.logo .l2 .lgIn { animation-duration: .7s; animation-delay: .95s; }
#intro.logo .l3 .lgIn { animation-duration: .7s; animation-delay: 1.0s; }
#intro.logo .lgEmb > .lgSheen { animation-duration: 1.0s; animation-delay: 1.65s; }
#intro.logo .l1 .lgSheen { animation-duration: 1.0s; animation-delay: 1.72s; }
#intro.logo .l2 .lgSheen { animation-duration: 1.0s; animation-delay: 1.78s; }
#intro.logo .l3 .lgSheen { animation-duration: 1.0s; animation-delay: 1.82s; }
#intro.logo .lgStar { animation-duration: .9s; animation-delay: 2.0s; }
#intro.logo .lgStar.s2 { animation-duration: .8s; animation-delay: 2.3s; }

/* ---- 2026-11-23 AKT III (18d): søkortets flåde er de navnløses, titelkortet, skiltet om The Beating Mass ---- */
#chart.act3 > .panel { box-shadow: inset 0 0 0 1.6px rgba(190, 90, 255, calc(0.65 * var(--chk, 1))), inset 0 0 110px rgba(30, 0, 40, calc(0.55 * var(--chk, 1))) !important; }
#chart.act3 #fleetG stop { stop-color: #1e0730; }
#chartSvg .a3Tent { pointer-events: none; }
#chartSvg .a3Tent path { fill: none; stroke: #6c1f9a; stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; opacity: 0.9; filter: drop-shadow(0 0 2px rgba(170, 70, 255, 0.6)); }
#chart.act3 #chartSvg .fleetShip { fill: #12061a; stroke: #b884ff; }
#chart.act3 #chartSvg .fleetEdge { stroke: #8a3ad8; filter: drop-shadow(0 0 4px rgba(150, 60, 255, 0.7)); }
#chart.act3 #chartSvg .fleetLbl { fill: #d2b0ff; }
#chartSector .actTag.a3 { background: #33092a; color: #ffc4ee; box-shadow: 0 0 6px rgba(255, 80, 200, 0.35); }
#actCard.a3 small { color: #ff9ad8; }
#actCard.a3 i { background: linear-gradient(90deg, transparent, #c0307a, #fff0ff, #c0307a, transparent); box-shadow: 0 0 14px #c0307a; }
#a3Note { position: fixed; left: 50%; bottom: 13vh; z-index: 7900; width: min(560px, 88vw); transform: translate(-50%, 14px); opacity: 0; transition: opacity 0.9s ease, transform 1.2s ease; cursor: pointer; }
#a3Note.on { opacity: 1; transform: translate(-50%, 0); }
#a3Note .a3nIn { display: flex; gap: 14px; align-items: flex-start; padding: 14px 18px; border-radius: 6px; background: linear-gradient(180deg, rgba(34, 10, 40, 0.95), rgba(18, 5, 22, 0.95)); border: 1px solid rgba(200, 120, 255, 0.5); box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 24px rgba(150, 40, 200, 0.35); color: #eadcf6; }
#a3Note .a3nIco svg { width: 46px; height: 46px; filter: drop-shadow(0 0 6px rgba(200, 80, 255, 0.6)); animation: a3Beat 1.2s ease-in-out infinite; }
#a3Note b { display: block; font: 400 1.25rem/1.2 "IM Fell English SC", var(--display); letter-spacing: 0.06em; color: #ffd4f4; margin-bottom: 4px; }
#a3Note p { margin: 0; font: italic 400 0.98rem/1.4 "IM Fell English", Georgia, serif; }
@keyframes a3Beat { 0%, 60%, 100% { transform: scale(1); } 10% { transform: scale(1.09); } 22% { transform: scale(1.04); } }
html.calm #a3Note, html.calm #a3Note .a3nIco svg { transition-duration: 0.3s; animation: none; }

/* AKT II'S TO FLAGSKIBE (2026-11-23, 18d duoTabsUI): samme faner som tvillingerne (kopieret ovenfra), men i hvert skibs farve
   (--pc: skarlagen / grøn) på kanten, skrogbjælken og navnet; skadens spøgelse skjules (bjælken viser hovedmålets halvdel). */
#pairTabs { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; margin: 6px 0 4px; align-items: stretch; }
#pairTabs[hidden] { display: none; }
#pairTabs .ttHead { grid-column: 1 / -1; font: 700 10px/1 var(--body, sans-serif); letter-spacing: 0.14em; text-transform: uppercase; color: #d9b98a; opacity: 0.85; }
#pairTabs .ttHead kbd { font: 700 9px/1 var(--body, sans-serif); padding: 2px 4px; margin-left: 4px; border-radius: 3px; background: rgba(0, 0, 0, 0.45); border: 1px solid rgba(255, 220, 160, 0.35); color: #ffe7b8; letter-spacing: 0; }
#pairTabs button { display: grid; grid-template-columns: 1fr auto; grid-template-rows: auto 6px; gap: 4px 8px; align-items: center; padding: 6px 9px 7px; text-align: left; cursor: pointer;
  border-radius: 4px; border: 1px solid rgba(120, 30, 40, 0.7); background: linear-gradient(180deg, rgba(40, 8, 14, 0.85), rgba(18, 4, 8, 0.9)); color: #e6cfc4;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06); transition: border-color 0.25s, box-shadow 0.25s, transform 0.15s, opacity 0.3s; }
#pairTabs button b { font: 700 12px/1.1 var(--body, sans-serif); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#pairTabs button em { font: 600 10px/1 var(--body, sans-serif); font-style: normal; color: #c9a6a0; white-space: nowrap; }
#pairTabs .ttBar { grid-column: 1 / -1; display: block; height: 6px; border-radius: 3px; background: rgba(0, 0, 0, 0.55); overflow: hidden; box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.7); }
#pairTabs .ttBar i { display: block; height: 100%; background: linear-gradient(180deg, #ff6a5a, #b0142a); transition: width 0.4s ease; }
#pairTabs button:hover:not(:disabled) { border-color: rgba(255, 150, 120, 0.8); transform: translateY(-1px); }
#pairTabs button.on { border-color: #ffcf7a; color: #fff3dc; background: linear-gradient(180deg, rgba(90, 20, 26, 0.95), rgba(40, 8, 12, 0.95));
  box-shadow: 0 0 0 1px rgba(255, 207, 122, 0.35), 0 0 12px rgba(255, 120, 60, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.12); }
#pairTabs button.on b::before { content: "◎ "; color: #ffcf7a; }
#pairTabs button.dead { opacity: 0.45; cursor: default; filter: grayscale(0.8); }
#pairTabs button:focus-visible { outline: 2px solid #f0c060; outline-offset: 2px; }
#pairTabs button { border-left: 4px solid var(--pc); background: linear-gradient(180deg, color-mix(in srgb, var(--pc) 16%, rgba(26, 14, 8, 0.9)), rgba(14, 8, 5, 0.92)); border-color: color-mix(in srgb, var(--pc) 55%, transparent); border-left-color: var(--pc); }
#pairTabs button b { color: color-mix(in srgb, var(--pc) 45%, #fff1dc); }
#pairTabs .ttBar i { background: linear-gradient(180deg, color-mix(in srgb, var(--pc) 70%, #fff), var(--pc)); }
#pairTabs button:hover:not(:disabled) { border-color: var(--pc); border-left-color: var(--pc); }
#pairTabs button.on { border-color: #ffcf7a; border-left-color: var(--pc); background: linear-gradient(180deg, color-mix(in srgb, var(--pc) 38%, rgba(30, 14, 8, 0.95)), rgba(20, 10, 6, 0.95));
  box-shadow: 0 0 0 1px rgba(255, 207, 122, 0.35), 0 0 14px color-mix(in srgb, var(--pc) 55%, transparent), inset 0 1px 0 rgba(255, 255, 255, 0.12); }
#enemyPanel.pairView .hpGhost { display: none !important; }
body #enemyPanel.pairView .emeters > .big .bar > i#epHullBar { background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--pc, #ff6a4a) 85%, #fff) 0 9px, transparent 9px 11px), linear-gradient(180deg, color-mix(in srgb, var(--pc, #ff6a4a) 45%, #fff), var(--pc, #d8402a)) !important; }
#enemyPanel.pairView #epName { text-shadow: 0 0 10px color-mix(in srgb, var(--pc, #c33) 60%, transparent); }

/* =====================================================================
   RANG OG ERFARING (2026-11-23, 08b): stjerner på portrætterne, postens "+50%", en valgt mands stjerner på posterne,
   en ny stjerne midt i kampen, og mønstringsrullen (#rankBoard) efter sejren
   ===================================================================== */
/* portrættet: stjernerne i en lille lodret søjle på venstre side af ikonet (2026-11-23, brugerens ønske), en tynd guldstreg
   øverst mod næste stjerne. Et portræt med stjerner får lidt luft til venstre, så søjlen ikke rører naboen */
/* alle pladser (med og uden stjerner, og de tomme) får samme luft til venstre, så portrætterne står i lige søjler */
#stationList .sc { gap: 2px !important; }
#stationList .sc > .cc, #stationList .sc > .es { margin-left: 8px !important; }
#stationList .cc.hst { overflow: visible !important; }
#stationList .cc .cst { position: absolute; left: -9px; top: 50%; z-index: 2; translate: 0 -50%; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; gap: 0;
  padding: 1px 1px; border-radius: 4px; font: 700 7.5px/8px var(--body, sans-serif);
  color: #ffd772; background: rgba(20, 11, 4, 0.92); box-shadow: 0 0 0 1px rgba(201, 160, 74, 0.85); text-shadow: 0 0 3px rgba(255, 200, 90, 0.6); }
#stationList .cc .cst b { display: block; font: inherit; }
#stationList .cc .cst.s3 { color: #3a2208; text-shadow: none; background: linear-gradient(90deg, #fff1b8, #f2c95a 55%, #c9962e); box-shadow: 0 0 0 1px #3a2208, 0 0 5px rgba(255, 215, 114, 0.8); }
#stationList .cc .cxp { position: absolute; left: 0; top: 0; z-index: 2; height: 2px; width: var(--xp, 0%); pointer-events: none;
  background: linear-gradient(90deg, #c9962e, #ffe08a); box-shadow: 0 0 4px rgba(255, 215, 114, 0.7); border-radius: 0 1px 1px 0; }
#stationList .cc .cmis { position: absolute; right: 1px; top: 1px; z-index: 2; width: 6px; height: 6px; border-radius: 50%; pointer-events: none;
  background: #e8a33a; box-shadow: 0 0 0 1px #1a0e05; opacity: 0.9; }
#stationList .cc.r3:not(.sel):not(.ill) { border-color: #f2cd70 !important; box-shadow: 0 0 0 1px #1a0e05, 0 0 7px rgba(255, 215, 114, 0.55) !important; }
#stationList .cc.r3:not(.moving) img { animation: rkMaster 4.5s ease-in-out infinite; }
@keyframes rkMaster { 0%, 86%, 100% { filter: none; } 92% { filter: brightness(1.35) sepia(0.25); } }
/* en ny stjerne: portrættet hopper op i en gylden ring, rækken får et guldstrøg og et skilt */
#stationList .cc.lvup { z-index: 4; animation: rkChipUp 0.9s cubic-bezier(0.2, 1.5, 0.4, 1) both, rkRing 0.85s ease-out 3; }
@keyframes rkChipUp { 0% { transform: scale(1); } 35% { transform: translateY(-4px) scale(1.28); } 100% { transform: scale(1); } }
@keyframes rkRing { 0% { box-shadow: 0 0 0 0 rgba(255, 215, 114, 0.95), 0 0 12px rgba(255, 215, 114, 0.9); } 100% { box-shadow: 0 0 0 9px rgba(255, 215, 114, 0), 0 0 12px rgba(255, 215, 114, 0); } }
#stationList .srow.rankup { animation: rkRow 1.6s ease-out; }
@keyframes rkRow { 0% { box-shadow: inset 0 0 0 2px #ffe08a, inset 0 0 28px rgba(255, 200, 90, 0.6); } 100% { box-shadow: inset 0 0 0 2px rgba(255, 224, 138, 0), inset 0 0 28px rgba(255, 200, 90, 0); } }
#stationList .srow .sdn.rk { color: #2a1804; background: linear-gradient(180deg, #fff0b0, #ffd772 50%, #e0ac3c); box-shadow: 0 0 0 1px #3a2408, 0 0 0 2px rgba(255, 235, 170, 0.6), 0 2px 8px rgba(0, 0, 0, 0.55), 0 0 14px rgba(255, 210, 110, 0.5); }
#stationList .srow .sdn.rk::before { content: "\2605\00a0"; color: #7a4a08; }
#stationList .srow .sdn.rk.on { animation-duration: 2.8s; }
/* postens løft (2026-11-23, finpudset): "▲ 50%" (grøn pil, ingen ramme) under navnet, på linje med navnets bogstaver; navnet
   rykker lidt op, så de to står samlet midt i rækken. Kun når rækken ikke viser sin egen anden linje */
#stationList .srow .smul { position: absolute; left: 33px; bottom: 5px; z-index: 2; pointer-events: auto; display: inline-flex; align-items: center; gap: 3px;
  padding: 0; font: 700 0.62rem/1.25 var(--body, sans-serif); letter-spacing: 0.03em; font-variant-numeric: tabular-nums;
  color: #ffe2a0; text-shadow: 0 1px 0 rgba(0, 0, 0, 0.6); }
#stationList .srow .smul::before { content: "\25B2"; font-size: 0.5rem; color: #8fe08a; transform: translateY(-0.5px); }
#stationList .srow.hasMul.full:not([data-state="bad"]):not(.burning):not([data-id="helm"]) .sn { translate: 0 -6px; transition: translate 0.2s ease; overflow: visible !important; }   /* ellers klippes det nedrykkede ikon */
/* kun navnet rykker op: ikonet bliver midt i rækken (2026-11-23, brugerens ønske) */
#stationList .srow.hasMul.full:not([data-state="bad"]):not(.burning):not([data-id="helm"]) .sn > :first-child { translate: 0 6px; transition: translate 0.2s ease; }   /* translate (ikke transform): ikonernes egne transform (spejling, arbejdsanimation) bevares */
#stationList .srow .smul:empty, #stationList .srow .sfit:empty { display: none; }
#stationList .srow:is(:not(.full), [data-state="bad"], .burning, [data-id="helm"]) .smul { display: none; }
/* en valgt eller trukket mand: hans stjerner på de poster, han er god til */
#stationList .srow .sfit { position: absolute; right: 7px; top: 50%; z-index: 3; translate: 0 -50%; pointer-events: none;
  padding: 1px 6px 2px; border-radius: 9px; font: 700 0.72rem/1.2 var(--body, sans-serif); letter-spacing: 0.02em;
  color: #ffd772; background: rgba(20, 11, 4, 0.92); box-shadow: 0 0 0 1px rgba(201, 160, 74, 0.9), 0 0 10px rgba(255, 210, 110, 0.35); animation: rkFitIn 0.22s ease-out; }
@keyframes rkFitIn { 0% { opacity: 0; translate: 6px -50%; } 100% { opacity: 1; translate: 0 -50%; } }
#stationList .srow[data-fit] { box-shadow: inset 0 0 0 1px rgba(255, 215, 114, 0.5), inset 0 0 14px rgba(255, 200, 90, 0.12) !important; }
#stationList .srow[data-fit="3"] .sfit { color: #3a2208; background: linear-gradient(180deg, #fff1b8, #f2c95a 55%, #c9962e); }
/* skilte over hovedet */
#floaters .floater.rankUp { color: #ffd772; border-color: rgba(255, 215, 114, 0.9) !important; background: linear-gradient(180deg, rgba(48, 30, 8, 0.92), rgba(20, 12, 4, 0.92));
  box-shadow: 0 0 0 1px #1a0e05, 0 0 18px rgba(255, 200, 90, 0.45), 0 3px 10px rgba(0, 0, 0, 0.5); animation: floatPop 0.4s cubic-bezier(.2, 1.7, .4, 1); }
#floaters .floater.rankUp b { color: #fff0b8; text-shadow: 0 0 10px rgba(255, 190, 80, 0.8); }
#floaters .floater.rankPerk { color: #2a1804; background: linear-gradient(180deg, #fff0b0, #ffd772 55%, #e0ac3c); box-shadow: 0 0 0 1px #3a2408, 0 0 12px rgba(255, 210, 110, 0.55);
  font: 800 0.8rem/1.2 var(--body); letter-spacing: 0.06em; text-transform: uppercase; animation: floatPop 0.3s cubic-bezier(.2, 1.7, .4, 1); }

/* ---------- mønstringsrullen ---------- */
#rankBoard { position: fixed; z-index: 29; left: 12px; bottom: 12px; width: 360px; max-width: calc(100vw - 24px); max-height: calc(100vh - 160px);
  display: flex; flex-direction: column; box-sizing: border-box; padding: 13px 14px 11px; border-radius: 6px;
  background: var(--wood-bg, linear-gradient(180deg, #4a2e14, #2a180a)); box-shadow: var(--wood-edge, 0 12px 30px rgba(0, 0, 0, 0.55)), 0 0 0 1px rgba(255, 215, 114, 0.12);
  color: var(--cb-cream, #f1e4c6); animation: rbIn 0.55s cubic-bezier(0.2, 1.1, 0.3, 1) both; transition: opacity 0.4s ease, translate 0.4s ease; }
#rankBoard.out { opacity: 0; translate: 0 20px; pointer-events: none; }
@keyframes rbIn { 0% { opacity: 0; translate: 0 28px; scale: 0.97; } 100% { opacity: 1; translate: 0 0; scale: 1; } }
#rankBoard .rbHead { display: flex; align-items: center; gap: 10px; padding: 2px 4px 9px 6px; margin-bottom: 7px;
  border-bottom: 1px solid rgba(255, 215, 114, 0.25); box-shadow: 0 1px 0 rgba(0, 0, 0, 0.45); }
#rankBoard .rbTi { flex: 1; min-width: 0; display: flex; flex-direction: column; }
#rankBoard .rbTi b { font: 400 1.42rem/1 "Pirata One", var(--display, serif); letter-spacing: 0.04em; color: var(--cb-brass-hi, #f2cd70); text-shadow: 0 2px 0 rgba(0, 0, 0, 0.55), 0 0 18px rgba(255, 200, 90, 0.25); }
#rankBoard .rbTi small { margin-top: 3px; font: 600 0.68rem/1.2 var(--body); letter-spacing: 0.08em; text-transform: uppercase; color: #c9b88e; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#rankBoard .rbSum { display: flex; flex-direction: column; align-items: flex-end; }
#rankBoard .rbTot { font: 800 1.12rem/1 var(--body); color: #ffe08a; font-variant-numeric: tabular-nums; text-shadow: 0 0 10px rgba(255, 200, 90, 0.45); }
#rankBoard .rbSum small { margin-top: 2px; font: 600 0.62rem/1 var(--body); letter-spacing: 0.08em; text-transform: uppercase; color: #c9b88e; }
#rankBoard .rbX { flex: none; width: 24px; height: 24px; padding: 0 !important; border-radius: 50% !important; display: grid; place-items: center;
  font: 700 1rem/1 var(--body) !important; color: #e8d6a8 !important; background: rgba(20, 11, 4, 0.75) !important; box-shadow: 0 0 0 1px rgba(201, 160, 74, 0.6) !important; cursor: pointer; }
#rankBoard .rbX:hover { color: #fff3c8 !important; box-shadow: 0 0 0 1px #f2cd70, 0 0 8px rgba(255, 210, 110, 0.5) !important; }
#rankBoard .rbList { overflow-y: auto; overflow-x: hidden; display: flex; flex-direction: column; gap: 5px; padding: 1px 2px 2px; scrollbar-width: thin; }
#rankBoard .rbRow { position: relative; display: grid; grid-template-columns: 38px minmax(0, 1fr) auto; align-items: center; gap: 9px;
  padding: 6px 9px 6px 6px; border-radius: 4px; background: var(--slot-bg, rgba(20, 11, 5, 0.85));
  box-shadow: inset 0 0 0 1px rgba(184, 141, 85, 0.3), inset 0 3px 7px rgba(0, 0, 0, 0.55);
  opacity: 0; animation: rbRowIn 0.45s cubic-bezier(0.2, 1, 0.3, 1) forwards; animation-delay: calc(0.18s + var(--i) * 0.07s); }
@keyframes rbRowIn { 0% { opacity: 0; translate: -14px 0; } 100% { opacity: 1; translate: 0 0; } }
#rankBoard .rbPor { position: relative; width: 36px; height: 38px; border-radius: 5px; overflow: hidden; border: 2px solid var(--rc, #8a7a5a); background: #120c08; box-sizing: border-box; }
#rankBoard .rbPor img { width: 100%; height: 100%; display: block; image-rendering: pixelated; }
#rankBoard .rbMid { min-width: 0; display: flex; flex-direction: column; gap: 3px; }
#rankBoard .rbL1 { display: flex; align-items: baseline; gap: 6px; min-width: 0; }
#rankBoard .rbL1 b { font: 700 0.86rem/1.1 var(--body); color: #f6ead0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#rankBoard .rbRole { font: 600 0.6rem/1 var(--body); letter-spacing: 0.08em; text-transform: uppercase; color: #a8987a; white-space: nowrap; }
#rankBoard .rbStars { margin-left: auto; display: flex; gap: 1px; font-size: 0.82rem; line-height: 1; }
#rankBoard .rbStars i { font-style: normal; color: rgba(255, 230, 170, 0.16); text-shadow: 0 1px 0 rgba(0, 0, 0, 0.6); transition: color 0.3s ease; }
#rankBoard .rbStars i.on { color: #ffd772; text-shadow: 0 0 6px rgba(255, 200, 90, 0.7), 0 1px 0 rgba(0, 0, 0, 0.6); }
#rankBoard .rbStars i.pop { animation: rbStarPop 0.75s cubic-bezier(0.2, 1.8, 0.4, 1); }
@keyframes rbStarPop { 0% { transform: scale(0.2) rotate(-40deg); } 55% { transform: scale(2.1) rotate(12deg); color: #fff8dc; text-shadow: 0 0 14px #ffe08a, 0 0 26px rgba(255, 190, 70, 0.9); } 100% { transform: scale(1) rotate(0); } }
#rankBoard .rbL2 { display: grid; grid-template-columns: 74px minmax(0, 1fr) 50px; align-items: center; gap: 7px; }
#rankBoard .rbTrade { font: 700 0.62rem/1 var(--body); letter-spacing: 0.09em; text-transform: uppercase; color: #d8c08a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#rankBoard .rbBar { position: relative; height: 8px; border-radius: 4px; overflow: hidden; background: rgba(0, 0, 0, 0.55); box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(201, 160, 74, 0.35); }
#rankBoard .rbBar i { position: absolute; left: 0; top: 0; bottom: 0; width: 0; border-radius: 4px; }
#rankBoard .rbBase { background: linear-gradient(180deg, #8a6a32, #5e4420); z-index: 1; }
#rankBoard .rbFill { background: linear-gradient(180deg, #fff0b0, #ffd060 45%, #d89a2a); box-shadow: 0 0 8px rgba(255, 200, 90, 0.7); }
#rankBoard .rbShine { width: 100% !important; z-index: 2; background: linear-gradient(100deg, transparent 30%, rgba(255, 255, 255, 0.45) 45%, transparent 60%) no-repeat; background-size: 220% 100%; background-position: 160% 0; opacity: 0; }
#rankBoard .rbRow.up .rbShine { animation: rbShine 0.9s ease-out; }
@keyframes rbShine { 0% { opacity: 1; background-position: 160% 0; } 100% { opacity: 0; background-position: -60% 0; } }
#rankBoard .rbNum { font: 700 0.62rem/1 var(--body); color: #c9b88e; text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
#rankBoard .rbRow.max .rbNum { color: #ffd772; letter-spacing: 0.08em; }
#rankBoard .rbNote { font: 500 0.66rem/1.25 var(--body); color: #b9aa88; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#rankBoard .rbNote:empty { display: none; }
#rankBoard .rbPerk { font: 600 0.66rem/1.3 var(--body); color: #f1e2b8; padding: 3px 7px; margin-top: 1px; border-radius: 3px; background: linear-gradient(90deg, rgba(255, 200, 90, 0.22), rgba(255, 200, 90, 0.04)); box-shadow: inset 2px 0 0 #ffd772; }
#rankBoard .rbPerk b { color: #ffd772; letter-spacing: 0.04em; }
#rankBoard .rbPerk.in { animation: rbPerkIn 0.6s cubic-bezier(0.2, 1.2, 0.3, 1); }
@keyframes rbPerkIn { 0% { opacity: 0; translate: -10px 0; } 100% { opacity: 1; translate: 0 0; } }
#rankBoard .rbGain { min-width: 34px; text-align: right; font: 800 0.92rem/1 var(--body); color: #ffe08a; font-variant-numeric: tabular-nums; text-shadow: 0 0 8px rgba(255, 200, 90, 0.35); }
#rankBoard .rbRow.max .rbPor { border-color: #f2cd70; box-shadow: 0 0 8px rgba(255, 215, 114, 0.55); }
#rankBoard .rbRow.up { animation: rbRowUp 1.5s ease-out; opacity: 1; }
@keyframes rbRowUp { 0% { box-shadow: inset 0 0 0 2px #ffe08a, inset 0 0 30px rgba(255, 200, 90, 0.55), 0 0 18px rgba(255, 200, 90, 0.45); } 100% { box-shadow: inset 0 0 0 1px rgba(184, 141, 85, 0.3), inset 0 3px 7px rgba(0, 0, 0, 0.55), 0 0 0 rgba(255, 200, 90, 0); } }
#rankBoard .rbRow.up .rbPor { animation: rbPorUp 0.8s cubic-bezier(0.2, 1.6, 0.4, 1); }
@keyframes rbPorUp { 0% { transform: scale(1); } 40% { transform: scale(1.16); box-shadow: 0 0 0 3px rgba(255, 224, 138, 0.9), 0 0 18px rgba(255, 200, 90, 0.9); } 100% { transform: scale(1); } }
#rankBoard .rbUpTag { position: absolute; left: 50px; bottom: 5px; z-index: 3; padding: 2px 8px; border-radius: 9px; pointer-events: none; white-space: nowrap;
  font: 800 0.6rem/1.3 var(--body); letter-spacing: 0.1em; text-transform: uppercase; color: #2a1804;
  background: linear-gradient(180deg, #fff0b0, #ffd772 50%, #e0ac3c); box-shadow: 0 0 0 1px #3a2408, 0 2px 8px rgba(0, 0, 0, 0.5), 0 0 14px rgba(255, 210, 110, 0.6);
  animation: rbTag 2.6s cubic-bezier(0.2, 1.4, 0.4, 1) forwards; }
@keyframes rbTag { 0% { opacity: 0; translate: 0 6px; scale: 0.7; } 10% { opacity: 1; translate: 0 0; scale: 1.06; } 18% { scale: 1; } 85% { opacity: 1; } 100% { opacity: 0; translate: 0 -4px; } }
#rankBoard .rbBurst { position: absolute; left: 25px; top: 25px; width: 0; height: 0; z-index: 4; pointer-events: none; }
#rankBoard .rbBurst i { position: absolute; left: -2px; top: -2px; width: 4px; height: 4px; border-radius: 50%; background: #ffe08a; box-shadow: 0 0 6px #ffc850;
  animation: rbSpark 1s cubic-bezier(0.1, 0.8, 0.3, 1) forwards; }
#rankBoard .rbBurst i:nth-child(1) { --a: 0deg; } #rankBoard .rbBurst i:nth-child(2) { --a: 36deg; } #rankBoard .rbBurst i:nth-child(3) { --a: 72deg; }
#rankBoard .rbBurst i:nth-child(4) { --a: 108deg; } #rankBoard .rbBurst i:nth-child(5) { --a: 144deg; } #rankBoard .rbBurst i:nth-child(6) { --a: 180deg; }
#rankBoard .rbBurst i:nth-child(7) { --a: 216deg; } #rankBoard .rbBurst i:nth-child(8) { --a: 252deg; } #rankBoard .rbBurst i:nth-child(9) { --a: 288deg; } #rankBoard .rbBurst i:nth-child(10) { --a: 324deg; }
@keyframes rbSpark { 0% { transform: rotate(var(--a)) translateX(0) scale(1.3); opacity: 1; } 100% { transform: rotate(var(--a)) translateX(34px) scale(0.2); opacity: 0; } }
#rankBoard .rbRow.fallen { filter: grayscale(0.9); }
#rankBoard .rbRow.fallen .rbMid, #rankBoard .rbRow.fallen .rbPor { opacity: 0.55; }
#rankBoard .rbRow.fallen .rbL1 b { text-decoration: line-through; text-decoration-color: rgba(220, 90, 60, 0.7); }
#rankBoard .rbList.dense { gap: 3px; }
#rankBoard .rbList.dense .rbRow { padding: 4px 8px 4px 5px; }
#rankBoard .rbList.dense .rbPor { width: 30px; height: 32px; }
#rankBoard .rbList.dense .rbRow { grid-template-columns: 32px minmax(0, 1fr) auto; }
#rankBoard .rbFoot { margin-top: 8px; padding: 7px 4px 0; border-top: 1px solid rgba(255, 215, 114, 0.18); font: 500 0.64rem/1.3 var(--body); color: #a8987a; text-align: center; letter-spacing: 0.02em; }
#rankBoard .rbFoot b { color: #ffd772; }
html.calm #rankBoard, html.calm #rankBoard .rbRow, html.calm #rankBoard * { animation: none !important; }
html.calm #rankBoard .rbRow { opacity: 1; }
@media (prefers-reduced-motion: reduce) { #rankBoard, #rankBoard .rbRow, #rankBoard *, #stationList .cc.lvup, #stationList .cc.r3 img { animation: none !important; } #rankBoard .rbRow { opacity: 1; } }
@media (max-width: 760px) { #rankBoard { left: 8px !important; right: 8px; width: auto !important; top: calc(64px + env(safe-area-inset-top, 0px)) !important; bottom: auto !important; max-height: calc(100vh - 220px) !important; } }
#rankBoard .rbList.dense .rbUpTag { left: 44px; bottom: 3px; }
/* smal rulle (lidt plads til venstre for dialogen): rollen skjules, mindre portræt og tal, så navn og bjælke har plads */
#rankBoard.narrow { padding: 11px 10px 9px; }
#rankBoard.narrow .rbRole { display: none; }
#rankBoard.narrow .rbRow, #rankBoard.narrow .rbList.dense .rbRow { grid-template-columns: 30px minmax(0, 1fr) auto; gap: 7px; padding: 5px 7px 5px 5px; }
#rankBoard.narrow .rbPor, #rankBoard.narrow .rbList.dense .rbPor { width: 30px; height: 32px; }
#rankBoard.narrow .rbL2 { grid-template-columns: 58px minmax(0, 1fr) 40px; gap: 5px; }
#rankBoard.narrow .rbTrade { font-size: 0.56rem; letter-spacing: 0.05em; }
#rankBoard.narrow .rbNum { font-size: 0.58rem; }
#rankBoard.narrow .rbGain { min-width: 28px; font-size: 0.84rem; }
#rankBoard.narrow .rbTi b { font-size: 1.22rem; }
#rankBoard.narrow .rbUpTag { left: 42px; }
#rankBoard.narrow .rbBurst { left: 20px; top: 21px; }

/* ---------- ★★★: valget mellem to evner (08c rankPerkInner) i rullen og i det lille kort (#rankPrompt) ---------- */
#rankBoard .rbPerk.pick { display: flex; flex-direction: column; gap: 5px; padding: 6px 7px 7px; background: linear-gradient(90deg, rgba(255, 200, 90, 0.2), rgba(255, 200, 90, 0.05)); box-shadow: inset 2px 0 0 #ffd772, 0 0 12px rgba(255, 200, 90, 0.18); }
.rbPerk.chosen { animation: rbChosen 0.9s ease-out; }
@keyframes rbChosen { 0% { box-shadow: inset 2px 0 0 #ffd772, 0 0 0 2px #ffe08a, 0 0 22px rgba(255, 210, 110, 0.8); } 100% { box-shadow: inset 2px 0 0 #ffd772; } }
/* ---------- hendes veteraner (08c) i fjendepanelet ---------- */
#enemyPanel .chip.vet { color: #2a1804 !important; background: linear-gradient(180deg, #fff0b0, #ffd772 55%, #e0ac3c) !important; box-shadow: 0 0 0 1px #3a2408 !important; letter-spacing: -0.5px; }
#enemyPanel .now.vet, #eInfo .now.vet { color: #ffd772 !important; }
#floaters .floater.rankPerk.foe { color: #fff1d8; background: linear-gradient(180deg, #c8402a, #8a1f14); box-shadow: 0 0 0 1px #2a0804, 0 0 12px rgba(220, 80, 40, 0.5); }
/* den valgte evne folder sig sammen i rullen kort efter valget (2026-11-24) */
#rankBoard .rbPerk.gone { opacity: 0; max-height: 0; margin: 0; padding-top: 0; padding-bottom: 0; overflow: hidden; transition: opacity 0.3s ease, max-height 0.4s ease, padding 0.4s ease, margin 0.4s ease; }
#rankBoard .rbPerk { max-height: 160px; }
/* buildets tredje evne (2026-11-24): over hele bredden, med buildets navn; den nuværende evne markeret */
/* ---------- buildevnen i farve, som de særlige valg i hændelserne (2026-11-24, brugerens ønske) ----------
   --spc = buildets farve (08c RANK_BHUE); farvet kant og glød, en lys stribe til venstre, buildets ikon i et skinnende skjold,
   et ✦, og et lys der glider hen over knappen af og til */
@keyframes rbBldShine { 0%, 62% { background-position: 180% 0; } 100% { background-position: -80% 0; } }
@keyframes rbBldIn { 0% { opacity: 0; translate: 0 6px; } 100% { opacity: 1; translate: 0 0; } }
.rbPickIco { position: relative; flex: none; width: 30px; height: 30px; display: grid; place-items: center; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--spl) 40%, transparent), color-mix(in srgb, var(--spc) 32%, rgba(14, 12, 10, 0.94)) 70%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--spl) 85%, transparent), 0 0 10px color-mix(in srgb, var(--spc) 55%, transparent); }
.rbPickIco .px, .rbPickIco img, .rbPickIco svg { width: 20px; height: 20px; image-rendering: pixelated; filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.6)); }
.rbPickIco::after { content: "✦"; position: absolute; right: -3px; top: -5px; font-size: 0.6rem; color: var(--spl); text-shadow: 0 0 6px var(--spc); animation: rbTwinkle 2.4s ease-in-out infinite; }
@keyframes rbTwinkle { 0%, 100% { opacity: 0.55; transform: scale(0.85); } 50% { opacity: 1; transform: scale(1.15); } }
/* den valgte buildevne i rullen */
.rbChosenB { display: inline-flex; align-items: center; gap: 7px; flex-wrap: wrap; --spl: color-mix(in srgb, var(--spc) 42%, #fff); }
.rbChosenB .rbPickIco { width: 22px; height: 22px; }
.rbChosenB .rbPickIco .px, .rbChosenB .rbPickIco img, .rbChosenB .rbPickIco svg { width: 15px; height: 15px; }
.rbChosenB b { color: var(--spl) !important; text-shadow: 0 0 8px color-mix(in srgb, var(--spc) 60%, transparent); }
.rbChosenB em { font: 700 0.55rem/1 var(--body); font-style: normal; letter-spacing: 0.1em; text-transform: uppercase; color: color-mix(in srgb, var(--spl) 80%, #c9a85a); }
#rankBoard .rbPerk:has(.rbChosenB) { box-shadow: inset 2px 0 0 var(--spc, #ffd772); background: linear-gradient(90deg, color-mix(in srgb, var(--spc, #ffd772) 22%, transparent), transparent); }
#rankBoard .rbPerk [title] { cursor: help; }   /* evnens beskrivelse står i tooltip (08c rankPerkInner) */
html.calm .rbPickIco::after { animation: none; }
@media (prefers-reduced-motion: reduce) { .rbPickIco::after { animation: none !important; } }

/* =====================================================================
   MESTERENS EVNE v2 (2026-11-24, brugerens ønske): mærket under postlisten (#rankBadge), knappen i rullen (.rbOpenC)
   og ceremonien (#rankCeremony). Guld, stråler, tre stjerner der tændes, og evnerne som kort; buildets kort i sin farve (--spc)
   ===================================================================== */
#rankBoard .rbPerk.pick { display: block; padding: 0; background: none; box-shadow: none; }
.rbOpenC { all: unset; box-sizing: border-box; cursor: pointer; position: relative; overflow: hidden; display: flex; align-items: center; gap: 8px; width: 100%; padding: 6px 10px 6px 7px; border-radius: 4px;
  font: 800 0.64rem/1.2 var(--body); letter-spacing: 0.08em; text-transform: uppercase; color: #2a1804;
  background: linear-gradient(180deg, #fff3c2, #ffd772 48%, #d9a13a); box-shadow: 0 0 0 1px #3a2408, 0 0 0 2px rgba(255, 235, 170, 0.5), 0 0 16px rgba(255, 205, 100, 0.55);
  animation: rcBtnPulse 2.2s ease-in-out infinite; }
.rbOpenC::after { content: ""; position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.75) 50%, transparent 65%) no-repeat; background-size: 260% 100%; background-position: 180% 0; animation: rcSweep 2.8s ease-in-out infinite; }
.rbOpenC:hover, .rbOpenC:focus-visible { filter: brightness(1.08); box-shadow: 0 0 0 1px #3a2408, 0 0 0 2px #fff3c2, 0 0 22px rgba(255, 210, 110, 0.85); }
.rbOpenStar { display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #2a1804; color: #ffd772; font-size: 0.75rem; box-shadow: 0 0 8px rgba(255, 210, 110, 0.8); }
.rbOpenC > span:nth-child(2) { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rbOpenArr { font-size: 1.1rem; line-height: 1; }
@keyframes rcBtnPulse { 0%, 100% { box-shadow: 0 0 0 1px #3a2408, 0 0 0 2px rgba(255, 235, 170, 0.5), 0 0 12px rgba(255, 205, 100, 0.45); } 50% { box-shadow: 0 0 0 1px #3a2408, 0 0 0 2px rgba(255, 235, 170, 0.8), 0 0 22px rgba(255, 205, 100, 0.8); } }
@keyframes rcSweep { 0%, 55% { background-position: 180% 0; } 100% { background-position: -80% 0; } }

/* mærket: en mester venter */
#rankBadge { all: unset; box-sizing: border-box; position: fixed; z-index: 27; left: 12px; top: 140px; cursor: pointer; overflow: hidden; display: flex; align-items: center; gap: 9px; max-width: 320px; padding: 6px 12px 6px 6px; border-radius: 8px;
  background: linear-gradient(180deg, rgba(58, 36, 12, 0.96), rgba(26, 15, 6, 0.96)); color: #f6ead0;
  box-shadow: 0 0 0 1px #ffd772, 0 0 0 2px rgba(58, 36, 8, 0.9), 0 0 18px rgba(255, 200, 90, 0.5), 0 6px 14px rgba(0, 0, 0, 0.5);
  animation: rbgIn 0.6s cubic-bezier(0.2, 1.5, 0.35, 1) both, rbgGlow 2.4s ease-in-out 0.6s infinite; transition: opacity 0.35s ease, translate 0.35s ease; }
#rankBadge.out { opacity: 0; translate: -14px 0; pointer-events: none; }
#rankBadge:hover, #rankBadge:focus-visible { box-shadow: 0 0 0 1px #fff0b8, 0 0 0 2px rgba(58, 36, 8, 0.9), 0 0 28px rgba(255, 210, 110, 0.85), 0 8px 18px rgba(0, 0, 0, 0.55); translate: 0 -1px; }
.rbgPor { position: relative; flex: none; width: 30px; height: 32px; border-radius: 5px; overflow: hidden; border: 2px solid #f2cd70; background: #120c08; box-shadow: 0 0 10px rgba(255, 215, 114, 0.7); }
.rbgPor img { width: 100%; height: 100%; display: block; image-rendering: pixelated; }
.rbgTx { display: flex; flex-direction: column; min-width: 0; }
.rbgTx b { font: 700 0.8rem/1.2 var(--body); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rbgTx small { font: 800 0.56rem/1.3 var(--body); letter-spacing: 0.09em; text-transform: uppercase; color: #ffd772; white-space: nowrap; }
.rbgStar { flex: none; font-size: 1.05rem; color: #ffd772; text-shadow: 0 0 10px rgba(255, 200, 90, 0.95); animation: rcTwinkle 1.8s ease-in-out infinite; }
.rbgShine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 38%, rgba(255, 240, 190, 0.35) 50%, transparent 62%) no-repeat; background-size: 260% 100%; background-position: 180% 0; animation: rcSweep 3.4s ease-in-out infinite; }
@keyframes rbgIn { 0% { opacity: 0; translate: -24px 0; scale: 0.9; } 100% { opacity: 1; translate: 0 0; scale: 1; } }
@keyframes rbgGlow { 0%, 100% { filter: none; } 50% { filter: brightness(1.12); } }
@keyframes rcTwinkle { 0%, 100% { opacity: 0.7; transform: scale(0.9) rotate(0); } 50% { opacity: 1; transform: scale(1.2) rotate(18deg); } }

/* ceremonien */
#rankCeremony { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: 16px; }
#rankCeremony .rcVeil { position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 45%, rgba(40, 24, 6, 0.35), rgba(4, 3, 2, 0.82) 70%); backdrop-filter: blur(3px) saturate(0.8); animation: rcFade 0.5s ease both; }
#rankCeremony .rcCard { position: relative; width: min(680px, 100%); max-height: calc(100vh - 32px); overflow: auto; box-sizing: border-box; padding: 26px 26px 18px; border-radius: 10px; text-align: center;
  background: radial-gradient(ellipse at 50% 0%, rgba(255, 200, 90, 0.16), transparent 55%), var(--wood-bg, linear-gradient(180deg, #4a2e14, #2a180a));
  box-shadow: var(--wood-edge, 0 12px 30px rgba(0, 0, 0, 0.55)), 0 0 0 1px rgba(255, 215, 114, 0.55), 0 0 0 5px rgba(20, 11, 4, 0.6), 0 0 60px rgba(255, 190, 80, 0.25), 0 30px 60px rgba(0, 0, 0, 0.6);
  color: var(--cb-cream, #f1e4c6); animation: rcCardIn 0.75s cubic-bezier(0.18, 1.25, 0.3, 1) both; }
#rankCeremony .rcCard::before { content: ""; position: absolute; inset: 7px; border-radius: 6px; pointer-events: none; box-shadow: inset 0 0 0 1px rgba(255, 215, 114, 0.28); }
@keyframes rcFade { 0% { opacity: 0; } 100% { opacity: 1; } }
@keyframes rcCardIn { 0% { opacity: 0; transform: translateY(26px) scale(0.9); filter: brightness(1.8); } 60% { filter: brightness(1.15); } 100% { opacity: 1; transform: none; filter: none; } }
#rankCeremony.out .rcVeil { animation: rcFade 0.5s ease reverse both; }
#rankCeremony.out .rcCard { animation: rcCardOut 0.5s ease both; }
@keyframes rcCardOut { 0% { opacity: 1; transform: none; } 100% { opacity: 0; transform: translateY(-14px) scale(0.96); } }
/* gyldne gnister der stiger */
.rcMotes { position: absolute; inset: 0; pointer-events: none; overflow: hidden; border-radius: 10px; }
.rcMotes i { position: absolute; bottom: -8px; width: 3px; height: 3px; border-radius: 50%; background: #ffe08a; box-shadow: 0 0 6px #ffc850; opacity: 0; animation: rcMote 5s linear infinite; }
.rcMotes i:nth-child(1) { left: 6%; animation-delay: 0.2s; } .rcMotes i:nth-child(2) { left: 14%; animation-delay: 2.1s; } .rcMotes i:nth-child(3) { left: 22%; animation-delay: 1.1s; }
.rcMotes i:nth-child(4) { left: 31%; animation-delay: 3.4s; } .rcMotes i:nth-child(5) { left: 39%; animation-delay: 0.7s; } .rcMotes i:nth-child(6) { left: 47%; animation-delay: 2.7s; }
.rcMotes i:nth-child(7) { left: 55%; animation-delay: 1.6s; } .rcMotes i:nth-child(8) { left: 62%; animation-delay: 4.1s; } .rcMotes i:nth-child(9) { left: 70%; animation-delay: 0.4s; }
.rcMotes i:nth-child(10) { left: 77%; animation-delay: 3s; } .rcMotes i:nth-child(11) { left: 84%; animation-delay: 1.9s; } .rcMotes i:nth-child(12) { left: 91%; animation-delay: 4.5s; }
.rcMotes i:nth-child(13) { left: 27%; animation-delay: 4.8s; } .rcMotes i:nth-child(14) { left: 66%; animation-delay: 2.4s; }
@keyframes rcMote { 0% { transform: translate(0, 0) scale(0.6); opacity: 0; } 12% { opacity: 0.9; } 100% { transform: translate(14px, -440px) scale(1.2); opacity: 0; } }
/* portrættet med stråler og stjerner */
.rcTop { position: relative; height: 112px; display: grid; place-items: center; margin: 0 auto 4px; }
.rcRays { position: absolute; left: 50%; top: 50%; width: 260px; height: 260px; translate: -50% -50%; border-radius: 50%; pointer-events: none;
  background: repeating-conic-gradient(from 0deg, rgba(255, 214, 120, 0.42) 0deg 5deg, transparent 5deg 18deg);
  -webkit-mask: radial-gradient(circle, #000 18%, transparent 68%); mask: radial-gradient(circle, #000 18%, transparent 68%);
  animation: rcSpin 22s linear infinite, rcRaysIn 1.1s ease-out both; }
@keyframes rcSpin { to { rotate: 360deg; } }
@keyframes rcRaysIn { 0% { opacity: 0; scale: 0.4; } 100% { opacity: 1; scale: 1; } }
.rcPor { position: relative; z-index: 1; width: 68px; height: 72px; border-radius: 8px; overflow: hidden; border: 3px solid #f2cd70; background: #120c08;
  box-shadow: 0 0 0 2px #3a2408, 0 0 24px rgba(255, 210, 110, 0.85), 0 8px 18px rgba(0, 0, 0, 0.55); animation: rcPorIn 0.8s cubic-bezier(0.2, 1.6, 0.4, 1) 0.15s both, rcPorGlow 2.6s ease-in-out 1s infinite; }
.rcPor img { width: 100%; height: 100%; display: block; image-rendering: pixelated; }
@keyframes rcPorIn { 0% { opacity: 0; transform: scale(0.4) rotate(-8deg); } 100% { opacity: 1; transform: none; } }
@keyframes rcPorGlow { 0%, 100% { box-shadow: 0 0 0 2px #3a2408, 0 0 20px rgba(255, 210, 110, 0.7), 0 8px 18px rgba(0, 0, 0, 0.55); } 50% { box-shadow: 0 0 0 2px #3a2408, 0 0 34px rgba(255, 220, 130, 1), 0 8px 18px rgba(0, 0, 0, 0.55); } }
.rcStars { position: absolute; z-index: 2; bottom: -2px; left: 50%; translate: -50% 0; display: flex; gap: 4px; }
.rcStars i { font-style: normal; font-size: 1.15rem; color: #ffd772; text-shadow: 0 0 10px rgba(255, 200, 90, 1), 0 1px 0 #3a2408; opacity: 0; animation: rcStarOn 0.6s cubic-bezier(0.2, 1.9, 0.4, 1) both; }
.rcStars i:nth-child(1) { animation-delay: 0.55s; } .rcStars i:nth-child(2) { animation-delay: 0.75s; font-size: 1.35rem; } .rcStars i:nth-child(3) { animation-delay: 0.95s; }
@keyframes rcStarOn { 0% { opacity: 0; transform: scale(0.1) rotate(-60deg); } 60% { opacity: 1; transform: scale(1.6) rotate(10deg); color: #fff8dc; } 100% { opacity: 1; transform: none; } }
.rcKick { font: 800 0.66rem/1.2 var(--body); letter-spacing: 0.24em; text-transform: uppercase; color: #ffd772; margin-top: 6px; animation: rcUp 0.6s ease 0.9s both; }
.rcTitle { margin: 4px 0 2px; font: 400 2.3rem/1.05 "Pirata One", var(--display, serif); letter-spacing: 0.03em;
  background: linear-gradient(100deg, #b8862e 0%, #ffe9a8 30%, #fff8dc 42%, #ffd772 55%, #c9962e 80%); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 2px 0 rgba(0, 0, 0, 0.6)) drop-shadow(0 0 16px rgba(255, 200, 90, 0.35)); animation: rcUp 0.6s ease 1s both, rcGold 4s ease-in-out 1.4s infinite; }
@keyframes rcGold { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0% 0; } }
.rcName { font: 700 0.82rem/1.3 var(--body); color: #e8dcc0; animation: rcUp 0.6s ease 1.1s both; }
.rcAsk { margin: 10px auto 14px; max-width: 460px; font: 500 0.78rem/1.4 var(--body); color: #c9b88e; animation: rcUp 0.6s ease 1.2s both; transition: color 0.3s ease; }
#rankCeremony.picked .rcAsk { color: #ffe9a8; }
@keyframes rcUp { 0% { opacity: 0; transform: translateY(8px); } 100% { opacity: 1; transform: none; } }
/* evnerne som kort */
.rcOpts { display: grid; gap: 12px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.rcOpts.n3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.rcOpts.n1 { grid-template-columns: minmax(0, 260px); justify-content: center; }
@media (max-width: 620px) { .rcOpts.n3 { grid-template-columns: 1fr; } .rcOpts { grid-template-columns: 1fr; } }
.rcOpt { --spc: #ffd772; --spl: color-mix(in srgb, var(--spc) 42%, #fff);
  all: unset; box-sizing: border-box; cursor: pointer; position: relative; overflow: hidden; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 16px 12px 14px; border-radius: 8px; text-align: center;
  background-color: color-mix(in srgb, var(--spc) 10%, rgba(16, 10, 5, 0.94));
  background-image: radial-gradient(ellipse at 50% 0%, color-mix(in srgb, var(--spc) 28%, transparent), transparent 70%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--spc) 70%, transparent), inset 0 0 0 2px rgba(0, 0, 0, 0.45), 0 6px 14px rgba(0, 0, 0, 0.45);
  transition: transform 0.22s cubic-bezier(0.2, 1.4, 0.4, 1), box-shadow 0.22s ease, background-color 0.22s ease, opacity 0.35s ease, filter 0.35s ease;
  animation: rcOptIn 0.6s cubic-bezier(0.2, 1.3, 0.35, 1) backwards; }
.rcOpt:nth-child(1) { animation-delay: 1.25s; } .rcOpt:nth-child(2) { animation-delay: 1.38s; } .rcOpt:nth-child(3) { animation-delay: 1.51s; }
@keyframes rcOptIn { 0% { opacity: 0; transform: translateY(16px) scale(0.94); } 100% { opacity: 1; transform: none; } }
.rcOpt:hover:not([aria-disabled]), .rcOpt:focus-visible:not([aria-disabled]) { transform: translateY(-4px); background-color: color-mix(in srgb, var(--spc) 18%, rgba(20, 13, 6, 0.96));
  box-shadow: inset 0 0 0 1px var(--spl), inset 0 0 0 2px rgba(0, 0, 0, 0.45), 0 0 26px color-mix(in srgb, var(--spc) 55%, transparent), 0 12px 22px rgba(0, 0, 0, 0.5); }
.rcOpt.bld { background-color: color-mix(in srgb, var(--spc) 20%, rgba(16, 10, 5, 0.95)); background-image: radial-gradient(ellipse at 50% 0%, color-mix(in srgb, var(--spc) 50%, transparent), transparent 72%);
  box-shadow: inset 0 0 0 1px var(--spc), inset 0 0 0 2px rgba(0, 0, 0, 0.45), 0 0 18px color-mix(in srgb, var(--spc) 40%, transparent), 0 6px 14px rgba(0, 0, 0, 0.45); }
.rcMed { position: relative; display: grid; place-items: center; width: 46px; height: 46px; border-radius: 50%; margin-bottom: 4px;
  background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--spl) 50%, transparent), color-mix(in srgb, var(--spc) 35%, rgba(14, 10, 6, 0.95)) 72%);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--spl) 90%, transparent), 0 0 14px color-mix(in srgb, var(--spc) 60%, transparent); transition: transform 0.25s ease; }
.rcMed i { font-style: normal; font-size: 1.4rem; color: var(--spl); text-shadow: 0 0 10px var(--spc); }
.rcMed .px, .rcMed img, .rcMed svg { width: 28px; height: 28px; image-rendering: pixelated; filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.6)); }
.rcMed::after { content: "✦"; position: absolute; right: -4px; top: -6px; font-size: 0.7rem; color: var(--spl); text-shadow: 0 0 6px var(--spc); animation: rcTwinkle 2.2s ease-in-out infinite; }
.rcOpt:hover .rcMed { transform: scale(1.08) rotate(-6deg); }
.rcOpt b { font: 800 0.95rem/1.2 var(--body); color: var(--spl); text-shadow: 0 0 10px color-mix(in srgb, var(--spc) 55%, transparent); }
.rcOpt em { font: 800 0.55rem/1.2 var(--body); font-style: normal; letter-spacing: 0.14em; text-transform: uppercase; color: color-mix(in srgb, var(--spl) 75%, #b89a5a); }
.rcOpt small { font: 500 0.72rem/1.4 var(--body); color: #e3d7bd; }
.rcOpt.cur { box-shadow: inset 0 0 0 1px #8fe08a, inset 0 0 0 2px rgba(0, 0, 0, 0.45), 0 6px 14px rgba(0, 0, 0, 0.45); }
.rcOpt.cur em { color: #8fe08a; }
.rcShine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 35%, color-mix(in srgb, var(--spl) 30%, transparent) 46%, rgba(255, 255, 255, 0.4) 50%, color-mix(in srgb, var(--spl) 30%, transparent) 54%, transparent 65%) no-repeat;
  background-size: 260% 100%; background-position: 180% 0; animation: rcSweep 4.2s ease-in-out 2s infinite; }
.rcOpt:nth-child(2) .rcShine { animation-delay: 2.5s; } .rcOpt:nth-child(3) .rcShine { animation-delay: 3s; }
.rcOpt:hover .rcShine { animation-duration: 1.2s; animation-delay: 0s; }
/* valget: kortet blusser op, de andre trækker sig */
.rcOpt.chosen { transform: translateY(-6px) scale(1.05); z-index: 1; animation: rcChosen 1.2s ease-out both; }
@keyframes rcChosen { 0% { box-shadow: inset 0 0 0 2px #fff8dc, 0 0 0 0 rgba(255, 220, 140, 0.9), 0 0 50px color-mix(in srgb, var(--spc) 90%, transparent); } 100% { box-shadow: inset 0 0 0 1px var(--spl), 0 0 0 18px rgba(255, 220, 140, 0), 0 0 30px color-mix(in srgb, var(--spc) 60%, transparent); } }
.rcOpt.chosen .rcShine { animation: rcSweep 0.9s ease-out 0s 1 both; }
.rcOpt.dim { opacity: 0.32; filter: grayscale(0.7); transform: scale(0.96); animation: none; }
.rcOpt[aria-disabled] { cursor: default; pointer-events: none; }
.rcLater { all: unset; cursor: pointer; margin-top: 14px; padding: 4px 12px; border-radius: 12px; font: 700 0.62rem/1.4 var(--body); letter-spacing: 0.14em; text-transform: uppercase; color: #a8987a; transition: color 0.2s ease, background 0.2s ease; animation: rcUp 0.6s ease 1.6s both; }
.rcLater:hover, .rcLater:focus-visible { color: #f1e4c6; background: rgba(255, 215, 114, 0.1); }
#rankCeremony.picked .rcLater { visibility: hidden; }
html.calm #rankCeremony *, html.calm #rankBadge, html.calm .rbOpenC, html.calm .rbOpenC::after { animation: none !important; }
html.calm .rcStars i, html.calm .rcOpt, html.calm .rcKick, html.calm .rcTitle, html.calm .rcName, html.calm .rcAsk, html.calm .rcLater { opacity: 1; }
@media (prefers-reduced-motion: reduce) { #rankCeremony *, #rankBadge, .rbOpenC, .rbOpenC::after { animation: none !important; } .rcStars i, .rcOpt, .rcKick, .rcTitle, .rcName, .rcAsk, .rcLater { opacity: 1; } }

/* 2026-11-24 SLANGENS SLAG (14-battle2 bsUI): nedtællingen til halens slag / tvillingernes salve, og postens række, der skal tømmes */
#strikeCard { display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 2px 9px; margin: 6px 0 4px; padding: 7px 9px 8px 8px; border-radius: 4px;
  border-left: 3px solid #a8743e; background: linear-gradient(90deg, rgba(44, 16, 10, 0.78), rgba(22, 9, 6, 0.55)); color: #f3e2cc; }
#strikeCard[hidden] { display: none; }
#strikeCard .skIco { grid-row: 1 / 3; color: #e8b88a; }
#strikeCard .skIco svg { width: 26px; height: 26px; display: block; }
#strikeCard .skName { font: 400 1.02rem/1.1 "Pirata One", var(--display); color: #ffd98a; letter-spacing: 0.04em; }
#strikeCard .skT { font-weight: 700; font-variant-numeric: tabular-nums; color: #ffe8c8; }
#strikeCard .skHow { grid-column: 2 / 4; font-size: 0.78rem; line-height: 1.25; opacity: 0.86; }
#strikeCard .skBar { grid-column: 1 / -1; display: block; height: 5px; margin-top: 4px; border-radius: 3px; background: rgba(0, 0, 0, 0.55); overflow: hidden; }
#strikeCard .skBar i { display: block; height: 100%; background: linear-gradient(90deg, #b8803a, #ffd98a); transition: width 0.12s linear; }
#strikeCard[data-m="warn"] { border-left-color: #ff4a2a; background: linear-gradient(90deg, rgba(176, 26, 12, 0.7), rgba(48, 8, 4, 0.55)); animation: bcWarn 0.6s ease-in-out infinite; }
#strikeCard[data-m="warn"] .skName { color: #ffcf6a; text-transform: uppercase; letter-spacing: 0.05em; }
#strikeCard[data-m="warn"] .skIco { color: #ffb08a; }
#strikeCard[data-m="warn"] .skBar i { background: linear-gradient(90deg, #ff2a0a, #ff9a4a); box-shadow: 0 0 8px #ff5a2a; }
.srow.bsDanger { box-shadow: inset 0 0 0 2px #ff4a2a, 0 0 14px rgba(255, 60, 30, 0.55); animation: bcWarn 0.6s ease-in-out infinite; }
html.calm #strikeCard[data-m="warn"], html.calm .srow.bsDanger { animation: none; }
@media (prefers-reduced-motion: reduce) { #strikeCard[data-m="warn"], .srow.bsDanger { animation: none !important; } }

/* ---------- New voyage: "slet det gemte togt?" (2026-11-24, 17 newVoyageAsk) ---------- */
#newConfirm { position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center; background: rgba(8, 5, 2, 0.62); backdrop-filter: blur(2px); }
#newConfirm[hidden] { display: none !important; }
#newConfirm .ncBox {
  width: min(460px, calc(100vw - 32px)); padding: 22px 26px 20px; text-align: center; border-radius: var(--jn-r, 3px);
  background: var(--cb-frame-plain, none), var(--planks, linear-gradient(#4e2f17, #37200f));
  box-shadow: var(--wood-edge, 0 0 0 1px #e2bb6880), 0 18px 50px rgba(0, 0, 0, 0.6), inset 0 0 0 1px var(--jn-inlay-3, rgba(226, 187, 104, 0.24));
  animation: ncIn 0.22s cubic-bezier(0.2, 1.2, 0.4, 1);
}
#newConfirm h2 { margin: 0 0 10px; font-family: var(--jn-title, Georgia, serif); font-size: 1.5rem; color: var(--jn-cream, #f8efdc); font-weight: 600; }
#newConfirm p { margin: 0 0 18px; color: var(--jn-sheet, #f1e6cd); font-size: 1rem; line-height: 1.4; }
#newConfirm p b { color: var(--jn-inlay, #e2bb68); }
#newConfirm .ncBtns { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
#newConfirm .ncBtns button { min-width: 170px; }
html.cab body #newConfirm .ncBtns button.ncDanger { color: #ffd9cc !important; box-shadow: inset 0 0 0 1px rgba(255, 138, 106, 0.55) !important; }
html.cab body #newConfirm .ncBtns button.ncDanger:hover, html.cab body #newConfirm .ncBtns button.ncDanger:focus-visible { background-color: var(--jn-red, #8a2414) !important; color: #fff !important; }
html.calm #newConfirm .ncBox { animation: none; }
@keyframes ncIn { from { opacity: 0; transform: translateY(10px) scale(0.97); } to { opacity: 1; transform: none; } }

