:root {
  color-scheme: light;
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  padding: 1rem;
  display: flex;
  justify-content: center;
  align-items: center;
  background: radial-gradient(circle at 15% 15%, #dbeafe, #eef2ff 45%, #f8fafc);
  color: #0f172a;
}

.quiz {
  width: 100%;
  max-width: 42rem;
  padding: 1.25rem;
  border-radius: 1.25rem;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 12px 30px rgba(15, 23, 42, 0.15);
}

.quiz-header h1 {
  margin: 0;
  font-size: 1.6rem;
}

.intro {
  margin: 0.65rem 0 0;
  color: #475569;
  line-height: 1.45;
}

.progress {
  margin: 1rem 0 0.85rem;
  font-size: 0.95rem;
  color: #334155;
  font-weight: 600;
}

.question-card {
  border-radius: 1rem;
  padding: 1rem;
  background: linear-gradient(150deg, #f8fafc, #eef2ff);
  border: 1px solid #dbeafe;
}

.question-card.enter {
  animation: fade-slide 240ms ease;
}

.question {
  margin: 0;
  font-size: 1.1rem;
  line-height: 1.4;
}

.choices {
  margin-top: 0.9rem;
  display: grid;
  gap: 0.65rem;
}

button {
  border: 0;
  border-radius: 0.85rem;
  min-height: 3rem;
  width: 100%;
  padding: 0.75rem 0.95rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: transform 120ms ease, box-shadow 180ms ease, background-color 180ms ease, opacity 180ms ease;
}

.choice {
  color: #0f172a;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  text-align: left;
}

.choice:hover,
.choice:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(37, 99, 235, 0.14);
}

.choice:active {
  transform: scale(0.99);
}

.choice.selected {
  background: #dbeafe;
  border-color: #3b82f6;
}

.actions {
  margin-top: 1rem;
  display: grid;
  gap: 0.6rem;
}

#nextButton {
  background: #2563eb;
  color: #ffffff;
}

#nextButton:hover,
#nextButton:focus-visible {
  background: #1d4ed8;
}

#nextButton:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.secondary {
  background: #334155;
  color: #ffffff;
}

.secondary:hover,
.secondary:focus-visible {
  background: #1e293b;
}

.feedback {
  min-height: 1.6rem;
  margin: 0.9rem 0 0;
  color: #0f766e;
  font-weight: 600;
}

.hidden {
  display: none;
}

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

@media (min-width: 768px) {
  .quiz {
    padding: 1.6rem;
  }

  .quiz-header h1 {
    font-size: 1.9rem;
  }

  .question {
    font-size: 1.2rem;
  }
}
