/* Tempo. An instrument: cool grey ground, white panels, ink for everything
   normal, colour only where something needs attention. Rain is the one
   measurement that is always blue. */

@font-face {
  font-family: 'Atkinson Next';
  src: url('/vendor/font/atkinson-hyperlegible-next-latin-wght-normal.woff2') format('woff2-variations');
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Atkinson Next';
  src: url('/vendor/font/atkinson-hyperlegible-next-latin-ext-wght-normal.woff2') format('woff2-variations');
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

:root {
  --ground: #e7ebf0;
  --panel: #ffffff;
  --ink: #131c26;
  --ink-2: #45525f;
  --line: #cdd5dd;
  --line-soft: #e3e8ee;
  --rain-1: #86b9ea;
  --rain-2: #2f7fd1;
  --rain-3: #0b3f85;
  --rain-ink: #0f5aa8;
  --watch: #8a4b00;
  --watch-bg: #fdf1dc;
  --watch-line: #e2a03a;
  --danger: #a3211a;
  --danger-bg: #fbe6e3;
  --danger-line: #d0453b;
  --focus: #0f5aa8;
  --radius: 5px;
  --rail: 0px;
  --tabs: 62px;
  font-family: 'Atkinson Next', system-ui, -apple-system, 'Segoe UI', sans-serif;
  font-size: 100%;
  line-height: 1.45;
  color: var(--ink);
  background: var(--ground);
}

@media (prefers-color-scheme: dark) {
  :root {
    --ground: #0e141b;
    --panel: #161f29;
    --ink: #e9eef3;
    --ink-2: #a7b4c1;
    --line: #2c3947;
    --line-soft: #212c38;
    --rain-1: #2f6fb0;
    --rain-2: #4d9ae6;
    --rain-3: #a5d0ff;
    --rain-ink: #7fbcff;
    --watch: #ffc56b;
    --watch-bg: #2e2412;
    --watch-line: #a8741f;
    --danger: #ff9d94;
    --danger-bg: #35191a;
    --danger-line: #b8473f;
    --focus: #7fbcff;
  }
}

* {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
body {
  margin: 0;
  min-height: 100dvh;
  padding-bottom: calc(var(--tabs) + env(safe-area-inset-bottom));
}
h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
  padding: 0;
}
ul,
ol {
  list-style: none;
}
button,
input {
  font: inherit;
  color: inherit;
}
button {
  cursor: pointer;
}
svg {
  display: block;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 2px;
}
[hidden] {
  display: none !important;
}

.skip {
  position: absolute;
  left: 8px;
  top: -60px;
  z-index: 2000;
  background: var(--ink);
  color: var(--panel);
  padding: 10px 14px;
  border-radius: var(--radius);
}
.skip:focus {
  top: 8px;
}

/* Top bar: where, and how fresh. */
.top {
  position: sticky;
  top: 0;
  z-index: 1100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 14px;
  padding-top: calc(8px + env(safe-area-inset-top));
  background: var(--ground);
  border-bottom: 1px solid var(--line);
  margin-left: var(--rail);
}
.top button {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  padding: 6px 10px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  background: none;
}
.top button:hover {
  border-color: var(--line);
  background: var(--panel);
}
.top svg,
.tabs svg,
.close svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.place {
  font-weight: 700;
  font-size: 1.0625rem;
  margin-left: -10px;
  min-width: 0;
}
.place span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.refresh {
  color: var(--ink-2);
  font-size: 0.875rem;
  font-variant-numeric: tabular-nums;
  margin-right: -10px;
  flex: none;
}
.refresh.busy svg {
  animation: turn 0.9s linear infinite;
}
@keyframes turn {
  to {
    transform: rotate(360deg);
  }
}

/* Sections: a bar along the bottom on a phone, a rail on the left on a desk. */
.tabs {
  position: fixed;
  inset: auto 0 0 0;
  z-index: 1200;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  background: var(--panel);
  border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom);
}
.tabs button {
  position: relative;
  display: grid;
  justify-items: center;
  gap: 2px;
  min-height: var(--tabs);
  padding: 9px 4px 7px;
  border: 0;
  background: none;
  color: var(--ink-2);
  font-size: 0.8125rem;
}
.tabs button[aria-current='page'] {
  color: var(--ink);
  font-weight: 700;
  box-shadow: inset 0 3px 0 var(--ink);
}
.tabs .dot {
  position: absolute;
  top: 8px;
  left: calc(50% + 9px);
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--watch-line);
  border: 2px solid var(--panel);
  box-sizing: content-box;
}
.tabs .dot.danger {
  background: var(--danger-line);
}

