/* StarExplorer Web 0.19.02b — układ „Centrum dowodzenia” (Jakub t284u–t287u):
   górny pasek z chipami statystyk, lewa szyna ikon (menu), plansza przybliżona 1,8× z przeciąganiem i strzałkami na ramce HUD,
   prawa wysuwana szuflada (kontekst + dziennik zdarzeń). Ładowany PO desktop.css; klasy lx/lx-c na <html>, lxc-cam/lxc-s1 z desktop.js.
   Prototyp i warianty: /workspace/game-new/design/web-layouts/ */
/* PROTOTYP układów (Jakub t284u) — wspólne: ikony menu, marka, szkło. Ładowany przez layout-a/b/c.css */
#dx-tl { display: none !important; }
html.lx body .menu-button::before {
  content: ""; display: block; width: 22px; height: 22px; margin: 0 auto 4px; flex: none;
  background-color: currentColor; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat;
}
html.lx body .menu-button:nth-child(1) { --ic: url(icons/ship.svg); }
html.lx body .menu-button:nth-child(2) { --ic: url(icons/character.svg); }
html.lx body .menu-button:nth-child(3) { --ic: url(icons/cargo.svg); }
html.lx body .menu-button:nth-child(4) { --ic: url(icons/discoveries.svg); }
html.lx body .menu-button:nth-child(5) { --ic: url(icons/options.svg); }
html.lx body .menu-button:nth-child(6) { --ic: url(icons/computer.svg); }
html.lx body .menu-button:nth-child(7) { --ic: url(icons/lore.svg); }
html.lx body .menu-button:nth-child(8) { --ic: url(icons/journal.svg); }
html.lx body .menu-button:nth-child(9) { --ic: url(icons/missions.svg); }
html.lx body .menu-button:nth-child(10) { --ic: url(icons/fullscreen.svg); }
html.lx body .game-container .top-row > .column:nth-child(1)::before {
  content: "STAREXPLORER"; display: block !important; position: static !important; width: auto !important; height: auto !important; inset: auto !important; background: none !important; border: 0 !important; box-shadow: none !important; flex: none !important; margin-left: 4px; font-size: 15px; letter-spacing: .24em; color: #00ff00; text-shadow: 0 0 8px rgba(0,255,0,.65); white-space: nowrap;
}
html.lx body .game-container .top-row > .column:nth-child(1) { justify-content: center; }
:root { --lx-glass: rgba(0, 14, 0, .72); --lx-edge: rgba(0, 255, 0, .34); --lx-soft: 0 0 18px rgba(0,255,0,.10), inset 0 0 22px rgba(0,255,0,.05); }
/* dziennik: przewijanie wpisów nie może przesuwać całej ramki (scrollIntoView) */
html.lx body .game-container .bottom-row > .column:nth-child(1) { overflow: clip !important; }
/* pseudo-elementy kolumn mają w index.html animację „scanline” (translateY) — napisy muszą stać w miejscu */
html.lx body .game-container .top-row > .column:nth-child(1)::before,
html.lx body .game-container .bottom-row > .column:nth-child(1)::before,
html.lx body .game-container .bottom-row > .column:nth-child(3)::before { animation: none !important; transform: none !important; pointer-events: none; }
html.lx body .game-container .bottom-row > .column:nth-child(1) { justify-content: flex-start !important; }

/* ===== WARIANT C — „Centrum dowodzenia”: górny pasek ze wszystkimi statystykami jako chipy, lewa szyna ikon (menu),
   plansza na środku, prawa wysuwana szuflada (kontekst + dziennik), chowana przyciskiem lub Tab. ===== */
