:root { color-scheme: light; font-family: Inter, ui-sans-serif, system-ui, sans-serif; color: #162031; background: #f4f7fa; }
* { box-sizing: border-box; }
body { margin: 0; }
a { color: inherit; }
.home-link, .site-heading a { text-decoration: none; }
.home-link:hover, .site-heading a:hover, .back-link:hover { text-decoration: underline; }
.page-header, main { width: min(1040px, calc(100% - 40px)); margin: 0 auto; }
.page-header { align-items: flex-start; display: flex; justify-content: space-between; padding: 64px 0 32px; }
.header-brand { align-items: center; display: flex; gap: 16px; min-width: 0; }
.brand-logo { display: block; flex: 0 0 auto; }
.brand-logo img { display: block; height: 105px; object-fit: contain; width: auto; }
.eyebrow { color: #2463eb; font-size: .78rem; font-weight: 700; letter-spacing: .12em; margin: 0 0 8px; text-transform: uppercase; }
h1 { font-size: clamp(2rem, 5vw, 3.5rem); letter-spacing: -.04em; margin: 0; }
.subtitle { color: #657083; margin: 12px 0 0; }
.summary { display: grid; gap: 12px; grid-template-columns: repeat(3, 1fr); margin-bottom: 20px; }
.summary div { background: #e8eef8; border-radius: 12px; display: flex; flex-direction: column; padding: 18px; }
.summary strong { font-size: 1.7rem; }
.summary span { color: #657083; font-size: .82rem; }
.site-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); padding-bottom: 60px; }
.site-card, .empty-state, .detail-header, .detail-summary, .history-panel { background: white; border: 1px solid #dfe5ed; border-radius: 16px; box-shadow: 0 12px 35px rgb(31 46 68 / 7%); padding: 26px; }
.site-heading { align-items: center; display: flex; gap: 18px; justify-content: space-between; }
h2 { font-size: 1.25rem; margin: 0; }
.status { border-radius: 999px; font-size: .78rem; font-weight: 700; padding: 6px 10px; }
.status.online { background: #dcfce7; color: #137333; }
.status.offline { background: #fee2e2; color: #b42318; }
.status.unknown { background: #edf0f4; color: #596577; }
.metrics { display: grid; gap: 17px; margin: 28px 0; }
.metrics div { align-items: baseline; display: flex; justify-content: space-between; }
dt { color: #6a7484; font-size: .88rem; }
dd { font-weight: 650; margin: 0; text-align: right; }
.history { display: flex; flex-wrap: wrap; gap: 6px; }
.history-dot { border-radius: 4px; display: block; height: 10px; width: 22px; }
.history-dot.online { background: #32b568; }
.history-dot.offline { background: #e65353; }
.speed-summary { border-top: 1px solid #e5e9ef; margin-top: 24px; padding-top: 20px; }
.speed-summary h3 { font-size: .9rem; margin: 0 0 14px; }
.speed-values, .average-grid { display: grid; gap: 14px; grid-template-columns: repeat(2, 1fr); }
.speed-values p, .average-grid div { display: flex; flex-direction: column; gap: 3px; margin: 0; }
.speed-values span, .average-grid span, .speed-values small, .average-grid small { color: #657083; font-size: .75rem; }
.compact { font-size: .78rem; margin: 10px 0 0; }
.average-grid { margin-bottom: 20px; }
.average-grid div { background: #f4f7fa; border-radius: 10px; padding: 16px; }
.empty-state { text-align: center; }
.empty-state p { color: #657083; }
.back-link { color: #2463eb; font-weight: 650; }
.detail-header { align-items: center; display: flex; justify-content: space-between; margin: 18px 0 20px; }
.detail-header h2 { font-size: 2rem; }
.detail-summary { display: grid; grid-template-columns: repeat(3, 1fr); }
.detail-summary div { align-items: flex-start; flex-direction: column; gap: 6px; }
.history-panel { margin: 20px 0 60px; }
.history-panel h3 { margin-top: 0; }
.table-wrap { overflow-x: auto; }
table { border-collapse: collapse; width: 100%; }
th, td { border-bottom: 1px solid #e5e9ef; padding: 13px 8px; text-align: left; }
th { color: #657083; font-size: .78rem; letter-spacing: .04em; text-transform: uppercase; }
.text-state { font-weight: 700; }
.text-state.online { color: #137333; }
.text-state.offline { color: #b42318; }
.muted { color: #657083; }
.admin-panel { background: #fff; border: 1px solid #dfe5ed; border-radius: 16px; box-shadow: 0 12px 35px rgb(31 46 68 / 7%); margin-bottom: 48px; padding: 26px; }
.admin-panel h2 { font-size: 1.6rem; margin-bottom: 22px; }
.admin-panel h3 { margin: 0 0 12px; }
.admin-panel form { display: grid; gap: 12px; }
.admin-panel label { color: #465267; display: grid; font-size: .86rem; font-weight: 650; gap: 6px; }
.admin-panel input, .admin-panel select, .admin-panel textarea { border: 1px solid #cbd4df; border-radius: 8px; color: #162031; font: inherit; padding: 10px 11px; width: 100%; }
.admin-panel button, .button-link { align-items: center; background: #2463eb; border: 1px solid #2463eb; border-radius: 8px; color: #fff; cursor: pointer; display: inline-flex; font: inherit; font-weight: 650; justify-content: center; padding: 9px 14px; text-decoration: none; width: fit-content; }
.admin-panel button:disabled { cursor: wait; opacity: .65; }
.admin-panel .button-secondary, .button-link { background: #fff; color: #2453a6; }
.admin-panel .button-quiet { background: transparent; border-color: transparent; color: #2453a6; padding: 5px 7px; }
.admin-panel .button-danger { background: #fff; border-color: #d92d20; color: #b42318; }
.admin-panel .inline-form { display: inline-flex; margin: 2px; }
.admin-grid { display: grid; gap: 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 28px; }
.admin-subpanel, .key-card { background: #f8fafc; border: 1px solid #dfe5ed; border-radius: 12px; margin-top: 18px; padding: 20px; }
.action-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.field-unit { color: #7a8595; float: right; font-size: .75rem; font-weight: 500; }
.key-list { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.key-card.active { border-color: #8ad6a7; }
.key-card.revoked, .key-card.expired { opacity: .8; }
.key-card h4 { margin: 0 0 6px; }
.key-status { color: #536176; margin-top: 0; }
.key-card form + form, .key-card details + form, .key-card p + form { margin-top: 12px; }
.command-block { align-items: start; display: grid; gap: 12px; grid-template-columns: 1fr auto; }
.command-text { font-family: ui-monospace, SFMono-Regular, Consolas, monospace !important; resize: vertical; }
.copy-feedback, .pending-feedback { min-height: 1.3em; }
.spinner { animation: spin .8s linear infinite; border: 2px solid currentColor; border-right-color: transparent; border-radius: 50%; display: inline-block; height: 1em; margin-right: 8px; vertical-align: -.12em; width: 1em; }
.form-message { border-radius: 8px; padding: 10px 12px; }
.form-message.success { background: #dcfce7; color: #125f30; }
.form-message.error { background: #fee2e2; color: #9f241d; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (max-width: 850px) { .brand-logo img { height: 82px; } }
@media (max-width: 600px) { .page-header, main { width: min(100% - 24px, 1040px); } .page-header { padding-top: 36px; } .header-brand { gap: 10px; } .brand-logo img { height: 56px; } .site-card, .detail-header, .detail-summary, .history-panel, .admin-panel { padding: 20px; } .detail-summary, .admin-grid { grid-template-columns: 1fr; } .summary div { padding: 13px; } .command-block { grid-template-columns: 1fr; } }

/* Compact single-screen dashboard */
.page-header { padding: 24px 0 14px; }
.page-header h1 { font-size: clamp(1.8rem, 3vw, 2.6rem); }
.page-header .subtitle { margin-top: 5px; }
.compact-summary { align-items: stretch; grid-template-columns: minmax(280px, 1fr) repeat(3, 100px); margin-bottom: 10px; }
.compact-summary > * { min-height: 52px; }
.compact-summary .overall-health { border-radius: 12px; display: flex; flex-direction: column; justify-content: center; margin: 0; padding: 10px 16px; }
@media (min-width: 651px) { .compact-summary > * { min-height: 40px; } .compact-summary > div { padding: 12px; } .compact-summary .overall-health { padding: 7px 16px; } }
.overall-health.calm { background: #dcfce7; color: #125f30; }
.overall-health.attention { background: #fee2e2; color: #9f241d; }
.overall-health.neutral { background: #edf0f4; color: #4f5d70; }
.overall-health span { color: inherit; }
.health-narrow { display: none; }
.site-list { display: grid; gap: 7px; padding-bottom: 18px; }
.site-row { align-items: center; background: #fff; border: 1px solid #dfe5ed; border-radius: 11px; color: inherit; cursor: pointer; display: grid; font: inherit; gap: 13px; grid-template-columns: minmax(180px, 1.5fr) .65fr .75fr 1.1fr 1.15fr 48px; min-height: 66px; padding: 8px 13px; text-align: left; width: 100%; }
.site-row:hover, .site-row:focus-visible { border-color: #77a0e8; box-shadow: 0 5px 18px rgb(31 46 68 / 10%); outline: none; }
.site-identity { align-items: center; display: grid; grid-template-columns: 12px 1fr; }
.site-identity strong { font-size: 1.02rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.site-identity small { color: #657083; grid-column: 2; }
.state-dot { border-radius: 50%; height: 10px; margin-right: 9px; width: 10px; }
.state-dot.online { background: #27a85c; box-shadow: 0 0 0 4px #dcfce7; }
.state-dot.offline { background: #d94747; box-shadow: 0 0 0 4px #fee2e2; }
.state-dot.unknown { background: #8792a2; box-shadow: 0 0 0 4px #edf0f4; }
.row-metric { display: flex; flex-direction: column; min-width: 0; }
.row-metric small { color: #738093; font-size: .67rem; }
.auto-label-narrow { display: none; }
.row-metric strong { font-size: .78rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.row-open { color: #2463eb; font-size: .75rem; font-weight: 700; }
.site-dialog { background: transparent; border: 0; max-height: 92vh; max-width: 1000px; padding: 0; width: calc(100% - 32px); }
.site-dialog::backdrop { background: rgb(13 23 38 / 62%); backdrop-filter: blur(3px); }
.dialog-shell { background: #f4f7fa; border-radius: 18px; max-height: 92vh; overflow: auto; padding: 24px; }
.dialog-shell > header { align-items: flex-start; display: flex; justify-content: space-between; }
.dialog-shell h2 { font-size: 1.8rem; }
.dialog-close { background: #e5e9ef; border: 0; border-radius: 50%; cursor: pointer; font-size: 1.5rem; height: 38px; width: 38px; }
.dialog-status { align-items: center; display: flex; flex-wrap: wrap; gap: 14px; margin: 14px 0; }
.dialog-status > span:not(.status) { color: #657083; font-size: .8rem; }
.dialog-grid { display: grid; gap: 14px; grid-template-columns: 2fr 1fr; }
.dialog-grid > section, .dialog-grid > aside { background: #fff; border: 1px solid #dfe5ed; border-radius: 12px; padding: 17px; }
.graph-panel { position: relative; }
.dialog-grid.lower { grid-template-columns: 1fr 1fr; margin-top: 14px; }
.panel-heading { align-items: center; display: flex; justify-content: space-between; }
.panel-heading h3, .dialog-grid h3 { margin: 0 0 12px; }
.range-buttons { display: flex; gap: 4px; }
.range-buttons button { background: #edf1f6; border: 0; border-radius: 6px; cursor: pointer; padding: 6px 9px; }
.range-buttons button.active { background: #2463eb; color: #fff; }
.speed-graph-stack { background: #f8fafc; border-radius: 8px; height: 220px; overflow: hidden; position: relative; }
.speed-graph { display: block; height: 108px; width: 100%; }
.speed-graph + .speed-graph { border-top: 1px solid #dfe5ed; }
.speed-graph text { fill: #738093; font-size: 14px; }
.speed-graph .band-label { font-size: 13px; font-weight: 700; }
.speed-graph .band-label.download { fill: #2463eb; }
.speed-graph .band-label.upload { fill: #25a764; }
.speed-graph polyline { fill: none; stroke-linecap: round; stroke-linejoin: round; stroke-width: 4; }
.speed-graph .download-line { stroke: #2463eb; }
.speed-graph .upload-line { stroke: #25a764; }
.speed-graph .axis { stroke: #cfd6e0; }
.speed-graph .graph-point { cursor: pointer; fill: #fff; stroke-width: 3; }
.speed-graph .graph-point.download { stroke: #2463eb; }
.speed-graph .graph-point.upload { stroke: #25a764; }
.speed-graph .graph-point:focus { outline: none; stroke-width: 5; }
.graph-tooltip { align-items: center; background: #162031; border-radius: 10px; box-shadow: 0 8px 24px rgb(13 23 38 / 25%); color: #fff; display: flex; gap: 9px; max-width: 250px; padding: 8px 11px; pointer-events: none; position: absolute; z-index: 3; }
.graph-tooltip[hidden] { display: none; }
.graph-tooltip img { flex: 0 0 auto; height: 36px; object-fit: contain; width: 34px; }
.graph-tooltip div { display: flex; flex-direction: column; font-size: .72rem; line-height: 1.35; }
.graph-tooltip strong { font-size: .75rem; white-space: nowrap; }
.graph-empty { color: #738093; left: 16px; margin: 0; position: absolute; right: 16px; text-align: center; top: 85px; }
.big-number { font-size: 1.7rem; font-weight: 750; margin: 8px 0; }
.big-number.secondary { color: #26704a; }
.big-number small { color: #657083; font-size: .7rem; font-weight: 500; }
.test-now { border: 0; border-radius: 8px; display: block; margin-top: 16px; padding: 11px; width: 100%; }
.test-now:not(:disabled) { background: #2463eb; color: #fff; cursor: pointer; }
.admin-session { align-items: center; display: grid; font-size: .75rem; gap: 7px 10px; grid-template-columns: minmax(0, 1fr) auto; justify-items: end; }
.admin-session nav { display: flex; flex-wrap: nowrap; gap: 6px; grid-column: 1 / -1; white-space: nowrap; }
.admin-session > span { white-space: nowrap; }
.admin-session > .login-action { white-space: nowrap; }
.admin-session form { margin: 0; }
.admin-session button, .admin-session a { background: #e8eef8; border: 0; border-radius: 7px; cursor: pointer; padding: 7px 10px; text-decoration: none; }
.test-status { align-items: center; display: flex; flex-wrap: wrap; gap: 3px 7px; min-height: 1.4em; }
.status-guidance { color: #657083; flex-basis: 100%; font-size: .9em; }
.auto-test-time { display: block; margin: -7px 0 12px; }
.auto-test-time[hidden] { display: none; }
.login-panel { background: #fff; border: 1px solid #dfe5ed; border-radius: 16px; margin: 20px auto; max-width: 440px; padding: 28px; }
.login-panel form, .login-panel label { display: grid; gap: 8px; }
.login-panel form { gap: 16px; margin-top: 20px; }
.login-panel input { border: 1px solid #cfd6e0; border-radius: 7px; font: inherit; padding: 10px; }
.login-panel button { background: #2463eb; border: 0; border-radius: 7px; color: #fff; padding: 11px; }
.form-message.error { background: #fee2e2; border-radius: 7px; color: #9f241d; padding: 10px; }
.manual-tests-panel { background: #fff; border: 1px solid #dfe5ed; border-radius: 12px; margin-top: 14px; padding: 17px; }
.manual-tests-panel h3 { margin-top: 0; }
.key-card.current-connection { width: 100%; max-width: none; }
.key-card strong { overflow-wrap: anywhere; word-break: break-word; }
.manual-test-actions { display: grid; gap: 8px; margin-top: 12px; width: 100%; }
.manual-test-actions button { align-items: center; border: 1px solid #2463eb; border-radius: 8px; cursor: pointer; display: inline-flex; font: inherit; font-weight: 650; justify-content: center; margin: 0; min-height: 42px; padding: 10px 12px; text-align: center; width: 100%; }
.manual-test-actions .test-now { background: #2463eb; color: #fff; }
.manual-test-actions .button-secondary { background: #fff; color: #2453a6; }
.manual-test-actions button:disabled { cursor: wait; opacity: .6; }
.incident-list { list-style: none; margin: 0; padding: 0; }
.incident-list li { display: flex; font-size: .78rem; justify-content: space-between; padding: 6px 0; }
.fallback-link { font-size: .75rem; margin-bottom: 0; text-align: right; }
@media (max-width: 900px) { .site-row { grid-template-columns: minmax(180px, 1.4fr) repeat(3, 1fr) 42px; } .site-row .row-metric:nth-of-type(3) { display: none; } }
@media (max-width: 800px) { .page-header { flex-direction: column; gap: 16px; } .admin-session { justify-items: start; } .admin-session nav { flex-wrap: wrap; white-space: normal; } }
@media (max-width: 650px) { .compact-summary { grid-template-columns: repeat(3, 1fr); } .compact-summary .overall-health { grid-column: 1 / -1; min-height: 42px; padding: 7px 12px; } .compact-summary .overall-health strong { font-size: .92rem; } .compact-summary .overall-health > span { font-size: .7rem; } .health-wide, .auto-label-wide { display: none; } .health-narrow, .auto-label-narrow { display: inline; } .site-row { grid-template-columns: minmax(120px, 1.1fr) minmax(120px, 1fr) 38px; min-height: 82px; } .site-row .row-metric { display: flex; } .site-row .availability { display: none; } .site-row .last-checked { display: flex; grid-column: 1; grid-row: 2; } .site-row .performance.has-baseline { display: flex; grid-column: 2 / 4; grid-row: 2; } .site-row .performance.no-baseline { display: none; } .row-open { align-self: center; grid-column: 3; grid-row: 1; } .dialog-grid, .dialog-grid.lower { grid-template-columns: 1fr; } .dialog-shell { padding: 16px; } }
@media (prefers-reduced-motion: reduce) { .spinner { animation: none; } }
