/* ludo.css — Himalayan Ludo Modern Design */

:root {
  --bg-dark: #0a0f18;
  --bg-panel: rgba(18, 28, 45, 0.92);
  --border-panel: rgba(255, 255, 255, 0.12);
  --gold: #f4b41a;
  --gold-glow: rgba(244, 180, 26, 0.45);
  
  --red: #e63946;
  --red-bg: rgba(230, 57, 70, 0.18);
  --blue: #1d70b8;
  --blue-bg: rgba(29, 112, 184, 0.18);
  --yellow: #f1c40f;
  --yellow-bg: rgba(241, 196, 15, 0.18);
  --green: #2ecc71;
  --green-bg: rgba(46, 204, 113, 0.18);

  --text-main: #f0f4f8;
  --text-muted: #94a3b8;
  --font-main: 'Nunito', system-ui, -apple-system, sans-serif;
  --font-serif: 'Cinzel', serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  user-select: none;
  -webkit-user-select: none;
}

body {
  font-family: var(--font-main);
  background: radial-gradient(circle at 50% 20%, #16243b 0%, #0a0f18 100%);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow-x: hidden;
}

/* ── Bottom Action buttons (fixed outside status frame) ──────────────── */
.status-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 10px;
}

.status-actions .btn-roll {
  padding: 9px 20px;
  font-size: 0.95rem;
  font-weight: 800;
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.35);
  white-space: nowrap;
}

.status-action-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-panel);
  color: var(--text-main);
  padding: 8px 16px;
  border-radius: 9px;
  font-family: var(--font-main);
  font-size: 0.88rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.status-action-btn:hover {
  background: rgba(244, 180, 26, 0.2);
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 0 10px rgba(244, 180, 26, 0.35);
}

/* ── Main Game Layout ─────────────────────────────────────────────────── */
.game-container {
  width: 100%;
  max-width: 1100px;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 12px 16px 20px;
  flex: 1;
}

