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

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  min-height: 100vh;
  color: white;
}

.state {
  display: none;
  min-height: 100vh;
  align-items: center;
  justify-content: center;
}

.state:not(.hidden) {
  display: flex;
}

.container {
  max-width: 800px;
  width: 90%;
  text-align: center;
  padding: 2rem;
}

.container-full {
  width: 100%;
  max-width: 1400px;
  padding: 2rem;
}

/* Loading Spinner */
.spinner {
  border: 4px solid rgba(255, 255, 255, 0.3);
  border-top: 4px solid white;
  border-radius: 50%;
  width: 50px;
  height: 50px;
  animation: spin 1s linear infinite;
  margin: 0 auto 1rem;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Event Header */
.event-header {
  margin-bottom: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.event-header h1 {
  font-size: 2.5rem;
  font-weight: 700;
}

.live-badge {
  background: #ef4444;
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 1rem;
  font-weight: 600;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.7; }
}

.ended-badge {
  background: rgba(255, 255, 255, 0.2);
  padding: 0.5rem 1rem;
  border-radius: 9999px;
  font-size: 1rem;
  font-weight: 600;
}

/* Countdown Timer */
.countdown-timer {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: 1rem;
  padding: 3rem 2rem;
  margin-bottom: 2rem;
}

.countdown-timer h2 {
  font-size: 1.5rem;
  margin-bottom: 2rem;
  font-weight: 500;
}

.timer-display {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
}

.timer-unit {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.timer-value {
  font-size: 4rem;
  font-weight: 700;
  line-height: 1;
  min-width: 100px;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 0.5rem;
  padding: 1rem;
  margin-bottom: 0.5rem;
}

.timer-label {
  font-size: 0.875rem;
  text-transform: uppercase;
  opacity: 0.8;
  font-weight: 500;
}

.scheduled-time {
  margin-top: 2rem;
  font-size: 1.125rem;
  opacity: 0.9;
}

/* Video Container */
.video-container {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  background: rgba(0, 0, 0, 0.3);
  border-radius: 1rem;
  overflow: hidden;
  margin-bottom: 2rem;
}

.video-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: none;
}

/* Powered By */
.powered-by {
  text-align: center;
  opacity: 0.7;
  font-size: 0.875rem;
}

.powered-by strong {
  font-weight: 600;
}

/* Error State */
#error h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
}

#error p {
  font-size: 1.125rem;
  opacity: 0.9;
  margin-bottom: 2rem;
}

/* Responsive */
@media (max-width: 768px) {
  .event-header h1 {
    font-size: 1.75rem;
  }

  .timer-value {
    font-size: 2.5rem;
    min-width: 70px;
  }

  .timer-display {
    gap: 1rem;
  }

  .container-full {
    padding: 1rem;
  }
}