:root {
  color-scheme: dark;
  --background: #0c111b;
  --surface: #141c29;
  --surface-raised: #1a2434;
  --border: #2a3648;
  --text: #edf2fa;
  --muted: #a5b3c8;
  --accent: #82aaff;
  --green: #73ddb1;
  --amber: #f6cd7c;
  --red: #ff9b9f;
  font-family: "Segoe UI", system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--background); color: var(--text); }
[hidden] { display: none !important; }
button, a { -webkit-tap-highlight-color: transparent; }
button, .button-link { font: inherit; }
button:focus-visible, a:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
button { cursor: pointer; color: var(--text); border: 1px solid var(--border); border-radius: 8px; background: var(--surface-raised); padding: 9px 14px; }
button:hover { border-color: var(--accent); }
button:disabled { opacity: .6; cursor: wait; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.7rem, 3vw, 2rem); font-weight: 650; letter-spacing: -.035em; }
h2 { font-size: 1rem; font-weight: 600; }
h3 { font-size: 1.65rem; font-weight: 600; line-height: 1.3; overflow-wrap: anywhere; }
.shell { max-width: 1440px; margin: 0 auto; padding: 0 24px; }
.topbar { display: flex; justify-content: space-between; align-items: center; height: 40px; border-bottom: 1px solid var(--border); }
.brand { display: flex; align-items: center; gap: 8px; font-weight: 700; letter-spacing: .1em; font-size: .9rem; }
.brand > span:last-child { color: var(--muted); font-weight: 400; }
.brand-mark { display: grid; place-items: center; width: 30px; height: 30px; border: 1px solid #6383c3; border-radius: 7px; color: var(--accent); font-size: 1.4rem; margin-right: 4px; }
.view-label, .muted { color: var(--muted); font-size: .875rem; }
.page-heading { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin: 12px 0 10px; }
.label { display: block; color: var(--muted); font-size: .75rem; letter-spacing: .075em; }
.refresh { display: flex; align-items: center; gap: 16px; color: var(--muted); font-size: .875rem; }
.notice { padding: 12px 16px; border: 1px solid #655230; background: #272318; color: var(--amber); border-radius: 8px; margin-bottom: 18px; font-size: .875rem; }
.hostname-setup { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; padding: 18px 24px; margin-bottom: 24px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); }
.hostname-setup > div { flex: 1 1 320px; min-width: 0; }
.hostname-setup p { margin: 6px 0; }
.hostname-setup a { overflow-wrap: anywhere; }
.setup-download { display: inline-block; border: 1px solid var(--border); border-radius: 8px; background: var(--surface-raised); padding: 9px 14px; }
.setup-download:hover { border-color: var(--accent); }
.connection { display: grid; grid-template-columns: 1fr 200px 1fr; align-items: center; gap: 24px; padding: 12px 16px; border: 1px solid var(--border); border-radius: 12px; margin-bottom: 24px; background: #111925; }
.machine { display: flex; align-items: center; gap: 18px; min-width: 0; }
.machine:last-child { justify-self: end; }
.machine strong { display: block; font-size: 1.1rem; font-weight: 600; overflow-wrap: anywhere; }
.machine-icon { display: grid; place-items: center; flex-shrink: 0; width: 48px; height: 48px; background: var(--surface-raised); border: 1px solid var(--border); border-radius: 10px; color: var(--accent); font-size: 1.9rem; }
.connection-path { text-align: center; }
.connection-line { display: flex; align-items: center; gap: 10px; margin-top: 8px; color: #7f91ab; font-family: Consolas, monospace; font-size: .75rem; }
.connection-line i { flex: 1; height: 1px; background: #3b4e6b; }
.badge { display: inline-flex; align-items: center; gap: 7px; padding: 4px 10px; border: 1px solid; border-radius: 6px; font-size: .8125rem; white-space: nowrap; }
.badge::before, .status-dot { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; flex-shrink: 0; }
.badge.ok { color: var(--green); border-color: #315d50; background: #182e29; }
.badge.info { color: var(--accent); border-color: #354f7a; background: #1c2940; }
.badge.error { color: var(--red); border-color: #72434c; background: #302027; }
.badge.warning { color: var(--amber); border-color: #675435; background: #302b20; }
.badge.neutral { color: var(--muted); border-color: #3b485d; background: #202a38; }
.status-dot { display: inline-block; width: 8px; height: 8px; }
.status-dot.ok { color: var(--green); }
.status-dot.neutral { color: var(--muted); }
.workspace { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 24px; align-items: start; }
.main-column, .side-column { display: grid; gap: 24px; min-width: 0; }
.card { padding: 24px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; min-width: 0; }
.card-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 22px; flex-wrap: wrap; }
.job-card { border-top: 2px solid #617ea9; }
.job-identity { margin-top: 28px; margin-bottom: 28px; }
.job-identity p { margin-top: 8px; overflow-wrap: anywhere; }
.job-metrics { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.4fr) minmax(0, 1.1fr) minmax(0, .7fr) minmax(0, 1.1fr); gap: 16px; padding: 22px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.job-metrics > div { min-width: 0; }
.job-metrics .muted { display: block; overflow-wrap: anywhere; }
.job-metrics strong { display: block; font-size: 1.2rem; font-weight: 500; margin-top: 5px; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.job-footer { display: flex; justify-content: space-between; gap: 14px; align-items: center; flex-wrap: wrap; margin-top: 20px; }
.job-footer > span { overflow-wrap: anywhere; }
.button-link { font-size: .875rem; font-weight: 500; }
.empty { text-align: center; padding: 32px 8px 36px; color: var(--muted); font-size: .875rem; }
.empty p { color: #c4cede; margin-bottom: 4px; }
.empty span:not(.empty-icon) { font-size: .8125rem; }
.empty-icon { display: block; font-size: 2rem; color: #7286a4; margin-bottom: 8px; }
.empty.compact { padding: 8px 0 12px; }
.stages, .events { margin: 0; padding: 0; list-style: none; max-height: 400px; overflow-y: auto; }
.stages li { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid var(--border); }
.stages li:last-child { border: 0; padding-bottom: 0; }
.stage-icon { display: grid; place-items: center; height: 23px; width: 23px; border: 1px solid currentColor; border-radius: 50%; font-size: .875rem; }
.stage-icon.ok { color: var(--green); }
.stage-icon.error { color: var(--red); }
.stage-icon.info { color: var(--accent); }
.stage-name { display: block; font-size: .9375rem; overflow-wrap: anywhere; }
.stage-detail { display: block; color: var(--muted); font-size: .8125rem; overflow-wrap: anywhere; }
.stage-time { font-size: .875rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.events { max-height: 250px; }
.events li { display: grid; grid-template-columns: 62px 6px minmax(0, 1fr); gap: 12px; align-items: baseline; padding: 9px 0; }
.events time { color: var(--muted); font-size: .8125rem; font-variant-numeric: tabular-nums; }
.event-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.event-dot.ok { background: var(--green); }
.event-dot.error { background: var(--red); }
.events p { font-size: .875rem; overflow-wrap: anywhere; }
.resource-label { display: flex; align-items: baseline; justify-content: space-between; font-size: .875rem; }
.resource-value { display: flex; align-items: baseline; gap: 8px; margin: 5px 0 14px; }
.resource-value strong { font-size: 2rem; line-height: 1.25; font-weight: 550; letter-spacing: -.035em; }
progress { display: block; appearance: none; border: 0; border-radius: 4px; width: 100%; height: 6px; overflow: hidden; background: #2a364b; color: var(--accent); }
progress::-webkit-progress-bar { background: #2a364b; }
progress::-webkit-progress-value { background: var(--accent); border-radius: 4px; }
progress::-moz-progress-bar { background: var(--accent); }
.warning progress::-webkit-progress-value { background: var(--amber); }
.warning progress::-moz-progress-bar { background: var(--amber); }
.resource > p { margin-top: 9px; }
.small-metrics { display: grid; gap: 11px; margin-top: 22px; }
.small-metrics > div { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.small-metrics strong { font-size: .875rem; font-weight: 500; }
.limit-note { border-top: 1px solid var(--border); padding-top: 14px; margin-top: 20px; color: var(--muted); font-size: .8125rem; }
.limit-note strong { float: right; color: var(--text); font-weight: 500; }
.disk { padding: 0 0 20px; margin-bottom: 20px; border-bottom: 1px solid var(--border); }
.disk:last-child { border: 0; padding-bottom: 0; margin-bottom: 0; }
.disk-heading { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.disk-heading strong { font-family: Consolas, monospace; font-weight: 500; font-size: .9375rem; overflow-wrap: anywhere; }
.disk-value { margin: 10px 0 12px; font-size: .875rem; color: var(--muted); }
.disk-value strong { color: var(--text); font-size: 1.5rem; font-weight: 550; margin-right: 5px; }
.disk .disk-paths { font-size: .8125rem; color: var(--muted); margin-top: 9px; overflow-wrap: anywhere; }
.monitor-description { color: var(--muted); font-size: .875rem; margin-top: -5px; margin-bottom: 20px; }
.monitor-details { margin: 0; font-size: .875rem; display: grid; gap: 12px; }
.monitor-details > div { display: flex; justify-content: space-between; gap: 18px; }
.monitor-details dt { color: var(--muted); }
.monitor-details dd { margin: 0; text-align: right; overflow-wrap: anywhere; min-width: 0; }
footer { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 28px 0; font-size: .8125rem; color: #9aa9bf; }
.history-card { margin-top: 24px; }
.history-card .card-heading { margin-bottom: 10px; }
.history-note { margin-bottom: 18px; }
.history-scroll { overflow-x: auto; }
.history-scroll:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.history-table { width: 100%; min-width: 720px; border-collapse: collapse; table-layout: fixed; font-size: .875rem; }
.history-table th, .history-table td { text-align: left; vertical-align: top; padding: 15px 12px; border-bottom: 1px solid var(--border); overflow-wrap: anywhere; }
.history-table th { color: var(--muted); font-weight: 500; }
.history-table th:nth-child(2) { width: 27%; }
.history-table th:nth-child(4) { width: 13%; }
.history-table th:first-child, .history-table td:first-child { padding-left: 0; }
.history-table th:last-child, .history-table td:last-child { padding-right: 0; }
.history-table tr:last-child td { border-bottom: 0; }
.history-detail { display: block; margin-top: 6px; }
.footer-separator { padding: 0 8px; }
@media (max-width: 1100px) {
  .shell { padding: 0 24px; }
  .workspace { grid-template-columns: minmax(0, 1fr) 320px; gap: 18px; }
  .card { padding: 20px; }
  .connection { grid-template-columns: 1fr 140px 1fr; gap: 16px; padding: 12px 16px; }
  .job-metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .job-metrics > div:last-child { grid-column: 1 / -1; }
  .refresh { flex-direction: column-reverse; align-items: flex-end; gap: 6px; }
}
@media (max-width: 820px) {
  .workspace { grid-template-columns: 1fr; }
  .side-column { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .side-column > :nth-child(n+3) { grid-column: 1 / -1; }
  .connection { grid-template-columns: 1fr; }
  .machine:last-child { justify-self: start; }
  .connection-path { display: flex; align-items: center; gap: 16px; }
  .connection-line { flex: 1; margin-top: 0; }
}
@media (max-width: 520px) {
  .shell { padding: 0 16px; }
  .topbar { min-height: 40px; height: auto; padding: 5px 0; gap: 12px; flex-wrap: wrap; }
  .view-label { font-size: .8125rem; }
  .page-heading { flex-direction: column; align-items: flex-start; gap: 16px; margin-top: 12px; }
  .refresh { width: 100%; flex-direction: row; justify-content: space-between; align-items: center; }
  .side-column { grid-template-columns: 1fr; }
  .card-heading { gap: 8px; }
  .job-metrics { gap: 20px 10px; }
  .card { padding: 18px; }
  .label { letter-spacing: .04em; }
  .job-metrics strong { font-size: 1rem; }
  .events li { gap: 8px; }
}

.job-detail { display: grid; gap: 24px; min-width: 0; }
.back-link { width: fit-content; font-size: .875rem; }
.jobs-card { padding: 0; overflow: hidden; border-top: 2px solid #617ea9; }
.jobs-card > .card-heading { padding: 22px 24px 0; margin-bottom: 20px; }
.jobs-description { margin-top: 5px; }
.jobs-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; padding: 0 24px 20px; }
.jobs-filters { display: flex; flex-wrap: wrap; gap: 4px; }
.jobs-filters button { padding: 6px 9px; background: transparent; border-color: transparent; font-size: .8125rem; color: var(--muted); }
.jobs-filters button[aria-pressed="true"] { background: #24354f; color: #c9ddff; border-color: #3c567e; }
.jobs-filters span { margin-left: 5px; opacity: .75; font-variant-numeric: tabular-nums; }
#jobs-search { width: 210px; flex: 1 1 185px; min-width: 140px; margin-left: auto; border: 1px solid var(--border); border-radius: 7px; background: #101824; padding: 9px 12px; color: var(--text); font: inherit; font-size: .875rem; }
#jobs-search:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.jobs-scroll { overflow-x: auto; }
.jobs-table { width: 100%; min-width: 1000px; border-collapse: collapse; table-layout: fixed; font-size: .875rem; }
.jobs-table th { text-align: left; color: var(--muted); font-weight: 500; padding: 11px 16px; background: #101824; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); font-size: .8125rem; }
.jobs-table th:nth-child(1) { width: 20%; }
.jobs-table th:nth-child(2) { width: 16%; }
.jobs-table th:nth-child(3) { width: 23%; }
.jobs-table th:nth-child(4) { width: 17%; }
.jobs-table th:nth-child(5) { width: 10%; }
.jobs-table th:nth-child(6) { width: 14%; }
.jobs-table td { padding: 18px 16px; vertical-align: top; border-bottom: 1px solid var(--border); overflow-wrap: anywhere; }
.jobs-table th:first-child, .jobs-table td:first-child { padding-left: 24px; }
.jobs-table th:last-child, .jobs-table td:last-child { padding-right: 24px; }
.jobs-table strong { font-weight: 550; }
.job-row { cursor: pointer; }
.job-row:hover { background: #1b283a; }
.job-row:focus-within { background: #1b283a; }
.running-row { background: #182335; }
.running-row td:first-child { box-shadow: inset 3px 0 #82aaff; }
.row-detail { display: block; margin-top: 6px; font-size: .8125rem; }
.time-cell { font-variant-numeric: tabular-nums; }
.job-open { color: #afcdff; font-weight: 500; }
.gitlab-job-link { white-space: nowrap; }
.project-versions { display: grid; gap: 2px; margin-top: 8px; font-size: .75rem; font-weight: 400; }
.version-cell .project-versions { margin-top: 0; }
.jobs-pagination, .jobs-pages { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.jobs-pagination button { min-width: 36px; padding: 8px 10px; }
.jobs-pagination button[aria-current="page"] { color: var(--accent); border-color: var(--accent); background: rgba(126, 167, 255, .12); }
.jobs-pagination button:disabled { cursor: default; }
.gitlab-job-link[aria-disabled="true"] { cursor: help; opacity: .65; }
.jobs-bottom { padding: 15px 24px; display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; font-size: .8125rem; }
.jobs-card > .notice { margin: 0 24px 16px; }
@media (min-width: 1101px) { .shell { max-width: 1720px; } .workspace { grid-template-columns: minmax(0, 1fr) 310px; } }
@media (max-width: 1100px) { .workspace { grid-template-columns: minmax(0, 1fr); } .side-column { grid-template-columns: repeat(2, minmax(0, 1fr)); } .jobs-card { padding: 0; } }
.storage-open { width: 100%; margin-top: 18px; }
.danger { color: var(--red); border-color: #72434c; background: #302027; }
.danger:hover { border-color: var(--red); }
.storage-dialog { width: min(920px, calc(100vw - 32px)); max-height: calc(100vh - 40px); margin: auto; border: 1px solid var(--border); border-radius: 12px; background: var(--surface); color: var(--text); padding: 0; }
.storage-dialog::backdrop { background: rgba(6, 10, 16, .72); }
.storage-header, .storage-footer { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; padding: 20px 24px; }
.storage-header { border-bottom: 1px solid var(--border); }
.storage-header h2 { margin-bottom: 4px; }
.storage-footer { border-top: 1px solid var(--border); align-items: center; flex-wrap: wrap; }
.storage-body { padding: 8px 24px 20px; overflow: auto; max-height: min(58vh, 640px); }
.storage-group { margin-top: 18px; }
.storage-group-heading { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; margin-bottom: 10px; flex-wrap: wrap; }
.storage-group-heading h3 { font-size: 1rem; }
.storage-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: .875rem; }
.storage-table th, .storage-table td { text-align: left; vertical-align: top; padding: 12px 10px; border-bottom: 1px solid var(--border); overflow-wrap: anywhere; }
.storage-table th { color: var(--muted); font-weight: 500; font-size: .8125rem; }
.storage-table th:nth-child(1), .storage-table td:nth-child(1) { width: 36px; padding-left: 0; padding-right: 4px; }
.storage-table th:nth-child(2), .storage-table td:nth-child(2) { width: 42%; }
.storage-table th:nth-child(3), .storage-table td:nth-child(3) { width: 6.5rem; white-space: nowrap; }
.storage-table th:nth-child(4), .storage-table td:nth-child(4) { width: 8rem; white-space: nowrap; }
.storage-table th:nth-child(5), .storage-table td:nth-child(5) { width: auto; }
.storage-busy td { color: var(--muted); }
.storage-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.storage-confirm { padding: 20px 24px 24px; border-top: 1px solid var(--border); }
.storage-confirm h3 { margin-bottom: 8px; font-size: 1.1rem; }
.storage-confirm ul { margin: 14px 0; padding-left: 18px; }
.storage-confirm li { margin: 8px 0; }
.storage-dialog .notice { margin: 16px 24px 0; }
@media (max-width: 720px) {
  .storage-header, .storage-footer, .storage-body, .storage-confirm { padding-left: 16px; padding-right: 16px; }
}
