/* Sign-in, account and administration pages. Navy and gold by default, like the standard MULK menu. */
:root{
  --navy:#0A1222;--navy-2:#1A2847;--gold:#B08A3E;--gold-ink:#1b1306;
  --bg:#F3F4F7;--surface:#FFFFFF;--sunk:#F6F7FA;--ink:#141A26;--muted:#5E6677;--line:#DDE1E8;
  --good:#1E8556;--good-soft:#DDF1E6;--warn:#A86E12;--warn-soft:#FBEFD6;--bad:#BE3B28;--bad-soft:#FBE3DE;
  --f:"Manrope",ui-sans-serif,system-ui,-apple-system,"Segoe UI",Roboto,Arial,sans-serif;--mono:"IBM Plex Mono",ui-monospace,Menlo,Consolas,monospace;
  color-scheme:light;
}
@media (prefers-color-scheme:dark){:root{
  --bg:#0B1019;--surface:#121A28;--sunk:#0F1622;--ink:#E5E9F0;--muted:#9AA4B5;--line:#253045;
  --good:#4CC58A;--good-soft:#123326;--warn:#E3A944;--warn-soft:#3A2B10;--bad:#F07A66;--bad-soft:#3E1A14;color-scheme:dark}}
*{box-sizing:border-box}
html,body{margin:0;min-height:100%}
body{background:var(--bg);color:var(--ink);font:14.5px/1.5 var(--f)}
a{color:var(--gold)}
h1{font-size:24px;line-height:1.2;margin:0;letter-spacing:-.01em}
h2{font-size:17px;margin:0}
button,input,select{font:inherit;color:inherit}
[hidden]{display:none!important}

/* brand */
.brand{display:flex;align-items:center;gap:12px;min-width:0}
.brand .logo{width:40px;height:40px;border-radius:10px;background:var(--gold);color:var(--navy);display:grid;place-items:center;font-weight:800;letter-spacing:.02em;flex:none;overflow:hidden}
.brand .logo img{width:100%;height:100%;object-fit:contain;background:#fff}
.brand b{display:block;font-size:15px;line-height:1.25;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.brand span{display:block;font-size:12px;opacity:.75}

/* the system's name with its crown on top (the crown is exactly as wide as the name), as at the top of MULK's menu */
:root{--crown-a:#D9BE84;--crown-b:#B08A3E;--crown-c:#8C6A2A}
@media (prefers-color-scheme:dark){:root{--crown-a:#E9D3A0;--crown-b:#D6B470;--crown-c:#9A814F}}
.sysbrand{display:flex;flex-direction:column;align-items:center;gap:5px;text-align:center}
.sysbrand .sysword{display:inline-flex;flex-direction:column;align-items:center;gap:7px;max-width:100%}
.sysbrand .crown{display:block;width:100%;max-width:120px;aspect-ratio:240/96;background:linear-gradient(135deg,var(--crown-a) 0%,var(--crown-b) 55%,var(--crown-c) 100%);-webkit-mask:url("data:image/svg+xml,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%20240%2096'%3E%3Cpath%20fill-rule%3D'evenodd'%20d%3D'M24%2076L12%2036Q40%2066%2065%2024Q92%2062%20120%2016Q148%2062%20175%2024Q200%2066%20228%2036L216%2076ZM23.5%2081H216.5A7.5%207.5%200%200%201%20216.5%2096H23.5A7.5%207.5%200%200%201%2023.5%2081ZM120%2082.5L126%2088.5L120%2094.5L114%2088.5Z'%2F%3E%3Ccircle%20cx%3D'10'%20cy%3D'30'%20r%3D'10'%2F%3E%3Ccircle%20cx%3D'65'%20cy%3D'17'%20r%3D'9.5'%2F%3E%3Ccircle%20cx%3D'120'%20cy%3D'10'%20r%3D'10'%2F%3E%3Ccircle%20cx%3D'175'%20cy%3D'17'%20r%3D'9.5'%2F%3E%3Ccircle%20cx%3D'230'%20cy%3D'30'%20r%3D'10'%2F%3E%3C%2Fsvg%3E") center/100% 100% no-repeat;mask:url("data:image/svg+xml,%3Csvg%20xmlns%3D'http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg'%20viewBox%3D'0%200%20240%2096'%3E%3Cpath%20fill-rule%3D'evenodd'%20d%3D'M24%2076L12%2036Q40%2066%2065%2024Q92%2062%20120%2016Q148%2062%20175%2024Q200%2066%20228%2036L216%2076ZM23.5%2081H216.5A7.5%207.5%200%200%201%20216.5%2096H23.5A7.5%207.5%200%200%201%2023.5%2081ZM120%2082.5L126%2088.5L120%2094.5L114%2088.5Z'%2F%3E%3Ccircle%20cx%3D'10'%20cy%3D'30'%20r%3D'10'%2F%3E%3Ccircle%20cx%3D'65'%20cy%3D'17'%20r%3D'9.5'%2F%3E%3Ccircle%20cx%3D'120'%20cy%3D'10'%20r%3D'10'%2F%3E%3Ccircle%20cx%3D'175'%20cy%3D'17'%20r%3D'9.5'%2F%3E%3Ccircle%20cx%3D'230'%20cy%3D'30'%20r%3D'10'%2F%3E%3C%2Fsvg%3E") center/100% 100% no-repeat}
.sysbrand .sysmark{width:42px;height:42px;border-radius:12px;display:grid;place-items:center;background:linear-gradient(135deg,var(--crown-a),var(--crown-b) 60%,var(--crown-c));color:#0A1222;font-weight:800;font-size:19px}
.sysbrand b{font-family:"Bodoni Moda","Didot","Bodoni 72",Georgia,serif;font-weight:600;font-size:30px;line-height:1.05;letter-spacing:.05em;margin-right:-.05em;overflow-wrap:anywhere}
.sysbrand b.long{font-size:22px;letter-spacing:.02em;margin-right:-.02em}
.sysbrand .syssub{font-size:11px;font-weight:600;letter-spacing:.14em;text-transform:uppercase;color:var(--muted)}

/* sign-in */
body.auth{min-height:100vh;display:grid;place-items:center;padding:24px 16px;background:radial-gradient(1200px 600px at 20% -10%,#1A2847 0%,transparent 60%),var(--navy)}
.auth-card{width:100%;max-width:400px;background:var(--surface);border-radius:16px;padding:28px;display:flex;flex-direction:column;gap:18px;box-shadow:0 20px 60px rgba(0,0,0,.35)}
.auth-card .sysbrand{padding-bottom:18px;border-bottom:1px solid var(--line)}
.auth-card .sysbrand[hidden] + .brand{padding-bottom:18px;border-bottom:1px solid var(--line)}
.fine{font-size:12.5px;color:var(--muted);margin:0}

/* forms */
form{display:flex;flex-direction:column;gap:14px}
label{display:flex;flex-direction:column;gap:6px;font-size:13px;font-weight:600}
input,select{border:1px solid var(--line);background:var(--surface);border-radius:9px;padding:10px 12px;font-weight:500;min-width:0;width:100%}
input:focus,select:focus{outline:2px solid var(--gold);outline-offset:1px;border-color:var(--gold)}
.btn{display:inline-flex;align-items:center;justify-content:center;gap:8px;border:1px solid var(--line);background:var(--surface);padding:9px 14px;border-radius:9px;font-weight:650;cursor:pointer;white-space:nowrap;text-decoration:none;color:var(--ink)}
.btn:hover{background:var(--sunk)}
.btn.pri{background:var(--navy-2);border-color:var(--navy-2);color:#fff}
.btn.pri:hover{background:#22345c}
.btn.danger{color:var(--bad);border-color:color-mix(in srgb,var(--bad) 40%,var(--line))}
.btn.sm{padding:5px 10px;font-size:13px;border-radius:8px}
.btn:disabled{opacity:.55;cursor:default}
.error{color:var(--bad);background:var(--bad-soft);border-radius:9px;padding:9px 12px;margin:0;font-size:13.5px}
.note{background:var(--warn-soft);color:var(--ink);border-radius:9px;padding:9px 12px;margin:0;font-size:13.5px}
.ok{background:var(--good-soft);color:var(--ink);border-radius:9px;padding:9px 12px;margin:0;font-size:13.5px}

/* account and administration */
.top{background:var(--navy);color:#fff;padding:12px 20px;display:flex;align-items:center;gap:16px;position:sticky;top:0;z-index:5}
.top .brand{flex:1}
.top .btn{background:transparent;color:#fff;border-color:rgba(255,255,255,.25)}
.top .btn:hover{background:rgba(255,255,255,.08)}
.wrap{max-width:1100px;margin:0 auto;padding:24px 20px 60px;display:flex;flex-direction:column;gap:20px}
.panel{background:var(--surface);border:1px solid var(--line);border-radius:12px;padding:20px;display:flex;flex-direction:column;gap:14px;min-width:0}
.panel > p{margin:0}
.muted{color:var(--muted)}
.row{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.grid2{display:grid;grid-template-columns:repeat(auto-fit,minmax(300px,1fr));gap:20px}
.kv{display:grid;grid-template-columns:max-content 1fr;gap:6px 18px;margin:0}
.kv dt{color:var(--muted)}
.kv dd{margin:0;font-weight:600;overflow-wrap:anywhere}
.pill{display:inline-block;font-size:12px;font-weight:700;padding:2px 9px;border-radius:99px;background:var(--sunk);border:1px solid var(--line)}
.pill.on{background:var(--good-soft);border-color:transparent;color:var(--good)}
.pill.off{background:var(--bad-soft);border-color:transparent;color:var(--bad)}
.tabs{display:flex;gap:4px;border-bottom:1px solid var(--line);overflow-x:auto}
.tabs button{border:0;background:none;padding:10px 14px;font-weight:650;color:var(--muted);border-bottom:2px solid transparent;cursor:pointer;white-space:nowrap}
.tabs button[aria-selected="true"]{color:var(--ink);border-bottom-color:var(--gold)}
.tbl{overflow-x:auto;border:1px solid var(--line);border-radius:10px}
table{border-collapse:collapse;width:100%;font-size:13.5px}
th,td{padding:9px 12px;border-bottom:1px solid var(--line);text-align:left;vertical-align:top}
th{font-size:12px;text-transform:uppercase;letter-spacing:.05em;color:var(--muted);background:var(--sunk);white-space:nowrap}
tr:last-child td{border-bottom:0}
td.n{text-align:right;font-family:var(--mono);font-variant-numeric:tabular-nums}
td code,.mono{font-family:var(--mono);font-size:12.5px}
td select{width:auto;padding:5px 8px}
.secret{font-family:var(--mono);font-size:15px;letter-spacing:.06em;background:var(--sunk);border:1px dashed var(--line);border-radius:9px;padding:10px 12px;overflow-wrap:anywhere;user-select:all}
.qr{width:200px;height:200px;background:#fff;border-radius:10px;padding:10px}
.qr svg{width:100%;height:100%;display:block}
.inline-form{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px;align-items:end}
@media (max-width:640px){.top{padding:10px 14px}.wrap{padding:16px 14px 48px}.top .brand span{display:none}.kv{grid-template-columns:1fr}}
/* the eye button in password boxes (Show / Hide what is typed) */
.pwbox{position:relative;display:block;min-width:0}
.pwbox>input{padding-right:46px}
.pwbox>input::-ms-reveal,.pwbox>input::-ms-clear{display:none}
.pweye{position:absolute;right:5px;top:50%;transform:translateY(-50%);width:36px;height:32px;display:grid;place-items:center;border:0;border-radius:8px;background:transparent;color:var(--muted);cursor:pointer;padding:0}
.pweye:hover{color:var(--ink);background:var(--sunk)}
.pweye:focus-visible{outline:2px solid var(--gold);outline-offset:1px}
.pweye[aria-pressed="true"]{color:var(--gold)}
.pweye svg{width:19px;height:19px;fill:none;stroke:currentColor;stroke-width:1.8;stroke-linecap:round;stroke-linejoin:round}
@media (pointer:coarse){.pweye{width:42px;height:40px;right:2px}.pwbox>input{padding-right:50px}}
