/* ============================================
   Quick Draw - Designed UI
   ============================================ */

:root {
  /* Primary Palette - Playful Purple */
  --primary: #8B5CF6;
  --primary-light: #A78BFA;
  --primary-dark: #7C3AED;
  
  /* Secondary - Vibrant Coral */
  --secondary: #F472B6;
  --secondary-light: #F9A8D4;
  
  /* Accent - Electric Teal */
  --accent: #2DD4BF;
  --accent-light: #5EEAD4;
  
  /* Status Colors */
  --success: #10B981;
  --warning: #F59E0B;
  --danger: #EF4444;
  
  /* Neutrals */
  --bg-dark: #0F172A;
  --bg-card: #1E293B;
  --bg-elevated: #334155;
  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  --border: #475569;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(139, 92, 246, 0.4);
  
  /* Gradients */
  --gradient-primary: linear-gradient(135deg, #8B5CF6 0%, #6366F1 100%);
  --gradient-coral: linear-gradient(135deg, #F472B6 0%, #EC4899 100%);
  --gradient-teal: linear-gradient(135deg, #2DD4BF 0%, #14B8A6 100%);
  --gradient-bg: radial-gradient(ellipse at top, #1E293B 0%, #0F172A 100%);
  
  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;
  --transition-slow: 400ms ease;
}

/* ============================================
   Base Styles
   ============================================ */

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

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--gradient-bg);
  background-attachment: fixed;
  color: var(--text-primary);
  min-height: 100vh;
  line-height: 1.6;
}

/* Background Pattern */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-image: 
    radial-gradient(circle at 20% 80%, rgba(139, 92, 246, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 20%, rgba(244, 114, 182, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 40%, rgba(45, 212, 191, 0.05) 0%, transparent 40%);
  pointer-events: none;
  z-index: -1;
}

#app {
  max-width: 1400px;
  margin: 0 auto;
  padding: 24px;
  min-height: 100vh;
}

/* ============================================
   Screen Transitions
   ============================================ */

.screen {
  animation: screenIn 0.4s var(--transition-normal) forwards;
}

.screen.hidden {
  display: none;
  animation: none;
}

@keyframes screenIn {
  from {
    opacity: 0;
    transform: translateY(20px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* ============================================
   Login Screen - Hero Design
   ============================================ */

#login-screen {
  min-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
}

/* Logo/Title */
#login-screen h1 {
  font-size: 4.5rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary-light) 0%, var(--secondary) 50%, var(--accent-light) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 8px;
  letter-spacing: -2px;
  text-shadow: 0 0 60px rgba(139, 92, 246, 0.5);
  animation: titleFloat 3s ease-in-out infinite;
}

@keyframes titleFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.tagline {
  color: var(--text-secondary);
  font-size: 1.25rem;
  margin-bottom: 48px;
  font-weight: 400;
}

/* Floating Shapes */
.floating-shapes {
  position: absolute;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
  z-index: -1;
}

.shape {
  position: absolute;
  border-radius: var(--radius-full);
  opacity: 0.15;
  animation: float 6s ease-in-out infinite;
}

.shape-1 {
  width: 300px;
  height: 300px;
  background: var(--primary);
  top: -100px;
  left: -100px;
  animation-delay: 0s;
}

.shape-2 {
  width: 200px;
  height: 200px;
  background: var(--secondary);
  bottom: 10%;
  right: 5%;
  animation-delay: 2s;
}

.shape-3 {
  width: 150px;
  height: 150px;
  background: var(--accent);
  top: 40%;
  right: 15%;
  animation-delay: 4s;
}

@keyframes float {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(30px, -30px) rotate(5deg); }
  66% { transform: translate(-20px, 20px) rotate(-5deg); }
}

/* Form Container */
.form-group {
  background: var(--bg-card);
  padding: 32px;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg), var(--shadow-glow);
  border: 1px solid var(--border);
  width: 100%;
  max-width: 380px;
}

.form-group input {
  width: 100%;
  padding: 16px 20px;
  background: var(--bg-elevated);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 1rem;
  transition: all var(--transition-normal);
  margin-bottom: 16px;
}

.form-group input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.2);
}

.form-group input::placeholder {
  color: var(--text-muted);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  border: none;
  border-radius: var(--radius-md);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition-normal);
  text-decoration: none;
}

.btn.primary {
  background: var(--gradient-primary);
  color: white;
  box-shadow: var(--shadow-md), 0 0 20px rgba(139, 92, 246, 0.3);
}

.btn.primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(139, 92, 246, 0.5);
}