/* ── Bottom Control Bar & Status Banner ─────────────────────────────────── */
.bottom-control-bar {
  width: 100%;
  max-width: 1020px;
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

/* Banner / Message Bar (Left frame exclusively for status inscriptions) */
.status-banner {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 58px;
  background: rgba(24, 38, 62, 0.88);
  border: 1px solid var(--border-panel);
  border-radius: 14px;
  padding: 6px 18px;
  margin: 0;
  display: flex;
  align-items: center;
  box-shadow: 0 6px 20px rgba(0,0,0,0.3);
  backdrop-filter: blur(8px);
  box-sizing: border-box;
}

.status-text {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.35;
  word-break: break-word;
}

.status-badge {
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

/* ── Board & Corner Player Cards Layout ────────────────────────────────── */
.board-wrapper {
  position: relative;
  width: 100%;
  max-width: 660px;
  aspect-ratio: 1 / 1;
  margin: 0 auto;
  box-shadow: 0 16px 45px rgba(0, 0, 0, 0.65), 0 0 20px rgba(244, 180, 26, 0.15);
  border-radius: 16px;
  overflow: visible;
  background: #ffffff;
  border: 4px solid #1a273b;
}

#ludoCanvas {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 12px;
  cursor: default;
}

/* Corner player widgets overlaid or surrounding */
.player-tag {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 10px;
  background: rgba(14, 22, 36, 0.9);
  border: 2px solid transparent;
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  z-index: 5;
  pointer-events: none;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}

.player-tag.active {
  transform: scale(1.08);
  border-width: 2px;
  border-style: solid;
}

.player-tag.red.active {
  border-color: #ef4444;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.65), 0 0 20px rgba(239, 68, 68, 0.65);
}
.player-tag.red.active .tag-turn-pill {
  background: #ef4444;
  box-shadow: 0 0 8px #ef4444;
}

.player-tag.blue.active {
  border-color: #38bdf8;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.65), 0 0 20px rgba(56, 189, 248, 0.65);
}
.player-tag.blue.active .tag-turn-pill {
  background: #38bdf8;
  box-shadow: 0 0 8px #38bdf8;
}

.player-tag.yellow.active {
  border-color: #f59e0b;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.65), 0 0 20px rgba(245, 158, 11, 0.65);
}
.player-tag.yellow.active .tag-turn-pill {
  background: #f59e0b;
  box-shadow: 0 0 8px #f59e0b;
}

.player-tag.green.active {
  border-color: #22c55e;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.65), 0 0 20px rgba(34, 197, 94, 0.65);
}
.player-tag.green.active .tag-turn-pill {
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
}

.player-tag.red { bottom: 12px; left: -48px; }
.player-tag.blue { top: 12px; left: -48px; }
.player-tag.yellow { top: 12px; right: -48px; }
.player-tag.green { bottom: 12px; right: -48px; }

.tag-avatar {
  font-size: 1.25rem;
}

.tag-name {
  white-space: nowrap;
}

.tag-turn-pill {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #64748b;
}

/* ── Board Arena & Side Bays (Слева / Справа поля) ───────────────────── */
.board-arena {
  position: relative;
  width: 100%;
  max-width: 1020px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
}

.dice-side-bay {
  flex: 0 0 135px;
  width: 135px;
  height: 560px;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1.5px dashed rgba(244, 180, 26, 0.28);
  border-radius: 20px;
  background: rgba(14, 22, 36, 0.45);
  backdrop-filter: blur(6px);
  margin: 0 14px;
  transition: all 0.3s ease;
  position: relative;
  cursor: pointer;
}

.dice-side-bay:hover {
  border-color: rgba(244, 180, 26, 0.55);
  background: rgba(244, 180, 26, 0.06);
}

.dice-side-bay.active {
  border-color: var(--gold);
  background: rgba(244, 180, 26, 0.12);
  box-shadow: 0 0 24px rgba(244, 180, 26, 0.3);
}

.dice-side-bay .bay-indicator {
  writing-mode: vertical-rl;
  text-orientation: sideways;
  color: var(--text-muted);
  font-size: 0.88rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  font-weight: 800;
  opacity: 0.65;
  transition: all 0.3s;
  user-select: none;
  pointer-events: none;
}

.dice-side-bay.active .bay-indicator {
  color: var(--gold);
  opacity: 1;
  text-shadow: 0 0 10px rgba(244, 180, 26, 0.6);
}

/* ── 3D Rolling Dice Stage ────────────────────────────────────────────── */
.dice-3d-stage {
  position: absolute;
  width: 80px;
  height: 80px;
  perspective: 900px;
  perspective-origin: 50% 50%;
  z-index: 30;
  cursor: pointer;
  left: 12px;
  top: 50%;
  transform: translate(0, -50%);
  will-change: transform, top, left, right;
}

.dice-3d-stage:hover .cube-face {
  box-shadow: inset 0 2px 5px rgba(255, 255, 255, 1), 
              inset 0 -3px 5px rgba(244, 180, 26, 0.35);
  border-color: rgba(244, 180, 26, 0.7);
}

.dice-3d-stage:hover .dice-3d-shadow {
  transform: translateX(-50%) scale(1.15);
  opacity: 0.95;
}

.dice-3d-cube {
  width: 62px;
  height: 62px;
  position: relative;
  transform-style: preserve-3d;
  margin: auto;
  will-change: transform;
}

.dice-3d-shadow {
  position: absolute;
  bottom: -12px;
  left: 50%;
  width: 58px;
  height: 16px;
  transform: translateX(-50%);
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.75) 0%, rgba(0, 0, 0, 0) 72%);
  border-radius: 50%;
  pointer-events: none;
  filter: blur(2px);
  will-change: transform, opacity, filter;
}

