:root {
  color-scheme: dark;
  --bg: #000;
  --panel: rgba(8, 14, 18, 0.92);
  --panel-soft: rgba(15, 24, 28, 0.82);
  --text: #f8fbff;
  --muted: #9eb4bf;
  --cyan: #00d4ff;
  --green: #6cff8f;
  --yellow: #ffe86b;
  --red: #ff6b7a;
  --line: rgba(255, 255, 255, 0.16);
}

* {
  box-sizing: border-box;
}

html,
body {
  width: 600px;
  height: 600px;
  margin: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button {
  font: inherit;
  color: inherit;
}

.app-shell {
  position: relative;
  width: 600px;
  height: 600px;
  padding: 18px;
  background: radial-gradient(circle at 50% 44%, rgba(0, 212, 255, 0.08), transparent 42%), #000;
}

body.fullscreen-active .app-shell {
  visibility: hidden;
}

.topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  height: 58px;
}

.eyebrow {
  margin: 0 0 4px;
  color: var(--muted);
  font-size: 14px;
  font-weight: 850;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  font-size: 32px;
  line-height: 1;
}

.status-pill {
  min-width: 98px;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--yellow);
  font-size: 16px;
  font-weight: 950;
  text-align: center;
  background: rgba(255, 232, 107, 0.08);
}

.timer-face {
  position: relative;
  height: 228px;
  display: grid;
  place-items: center;
}

.time-readout {
  position: absolute;
  z-index: 2;
  color: var(--green);
  font-size: 86px;
  font-weight: 950;
  line-height: 1;
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 18px rgba(108, 255, 143, 0.25);
}

body.timer-done .time-readout {
  color: var(--red);
  text-shadow: 0 0 24px rgba(255, 107, 122, 0.48);
}

.progress-ring {
  width: 220px;
  height: 220px;
}

#timerCanvas {
  width: 220px;
  height: 220px;
}

.controls {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.command {
  min-height: 58px;
  border: 2px solid var(--line);
  border-radius: 8px;
  background: var(--panel-soft);
  font-size: 20px;
  font-weight: 950;
}

.command.primary {
  border-color: rgba(0, 212, 255, 0.5);
  color: var(--cyan);
}

.focusable {
  transition: border-color 150ms ease, box-shadow 150ms ease, transform 150ms ease;
}

.focusable:focus {
  outline: none;
  border-color: var(--cyan);
  box-shadow: 0 0 22px rgba(0, 212, 255, 0.52);
  transform: translateY(-1px);
}

.hidden {
  display: none;
}

.fullscreen-view {
  position: fixed;
  inset: 0;
  z-index: 100;
  width: 600px;
  height: 600px;
  padding: 28px;
  background:
    radial-gradient(circle at 50% 50%, rgba(108, 255, 143, 0.13), transparent 44%),
    #000;
  text-align: center;
  user-select: none;
}

.fullscreen-status {
  height: 38px;
  color: var(--yellow);
  font-size: 22px;
  font-weight: 950;
  text-transform: uppercase;
}

.fullscreen-time {
  height: 342px;
  display: grid;
  place-items: center;
  color: var(--green);
  font-size: 112px;
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  text-shadow: 0 0 28px rgba(108, 255, 143, 0.28);
}

body.timer-done .fullscreen-time {
  color: var(--red);
  text-shadow: 0 0 36px rgba(255, 107, 122, 0.58);
}

body.timer-done .fullscreen-view {
  background:
    radial-gradient(circle at 50% 50%, rgba(255, 107, 122, 0.16), transparent 44%),
    #000;
}

.fullscreen-mode {
  color: var(--cyan);
  font-size: 32px;
  font-weight: 950;
}

.fullscreen-hint {
  margin-top: 42px;
  color: var(--muted);
  font-size: 20px;
  font-weight: 850;
}