html.lx-c body .game-container {
  grid-template-columns: 82px minmax(0, 1fr) 340px !important;
  grid-template-rows: 56px minmax(0, 1fr) 210px 30px !important;
  grid-template-areas: none !important; background: #000 !important; transition: grid-template-columns .2s;
}
html.lx-c body .game-container .column { border-color: rgba(0,255,0,.24) !important; box-shadow: none !important; }
/* górny pasek */
html.lx-c body .game-container .top-row > .column:nth-child(1) { display: flex !important; grid-column: 1 / -1 !important; grid-row: 1 !important; padding: 0 18px !important; align-items: flex-start !important; background: linear-gradient(180deg, #021a02, #000) !important; border-width: 0 0 1px 0 !important; border-color: rgba(0,255,0,.45) !important; }
html.lx-c body .game-container .middle-row > .column:nth-child(1) {
  grid-column: 1 / -1 !important; grid-row: 1 !important; z-index: 2; justify-self: center; align-self: center; width: auto !important;
  padding: 0 !important; border: 0 !important; background: transparent !important; overflow: visible !important;
}
html.lx-c body .left-column-content.hx { flex-direction: row !important; align-items: center !important; gap: 8px !important; }
html.lx-c body .hx .hx-g { width: auto !important; min-height: 34px !important; padding: 3px 10px !important; gap: 8px !important; border-radius: 17px !important; background: #001500 !important; border-color: rgba(0,255,0,.35) !important; flex-direction: row !important; align-items: center !important; }
html.lx-c body .hx .hx-meter .hx-l { align-self: center !important; }
html.lx-c body .hx .hx-meter .hx-bar, html.lx-c body .hx .hx-xp .hx-bar { width: 112px !important; height: 15px !important; }
html.lx-c body .hx .hx-l { font-size: 11px !important; }
html.lx-c body .hx .hx-xp { order: 2; }
html.lx-c body .hx .hx-lvl .hx-full, html.lx-c body .hx .hx-xp .hx-l { white-space: nowrap; }
html.lx-c body .cargo-miniature { display: none !important; }
html.lx-c body .game-container .top-row > .column:nth-child(3) { grid-column: 3 !important; grid-row: 1 !important; z-index: 3; display: none !important; }
/* lewa szyna ikon */
html.lx-c body .game-container .bottom-row > .column.game-area { grid-column: 1 !important; grid-row: 2 / 5 !important; padding: 10px 7px !important; border-width: 0 1px 0 0 !important; background: #010901 !important; justify-content: flex-start !important; }
html.lx-c body .menu-buttons { display: flex !important; flex-direction: column; gap: 6px !important; height: auto !important; }
html.lx-c body .menu-button { height: 56px !important; flex: none !important; display: flex !important; flex-direction: column; align-items: center; justify-content: center; font-size: 8.5px !important; letter-spacing: .02em !important; padding: 2px 2px !important; border-radius: 10px; background: transparent !important; border: 1px solid transparent !important; white-space: normal; text-align: center; line-height: 1.05; }
html.lx-c body .menu-button:hover { background: #002a00 !important; border-color: rgba(0,255,0,.45) !important; }
html.lx-c body .menu-button.dx-active { background: #00ff00 !important; box-shadow: 0 0 14px rgba(0,255,0,.6) !important; }
html.lx-c body .menu-button::before { width: 22px; height: 22px; margin-bottom: 4px; }
html.lx-c body .menu-button .dx-k { left: 5px; top: 3px; }
/* plansza */
html.lx-c body .game-container .middle-row > .column.game-area { grid-column: 2 !important; grid-row: 2 / 4 !important; border: 0 !important; padding: 10px !important;
  background: repeating-linear-gradient(0deg, rgba(0,255,0,.035) 0 1px, transparent 1px 40px), repeating-linear-gradient(90deg, rgba(0,255,0,.035) 0 1px, transparent 1px 40px), #000 !important; }
html.lx-c body .middle-row > .column.game-area .board { box-shadow: 0 0 0 1px rgba(0,255,0,.32); }
/* stopka pod planszą: układ + wersja */
html.lx-c body .game-container .top-row > .column:nth-child(2) { grid-column: 2 !important; grid-row: 4 !important; padding: 0 12px !important; align-items: center !important; border-width: 1px 0 0 0 !important; background: #010901 !important; }
html.lx-c body .system-info { font-size: 11px !important; letter-spacing: .24em; justify-content: flex-start !important; width: 100%; }
html.lx-c body .game-container .bottom-row > .column:nth-child(3) { grid-column: 2 !important; grid-row: 4 !important; justify-self: end; width: auto !important; border: 0 !important; background: transparent !important; padding: 0 12px !important; z-index: 2; }
html.lx-c body .version-info { flex-direction: row !important; gap: 8px; }
html.lx-c body .version-info::after { margin: 0 !important; }
html.lx-c body .version-info p { font-size: 11px !important; }
/* szuflada: kontekst + dziennik */
html.lx-c body .game-container .middle-row > .column:nth-child(3) { grid-column: 3 !important; grid-row: 2 !important; padding: 12px 14px !important; border-width: 0 0 0 1px !important; background: #000 !important; }
html.lx-c body .game-container .bottom-row > .column:nth-child(1) { grid-column: 3 !important; grid-row: 3 / 5 !important; border-width: 1px 0 0 1px !important; background: #010901 !important; }
html.lx-c body .middle-row > .column:nth-child(3) .sensors-active { opacity: .7; }
html.lx-c.lx-sel body .game-container .middle-row > .column:nth-child(3) { box-shadow: inset 3px 0 0 #00ff00 !important; }
/* ekrany */
html.lx-c body .game-container .middle-row > .column.game-area > .screen-container,
html.lx-c body .game-container .middle-row > .column.game-area > div:not(.board-container):not(.se-mis-hud):not(.se-mis-pop) { max-width: 780px !important; width: 100% !important; margin: 0 auto !important; }

/* ===== C + kamera (Jakub t286u): przybliżona plansza, przeciąganie, strzałki na ramce. ?layout=c&arrows=1|2|3 ===== */
html.lxc-cam body .game-container .middle-row > .column.game-area:has(.board) { padding: 30px !important; }
html.lxc-cam body .game-container .middle-row > .column.game-area > .board-container { cursor: grab; touch-action: none; }
html.lxc-cam.lxc-dragging body, html.lxc-cam.lxc-dragging body .board .cell { cursor: grabbing !important; }
html.lxc-cam.lxc-dragging body .board .cell:hover { box-shadow: none !important; filter: none !important; }
html.lxc-cam body .board-container.lxc-anim .board { transition: left .3s cubic-bezier(.2,.7,.2,1), top .3s cubic-bezier(.2,.7,.2,1); }
html.lxc-cam body .middle-row > .column.game-area .board { box-shadow: none !important; }
html.lxc-cam body .se-mis-hud { top: 3px !important; left: 44px !important; z-index: 7; }
html.lxc-cam body .se-mis-pop { top: 32px !important; left: 44px !important; z-index: 8; }
html.lxc-cam body .game-container:not(:has(.board)) .lxc-ov { display: none; }
.lxc-ov { position: absolute; inset: 0; pointer-events: none; z-index: 6; }
.lxc-ov .lxc-frame { position: absolute; left: var(--vx); top: var(--vy); width: var(--vw); height: var(--vh); box-sizing: border-box; }
.lxc-ov .lxc-frame .c { position: absolute; width: 0; height: 0; }
.lxc-arr {
  position: absolute; pointer-events: auto; cursor: pointer; padding: 0; margin: 0; font: inherit; color: #00ff00; background: none; border: 0;
  display: flex; align-items: center; justify-content: center; transition: opacity .2s, box-shadow .15s, background .15s, filter .15s;
  --rot: 0deg; --off: 15px;
}
.lxc-arr.lxc-u { left: calc(var(--vx) + var(--vw) / 2); top: calc(var(--vy) - var(--off)); --rot: 0deg; }
.lxc-arr.lxc-d { left: calc(var(--vx) + var(--vw) / 2); top: calc(var(--vy) + var(--vh) + var(--off)); --rot: 180deg; }
.lxc-arr.lxc-l { left: calc(var(--vx) - var(--off)); top: calc(var(--vy) + var(--vh) / 2); --rot: -90deg; }
.lxc-arr.lxc-r { left: calc(var(--vx) + var(--vw) + var(--off)); top: calc(var(--vy) + var(--vh) / 2); --rot: 90deg; }
.lxc-arr { transform: translate(-50%, -50%) rotate(var(--rot)); }
.lxc-ov:not(.can-u) .lxc-u, .lxc-ov:not(.can-d) .lxc-d, .lxc-ov:not(.can-l) .lxc-l, .lxc-ov:not(.can-r) .lxc-r { opacity: .14; pointer-events: none; filter: grayscale(1); }
.lxc-arr .g { display: block; position: absolute; }

/* ---------- 1: ramka HUD z klamrami + cienkie szewrony w kapsułach na środku boków ---------- */
.lxc-s1 .lxc-ov .lxc-frame { inset: auto; left: calc(var(--vx) - 7px); top: calc(var(--vy) - 7px); width: calc(var(--vw) + 14px); height: calc(var(--vh) + 14px);
  border: 1px solid rgba(0,255,0,.38); border-radius: 4px; box-shadow: 0 0 10px rgba(0,255,0,.18), inset 0 0 14px rgba(0,255,0,.10); }
.lxc-s1 .lxc-ov .lxc-frame .c { width: 26px; height: 26px; border: 0 solid #00ff00; filter: drop-shadow(0 0 4px rgba(0,255,0,.8)); }
.lxc-s1 .lxc-ov .lxc-frame .tl { left: -2px; top: -2px; border-width: 2px 0 0 2px; }
.lxc-s1 .lxc-ov .lxc-frame .tr { right: -2px; top: -2px; border-width: 2px 2px 0 0; }
.lxc-s1 .lxc-ov .lxc-frame .bl { left: -2px; bottom: -2px; border-width: 0 0 2px 2px; }
.lxc-s1 .lxc-ov .lxc-frame .br { right: -2px; bottom: -2px; border-width: 0 2px 2px 0; }
.lxc-s1 .lxc-arr { --off: 7px; width: 74px; height: 20px; background: #000; border: 1px solid rgba(0,255,0,.6); border-radius: 10px; box-shadow: 0 0 8px rgba(0,255,0,.25); }
.lxc-s1 .lxc-arr .g { width: 8px; height: 8px; border: 0 solid currentColor; border-width: 1.6px 0 0 1.6px; transform: rotate(45deg); top: 7px; left: calc(50% - 5px); }
.lxc-s1 .lxc-arr .g2 { top: 11px; opacity: .45; }
.lxc-s1 .lxc-arr::before, .lxc-s1 .lxc-arr::after { content: ""; position: absolute; top: 50%; width: 16px; height: 1px; background: rgba(0,255,0,.55); }
.lxc-s1 .lxc-arr::before { left: 8px; } .lxc-s1 .lxc-arr::after { right: 8px; }
.lxc-s1 .lxc-arr:hover { background: #003a00; border-color: #00ff00; box-shadow: 0 0 16px rgba(0,255,0,.75); color: #c8ffc8; }
.lxc-s1 .lxc-arr:hover .g { top: 5px; } .lxc-s1 .lxc-arr:hover .g2 { top: 10px; opacity: .9; }


/* ===== 0.19.02b: czytelna szyna także w 1280×720 (min. 12 px na ekranie; przy 1920×1080 ≈ 14 px) ===== */
html.lx-c body .game-container { grid-template-columns: 92px minmax(0, 1fr) 340px !important; }
html.lx-c body .menu-button {
  font-size: max(9.5px, calc(12px / var(--dx-zoom, 1))) !important; letter-spacing: 0 !important; line-height: 1.08 !important;
  min-height: 54px !important; height: auto !important; padding: 4px 2px !important; hyphens: auto; overflow-wrap: break-word; word-break: normal;
}
html.lx-c body .bottom-row > .column.game-area { overflow-y: auto !important; overflow-x: hidden !important; }
html.lx-c body .menu-buttons { gap: 4px !important; }
/* długie pojedyncze słowa (es „DESCUBRIMIENTOS”, de „ENTDECKUNGEN”, uk „НАЛАШТУВАННЯ”) mieszczą się w szynie przy 12 px */
html.lx-c body .game-container { grid-template-columns: 104px minmax(0, 1fr) 340px !important; }
html.lx-c body .game-container .bottom-row > .column.game-area { padding: 8px 5px !important; }
html.lx-c body .menu-button { padding: 4px 1px !important; }

/* ===== 0.19.02b (Jakub t288u) ===== */
/* strzałki przewijania (styl 1) o połowę mniejsze — ten sam wygląd: kapsuła, dwa szewrony, boczne kreski, hover */
.lxc-s1 .lxc-arr { --off: 5px; width: 37px; height: 11px; border-radius: 6px; box-shadow: 0 0 5px rgba(0,255,0,.25); }
.lxc-s1 .lxc-arr .g { width: 4px; height: 4px; border-width: 1.2px 0 0 1.2px; top: 3.5px; left: calc(50% - 2.6px); }
.lxc-s1 .lxc-arr .g2 { top: 5.6px; }
.lxc-s1 .lxc-arr::before, .lxc-s1 .lxc-arr::after { width: 8px; }
.lxc-s1 .lxc-arr::before { left: 4px; } .lxc-s1 .lxc-arr::after { right: 4px; }
.lxc-s1 .lxc-arr:hover { box-shadow: 0 0 9px rgba(0,255,0,.75); }
.lxc-s1 .lxc-arr:hover .g { top: 2.5px; } .lxc-s1 .lxc-arr:hover .g2 { top: 5px; }
/* minimalne przybliżenie (cała plansza na ekranie): strzałki chowane */
.lxc-ov.lxc-fit .lxc-arr { opacity: 0 !important; pointer-events: none !important; }

/* trafienie: klatka wybuchu NAD wrogiem w tym samym polu — bez przesuwania ikony (notes-explosion-fix.md) */
.enemy-container > .se-enemy-icon { position: relative; z-index: 1; flex: 0 0 auto; }
html body .board .cell .enemy-container > img.se-hit-fx {
  position: absolute !important; left: 50% !important; top: 50% !important; right: auto !important; bottom: auto !important;
  width: 72% !important; height: 72% !important; max-width: none !important; max-height: none !important; margin: 0 !important;
  transform: translate(-50%, -50%); object-fit: contain; pointer-events: none; z-index: 4;
  animation: seHitFx .5s ease-out forwards;
}
@keyframes seHitFx {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(.45); }
  22% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: .15; transform: translate(-50%, -50%) scale(1.12); }
}

/* karta Statek / Postać: Statystyki i rozdawanie punktów obok siebie (jedna kolumna tylko, gdy naprawdę za wąsko) */
html.lx-c body .screen-container.se-card { container-type: inline-size; }
@container (min-width: 640px) {
  html.lx-c body .se-card .se-card-content { max-width: none !important; display: grid !important; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 16px; align-items: start; }
  html.lx-c body .se-card .se-card-content > * { grid-column: 1 / -1; }
  html.lx-c body .se-card .se-card-content > .se-card-stats { grid-column: 1; margin-top: 10px; }
  html.lx-c body .se-card .se-card-content > .se-allocation { grid-column: 2; margin-top: 10px; border-top: 0; padding-top: 0; }
  html.lx-c body .se-card .se-card-content > .se-allocation h3 { margin-top: 0; }
  html.lx-c body .se-card .se-card-content > .se-card-back { justify-self: center; }
}