.btn.primary:active {
  transform: translateY(0);
}

.btn.secondary {
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border);
}

.btn.secondary:hover {
  background: var(--border);
  border-color: var(--text-muted);
}

.btn.danger {
  background: var(--danger);
  color: white;
}

.btn.warning {
  background: var(--warning);
  color: var(--bg-dark);
}

.btn.big {
  padding: 18px 36px;
  font-size: 1.125rem;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none !important;
}

/* Button Group */
.btn-group {
  display: flex;
  gap: 12px;
  margin-top: 8px;
}

.btn-group .btn {
  flex: 1;
}

/* Join Form Toggle */
#join-form {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
  display: none;
}

#join-form.visible {
  display: block;
  animation: slideDown 0.3s ease;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

#join-form input {
  width: 120px;
  text-transform: uppercase;
  letter-spacing: 4px;
  text-align: center;
  font-weight: 700;
  font-size: 1.25rem;
}

#join-form .btn {
  flex: 0;
  padding: 16px 24px;
}

/* ============================================
   Lobby Screen
   ============================================ */

.lobby-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
}

.lobby-header h2 {
  font-size: 1.5rem;
  font-weight: 700;
}

.room-code-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-card);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
}

.room-code-badge code {
  font-family: 'JetBrains Mono', monospace;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 3px;
}

.lobby-content {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 32px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}

/* Players List */
.players-section {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  margin-bottom: 32px;
}

.players-list h3,
.lobby-settings h3 {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

#players-ul {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

#players-ul li {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  padding: 12px 20px;
  border-radius: var(--radius-full);
  font-weight: 500;
  border: 1px solid var(--border);
  transition: all var(--transition-normal);
}

#players-ul li::before {
  content: '🎨';
}

#players-ul li.is-host {
  border-color: var(--warning);
  background: rgba(245, 158, 11, 0.1);
}

#players-ul li.is-host::after {
  content: '👑';
  margin-left: 4px;
}

/* Settings */
.lobby-settings {
  background: var(--bg-elevated);
  padding: 24px;
  border-radius: var(--radius-lg);
}

.setting {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 16px;
}

.setting:last-child {
  margin-bottom: 0;
}

.setting label {
  font-weight: 500;
  color: var(--text-secondary);
  min-width: 100px;
}

.setting select {
  padding: 10px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 1rem;
  cursor: pointer;
}

.setting select:focus {
  outline: none;
  border-color: var(--primary);
}

/* Start Button */
#btn-start {
  width: 100%;
  padding: 20px;
  font-size: 1.25rem;
  border-radius: var(--radius-lg);
}

/* Waiting State */
.waiting-indicator {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 20px;
  color: var(--text-secondary);
  font-size: 1.125rem;
}

.waiting-dots {
  display: flex;
  gap: 4px;
}

.waiting-dots span {
  width: 8px;
  height: 8px;
  background: var(--primary);
  border-radius: 50%;
  animation: waitingPulse 1.4s ease-in-out infinite;
}

.waiting-dots span:nth-child(2) { animation-delay: 0.2s; }
.waiting-dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes waitingPulse {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

/* ============================================
   Category Selection
   ============================================ */

#category-screen {
  min-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px;
}

#category-screen h2 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 8px;
  background: var(--gradient-teal);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.drawer-info {
  color: var(--text-secondary);
  font-size: 1.25rem;
  margin-bottom: 40px;
}

.category-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  max-width: 800px;
  width: 100%;
}

.category-card {
  background: var(--bg-card);
  border: 2px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 24px;
  cursor: pointer;
  transition: all var(--transition-normal);
  font-size: 1.25rem;
  font-weight: 600;
}

.category-card:hover {
  border-color: var(--primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg), 0 0 30px rgba(139, 92, 246, 0.3);
  background: var(--bg-elevated);
}

.category-card.selected {
  border-color: var(--accent);
  background: rgba(45, 212, 191, 0.1);
}

/* Category Icons */
.category-card[data-category="Animals"]::before { content: '🦁 '; }
.category-card[data-category="Objects"]::before { content: '🧊 '; }
.category-card[data-category="Actions"]::before { content: '💃 '; }
.category-card[data-category="Food"]::before { content: '🍕 '; }
.category-card[data-category="Places"]::before { content: '🏝️ '; }
.category-card[data-category="Random"]::before { content: '🎲 '; }

/* ============================================
   Game Screen
   ============================================ */

