* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: "Poppins", sans-serif;
}

:root {
  --primary-color: #2041ff;
  --secondary-color: #6ea3ff;
  --accent-color: #ffffff;
  --light-color: #aff3ff;
  --text-color: #000000;
  --white: #ffffff;
  --error-color: #fe615c;
  --success-color: #66cc99;
  --card-bg: rgba(255, 255, 255, 0.9);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}

/* Header styles */
.header-menu {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--secondary-color)
  );
  padding: 0 10%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  border-bottom: 2px solid #fff;
  transition: all 0.3s ease;
}

.header-menu:hover {
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.15);
}

.logo {
  font-size: 28px;
  font-weight: 700;
  color: var(--white);
  text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.2);
  letter-spacing: 1px;
}

.navigation ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
}

.header-menu .navigation ul li {
  position: relative;
}

.header-menu .navigation ul li a {
  font-size: 16px;
  font-weight: 500;
  color: var(--white);
  text-decoration: none;
  padding: 22px 20px;
  display: block;
  transition: all 0.3s ease;
}

.header-menu .navigation ul li a:hover {
  background-color: rgba(255, 255, 255, 0.733);
  transform: translateY(-2px);
  color: var(--primary-color);
}

#toggle,
.header-menu label {
  display: none;
  cursor: pointer;
}

.menu {
  width: 28px;
  height: 28px;
  filter: brightness(0) invert(1);
}

@media (max-width: 950px) {
  .header-menu label {
    display: initial;
  }

  .header-menu {
    padding: 15px 10%;
  }

  .header-menu .navigation {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--primary-color);
    display: none;
    border-radius: 0 0 12px 12px;
  }

  .header-menu .navigation ul {
    flex-direction: column;
  }

  .header-menu .navigation ul li {
    width: 100%;
  }

  .header-menu .navigation ul li a {
    padding: 12px 20px;
  }

  #toggle:checked ~ .navigation {
    display: block;
    animation: slideDown 0.4s ease-out;
  }
}

/* Body styles */
body {
  background: linear-gradient(135deg, hsl(215, 100%, 86%), #3b97ff, #5c9bee);
  margin: 0;
  padding: 0;
  padding-top: 80px;
  min-height: 100vh;
  color: var(--text-color);
  background-size: 400% 400%;
  animation: gradientBG 15s ease infinite;
}

@keyframes gradientBG {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Main content styles */
.main-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 30px;
}

h1 {
  color: var(--white);
  text-align: center;
  margin-bottom: 30px;
  font-size: 2.2rem;
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.2);
}

.instructions {
  background-color: var(--card-bg);
  padding: 20px;
  border-radius: 15px;
  box-shadow: var(--shadow);
  margin-bottom: 30px;
  border-left: 5px solid var(--primary-color);
}

.instructions p {
  font-weight: 500;
  color: var(--primary-color);
}

.question {
  background-color: var(--card-bg);
  padding: 20px;
  margin-bottom: 20px;
  border-radius: 15px;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
}

.question:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.options {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-top: 15px;
}

@media (max-width: 768px) {
  .options {
    grid-template-columns: 1fr;
  }
}

.option {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 15px;
  border-radius: 10px;
  background-color: #e6f7ff;
  transition: all 0.3s;
  cursor: pointer;
  border: 2px solid transparent;
}

.option:hover {
  background-color: #cceeff;
  transform: translateY(-2px);
}

.option input {
  transform: scale(1.3);
  cursor: pointer;
}

.buttons-container {
  display: flex;
  justify-content: center;
  gap: 20px;
  margin: 30px auto;
}

.check-btn,
.reset-btn {
  padding: 15px 30px;
  color: white;
  border: none;
  border-radius: 30px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: all 0.3s;
  display: flex;
  align-items: center;
  gap: 10px;
}

.check-btn {
  background: linear-gradient(
    135deg,
    var(--primary-color),
    var(--secondary-color)
  );
}

.reset-btn {
  background: linear-gradient(135deg, var(--error-color), #e53935);
}

.check-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(32, 65, 255, 0.3);
}

.reset-btn:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 12px rgba(229, 57, 53, 0.3);
}

.progress-container {
  width: 100%;
  height: 20px;
  background-color: #e0e0e0;
  border-radius: 10px;
  margin: 30px 0;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.1);
}

.progress-bar {
  height: 100%;
  background: linear-gradient(135deg, var(--success-color), #4caf50);
  border-radius: 10px;
  width: 0%;
  transition: width 0.5s ease-in-out;
}

.score-display {
  text-align: center;
  font-size: 1.5rem;
  font-weight: 600;
  margin: 20px 0;
  color: var(--primary-color);
}

.result {
  text-align: center;
  font-size: 1.2rem;
  font-weight: 500;
  margin-top: 30px;
  padding: 20px;
  border-radius: 10px;
  background-color: rgba(255, 255, 255, 0.8);
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.correct {
  color: var(--success-color);
  background-color: rgba(76, 175, 80, 0.1);
  border-left: 4px solid var(--success-color);
}

.incorrect {
  color: var(--error-color);
  background-color: rgba(254, 97, 92, 0.1);
  border-left: 4px solid var(--error-color);
}

/* Celebration modal */
.celebration {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2000;
  animation: fadeIn 0.5s;
}

.celebration-content {
  background: white;
  padding: 40px;
  border-radius: 20px;
  text-align: center;
  max-width: 500px;
  animation: zoomIn 0.5s;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
}

.celebration-content::before {
  content: "";
  position: absolute;
  top: -10px;
  left: -10px;
  right: -10px;
  bottom: -10px;
  background: linear-gradient(
    45deg,
    var(--primary-color),
    var(--secondary-color),
    var(--success-color)
  );
  z-index: -1;
  filter: blur(20px);
  opacity: 0.3;
}

.celebration-content h2 {
  color: var(--primary-color);
  font-size: 2rem;
  margin-bottom: 20px;
}

.celebration-content p {
  font-size: 1.2rem;
  margin-bottom: 25px;
  line-height: 1.6;
}

.celebration-content button {
  background: var(--primary-color);
  color: white;
  border: none;
  padding: 12px 25px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: all 0.3s;
}

.celebration-content button:hover {
  transform: scale(1.05);
  box-shadow: 0 5px 15px rgba(32, 65, 255, 0.3);
}

.confetti {
  position: absolute;
  width: 10px;
  height: 10px;
  background-color: #f00;
  border-radius: 50%;
  animation: confettiFall 5s linear forwards;
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes zoomIn {
  from {
    transform: scale(0.8);
    opacity: 0;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

@keyframes confettiFall {
  0% {
    transform: translateY(-100vh) rotate(0deg);
    opacity: 1;
  }
  100% {
    transform: translateY(100vh) rotate(360deg);
    opacity: 0;
  }
}