/* 6 Faces of the 3D Cube */
.cube-face {
  position: absolute;
  width: 62px;
  height: 62px;
  background: radial-gradient(circle at 35% 30%, #ffffff 0%, #faf6ee 50%, #e2dac9 100%);
  border-radius: 12px;
  border: 1.5px solid rgba(220, 210, 195, 0.6);
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.95), 
              inset 0 -3px 6px rgba(0, 0, 0, 0.18), 
              0 6px 14px rgba(0, 0, 0, 0.35);
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-template-rows: repeat(3, 1fr);
  padding: 6px;
  box-sizing: border-box;
}

/* Half of 62px = 31px */
.face-1 { transform: rotateY(0deg) translateZ(31px); }
.face-2 { transform: rotateX(-90deg) translateZ(31px); }
.face-3 { transform: rotateY(90deg) translateZ(31px); }
.face-4 { transform: rotateY(-90deg) translateZ(31px); }
.face-5 { transform: rotateX(90deg) translateZ(31px); }
.face-6 { transform: rotateY(180deg) translateZ(31px); }

/* Pips inside faces */
.cube-face .pip {
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 35%, #475569 0%, #1e293b 70%, #0f172a 100%);
  margin: auto;
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, 0.8), 0 1px 1px rgba(255, 255, 255, 0.9);
}

.face-1 .pip.center,
.face-1 .pip.red-ace {
  width: 16px;
  height: 16px;
  background: radial-gradient(circle at 35% 35%, #e63946 0%, #ba181b 70%, #660708 100%);
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, 0.7), 0 1px 1px rgba(255, 255, 255, 0.8);
}

.pip.top-left { grid-column: 1; grid-row: 1; }
.pip.top-right { grid-column: 3; grid-row: 1; }
.pip.mid-left { grid-column: 1; grid-row: 2; }
.pip.center { grid-column: 2; grid-row: 2; }
.pip.mid-right { grid-column: 3; grid-row: 2; }
.pip.bottom-left { grid-column: 1; grid-row: 3; }
.pip.bottom-right { grid-column: 3; grid-row: 3; }

/* ── Interactive Dice Control Box ─────────────────────────────────────── */
.dice-panel {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  margin-top: 14px;
}

@media (max-width: 820px) {
  .dice-side-bay {
    display: none;
  }
  .player-tag.red, .player-tag.blue { left: -16px; }
  .player-tag.yellow, .player-tag.green { right: -16px; }
  .dice-3d-stage {
    width: 62px;
    height: 62px;
  }
  .dice-3d-cube {
    width: 48px;
    height: 48px;
  }
  .cube-face {
    width: 48px;
    height: 48px;
  }
  .face-1 { transform: rotateY(0deg) translateZ(24px); }
  .face-2 { transform: rotateX(-90deg) translateZ(24px); }
  .face-3 { transform: rotateY(90deg) translateZ(24px); }
  .face-4 { transform: rotateY(-90deg) translateZ(24px); }
  .face-5 { transform: rotateX(90deg) translateZ(24px); }
  .face-6 { transform: rotateY(180deg) translateZ(24px); }
}

.btn-roll {
  padding: 12px 24px;
  font-size: 1.1rem;
  font-weight: 800;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  font-family: var(--font-main);
  background: linear-gradient(135deg, #f4b41a 0%, #e67e22 100%);
  color: #1a1002;
  box-shadow: 0 6px 18px rgba(244, 180, 26, 0.4);
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 8px;
}

.btn-roll:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(244, 180, 26, 0.6);
}

.btn-roll:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

/* ── Modals & Overlays ────────────────────────────────────────────────── */
.ludo-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(8, 12, 20, 0.85);
  backdrop-filter: blur(8px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  padding: 16px;
}

.ludo-modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.ludo-modal-card {
  background: var(--bg-panel);
  border: 1px solid var(--border-panel);
  border-radius: 18px;
  width: 100%;
  max-width: 500px;
  padding: 24px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
  position: relative;
  transform: translateY(20px);
  transition: transform 0.25s ease;
}

.ludo-modal-overlay.active .ludo-modal-card {
  transform: translateY(0);
}

