/* ==========================================================================
   WW2 Attack Command - styles.css
   Original interface styling: dark military panels, sidebar HUD, menus.
   ========================================================================== */

:root {
  --accent: #7fb3ff;
  --panel: rgba(14, 19, 26, 0.92);
  --panel2: rgba(20, 27, 36, 0.94);
  --edge: rgba(120, 150, 180, 0.22);
  --edge2: rgba(140, 190, 240, 0.35);
  --text: #d9e3ec;
  --dim: #8d9aa8;
  --good: #6ee06a;
  --warn: #ffcb5a;
  --bad: #ff6a5a;
  --font: "Segoe UI", "Trebuchet MS", Tahoma, system-ui, sans-serif;
  --mono: "Consolas", "Courier New", monospace;
}

* { box-sizing: border-box; }

html, body {
  margin: 0; padding: 0; height: 100%; overflow: hidden;
  background: #05070b; color: var(--text);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
  user-select: none;
}

#app { position: fixed; inset: 0; }

#game {
  position: absolute; inset: 0;
  display: block;
  image-rendering: auto;
  cursor: crosshair;
}

.hidden { display: none !important; }

/* ============================================================== top bar == */
#topbar {
  position: absolute; top: 0; left: 0; right: 0; height: 38px;
  display: flex; align-items: center; gap: 22px;
  padding: 0 12px;
  background: linear-gradient(180deg, rgba(10,14,20,0.96), rgba(10,14,20,0.72));
  border-bottom: 1px solid var(--edge);
  backdrop-filter: blur(3px);
  z-index: 20;
}
#topbar .stat { display: flex; flex-direction: column; line-height: 1.05; }
#topbar .lbl { font-size: 9px; letter-spacing: 1.4px; color: var(--dim); }
#topbar .val { font-size: 15px; font-weight: 700; font-family: var(--mono); color: #eaf2fb; }
#topbar .val.warn { color: var(--bad); animation: pulse 1s infinite; }
#topbar .factionTag {
  position: absolute; right: 14px; bottom: 2px;
  font-size: 20px; font-weight: 800; letter-spacing: 3px;
  opacity: 0.85;
}
/* performance readout: sits under the top bar, clear of the faction tag and
   the right-hand sidebar, so a second line of audio detail has room */
#topbar .fps {
  position: absolute; right: 258px; top: 44px;
  font-size: 10px; font-family: var(--mono); color: var(--dim);
  white-space: pre-line; text-align: right; line-height: 1.35; max-width: 330px;
  background: rgba(8,12,18,0.5); border-radius: 4px; padding: 2px 6px;
  pointer-events: none; z-index: 15;
}
@keyframes pulse { 0%,100% { opacity: 1 } 50% { opacity: 0.35 } }

/* ============================================================== sidebar == */
#sidebar {
  position: absolute; top: 38px; right: 0; bottom: 0; width: 246px;
  display: flex; flex-direction: column; gap: 6px;
  padding: 8px;
  background: linear-gradient(180deg, rgba(9,13,18,0.94), rgba(9,13,18,0.86));
  border-left: 1px solid var(--edge);
  z-index: 18;
  overflow: hidden;
}
.panelTitle {
  font-size: 9px; letter-spacing: 1.6px; color: var(--dim);
  margin: 2px 0 3px 2px;
}

#minimapWrap {
  position: relative;
  width: 100%;
  aspect-ratio: 1 / 1;
  border: 1px solid var(--edge2);
  border-radius: 4px;
  overflow: hidden;
  background: #05070b;
  box-shadow: inset 0 0 20px rgba(0,0,0,0.7);
}
#minimap { width: 100%; height: 100%; display: block; cursor: pointer; }
#minimapLabel {
  position: absolute; left: 0; right: 0; bottom: 0;
  font-size: 8px; letter-spacing: 2px; text-align: center; color: rgba(200,220,240,0.55);
  background: linear-gradient(0deg, rgba(0,0,0,0.7), transparent);
  padding: 2px 0;
  pointer-events: none;
}

