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

body {
  font-family: "Segoe UI", Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f0f2f5;
}

header {
  background-color: #3498db;
  color: white;
  padding: 2rem 1rem;
  text-align: center;
  margin-bottom: 2rem;
}

h1 {
  font-size: 2.5rem;
  margin-bottom: 0.5rem;
  color: white;
}

header p {
  max-width: 65ch;
  margin-inline: auto;
  opacity: 0.9;
}

main {
  max-width: 600px;
  margin: 0 auto 3rem auto;
  background-color: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: #2c3e50;
  text-align: center;
  border-bottom: 2px solid #f4f4f4;
  padding-bottom: 0.5rem;
}

#timer-section {
  background: #cfe5ff;

  border: 2px solid #edf2f7;
  border-radius: 12px;

  padding: 2.5rem 1rem;
  margin-bottom: 2.5rem;

  display: flex;
  flex-direction: column;
  align-items: center;

  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
    0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

#timer-display {
  font-size: 1.1rem;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: #002049;
  margin-bottom: 0.5rem;
}

#time-value {
  font-size: 4.5rem;
  font-weight: 800;
  color: #2d3748;
  line-height: 1;
}
#timer-controls {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 3rem;
}

#dynamic-buttons {
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 10px;
}

#instructions {
  font-size: 0.95rem;
  color: #555;
  text-align: left;
}

.instructions-list {
  margin-top: 1rem;
  padding-left: 1.5rem;
}

.instructions-list li {
  margin-bottom: 0.5rem;
}

.timer-control-button {
  padding: 0.8rem 1.5rem;
  margin: 0.5rem;
  font-size: 1rem;
  background-color: #3498db;
  border: none;
  border-radius: 50px;
  color: #fff;
  cursor: pointer;
  transition: transform 0.2s, background-color 0.2s;
  font-weight: bold;
}

#time-value {
  font-size: 3.5rem;
  font-weight: 800;
  color: #2c3e50;
  display: inline-block;
  min-width: 1.5ch;
  text-align: center;
}
.timer-control-button:hover {
  background-color: #2980b9;
  transform: translateY(-2px);
}

footer {
  text-align: center;
  padding: 2rem;
  color: #888;
  font-size: 0.8rem;
}

#how-it-works {
  background-color: #f8f9fa;
  border-left: 5px solid #3498db;
  padding: 1.5rem;
  margin-top: 2rem;
  border-radius: 4px;
  text-align: left;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

#how-it-works h2 {
  font-size: 1.4rem;
  color: #2c3e50;
  margin-bottom: 1rem;
  border-bottom: none;
}

.explanation-list {
  list-style: none;
  padding: 0;
}

.explanation-list li {
  margin-bottom: 1.2rem;
  line-height: 1.6;
  color: #444;
}

.explanation-list strong {
  color: #2c3e50;
  display: block;
  margin-bottom: 0.2rem;
}

code {
  background-color: #eef1f5;
  color: #bb246d;
  font-weight: bold;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: Consolas, "Courier New", monospace;
  font-size: 0.9em;
}
