/* ==========================================================================
   base.css：基本設定、共通変数、画面切り替え、共通演出
   ========================================================================== */
:root {
  --uno-赤: #ea2b2b;
  --uno-青: #0063b3;
  --uno-緑: #379737;
  --uno-黄: #ffaa00;
  --uno-黒: #111111;
}

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

body {
  background: radial-gradient(circle, #2d5a27 0%, #132711 100%);
  font-family: "Arial Black", Impact, -apple-system, sans-serif;
  color: #fff;
  height: 100vh;
  overflow: hidden;
  position: relative;
}

/* 画面切り替え（SPA制御） */
.screen {
  display: none;
  width: 100%;
  height: 100%;
}

.screen.active {
  display: flex;
  flex-direction: column;
}

/* UNO宣言時のカットイン演出（共通レイヤー） */
.cutin-overlay {
  display: none;
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  justify-content: center;
  align-items: center;
  z-index: 200;
  pointer-events: none;
}

.cutin-text {
  font-size: 72px;
  font-weight: 900;
  font-style: italic;
  color: #ffcc00;
  text-shadow: 0 0 20px #ff0000, 4px 4px 0 #fff;
  animation: ポップ演出 1.2s forwards;
}

@keyframes ポップ演出 {
  0% {
    transform: scale(0.2);
    opacity: 0;
  }

  50% {
    transform: scale(1.3);
    opacity: 1;
  }

  80% {
    transform: scale(1);
    opacity: 1;
  }

  100% {
    transform: scale(1.2);
    opacity: 0;
  }
}

/* --- 4色カラーの完全共通化（カード・ボタン・バッジすべて一括適用） --- */
.red, .red-btn { background: var(--uno-赤) !important; color: #fff; }
.blue, .blue-btn { background: var(--uno-青) !important; color: #fff; }
.green, .green-btn { background: var(--uno-緑) !important; color: #fff; }
.yellow, .yellow-btn { background: var(--uno-黄) !important; color: #111 !important; text-shadow: none; }
.wild { background: var(--uno-黒) !important; color: #fff; }

/* ==========================================================================
   カード中央の数字の色（白い楕円の中なので、カードと同じ色を適用）
   ========================================================================== */
.uno-card.red .main-symbol { color: var(--uno-赤) !important; }
.uno-card.blue .main-symbol { color: var(--uno-青) !important; }
.uno-card.green .main-symbol { color: var(--uno-緑) !important; }
.uno-card.yellow .main-symbol { color: var(--uno-黄) !important; }
.uno-card.wild .main-symbol { color: #ffffff !important; }