#tabs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 3px; }
.tab {
  font-family: var(--font);
  font-size: 10px; letter-spacing: 0.4px;
  padding: 5px 2px;
  color: var(--dim);
  background: linear-gradient(180deg, #1b2330, #131a24);
  border: 1px solid var(--edge);
  border-radius: 3px;
  cursor: pointer;
  transition: all 0.12s;
}
.tab:hover { color: #eaf2fb; border-color: var(--edge2); }
.tab.on {
  color: #06121e; font-weight: 700;
  background: linear-gradient(180deg, var(--accent), rgba(90,150,220,0.85));
  border-color: #bcd9ff;
}

#buildGrid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 4px;
  overflow-y: auto;
  overflow-x: hidden;
  flex: 0 1 auto;
  max-height: 46%;
  padding-right: 2px;
}
#buildGrid::-webkit-scrollbar { width: 6px; }
#buildGrid::-webkit-scrollbar-thumb { background: rgba(120,150,180,0.3); border-radius: 3px; }

.buildBtn {
  position: relative;
  display: flex; flex-direction: column; align-items: center;
  gap: 1px;
  padding: 3px 2px 4px;
  background: linear-gradient(180deg, #1a222d, #111823);
  border: 1px solid var(--edge);
  border-radius: 4px;
  cursor: pointer;
  color: var(--text);
  transition: all 0.12s;
  font-family: var(--font);
}
.buildBtn:hover { border-color: var(--edge2); background: linear-gradient(180deg, #223044, #16202c); transform: translateY(-1px); }
.buildBtn .icon { width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; }
.buildBtn .icon canvas { width: 46px; height: 46px; border-radius: 3px; }
.buildBtn .nm { font-size: 8.5px; line-height: 1.05; text-align: center; color: #c3d1df; max-width: 100%; }
.buildBtn .cost { font-size: 9px; font-family: var(--mono); color: #ffd98a; font-weight: 700; }
.buildBtn.poor .cost { color: var(--bad); }
.buildBtn.locked { opacity: 0.42; filter: grayscale(0.6); }
.buildBtn.locked::after {
  content: ""; position: absolute; inset: 0;
  background: repeating-linear-gradient(45deg, rgba(0,0,0,0.25) 0 4px, transparent 4px 8px);
  border-radius: 4px; pointer-events: none;
}
.buildBtn .doneMark {
  position: absolute; top: 2px; right: 3px;
  font-size: 7px; letter-spacing: 0.5px; color: var(--good);
  background: rgba(0,0,0,0.6); padding: 0 2px; border-radius: 2px;
}

#queueWrap { border-top: 1px solid var(--edge); padding-top: 4px; }
#queue { display: flex; flex-direction: column; gap: 3px; max-height: 132px; overflow-y: auto; }
#queue::-webkit-scrollbar { width: 6px; }
#queue::-webkit-scrollbar-thumb { background: rgba(120,150,180,0.3); border-radius: 3px; }
.emptyQueue { font-size: 10px; color: #5d6b7a; padding: 3px; }
.qRow {
  display: flex; align-items: center; gap: 5px;
  padding: 2px 3px;
  background: rgba(30,40,52,0.65);
  border: 1px solid rgba(120,150,180,0.14);
  border-radius: 3px;
}
.qIcon canvas, .qUpg { width: 26px; height: 26px; border-radius: 2px; display: block; }
.qUpg { display: flex; align-items: center; justify-content: center; background: #223044; color: var(--accent); font-size: 12px; font-weight: 700; }
.qBody { flex: 1; min-width: 0; }
.qName { font-size: 9.5px; color: #cfe0ef; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.qBar { height: 4px; background: rgba(0,0,0,0.55); border-radius: 2px; overflow: hidden; margin-top: 2px; }
.qFill { height: 100%; background: linear-gradient(90deg, #4ea1ff, #8fe0ff); }
.qTime { font-size: 9px; font-family: var(--mono); color: #9fb4c7; }
.qCancel {
  width: 16px; height: 16px; line-height: 1;
  background: rgba(80,30,25,0.8); color: #ffb0a0;
  border: 1px solid rgba(255,120,100,0.35); border-radius: 3px;
  cursor: pointer; font-size: 10px; padding: 0;
}
.qCancel:hover { background: rgba(140,40,30,0.95); }

#selInfo { flex: 0 0 auto; border-top: 1px solid var(--edge); padding-top: 5px; }
.selEmpty { font-size: 10px; color: #7d8b9a; line-height: 1.5; padding: 4px 2px; }
.selEmpty .hint { font-size: 9px; color: #5d6b7a; }
.selCard {
  background: linear-gradient(180deg, rgba(28,38,50,0.9), rgba(16,22,30,0.9));
  border: 1px solid var(--edge);
  border-radius: 4px; padding: 5px 6px;
}
.selHead { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; }
.selName { font-size: 11.5px; font-weight: 700; color: #eaf2fb; }
.selFrac { font-size: 10px; font-family: var(--mono); color: #9fb4c7; }
.hpBig { height: 6px; background: rgba(0,0,0,0.6); border-radius: 3px; overflow: hidden; margin: 4px 0 5px; }
.hpFill { height: 100%; background: linear-gradient(90deg, #3fbf58, #8ff09a); }
.kv { display: flex; justify-content: space-between; font-size: 10px; color: #a9b8c6; line-height: 1.5; }
.kv b { color: #e8f1fa; font-weight: 600; }
.selList { max-height: 66px; overflow-y: auto; margin-top: 4px; }
.selLine { font-size: 10px; color: #b9c8d6; line-height: 1.5; }
.selLine b { color: #ffd98a; }

#orderBar { display: flex; flex-wrap: wrap; gap: 3px; padding-top: 4px; }
.orderBtn {
  flex: 1 1 46%;
  font-family: var(--font); font-size: 10px;
  padding: 5px 3px;
  color: #cfe0ef;
  background: linear-gradient(180deg, #1e2836, #141b25);
  border: 1px solid var(--edge); border-radius: 3px; cursor: pointer;
}
.orderBtn:hover { border-color: var(--edge2); color: #fff; background: linear-gradient(180deg, #263447, #182231); }
.orderBtn:active { transform: translateY(1px); }

/* ============================================================== alerts === */
#alerts {
  position: absolute; top: 46px; left: 12px;
  display: flex; flex-direction: column; gap: 4px;
  width: 300px; z-index: 16; pointer-events: none;
}
.alertRow {
  pointer-events: auto;
  font-size: 11px; padding: 5px 8px;
  background: rgba(16,22,30,0.9);
  border-left: 3px solid var(--warn);
  border-radius: 3px;
  color: #dce8f4;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
  transition: opacity 0.4s;
}
.alertRow.crit { border-left-color: var(--bad); color: #ffe2dd; }
.alertRow.fresh { animation: alertIn 0.35s ease-out; }
.alertRow:hover { background: rgba(30,42,56,0.95); }
@keyframes alertIn { from { transform: translateX(-24px); opacity: 0 } to { transform: none; opacity: 1 } }

#statusBar {
  position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%);
  padding: 6px 16px;
  background: rgba(10,16,24,0.86);
  border: 1px solid var(--edge2);
  border-radius: 20px;
  font-size: 12px; color: #dff0ff;
  opacity: 0; transition: opacity 0.25s;
  pointer-events: none; z-index: 16;
  max-width: 60vw; text-align: center;
}
#statusBar.show { opacity: 1; }

#toasts {
  position: absolute; bottom: 16px; left: 16px;
  display: flex; flex-direction: column; gap: 4px; z-index: 17;
}
.toast {
  font-size: 11px; padding: 5px 10px;
  background: rgba(20,30,42,0.92);
  border: 1px solid var(--edge2); border-radius: 3px;
  color: #d7e7f6;
  transition: opacity 0.4s, transform 0.4s;
}
.toast.out { opacity: 0; transform: translateY(6px); }

#pauseBtn {
  position: absolute; top: 46px; right: 258px;
  width: 30px; height: 30px; line-height: 28px;
  text-align: center; font-size: 13px; letter-spacing: 1px;
  background: rgba(14,20,28,0.85);
  border: 1px solid var(--edge2); border-radius: 4px;
  cursor: pointer; color: #cfe0ef; z-index: 19;
}
#pauseBtn:hover { background: rgba(30,44,60,0.95); }

#musicBtn {
  position: absolute; top: 46px; right: 294px;
  width: 30px; height: 30px; line-height: 28px;
  text-align: center; font-size: 14px;
  background: rgba(14,20,28,0.85);
  border: 1px solid var(--edge2); border-radius: 4px;
  cursor: pointer; color: #cfe0ef; z-index: 19;
}
#musicBtn:hover { background: rgba(30,44,60,0.95); }
#musicBtn.off { color: #55636f; }
/* a red slash through the note says "music off" at a glance */
#musicBtn.off::after {
  content: '/'; position: absolute; inset: 0;
  font-size: 20px; line-height: 28px;
  color: #cf5a44; transform: rotate(-6deg);
  pointer-events: none;
}

/* ============================================================== tooltip == */
#tooltip {
  position: fixed; right: 256px; top: 100px;
  width: 246px; padding: 8px 10px;
  background: rgba(8,12,18,0.97);
  border: 1px solid var(--edge2); border-radius: 4px;
  font-size: 11px; line-height: 1.45; color: #cfdcea;
  opacity: 0; pointer-events: none; transition: opacity 0.12s;
  z-index: 40; box-shadow: 0 6px 22px rgba(0,0,0,0.6);
}
#tooltip.show { opacity: 1; }
#tooltip b { color: #ffe9b8; }
.ttDesc { color: #9fb0c0; font-size: 10.5px; margin: 3px 0 5px; }
.ttRow { font-size: 10.5px; color: #b8c8d8; }

/* ============================================================== screens == */
#screens {
  position: absolute; inset: 0; z-index: 60;
  overflow-y: auto;
  background: radial-gradient(ellipse at 50% 30%, rgba(18,28,40,0.96), rgba(3,5,8,0.985));
}
#screens.hidden { display: none; }

.menuWrap { min-height: 100%; display: flex; align-items: center; justify-content: center; padding: 24px; }
.menuWrap.scrollable { align-items: flex-start; }

.menuPanel {
  width: min(520px, 92vw);
  padding: 30px 34px 22px;
  background: linear-gradient(180deg, rgba(20,28,38,0.92), rgba(10,14,20,0.95));
  border: 1px solid var(--edge2);
  border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.7), inset 0 1px 0 rgba(255,255,255,0.05);
  text-align: center;
}
.gameTitle {
  font-size: 40px; font-weight: 900; letter-spacing: 6px; line-height: 1;
  color: #f2f7fc;
  text-shadow: 0 2px 0 #2a3a4c, 0 0 34px rgba(120,180,255,0.35);
}
.gameTitle span {
  display: block; font-size: 20px; letter-spacing: 9px; margin-top: 8px;
  color: var(--accent);
  text-shadow: 0 0 18px rgba(120,180,255,0.5);
}
.gameSub { margin: 14px 0 22px; font-size: 12px; color: var(--dim); letter-spacing: 0.6px; }

.menuButtons { display: flex; flex-direction: column; gap: 8px; }
.menuButtons.row { flex-direction: row; flex-wrap: wrap; }
.menuButtons.row .mBtn { flex: 1 1 40%; }

.mBtn {
  font-family: var(--font);
  font-size: 14px; font-weight: 600; letter-spacing: 0.6px;
  padding: 11px 18px;
  color: #dce8f4;
  background: linear-gradient(180deg, #1f2a38, #131a24);
  border: 1px solid var(--edge2);
  border-radius: 5px; cursor: pointer;
  transition: all 0.14s;
}
.mBtn:hover { background: linear-gradient(180deg, #2a3a4e, #18222f); color: #fff; transform: translateY(-1px); }
.mBtn:active { transform: translateY(1px); }
.mBtn:disabled { opacity: 0.4; cursor: default; transform: none; }
.mBtn.primary {
  background: linear-gradient(180deg, #3f7fd0, #24507f);
  border-color: #9ecbff; color: #fff;
  box-shadow: 0 4px 16px rgba(60,120,200,0.35);
}
.mBtn.primary:hover { background: linear-gradient(180deg, #4f93e6, #2a5f97); }
.mBtn.quit { border-color: rgba(255,120,100,0.3); color: #ffc9c0; }
.mBtn.quit:hover { background: linear-gradient(180deg, #4a2018, #2a1310); }

.menuFoot { margin-top: 18px; font-size: 10px; letter-spacing: 1px; color: #62707e; }

/* --------------------------------------------------------- skirmish set-up */
.setup { padding: 20px; }
.setupPanel {
  width: min(1080px, 96vw);
  padding: 20px 24px 16px;
  background: linear-gradient(180deg, rgba(18,25,34,0.94), rgba(9,13,18,0.96));
  border: 1px solid var(--edge2); border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.7);
}
.setupPanel h2 { margin: 0 0 14px; font-size: 22px; letter-spacing: 3px; color: #eaf2fb; text-align: center; }
.setupCols { display: flex; gap: 22px; align-items: flex-start; }
.setupCol { flex: 1; min-width: 0; }
.setupCol.wide { flex: 1.5; }
.setupCol h3, .docPanel h3 {
  font-size: 11px; letter-spacing: 2px; color: var(--dim);
  margin: 10px 0 6px; text-transform: uppercase;
}
.factionPick { display: flex; flex-direction: column; gap: 8px; }
.fCard {
  padding: 10px 12px; cursor: pointer;
  background: linear-gradient(180deg, #1a2230, #111823);
  border: 1px solid var(--edge); border-radius: 5px;
  transition: all 0.14s;
}
.fCard:hover { border-color: var(--edge2); }
.fCard.on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset, 0 4px 18px rgba(80,140,220,0.25); }
.fName { font-size: 15px; font-weight: 800; letter-spacing: 1.5px; }
.fMotto { font-size: 11px; color: var(--dim); margin: 2px 0 5px; }
.fTag { font-size: 10.5px; color: #a9b8c6; line-height: 1.4; }

.diffPick { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.dCard {
  padding: 7px 9px; cursor: pointer;
  background: linear-gradient(180deg, #1a2230, #111823);
  border: 1px solid var(--edge); border-radius: 5px;
}
.dCard:hover { border-color: var(--edge2); }
.dCard.on { border-color: var(--warn); box-shadow: 0 0 0 1px rgba(255,203,90,0.6) inset; }
.dName { font-size: 12.5px; font-weight: 700; }
.dDesc { font-size: 9.5px; color: var(--dim); line-height: 1.35; margin-top: 2px; }

.mapPick {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px;
  max-height: 320px; overflow-y: auto; padding-right: 4px;
}
.mapPick::-webkit-scrollbar { width: 6px; }
.mapPick::-webkit-scrollbar-thumb { background: rgba(120,150,180,0.3); border-radius: 3px; }
.mCard {
  cursor: pointer; padding: 3px; border-radius: 5px;
  background: rgba(20,28,38,0.8);
  border: 1px solid var(--edge);
  transition: all 0.14s;
}
.mCard:hover { border-color: var(--edge2); }
.mCard.on { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.mapThumb { width: 100%; height: auto; display: block; border-radius: 3px; image-rendering: pixelated; }
.mapName { font-size: 9.5px; text-align: center; color: #c5d3e0; margin-top: 2px; }
.mapInfo { margin-top: 8px; font-size: 12px; color: #dbe7f3; }
.mapDesc { font-size: 10.5px; color: var(--dim); line-height: 1.45; margin-top: 3px; }
.setupFoot { display: flex; justify-content: space-between; margin-top: 16px; }

/* -------------------------------------------------------------- documents */
.docPanel {
  width: min(900px, 95vw); margin: 24px auto 40px;
  padding: 24px 28px;
  background: linear-gradient(180deg, rgba(18,25,34,0.94), rgba(9,13,18,0.96));
  border: 1px solid var(--edge2); border-radius: 8px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.7);
}
.docPanel.narrow { width: min(620px, 92vw); }
.docPanel h2 { margin: 0 0 16px; font-size: 22px; letter-spacing: 3px; text-align: center; }
.docPanel p { font-size: 12.5px; line-height: 1.6; color: #c2d0dd; }
.docPanel p.hint { font-size: 11px; color: var(--dim); }
.docCols { display: flex; gap: 26px; }
.docCols > div { flex: 1; min-width: 0; }
.keys { width: 100%; border-collapse: collapse; font-size: 11.5px; }
.keys td { padding: 3px 6px; border-bottom: 1px solid rgba(120,150,180,0.12); color: #c2d0dd; }
.keys td:first-child { font-family: var(--mono); color: #ffe9b8; white-space: nowrap; width: 42%; }
.docFoot { display: flex; justify-content: center; gap: 10px; margin-top: 22px; }

.setRow { display: flex; align-items: center; gap: 12px; margin: 8px 0; font-size: 12px; }
.setRow label { flex: 0 0 150px; color: #c2d0dd; }
.setRow input[type=range] { flex: 1; accent-color: var(--accent); }
.setRow input[type=checkbox] { width: 16px; height: 16px; accent-color: var(--accent); }
.setVal { font-family: var(--mono); font-size: 11px; color: #9fb4c7; width: 44px; text-align: right; }

.credits { text-align: center; }
.creditBig { font-size: 26px; font-weight: 900; letter-spacing: 4px; color: var(--accent); margin: 6px 0 16px; }
.creditLine { font-size: 13px; }
.creditList { list-style: none; padding: 0; font-size: 12px; color: #c2d0dd; }
.creditList li { padding: 3px 0; }
.credits p { text-align: left; }

/* ----------------------------------------------------------- save slots */
.slotGrid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.slotCard {
  padding: 10px 12px;
  background: linear-gradient(180deg, #1a2230, #111823);
  border: 1px solid var(--edge); border-radius: 5px;
  min-height: 118px; display: flex; flex-direction: column; gap: 4px;
}
.slotCard.empty { opacity: 0.55; }
.slotTitle { font-size: 13px; font-weight: 700; color: #eaf2fb; }
.slotMeta { font-size: 10.5px; color: #9fb0c0; line-height: 1.45; flex: 1; }
.slotBtns { display: flex; gap: 6px; }
.slotBtns button {
  flex: 1; font-family: var(--font); font-size: 11px; padding: 5px 0;
  background: linear-gradient(180deg, #24313f, #16202c);
  border: 1px solid var(--edge2); border-radius: 3px; color: #d6e4f2; cursor: pointer;
}
.slotBtns button:hover { background: linear-gradient(180deg, #2e4054, #1b2634); }
.slotDel { border-color: rgba(255,120,100,0.3) !important; color: #ffc9c0 !important; }

/* --------------------------------------------------------------- overlays */
.pauseOverlay, .winOverlay, .loseOverlay {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(4,7,11,0.78);
  backdrop-filter: blur(3px);
}
.winOverlay { background: radial-gradient(ellipse at 50% 40%, rgba(20,50,30,0.85), rgba(3,8,6,0.94)); }
.loseOverlay { background: radial-gradient(ellipse at 50% 40%, rgba(52,16,14,0.85), rgba(10,3,3,0.94)); }
.pausePanel, .endPanel {
  width: min(560px, 94vw);
  padding: 24px 28px;
  background: linear-gradient(180deg, rgba(20,28,38,0.96), rgba(10,14,20,0.97));
  border: 1px solid var(--edge2); border-radius: 8px;
  box-shadow: 0 24px 70px rgba(0,0,0,0.75);
  text-align: center;
}
.pausePanel h2 { font-size: 22px; letter-spacing: 5px; margin: 0 0 14px; }
.pauseStats {
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px 14px;
  margin-bottom: 18px; font-size: 11.5px;
}
.pauseStats div { display: flex; justify-content: space-between; border-bottom: 1px solid rgba(120,150,180,0.14); padding: 3px 0; }
.pauseStats span { color: var(--dim); }

.endTitle {
  font-size: 44px; letter-spacing: 12px; margin: 0 0 6px;
  text-shadow: 0 0 30px rgba(255,255,255,0.25);
}
.winOverlay .endTitle { color: #8ff09a; }
.loseOverlay .endTitle { color: #ff8a75; }
.endSub { font-size: 12.5px; color: #b8c8d8; margin-bottom: 18px; }
.endStats { display: grid; grid-template-columns: 1fr 1fr; gap: 3px 16px; margin-bottom: 20px; }
.endStats div { display: flex; justify-content: space-between; font-size: 11.5px; border-bottom: 1px solid rgba(120,150,180,0.14); padding: 4px 0; }
.endStats span { color: var(--dim); }

/* ------------------------------------------------------------- exit note */
.exitNote {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(3,5,8,0.9); z-index: 80;
}
.exitBox {
  width: min(460px, 92vw); padding: 26px 28px; text-align: center;
  background: linear-gradient(180deg, rgba(20,28,38,0.97), rgba(10,14,20,0.98));
  border: 1px solid var(--edge2); border-radius: 8px;
}
.exitBox h3 { margin: 0 0 10px; font-size: 18px; letter-spacing: 2px; color: #eaf2fb; }
.exitBox p { font-size: 12px; color: #b8c8d8; line-height: 1.6; margin-bottom: 18px; }

/* ---------------------------------------------------------- small screens */
@media (max-width: 980px) {
  #sidebar { width: 210px; }
  .mapPick { grid-template-columns: repeat(3, 1fr); }
  .setupCols { flex-direction: column; }
  .docCols { flex-direction: column; }
  .slotGrid { grid-template-columns: repeat(2, 1fr); }
}
