:root {
  color-scheme: dark;
  --bg: #080b14;
  --bg-elevated: #0c111d;
  --surface: #101624;
  --surface-hover: #151d2d;
  --surface-strong: #192237;
  --line: #222c40;
  --line-bright: #303d56;
  --text: #eef3ff;
  --text-soft: #c5cede;
  --muted: #8994aa;
  --faint: #606b81;
  --blue: #718dff;
  --violet: #a080ff;
  --green: #43d6a1;
  --amber: #eab65a;
  --orange: #ee8d56;
  --red: #f06b78;
  --radius: 14px;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { background: var(--bg); scroll-behavior: smooth; }
body { margin: 0; min-width: 320px; background: radial-gradient(circle at 50% -20%, rgba(83, 102, 184, .12), transparent 35%), var(--bg); color: var(--text); line-height: 1.5; }
a { color: var(--blue); text-decoration: none; }
a:hover { color: #9caeff; }
a:focus-visible, button:focus-visible, select:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
button, select { font: inherit; }
code { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; }
.shell { width: min(1380px, calc(100% - 48px)); margin-inline: auto; }

.site-header { position: sticky; top: 0; z-index: 20; border-bottom: 1px solid rgba(48, 61, 86, .65); background: rgba(8, 11, 20, .9); backdrop-filter: blur(18px); }
.header-row { min-height: 76px; display: grid; grid-template-columns: minmax(290px, 1fr) auto minmax(150px, 1fr); align-items: center; gap: 28px; }
.brand-lockup { display: inline-flex; align-items: center; gap: 12px; color: var(--text); min-width: 0; }
.brand-lockup:hover { color: var(--text); }
.brand-lockup > span:last-child { display: flex; flex-direction: column; min-width: 0; }
.brand-lockup strong { font-size: .98rem; letter-spacing: -.015em; }
.brand-lockup small { color: var(--muted); font-size: .71rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brand-mark { width: 36px; height: 36px; flex: 0 0 auto; padding: 3px; border: 1px solid rgba(113, 141, 255, .38); border-radius: 10px; background: linear-gradient(145deg, rgba(84, 216, 255, .1), rgba(113, 141, 255, .06)); box-shadow: inset 0 0 16px rgba(113, 141, 255, .08), 0 0 18px rgba(84, 216, 255, .04); }
.primary-nav { height: 76px; display: flex; align-items: stretch; gap: 4px; }
.primary-nav a { position: relative; display: inline-flex; align-items: center; padding: 0 13px; color: var(--muted); font-size: .82rem; font-weight: 600; }
.primary-nav a:hover, .primary-nav a.active { color: var(--text); }
.primary-nav a.active::after { content: ""; position: absolute; inset: auto 12px -1px; height: 2px; border-radius: 2px; background: var(--blue); box-shadow: 0 -2px 10px rgba(113, 141, 255, .65); }
.operational-badge { justify-self: end; display: inline-flex; align-items: center; gap: 8px; padding: 7px 11px; border: 1px solid rgba(67, 214, 161, .28); border-radius: 999px; background: rgba(67, 214, 161, .07); color: var(--green); font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.operational-badge > span, .inline-status > span { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 9px rgba(67, 214, 161, .8); }
.operational-badge.degraded { color: var(--amber); border-color: rgba(234, 182, 90, .28); background: rgba(234, 182, 90, .07); }
.operational-badge.degraded > span { background: var(--amber); }

main { padding-block: 34px 64px; }
.hero { position: relative; overflow: hidden; min-height: 270px; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(300px, .6fr); align-items: center; gap: 50px; padding: 42px 46px 56px; border: 1px solid var(--line); border-radius: 18px; background: linear-gradient(115deg, rgba(20, 29, 49, .98), rgba(11, 16, 29, .96)), var(--surface); box-shadow: 0 20px 50px rgba(0, 0, 0, .2); }
.hero::before { content: ""; position: absolute; width: 520px; height: 520px; right: -190px; top: -260px; border-radius: 50%; background: radial-gradient(circle, rgba(113, 141, 255, .18), transparent 66%); pointer-events: none; }
.hero::after { content: ""; position: absolute; inset: 0; opacity: .22; pointer-events: none; background-image: linear-gradient(rgba(113, 141, 255, .06) 1px, transparent 1px), linear-gradient(90deg, rgba(113, 141, 255, .06) 1px, transparent 1px); background-size: 34px 34px; mask-image: linear-gradient(90deg, transparent 20%, black); }
.hero-copy, .hero-assurance, .disclaimer { position: relative; z-index: 1; }
.kicker, .section-kicker { color: #849bff; font: 700 .67rem/1.2 "SFMono-Regular", Consolas, monospace; letter-spacing: .14em; }
.kicker { display: inline-flex; align-items: center; gap: 8px; padding: 6px 9px; border: 1px solid rgba(113, 141, 255, .22); border-radius: 999px; background: rgba(113, 141, 255, .07); }
.kicker > span { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { color: var(--text); letter-spacing: -.03em; }
.hero h1 { max-width: 760px; margin: 17px 0 12px; font-size: clamp(2rem, 4.4vw, 3.25rem); line-height: 1.05; }
.hero-copy > p { max-width: 780px; margin-bottom: 24px; color: var(--text-soft); font-size: .98rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.button { display: inline-flex; min-height: 39px; align-items: center; justify-content: center; gap: 8px; padding: 8px 14px; border: 1px solid transparent; border-radius: 9px; cursor: pointer; font-size: .78rem; font-weight: 700; white-space: nowrap; }
.button-primary { color: white; border-color: #728cff; background: linear-gradient(135deg, #647ff0, #765ed5); box-shadow: 0 8px 22px rgba(83, 101, 207, .22); }
.button-primary:hover { color: white; background: linear-gradient(135deg, #738eff, #846ee0); }
.button-secondary { color: var(--text-soft); border-color: var(--line-bright); background: rgba(255, 255, 255, .025); }
.button-secondary:hover, .button-ghost:hover { color: var(--text); border-color: #4a5b78; background: rgba(255, 255, 255, .045); }
.button-ghost { color: var(--muted); border-color: transparent; background: transparent; }
.hero-assurance { display: flex; align-items: center; gap: 15px; padding: 19px; border: 1px solid rgba(113, 141, 255, .22); border-radius: 13px; background: rgba(7, 11, 21, .55); }
.assurance-icon { width: 43px; height: 43px; flex: 0 0 auto; display: grid; place-items: center; border: 1px solid rgba(67, 214, 161, .3); border-radius: 11px; color: var(--green); background: rgba(67, 214, 161, .07); font-size: 1.4rem; }
.hero-assurance strong { font-size: .87rem; }
.hero-assurance p { margin: 4px 0 0; color: var(--muted); font-size: .76rem; }
.disclaimer { position: absolute; left: 46px; bottom: 20px; margin: 0; color: var(--faint); font-size: .7rem; }

.section-block { margin-top: 36px; }
.section-heading, .panel-heading, .page-heading, .room-card-head { display: flex; align-items: center; justify-content: space-between; gap: 22px; }
.section-heading { margin-bottom: 16px; }
.section-heading h2, .panel-heading h2 { margin: 4px 0 0; font-size: 1.05rem; }
.freshness { color: var(--faint); font-size: .72rem; }
.live-freshness { display: inline-flex; align-items: center; gap: 9px; color: var(--faint); font-size: .7rem; white-space: nowrap; }
.live-label { display: inline-flex; align-items: center; gap: 6px; color: var(--green); font-weight: 700; letter-spacing: .06em; }
.live-label i { width: 6px; height: 6px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px rgba(67, 214, 161, .8); }
.live-freshness.pending .live-label { color: var(--faint); }
.live-freshness.pending .live-label i { background: var(--faint); box-shadow: none; }
.live-freshness.reconnecting .live-label { color: var(--amber); }
.live-freshness.reconnecting .live-label i { background: var(--amber); box-shadow: none; }
.live-freshness.fallback .live-label { color: var(--blue); }
.live-freshness.fallback .live-label i { background: var(--blue); box-shadow: none; }
.page-status { display: flex; align-items: flex-end; flex-direction: column; gap: 9px; }
.metric-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.metric-card { position: relative; overflow: hidden; min-height: 126px; display: flex; align-items: flex-start; gap: 14px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: linear-gradient(145deg, rgba(20, 28, 45, .9), rgba(14, 20, 33, .9)); }
.metric-card::after { content: ""; position: absolute; inset: auto 0 0; height: 2px; background: var(--metric-color); opacity: .65; }
.metric-card > div { display: flex; min-width: 0; flex-direction: column; }
.metric-icon { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; border: 1px solid color-mix(in srgb, var(--metric-color) 35%, var(--line)); border-radius: 8px; color: var(--metric-color); background: color-mix(in srgb, var(--metric-color) 8%, transparent); font-size: .9rem; }
.metric-card div > span { color: var(--muted); font-size: .73rem; }
.metric-card strong { margin: 6px 0 2px; font-size: 1.75rem; line-height: 1; letter-spacing: -.04em; }
.metric-card small { overflow: hidden; color: var(--faint); font-size: .67rem; text-overflow: ellipsis; white-space: nowrap; }
.accent-blue { --metric-color: var(--blue); }.accent-green { --metric-color: var(--green); }.accent-amber { --metric-color: var(--amber); }.accent-red { --metric-color: var(--red); }.accent-violet { --metric-color: var(--violet); }

.panel { border: 1px solid var(--line); border-radius: var(--radius); background: linear-gradient(145deg, rgba(16, 22, 36, .98), rgba(13, 18, 30, .98)); box-shadow: 0 12px 30px rgba(0, 0, 0, .1); }
.panel-heading { min-height: 69px; padding: 15px 18px; border-bottom: 1px solid var(--line); }
.chart-grid { display: grid; grid-template-columns: 1.3fr .7fr; gap: 12px; margin: 24px 0; }
.chart-wide { grid-row: span 2; }
.chart-card { overflow: hidden; }
.chart-shell { min-height: 230px; padding: 12px 14px 6px; }
.chart-shell canvas { display: block; max-width: 100%; }
.chart-data { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }
.period-pill, .privacy-chip, .api-version { padding: 5px 8px; border: 1px solid var(--line-bright); border-radius: 999px; color: var(--muted); background: rgba(255, 255, 255, .025); font-size: .65rem; font-weight: 700; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .77rem; }
th { padding: 11px 14px; color: var(--faint); background: rgba(5, 8, 15, .25); text-align: left; font-size: .63rem; letter-spacing: .08em; text-transform: uppercase; }
td { padding: 13px 14px; border-top: 1px solid rgba(34, 44, 64, .78); color: var(--text-soft); vertical-align: middle; }
tbody tr { transition: background .15s ease; }
tbody tr:hover { background: rgba(113, 141, 255, .035); }
.events-table { min-width: 1050px; }
.event-time { color: var(--text-soft); white-space: nowrap; }
.room-badge { display: inline-flex; padding: 4px 7px; border: 1px solid rgba(113, 141, 255, .22); border-radius: 6px; color: #9aabff; background: rgba(113, 141, 255, .07); font: 700 .68rem/1.2 "SFMono-Regular", Consolas, monospace; white-space: nowrap; }
.sequence { color: var(--muted); }
.sender { max-width: 190px; }
.sender strong { display: block; overflow: hidden; color: var(--text); font-size: .76rem; text-overflow: ellipsis; white-space: nowrap; }
.did-preview { display: block; max-width: 180px; overflow: hidden; margin-top: 2px; color: var(--faint); font: .61rem monospace; text-overflow: ellipsis; white-space: nowrap; }
.identity, .severity, .flag { display: inline-flex; align-items: center; gap: 6px; border-radius: 999px; font: 700 .6rem/1.2 "SFMono-Regular", Consolas, monospace; white-space: nowrap; }
.identity, .severity { padding: 5px 8px; border: 1px solid var(--line); }
.identity > span, .severity > span { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.identity-signed, .identity-did { color: var(--green); border-color: rgba(67, 214, 161, .22); background: rgba(67, 214, 161, .06); }
.identity-unsigned { color: var(--amber); border-color: rgba(234, 182, 90, .22); background: rgba(234, 182, 90, .06); }
.severity-none { color: var(--muted); }.severity-info { color: var(--blue); border-color: rgba(113, 141, 255, .22); background: rgba(113, 141, 255, .06); }.severity-low { color: var(--amber); border-color: rgba(234, 182, 90, .22); background: rgba(234, 182, 90, .06); }.severity-medium { color: var(--orange); border-color: rgba(238, 141, 86, .24); background: rgba(238, 141, 86, .07); }.severity-high { color: var(--red); border-color: rgba(240, 107, 120, .25); background: rgba(240, 107, 120, .07); }
.severity-large { padding: 8px 12px; font-size: .68rem; }
.flag { max-width: 220px; overflow: hidden; margin: 2px 4px 2px 0; padding: 4px 7px; border: 1px solid var(--line-bright); color: var(--muted); background: rgba(255, 255, 255, .02); text-overflow: ellipsis; }
.flags-cell { max-width: 280px; }
.muted { color: var(--faint); }
.text-link { font-size: .74rem; font-weight: 700; }

.dashboard-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 24px 0; }
.status-orb { width: 10px; height: 10px; border-radius: 50%; background: var(--green); box-shadow: 0 0 14px rgba(67, 214, 161, .8); }
.status-orb.warning { background: var(--amber); box-shadow: 0 0 14px rgba(234, 182, 90, .7); }
.status-list, .detail-list, .room-card dl { margin: 0; }
.status-list > div { display: grid; grid-template-columns: 170px minmax(0, 1fr); gap: 18px; padding: 11px 18px; border-top: 1px solid rgba(34, 44, 64, .7); }
.status-list > div:first-child { border-top: 0; }
dt { color: var(--muted); font-size: .72rem; }
dd { margin: 0; color: var(--text-soft); font-size: .74rem; overflow-wrap: anywhere; }
.inline-status { display: inline-flex; align-items: center; gap: 7px; color: var(--green); }
.api-panel > p { margin: 18px 18px 13px; color: var(--muted); font-size: .76rem; }
.api-version { color: var(--blue); border-color: rgba(113, 141, 255, .25); }
.endpoint-list { margin: 0 18px; border: 1px solid var(--line); border-radius: 9px; overflow: hidden; }
.endpoint-list a { display: flex; align-items: center; gap: 12px; padding: 9px 11px; border-top: 1px solid var(--line); color: var(--text-soft); }
.endpoint-list a:first-child { border-top: 0; }
.endpoint-list a:hover { background: var(--surface-hover); }
.endpoint-list span { color: var(--green); font: 700 .58rem monospace; }
.endpoint-list code { font-size: .7rem; }
.code-copy { display: flex; align-items: center; gap: 8px; margin: 13px 18px 18px; padding: 9px 10px; border: 1px solid var(--line); border-radius: 9px; background: #080c15; }
.code-copy code { min-width: 0; flex: 1; overflow: hidden; color: var(--muted); font-size: .65rem; text-overflow: ellipsis; white-space: nowrap; }
.code-copy button { padding: 4px 7px; border: 1px solid var(--line-bright); border-radius: 5px; color: var(--text-soft); background: var(--surface-strong); cursor: pointer; font-size: .62rem; }
.explanations { overflow: hidden; }
.explanations dl { display: grid; grid-template-columns: 1fr 1fr; margin: 0; }
.explanations dl div { padding: 17px 18px; border-top: 1px solid var(--line); }
.explanations dl div:nth-child(odd) { border-right: 1px solid var(--line); }
.explanations dl div:nth-child(-n+2) { border-top: 0; }
.explanations dt { color: #8ca1ff; font: 700 .7rem monospace; }
.explanations dd { margin-top: 6px; color: var(--muted); font-size: .76rem; }

.page-heading { min-height: 150px; margin-bottom: 22px; padding: 28px 0 22px; border-bottom: 1px solid var(--line); }
.page-heading h1 { margin: 7px 0 7px; font-size: clamp(2rem, 4vw, 2.7rem); }
.page-heading p { max-width: 720px; margin-bottom: 0; color: var(--muted); font-size: .86rem; }
.filter-panel { margin-bottom: 14px; padding: 13px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.filter-panel form { display: flex; align-items: end; gap: 10px; }
.filter-panel label { display: flex; min-width: 170px; flex: 1; flex-direction: column; gap: 5px; color: var(--muted); font-size: .63rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.filter-panel select { width: 100%; min-height: 39px; padding: 7px 30px 7px 10px; border: 1px solid var(--line-bright); border-radius: 8px; color: var(--text-soft); background: #0d1422; font-size: .74rem; text-transform: none; }
.pagination { display: flex; justify-content: space-between; align-items: center; padding: 13px 17px; border-top: 1px solid var(--line); color: var(--faint); font-size: .68rem; }
.empty-state { min-height: 180px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 30px; color: var(--faint); text-align: center; }
.empty-state > span { font-size: 1.5rem; color: var(--line-bright); }
.empty-state h3, .empty-state h2 { margin: 8px 0 3px; font-size: .95rem; }
.empty-state p { margin: 0; font-size: .74rem; }
.empty-state.compact { min-height: 230px; }

.room-card-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.room-card { padding: 20px; }
.room-card-head { align-items: flex-start; }
.room-card h2 { margin: 10px 0 0; font-size: 1.15rem; }
.room-card dl { display: grid; grid-template-columns: 1fr 2fr; gap: 10px; margin: 22px 0; padding: 15px; border: 1px solid var(--line); border-radius: 10px; background: rgba(5, 8, 15, .22); }
.room-card dl div { min-width: 0; }
.room-card dd { margin-top: 4px; }
.severity-strip { display: flex; flex-wrap: wrap; gap: 8px 12px; margin-bottom: 18px; color: var(--muted); font-size: .65rem; }
.severity-strip span { display: inline-flex; align-items: center; gap: 5px; }
.severity-strip strong { color: var(--text-soft); }
.dot { width: 5px; height: 5px; border-radius: 50%; background: var(--faint); }.dot.high { background: var(--red); }.dot.medium { background: var(--orange); }.dot.low { background: var(--amber); }.dot.info { background: var(--blue); }

.back-link { display: block; margin-bottom: 18px; color: var(--muted); font-size: .72rem; }
.detail-layout { display: grid; grid-template-columns: 1.15fr .85fr; gap: 14px; }
.detail-card { overflow: hidden; }
.detail-wide-card { grid-column: 1 / -1; }
.detail-list { display: grid; grid-template-columns: 1fr 1fr; }
.detail-list > div { min-width: 0; padding: 15px 18px; border-top: 1px solid var(--line); }
.detail-list > div:nth-child(-n+2) { border-top: 0; }
.detail-list dt { margin-bottom: 7px; }
.detail-list dd { font-size: .8rem; }
.detail-list .detail-wide { grid-column: 1 / -1; border-top: 1px solid var(--line); }
.breakable { overflow-wrap: anywhere; word-break: break-word; }
.hash-value { color: var(--muted); }

footer { border-top: 1px solid var(--line); color: var(--faint); font-size: .7rem; }
.footer-row { min-height: 92px; display: grid; grid-template-columns: minmax(280px, 1.2fr) auto minmax(340px, 1.2fr); align-items: center; gap: 24px; }
.footer-credit { display: flex; flex-direction: column; gap: 3px; color: var(--muted); }
.footer-credit strong { color: var(--text-soft); font-weight: 650; }
.footer-credit a, .footer-links a { color: var(--text-soft); }
.footer-credit a:hover, .footer-links a:hover { color: #9caeff; }
.footer-links { display: flex; align-items: center; justify-content: center; gap: 16px; }
.footer-disclaimer { max-width: 420px; margin: 0; justify-self: end; color: var(--faint); text-align: right; }

@media (max-width: 1180px) {
  .header-row { grid-template-columns: minmax(250px, 1fr) auto; }
  .primary-nav { grid-row: 2; grid-column: 1 / -1; height: 45px; border-top: 1px solid rgba(34, 44, 64, .55); }
  .operational-badge { grid-column: 2; grid-row: 1; }
  .metric-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .shell { width: min(100% - 28px, 1380px); }
  .hero { grid-template-columns: 1fr; padding: 34px 30px 56px; gap: 25px; }
  .disclaimer { left: 30px; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .chart-grid { grid-template-columns: 1fr; }
  .chart-wide { grid-row: auto; }
  .dashboard-columns, .room-card-grid { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .site-header { position: static; }
  .header-row { display: flex; flex-wrap: wrap; gap: 14px; padding-top: 15px; }
  .brand-lockup { max-width: calc(100% - 112px); }
  .brand-lockup small { display: none; }
  .operational-badge { margin-left: auto; font-size: .6rem; }
  .primary-nav { order: 3; width: 100%; height: 45px; overflow-x: auto; }
  .primary-nav a { padding: 0 10px; }
  main { padding-block: 20px 45px; }
  .hero { min-height: 0; padding: 27px 22px 67px; }
  .hero h1 { font-size: 2rem; }
  .disclaimer { right: 22px; left: 22px; bottom: 18px; }
  .section-heading { align-items: flex-start; }
  .freshness { max-width: 150px; text-align: right; }
  .metric-grid { grid-template-columns: 1fr; }
  .metric-card { min-height: 104px; }
  .filter-panel form { align-items: stretch; flex-direction: column; }
  .filter-panel label { width: 100%; }
  .filter-panel .button { width: 100%; }
  .explanations dl, .detail-list { grid-template-columns: 1fr; }
  .explanations dl div, .explanations dl div:nth-child(odd), .explanations dl div:nth-child(-n+2), .detail-list > div, .detail-list > div:nth-child(-n+2) { border-right: 0; border-top: 1px solid var(--line); }
  .explanations dl div:first-child, .detail-list > div:first-child { border-top: 0; }
  .detail-layout { grid-template-columns: 1fr; }
  .detail-wide-card, .detail-list .detail-wide { grid-column: auto; }
  .page-heading { align-items: flex-start; flex-direction: column; min-height: 130px; }
  .status-list > div { grid-template-columns: 1fr; gap: 4px; }
  .footer-row { grid-template-columns: 1fr; gap: 12px; padding-block: 22px; }
  .footer-links { justify-content: flex-start; }
  .footer-disclaimer { justify-self: start; text-align: left; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
