/* The control plane's own look: deliberately not the tenant app's.
   An operator should never be in doubt about which one they are in, least
   of all while suspending somebody. */

:root {
    --ink: #e8ebf4;
    --ink-2: #aab2c6;
    --ink-3: #7b8498;
    --ground: #0b0e16;
    --surface: #141924;
    --surface-2: #1a2030;
    --line: #242c3c;
    --line-strong: #36405a;
    --accent: #ffb020;          /* amber: this is the operator console */
    --accent-ink: #1a1203;
    --ok: #4dc392;
    --warn: #e3a942;
    --bad: #f0847b;
    --font: Inter, system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

body {
    margin: 0;
    background: var(--ground);
    color: var(--ink);
    font-family: var(--font);
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-weight: 650; letter-spacing: -.02em; margin: 0 0 .5rem; }
h1 { font-size: 1.5rem; }
h2 { font-size: 1.1rem; }
a { color: var(--accent); text-underline-offset: 2px; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .85em; color: var(--ink-2); }

/* --- chrome ----------------------------------------------------------- */
.topbar {
    display: flex; align-items: center; gap: 1.5rem;
    padding: .75rem 1.25rem;
    background: var(--surface);
    border-bottom: 2px solid var(--accent);
}
.brand { display: flex; align-items: center; gap: .5rem; color: var(--ink); text-decoration: none; font-weight: 650; }
.mark {
    display: grid; place-items: center; width: 42px; height: 26px;
    background: var(--accent); color: var(--accent-ink);
    border-radius: 5px; font-size: .72rem; font-weight: 800; letter-spacing: .02em;
}
.topbar nav { display: flex; gap: .25rem; }
.topbar nav a {
    padding: .35rem .7rem; border-radius: 6px;
    color: var(--ink-2); text-decoration: none; font-size: .92rem; font-weight: 500;
}
.topbar nav a:hover { background: var(--surface-2); color: var(--ink); }
.topbar nav a.on { background: var(--surface-2); color: var(--accent); }
.who { margin-left: auto; display: flex; align-items: center; gap: .75rem; font-size: .85rem; color: var(--ink-3); }
.who form { margin: 0; }
.who button {
    background: none; border: 1px solid var(--line-strong); color: var(--ink-2);
    border-radius: 6px; padding: .3rem .6rem; font: inherit; font-size: .85rem; cursor: pointer;
}
.who button:hover { color: var(--ink); border-color: var(--ink-3); }

main { max-width: 1100px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }
footer { padding: 1.5rem; text-align: center; color: var(--ink-3); font-size: .8rem; border-top: 1px solid var(--line); }

/* --- pieces ----------------------------------------------------------- */
.head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
        padding-bottom: 1rem; margin-bottom: 1.25rem; border-bottom: 1px solid var(--line); }
.head p { margin: 0; color: var(--ink-3); font-size: .9rem; }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 1.25rem; margin-bottom: 1rem; }
.panel h2 { padding-bottom: .6rem; margin-bottom: .9rem; border-bottom: 1px solid var(--line); }

.note { padding: .7rem 1rem; border-radius: 8px; border: 1px solid; margin-bottom: 1rem; font-size: .92rem; }
.note.ok { border-color: var(--ok); background: #0f2c23; }
.note.bad { border-color: var(--bad); background: #331819; }

.button {
    display: inline-flex; align-items: center; gap: .4rem; min-height: 36px; padding: .4rem .85rem;
    border: 1px solid var(--line-strong); border-radius: 8px;
    background: var(--surface-2); color: var(--ink);
    font: 550 .9rem var(--font); text-decoration: none; cursor: pointer;
}
.button:hover { border-color: var(--ink-3); }
.button.primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.button.danger { border-color: var(--bad); color: var(--bad); }
.button:disabled { opacity: .5; cursor: not-allowed; }

table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th { text-align: left; font-size: .7rem; text-transform: uppercase; letter-spacing: .07em; color: var(--ink-3); padding: .5rem .6rem; }
td { padding: .6rem; border-top: 1px solid var(--line); vertical-align: middle; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
tr:hover td { background: var(--surface-2); }

.chip {
    display: inline-flex; align-items: center; gap: .3rem; padding: .15rem .5rem;
    border-radius: 5px; font-size: .72rem; font-weight: 650; text-transform: capitalize;
    border: 1px solid var(--line-strong); background: var(--surface-2); color: var(--ink-2);
}
.chip.active { color: var(--ok); border-color: #1d4c3c; background: #0f2c23; }
.chip.provisioning, .chip.running, .chip.queued { color: var(--warn); border-color: #3c3113; background: #30250e; }
.chip.failed, .chip.deleting, .chip.deleted { color: var(--bad); border-color: #4a2524; background: #331819; }
.chip.suspended, .chip.draft { color: var(--ink-3); }

.field { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1rem; }
.field > span { font-size: .85rem; font-weight: 600; }
.field input, .field select {
    min-height: 40px; padding: .45rem .7rem; font: inherit; font-size: .94rem;
    background: var(--ground); color: var(--ink);
    border: 1px solid var(--line-strong); border-radius: 8px;
}
.field input:focus, .field select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px rgb(255 176 32 / .2); }
.field small { color: var(--ink-3); font-size: .8rem; }
.row { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }

.facts { display: grid; gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: 8px; overflow: hidden;
         grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); }
.facts div { background: var(--surface); padding: .75rem 1rem; }
.facts dt { font-size: .68rem; text-transform: uppercase; letter-spacing: .07em; color: var(--ink-3); font-weight: 600; }
.facts dd { margin: .15rem 0 0; font-size: 1.2rem; font-weight: 650; font-variant-numeric: tabular-nums; }

.steps { list-style: none; margin: 0; padding: 0; }
.steps li { display: flex; align-items: baseline; gap: .75rem; padding: .5rem 0; border-top: 1px solid var(--line); }
.steps li:first-child { border-top: 0; }
.steps .name { font-weight: 550; min-width: 190px; }
.steps .detail { color: var(--ink-3); font-size: .85rem; }

.narrow { max-width: 440px; margin: 3rem auto; }
.danger-zone { border-color: #4a2524; }