.modal-close-x {
  position: absolute;
  top: 14px;
  right: 16px;
  z-index: 20;
  pointer-events: auto;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border-panel);
  color: #fff;
  font-size: 1.3rem;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.modal-close-x:hover {
  background: rgba(230, 57, 70, 0.4);
  border-color: var(--red);
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--gold);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.modal-subtitle {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 20px;
}

/* Options Selector inside Menu */
.opt-label {
  font-weight: 700;
  margin-bottom: 8px;
  font-size: 0.95rem;
  color: #e2e8f0;
}

.opt-row {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.opt-btn {
  flex: 1;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-panel);
  border-radius: 10px;
  color: var(--text-main);
  font-weight: 700;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}

.opt-btn:hover {
  background: rgba(255, 255, 255, 0.12);
}

.opt-btn.active {
  background: rgba(244, 180, 26, 0.2);
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 0 12px var(--gold-glow);
}

.color-dot {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: 2px solid #fff;
}

.color-dot.red { background: var(--red); }
.color-dot.blue { background: var(--blue); }
.color-dot.yellow { background: var(--yellow); }
.color-dot.green { background: var(--green); }

/* Toss Modal Display */
.toss-modal-card {
  max-width: 620px;
  width: 95%;
}

.toss-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin: 18px 0;
}

.toss-card {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-panel);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  box-sizing: border-box;
}

.toss-card.winner {
  border-color: var(--gold);
  background: rgba(244, 180, 26, 0.15);
  box-shadow: 0 0 14px var(--gold-glow);
}

.toss-dice-val {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--gold);
}

/* ── 3D Dice in Toss Modal (Жеребьевка) ───────────────────────────────── */
.toss-dice-stage {
  width: 54px;
  height: 54px;
  perspective: 450px;
  perspective-origin: 50% 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  flex-shrink: 0;
  margin-left: 6px;
  transform: scale(0.68);
  transform-origin: center center;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.toss-dice-stage.enlarged {
  transform: scale(0.88);
  filter: drop-shadow(0 0 10px rgba(244, 180, 26, 0.7));
}

.toss-dice-stage .dice-3d-cube {
  margin: 0;
}

.toss-dice-stage .dice-3d-shadow {
  bottom: -5px;
  width: 48px;
  height: 12px;
}

/* ── Celebration Canvas & Fireworks ──────────────────────────────────── */
.ludo-celebration-canvas {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 95;
}

/* ── Floating Inspection Banner (During Fireworks & Dice Rolling) ─────── */
.ludo-inspect-banner {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(40px);
  background: rgba(15, 23, 42, 0.94);
  border: 1.5px solid var(--gold);
  border-radius: 50px;
  padding: 12px 28px;
  box-shadow: 0 10px 35px rgba(0, 0, 0, 0.8), 0 0 24px rgba(244, 180, 26, 0.5);
  backdrop-filter: blur(12px);
  z-index: 98;
  display: flex;
  align-items: center;
  gap: 14px;
  opacity: 0;
  pointer-events: none;
  transition: all 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  cursor: pointer;
}

.ludo-inspect-banner.active {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
  pointer-events: auto;
}

.ludo-inspect-banner:hover {
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.85), 0 0 32px rgba(244, 180, 26, 0.8);
  border-color: #ffd700;
}

.ludo-inspect-banner .inspect-badge {
  background: var(--gold);
  color: #1a1500;
  font-weight: 900;
  font-size: 0.82rem;
  letter-spacing: 0.5px;
  padding: 4px 12px;
  border-radius: 20px;
  white-space: nowrap;
}

.ludo-inspect-banner .inspect-text {
  color: #f8fafc;
  font-weight: 700;
  font-size: 0.95rem;
}

/* ── Victory & Statistics Modal Card ─────────────────────────────────── */
.win-modal-card {
  max-width: 580px;
  width: 95%;
  text-align: center;
}

