/* ================================================================
   リバーシ プラグイン スタイル
   ================================================================ */
#reversi-wrap {
  font-family: 'Segoe UI', 'Hiragino Sans', 'Meiryo', sans-serif;
  background: #1a1a2e;
  color: #eee;
  padding: 12px;
  border-radius: 10px;
  max-width: 760px;
  margin: 0 auto;
  box-sizing: border-box;
  position: relative;
  user-select: none;
}

#rv-container {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  flex-wrap: wrap;
}

/* ---- Board area ---- */
#rv-board-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

#rv-canvas {
  display: block;
  border: 3px solid #444;
  border-radius: 4px;
  cursor: pointer;
  max-width: 100%;
}

/* ---- Side panel ---- */
#rv-side-panel {
  flex: 1 1 160px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 140px;
}

/* Bot face */
#rv-bot-face-area {
  display: flex;
  flex-direction: column;
  align-items: center;
  background: #16213e;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 8px;
}

#rv-bot-face-img {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 50%;
  border: 2px solid #888;
  background: #333;
}

.rv-bot-label {
  font-size: 12px;
  color: #aaa;
  margin-top: 2px;
}

#rv-next-game-btn {
  margin-top: 6px;
  padding: 6px 12px;
  font-size: 13px;
  font-weight: bold;
  background: #4a9;
  color: #fff;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  width: 100%;
}
#rv-next-game-btn:hover { background: #3b8; }

/* Info */
#rv-info {
  background: #16213e;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 8px;
  font-size: 13px;
  text-align: center;
}

#rv-turn-label {
  font-weight: bold;
  font-size: 14px;
  margin-bottom: 6px;
  color: #ffd700;
}

#rv-score {
  display: flex;
  justify-content: space-around;
  font-size: 13px;
}

#rv-player-score { color: #f8c; }
#rv-bot-score    { color: #8cf; }

/* Log panel */
#rv-log-panel {
  background: #16213e;
  border: 1px solid #444;
  border-radius: 8px;
  padding: 6px;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  max-height: 220px;
}

#rv-log-header {
  font-size: 11px;
  font-weight: bold;
  color: #aaa;
  border-bottom: 1px solid #333;
  margin-bottom: 4px;
  padding-bottom: 2px;
}

#rv-move-log {
  font-size: 11px;
  overflow-y: auto;
  flex: 1;
  color: #ccc;
  line-height: 1.6;
}

/* Side buttons */
.rv-side-btn {
  display: block;
  width: 100%;
  padding: 7px 10px;
  background: #2d4a6e;
  color: #ddd;
  border: 1px solid #456;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  text-align: center;
  box-sizing: border-box;
}
.rv-side-btn:hover { background: #3a5f8a; }

/* Reward button */
#rv-reward-btn {
  padding: 8px 18px;
  background: linear-gradient(135deg, #e84393, #c0145a);
  color: #fff;
  border: none;
  border-radius: 20px;
  cursor: pointer;
  font-size: 14px;
  font-weight: bold;
  box-shadow: 0 2px 8px rgba(232,67,147,0.5);
  animation: rv-pulse 1.5s infinite;
}
@keyframes rv-pulse {
  0%,100% { transform: scale(1); }
  50%      { transform: scale(1.05); }
}

/* Reward overlay */
#rv-reward-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  z-index: 9999;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  cursor: pointer;
}
#rv-reward-overlay.active {
  display: flex;
}
.rv-reward-msg {
  font-size: 28px;
  font-weight: bold;
  color: #ffd700;
  text-shadow: 0 0 20px #ffd700;
}
#rv-reward-img {
  max-width: 80vw;
  max-height: 70vh;
  border-radius: 8px;
  box-shadow: 0 4px 30px rgba(0,0,0,0.8);
}
.rv-reward-hint {
  color: #aaa;
  font-size: 14px;
}

/* Responsive */
@media (max-width: 520px) {
  #rv-canvas { width: 100%; height: auto; }
  #rv-container { flex-direction: column; align-items: center; }
  #rv-side-panel { width: 100%; min-width: unset; }
}
