/* The control page: near-neutral slate surfaces, purple only as an accent, ember for the one primary action. */
:root {
  --ground: #181b2a;      /* slate, darkened toward neutral */
  --surface: #20253a;
  --surface-2: #2c3350;   /* brand slate */
  --line: #3a4263;
  --muted: #a7adc4;
}
html { background: var(--ground); }
body { min-height: 100vh; display: flex; flex-direction: column; }
.wrap { width: min(40rem, 100% - 2 * var(--gutter)); margin-inline: auto; padding-block: 2.5rem; }
header { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 2rem; }
.brand { display: flex; align-items: center; gap: .75rem; }
.brand img { width: 2.25rem; height: auto; }
.brand h1 { margin: 0; font-size: var(--step-1); font-weight: 400; letter-spacing: .02em; }
.who { color: var(--muted); font-size: var(--step--1); text-align: right; overflow-wrap: anywhere; }
.who button { margin-left: .5rem; }
main.card { background: var(--surface); border: 1px solid var(--line); border-radius: 6px; padding: 1.5rem; }
.state { display: flex; align-items: center; gap: .75rem; margin: 0 0 .25rem; font-size: var(--step-2); line-height: 1.1; }
.dot { width: .8rem; height: .8rem; background: var(--muted); flex: none; }
.state[data-state="on"] .dot { background: var(--rune); }
.state[data-state="starting"] .dot, .state[data-state="stopping"] .dot { background: var(--heather); animation: pulse 1.2s steps(2) infinite; }
@keyframes pulse { 50% { opacity: .25; } }
.detail { margin: 0 0 1.5rem; color: var(--muted); font-size: var(--step--1); min-height: 1.4em; }
.hours { display: flex; align-items: center; gap: .75rem; margin-bottom: 1.25rem; }
.hours label { color: var(--muted); }
.hours input {
  width: 4.5rem; padding: .35rem .5rem; font: inherit; color: var(--vellum);
  background: var(--ground); border: 1px solid var(--line); border-radius: 4px;
}
.hours .unit { color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; }
button {
  font: inherit; color: var(--vellum); background: var(--surface-2); border: 1px solid var(--line);
  border-radius: 4px; padding: .5rem 1rem; cursor: pointer;
}
button:hover:not(:disabled) { border-color: var(--heather); }
button:disabled { opacity: .4; cursor: not-allowed; }
button.primary { background: var(--ember); border-color: var(--ember); color: var(--night); }
button.primary:hover:not(:disabled) { filter: brightness(1.08); border-color: var(--ember); }
button.link { background: none; border: none; padding: 0; color: var(--heather); text-decoration: underline; }
.open { display: inline-block; margin-top: 1.25rem; padding: .5rem 1rem; border: 1px solid var(--heather); border-radius: 4px; color: var(--vellum); text-decoration: none; }
.open:hover { background: var(--surface-2); }
.msg { margin: 1rem 0 0; min-height: 1.4em; font-size: var(--step--1); color: var(--muted); }
.msg.err { color: var(--ember); }
footer { margin-top: 1.5rem; color: var(--muted); font-size: var(--step--1); }
[hidden] { display: none !important; }
.center { text-align: center; }
.state.centered { justify-content: center; }
