:root {
    --cinch-bg: #1a1d24;
    --cinch-bg-light: #23272f;
    --cinch-text: #f4f6f9;
    --cinch-text-muted: #9aa4b2;
    --cinch-accent: #2d8cff;
    --cinch-border: #2c313a;

    --status-operational: #2ecc71;
    --status-degraded: #f1c40f;
    --status-partial: #e67e22;
    --status-major: #e74c3c;
    --status-maintenance: #3498db;
    --status-unknown: #95a5a6;
}

body {
    background-color: var(--cinch-bg);
    color: var(--cinch-text);
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    font-size: 14px;
    margin: 0;
    padding: 0;
}

.container { max-width: 1080px; margin: 0 auto; padding: 0 20px; }

/* Header */
.statusPage { min-height: 100vh; display: flex; flex-direction: column; }
.statusHeader {
    background: var(--cinch-bg-light);
    border-bottom: 1px solid var(--cinch-border);
    padding: 16px 0;
}
.statusHeader { display: flex; justify-content: space-between; align-items: center; padding: 16px 20px; }
.statusHeader .brand { display: flex; align-items: center; margin: 0; }
.statusHeader .brand img { height: 28px; }
.statusNav { display: flex; gap: 24px; }
.statusNav .navLink { color: var(--cinch-text-muted); text-decoration: none; font-size: 14px; }
.statusNav .navLink:hover { color: var(--cinch-text); }

/* Main */
.statusMain { flex: 1; padding: 40px 0; }

/* Overall status banner */
.overallBanner {
    border-radius: 8px;
    padding: 28px 24px;
    text-align: center;
    margin-bottom: 32px;
    border: 1px solid var(--cinch-border);
    background: var(--cinch-bg-light);
}
.overallBanner h1 { margin: 0 0 6px 0; font-size: 28px; font-weight: 400; }
.overallBanner .sub { color: var(--cinch-text-muted); font-size: 14px; }
.overallBanner.level-Operational { border-left: 6px solid var(--status-operational); }
.overallBanner.level-Degraded { border-left: 6px solid var(--status-degraded); }
.overallBanner.level-PartialOutage { border-left: 6px solid var(--status-partial); }
.overallBanner.level-MajorOutage { border-left: 6px solid var(--status-major); }
.overallBanner.level-Maintenance { border-left: 6px solid var(--status-maintenance); }
.overallBanner.level-Unknown { border-left: 6px solid var(--status-unknown); }

/* Service groups */
.serviceGroup { margin-bottom: 32px; }
.serviceGroup h2 { font-size: 13px; text-transform: uppercase; letter-spacing: 1.5px; color: var(--cinch-text-muted); margin: 0 0 12px 0; }

.serviceRow {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 18px;
    background: var(--cinch-bg-light);
    border: 1px solid var(--cinch-border);
    border-radius: 6px;
    margin-bottom: 8px;
    text-decoration: none;
    color: var(--cinch-text);
    transition: border-color .15s;
}
.serviceRow:hover { border-color: var(--cinch-accent); text-decoration: none; color: var(--cinch-text); }
.serviceRow .name { font-weight: 500; }
.serviceRow .meta { font-size: 12px; color: var(--cinch-text-muted); }
.statusPill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 500;
    padding: 4px 10px;
    border-radius: 14px;
    color: #fff;
}
.statusPill::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: currentColor; box-shadow: 0 0 0 2px rgba(255,255,255,0.25); }
.statusPill.level-Operational { background: var(--status-operational); }
.statusPill.level-Degraded { background: var(--status-degraded); color: #1a1d24; }
.statusPill.level-PartialOutage { background: var(--status-partial); }
.statusPill.level-MajorOutage { background: var(--status-major); }
.statusPill.level-Maintenance { background: var(--status-maintenance); }
.statusPill.level-Unknown { background: var(--status-unknown); }

/* Uptime bar chart */
.uptimeBars { display: flex; gap: 2px; height: 40px; margin: 16px 0 24px 0; }
.uptimeBars .bar {
    flex: 1;
    border-radius: 3px;
    min-width: 2px;
    background: var(--status-operational);
    cursor: help;
}
.uptimeBars .bar.has-failures { background: var(--status-degraded); }
.uptimeBars .bar.all-failures { background: var(--status-major); }
.uptimeBars .bar.no-data { background: var(--status-unknown); opacity: 0.3; }

.uptimeStats { display: flex; gap: 32px; margin-bottom: 24px; flex-wrap: wrap; }
.uptimeStats .stat { display: flex; flex-direction: column; }
.uptimeStats .statLabel { font-size: 11px; text-transform: uppercase; letter-spacing: 1px; color: var(--cinch-text-muted); }
.uptimeStats .statValue { font-size: 24px; font-weight: 400; }

/* History table */
.historyTable { width: 100%; margin-top: 16px; border-collapse: collapse; }
.historyTable th { text-align: left; color: var(--cinch-text-muted); font-weight: normal; padding: 8px 12px; border-bottom: 1px solid var(--cinch-border); font-size: 12px; text-transform: uppercase; letter-spacing: 1px; }
.historyTable td { padding: 10px 12px; border-bottom: 1px solid var(--cinch-border); }
.historyTable tr.success td { color: var(--cinch-text); }
.historyTable tr.failure td { color: var(--status-major); }

/* Misc */
.backLink { color: var(--cinch-accent); text-decoration: none; }
.backLink:hover { text-decoration: underline; }
.meta { color: var(--cinch-text-muted); font-size: 12px; }
h1 { color: var(--cinch-text); font-weight: 400; font-size: 28px; }
h2 { color: var(--cinch-text); font-weight: 500; font-size: 22px; }
h3 { color: var(--cinch-text); font-weight: 500; font-size: 18px; margin-top: 28px; }

/* Footer */
.statusFooter {
    background: var(--cinch-bg-light);
    border-top: 1px solid var(--cinch-border);
    padding: 16px 0;
    color: var(--cinch-text-muted);
    font-size: 12px;
    text-align: center;
}
.statusFooter a { color: var(--cinch-text-muted); }
.statusFooter .buildVersion { color: var(--cinch-text-muted); opacity: 0.6; margin-left: 8px; }
