:root {
  color-scheme: dark;
  --bg: #101217;
  --sidebar: #13161d;
  --panel: #191d25;
  --field: #11151c;
  --line: #2d3440;
  --text: #f0f3f7;
  --muted: #a7b0bf;
  --mint: #79e9c2;
  --purple: #b6a0fb;
  --red: #ff9aa5;
  font-family: "Inter", system-ui, sans-serif;
  font-size: 14px;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 310px; background: var(--bg); color: var(--text); }
[hidden] { display: none !important; }
a { color: var(--mint); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: .6; cursor: wait; }
button, a, input, select, summary { outline-offset: 4px; }
:focus-visible { outline: 2px solid var(--mint); }
h1, h2, h3, p { margin: 0; }
h1 { font-size: clamp(1.85rem, 3.5vw, 2.7rem); letter-spacing: -.055em; }
h2 { font-size: 1.12rem; letter-spacing: -.025em; }
h3 { font-size: 1rem; }
code, .mono, .metric strong, .chart-total { font-family: "IBM Plex Mono", Consolas, monospace; }
.muted, .empty { color: var(--muted); line-height: 1.55; }
.empty { padding: 1.1rem 0; }
.sidebar { width: 235px; background: var(--sidebar); border-right: 1px solid var(--line); position: fixed; inset: 0 auto 0 0; padding: 26px 18px; display: flex; flex-direction: column; gap: 43px; }
.brand { color: var(--text); display: inline-flex; align-items: center; gap: 11px; font-size: 1.18rem; letter-spacing: -.035em; white-space: nowrap; }
.brand:hover { text-decoration: none; }
.mark { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--mint); color: #132a23; font-weight: 850; }
.sidebar nav, .sidebar-end { display: grid; gap: 7px; }
.sidebar nav a, .text-button { display: flex; align-items: center; gap: 10px; border: 1px solid transparent; padding: 10px 11px; border-radius: 8px; background: transparent; text-align: left; color: var(--muted); font-weight: 600; }
.sidebar nav a:hover, .text-button:hover { text-decoration: none; color: var(--text); background: #222832; }
.sidebar nav a[aria-current="page"] { background: #1d302d; border-color: #34524b; color: var(--mint); }
.sidebar nav span { width: 17px; font-size: 1.16rem; }
.sidebar-end { margin-top: auto; }
.workspace { margin-left: 235px; max-width: 1650px; padding: 34px clamp(22px, 3.5vw, 64px) 55px; }
.top { display: flex; justify-content: space-between; gap: 16px; align-items: end; margin-bottom: 28px; }
.eyebrow { font-size: .71rem; color: var(--muted); letter-spacing: .15em; font-weight: 750; margin-bottom: 7px; }
.top-actions, .filters, .row-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
#device-detail .row-actions { margin-top: 14px; }
.primary, .secondary, .danger { border: 1px solid transparent; border-radius: 8px; font-weight: 750; padding: 10px 14px; }
.primary { background: var(--mint); color: #0d2921; }
.primary:hover { background: #a0f4da; }
.secondary { background: #222832; border-color: var(--line); color: var(--text); }
.secondary:hover { background: #303845; }
.danger { color: #ffd0d5; background: #51262f; border-color: #7d4651; }
.danger:hover { background: #63303b; }
.badge, .chip { display: inline-flex; align-items: center; white-space: nowrap; border: 1px solid var(--line); border-radius: 999px; padding: 4px 9px; color: var(--muted); font-size: .78rem; }
.badge.good { color: var(--mint); background: #1d302a; border-color: #37554a; }
.badge.warn { color: #ffd6a2; background: #392d24; border-color: #5f4938; }
.badge.blocked { color: var(--purple); background: #2d2741; border-color: #4b3e69; }
.page { display: grid; gap: 16px; }
.metrics { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.card, .metric { border-radius: 13px; background: var(--panel); border: 1px solid var(--line); }
.metric { padding: 16px; min-width: 0; }
.metric p { color: var(--muted); font-size: .83rem; }
.metric strong { display: block; font-size: clamp(1.2rem, 2vw, 1.8rem); letter-spacing: -.055em; margin: 8px 0 6px; overflow-wrap: anywhere; }
.metric small { color: var(--muted); line-height: 1.4; }
.metric:first-child strong { color: var(--mint); }
.card { padding: 19px 21px; min-width: 0; }
.card-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-bottom: 15px; }
.card-head p { margin-top: 4px; }
.card-head a { font-size: .83rem; }
.columns { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.details { display: grid; grid-template-columns: minmax(100px, 1fr) 1.45fr; margin: 0; }
.details dt, .details dd { padding: 9px 0; border-bottom: 1px solid #282e39; margin: 0; overflow-wrap: anywhere; }
.details dt { color: var(--muted); padding-right: 8px; }
.details dd { text-align: right; }
.chart-total { font-size: 1.25rem; margin: 3px 0; color: var(--mint); }
canvas { display: block; width: 100%; height: 226px; }
.dot { display: inline-block; width: .55rem; height: .55rem; border-radius: 50%; margin-right: .25rem; }
.dot.mint { background: var(--mint); }
.dot.purple { background: var(--purple); margin-left: .6rem; }
.scroll { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th, td { border-bottom: 1px solid var(--line); padding: 12px 8px; }
th { color: var(--muted); font-size: .8rem; font-weight: 650; white-space: nowrap; }
td { overflow-wrap: anywhere; }
td small { display: block; margin-top: 3px; color: var(--muted); }
td .secondary { font-size: .82rem; padding: 6px 9px; }
tr:last-child td { border-bottom: 0; }
.event { display: grid; grid-template-columns: 1.2fr 1.2fr auto; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); align-items: center; }
.event:last-child { border-bottom: 0; }
.event time { color: var(--muted); font-size: .8rem; text-align: right; }
.help p { color: var(--muted); line-height: 1.7; margin-top: 7px; max-width: 72ch; }
.help code { color: var(--mint); }
.help pre { white-space: pre-wrap; overflow-wrap: anywhere; padding: 10px; background: var(--field); border: 1px solid var(--line); border-radius: 7px; }
#laptop-link-label { margin-top: 14px; }
#laptop .scroll { margin-top: 17px; }
label { display: grid; gap: 6px; font-size: .9rem; font-weight: 650; }
input, select { background: var(--field); color: var(--text); border: 1px solid #3b4553; border-radius: 7px; padding: 9px 10px; min-width: 0; }
input::placeholder { color: #8d98a9; }
label small { color: var(--muted); font-weight: 400; }
dialog { max-height: calc(100dvh - 20px); width: min(480px, calc(100% - 26px)); border: 1px solid #435061; border-radius: 14px; background: var(--panel); padding: 21px; color: var(--text); }
dialog::backdrop { background: #080a10c9; backdrop-filter: blur(3px); }
dialog .card-head { margin-bottom: 0; }
.close { border-radius: 7px; border: 1px solid var(--line); background: transparent; color: var(--muted); font-size: 1.2rem; }
.form { display: grid; gap: 15px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
#guest-options { display: grid; gap: 13px; }
summary { cursor: pointer; color: var(--mint); }
details label { margin-top: 9px; }
.error { color: var(--red); }
.notice { background: #243330; color: var(--mint); border: 1px solid #39524a; border-radius: 8px; padding: 10px 13px; margin-bottom: 14px; }
.notice.error { color: var(--red); background: #35232c; border-color: #593d48; }
#qr-code { margin: auto; border: 8px solid #fff; border-radius: 8px; background: #fff; object-fit: contain; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); }
.login-page { min-height: 100dvh; display: grid; place-items: center; padding: 18px; }
.login-shell { width: min(100%, 870px); display: grid; grid-template-columns: 1.06fr 1fr; border: 1px solid var(--line); border-radius: 18px; overflow: hidden; background: var(--panel); }
.login-art { display: grid; place-items: center; position: relative; overflow: hidden; min-height: 460px; isolation: isolate; background: radial-gradient(ellipse at center, #244237, #141e24 60%, #151821 90%); }
.orbit { position: absolute; inset: auto; width: 155px; height: 155px; border: 1px solid #649e8580; border-radius: 50%; }
.ring-two { width: 245px; height: 245px; border-color: #649e8550; }
.ring-three { width: 330px; height: 330px; border-color: #a98be048; }
.art-center { display: grid; place-items: center; width: 100px; height: 100px; border: 1px solid #70ba9b; background: #253e36; border-radius: 28px; transform: rotate(-10deg); box-shadow: 0 13px 42px #0d1514; }
.mark.large { width: 67px; height: 67px; border-radius: 17px; font-size: 2.55rem; transform: rotate(10deg); }
.art-node { position: absolute; top: 50%; left: 50%; width: 11px; height: 11px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 14px #79e9c280; }
.node-one { transform: translate(112px, -54px); }
.node-two { transform: translate(-126px, 26px); background: var(--purple); }
.node-three { transform: translate(27px, 154px); width: 8px; height: 8px; }
.login-panel { padding: clamp(25px, 5vw, 54px); display: grid; align-content: center; gap: 22px; }
.login-panel h1 { font-size: clamp(1.58rem, 3vw, 2.23rem); }
.login-panel .primary { display: flex; justify-content: space-between; }
@media (max-width: 1020px) {
  .sidebar { width: 192px; }
  .workspace { margin-left: 192px; }
  .metrics { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .columns { grid-template-columns: 1fr; }
}
@media (max-width: 680px) {
  .sidebar { position: static; width: auto; gap: 13px; padding: 13px 14px; border-right: 0; border-bottom: 1px solid var(--line); }
  .sidebar nav { display: flex; overflow-x: auto; }
  .sidebar nav a { white-space: nowrap; font-size: .82rem; padding: 7px; gap: 3px; }
  .sidebar-end { display: flex; gap: 5px; }
  .text-button { padding: 4px 7px; font-size: .8rem; }
  .workspace { margin-left: 0; padding: 19px 12px 40px; }
  .top { align-items: start; flex-direction: column; margin-bottom: 15px; }
  .card { padding: 13px; }
  .metric { padding: 12px; }
  .login-shell { grid-template-columns: 1fr; }
  .login-art { min-height: 165px; }
  .art-center { scale: .72; }
}
