:root {
  color-scheme: dark;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #111217;
  color: #f5f5f5;
}

.app {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 2rem;
  align-items: center;
}

.title {
  font-size: clamp(1.5rem, 2vw + 0.8rem, 2.5rem);
  font-weight: 400;
  margin: 0;
  letter-spacing: 0.08em;
}

.timers {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  justify-content: center;
}

.timer {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 1rem;
  padding: 1.5rem 2rem;
  min-width: 180px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  transition: background 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
  border: 2px solid rgba(72, 220, 148, 0.6);
  cursor: pointer;
}

.timer.running {
  border-color: transparent;
}

.timer.starting {
  animation: timer-activate 0.45s ease-out;
}

.timer-label {
  font-size: 1.1rem;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}

.timer-display {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.1em;
}

.timer.expired {
  background: #862525;
  border-color: #ff5a5a;
}

.timer.expired .timer-display {
  animation: flash 0.5s ease-in-out 2;
}

.timer:focus-visible {
  outline: 3px solid #ff5a5a;
  outline-offset: 4px;
}

.instructions {
  font-size: 1rem;
  opacity: 0.75;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  align-items: center;
}

.instructions p {
  margin: 0;
}

.instructions ul {
  margin: 0;
  padding-left: 1.25rem;
  text-align: left;
}

.instructions li {
  list-style-position: inside;
}

.credits {
  margin: 0;
  font-size: 0.9rem;
  color: #f5f5f5;
}

@media (max-width: 640px) {
  .title,
  .instructions,
  .credits {
    padding-inline: 1.5rem;
  }
}

.credit-name {
  position: relative;
  color: #b3b7c6;
  cursor: default;
  transition: color 0.2s ease;
}

.credit-name:hover,
.credit-name:focus-visible {
  color: #d7dbe9;
}

.support {

  display: flex;
  justify-content: center;
  margin-bottom: 1rem;
}

.support .bmc-btn {
  transform: scale(0.63);
  transform-origin: center;
}

@keyframes timer-activate {
  0% {
    transform: scale(1);
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(72, 220, 148, 0.6);
    box-shadow: 0 0 0 0 rgba(72, 220, 148, 0);
  }
  50% {
    transform: scale(1.05);
    background: rgba(72, 220, 148, 0.35);
    border-color: rgba(114, 245, 180, 0.7);
    box-shadow: 0 0 18px 6px rgba(72, 220, 148, 0.35);
  }
  100% {
    transform: scale(1);
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(72, 220, 148, 0.6);
    box-shadow: 0 0 0 0 rgba(72, 220, 148, 0);
  }
}

@keyframes flash {
  from {
    opacity: 1;
  }
  50% {
    opacity: 0.4;
  }
  to {
    opacity: 1;
  }
}
