:root {
    --ink: #172d35;
    --muted: #607078;
    --paper: #f2f4f0;
    --panel: #fff;
    --line: #dce3dd;
    --accent: #176a5d;
    --danger: #a42d32;
    --sans: "Avenir Next", "Trebuchet MS", sans-serif;
    --mono: "SFMono-Regular", Consolas, monospace;
}
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: var(--sans); font-size: 15px; line-height: 1.5; }
a { color: inherit; }
button, input, select { font: inherit; }
button, .button { cursor: pointer; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid #e4a64e; outline-offset: 4px; }
button, .button { padding: 10px 16px; border: 1px solid #bdcbc5; border-radius: 6px; color: var(--ink); background: white; text-decoration: none; font-weight: 600; }
button:hover, .button:hover { background: #edf4ef; }
input, select { min-width: 0; padding: 11px 13px; border: 1px solid #bccbc4; border-radius: 5px; background: white; color: var(--ink); }
label { display: grid; gap: 7px; font-size: 13px; font-weight: 600; }
h1, h2, h3, p { margin-top: 0; }
h1 { font-size: clamp(25px, 3vw, 38px); line-height: 1.15; letter-spacing: -.04em; font-weight: 600; margin-bottom: 12px; }
h2 { font-size: 21px; line-height: 1.25; letter-spacing: -.025em; margin: 0; }
.eyebrow { font: 10px/1.6 var(--mono); letter-spacing: .11em; font-weight: 600; margin-bottom: 12px; }
.wordmark { display: block; font: 700 23px/1.1 var(--mono); text-decoration: none; letter-spacing: -.08em; }
.wordmark span { display: block; font-size: 10px; letter-spacing: .35em; margin-top: 10px; color: #add1c1; }
.muted { color: var(--muted); }
.small { font-size: 12px; }
.block { display: block; }
.login-layout { min-height: 100svh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-intro { color: #f3f5ed; padding: clamp(30px, 6vw, 90px); display: flex; flex-direction: column; justify-content: space-between; gap: 70px; background: radial-gradient(ellipse at 90% 90%, #346f5b80, transparent 60%), repeating-linear-gradient(90deg, transparent 0 89px, #ffffff06 89px 90px), #152e35; }
.login-intro h1 { font-size: clamp(36px, 4.5vw, 65px); max-width: 580px; line-height: 1.08; }
.login-intro p:not(.eyebrow) { color: #bbd0c8; max-width: 400px; }
.login-panel { padding: 40px; display: grid; place-items: center; }
.login-form { width: 100%; max-width: 370px; }
.login-form h2 { font-size: 28px; margin-bottom: 12px; }
.login-form label { margin-top: 23px; }
.primary { background: var(--accent); border-color: var(--accent); color: white; }
.primary:hover { background: #105347; }
.login-form .primary { margin-top: 30px; width: 100%; display: flex; justify-content: space-between; }
.setup { max-width: 650px; margin: 10vh auto; padding: 30px; }
.app-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100svh; }
.sidebar { background: linear-gradient(160deg, #18333b, #10292d); color: #f5f5ec; padding: 35px 22px; display: flex; flex-direction: column; position: sticky; top: 0; height: 100svh; }
.sidebar .wordmark { margin-bottom: 55px; padding: 0 10px; }
.sidebar > .eyebrow { padding: 0 10px; color: #a1b7b3; }
.project-link { display: flex; justify-content: space-between; gap: 8px; padding: 12px 10px; margin-bottom: 5px; text-decoration: none; font-size: 13px; border-radius: 5px; }
.project-link:hover { background: #ffffff0a; }
.project-link.selected { background: #ffffff14; box-shadow: inset 3px 0 #acd2ad; }
.project-link span { color: #c3d5cc; font-family: var(--mono); }
.sidebar-bottom { margin-top: auto; padding-top: 30px; font-size: 11px; color: #a8bcb5; }
.logout { padding: 8px 0; border: 0; background: transparent; color: #f3f4ec; font-size: 12px; }
.logout:hover { background: transparent; color: #c3e6cc; }
.dashboard { padding: 40px clamp(20px, 4vw, 65px); max-width: 1580px; width: 100%; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.page-head .button { white-space: nowrap; font-size: 12px; }
.page-head .muted { margin-bottom: 0; font-size: 12px; }
.page-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; max-width: 370px; }
.page-actions button { font-size: 12px; white-space: nowrap; }
.page-actions > span { width: 100%; text-align: right; font-size: 10px; }
button:disabled { cursor: wait; opacity: .65; }
.notice { padding: 15px 18px; margin-bottom: 18px; background: #faf2df; border: 1px solid #e8d9b9; border-radius: 6px; color: #684a18; font-size: 13px; }
.notice.danger { background: #fff0ed; border-color: #ebc8c2; color: #8f3331; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 13px; margin: 25px 0 30px; }
.metrics article { padding: 20px; background: var(--panel); border: 1px solid var(--line); border-radius: 7px; }
.metrics span { display: block; font: 9px/1.5 var(--mono); letter-spacing: .04em; color: var(--muted); min-height: 27px; }
.metrics strong { display: block; font-size: 40px; font-weight: 500; letter-spacing: -.05em; margin: 5px 0; }
.metrics small { font-size: 11px; color: var(--muted); }
.metrics .attention { border-top: 3px solid var(--danger); padding-top: 18px; }
.metrics .attention strong { color: var(--danger); }
.panel { background: white; border: 1px solid var(--line); border-radius: 7px; margin-bottom: 25px; overflow: hidden; }
.panel-heading { padding: 24px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.panel-heading .eyebrow { margin-bottom: 6px; color: var(--muted); }
.table-scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { font: 10px/1.5 var(--mono); color: var(--muted); background: #f8faf7; letter-spacing: .02em; }
th, td { padding: 14px 24px; border-top: 1px solid #e8ede8; }
td { font-size: 13px; vertical-align: top; }
td strong { font-weight: 600; }
.url { display: block; font: 11px/1.7 var(--mono); color: var(--muted); overflow-wrap: anywhere; max-width: 400px; margin-top: 3px; }
.badge { display: inline-flex; align-items: center; padding: 4px 8px; font-size: 10px; font-weight: 600; border-radius: 4px; background: #edf0ee; color: #596860; white-space: nowrap; }
.badge.up, .badge.ok { background: #e6f3ec; color: #246a48; }
.badge.down, .badge.critical, .badge.error { background: #fbe7e4; color: #a02c30; }
.badge.pending, .badge.warning, .badge.stale, .badge.missing, .badge.partial { background: #fbf0d8; color: #8b621c; }
.detail { max-width: 220px; overflow-wrap: anywhere; margin-top: 5px; }
.filters { display: flex; align-items: flex-end; gap: 13px; padding: 0 24px 23px; border-bottom: 1px solid var(--line); }
.filters select { padding: 8px 10px; min-width: 140px; }
.filters label { font-size: 11px; }
.filters button { font-size: 12px; }
.empty { padding: 38px 24px; background: linear-gradient(135deg, #f9fbf7, white); }
.empty h3 { font-size: 16px; font-weight: 600; margin-bottom: 8px; }
.empty p { font-size: 13px; color: var(--muted); margin: 0; max-width: 620px; }
.issue { padding: 23px 24px; border-bottom: 1px solid var(--line); }
.issue:last-child { border-bottom: 0; }
.issue-head { display: flex; align-items: center; gap: 10px; margin-bottom: 13px; flex-wrap: wrap; }
.occurrences { margin-left: auto; font: 10px/1.5 var(--mono); color: var(--muted); }
.issue h3 { font: 500 13px/1.65 var(--mono); overflow-wrap: anywhere; margin-bottom: 9px; }
.source { font: 10px/1.6 var(--mono); color: var(--muted); overflow-wrap: anywhere; }
.issue-foot { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.issue-foot p { margin: 0; font-size: 10px; }
.actions { display: flex; gap: 7px; }
.actions button { padding: 6px 9px; font-size: 10px; font-weight: 500; }
.source-row { padding: 18px 24px; border-top: 1px solid var(--line); font-size: 13px; }
.source-row > .badge { margin-left: 10px; }
.source-item { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px 12px; padding-top: 12px; }
.source-item code { font-size: 11px; overflow-wrap: anywhere; }
.source-item .small { width: 100%; font-size: 11px; }
.dashboard-footer { color: var(--muted); font: 10px/1.8 var(--mono); margin-top: 30px; }
@media (max-width: 1150px) {
    .app-layout { grid-template-columns: 210px minmax(0, 1fr); }
    .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    th, td { padding: 12px 16px; }
    .issue-foot { align-items: flex-start; flex-direction: column; }
}
@media (max-width: 760px) {
    .login-layout { grid-template-columns: 1fr; }
    .login-intro { min-height: auto; gap: 40px; padding: 30px; }
    .login-intro > .small { display: none; }
    .login-intro h1 { font-size: 38px; }
    .login-panel { padding: 38px 25px; }
    .app-layout { display: block; }
    .sidebar { position: static; height: auto; padding: 20px; display: block; }
    .sidebar .wordmark { margin-bottom: 20px; padding: 0; font-size: 18px; }
    .sidebar > .eyebrow, .sidebar-bottom p { display: none; }
    .project-link { display: inline-flex; margin: 0 4px 5px 0; gap: 10px; padding: 8px; font-size: 11px; }
    .sidebar-bottom { padding-top: 10px; }
    .dashboard { padding: 27px 16px; }
    .page-head { align-items: flex-start; flex-direction: column; }
    .page-actions { justify-content: flex-start; max-width: none; }
    .page-actions > span { text-align: left; }
    .metrics article { padding: 16px; }
    .metrics strong { font-size: 34px; }
    .panel-heading { align-items: flex-start; flex-direction: column; padding: 20px; }
    .panel-heading > .small { font-size: 10px; }
    table { min-width: 570px; }
    .filters { flex-wrap: wrap; padding: 0 20px 20px; }
    .filters label { flex: 1; }
    .filters select { min-width: 0; width: 100%; }
    .issue { padding: 20px; }
    .source-row { padding: 18px 20px; }
}
