.brk {
  display: flex;
  flex-direction: column;
  gap: var(--space-6);
  align-items: center;
  width: 100%;
}

.brk-face {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  width: 100%;
}

.brk-label {
  margin: 0;
  font-size: var(--text-sm);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  color: var(--c-ink-muted);
}

/* The time of day is the headline: it is what the room needs to read from the
   back, and what people actually set their own watches by. */
.brk-time {
  margin: 0;
  font-variant-numeric: tabular-nums;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  font-size: clamp(4rem, 20vw, 15rem);
  color: var(--hue, var(--c-amber));
}

/* The countdown is the supporting act — useful, but not the thing you shout. */
.brk-countdown {
  margin: 0;
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  font-size: var(--text-xl);
  color: var(--c-ink-muted);
}

.brk-countdown.is-hint {
  font-variant-numeric: normal;
  font-weight: 400;
  font-size: var(--text-base);
  text-align: center;
  text-wrap: balance;
  max-width: 32ch;
}

.brk-face.is-over .brk-time,
.brk-face.is-over .brk-countdown {
  color: var(--c-abort);
}

.brk-face.is-over .brk-time {
  animation: over-pulse 1.4s ease-in-out infinite;
}

@keyframes over-pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.55;
  }
}

@media (prefers-reduced-motion: reduce) {
  .brk-face.is-over .brk-time {
    animation: none;
  }
}

.brk-bar {
  width: 100%;
  max-width: 40rem;
  height: 8px;
  margin-top: var(--space-2);
  border-radius: 999px;
  background: var(--hue-tint, var(--c-amber-tint));
  overflow: hidden;
}

.brk-bar-fill {
  height: 100%;
  background: var(--hue, var(--c-amber));
  transform-origin: left center;
  transition: transform 250ms linear;
}

.brk-face.is-over .brk-bar-fill {
  background: var(--c-abort);
}

.brk-setup {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4) var(--space-6);
  align-items: flex-end;
  justify-content: center;
}

.presets {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.brk-actions {
  display: flex;
  gap: var(--space-3);
  justify-content: center;
}

/* In fullscreen the wall shows the time and nothing else. */
.toy.is-fullscreen .brk {
  justify-content: center;
  height: 100%;
}

.toy.is-fullscreen .brk-setup,
.toy.is-fullscreen .brk-actions {
  opacity: 0;
  transition: opacity 200ms ease;
}

.toy.is-fullscreen .brk-setup:focus-within,
.toy.is-fullscreen:hover .brk-setup,
.toy.is-fullscreen:hover .brk-actions {
  opacity: 1;
}
