/* Status page, on top of the website's site.css + sx/sx.css.
 *
 * Only what the site has no word for lives here: the state colours, the
 * 90-day bars, the backup tiles, the incident cards. The state colours are a
 * family of the brand palette (yellow edge for "degraded", cobalt for
 * "maintenance") and every one keeps 3:1 against the card it sits on in both
 * schemes (statuspage/tests/test_contrast.py reads THIS file). Colour is never
 * the only carrier: every state has its word and its icon, every bar its
 * tooltip and the strip a spoken summary.
 */

.sp-status{
 --st-ok:#23804f;--st-degraded:#a86a00;--st-partial:#c4471a;--st-major:#b42318;
 --st-maint:#2455d6;--st-nodata:#6b7890;--st-before:#e4eaf4;--st-card:#ffffff;
 --st-down-bg:#fde6e3;--st-down-ink:#a01c12;
}
[data-theme="dark"] .sp-status{
 --st-ok:#4cc285;--st-degraded:#ffb400;--st-partial:#ff8a5c;--st-major:#ff6b5e;
 --st-maint:#a7c0ff;--st-nodata:#8d9fc2;--st-before:#1f3a63;--st-card:#142848;
 --st-down-bg:#4a1512;--st-down-ink:#ffb4ab;
}

.sp-status .sx.st-section{padding-block:clamp(56px,7vw,96px)}
.sp-status .sx-pill.is-down{background:var(--st-down-bg);color:var(--st-down-ink)}
.sp-status .st-pill{flex:none}

/* ---- hero ---- */
.sp-status .st-hero .sx-hero-frame{align-items:start}
.sp-status .st-kicker::before{display:none}
.sp-status .st-dot{position:relative;flex:none;width:10px;height:10px;border-radius:50%;background:var(--st-nodata)}
.sp-status .st-kicker[data-state="operational"] .st-dot{background:var(--st-ok)}
.sp-status .st-kicker[data-state="degraded"] .st-dot{background:var(--st-degraded)}
.sp-status .st-kicker[data-state="partial_outage"] .st-dot{background:var(--st-partial)}
.sp-status .st-kicker[data-state="major_outage"] .st-dot{background:var(--st-major)}
.sp-status .st-kicker[data-state="maintenance"] .st-dot{background:var(--st-maint)}
.sp-status .st-dot::after{content:"";position:absolute;inset:-4px;border-radius:50%;border:2px solid currentColor;opacity:0}
.sp-status .st-kicker[data-state="operational"] .st-dot::after{color:var(--st-ok);animation:st-pulse 2.6s ease-out infinite}
@keyframes st-pulse{0%{transform:scale(.6);opacity:.55}80%,100%{transform:scale(1.7);opacity:0}}
@media (prefers-reduced-motion:reduce){.sp-status .st-dot::after{animation:none!important}}
.sp-status .st-kicker time{font-variant-numeric:tabular-nums}
.sp-relaunch .st-kicker{gap:10px}

.sp-status .st-measure{display:flex;flex-wrap:wrap;align-items:center;gap:8px 18px;margin:28px 0 0;padding-top:20px;border-top:1px solid var(--sx-line);font-size:14px;color:var(--sx-muted)}
.sp-status .st-measure svg,.sp-status .st-links svg,.sp-status .st-fact svg{width:16px;height:16px;flex:none}
.sp-status .st-measure>span{display:inline-flex;align-items:center;gap:6px}
.sp-status .st-measure>svg{margin-right:-12px}
.sp-status .st-links{display:flex;flex-wrap:wrap;gap:10px;margin:18px 0 0}
.sp-status .st-hero-links{gap:6px 22px;margin-top:14px}
.sp-status .st-hero .st-hero-links a{padding:4px 0;border:0;border-radius:0;background:none;color:var(--sx-cobalt);font-weight:600}
.sp-status .st-hero .st-hero-links a:hover{color:var(--sx-ink);background:none}
.sp-status .st-links a{display:inline-flex;align-items:center;gap:8px;padding:9px 14px;border:1px solid var(--sx-line);border-radius:999px;
 background:color-mix(in srgb,var(--sx-card) 75%,transparent);color:var(--sx-ink);font:500 14px/1.1 var(--sans);text-decoration:none}
