@font-face {
  font-family: Geist;
  src: url('/brand/geist-latin.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  color-scheme: dark;
  font-family: Geist, system-ui, sans-serif;
  background: #161a17;
  color: #eef1e9;
  --ink: #eef1e9;
  --muted: #b1b9ad;
  --line: #353d35;
  --card: #202620;
  --ring: #8adcaf;
}

* { box-sizing: border-box; }
body { margin: 0; }
[hidden] { display: none !important; }
a { color: inherit; }
button, input, select { font: inherit; }
button, select, summary { cursor: pointer; }
button:disabled { cursor: wait; }
svg { display: block; width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; }
.symbols, .sr-only { position: absolute; width: .0625rem; height: .0625rem; padding: 0; margin: -.0625rem; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
:focus-visible { outline: .15rem solid var(--ring); outline-offset: .22rem; }
.skip { position: absolute; inset-inline-start: 1rem; inset-block-start: -10rem; z-index: 1; background: var(--card); padding: .7rem 1rem; }
.skip:focus { inset-block-start: .75rem; }
.layout { width: min(100% - 4rem, 43rem); margin-inline: auto; }

.masthead { border-bottom: .0625rem solid var(--line); }
.masthead-inner { display: flex; align-items: center; min-height: 4rem; gap: 1rem; }
.wordmark { display: block; flex: none; }
.wordmark img { display: block; width: 6.4rem; height: auto; filter: brightness(0) invert(1); }
.section-label { border-inline-start: .0625rem solid var(--line); padding-inline-start: 1rem; color: var(--muted); font-size: .85rem; }
.site-link, .footer a { display: flex; gap: .35rem; align-items: center; font-size: .84rem; text-decoration: none; min-height: 2.75rem; }
.site-link { margin-inline-start: auto; }
.site-link:hover, .footer a:hover, .jump-nav a:hover { text-decoration: underline; text-underline-offset: .25em; }

.intro { display: flex; justify-content: space-between; gap: 1rem; align-items: end; padding-block: 2.4rem 1.1rem; }
.intro h1 { margin: 0; font-size: clamp(1.85rem, 5vw, 2.55rem); line-height: 1.02; letter-spacing: -.06em; font-weight: 560; }
.intro p, .section-heading p { color: var(--muted); line-height: 1.5; }
.intro p { margin: .55rem 0 0; font-size: .88rem; }
.refresh { background: transparent; border: .0625rem solid #465149; color: var(--ink); border-radius: .45rem; padding: .6rem .9rem; min-height: 2.45rem; display: flex; align-items: center; gap: .55rem; font-size: .85rem; white-space: nowrap; }
.refresh:hover, .refresh:disabled { background: #303a31; }
.refresh:disabled svg { animation: rotate 1.1s linear infinite; }
@keyframes rotate { to { transform: rotate(1turn); } }

[data-state="operational"] { --state-color: #9be5b1; --state-fill: #203a2b; }
[data-state="degraded"], [data-state="stale"], [data-state="investigating"], [data-state="active"] { --state-color: #f2ca82; --state-fill: #3b3020; }
[data-state="outage"] { --state-color: #ffaaa3; --state-fill: #412925; }
[data-state="maintenance"], [data-state="scheduled"], [data-state="monitoring"] { --state-color: #b7c9fa; --state-fill: #29334b; }
[data-state="unknown"] { --state-color: #c1c6bc; --state-fill: #2b332e; }
[data-state="resolved"] { --state-color: #9be5b1; --state-fill: #203a2b; }

.overview { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 1.1rem; align-items: center; border: .0625rem solid color-mix(in srgb, var(--state-color) 18%, transparent); border-radius: .75rem; padding: 1rem 1.15rem; background: var(--state-fill); }
.overall-icon { display: grid; place-items: center; width: 2.7rem; height: 2.7rem; color: var(--state-fill); background: var(--state-color); border-radius: 50%; font-size: 1.33rem; }
.overall-copy h2 { color: var(--state-color); font-size: clamp(1.18rem, 2vw, 1.45rem); font-weight: 650; margin: 0; letter-spacing: -.035em; }
.overall-copy p { margin: .37rem 0 0; color: var(--state-color); font-size: .87rem; line-height: 1.38; }
.last-check { border-inline-start: .0625rem solid color-mix(in srgb, var(--state-color) 20%, transparent); padding-inline-start: 1.2rem; display: grid; gap: .27rem; color: var(--state-color); font-size: .84rem; line-height: 1.35; }
.last-check span { font-size: .72rem; font-weight: 650; }
.last-check time { font-variant-numeric: tabular-nums; white-space: nowrap; }
.fetch-error { margin-block: .8rem 0; background: #3b3020; color: #f2ca82; border: .0625rem solid #655032; border-radius: .45rem; padding: .75rem .9rem; font-size: .88rem; line-height: 1.45; }

.jump-nav { display: flex; flex-wrap: wrap; gap: .15rem 1.1rem; }
.jump-nav a { color: #bdcabd; text-decoration: none; display: flex; align-items: center; font-size: .87rem; min-height: 2rem; }
.page-section { display: grid; grid-template-columns: 1fr; gap: .8rem; border-top: .0625rem solid var(--line); padding-block: 1.35rem 1.75rem; scroll-margin-block-start: 1rem; }
.section-heading h2 { font-size: 1.44rem; letter-spacing: -.045em; font-weight: 650; margin: 0; }
.section-heading p { margin: .6rem 0 0; font-size: .84rem; }
.result-list, .group { border: .0625rem solid var(--line); background: var(--card); border-radius: .55rem; overflow: hidden; }
.result-list { align-self: start; }
.empty { margin: 0; padding: 1rem; color: var(--muted); line-height: 1.5; font-size: .9rem; }
#model-results > .empty { padding: .85rem 0 0; }
.group + .group { margin-top: .42rem; }
.group > summary:focus-visible { outline-offset: -.18rem; }
.group > summary { cursor: pointer; margin: 0; padding: .64rem 1rem; color: #c4cfc2; border-bottom: .0625rem solid var(--line); background: #262e26; font-size: .78rem; font-weight: 650; letter-spacing: .025em; }
.row + .row, .component-row + .component-row { border-top: .0625rem solid var(--line); }
.row summary { list-style: none; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: center; gap: .7rem; padding: .65rem .85rem; line-height: 1.35; }
.row summary::-webkit-details-marker { display: none; }
.row summary:hover { background: #29332a; }
.row summary:focus-visible { outline-offset: -.18rem; }
.row-title { font-size: .95rem; font-weight: 580; overflow-wrap: anywhere; }
.row-title small { display: block; margin-top: .2rem; font-size: .78rem; font-weight: 420; color: var(--muted); }
.chevron { font-size: 1rem; color: #a8b1a4; transition: transform 140ms ease; }
.row[open] .chevron { transform: rotate(90deg); }
.badge { display: inline-flex; align-items: center; gap: .25rem; border-radius: 2rem; background: var(--state-fill); color: var(--state-color); font-size: .75rem; font-weight: 600; padding: .27rem .52rem; line-height: 1.3; white-space: nowrap; }
.badge svg { font-size: .94rem; }
.row-body { padding: 0 .85rem .7rem; font-size: .85rem; line-height: 1.5; }
.row-body p { color: #c1cabc; margin: 0 0 .7rem; }
.facts { display: flex; flex-wrap: wrap; gap: .6rem 1.35rem; margin: 0; }
.facts dt { color: var(--muted); font-size: .74rem; }
.facts dd { margin: .13rem 0 0; overflow-wrap: anywhere; }
.incident-updates { list-style: none; padding: 0 0 0 .8rem; margin: .9rem 0 0; border-inline-start: .125rem solid #49574b; }
.incident-updates li + li { margin-top: .7rem; }
.incident-updates time { color: var(--muted); font-size: .77rem; }
.incident-updates p { margin: .15rem 0 0; }

.filters { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: .6rem; }
.search-box { display: flex; align-items: center; gap: .55rem; color: var(--muted); }
.search-box, .filter-box select { min-height: 2.65rem; border-radius: .45rem; border: .0625rem solid #465149; background: var(--card); padding: 0 .75rem; }
.search-box input { min-width: 0; width: 100%; color: var(--ink); border: none; background: transparent; padding: .58rem 0; outline: none; font-size: .87rem; }
.search-box:focus-within { outline: .15rem solid var(--ring); outline-offset: .12rem; }
.search-box input::placeholder { color: #a7b3a5; opacity: 1; }
.filter-box select { color: var(--ink); font-size: .84rem; }
.service-filter { display: block; margin-bottom: .5rem; }
.incident-link { display: inline-block; color: #a5dcb5; text-underline-offset: .15em; margin-top: .75rem; }
.result-count { color: var(--muted); font-size: .78rem; margin: .78rem 0 .52rem; }
.footer { border-top: .0625rem solid var(--line); display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding-block: .75rem 1.5rem; color: var(--muted); font-size: .82rem; }

@media (max-width: 44rem) {
  .layout { width: calc(100% - 2.25rem); }
  .page-section { grid-template-columns: 1fr; gap: 1rem; padding-block: 1.5rem 1.85rem; }
  .section-heading p { max-width: initial; }
}
@media (max-width: 32rem) {
  .intro { align-items: start; flex-wrap: wrap; }
  .filters { grid-template-columns: 1fr 1fr; }
  .search-box { grid-column: 1 / -1; }
  .filters select { width: 100%; }
  .intro p { max-width: 22rem; font-size: .94rem; }
  .overview { grid-template-columns: auto minmax(0, 1fr); padding: 1rem; gap: .8rem; }
  .last-check { grid-column: 2; border: 0; padding: .15rem 0 0; white-space: normal; }
  .row summary { padding: .75rem; gap: .45rem; }
  .row-body { padding: 0 .75rem .75rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

.history-controls { display: flex; align-items: center; justify-content: space-between; gap: .6rem; padding-block: .75rem .45rem; }
.history-key { display: flex; flex-wrap: wrap; gap: .4rem .9rem; padding-bottom: .8rem; color: var(--muted); font-size: .72rem; }
.history-key span { display: inline-flex; align-items: center; gap: .34rem; }
.history-key i { display: inline-block; width: .72rem; height: .58rem; border-radius: .13rem; }
.history-key i, .segment { background: var(--history-fill); }
[data-state="operational"] { --history-fill: #79c799; }
[data-state="degraded"] { --history-fill: #dfad5d; }
[data-state="outage"] { --history-fill: #ed847e; }
[data-state="maintenance"] { --history-fill: #93a5e0; }
[data-state="unknown"], [data-state="stale"] {
  --history-fill: repeating-linear-gradient(145deg, #343e36 0, #343e36 .12rem, #434e45 .12rem, #434e45 .2rem);
}
.history-strip { padding: 0 .85rem .63rem; }
.segments { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: .1rem; }
.segment { appearance: none; min-width: 0; width: 100%; height: 1.03rem; border: 0; padding: 0; border-radius: .14rem; }
.segment:hover { filter: brightness(1.34); }
.segment:focus-visible { outline: .13rem solid #eef1e9; outline-offset: .05rem; z-index: 1; }
.segment[aria-pressed="true"] { box-shadow: inset 0 0 0 .13rem #eef1e9; }
.history-caption { display: flex; justify-content: space-between; gap: .35rem; color: var(--muted); font-size: .69rem; margin-top: .23rem; }
.history-selected { display: flex; flex-wrap: wrap; align-items: baseline; gap: .15rem .7rem; color: #c7cfc5; font-size: .75rem; margin-top: .4rem; }
.history-selected a { color: #b1e1bd; text-underline-offset: .17em; }
.date-filter { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; color: var(--muted); font-size: .84rem; }
.date-filter input, .date-filter button { font: inherit; background: var(--card); color: var(--ink); border: .0625rem solid #465149; border-radius: .4rem; min-height: 2.45rem; padding: .42rem .65rem; }
.date-filter button:hover { background: #303a31; }

@media (max-width: 32rem) {
  .layout { width: calc(100% - 1.5rem); }
  .history-controls { align-items: start; }
  .segments { gap: .06rem; }
  .history-strip { padding-inline: .65rem; }
}
