:root {
    --bg: #0f1115; --surface: #171a21; --surface-2: #1e222b; --text: #e6e8ec; --muted: #9aa1ad; --border: #2a2f3a;
    --ok: #3fb950; --warn: #d29922; --down: #f85149; --none: #2a2f3a; --primary: #58a6ff;
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body { margin: 0; padding-bottom: 56px; font: 15px/1.6 "Segoe UI", system-ui, -apple-system, Arial, sans-serif; color: var(--text); background: var(--bg); }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { width: 100%; max-width: 1100px; margin: 0 auto; padding: 32px 20px 40px; }
.header-container { width: 100%; padding: 0 28px; }

.site-header { background: var(--surface); }
.header-main { border-bottom: 1px solid var(--border); }
.header-main .header-container { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; min-height: 96px; }
.site-branding { display: flex; flex-direction: column; gap: 4px; color: var(--text); }
.site-branding:hover { text-decoration: none; }
.site-title { font-size: 1.9rem; font-weight: 700; line-height: 1.15; letter-spacing: -.02em; }
.site-description { color: var(--muted); font-size: .9rem; }

.banner { display: flex; align-items: center; gap: 16px; padding: 20px 22px; margin-bottom: 20px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.banner strong { display: block; font-size: 1.2rem; }
.banner small { color: var(--muted); }
.banner .dot { flex: 0 0 auto; width: 16px; height: 16px; border-radius: 50%; }
.banner-ok { border-color: rgba(63, 185, 80, .5); } .banner-ok .dot { background: var(--ok); box-shadow: 0 0 0 5px rgba(63, 185, 80, .2); }
.banner-warn { border-color: rgba(210, 153, 34, .5); } .banner-warn .dot { background: var(--warn); box-shadow: 0 0 0 5px rgba(210, 153, 34, .2); }
.banner-down { border-color: rgba(248, 81, 73, .5); } .banner-down .dot { background: var(--down); box-shadow: 0 0 0 5px rgba(248, 81, 73, .2); }
.notice { margin-bottom: 20px; padding: 12px 16px; border: 1px solid rgba(210, 153, 34, .5); border-radius: 8px; background: rgba(210, 153, 34, .12); }

.services { display: grid; gap: 14px; }
.services .group { margin: 18px 0 0; font-size: .85rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.services .group:first-child { margin-top: 0; }
.service { padding: 18px 20px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.service-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.service h2 { margin: 0; font-size: 1.1rem; }
.host { color: var(--muted); font-size: .85rem; }
.badge { padding: 3px 12px; font-size: .8rem; font-weight: 600; white-space: nowrap; border-radius: 999px; border: 1px solid; }
.badge-up { color: var(--ok); background: rgba(63, 185, 80, .12); border-color: rgba(63, 185, 80, .4); }
.badge-degraded { color: var(--warn); background: rgba(210, 153, 34, .12); border-color: rgba(210, 153, 34, .4); }
.badge-down { color: var(--down); background: rgba(248, 81, 73, .12); border-color: rgba(248, 81, 73, .4); }
.badge-unknown { color: var(--muted); background: var(--surface-2); border-color: var(--border); }

.bars { display: flex; gap: 3px; height: 30px; margin-bottom: 14px; }
.bar { flex: 1; border-radius: 3px; background: var(--none); }
.bar-ok { background: var(--ok); } .bar-warn { background: var(--warn); } .bar-down { background: var(--down); }
.bar:hover { opacity: .75; }

.meta { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 0; }
.meta dt { color: var(--muted); font-size: .75rem; }
.meta dd { margin: 0; font-weight: 600; }
.error { margin: 12px 0 0; color: var(--down); font-size: .9rem; }

.incidents { margin-top: 32px; }
.incidents h2 { font-size: 1.1rem; }
.incidents ul { margin: 0; padding: 0; list-style: none; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.incidents li { display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 12px 18px; border-top: 1px solid var(--border); }
.incidents li:first-child { border-top: 0; }
.muted, .empty { color: var(--muted); }

.site-footer { position: fixed; left: 0; right: 0; bottom: 0; z-index: 1000; width: 100%; background: var(--surface); border-top: 1px solid var(--border); }
.footer-container { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 12px 28px; color: var(--muted); font-size: .85rem; }
.footer-container p { margin: 0; }

@media (max-width: 700px) {
    .meta { grid-template-columns: repeat(2, 1fr); }
    .bars { gap: 2px; }
    .header-container, .footer-container { padding-left: 16px; padding-right: 16px; }
    .footer-container { justify-content: center; text-align: center; }
}