.game-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-card);
  padding: 20px 28px;
  border-radius: var(--radius-lg);
  margin-bottom: 24px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.game-info {
  display: flex;
  align-items: center;
  gap: 24px;
}

#game-status {
  font-weight: 700;
  color: var(--primary-light);
  font-size: 1.125rem;
}

#drawer-info {
  color: var(--text-secondary);
  padding: 8px 16px;
  background: var(--bg-elevated);
  border-radius: var(--radius-full);
}

#drawer-info.drawing {
  background: rgba(244, 114, 182, 0.2);
  color: var(--secondary);
}

/* Timer */
.timer {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-elevated);
  padding: 12px 24px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--border);
  transition: all var(--transition-normal);
}

.timer.urgent {
  border-color: var(--danger);
  background: rgba(239, 68, 68, 0.1);
  animation: timerPulse 1s ease-in-out infinite;
}

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

#timer-display {
  font-size: 2rem;
  font-weight: 800;
  font-family: 'JetBrains Mono', monospace;
  color: var(--text-primary);
}

.timer.urgent #timer-display {
  color: var(--danger);
}

/* Game Layout */
.game-content {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 24px;
}

/* Canvas Area */
.canvas-area {
  background: var(--bg-card);
  border-radius: var(--radius-xl);
  padding: 24px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
  position: relative;
}

#drawing-canvas {
  border: 3px solid var(--border);
  border-radius: var(--radius-md);
  cursor: crosshair;
  display: block;
  width: 100%;
  background: #FFFFFF;
  transition: border-color var(--transition-normal);
}

#drawing-canvas:hover {
  border-color: var(--primary-light);
}

#drawing-canvas.disabled {
  cursor: not-allowed;
  opacity: 0.7;
}

/* Word Display */
.word-display {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(15, 23, 42, 0.95);
  color: white;
  padding: 20px 40px;
  border-radius: var(--radius-lg);
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 8px;
  box-shadow: var(--shadow-lg);
  border: 2px solid var(--border);
  z-index: 10;
}

.word-display.hidden {
  display: none;
}

/* Sidebar */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.scores,
.chat {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 20px;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.scores {
  max-height: 200px;
  overflow-y: auto;
}

.scores h3,
.chat h3 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

#scores-ul {
  list-style: none;
}

#scores-ul li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

#scores-ul li:last-child {
  border-bottom: none;
}

#scores-ul li .player-name {
  font-weight: 500;
}

#scores-ul li .score-value {
  font-weight: 700;
  color: var(--accent);
  font-family: 'JetBrains Mono', monospace;
}

/* Chat */
.chat {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 350px;
}

#chat-messages {
  flex: 1;
  overflow-y: auto;
  margin-bottom: 16px;
  padding: 12px;
  background: var(--bg-elevated);
  border-radius: var(--radius-md);
  min-height: 200px;
}

.chat-message {
  margin-bottom: 8px;
  padding: 10px 14px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  font-size: 0.9375rem;
}

.chat-message.correct {
  background: linear-gradient(135deg, rgba(16, 185, 129, 0.2) 0%, rgba(45, 212, 191, 0.1) 100%);
  border: 1px solid var(--success);
  color: var(--success);
  font-weight: 600;
}

.chat-message.wrong {
  color: var(--text-muted);
  font-style: italic;
  font-size: 0.875rem;
}

.chat-message .player {
  font-weight: 600;
  color: var(--primary-light);
  margin-right: 8px;
}

/* Guess Input */
#guess-input {
  width: 100%;
  padding: 14px 18px;
  background: var(--bg-elevated);
  border: 2px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-size: 1rem;
  transition: all var(--transition-normal);
}

#guess-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 4px rgba(139, 92, 246, 0.2);
}

#guess-input:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Game Controls */
.game-controls {
  margin-top: 20px;
  background: var(--bg-card);
  padding: 16px 20px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  border: 1px solid var(--border);
}

