:root {
  --bg: #181425; --bg2: #262b44; --line: #3a4466; --line2: #5a6988; --text: #ead4aa; --dim: #8b9bb4;
  --gold: #feae34; --gold2: #fee761; --red: #e43b44; --green: #63c74d; --blue: #0099db; --purple: #b55088; --cyan: #2ce8f5;
  --font: "Trebuchet MS", "Segoe UI", Tahoma, sans-serif;
  --title: Georgia, "Palatino Linotype", "Book Antiqua", serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; width: 100%; height: 100%; overflow: hidden; background: #0c0a18; color: var(--text); font-family: var(--font); user-select: none; -webkit-user-select: none; }
canvas#game { position: fixed; inset: 0; display: block; image-rendering: pixelated; image-rendering: crisp-edges; cursor: crosshair; }
img.px, canvas.px { image-rendering: pixelated; image-rendering: crisp-edges; }
.hidden { display: none !important; }
.dim { color: var(--dim); font-weight: normal; }

.panel {
  background: rgba(24, 20, 37, 0.88);
  border: 3px solid var(--line);
  box-shadow: inset 0 0 0 2px #0c0a18, 0 0 0 2px #0c0a18, 4px 4px 0 rgba(0,0,0,0.35);
  padding: 8px 10px;
  border-radius: 2px;
}
.btn {
  font-family: var(--font); font-weight: bold; font-size: 15px; color: var(--text);
  background: #3a4466; border: 2px solid #0c0a18; box-shadow: inset 0 -3px 0 #262b44, inset 0 2px 0 #5a6988;
  padding: 7px 14px; cursor: pointer; border-radius: 2px; transition: transform 0.05s;
}
.btn:hover { background: #4a5680; color: #fff; }
.btn:active { transform: translateY(1px); box-shadow: inset 0 -1px 0 #262b44, inset 0 2px 0 #5a6988; }
.btn.gold { background: #a8642a; box-shadow: inset 0 -3px 0 #733e39, inset 0 2px 0 #feae34; color: #fff; }
.btn.gold:hover { background: #c47a34; }
.btn.red { background: #8a2430; box-shadow: inset 0 -3px 0 #5a1420, inset 0 2px 0 #e43b44; }
.btn.green { background: #2f6e3a; box-shadow: inset 0 -3px 0 #1d4425, inset 0 2px 0 #63c74d; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; filter: grayscale(0.6); }
.btn.small { font-size: 12px; padding: 4px 8px; }
.bar { position: relative; height: 10px; background: #0c0a18; border: 2px solid #0c0a18; box-shadow: 0 0 0 1px var(--line); }
.bar .fill { height: 100%; background: var(--gold); width: 50%; transition: width 0.15s; }
.bar.big { height: 14px; }

#hud > * { pointer-events: none; }
#hud .panel, #hud button, #hud canvas, #buildbar, #buildbar * { pointer-events: auto; }
#hud #toasts, #hud #toasts *, #hud #hint, #hud #center-msg { pointer-events: none !important; }

/* lewa góra */
#top-left { position: fixed; left: 10px; top: 10px; display: flex; flex-direction: column; gap: 8px; width: 230px; }
#res-panel { display: grid; grid-template-columns: 1fr 1fr; gap: 3px 10px; }
.res { display: flex; align-items: center; gap: 6px; font-weight: bold; font-size: 16px; text-shadow: 2px 2px 0 #0c0a18; }
.res img { width: 22px; height: 20px; image-rendering: pixelated; }
.res.flash { animation: flash 0.4s; }
@keyframes flash { 0% { color: #fff; transform: scale(1.15); } 100% { transform: scale(1); } }
#objective .obj-head { color: var(--gold); font-family: var(--title); font-weight: bold; font-size: 13px; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 2px; }
#obj-text { font-size: 13px; line-height: 1.35; }

/* fala */
#top-center { position: fixed; left: 50%; top: 10px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; width: 360px; }
#wave-panel { width: 100%; text-align: center; }
#wave-title { font-family: var(--title); font-size: 20px; font-weight: bold; color: var(--gold2); text-shadow: 2px 2px 0 #0c0a18; }
#wave-panel.night #wave-title { color: #f6757a; }
#wave-timer { font-size: 14px; margin: 2px 0 4px; }
#wave-timer b { font-size: 18px; color: #fff; }
#wave-info { font-size: 12px; color: var(--dim); margin: 4px 0; min-height: 14px; }
#wave-panel.night .bar .fill { background: var(--red); }
#core-row { display: flex; align-items: center; gap: 6px; font-size: 12px; margin: 2px 0 6px; color: var(--gold); font-weight: bold; }
#core-row .bar { flex: 1; height: 8px; }
#core-fill { background: linear-gradient(#feae34, #f77622) !important; }
#core-row.hurt { color: #ff7a80; animation: blink 0.6s infinite; }
#core-text { min-width: 70px; text-align: right; color: var(--text); }
#boss-bar { width: 100%; text-align: center; }
#boss-name { font-family: var(--title); font-weight: bold; color: #f6757a; margin-bottom: 4px; }
#boss-fill { background: linear-gradient(#ff0044, #a22633); }
#toasts { display: flex; flex-direction: column; align-items: center; gap: 4px; width: 520px; }
.toast { background: rgba(24,20,37,0.9); border: 2px solid var(--line); padding: 5px 12px; font-size: 14px; animation: toastIn 0.25s; text-align: center; text-shadow: 1px 1px 0 #000; }
.toast.bad { border-color: var(--red); color: #ffb0b0; }
.toast.good { border-color: var(--green); color: #c8ffb0; }
.toast.warn { border-color: var(--gold); color: var(--gold2); }
.toast.out { opacity: 0; transition: opacity 0.6s; }
@keyframes toastIn { from { transform: translateY(-8px); opacity: 0; } to { transform: none; opacity: 1; } }

/* prawa strona */
#right-panel { position: fixed; right: 10px; top: 10px; display: flex; flex-direction: column; gap: 8px; width: 214px; }
#minimap-wrap { padding: 6px; }
#minimap { width: 196px; height: 196px; image-rendering: pixelated; display: block; cursor: pointer; background: #0c0a18; }
#mm-legend { font-size: 11px; color: var(--dim); margin-top: 4px; text-align: center; }
.lg.core { color: var(--gold); } .lg.rift { color: #ff0044; } .lg.shrine { color: var(--gold2); }
#keys { font-size: 11px; color: var(--dim); line-height: 1.5; }
#keys b { color: var(--text); }

/* gracz */
#bottom-left { position: fixed; left: 10px; bottom: 10px; width: 300px; display: flex; flex-direction: column; gap: 6px; }
#player-panel { width: 100%; }
.hp-row { display: flex; align-items: center; gap: 8px; }
.hp-row img { width: 24px; height: 24px; image-rendering: pixelated; }
.bar.hp { flex: 1; height: 18px; }
#hp-fill { background: linear-gradient(#e43b44, #a22633); }
#hp-text { position: absolute; inset: 0; text-align: center; font-size: 12px; font-weight: bold; line-height: 14px; text-shadow: 1px 1px 0 #000; }
#equip-row { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.eq { display: flex; align-items: center; gap: 3px; font-size: 12px; background: #262b44; padding: 2px 6px 2px 3px; border: 1px solid #3a4466; }
.eq img { width: 24px; height: 24px; image-rendering: pixelated; }
.eq.shard img { width: 18px; height: 20px; }

/* budowa */
#bottom-center { position: fixed; left: 50%; bottom: 10px; transform: translateX(-50%); display: flex; flex-direction: column; align-items: center; gap: 6px; }
#hint { background: rgba(24,20,37,0.92); border: 2px solid var(--gold); padding: 5px 14px; font-weight: bold; font-size: 14px; color: var(--gold2); }
#buildbar { display: flex; flex-direction: column; gap: 5px; padding: 6px 8px; }
#mode-row { display: flex; gap: 4px; justify-content: center; }
.mode { display: flex; align-items: center; gap: 4px; font-size: 12px; font-weight: bold; padding: 3px 8px; background: #262b44; border: 2px solid #0c0a18; cursor: pointer; color: var(--text); }
.mode img { width: 20px; height: 20px; image-rendering: pixelated; }
.mode.on { background: #a8642a; color: #fff; }
.mode:hover { background: #3a4466; }
#build-tabs { display: flex; gap: 3px; justify-content: center; }
.tab { font-size: 12px; font-weight: bold; padding: 3px 10px; background: #262b44; border: 2px solid #0c0a18; cursor: pointer; color: var(--dim); }
.tab.on { color: var(--gold2); background: #3a4466; }
#build-slots { display: flex; gap: 4px; justify-content: center; min-height: 58px; }
.slot { position: relative; width: 54px; height: 58px; background: #262b44; border: 2px solid #0c0a18; box-shadow: inset 0 0 0 1px #3a4466; cursor: pointer; display: flex; align-items: flex-end; justify-content: center; padding-bottom: 3px; }
.slot:hover { background: #3a4466; }
.slot.on { box-shadow: inset 0 0 0 2px var(--gold2); background: #4a3a2a; }
.slot img { image-rendering: pixelated; max-width: 48px; max-height: 52px; }
.slot .key { position: absolute; left: 3px; top: 1px; font-size: 11px; font-weight: bold; color: var(--gold2); text-shadow: 1px 1px 0 #000; }
.slot.poor img { opacity: 0.55; }
.slot.locked img { filter: grayscale(1) brightness(0.45); }
.slot .lock { position: absolute; right: 2px; top: 2px; width: 16px; }

/* tooltip */
#tooltip { position: fixed; z-index: 80; pointer-events: none; max-width: 300px; background: rgba(24,20,37,0.96); border: 2px solid var(--line2); padding: 7px 10px; font-size: 13px; line-height: 1.4; box-shadow: 3px 3px 0 rgba(0,0,0,0.4); }
#tooltip .tt-title { font-weight: bold; color: var(--gold2); font-size: 14px; }
#tooltip .tt-cost { margin-top: 3px; }
#tooltip .ok { color: #9be35d; } #tooltip .no { color: #ff7a80; }
#tooltip .tt-desc { color: var(--text); margin-top: 3px; }
#tooltip .tt-lock { color: #ff7a80; margin-top: 3px; }
.cost-item { display: inline-flex; align-items: center; gap: 2px; margin-right: 7px; font-weight: bold; }
.cost-item img { width: 16px; height: 15px; image-rendering: pixelated; }
.cost-item.no { color: #ff7a80; }

/* dialog */
#dialog { position: fixed; left: 50%; bottom: 120px; transform: translateX(-50%); width: min(760px, 92vw); display: flex; gap: 14px; background: rgba(24,20,37,0.96); border: 3px solid var(--gold); box-shadow: inset 0 0 0 2px #0c0a18, 0 0 0 2px #0c0a18, 6px 6px 0 rgba(0,0,0,0.4); padding: 12px; z-index: 40; cursor: pointer; animation: toastIn 0.2s; }
.dlg-portrait-wrap { flex: none; width: 108px; height: 108px; border: 3px solid var(--line); background: #0c0a18; }
#dlg-portrait { width: 102px; height: 102px; image-rendering: pixelated; }
.dlg-body { flex: 1; display: flex; flex-direction: column; }
#dlg-name { font-family: var(--title); font-weight: bold; font-size: 18px; color: var(--gold2); margin-bottom: 4px; }
#dialog.varn #dlg-name { color: #f6757a; } #dialog.varn { border-color: #b55088; }
#dialog.lore #dlg-name { color: var(--cyan); } #dialog.lore { border-color: var(--cyan); }
#dlg-text { font-size: 16px; line-height: 1.45; flex: 1; white-space: pre-wrap; }
#dlg-next { align-self: flex-end; font-size: 12px; color: var(--dim); animation: blink 1s infinite; }
@keyframes blink { 50% { opacity: 0.3; } }

/* modal */
#modal { position: fixed; inset: 0; background: rgba(8,6,16,0.6); display: flex; align-items: center; justify-content: center; z-index: 65; }
#modal-box { width: min(980px, 96vw); max-height: 92vh; display: flex; flex-direction: column; padding: 0; }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 14px; border-bottom: 3px solid var(--line); background: #262b44; }
#modal-title { font-family: var(--title); font-size: 22px; font-weight: bold; color: var(--gold2); text-shadow: 2px 2px 0 #0c0a18; }
#modal-body { padding: 14px; overflow: auto; }
.mtabs { display: flex; gap: 4px; margin-bottom: 12px; }
.mtabs .tab { font-size: 14px; padding: 6px 14px; }

/* drzewko technologii */
.tech-wrap { position: relative; height: 470px; min-width: 860px; }
.tech-wrap svg { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.tnode { position: absolute; width: 190px; height: 62px; background: #262b44; border: 2px solid #0c0a18; box-shadow: inset 0 0 0 2px #3a4466; padding: 5px 8px; cursor: pointer; font-size: 13px; }
.tnode .tn-name { font-weight: bold; font-size: 14px; }
.tnode .tn-cost { display: flex; align-items: center; gap: 4px; margin-top: 3px; font-weight: bold; color: #f6757a; }
.tnode .tn-cost img { width: 16px; height: 16px; image-rendering: pixelated; }
.tnode.done { box-shadow: inset 0 0 0 2px var(--green); background: #1f3d2a; }
.tnode.done .tn-cost { color: var(--green); }
.tnode.avail { box-shadow: inset 0 0 0 2px var(--gold); }
.tnode.avail:hover { background: #3a4466; }
.tnode.poor { box-shadow: inset 0 0 0 2px #8a6a3a; }
.tnode.locked { opacity: 0.5; }
.tech-info { margin-top: 10px; min-height: 44px; font-size: 14px; color: var(--text); border-top: 2px solid var(--line); padding-top: 8px; }

/* odłamki */
.shards-grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 10px; margin-bottom: 14px; }
.shard-card { background: #262b44; border: 2px solid #0c0a18; box-shadow: inset 0 0 0 2px #3a4466; padding: 10px; text-align: center; font-size: 13px; min-height: 150px; }
.shard-card img { width: 36px; height: 40px; image-rendering: pixelated; margin: 4px 0; }
.shard-card.placed { box-shadow: inset 0 0 0 2px var(--gold); background: #3d3020; }
.shard-card.carried { box-shadow: inset 0 0 0 2px var(--green); }
.shard-card.missing img { filter: brightness(0) opacity(0.4); }
.shard-card .sc-name { font-weight: bold; color: var(--gold2); }
.big-action { text-align: center; margin: 10px 0; }
.big-action .btn { font-size: 18px; padding: 12px 28px; }

/* kuźnia, handel */
.rows { display: flex; flex-direction: column; gap: 8px; }
.row { display: flex; align-items: center; gap: 12px; background: #262b44; border: 2px solid #0c0a18; box-shadow: inset 0 0 0 1px #3a4466; padding: 8px 10px; }
.row img.ico { width: 36px; height: 36px; image-rendering: pixelated; }
.row .r-main { flex: 1; }
.row .r-title { font-weight: bold; font-size: 15px; }
.row .r-sub { font-size: 13px; color: var(--dim); margin-top: 2px; }
.row .r-next { font-size: 13px; margin-top: 3px; }
.trade-arrow { font-size: 20px; color: var(--gold); }

/* ekrany */
#screen { position: fixed; inset: 0; z-index: 60; display: flex; align-items: center; justify-content: center; flex-direction: column; background: radial-gradient(ellipse at center, rgba(40,20,50,0.55), rgba(8,6,16,0.95)); }
.menu-title { font-family: var(--title); font-size: clamp(42px, 7vw, 88px); font-weight: bold; color: var(--gold2); text-shadow: 4px 4px 0 #a22633, 8px 8px 0 #0c0a18; letter-spacing: 3px; text-align: center; }
.menu-sub { font-family: var(--title); font-style: italic; color: var(--text); font-size: 18px; margin: 6px 0 28px; text-align: center; }
.menu-btns { display: flex; flex-direction: column; gap: 10px; width: 300px; }
.menu-btns .btn { font-size: 18px; padding: 11px; }
.menu-foot { position: absolute; bottom: 14px; color: var(--dim); font-size: 12px; text-align: center; width: 100%; }
.newgame { width: min(520px, 92vw); }
.newgame label { display: block; font-weight: bold; margin: 10px 0 4px; }
.newgame input[type=text] { width: 100%; font: bold 16px var(--font); background: #0c0a18; color: var(--text); border: 2px solid var(--line); padding: 7px; }
.diff-row { display: flex; gap: 6px; }
.diff { flex: 1; background: #262b44; border: 2px solid #0c0a18; box-shadow: inset 0 0 0 2px #3a4466; padding: 8px; cursor: pointer; text-align: center; }
.diff.on { box-shadow: inset 0 0 0 2px var(--gold); background: #3d3020; }
.diff b { display: block; font-size: 15px; } .diff span { font-size: 12px; color: var(--dim); }
.intro-text { max-width: 760px; font-family: var(--title); font-size: clamp(18px, 2.2vw, 26px); line-height: 1.6; text-align: center; padding: 20px; white-space: pre-wrap; text-shadow: 2px 2px 0 #000; animation: fadeIn 1.2s; }
.intro-hint { margin-top: 30px; color: var(--dim); font-size: 14px; animation: blink 1.4s infinite; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.end-title { font-family: var(--title); font-size: clamp(36px, 5vw, 64px); color: var(--gold2); text-shadow: 3px 3px 0 #a22633, 6px 6px 0 #0c0a18; margin-bottom: 14px; text-align: center; }
.stats { display: grid; grid-template-columns: auto auto; gap: 4px 24px; margin: 16px 0; font-size: 15px; background: rgba(24,20,37,0.9); border: 3px solid var(--line); box-shadow: 0 0 0 2px #0c0a18; padding: 10px 18px; }
.stats b { color: var(--gold2); text-align: right; }
.choice-row { display: flex; gap: 20px; margin-top: 20px; flex-wrap: wrap; justify-content: center; }
.choice { width: 300px; background: #262b44; border: 3px solid var(--line); padding: 16px; cursor: pointer; text-align: center; }
.choice:hover { border-color: var(--gold); background: #3a4466; }
.choice b { display: block; font-family: var(--title); font-size: 20px; color: var(--gold2); margin-bottom: 6px; }
.help { font-size: 14px; line-height: 1.55; max-width: 860px; }
.help h3 { color: var(--gold2); font-family: var(--title); margin: 12px 0 4px; }
.help kbd { background: #3a4466; border: 1px solid #0c0a18; padding: 0 5px; font-family: var(--font); font-weight: bold; }
.settings label { display: flex; align-items: center; gap: 10px; margin: 8px 0; }
.settings input[type=range] { width: 220px; }

/* baner */
#banner { position: fixed; left: 0; right: 0; top: 30%; text-align: center; z-index: 25; pointer-events: none; animation: bannerIn 0.6s; }
#banner-title { font-family: var(--title); font-size: clamp(40px, 6vw, 76px); font-weight: bold; color: var(--gold2); text-shadow: 4px 4px 0 #a22633, 7px 7px 0 #0c0a18; letter-spacing: 4px; text-transform: uppercase; }
#banner-sub { font-size: 18px; margin-top: 6px; text-shadow: 2px 2px 0 #000; }
#banner.night #banner-title { color: #f6757a; text-shadow: 4px 4px 0 #3e2731, 7px 7px 0 #0c0a18; }
#banner.out { opacity: 0; transition: opacity 1s; }
@keyframes bannerIn { from { transform: scale(1.3); opacity: 0; } to { transform: none; opacity: 1; } }

#center-msg { position: fixed; left: 50%; top: 45%; transform: translate(-50%, -50%); font-family: var(--title); font-size: 30px; color: #ffb0b0; text-shadow: 3px 3px 0 #000; text-align: center; }

#loading { position: fixed; inset: 0; z-index: 70; background: #0c0a18; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.load-title { font-family: var(--title); font-size: 48px; color: var(--gold2); text-shadow: 3px 3px 0 #a22633; margin-bottom: 14px; }
#load-text { color: var(--dim); }
.load-bar { width: 260px; height: 10px; border: 2px solid var(--line); margin-top: 12px; overflow: hidden; }
.load-bar div { width: 40%; height: 100%; background: var(--gold); animation: loadAnim 1s infinite linear; }
@keyframes loadAnim { from { transform: translateX(-100%); } to { transform: translateX(260%); } }

#bigmap { width: min(80vh, 88vw); height: min(80vh, 88vw); image-rendering: pixelated; display: block; margin: 0 auto; }

@media (max-width: 1100px) {
  #keys { display: none; }
  #top-center { width: 300px; }
  #top-left { width: 200px; }
}

/* ===== v2: nowe elementy ===== */
#hud #bottom-left > * { pointer-events: auto; }
#hud #bottom-left #chat-log { pointer-events: none; }
.vrow { display: flex; align-items: center; gap: 6px; font-size: 12px; margin: 2px 0 4px; color: var(--gold); font-weight: bold; }
.vrow .bar { flex: 1; height: 8px; }
.vrow > span:first-child { min-width: 58px; text-align: left; }
.vrow > span:last-child { min-width: 70px; text-align: right; color: var(--text); }
.vrow.hurt { color: #ff7a80; animation: blink 0.6s infinite; }
#fuel-fill { background: linear-gradient(#feae34, #be4a2f) !important; }
#wave-mod { font-size: 12px; font-weight: bold; margin: 2px 0 4px; }
#quest-mini { margin-top: 6px; font-size: 12px; color: var(--dim); white-space: pre-line; line-height: 1.35; border-top: 1px solid var(--line); padding-top: 4px; }
#players-panel { font-size: 12px; display: flex; flex-direction: column; gap: 4px; }
#players-panel .pl.off { opacity: 0.4; }
#players-panel .dot, .lp .dot { display: inline-block; width: 9px; height: 9px; border: 1px solid #0c0a18; margin-right: 4px; }
.bar.mini { height: 5px; margin-top: 2px; border-width: 1px; }
#hotbar { display: flex; gap: 4px; justify-content: center; min-height: 58px; }
.slot.item .cnt { position: absolute; right: 3px; bottom: 1px; font-size: 12px; font-weight: bold; color: #fff; text-shadow: 1px 1px 0 #000, -1px -1px 0 #000; }
.slot.item img { width: 36px; height: 36px; margin-bottom: 8px; }
#ability { position: relative; width: 38px; height: 38px; flex: none; background: #262b44; border: 2px solid #0c0a18; box-shadow: inset 0 0 0 1px var(--gold); cursor: pointer; overflow: hidden; }
#ability img { width: 34px; height: 34px; image-rendering: pixelated; }
#ability .cd { position: absolute; left: 0; right: 0; bottom: 0; background: rgba(12,10,24,0.75); height: 0; }
#ability .cdt { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; font-weight: bold; font-size: 15px; text-shadow: 1px 1px 0 #000; }
#ability .key { position: absolute; left: 2px; top: 0; font-size: 10px; color: var(--gold2); font-weight: bold; text-shadow: 1px 1px 0 #000; }
.eq.carry { border-color: var(--gold); color: var(--gold2); font-weight: bold; animation: blink 1s infinite; }
.eq.buff { padding: 1px; } .eq.relic { color: var(--gold2); font-size: 14px; padding: 2px 6px; }
#chat-log { font-size: 13px; background: rgba(24,20,37,0.7); padding: 5px 8px; border: 2px solid var(--line); max-height: 160px; overflow: hidden; transition: opacity 0.8s; line-height: 1.35; }
#chat-log.faded { opacity: 0.25; }
#chat-log b { color: var(--gold2); }
#chat-input { width: 100%; font: 14px var(--font); background: #0c0a18; color: var(--text); border: 2px solid var(--gold); padding: 6px; }
#dialog.side { left: auto; right: 10px; transform: none; bottom: auto; top: 300px; width: min(440px, 46vw); padding: 8px; gap: 10px; }
#dialog.side .dlg-portrait-wrap { width: 64px; height: 64px; }
#dialog.side #dlg-portrait { width: 58px; height: 58px; }
#dialog.side #dlg-text { font-size: 14px; }
#dialog.hermit #dlg-name { color: var(--green); }
.sub-h { font-family: var(--title); color: var(--gold2); margin: 12px 0 6px; font-size: 17px; }
.row.dimrow { opacity: 0.45; }
.relic-big { width: 36px; text-align: center; font-size: 26px; color: var(--gold2); }
.panel.newgame.wide { width: min(880px, 95vw); max-height: 92vh; overflow: auto; }
.coop-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 8px; }
.room-list { max-height: 220px; overflow: auto; display: flex; flex-direction: column; gap: 4px; }
.room { display: flex; align-items: center; justify-content: space-between; gap: 8px; background: #262b44; border: 2px solid #0c0a18; padding: 6px 8px; font-size: 13px; }
.lobby-code { text-align: center; font-size: 20px; margin: 4px 0; }
.lobby-code b { font-family: monospace; font-size: 28px; color: var(--gold2); letter-spacing: 4px; }
.lobby-players { display: flex; flex-direction: column; gap: 4px; }
.lp { background: #262b44; padding: 6px 10px; border: 2px solid #0c0a18; }
.tag { background: var(--gold); color: #0c0a18; font-size: 11px; padding: 0 5px; font-weight: bold; margin-left: 4px; }
.cls-row .diff span { display: block; font-size: 11px; line-height: 1.3; margin-top: 3px; }
.color-row { display: flex; gap: 6px; }
.cswatch { width: 30px; height: 30px; border: 3px solid #0c0a18; cursor: pointer; box-shadow: inset 0 0 0 2px rgba(255,255,255,0.15); }
.cswatch.on { border-color: #fff; }
.newgame input[type=checkbox] { margin-right: 6px; }
@media (max-width: 1100px) { .coop-cols { grid-template-columns: 1fr; } #dialog.side { top: auto; bottom: 150px; } }