main {
  margin-left: var(--rail);
  outline: none;
}
.view {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 14px;
  padding: 14px;
  max-width: 720px;
  margin: 0 auto;
}

/* The verdict: one sentence that answers the screen's question. */
.verdict {
  border-left: 3px solid var(--ink);
  padding: 2px 0 2px 14px;
}
.verdict h1 {
  font-size: clamp(1.75rem, 6.2vw, 2.5rem);
  line-height: 1.08;
  font-weight: 750;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.verdict p {
  margin-top: 8px;
  color: var(--ink-2);
  max-width: 34em;
}
.verdict.wet {
  border-left-color: var(--rain-2);
}
.verdict.watch {
  border-left-color: var(--watch-line);
}
.verdict.watch h1 {
  color: var(--watch);
}
.verdict.danger {
  border-left-color: var(--danger-line);
}
.verdict.danger h1 {
  color: var(--danger);
}

.panel {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 14px;
}
.panel > h2 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 2px;
}
.panel > h2 + .sub {
  color: var(--ink-2);
  font-size: 0.875rem;
  margin-bottom: 12px;
}
.note {
  color: var(--ink-2);
  font-size: 0.875rem;
}
.note + .note {
  margin-top: 6px;
}

/* The rain strip: ninety minutes, one column every five. */
.chart {
  position: relative;
}
.strip svg {
  display: block;
  width: 100%;
  height: 112px;
}
.strip svg line {
  vector-effect: non-scaling-stroke;
}
.ticks {
  position: relative;
  height: 1.5rem;
  margin-top: 4px;
  color: var(--ink-2);
  font-size: 0.8125rem;
  font-variant-numeric: tabular-nums;
}
.ticks span {
  position: absolute;
  top: 0;
  transform: translateX(-50%);
  white-space: nowrap;
}
.ticks .first {
  transform: none;
}
.ticks .last {
  transform: translateX(-100%);
}
.hours .scroller {
  overflow-x: auto;
  padding-bottom: 4px;
}
.hours svg {
  display: block;
  max-width: none;
}
.hours text {
  font-size: 12px;
  fill: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.hours text.day {
  font-weight: 700;
  fill: var(--ink);
}
.strip .base,
.hours .base {
  stroke: var(--ink);
  stroke-width: 1;
}
.strip .half,
.hours .half {
  stroke: var(--line);
  stroke-width: 1;
  stroke-dasharray: 3 3;
}
.strip .dry,
.hours .dry {
  fill: var(--line);
}
.strip .r1,
.hours .r1,
.key .r1 {
  fill: var(--rain-1);
  background: var(--rain-1);
}
.strip .r2,
.hours .r2,
.key .r2 {
  fill: var(--rain-2);
  background: var(--rain-2);
}
.strip .r3,
.hours .r3,
.key .r3 {
  fill: var(--rain-3);
  background: var(--rain-3);
}
.strip .unknown {
  fill: none;
  stroke: var(--line);
  stroke-dasharray: 2 3;
}
.hours .daymark {
  stroke: var(--line);
}
.hours .sel {
  fill: none;
  stroke: var(--ink);
  stroke-width: 1.5;
}
.hours .hit {
  fill: transparent;
  cursor: pointer;
}
.key {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 14px;
  margin-top: 10px;
  color: var(--ink-2);
  font-size: 0.8125rem;
}
.key i {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 2px;
  margin-right: 5px;
}
.hour-detail {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line-soft);
  font-size: 0.9375rem;
}
.hour-detail strong {
  font-weight: 700;
}
.models {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 2px 16px;
  margin-top: 8px;
  color: var(--ink-2);
  font-size: 0.875rem;
  font-variant-numeric: tabular-nums;
}
.models li {
  display: flex;
  justify-content: space-between;
}
.models .wet {
  color: var(--rain-ink);
  font-weight: 700;
}

/* Maps */
.mapwrap {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--panel);
}
.map {
  height: min(62vh, 380px);
  background: var(--line-soft);
}
.mapbar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-top: 1px solid var(--line);
  font-size: 0.875rem;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.mapbar button {
  min-width: 44px;
  min-height: 40px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  color: var(--ink);
  font-weight: 700;
}
.mapbar:has(.layers) {
  display: grid;
  gap: 8px;
}
.layers {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.layers button {
  min-height: 40px;
  padding: 6px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--panel);
  color: var(--ink-2);
  font-weight: 700;
}
.layers button[aria-pressed='true'] {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--panel);
}
.playrow {
  display: flex;
  align-items: center;
  gap: 10px;
}
.mapbar button:disabled {
  opacity: 0.45;
}
.mapnote {
  font-size: 0.8125rem;
  color: var(--ink-2);
}
/* Lightning arrives yellow, which is also the radar's heavy-rain colour.
   Turned to violet with a dark edge so the two are never confused. */
