@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600&display=swap');

:root {
  --background-color: #f0f2f5;
  --container-bg: #ffffff;
  --primary-color: #1DB954;
  --text-color: #333;
  --shadow-color: rgba(0, 0, 0, 0.1);
  --glow-color: rgba(29, 185, 84, 0.4);
  --toggle-btn-bg: #ddd;
}

body.dark-mode {
  --background-color: #121212;
  --container-bg: #1e1e1e;
  --text-color: #e0e0e0;
  --shadow-color: rgba(0, 0, 0, 0.5);
  --glow-color: rgba(29, 185, 84, 0.2);
  --toggle-btn-bg: #333;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  transition: background-color 0.3s ease, color 0.3s ease;
}

body {
  font-family: 'Poppins', sans-serif;
  background-color: var(--background-color);
  color: var(--text-color);
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 100vh;
}

.theme-toggle {
  position: absolute;
  top: 20px;
  right: 20px;
}

#theme-btn {
  background-color: var(--toggle-btn-bg);
  border: none;
  padding: 0.5rem 1rem;
  border-radius: 20px;
  cursor: pointer;
  font-size: 1.2rem;
  box-shadow: 0 2px 5px var(--shadow-color);
  transition: transform 0.2s ease;
}

#theme-btn:active {
  transform: scale(0.9);
}

.container {
  background-color: var(--container-bg);
  padding: 2rem;
  border-radius: 15px;
  box-shadow: 0 10px 20px var(--shadow-color);
  text-align: center;
  max-width: 400px;
  width: 90%;
}

h1 {
  margin-bottom: 2rem;
  font-weight: 600;
  font-size: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

#icon {
  display: inline-block;
  margin-right: 0.5rem;
  animation: spin 2s linear infinite;
}

.numbers {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.number {
  background-color: var(--primary-color);
  color: #fff;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 1.5rem;
  font-weight: 600;
  box-shadow: 0 4px 8px var(--shadow-color);
  transform: scale(0);
  animation: pop-in 0.5s forwards;
}

.number:nth-child(1) { animation-delay: 0.1s; }
.number:nth-child(2) { animation-delay: 0.2s; }
.number:nth-child(3) { animation-delay: 0.3s; }
.number:nth-child(4) { animation-delay: 0.4s; }
.number:nth-child(5) { animation-delay: 0.5s; }
.number:nth-child(6) { animation-delay: 0.6s; }

#generate {
  background-color: var(--primary-color);
  color: #fff;
  border: none;
  padding: 1rem 2rem;
  border-radius: 10px;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  box-shadow: 0 5px 15px var(--glow-color);
  transition: all 0.3s ease;
}

#generate:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px var(--glow-color);
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes pop-in {
  to {
    transform: scale(1);
  }
}
