.theme-toggle{display:inline-flex;align-items:center;gap:6px;white-space:nowrap;border:1px solid var(--line);border-radius:24px;background:linear-gradient(#fff,#e8f1ff);color:var(--ink);padding:9px 12px;font:inherit;font-size:12px;cursor:pointer}.header-inner{gap:14px}.registration-control{margin-bottom:20px}.autostart-control{border:1px solid var(--line);background:var(--bg);padding:18px;border-radius:18px;margin:20px 0}.autostart-label{display:block;margin-top:6px;color:var(--muted);font-size:11px}
.home-shell{padding-top:18px;padding-bottom:24px}.home-compact .hero{margin:0 0 12px;padding:24px 0 12px;gap:30px;grid-template-columns:1.5fr 1fr}.home-compact .hero h1{font-size:clamp(28px,3.5vw,44px);line-height:1.12;margin:12px 0}.home-compact .hero p{font-size:15px;margin:12px 0}.home-compact .hero-art{min-height:190px;height:210px;border-radius:28px}.home-compact .hero-art strong{font-size:27px}.home-compact .stats{margin:12px 0 18px;gap:14px}.home-compact .stat{padding:14px 20px}.home-compact .stat strong{font-size:25px}.home-compact .connection{padding:18px 24px;display:flex;align-items:center;justify-content:space-between;gap:20px}.home-compact .connection h2{font-size:18px;margin:4px 0}.home-compact .connection p{margin:4px 0;font-size:13px}.home-compact .connection code{font-size:15px;margin:0;white-space:nowrap}.home-compact .registration-note{margin:12px 0}.home-compact .eyebrow{font-size:10px}.home-compact .hero-art small{font-size:11px}
html[data-theme=dark]{color-scheme:dark;--ink:#e0ecff;--muted:#a8bedf;--navy:#d2e3ff;--accent:#76b5ff;--accent-dark:#a1ceff;--line:#294b78;--bg:#102642;--shadow:0 12px 30px #0003}
html[data-theme=dark] body{background:radial-gradient(ellipse at 0 0,#173c6a 0,transparent 45%),radial-gradient(ellipse at 100% 50%,#142f58 0,transparent 50%),#09172b;color:var(--ink)}
html[data-theme=dark] .site-header{background:#0d2039ef;border-color:#294b78}html[data-theme=dark] .brand{color:#e0edff}html[data-theme=dark] .brand small,html[data-theme=dark] .muted{color:#a8bedf}html[data-theme=dark] a{color:#8cc5ff}html[data-theme=dark] h1,html[data-theme=dark] h2,html[data-theme=dark] h3{color:#dceaff}
html[data-theme=dark] .card,html[data-theme=dark] .stat{background:linear-gradient(150deg,#193658,#10253f);border-color:#32557f;box-shadow:inset 0 1px #729ed222,var(--shadow)}
html[data-theme=dark] .button{color:#fff;background:linear-gradient(#528ff0,#285bce);border-color:#5e97ee;box-shadow:inset 0 1px #b8d7ff55,0 4px 15px #0003}html[data-theme=dark] .button.secondary,html[data-theme=dark] .theme-toggle{background:linear-gradient(#254971,#183553);color:#d7eaff;border-color:#41658c}html[data-theme=dark] .button.danger{background:linear-gradient(#97465e,#713047);border-color:#b15d78;color:#ffe6ee}
html[data-theme=dark] input,html[data-theme=dark] select,html[data-theme=dark] textarea{background:#0a1d35;color:#e0ecff;border-color:#365a86}html[data-theme=dark] input::placeholder{color:#9bb0cd}html[data-theme=dark] .main-nav>a:not(.button),html[data-theme=dark] .nav-button{color:#b9d0f1}html[data-theme=dark] .main-nav a[aria-current],html[data-theme=dark] .tabs a[aria-current]{background:linear-gradient(#2f6096,#1c3e69);color:#e4f1ff!important;border-color:#4677af}html[data-theme=dark] .main-nav a:hover,html[data-theme=dark] .nav-button:hover{background:#24446c}
html[data-theme=dark] .tabs{background:#122d4e}html[data-theme=dark] .portal-languages{background:#153352!important;border-color:#365a86!important}html[data-theme=dark] .portal-languages a[aria-current=true]{background:#245285!important;border-color:#76adf2!important;box-shadow:0 0 0 2px #345e8a!important}
html[data-theme=dark] .notice,html[data-theme=dark] .confirm-panel,html[data-theme=dark] .empty,html[data-theme=dark] .job-entry-output{background:#122e50;border-color:#36577f;color:#c9ddf8}html[data-theme=dark] .notice.error{background:#47263d;color:#ffcad9;border-color:#78435d}html[data-theme=dark] .badge{background:#244568;color:#d6e8ff}html[data-theme=dark] .badge.online,html[data-theme=dark] .badge.completed,html[data-theme=dark] .badge.approved{background:#123f4d;color:#a7e8e0}html[data-theme=dark] .badge.failed,html[data-theme=dark] .badge.offline,html[data-theme=dark] .badge.rejected{background:#472b44;color:#ffc1d7}html[data-theme=dark] .badge.pending,html[data-theme=dark] .badge.running{background:#4b3d20;color:#ffe4a4}
html[data-theme=dark] th,html[data-theme=dark] td,html[data-theme=dark] .job,html[data-theme=dark] .job-entry,html[data-theme=dark] details,html[data-theme=dark] .site-footer{border-color:#2b486c}html[data-theme=dark] th{background:#193b60;color:#d4e6ff}html[data-theme=dark] .job-entry-output pre,html[data-theme=dark] .job-entry-output summary{color:#bcd7fc}html[data-theme=dark] code{background:#0d2543;color:#b4d7ff}
html[data-theme=dark] .region-map{background:#102843;border-color:#35577e}html[data-theme=dark] .map-viewport{background:#091a30;border-color:#325071}html[data-theme=dark] .map-grid{stroke:#162e49}html[data-theme=dark] .map-grid.major{stroke:#274968}html[data-theme=dark] .map-axis{fill:#849ebd}html[data-theme=dark] .map-north{background:#183656dd;color:#bbd9ff}html[data-theme=dark] .map-help,html[data-theme=dark] .map-legend,html[data-theme=dark] .map-status{color:#a9c7ec}html[data-theme=dark] .map-tile.online rect{fill:#214e80;stroke:#6e9fdc}html[data-theme=dark] .map-tile.offline rect,html[data-theme=dark] .map-tile.occupied rect{fill:#203149;stroke:#627994}html[data-theme=dark] .map-tile.online text,html[data-theme=dark] .map-tile.offline text{fill:#d7e8ff}html[data-theme=dark] .map-tile.occupied text{fill:#a8b9cc}
@media(max-height:720px) and (min-width:721px){.home-compact .hero{padding-top:12px}.home-compact .hero h1{font-size:32px}.home-compact .hero-art{height:160px;min-height:160px}.home-compact .stats{margin:8px 0 12px}.home-compact .stat{padding:10px 18px}.home-compact .connection{padding:12px 20px}.site-header .header-inner{min-height:66px}.site-footer{padding-top:16px;padding-bottom:16px}}
@media(max-width:1000px){.header-inner{flex-wrap:wrap}.main-nav{flex-wrap:wrap}.theme-toggle{margin-left:auto}.home-compact .connection{flex-wrap:wrap}.home-compact .hero{grid-template-columns:1.5fr 1fr}.home-compact .hero-art strong{font-size:22px}}
@media(max-width:720px){.home-compact .hero{grid-template-columns:1fr;padding-top:16px}.home-compact .hero-art{display:none}.home-compact .stats{gap:8px}.home-compact .stat{padding:12px}.home-compact .connection code{font-size:12px;white-space:normal;overflow-wrap:anywhere}.theme-toggle span{display:none}.theme-toggle{font-size:18px;padding:6px 10px}}

html[data-theme=dark] .stat strong{color:#a4d2ff}html[data-theme=dark] .stat span{color:#b3c8e6}html[data-theme=dark] .eyebrow{color:#8cbeff}html[data-theme=dark] .permission-item:has(input:checked),html[data-theme=dark] .full-access{background:#183f5b}html[data-theme=dark] .feature-icon{background:#254d7c;color:#bddbff}html[data-theme=dark] .details dt{color:#aac2e4}
.online-count{display:block;margin-top:5px;font-size:12px;color:var(--muted)}.online-count b{color:var(--accent)}

.subnav{display:flex;gap:8px;flex-wrap:wrap;margin:18px 0}.subnav a{display:inline-flex;padding:9px 15px;border:1px solid var(--line);border-radius:20px;color:var(--muted);font-size:13px}.subnav a[aria-current]{background:var(--accent);color:#fff;border-color:var(--accent)}.context-jobs{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin:18px 0}.context-jobs small{color:var(--muted)}.job-button{display:inline-flex;align-items:center;gap:8px}.job-button b{min-width:24px;text-align:center;border-radius:20px;background:#ffffff33;padding:2px 6px}.job-clock{display:inline-block;font-size:20px;line-height:1}.busy .job-clock,.job-clock.running{animation:job-clock-spin 2s linear infinite}.button.job-button.has-errors,html[data-theme=dark] .button.job-button.has-errors{background:linear-gradient(#be4f70,#952a4b);color:#fff;border-color:#d47791}.pagination{display:flex;gap:14px;align-items:center;justify-content:center;margin:20px 0}.pagination span{color:var(--muted);font-size:13px}@keyframes job-clock-spin{to{transform:rotate(360deg)}}@media(prefers-reduced-motion:reduce){.busy .job-clock,.job-clock.running{animation:none}}
html[data-theme=dark] input:not([type=checkbox]):not([type=radio]){background:#0a1d35;color:#e0ecff;border-color:#365a86}html[data-theme=dark] tbody tr:hover{background:#1b3a5e}html[data-theme=dark] .region-owner>div{background:#193a5f;border-color:#35577f}html[data-theme=dark] .region-card summary{color:#b9d9ff}html[data-theme=dark] .table-wrap{border-color:#35577f}html[data-theme=dark] .subnav a[aria-current]{background:#255aa4;color:#fff}
.map-status{white-space:pre-line;line-height:1.7;padding:12px 15px;background:var(--bg);border-block:1px solid var(--line);font-size:13px}.map-status.invalid{border-color:#ba5972}

/* Only the newest contextual job controls the button; terminal colours fade after 20s. */
.button.secondary.job-button,html[data-theme=dark] .button.secondary.job-button{background-color:#2866c9;background-image:linear-gradient(#ffffff22,#ffffff00);color:#fff;border-color:#75a8ef;transition:background-color 1s ease,border-color 1s ease;box-shadow:inset 0 1px 0 #ffffff44,0 3px 10px #153c7126}
.button.secondary.job-button.busy,html[data-theme=dark] .button.secondary.job-button.busy{background-color:#a65a09;border-color:#f4b660}
.button.secondary.job-button.failed,html[data-theme=dark] .button.secondary.job-button.failed{background-color:#a42e4e;border-color:#df8da4}
.button.secondary.job-button.succeeded,html[data-theme=dark] .button.secondary.job-button.succeeded{background-color:#187440;border-color:#73c79b}
@media(prefers-reduced-motion:reduce){.button.secondary.job-button{transition:none}}

.site-header{position:sticky;top:0;z-index:1000;box-shadow:0 4px 20px #153c7118}
html{scroll-padding-top:120px}#main{overflow-anchor:none}.prim-usage{font-variant-numeric:tabular-nums;white-space:nowrap}.region-prims{font-weight:600}.prim-usage+small{display:block;font-weight:400}
.cache-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:18px}.cache-card h3{margin-top:0}.cache-card .cache-size{font-size:25px;font-weight:700;color:var(--accent)}.cache-card form{margin-top:15px}.cache-card small{display:block}.cache-protected{border-left:4px solid var(--accent)}

.admin-shell{max-width:1520px}.admin-layout{display:grid;grid-template-columns:220px minmax(0,1fr);gap:26px;align-items:start}.admin-content{min-width:0}.admin-sidebar{position:sticky;top:calc(var(--portal-header-height,100px) + 18px);max-height:calc(100vh - var(--portal-header-height,100px) - 36px);overflow:auto;scrollbar-width:thin;border-radius:22px}.admin-sidebar .tabs{display:flex;flex-direction:column;gap:5px;margin:0;padding:12px;border:1px solid var(--line);border-radius:22px}.admin-sidebar .tabs a{display:block;width:100%;padding:11px 14px;white-space:normal;border-radius:14px;line-height:1.4;text-decoration:none}.admin-sidebar .tabs a[aria-current]{font-weight:700}.admin-menu>summary{display:none}.admin-content>.context-jobs:first-child{margin-top:0}.admin-content>.subnav:first-child{margin-top:0}
@media(max-width:860px){.admin-layout{grid-template-columns:minmax(0,1fr);gap:18px}.admin-sidebar{position:static;max-height:none;overflow:visible}.admin-menu{border:1px solid var(--line);border-radius:18px;background:var(--paper)}.admin-menu>summary{display:list-item;cursor:pointer;padding:12px 18px;font-weight:650;color:var(--ink)}.admin-sidebar .tabs{border:0;background:transparent;border-radius:0 0 18px 18px}.admin-menu:not([open])>nav{display:none}}
html[data-theme=dark] .admin-menu{background:#122d4e}

/* Amosch server overview: equal card widths and heights. */
.admin-overview-grid{grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}
.admin-overview-grid>.card{min-width:0;height:100%;box-sizing:border-box;margin:0}
.server-metrics{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px 18px;margin:0 0 16px}
.server-metrics div{min-width:0}.server-metrics dt{font-size:.82rem;color:var(--muted)}
.server-metrics dd{margin:3px 0 0;font-weight:600;overflow-wrap:anywhere}
.server-services{display:flex;flex-wrap:wrap;gap:7px}.server-services .badge{font-size:.75rem}
.server-status .status-stamp{display:block;margin-top:12px}
@media(max-width:860px){.admin-overview-grid{grid-template-columns:minmax(0,1fr);grid-auto-rows:1fr}}
@media(max-width:440px){.server-metrics{gap:10px 12px}.server-services .badge{white-space:normal}}