.leaflet-lightning-pane img {
  filter: hue-rotate(220deg) saturate(2.5) drop-shadow(0 0 1px #20052e);
}
.windmark {
  display: grid;
  justify-items: center;
  color: #1b2430;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  text-shadow: 0 0 3px #fff, 0 0 3px #fff, 0 0 2px #fff;
}
.windmark svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  filter: drop-shadow(0 0 1.5px #fff) drop-shadow(0 0 1.5px #fff);
}
.windmark.strong {
  color: #8a1c14;
}
.mapbar .grow {
  flex: 1;
  min-width: 0;
}
.leaflet-container {
  font: inherit;
  font-size: 0.8125rem;
  background: var(--line-soft);
}
.basetiles {
  filter: grayscale(1) contrast(0.82) brightness(1.08);
}
@media (prefers-color-scheme: dark) {
  .basetiles {
    filter: invert(1) grayscale(1) brightness(0.72) contrast(0.95);
  }
  .leaflet-container .leaflet-control-attribution,
  .leaflet-bar a {
    background: var(--panel);
    color: var(--ink-2);
  }
  .leaflet-container .leaflet-control-attribution a {
    color: var(--ink);
  }
}
.leaflet-control-attribution {
  font-size: 0.6875rem;
}
.here {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--ink);
  border: 3px solid var(--panel);
  box-shadow: 0 0 0 1px var(--ink);
}
.windbox {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 6px 9px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: var(--ink);
  font-size: 0.8125rem;
  font-weight: 700;
}
.windbox svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* Facts in a row: label under value. */
.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(104px, 1fr));
  gap: 12px 14px;
}
.facts dt {
  color: var(--ink-2);
  font-size: 0.8125rem;
  order: 2;
}
.facts dd {
  font-size: 1.25rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.01em;
}
.facts div {
  display: flex;
  flex-direction: column;
}
.facts small {
  font-size: 0.8125rem;
  font-weight: 400;
  color: var(--ink-2);
}

/* The five-step official fire risk scale. */
.scale {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 3px;
  margin: 10px 0 6px;
}
.scale i {
  height: 8px;
  background: var(--line);
  border-radius: 1px;
}
.scale i.on {
  background: var(--ink);
}
.scale.l3 i.on {
  background: var(--watch-line);
}
.scale.l4 i.on,
.scale.l5 i.on {
  background: var(--danger-line);
}
.risk {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.risk b {
  display: block;
  font-size: 1.125rem;
}
.risk span {
  color: var(--ink-2);
  font-size: 0.8125rem;
}

.rows > li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 12px;
  padding: 10px 0;
  border-top: 1px solid var(--line-soft);
}
.rows > li:first-child {
  border-top: 0;
  padding-top: 0;
}
.rows b {
  font-weight: 700;
}
.rows .meta {
  grid-column: 1 / -1;
  color: var(--ink-2);
  font-size: 0.875rem;
}
.rows .right {
  text-align: right;
  font-variant-numeric: tabular-nums;
  color: var(--ink-2);
}
.tag {
  display: inline-block;
  padding: 1px 7px;
  border-radius: 3px;
  border: 1px solid var(--line);
  font-size: 0.8125rem;
  font-weight: 700;
}
.tag.watch,
.tag.yellow {
  background: var(--watch-bg);
  border-color: var(--watch-line);
  color: var(--watch);
}
.tag.danger,
.tag.orange,
.tag.red {
  background: var(--danger-bg);
  border-color: var(--danger-line);
  color: var(--danger);
}

/* Banner: only when something official or urgent is active. */
#banner:not(:empty) {
  max-width: 720px;
  margin: 14px auto 0;
  padding: 0 14px;
  display: grid;
  gap: 8px;
}
.alert {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border-radius: var(--radius);
  border: 1px solid var(--watch-line);
  background: var(--watch-bg);
  color: var(--watch);
  font-weight: 700;
}
.alert.danger {
  border-color: var(--danger-line);
  background: var(--danger-bg);
  color: var(--danger);
}
.alert small {
  display: block;
  font-weight: 400;
  font-size: 0.875rem;
}

