/* The Expansion's shared look: theme colours, the island map, resource chips and
   dice. Used by board.html (TV) and player.html (phone), on top of /shared.css. */

:root {
  --ex-bg: #0e1522;
  --ex-bg-top: #1d3557;
  --ex-bg-dark: #070b13;
  --ex-panel: rgba(13, 22, 38, 0.72);
  --ex-line: rgba(255, 255, 255, 0.14);
  --ex-muted: #a9b8ce;
  --ex-danger: #ff7088;
  --ex-ok: #45dd9e;
  --ex-red: #d7263d;
  --ex-blue: #2f62d8;
  --ex-white: #f3efe4;
  --ex-purple: #8a3ffc;
}

.hidden { display: none !important; }
.muted { color: var(--ex-muted); }

/* player colours */
.dot.red { background: var(--ex-red); }
.dot.blue { background: var(--ex-blue); }
.dot.white { background: var(--ex-white); box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.35); }
.dot.purple { background: var(--ex-purple); }

/* icons, resource chips */
.ico { width: 16px; height: 16px; display: inline-block; vertical-align: -3px; flex: none; }
.rc {
  display: inline-flex; align-items: center; gap: 3px; padding: 2px 8px 2px 5px; border-radius: 999px;
  font-weight: 800; font-size: 0.85rem; line-height: 1.3; white-space: nowrap; font-variant-numeric: tabular-nums;
}
.rc .ico { width: 16px; height: 16px; }
.rc.sm { padding: 0 6px 0 3px; font-size: 0.78rem; }
.rc.sm .ico { width: 13px; height: 13px; }
.rc.lg { padding: 5px 11px 5px 7px; font-size: 1.15rem; }
.rc.lg .ico { width: 22px; height: 22px; }
.rc.zero { opacity: 0.4; }
.badge-bonus {
  font-size: 0.7rem; font-weight: 800; padding: 1px 6px; border-radius: 5px; white-space: nowrap;
  background: #3d2f05; color: var(--gold); border: 1px solid #7a5d0f;
}
.bot-tag { font-size: 0.68rem; font-weight: 800; padding: 1px 5px; border-radius: 4px; background: rgba(255, 255, 255, 0.16); color: #dfe8f5; }

/* dice */
.die { width: 42px; height: 42px; }
.die rect { fill: #f8f6f0; stroke: #222; stroke-width: 1; }
.die circle { fill: #1a1a1a; }
.die.dark rect { fill: #17171b; stroke: #77777f; }
.die.dark circle { fill: #f3f3f3; }
.die.alert rect { stroke: var(--ex-danger); stroke-width: 2.6; }
.die.stale { opacity: 0.35; }
.die text { font: 700 12px sans-serif; fill: #888; text-anchor: middle; dominant-baseline: central; }

/* ===================================================================== */
/* The island                                                            */
/* ===================================================================== */
.ex-map { display: block; width: 100%; height: auto; user-select: none; -webkit-user-select: none; -webkit-tap-highlight-color: transparent; }
.ex-map .shore { fill: #d8c38e; }
.ex-map .hex { stroke: #13212e; stroke-width: 0.035; stroke-linejoin: round; }
.ex-map .tile.target { cursor: pointer; }
.ex-map .hex-target {
  fill: rgba(255, 255, 255, 0.1); stroke: #fff; stroke-width: 0.07; stroke-linejoin: round;
  pointer-events: none; animation: ex-pulse 1.1s ease-in-out infinite;
}
.ex-map .tile.target:hover .hex-target { fill: rgba(255, 255, 255, 0.24); }
.ex-map .tile.blighted .hex { filter: saturate(0.35) brightness(0.7); }
.ex-map .token { fill: #f7f0de; stroke: #3b2f1e; stroke-width: 0.03; }
.ex-map .token.dim { opacity: 0.45; }
.ex-map .token.hot { fill: #ffe27a; stroke: #6b4f00; stroke-width: 0.05; }
.ex-map .token-num {
  font-weight: 800; fill: #2a1f12; text-anchor: middle; dominant-baseline: central;
  font-family: Georgia, 'Times New Roman', serif; pointer-events: none;
}
.ex-map .port-plank { stroke: #c9a46a; stroke-width: 0.07; stroke-linecap: round; }
.ex-map .port-disc { fill: #f3e8cf; stroke: #6b4f2a; stroke-width: 0.035; }
.ex-map .port-text { font-weight: 800; fill: #3a2a12; text-anchor: middle; dominant-baseline: central; font-family: system-ui, sans-serif; }
.ex-map .route-outline { stroke: #0b0e13; stroke-width: 0.2; stroke-linecap: round; }
.ex-map .route { stroke-width: 0.12; stroke-linecap: round; }
.ex-map .bld { stroke: #0b0e13; stroke-width: 0.035; stroke-linejoin: round; }
.ex-map .vert-target { fill: rgba(255, 255, 255, 0.3); stroke: #fff; stroke-width: 0.045; pointer-events: none; animation: ex-pulse 1.1s ease-in-out infinite; }
.ex-map .bld-target { fill: none; stroke: #fff; stroke-width: 0.05; stroke-dasharray: 0.08 0.06; pointer-events: none; animation: ex-pulse 1.1s ease-in-out infinite; }
.ex-map .edge-target { stroke: #fff; stroke-width: 0.085; stroke-dasharray: 0.12 0.08; stroke-linecap: round; pointer-events: none; animation: ex-pulse 1.1s ease-in-out infinite; }
.ex-map .vert-hit { fill: transparent; cursor: pointer; }
.ex-map .edge-hit { stroke: transparent; stroke-width: 0.44; stroke-linecap: butt; cursor: pointer; }
/* the piece just placed */
.ex-map .fresh-ring { fill: none; stroke: var(--gold); stroke-width: 0.06; animation: ex-pulse 1.1s ease-in-out 3; pointer-events: none; }
.ex-map .route.fresh { animation: ex-pulse 1.1s ease-in-out 3; }
@keyframes ex-pulse { 0%, 100% { opacity: 0.5; } 50% { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .ex-map * { animation: none !important; } }

/* the log: one line per event, a stripe in the player's colour */
.ex-log { list-style: none; margin: 0; padding: 0; font-size: 0.88rem; line-height: 1.4; }
.ex-log li { padding: 2px 0 2px 8px; border-left: 3px solid var(--pc, transparent); margin-bottom: 2px; color: #d6deea; }
.ex-log li.sys { color: var(--ex-muted); font-style: italic; }
.ex-log li.turn { color: var(--gold); font-weight: 800; border-left-color: transparent; padding-left: 0; margin-top: 6px; }