.sp-status .st-links a:hover{border-color:var(--sx-cobalt);color:var(--sx-cobalt)}
.sp-status .st-links a:focus-visible{outline:2px solid var(--sx-cobalt);outline-offset:3px}

.sp-status .st-stage{position:relative;max-width:540px;margin-left:auto}
.sp-status .st-plane{position:absolute;right:-26px;top:-46px;z-index:2;width:88px}
.sp-status .st-summary{overflow:hidden}
.sp-status .st-summary-label{margin:0;padding:18px 24px 6px;font:600 11.5px/1.3 var(--sans);letter-spacing:.16em;text-transform:uppercase;color:var(--sx-muted)}
.sp-status .st-summary-rows{list-style:none;margin:0;padding:2px 12px 10px}
.sp-status .st-summary-rows a{display:grid;grid-template-columns:auto minmax(0,1fr) auto;gap:14px;align-items:center;padding:12px;border-radius:14px;color:inherit;text-decoration:none}
.sp-status .st-summary-rows li+li a{border-top:1px solid var(--sx-line);border-radius:0}
.sp-status .st-summary-rows a:hover{background:var(--sx-pale);border-radius:14px}
.sp-status .st-summary-rows li+li a:hover{border-top-color:transparent}
.sp-status .st-summary-rows a:focus-visible{outline:2px solid var(--sx-cobalt);outline-offset:-2px;border-radius:14px}
.sp-status .st-ic{display:grid;place-items:center;width:38px;height:38px;border-radius:12px;background:var(--sx-pale);color:var(--sx-cobalt)}
.sp-status .st-ic svg{width:19px;height:19px}
.sp-status .st-sum-what{min-width:0}
.sp-status .st-sum-what b{display:block;font:600 15.5px/1.3 var(--sans);color:var(--sx-ink)}
.sp-status .st-sum-what small{display:block;margin-top:2px;font-size:13px;line-height:1.35;color:var(--sx-muted)}
.sp-status .st-summary-rows .sx-pill{padding:5px 10px;font-size:13px}
.sp-status .st-summary-rows .sx-pill svg{width:14px;height:14px}
.sp-status .st-summary-note{margin:0;padding:13px 24px 16px;border-top:1px solid var(--sx-line);background:color-mix(in srgb,var(--sx-pale) 45%,transparent);
 font-size:13px;line-height:1.45;color:var(--sx-muted)}
@media(max-width:900px){.sp-status .st-stage{margin-inline:auto}}
@media(max-width:600px){.sp-status .st-plane{right:-4px;top:-36px;width:62px}.sp-status .st-summary-rows a{grid-template-columns:auto minmax(0,1fr)}.sp-status .st-summary-rows .sx-pill{grid-column:2;justify-self:start}}

/* ---- notices (active incident, maintenance) ---- */
.sp-status .sx.st-notices{display:grid;gap:30px;padding-block:28px 0;border-top:0}
.sp-status .st-notice-label{margin:0 0 10px;font:600 12px/1.2 var(--sans);letter-spacing:.2em;text-transform:uppercase;color:var(--sx-muted)}