/* Weather now */
.nowrow {
  display: flex;
  align-items: center;
  gap: 16px;
}
.nowrow .temp {
  font-size: 3.5rem;
  font-weight: 750;
  line-height: 1;
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.sky {
  width: 30px;
  height: 30px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: none;
}
.nowrow .sky {
  width: 54px;
  height: 54px;
}
.hourly {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 56px;
  gap: 2px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: thin;
}
.hourly li {
  display: grid;
  justify-items: center;
  gap: 5px;
  font-size: 0.8125rem;
  color: var(--ink-2);
  font-variant-numeric: tabular-nums;
}
.hourly b {
  color: var(--ink);
  font-size: 1rem;
}
.days li {
  display: grid;
  grid-template-columns: 3.2em 30px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 9px 0;
  border-top: 1px solid var(--line-soft);
  font-variant-numeric: tabular-nums;
}
.days li:first-child {
  border-top: 0;
}
.days .what {
  min-width: 0;
}
.days .what small {
  display: block;
  color: var(--ink-2);
  font-size: 0.8125rem;
}
.days .rainy {
  color: var(--rain-ink);
  font-weight: 700;
}
.days .temps {
  text-align: right;
  white-space: nowrap;
}
.days .temps span {
  color: var(--ink-2);
}

/* Sources, one tap away */
#sources {
  max-width: 720px;
  margin: 0 auto;
  padding: 4px 14px 28px;
}
#sources details {
  border-top: 1px solid var(--line);
  padding-top: 10px;
}
#sources summary {
  cursor: pointer;
  color: var(--ink-2);
  font-size: 0.875rem;
  min-height: 32px;
}
#sources table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 8px;
  font-size: 0.8125rem;
}
#sources th,
#sources td {
  text-align: left;
  vertical-align: top;
  padding: 6px 8px 6px 0;
  border-top: 1px solid var(--line-soft);
  font-weight: 400;
}
#sources th {
  font-weight: 700;
  white-space: nowrap;
}
#sources td.state {
  white-space: nowrap;
  font-weight: 700;
}
#sources td.bad {
  color: var(--danger);
}

.empty {
  padding: 36px 8px;
  text-align: center;
  color: var(--ink-2);
}
.empty h1 {
  color: var(--ink);
  font-size: 1.5rem;
  margin-bottom: 8px;
}

/* Place dialog */
dialog {
  width: min(460px, calc(100vw - 24px));
  max-height: calc(100dvh - 24px);
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 16px;
  background: var(--panel);
  color: var(--ink);
}
dialog::backdrop {
  background: rgb(10 16 22 / 0.55);
}
.dialog-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 12px;
  margin-bottom: 14px;
}
dialog h2 {
  font-size: 1.25rem;
  line-height: 1.2;
}
dialog h3 {
  font-size: 0.875rem;
  color: var(--ink-2);
  font-weight: 400;
  margin: 16px 0 4px;
}
.close {
  border: 0;
  background: none;
  min-width: 44px;
  min-height: 44px;
  margin: -10px -10px 0 0;
  display: grid;
  place-items: center;
}
.primary {
  width: 100%;
  min-height: 48px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--panel);
  font-weight: 700;
}
dialog label {
  display: block;
  margin: 16px 0 6px;
  font-size: 0.9375rem;
}
dialog input {
  width: 100%;
  min-height: 48px;
  padding: 8px 12px;
  border: 1px solid var(--ink-2);
  border-radius: var(--radius);
  background: var(--panel);
}
.hint {
  color: var(--ink-2);
  font-size: 0.875rem;
  margin-top: 6px;
  min-height: 1.2em;
}
.results button {
  display: block;
  width: 100%;
  text-align: left;
  min-height: 48px;
  padding: 8px 4px;
  border: 0;
  border-top: 1px solid var(--line-soft);
  background: none;
}
.results button:hover {
  background: var(--ground);
}
.results small {
  display: block;
  color: var(--ink-2);
}

/* Wide screens: rail on the left; rain and fire put the map beside the words. */
@media (min-width: 900px) {
  :root {
    --rail: 92px;
  }
  body {
    padding-bottom: 0;
  }
  .tabs {
    inset: 0 auto 0 0;
    width: var(--rail);
    grid-template-columns: 1fr;
    grid-auto-rows: min-content;
    align-content: start;
    padding-top: 64px;
    border-top: 0;
    border-right: 1px solid var(--line);
  }
  .tabs button {
    padding: 14px 4px;
  }
  .tabs button[aria-current='page'] {
    box-shadow: inset 3px 0 0 var(--ink);
  }
  .view,
  #banner:not(:empty),
  #sources {
    max-width: 760px;
    padding-left: 24px;
    padding-right: 24px;
  }
}
@media (min-width: 1180px) {
  .view.split {
    max-width: none;
    grid-template-columns: minmax(380px, 500px) minmax(0, 1fr);
    align-items: start;
    gap: 14px 24px;
  }
  .view.split > * {
    grid-column: 1;
  }
  .view.split > .mapwrap {
    grid-column: 2;
    grid-row: 1 / span 12;
    position: sticky;
    top: 74px;
  }
  .view.split .map {
    height: calc(100dvh - 150px);
  }
  #banner:not(:empty),
  #sources {
    max-width: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation: none !important;
    transition: none !important;
  }
}