.win-trophy-badge {
  font-size: 2.6rem;
  line-height: 1;
  margin-bottom: 4px;
  pointer-events: none;
  filter: drop-shadow(0 0 18px rgba(244, 180, 26, 0.65));
  animation: winPulse 1.8s infinite ease-in-out;
}

.win-scene-box {
  width: 100%;
  max-width: 520px;
  margin: 4px auto 12px auto;
  border-radius: 14px;
  background: #0b152e;
  border: 1.5px solid rgba(148, 163, 184, 0.28);
  padding: 0;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.5);
}

.win-scene-box svg {
  width: 100%;
  height: auto;
  display: block;
}

@keyframes winPulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.08); }
}

.win-main-title {
  font-size: 1.8rem;
  color: var(--gold);
  text-shadow: 0 0 16px rgba(244, 180, 26, 0.4);
  justify-content: center;
  margin-bottom: 6px;
}

.win-summary-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 16px 0;
}

.win-metric-pill {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-panel);
  border-radius: 12px;
  padding: 10px 8px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.win-metric-pill .pill-label {
  font-size: 0.75rem;
  color: #94a3b8;
  font-weight: 600;
}

.win-metric-pill .pill-val {
  font-size: 1.25rem;
  font-weight: 900;
  color: var(--gold);
}

.win-standings-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 16px 0;
  text-align: left;
}

.win-standing-item {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-panel);
  border-radius: 12px;
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.win-standing-item.first {
  background: rgba(244, 180, 26, 0.14);
  border-color: var(--gold);
  box-shadow: 0 0 14px rgba(244, 180, 26, 0.25);
}

.win-standing-rank {
  font-size: 1.1rem;
  font-weight: 900;
  width: 32px;
}

/* Loading Overlay */
.wasm-loader {
  position: fixed;
  inset: 0;
  background: #0a0f18;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  transition: opacity 0.4s;
}

.loader-spinner {
  width: 50px;
  height: 50px;
  border: 4px solid rgba(255, 255, 255, 0.1);
  border-top-color: var(--gold);
  border-radius: 50%;
  animation: spin 0.8s infinite linear;
  margin-bottom: 16px;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

@media (max-width: 780px) {
  .bottom-control-bar {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .status-actions {
    justify-content: center;
    flex-wrap: wrap;
  }
}

@media (max-width: 650px) {
  .board-wrapper {
    max-width: 96vw;
    border-width: 2px;
  }
  .player-tag {
    font-size: 0.75rem;
    padding: 4px 8px;
  }
  .player-tag.red, .player-tag.blue { left: 4px; }
  .player-tag.yellow, .player-tag.green { right: 4px; }
  .dice-panel {
    gap: 12px;
    padding: 8px 16px;
  }
  .dice-cube {
    width: 56px;
    height: 56px;
  }
  .toss-grid {
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

/* ── Two-Column Rules Cards Layout ── */
.ludo-modal-card.ludo-rules-modal-card {
  max-width: 740px;
  max-height: 88vh;
  overflow-y: auto;
}

.ludo-rules-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  gap: 10px;
  margin-top: 10px;
}

.ludo-rules-card {
  background: rgba(11, 16, 22, 0.65);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  text-align: left;
}

.ludo-rules-card-wide {
  grid-column: 1 / -1;
}

.ludo-rules-card-title {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--gold);
  display: flex;
  align-items: center;
  gap: 6px;
}

.ludo-rules-card-text {
  margin: 0;
  font-size: 0.83rem;
  line-height: 1.48;
  color: #cbd5e1;
}

.lc-gold   { color: #facc15; font-weight: 700; }
.lc-cyan   { color: #38bdf8; font-weight: 700; }
.lc-green  { color: #4ade80; font-weight: 700; }
.lc-orange { color: #fb923c; font-weight: 700; }
.lc-red    { color: #fb7185; font-weight: 700; }

@media (max-width: 640px) {
  .ludo-rules-grid {
    grid-template-columns: 1fr;
  }
}