/* ---- groups and components ---- */
.sp-status .st-group{margin-top:40px}
.sp-status .st-group .sx-label{margin-top:0}
.sp-status .st-comps{list-style:none;margin:16px 0 0;padding:0 28px;background:var(--sx-card);border:1px solid var(--sx-line);border-radius:20px;
 box-shadow:0 1px 2px #10264d0a,0 22px 44px -30px #10264d33}
[data-theme="dark"] .st-comps{box-shadow:0 22px 44px -30px #00000099}
.sp-status .st-comp{padding:24px 0 20px}
.sp-status .st-comp+.st-comp{border-top:1px solid var(--sx-line)}
.sp-status .st-comp-head{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:8px 20px;align-items:start}
.sp-status .st-comp-name h4{margin:0;font:600 18px/1.3 var(--sans);letter-spacing:-.01em;color:var(--sx-ink)}
.sp-status .st-comp-name p{margin:6px 0 0;max-width:62ch;font-size:14.5px;line-height:1.5;color:var(--sx-muted)}
.sp-status .st-comp-head .st-pill{margin-top:1px}
.sp-status .st-sla{display:inline-block;margin-left:8px;padding:3px 9px;border:1px solid color-mix(in srgb,var(--sx-cobalt) 35%,transparent);border-radius:999px;
 font:600 11.5px/1.2 var(--sans);letter-spacing:.02em;color:var(--sx-cobalt);text-decoration:none;vertical-align:3px;white-space:nowrap}
.sp-status .st-sla:hover{background:var(--sx-pale)}
.sp-status .st-sla:focus-visible{outline:2px solid var(--sx-cobalt);outline-offset:2px}

.sp-status .st-facts{display:flex;flex-wrap:wrap;align-items:center;gap:8px 14px;margin:14px 0 0;font-size:14px;color:var(--sx-ink)}
.sp-status .st-fact{display:inline-flex;align-items:center;gap:7px}
.sp-status .st-fact svg{color:var(--sx-cobalt)}
.sp-status .st-flag{display:inline-block;margin-left:4px;padding:2px 8px;border-radius:999px;background:var(--sx-wait-bg);color:var(--sx-wait);font-size:12.5px;font-weight:600}
.sp-status .st-chips{display:inline-flex;flex-wrap:wrap;gap:6px}
.sp-status .st-chip{display:inline-flex;align-items:baseline;gap:6px;padding:4px 10px;border-radius:999px;background:var(--sx-pale);color:var(--sx-ink);font-size:13.5px;font-weight:500}
.sp-status .st-chip small{font:500 11.5px/1 var(--mono);color:var(--sx-muted)}
.sp-status .st-fact-aside{font-size:13px;color:var(--sx-muted)}

/* ---- the 90-day strip ---- */
.sp-status .st-bars{position:relative;margin-top:16px;border-radius:6px}
.sp-status .st-bars:focus-visible{outline:2px solid var(--sx-cobalt);outline-offset:4px}
.sp-status .st-bars ol{display:flex;gap:3px;height:32px;margin:0;padding:0;list-style:none}
.sp-status .st-bars.is-compact ol{gap:1px;height:26px}
.sp-status .st-day{flex:1 1 0;min-width:2px;border-radius:3px;background:var(--st-ok);transform-origin:bottom;transition:transform .12s}
.sp-status .st-day.is-operational{background:var(--st-ok)}
.sp-status .st-day.is-degraded{background:var(--st-degraded)}
.sp-status .st-day.is-partial_outage{background:var(--st-partial)}
.sp-status .st-day.is-major_outage{background:var(--st-major)}
.sp-status .st-day.is-maintenance{background:var(--st-maint)}
.sp-status .st-day.is-no_data{background:repeating-linear-gradient(135deg,var(--st-nodata) 0 2px,transparent 2px 5px);box-shadow:inset 0 0 0 1px var(--st-nodata)}
.sp-status .st-day.is-before_start{background:var(--st-before)}
.sp-status .st-day.is-not_offered{background:var(--st-nodata)}
/* a day measured for under 90 % of its minutes: same colour, shorter bar */
.sp-status .st-day.st-low{transform:scaleY(.62)}
.sp-status .st-day:hover,.sp-status .st-day.is-cursor{transform:scaleY(1.14)}
.sp-status .st-day.st-low:hover,.sp-status .st-day.st-low.is-cursor{transform:scaleY(.8)}
.sp-status .st-day.is-cursor{box-shadow:0 0 0 2px var(--sx-card),0 0 0 4px var(--sx-cobalt)}
@media (prefers-reduced-motion:reduce){.sp-status .st-day{transition:none}}
.sp-status .st-axis{display:flex;align-items:baseline;justify-content:space-between;gap:12px;margin-top:9px;font-size:12.5px;color:var(--sx-muted)}
.sp-status .st-axis-mid{display:flex;flex-wrap:wrap;justify-content:center;gap:4px 12px;text-align:center}
.sp-status .st-axis-mid b{color:var(--sx-ink);font-weight:600;font-variant-numeric:tabular-nums}
.sp-status .st-axis-30{display:none}
@media(max-width:640px){
 .sp-status .st-day.st-old{display:none}
 .sp-status .st-axis-90{display:none}.sp-status .st-axis-30{display:inline}
 .sp-status .st-bars ol{gap:3px}
}

.sp-status .st-tip{position:absolute;z-index:30;bottom:calc(100% + 10px);width:max-content;max-width:min(280px,86vw);padding:8px 11px;border-radius:10px;background:#10264d;color:#f6f8fc;
 font-size:12.5px;line-height:1.4;box-shadow:0 12px 30px #10264d40;pointer-events:none;white-space:normal;transform:translateX(-50%)}
.sp-status .st-tip::after{content:"";position:absolute;left:var(--tip-arrow,50%);top:100%;border:6px solid transparent;border-top-color:#10264d;transform:translateX(-50%)}
[data-theme="dark"] .st-tip{background:#f6f8fc;color:#10264d}
[data-theme="dark"] .st-tip::after{border-top-color:#f6f8fc}

/* ---- backups ---- */
.sp-status .st-tiles{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:18px;margin:40px 0 0;padding:0;list-style:none}
.sp-status .st-tile{display:flex;flex-direction:column;gap:8px;padding:24px 24px 20px;background:var(--sx-card);border:1px solid var(--sx-line);border-radius:20px;
 box-shadow:0 1px 2px #10264d0a,0 22px 44px -30px #10264d33}
[data-theme="dark"] .st-tile{box-shadow:0 22px 44px -30px #00000099}
.sp-status .st-tile-top{display:flex;align-items:flex-start;justify-content:space-between;gap:12px}
.sp-status .st-tile-label{font:600 12px/1.35 var(--sans);letter-spacing:.14em;text-transform:uppercase;color:var(--sx-muted)}
.sp-status .st-tile-top .sx-pill{padding:5px 10px;font-size:13px}
.sp-status .st-tile-top .sx-pill svg{width:14px;height:14px}
.sp-status .st-tile-when{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:6px 0 0;font:600 clamp(28px,2.8vw,38px)/1.05 var(--sans);letter-spacing:-.03em;color:var(--sx-ink);font-variant-numeric:tabular-nums}
.sp-status .st-tile-when .st-flag{font-size:13px;letter-spacing:0}
.sp-status .st-tile-exact{font-size:13px;color:var(--sx-muted)}
.sp-status .st-tile-about{flex:1;margin:6px 0 0;font-size:14px;line-height:1.5;color:var(--sx-muted)}
.sp-status .st-tile-bars{margin-top:4px}
.sp-status .st-tile[data-state="degraded"],.sp-status .st-tile[data-state="major_outage"]{border-color:color-mix(in srgb,var(--st-degraded) 55%,var(--sx-line))}

/* ---- upstream ---- */
.sp-status .st-ups{display:grid;grid-template-columns:repeat(auto-fit,minmax(280px,1fr));gap:18px;margin:36px 0 0;padding:0;list-style:none}
.sp-status .st-up{display:flex;flex-direction:column;gap:12px;padding:22px 24px;background:var(--sx-card);border:1px solid var(--sx-line);border-radius:20px}
.sp-status .st-up-head{display:flex;flex-wrap:wrap;align-items:baseline;justify-content:space-between;gap:6px 12px}
.sp-status .st-up-head h4{display:flex;flex-wrap:wrap;align-items:center;gap:8px;margin:0;font:600 17px/1.3 var(--sans);color:var(--sx-ink)}
.sp-status .st-src{display:inline-flex;align-items:center;gap:4px;font-size:13px;color:var(--sx-cobalt);text-decoration:none}
.sp-status .st-src svg{width:14px;height:14px}
.sp-status .st-src:hover{text-decoration:underline;text-underline-offset:3px}
.sp-status .st-up-msg{display:flex;flex-direction:column;gap:4px;margin:0;font-size:14.5px;line-height:1.45;color:var(--sx-ink)}
.sp-status .st-up-msg span{font-size:12.5px;color:var(--sx-muted)}
.sp-status .st-up-msg a{color:inherit;text-decoration:underline;text-decoration-color:var(--sx-line);text-underline-offset:3px}
.sp-status .st-up-msg.is-recent{padding-left:12px;border-left:3px solid var(--sx-cobalt)}
.sp-status .st-up-msg.is-none span{font-size:14.5px}
.sp-status .st-up-fetch{margin:auto 0 0;font-size:12.5px;color:var(--sx-muted)}

/* ---- incidents ---- */
.sp-status .st-incident{padding:22px 26px 20px;border-left-width:4px}
.sp-status .st-incident.impact-degraded{border-left-color:var(--st-degraded)}
.sp-status .st-incident.impact-partial_outage{border-left-color:var(--st-partial)}
.sp-status .st-incident.impact-major_outage{border-left-color:var(--st-major)}
.sp-status .st-incident.impact-maintenance{border-left-color:var(--st-maint)}
.sp-status .st-incident header{display:flex;flex-wrap:wrap;align-items:flex-start;justify-content:space-between;gap:10px 16px}
.sp-status .st-incident h3,.sp-status .st-incident h4{margin:0;font:600 19px/1.3 var(--sans);letter-spacing:-.01em;color:var(--sx-ink)}
.sp-status .st-incident h4{font-size:16.5px}
.sp-status .st-incident-pills{display:flex;gap:8px}
.sp-status .st-incident-pills .sx-pill{padding:5px 10px;font-size:13px}
.sp-status .st-incident-meta{margin:10px 0 0;font-size:13.5px;color:var(--sx-muted)}
.sp-status .st-latest{margin:12px 0 0;font-size:15px;line-height:1.55;color:var(--sx-ink)}
.sp-status .st-up-status{display:inline-block;margin-right:6px;font-weight:600}
.sp-status .st-updates{margin-top:12px;font-size:14px}
.sp-status .st-updates summary{cursor:pointer;color:var(--sx-cobalt);font-weight:600;width:max-content}
.sp-status .st-updates summary:focus-visible{outline:2px solid var(--sx-cobalt);outline-offset:3px;border-radius:4px}
.sp-status .st-updates ol{list-style:none;margin:12px 0 0;padding:0 0 0 18px;border-left:2px solid var(--sx-line)}
.sp-status .st-updates li{position:relative;padding:0 0 14px}
.sp-status .st-updates li::before{content:"";position:absolute;left:-25px;top:5px;width:10px;height:10px;border-radius:50%;background:var(--sx-card);border:2px solid var(--sx-cobalt)}
.sp-status .st-updates li time{margin-left:4px;font-size:12.5px;color:var(--sx-muted)}
.sp-status .st-updates li p{margin:4px 0 0;line-height:1.5;color:var(--sx-ink)}
.sp-status .st-incident .sx-link{margin-top:12px}

.sp-status .st-timeline{list-style:none;margin:36px 0 0;padding:0}
.sp-status .st-tl-day{display:grid;grid-template-columns:200px minmax(0,1fr);gap:8px 24px;align-items:baseline;padding:16px 0;border-top:1px solid var(--sx-line)}
.sp-status .st-tl-day.has-incident{align-items:start}
.sp-status .st-tl-day.has-incident h3{padding-top:22px}
.sp-status .st-tl-day:last-child{border-bottom:1px solid var(--sx-line)}
.sp-status .st-tl-day h3{margin:0;font:600 14.5px/1.4 var(--sans);color:var(--sx-ink)}
.sp-status .st-tl-day .st-incident{margin:0}
.sp-status .st-tl-day .st-incident+.st-incident{margin-top:12px}
.sp-status .st-quiet{margin:0;font-size:14.5px;color:var(--sx-muted)}
@media(max-width:640px){.sp-status .st-tl-day{grid-template-columns:1fr}}

/* ---- how we measure ---- */
.sp-status .st-method .sx-title{max-width:16em}
.sp-status .st-rules{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:22px 48px;margin:36px 0 0;padding:0;list-style:none;counter-reset:rule}
.sp-status .st-rules li{position:relative;padding-left:46px;font-size:15.5px;line-height:1.6;color:var(--sx-muted);counter-increment:rule}
.sp-status .st-rules li::before{content:counter(rule);position:absolute;left:0;top:-2px;display:grid;place-items:center;width:32px;height:32px;border-radius:50%;
 background:var(--sx-card);border:1px solid var(--sx-line);font:600 13px/1 var(--sans);color:var(--sx-cobalt)}
.sp-status .st-rules b{display:block;margin-bottom:2px;color:var(--sx-ink);font-weight:600}
.sp-status .st-subscribe{margin-top:44px;padding-top:28px;border-top:1px solid var(--sx-line)}
.sp-status .st-subscribe h3{margin:0;font:600 19px/1.3 var(--sans);color:var(--sx-ink)}
.sp-status .st-subscribe p{margin:8px 0 0;max-width:60ch;color:var(--sx-muted)}
@media(max-width:900px){.sp-status .st-rules{grid-template-columns:1fr}}

/* ---- history page ---- */
.sp-status .st-history .sx-title{font-size:clamp(34px,4vw,54px)}
.sp-status .st-history .sx-num svg{width:16px;height:16px}
.sp-status .st-history .sx-link svg{width:16px;height:16px;transform:rotate(180deg)}
.sp-status .st-back{margin-top:22px}
.sp-status .st-month{margin-top:56px}
.sp-status .st-month .sx-label{margin-top:0}
.sp-status .st-month .st-incident{margin-top:16px}

/* ---- freshness banner (status.js) ---- */
.sp-status .st-stale{position:sticky;top:0;z-index:50;margin:12px 0 0;padding:12px 18px;border-radius:14px;background:var(--sx-wait-bg);color:var(--sx-wait);
 border:1px solid color-mix(in srgb,var(--st-degraded) 50%,transparent);font-size:14.5px;line-height:1.45}

@media(max-width:600px){
 .sp-status .st-comps{padding:0 18px}
 .sp-status .st-comp-head{grid-template-columns:1fr}
 .sp-status .st-comp-head .st-pill{justify-self:start}
 .sp-status .st-incident{padding:18px 18px 16px}
}
@media print{.sp-status .st-links,.sp-status .st-stale,.sx-plane{display:none}}

/* site.css styles every <details> as an FAQ row (border, +/– marker); an
   incident's update list is a disclosure inside a card, not an FAQ */
.sp-status .st-updates{border:0;padding:0;background:none;box-shadow:none}
.sp-status .st-updates summary{display:inline-flex;align-items:center;gap:6px;padding:0;font-size:14px}
.sp-status .st-updates summary::after{content:"";width:7px;height:7px;margin-left:2px;border-right:2px solid currentColor;border-bottom:2px solid currentColor;
 font:inherit;transform:translateY(-2px) rotate(45deg);transition:transform .15s}
.sp-status .st-updates[open] summary::after{content:"";transform:translateY(1px) rotate(-135deg)}
@media (prefers-reduced-motion:reduce){.sp-status .st-updates summary::after{transition:none}}

.sp-status .st-method .sx-num{background:var(--sx-card);border:1px solid var(--sx-line)}
@media(max-width:640px){
 .sp-status .st-since{display:none}
 .sp-status .st-axis{font-size:12px}
 .sp-status .st-axis-mid{flex-direction:column;gap:2px}
}

/* where the problem lies: the first line under an incident's title */
.sp-status .st-cause{display:flex;align-items:center;gap:8px;margin:12px 0 0;padding:8px 12px;border-radius:10px;
 background:var(--sx-pale);font-size:14.5px;line-height:1.4;color:var(--sx-ink);width:fit-content;max-width:100%}
.sp-status .st-cause svg{width:17px;height:17px;flex:none;color:var(--sx-cobalt)}
.sp-status .st-cause b{font-weight:600}
.sp-status .st-cause a{color:var(--sx-cobalt);text-decoration:none;font-weight:500;white-space:nowrap}
.sp-status .st-cause a svg{width:13px;height:13px;margin-left:2px;vertical-align:-1px}
.sp-status .st-cause a:hover{text-decoration:underline;text-underline-offset:3px}
.sp-status .st-cause.is-unknown{background:transparent;border:1px dashed var(--sx-line);color:var(--sx-muted)}
.sp-status .st-cause.is-unknown svg{color:var(--sx-muted)}