/* Color Buttons */
.color-btn {
  width: 40px;
  height: 40px;
  border: 3px solid transparent;
  border-radius: 50%;
  cursor: pointer;
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.color-btn:hover {
  transform: scale(1.15);
}

.color-btn.active {
  border-color: white;
  box-shadow: 0 0 0 3px var(--primary), var(--shadow-md);
  transform: scale(1.1);
}

.color-btn.black { background: #1E293B; }
.color-btn.red { background: #EF4444; }
.color-btn.blue { background: #3B82F6; }
.color-btn.green { background: #22C55E; }
.color-btn.yellow { background: #EAB308; }
.color-btn.orange { background: #F97316; }
.color-btn.purple { background: #A855F7; }
.color-btn.pink { background: #EC4899; }
.color-btn.brown { background: #92400E; }
.color-btn.white { background: #F8FAFC; border: 2px solid var(--border); }

/* Clear Button */
.btn-clear {
  margin-left: auto;
  padding: 10px 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-normal);
}

.btn-clear:hover {
  background: var(--danger);
  color: white;
  border-color: var(--danger);
}

.btn-clear:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* ============================================
   Game Over Screen
   ============================================ */

#gameover-screen {
  min-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px;
}

#gameover-screen h1 {
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 32px;
  background: var(--gradient-coral);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  animation: celebrateIn 0.6s ease;
}

@keyframes celebrateIn {
  0% { transform: scale(0.5); opacity: 0; }
  50% { transform: scale(1.1); }
  100% { transform: scale(1); opacity: 1; }
}

/* Winner Card */
.winner {
  background: linear-gradient(135deg, #F59E0B 0%, #D97706 100%);
  padding: 40px 60px;
  border-radius: var(--radius-xl);
  margin-bottom: 40px;
  box-shadow: var(--shadow-lg), 0 0 40px rgba(245, 158, 11, 0.4);
  animation: winnerGlow 2s ease-in-out infinite;
}

@keyframes winnerGlow {
  0%, 100% { box-shadow: var(--shadow-lg), 0 0 40px rgba(245, 158, 11, 0.4); }
  50% { box-shadow: var(--shadow-lg), 0 0 60px rgba(245, 158, 11, 0.6); }
}

.winner h2 {
  font-size: 2rem;
  color: white;
}

.winner .trophy {
  font-size: 4rem;
  display: block;
  margin-bottom: 16px;
  animation: trophyBounce 1s ease-in-out infinite;
}

@keyframes trophyBounce {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

/* Final Scores */
.final-scores {
  width: 100%;
  max-width: 400px;
  margin-bottom: 40px;
}

.final-scores h3 {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-bottom: 16px;
}

.final-scores ul {
  background: var(--bg-card);
  border-radius: var(--radius-lg);
  padding: 8px;
  list-style: none;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
}

.final-scores li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  border-radius: var(--radius-md);
  font-size: 1.125rem;
  transition: all var(--transition-normal);
}

.final-scores li:first-child {
  background: rgba(139, 92, 246, 0.1);
  border: 1px solid var(--primary);
}

.final-scores li .rank {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-elevated);
  border-radius: 50%;
  font-weight: 700;
  margin-right: 12px;
}

.final-scores li:first-child .rank {
  background: var(--gradient-primary);
  color: white;
}

.final-scores li .player-name {
  flex: 1;
  text-align: left;
}

.final-scores li .score-value {
  font-weight: 700;
  color: var(--accent);
  font-family: 'JetBrains Mono', monospace;
}

/* Game Over Buttons */
#gameover-screen .btn-group {
  display: flex;
  gap: 16px;
}

/* ============================================
   Responsive Design
   ============================================ */

@media (max-width: 1024px) {
  .game-content {
    grid-template-columns: 1fr;
  }
  
  .sidebar {
    flex-direction: row;
  }
  
  .sidebar > * {
    flex: 1;
  }
}

@media (max-width: 768px) {
  #login-screen h1 {
    font-size: 3rem;
  }
  
  .form-group {
    padding: 24px;
  }
  
  .players-section {
    grid-template-columns: 1fr;
  }
  
  .category-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .game-header {
    flex-direction: column;
    gap: 16px;
    text-align: center;
  }
  
  .game-info {
    flex-direction: column;
    gap: 12px;
  }
  
  .sidebar {
    flex-direction: column;
  }
  
  .game-controls {
    justify-content: center;
  }
  
  .btn-clear {
    margin-left: 0;
    width: 100%;
  }
}

@media (max-width: 480px) {
  #app {
    padding: 16px;
  }
  
  #login-screen h1 {
    font-size: 2.5rem;
  }
  
  .tagline {
    font-size: 1rem;
  }
  
  .category-grid {
    grid-template-columns: 1fr;
  }
  
  .winner {
    padding: 24px 32px;
  }
  
  .winner h2 {
    font-size: 1.5rem;
  }
  
  #gameover-screen .btn-group {
    flex-direction: column;
    width: 100%;
  }
  
  #gameover-screen .btn-group .btn {
    width: 100%;
  }
}

/* ============================================
   Utility Classes
   ============================================ */

.hidden {
  display: none !important;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* Scrollbar Styling */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--bg-elevated);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--text-muted);
}
