/* ==========================================================================
   ABCya! Game Player Arena - Clean Vooks-Inspired Light Theme
   Enhanced for Fullscreen Mobile Touch & Desktop Cinema
   ========================================================================== */

:root {
  --player-header-h: 64px;
  --vooks-navy: #013870;
  --vooks-blue: #0284c7;
  --vooks-blue-cta: #2563eb;
  --vooks-border: #e2e8f0;
}

body {
  background: #f8fafc;
  color: #0f172a;
  min-height: 100vh;
}

/* Player Header */
.player-header {
  background: #ffffff;
  border-bottom: 2px solid var(--vooks-border);
  padding: 10px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.02);
}

.back-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: var(--radius-full);
  background: #f1f5f9;
  border: 1px solid var(--vooks-border);
  color: var(--vooks-navy);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.85rem;
  transition: all 0.2s ease;
  flex-shrink: 0;
}
.back-btn:hover {
  background: #e2e8f0;
  transform: translateX(-2px);
}
.back-btn:active {
  transform: scale(0.96);
}

.player-title-box {
  text-align: center;
  overflow: hidden;
  flex: 1;
}

.player-game-title {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--vooks-navy);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.2;
}

.player-game-grades {
  font-size: 0.75rem;
  color: var(--vooks-blue);
  font-weight: 700;
}

.player-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.action-btn {
  padding: 7px 14px;
  border-radius: var(--radius-full);
  background: #f8fafc;
  color: #334155;
  border: 1px solid var(--vooks-border);
  font-weight: 700;
  font-size: 0.82rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  transition: all 0.2s ease;
  font-family: inherit;
  text-decoration: none;
}
.action-btn:hover {
  background: #eff6ff;
  color: var(--vooks-blue);
  border-color: #bfdbfe;
  transform: translateY(-1px);
}
.action-btn:active {
  transform: scale(0.96);
}
.action-btn.active {
  background: #fff1f2;
  border-color: #fecdd3;
  color: #ef4444;
}

/* Arena Viewport */
.arena-wrapper {
  max-width: 1240px;
  margin: 18px auto;
  padding: 0 16px;
}

.game-viewport-card {
  background: #000;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(1, 56, 112, 0.14), 0 2px 8px rgba(0, 0, 0, 0.04);
  position: relative;
  width: 100%;
  border: 1px solid var(--vooks-border);
}

.game-aspect-ratio-wrap {
  position: relative;
  width: 100%;
  padding-top: 62.5%;
}

.game-iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
  background: #000;
}

/* Fullscreen Mode */
.game-viewport-card.is-fullscreen {
  position: fixed;
  inset: 0;
  width: 100vw;
  height: 100vh;
  z-index: 99999;
  border-radius: 0;
  border: none;
  margin: 0;
  padding: 0;
}

.game-viewport-card.is-fullscreen .game-aspect-ratio-wrap {
  padding-top: 0;
  height: 100vh;
}

/* Game Start Interactive Overlay */
.game-start-overlay {
  position: absolute;
  inset: 0;
  background: rgba(1, 56, 112, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.game-start-overlay.hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.start-btn-pulse {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  background: linear-gradient(135deg, #0284c7 0%, #2563eb 100%);
  padding: 24px 44px;
  border-radius: 24px;
  color: white;
  box-shadow: 0 16px 40px rgba(37, 99, 235, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.3);
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  animation: pulseScale 2s infinite ease-in-out;
  border: 2px solid rgba(255, 255, 255, 0.25);
}

.game-start-overlay:hover .start-btn-pulse {
  transform: scale(1.06);
  box-shadow: 0 20px 50px rgba(37, 99, 235, 0.65);
}

.start-play-icon {
  font-size: 2.8rem;
  line-height: 1;
}

.start-play-label {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 800;
  letter-spacing: 0.05em;
}

.start-play-sub {
  font-size: 0.82rem;
  opacity: 0.9;
  font-weight: 600;
}

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

/* Info Details Box (Clean White) */
.game-details-box {
  background: #ffffff;
  border-radius: var(--radius-lg);
  padding: 24px;
  margin-top: 24px;
  border: 1px solid var(--vooks-border);
  box-shadow: 0 3px 12px rgba(15, 23, 42, 0.04);
}

.details-heading {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--vooks-navy);
  margin-bottom: 8px;
}

.details-desc {
  font-size: 0.95rem;
  color: #475569;
  line-height: 1.6;
  margin-bottom: 16px;
}

.details-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.detail-pill {
  background: #eff6ff;
  color: var(--vooks-blue);
  border: 1px solid #bfdbfe;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
}

/* Similar Games Section */
.similar-games-section {
  margin-top: 36px;
  margin-bottom: 40px;
}

.similar-heading {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--vooks-navy);
  margin-bottom: 16px;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {
  .player-header {
    padding: 8px 12px;
  }
  .player-game-title {
    font-size: 1rem;
  }
  .action-btn span:not(.btn-icon) {
    display: none;
  }
  .action-btn {
    padding: 7px 10px;
  }
  .arena-wrapper {
    margin: 8px auto;
    padding: 0 8px;
  }
  .game-viewport-card {
    border-radius: var(--radius-md);
  }
  .start-btn-pulse {
    padding: 18px 28px;
    border-radius: 18px;
  }
  .start-play-icon {
    font-size: 2.2rem;
  }
  .start-play-label {
    font-size: 1.1rem;
  }
  .game-details-box {
    padding: 18px;
    border-radius: var(--radius-md);
  }
}