/* The code screen and the people page: one narrow column, the same
   instrument look as the app. */
body.door {
  padding: max(32px, env(safe-area-inset-top)) 16px 48px;
}
.door main {
  max-width: 26rem;
  margin: 0 auto;
}
.door h1 {
  font-size: 1.75rem;
  line-height: 1.2;
  margin: 12px 0 6px;
}
.door-mark {
  display: block;
  border-radius: 12px;
}
.door-lead {
  color: var(--ink-2);
  margin: 0 0 24px;
}
.door-form {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  margin: 0 0 20px;
}
.door-form label {
  display: block;
  font-weight: 700;
  margin-bottom: 6px;
}
.door-form input {
  width: 100%;
  min-height: 52px;
  padding: 8px 12px;
  border: 1px solid var(--ink-2);
  border-radius: var(--radius);
  background: var(--panel);
}
.door-form input[inputmode='numeric'] {
  font-size: 1.5rem;
  letter-spacing: 0.12em;
  font-variant-numeric: tabular-nums;
}
.door-form button,
.door-fresh + .door-form button {
  width: 100%;
  min-height: 48px;
  margin-top: 14px;
  border: 1px solid var(--ink);
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--panel);
  font-weight: 700;
}
.door-hint,
.door-meta {
  color: var(--ink-2);
  font-size: 0.875rem;
  margin: 6px 0 0;
}
.door-meta {
  display: block;
}
.door-error {
  color: var(--danger);
  background: var(--danger-bg);
  border-left: 4px solid var(--danger-line);
  padding: 8px 10px;
  margin: 10px 0 0;
}
.door-fresh {
  background: var(--panel);
  border: 2px solid var(--rain-2);
  border-radius: var(--radius);
  padding: 14px 16px;
  margin: 0 0 20px;
}
.door-fresh p {
  margin: 0;
}
.door-code {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  font-variant-numeric: tabular-nums;
  margin: 6px 0 !important;
}
.door-people {
  margin: 0 0 20px;
  padding: 0;
  border-top: 1px solid var(--line);
}
.door-people li {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.door-people li.is-off strong {
  color: var(--ink-2);
  text-decoration: line-through;
}
.door-tag {
  font-size: 0.8125rem;
  color: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 8px;
  white-space: nowrap;
}
.door-quiet {
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--ink-2);
  border-radius: var(--radius);
  background: none;
  white-space: nowrap;
}
.door a {
  color: var(--rain-ink);
}
#sources .people-link {
  margin-top: 10px;
}
#sources .people-link a {
  color: var(--rain-ink);
}

/* When it rains: one row per spell, time on the left, what on the right.
   A sure spell carries the rain blue; a maybe stays quiet. */
.spells ul {
  margin: 8px 0 10px;
  padding: 0;
}
.spell {
  display: grid;
  grid-template-columns: minmax(7.5em, auto) minmax(0, 1fr);
  gap: 4px 14px;
  padding: 10px 0 10px 12px;
  border-top: 1px solid var(--line-soft);
  border-left: 4px solid var(--rain-2);
}
.spell.likely {
  border-left-color: var(--rain-1);
}
.spell.maybe {
  border-left: 4px dashed var(--line);
}
.spell-when {
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.spell-what strong {
  color: var(--rain-ink);
}
.spell.maybe .spell-what strong {
  color: var(--ink-2);
}
.spell-what small {
  display: block;
  color: var(--ink-2);
}
@media (max-width: 420px) {
  .spell {
    grid-template-columns: minmax(0, 1fr);
  }
}

/* The next days as a story: the day's name, then a plain sentence or two. */
.story ul {
  margin: 6px 0 0;
  padding: 0;
}
.story li {
  display: grid;
  grid-template-columns: 6.5em minmax(0, 1fr);
  gap: 2px 14px;
  padding: 10px 0 10px 12px;
  border-top: 1px solid var(--line-soft);
  border-left: 4px solid transparent;
}
.story li.wet {
  border-left-color: var(--rain-2);
}
.story li strong {
  font-weight: 700;
}
@media (max-width: 420px) {
  .story li {
    grid-template-columns: minmax(0, 1fr);
  }
}
