/* Super-admin · the design copied from Genomain OS (OS/layer/face/genomain_face/static/face.css): glass + 1 px hairline, two text levels,
   one accent, the white pill = primary, hairline icons, large radii, generous space. The colours follow the sun (day · dusk · night,
   docs/DAG-OCH-NATT.md): every one is a token from tema.css (tools/tema.py), or a tint of one (color-mix … N %, transparent). Only the
   night sky (body) and the stars stay literal here: dusk and day are layers above them. Phone 390 and desktop 1280. */
:root {
  /* the colours (--bg, --fg, --mut, --dim, --acc, --line, --glass, --shadow …) live in tema.css, one set per phase (tools/tema.py) */
  --blur: blur(30px) saturate(1.3);
  --r: 20px; --r-s: 14px; --font: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Helvetica Neue", Inter, system-ui, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1); --fast: 150ms; --slow: 400ms;
}
@keyframes rise { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@keyframes tw { 0%, 100% { opacity: .15; } 50% { opacity: .9; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---- the sky ---------------------------------------------------------------------------------------------------- */
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body { font: 400 15px/1.5 var(--font); color: var(--fg); min-height: 100vh; -webkit-font-smoothing: antialiased; background: #07080f radial-gradient(900px 600px at 50% 110%, #1a1f4a 0%, #0b0d1f 55%, #07080f 100%) fixed; }
body::before { content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 0; background: radial-gradient(600px 400px at 85% 0%, rgba(122, 59, 156, .22), transparent 70%), radial-gradient(500px 300px at 90% 100%, rgba(59, 176, 200, .12), transparent 70%); }
.stars { position: fixed; inset: 0; pointer-events: none; z-index: 0; overflow: hidden; }
.stars i { position: absolute; width: 2px; height: 2px; border-radius: 50%; background: #fff; opacity: .4; } .stars i.tw { animation: tw 4s ease-in-out infinite; }
a { color: var(--acc); text-decoration: none; }
h1 { font-size: clamp(26px, 22px + 1vw, 34px); font-weight: 600; letter-spacing: -.02em; line-height: 1.15; margin: 4px 0 18px; }
p { margin: 6px 0; } .muted { color: var(--mut); } .small, p.small { font-size: 13px; margin: 12px 0 0; color: var(--dim); } .empty { margin: 4px 0; }
.kicker { font: 500 11px/1.2 var(--font); letter-spacing: .12em; text-transform: uppercase; color: var(--mut); margin: 0 0 8px; display: flex; align-items: center; gap: 8px; }
.kicker.warn { color: var(--warn); } .kicker.warn .dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--warn); }
.kicker.senast { margin-top: 22px; }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: 13px; }
pre.code { white-space: pre-wrap; word-break: break-all; font: 13px/1.6 ui-monospace, "SF Mono", Menlo, Consolas, monospace; background: var(--glass-3); border: 1px solid var(--line); border-radius: var(--r-s); padding: 12px 14px; margin: 8px 0 12px; }
.ic { width: 20px; height: 20px; color: inherit; flex: none; }

/* ---- the frame (docs/SUPER.md 2026-10-17): top line; the rail with the WORD under every icon — five places on top, two quiet ones at
   the bottom; on the phone the five sit in a bar at the bottom and "Mer" opens a labelled sheet ------------------------------------ */
[hidden] { display: none !important; }
.top { position: fixed; top: 0; left: 0; right: 0; height: 56px; z-index: 20; display: flex; align-items: center; justify-content: space-between; padding: 0 30px 0 26px; font-size: 13.5px; color: var(--mut); }
.top .brand { display: flex; align-items: center; gap: 10px; color: var(--mut); } .top .right { display: flex; align-items: center; gap: 8px; } .top .who { color: var(--mut); } .top .who:hover { color: var(--fg); }
.rail { position: fixed; left: 14px; top: 76px; bottom: 22px; z-index: 20; display: flex; flex-direction: column; justify-content: space-between; width: 88px; }
.rail .places, .rail .quiet { display: flex; flex-direction: column; gap: 10px; }
.rail a { display: flex; flex-direction: column; align-items: center; gap: 6px; color: var(--mut); width: 88px; padding: 9px 0 8px; border-radius: 16px; transition: background var(--fast), color var(--fast); }
.rail a .ic { stroke-width: 1.3; } .rail .w { font-size: 11.5px; letter-spacing: .01em; line-height: 1.15; text-align: center; } .rail .sh { display: none; }
.rail a:hover { color: var(--fg); background: var(--glass-3); } .rail a.on { color: var(--fg); background: color-mix(in srgb, var(--wash) 9%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.rail .quiet a { color: var(--dim); padding: 7px 0 6px; } .rail .quiet a .ic { width: 17px; height: 17px; } .rail .quiet .w { font-size: 10.5px; } .rail .quiet a.on { color: var(--fg); }
.rail .ico { position: relative; display: inline-flex; }
.rail .badge { position: absolute; top: -7px; right: -12px; min-width: 18px; height: 18px; padding: 0 5px; border-radius: 999px; background: var(--warn); color: var(--ink); font: 700 11px/18px var(--font); font-style: normal; text-align: center; }
.rail .more { display: none; }

/* ---- layout ------------------------------------------------------------------------------------------------------ */
main { position: relative; z-index: 1; padding: 80px 48px 70px 128px; animation: rise var(--slow) var(--ease) both; }
.page { max-width: 1140px; }
.card { background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); box-shadow: var(--shadow); border-radius: var(--r); padding: 18px 22px; min-width: 0; }
.card + .card, .two + .card, .card + .two, .tiles + .two, .tiles + .card, .status + .two, .status + .card, .toolbar + .card { margin-top: 14px; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; align-items: start; }
.card.stub { border-style: dashed; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; } .tiles.small { grid-template-columns: repeat(2, 1fr); gap: 8px; }
.tile { display: grid; gap: 2px; padding: 18px 20px; border-radius: 18px; background: var(--glass); backdrop-filter: var(--blur); -webkit-backdrop-filter: var(--blur); border: 1px solid var(--line); box-shadow: var(--shadow); }
.tile b { font-size: 30px; font-weight: 600; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; } .tile span { color: var(--mut); font-size: 13px; } .tile .note { color: var(--dim); font-size: 12px; }
.tile.warn b { color: var(--warn); } .tile.ok b { color: var(--acc); } .tile.bad b { color: var(--danger); } .tile.stub { border-style: dashed; box-shadow: none; }
.tiles.four { grid-template-columns: repeat(4, 1fr); }
/* ---- Drift (docs/LARM.md, design 24): the alarm card, the dots, a health row per computer -------------------------- */
.card.alarm { border-color: color-mix(in srgb, var(--danger) 50%, transparent); background: color-mix(in srgb, var(--danger) 6%, transparent); } .card.alarm.calm { border-color: var(--line); background: var(--glass-3); }
.alarm-head { display: flex; gap: 18px; align-items: center; } .alarm-n { font-size: 44px; font-weight: 600; color: var(--danger); letter-spacing: -.03em; line-height: 1; font-variant-numeric: tabular-nums; min-width: 40px; }
.alarm.calm .alarm-n { color: var(--mut); } .alarm-title { font-size: 20px; font-weight: 600; letter-spacing: -.01em; } .alarm-head p { margin: 2px 0 0; font-size: 14px; }
.alarm-list { list-style: none; margin: 14px 0 0; padding: 0; } .alarm-list li { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-2); font-size: 14px; }
.alarm-list .name { font-weight: 600; } .alarm-list .name small { color: var(--mut); font-weight: 400; margin-left: 8px; } .alarm-list .what { color: var(--mut); flex: 1; } .alarm-list li.quiet-alarm { opacity: .6; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; flex: none; background: var(--dim); }
.dot.up { background: var(--acc); box-shadow: 0 0 10px var(--acc-wash); } .dot.quiet { background: var(--warn); box-shadow: 0 0 10px color-mix(in srgb, var(--warn) 35%, transparent); } .dot.down { background: var(--danger); box-shadow: 0 0 12px color-mix(in srgb, var(--danger) 50%, transparent); }
.health { list-style: none; margin: 4px 0 0; padding: 0; } .hrow { display: grid; grid-template-columns: 10px minmax(140px, 1.2fr) 110px 135px 165px minmax(0, 1.5fr) 200px 64px; gap: 14px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; }
.hrow.has-act { grid-template-columns: 10px minmax(140px, 1.2fr) 110px 135px 165px minmax(0, 1.5fr) 200px 64px; } .hrow .pill { margin: -6px 0; }
.alarm .btns { margin-top: 14px; } .hrow:last-child { border-bottom: 0; } .hname { font-weight: 600; min-width: 0; } .hname small { display: block; color: var(--mut); font-weight: 400; font-size: 12.5px; }
.hcell { color: var(--mut); font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .hcell.open { white-space: normal; line-height: 1.35; }
.hstate { white-space: nowrap; text-align: right; font-weight: 500; overflow: hidden; text-overflow: ellipsis; } .hstate.up { color: var(--acc); } .hstate.quiet { color: var(--warn); } .hstate.down { color: var(--danger); } .hstate.dim { color: var(--dim); }
.tiles.small .tile { padding: 12px 14px; box-shadow: none; background: var(--glass-3); } .tiles.small .tile b { font-size: 20px; }
.status { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 16px 22px; border-radius: var(--r); border: 1px solid var(--acc-line); background: var(--glass-3); margin-bottom: 14px; }
.status .big { font-size: 24px; font-weight: 600; letter-spacing: -.02em; } .status.look { border-color: color-mix(in srgb, var(--warn) 50%, transparent); } .status .kicker { margin-bottom: 2px; }
.btns { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.say { margin: 0 0 14px; padding: 10px 16px; border-radius: var(--r-s); border: 1px solid var(--acc-line); background: var(--acc-wash); font-size: 14px; } .say.bad { color: var(--danger); background: color-mix(in srgb, var(--danger) 10%, transparent); border-color: color-mix(in srgb, var(--danger) 35%, transparent); }
.foot { margin-top: 26px; }

/* ---- the pieces: tags, tables, facts, meters, months, the log, the once-box ------------------------------------ */
.tag { display: inline-block; padding: 2px 10px; border-radius: 999px; font-size: 12px; font-weight: 600; border: 1px solid var(--line); color: var(--mut); vertical-align: middle; white-space: nowrap; }
.tag.ok { color: var(--acc); border-color: var(--acc-line); } .tag.warn { color: var(--warn); border-color: color-mix(in srgb, var(--warn) 50%, transparent); } .tag.bad { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); } .tag.acc { color: var(--fg); border-color: var(--line); background: var(--glass); }
.tbl { overflow-x: auto; margin: 0 -6px; } table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; color: var(--mut); font: 500 11px/1.2 var(--font); letter-spacing: .12em; text-transform: uppercase; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
td { padding: 11px 10px; border-bottom: 1px solid var(--line-2); vertical-align: middle; font-variant-numeric: tabular-nums; white-space: nowrap; } tr:last-child td { border-bottom: 0; } td .pill { margin: -6px 0; }
.row-link { color: var(--fg); font-weight: 500; } tr:hover td { background: var(--glass-3); }
.facts { display: grid; grid-template-columns: auto 1fr; gap: 9px 18px; margin: 6px 0; font-size: 14.5px; } .facts dt { color: var(--mut); } .facts dd { margin: 0; text-align: right; font-weight: 500; overflow-wrap: anywhere; }
.meter { margin: 10px 0 0; } .meter-head { display: flex; justify-content: space-between; font-size: 13.5px; } .bar { height: 7px; border-radius: 999px; background: var(--track); margin-top: 6px; overflow: hidden; } .bar span { display: block; height: 100%; background: var(--acc-2); border-radius: 999px; }
.months { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 8px; align-items: end; height: 150px; }
.month { display: grid; grid-template-rows: 1fr auto auto; justify-items: center; gap: 4px; height: 100%; font-size: 12px; } .month .col { display: flex; align-items: flex-end; width: 100%; max-width: 36px; height: 100%; }
.month .col span { display: block; width: 100%; border-radius: 8px 8px 3px 3px; background: linear-gradient(180deg, #6f93ff, #2e4fcf); } .month small { color: var(--mut); } .month b { font-weight: 500; font-size: 11px; color: var(--dim); white-space: nowrap; }
.log { list-style: none; margin: 4px 0 0; padding: 0; } .log li { display: flex; gap: 14px; padding: 8px 0; border-bottom: 1px solid var(--line-2); font-size: 14px; } .log li:last-child { border: 0; } .log li span { color: var(--dim); font-variant-numeric: tabular-nums; min-width: 86px; }
.spark { display: flex; align-items: flex-end; gap: 3px; height: 54px; } .spark span { flex: 1; border-radius: 3px 3px 1px 1px; background: var(--acc-2); min-width: 3px; }
.once { margin-top: 12px; padding: 14px 16px; border: 1px solid color-mix(in srgb, var(--warn) 50%, transparent); border-radius: var(--r-s); background: var(--glass-3); }
.big-version { font-size: 30px; font-weight: 600; letter-spacing: -.02em; line-height: 1.1; margin: 2px 0 10px; font-variant-numeric: tabular-nums; }
.channel .tiles.small { grid-template-columns: repeat(4, 1fr); margin: 12px 0; } .channel .btns { margin: 4px 0 8px; } .channel .log { margin-top: 10px; }
input[type=file] { padding: 9px 12px; height: auto; min-height: 42px; }
.row-line { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 12px 0 0; font-size: 14px; } .row-line.wrap { flex-wrap: wrap; }

/* ---- forms and buttons ------------------------------------------------------------------------------------------ */
label { display: block; margin: 12px 0 0; font-size: 12.5px; color: var(--mut); }
input, select { width: 100%; margin-top: 4px; height: 42px; padding: 0 14px; border-radius: var(--r-s); border: 1px solid var(--line); background: var(--field); color: var(--fg); font: inherit; }
input::placeholder { color: var(--dim); } input:hover, select:hover { border-color: var(--field-hover); }
input:focus, select:focus { outline: none; border-color: var(--acc-line); box-shadow: 0 0 0 3px var(--acc-wash); }
select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--mut) 50%), linear-gradient(135deg, var(--mut) 50%, transparent 50%); background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 32px; }
select option { background: var(--bg-2); color: var(--fg); }
.pill { height: 36px; padding: 0 16px; border-radius: 999px; display: inline-flex; align-items: center; gap: 8px; font: 600 13px/1 var(--font); border: 1px solid var(--line); color: var(--fg); background: var(--fill); cursor: pointer; white-space: nowrap; transition: transform var(--fast) var(--ease); }
.pill:hover { background: var(--fill-2); transform: translateY(-1px); } .pill.p { background: var(--fg); color: var(--ink); border-color: var(--fg); } .pill.p:hover { background: var(--primary-hover); }
.pill.quiet { background: transparent; color: var(--mut); } .pill.quiet:hover { color: var(--fg); background: var(--glass-3); } .pill.danger { color: var(--danger); border-color: color-mix(in srgb, var(--danger) 40%, transparent); }
.pill.ask { background: var(--warn); color: var(--ink); border-color: var(--warn); } .pill:disabled { opacity: .5; cursor: default; transform: none; }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 3px; gap: 2px; background: var(--glass-3); max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.seg a { padding: 7px 14px; border-radius: 999px; color: var(--mut); font-size: 13.5px; white-space: nowrap; } .seg a.on { background: var(--fg); color: var(--ink); font-weight: 600; } .seg a small { opacity: .7; font-size: 12px; }
.toolbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 0 0 14px; }
.search { flex: 1; max-width: 360px; } .search input { height: 38px; margin: 0; }
.inline-form { display: flex; gap: 10px; align-items: center; margin-top: 10px; } .inline-form input, .inline-form select { margin: 0; height: 38px; max-width: 220px; }
.stack label:first-child { margin-top: 0; } .stack .btns { margin-top: 16px; }
.lead { margin-top: 14px; } .lead-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; } .lead-head b { font-size: 17px; } .lead-head p { margin: 2px 0 0; font-size: 13px; }
.lead-text { margin: 10px 0; padding: 10px 14px; border-left: 2px solid var(--acc-line); color: var(--mut); font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.lead-form { display: grid; grid-template-columns: 160px 1fr auto; gap: 10px; align-items: center; margin-top: 8px; } .lead-form input, .lead-form select { margin: 0; height: 38px; }

/* ---- Ny kund, Nycklar, Ärenden (docs/NY-KUND.md, NYCKLAR.md, ARENDEN.md) ------------------------------------------ */
.card.narrow { max-width: 560px; } a.pill { text-decoration: none; }
textarea { width: 100%; margin-top: 4px; min-height: 120px; padding: 10px 14px; border-radius: var(--r-s); border: 1px solid var(--line); background: var(--field); color: var(--fg); font: inherit; resize: vertical; }
textarea::placeholder { color: var(--dim); } textarea:focus { outline: none; border-color: var(--acc-line); box-shadow: 0 0 0 3px var(--acc-wash); }
.settings { display: grid; gap: 14px; } .setting .lead-head b { font-size: 15px; font-weight: 500; color: var(--mut); } .setting .facts { margin: 10px 0 4px; } .setting label small { margin-left: 6px; font-size: 12px; }
.steps { list-style: none; margin: 4px 0 0; padding: 0; } .steps li { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-2); } .steps li:first-child { border-top: 0; }
.steps .mark { width: 22px; height: 22px; border-radius: 50%; border: 1px solid var(--line); flex: none; display: grid; place-items: center; margin-top: 2px; font-size: 13px; font-weight: 700; color: var(--ink); }
.steps li.done .mark { background: var(--acc); border-color: var(--acc); } .steps li.done .mark::after { content: "✓"; }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 var(--acc-wash); } 50% { box-shadow: 0 0 0 6px var(--acc-wash); } }
.steps li.now .mark { border-color: var(--acc); animation: pulse 1.6s ease-in-out infinite; } .steps li:not(.done):not(.now) { opacity: .55; }
.steps .what b { display: block; font-weight: 600; } .steps .what span { color: var(--mut); font-size: 13.5px; }
.card.build.ready { border-color: var(--acc-line); } .addr { margin: 4px 0 8px; font-size: 20px; letter-spacing: -.01em; overflow-wrap: anywhere; } .addr b { font-weight: 600; }
.answer { margin: 6px 0 0; padding: 10px 14px; border-left: 2px solid var(--acc); white-space: pre-wrap; overflow-wrap: anywhere; font-size: 14.5px; }

/* ---- v2 (docs/SUPER.md 2026-10-17): the calm grid, the scrolling customer list, the computer cards, the rooms ------------------- */
.page > :is(.card, .tiles, .two, .status, .toolbar, details, .pcs, .channels, .once, .quiet-line) + :is(.card, .tiles, .two, .status, .toolbar, details, .pcs, .channels, .once, .quiet-line) { margin-top: 14px; }
.tiles.six { grid-template-columns: repeat(3, 1fr); grid-auto-rows: 1fr; }
.tile { grid-template-rows: auto auto 1fr; align-content: start; min-width: 0; } a.tile { color: var(--fg); transition: border-color var(--fast), transform var(--fast) var(--ease); }
a.tile:hover { border-color: var(--acc-line); transform: translateY(-1px); } .tile b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile .note { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; align-self: end; }
.tiles.small.three { grid-template-columns: repeat(3, 1fr); margin: 12px 0 4px; }
.card.lines { padding: 4px 22px; } .line { display: flex; align-items: center; gap: 14px; padding: 14px 0; color: var(--fg); border-bottom: 1px solid var(--line-2); font-size: 15px; }
.line:last-child { border-bottom: 0; } .line .ic { color: var(--mut); } .line .go { margin-left: auto; color: var(--acc); font-size: 13.5px; white-space: nowrap; } .line:hover .go { color: var(--fg); }
details.more-info > summary { cursor: pointer; color: var(--acc); font-size: 14px; list-style: none; padding: 6px 0 2px; } details.more-info > summary::-webkit-details-marker { display: none; }
details.more-info > summary::before { content: "›"; display: inline-block; width: 14px; transition: transform var(--fast); } details.more-info[open] > summary::before { transform: rotate(90deg); }
details.more-info[open] > summary { margin-bottom: 6px; } details.card.more-info { padding-top: 12px; padding-bottom: 12px; } details.more-info .two { margin-top: 4px; }
.card.panel { padding: 0; overflow: hidden; } .scroll { max-height: 70vh; overflow: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; }
.scroll table thead th { position: sticky; top: 0; z-index: 1; background: var(--thead); padding-top: 14px; }
.scroll td:first-child, .scroll th:first-child { padding-left: 22px; } .scroll td:last-child, .scroll th:last-child { padding-right: 22px; }
.scroll .empty { padding: 18px 22px; } .scroll.leads { padding: 14px; } .scroll.leads .lead:first-child { margin-top: 0; }
tr[data-href] { cursor: pointer; } td.st { white-space: nowrap; } td.st .dot { vertical-align: middle; margin-right: 4px; }
.quiet-line { padding: 0 6px; } .quiet-line .muted { font-size: 13.5px; }
.kund-top .person { margin: 4px 0 0; font-size: 14.5px; }
.pcs { display: grid; grid-template-columns: repeat(auto-fill, minmax(360px, 1fr)); gap: 14px; }
.pc-head { display: flex; align-items: center; gap: 10px; } .pc-head b { font-size: 20px; font-weight: 600; letter-spacing: -.01em; } .pc-head .muted { font-size: 14px; }
.addr-line { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 8px 0 6px; font-size: 15px; } .addr-text { color: var(--acc); overflow-wrap: anywhere; }
.pill.sm { height: 30px; padding: 0 12px; font-size: 12.5px; } .chips { margin-top: 14px; }
.warn-line { color: var(--warn); font-size: 13.5px; margin: 2px 0 6px; } .warn-text { color: var(--warn); }
.danger-box { margin-top: 14px; padding: 14px 16px; border-radius: var(--r-s); border: 1px solid color-mix(in srgb, var(--danger) 50%, transparent); background: color-mix(in srgb, var(--danger) 7%, transparent); }
.danger-box p { margin: 0 0 12px; font-size: 14px; } .pill.danger.ask { background: var(--danger); border-color: var(--danger); color: var(--ink); }
.card.danger-zone { border-color: color-mix(in srgb, var(--danger) 35%, transparent); box-shadow: none; }
.how { display: flex; gap: 14px; align-items: flex-start; margin-top: 12px; padding: 16px 18px; border-radius: var(--r-s); background: var(--glass-3); border: 1px dashed var(--line); }
.how .ic { width: 26px; height: 26px; color: var(--acc); } .how p { margin: 2px 0; }
.states { list-style: none; margin: 4px 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 0 22px; }
.states li { display: flex; align-items: center; gap: 10px; padding: 8px 0; font-size: 14px; border-bottom: 1px solid var(--line-2); } .states small { margin-left: auto; color: var(--mut); }
.server .srv-head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 4px; } .server .srv-head b { font-size: 24px; font-weight: 600; letter-spacing: -.02em; }
.server .srv-head .muted { font-size: 13.5px; } .meter.big { margin-top: 16px; } .meter.big .meter-head { font-size: 14.5px; color: var(--mut); gap: 12px; } .meter.big .meter-head b { color: var(--fg); font-weight: 600; }
.meter.big .bar { height: 10px; } .bar.hot span { background: var(--warn); }
.quiet-card { background: var(--glass-3); box-shadow: none; } .quiet-table td { color: var(--mut); }
.channels { display: grid; gap: 10px; } .chan-line { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; font-size: 15px; } .chan-name { font-weight: 600; min-width: 48px; }
.channel .btns { margin-top: 12px; } .narrow-form { max-width: 520px; } .status.good { border-color: var(--acc-line); }

/* ---- phone (390): everything one column; the rail is a bar at the bottom with words, "Mer" opens the sheet ------------------- */
@media (max-width: 1100px) { .two { grid-template-columns: 1fr; } .tiles, .tiles.six { grid-template-columns: repeat(2, 1fr); } .tiles.four { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) {
  main { padding: 62px 16px calc(100px + env(safe-area-inset-bottom)); } .top { height: 48px; padding: 0 16px; font-size: 12.5px; background: linear-gradient(180deg, color-mix(in srgb, var(--deep) 92%, transparent), color-mix(in srgb, var(--deep) 0%, transparent)); }
  .top .co, #clock, .top .sep, .who-name { display: none; }
  .rail { top: auto; left: 0; right: 0; bottom: 0; width: auto; flex-direction: row; padding: 6px 4px calc(6px + env(safe-area-inset-bottom)); background: var(--bar-bg);
          -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border-top: 1px solid var(--line); }
  .rail .places { flex-direction: row; gap: 0; width: 100%; justify-content: space-around; } .rail .quiet { display: none; }
  .rail .places > a, .rail .more summary { flex: 1; width: auto; min-width: 0; min-height: 52px; padding: 6px 0 4px; gap: 4px; justify-content: center; }
  .rail .w { font-size: 10.5px; } .rail .lg { display: none; } .rail .sh { display: inline; }
  .rail .more { display: flex; flex: 1; } .rail .more summary { list-style: none; display: flex; flex-direction: column; align-items: center; color: var(--mut); cursor: pointer; border-radius: 16px; }
  .rail .more summary::-webkit-details-marker { display: none; } .rail .more summary.on, .rail .more[open] summary { color: var(--fg); background: color-mix(in srgb, var(--wash) 9%, transparent); }
  .rail .more .sheet { position: fixed; left: 10px; right: 10px; bottom: calc(74px + env(safe-area-inset-bottom)); padding: 14px 14px 8px; border-radius: 22px; background: var(--sheet);
                       border: 1px solid var(--line); box-shadow: var(--shadow); }
  .rail .more .sheet a { flex-direction: row; justify-content: flex-start; gap: 14px; width: 100%; padding: 12px 10px; min-height: 48px; font-size: 15px; color: var(--fg); }
  h1 { margin-bottom: 14px; } .card { padding: 14px 16px; border-radius: 18px; } .tiles, .tiles.six { grid-template-columns: 1fr 1fr; gap: 10px; } .tile { padding: 14px 16px; } .tile b { font-size: 24px; }
  .status { flex-direction: column; align-items: flex-start; gap: 12px; } .status .big { font-size: 20px; } .months { height: 120px; } .month b { display: none; }
  .channel .tiles.small { grid-template-columns: 1fr 1fr; } .tiles.four { grid-template-columns: 1fr 1fr; } .tiles.small.three { grid-template-columns: 1fr 1fr; }
  .hrow, .hrow.has-act { grid-template-columns: 10px 1fr auto auto; } .hact:empty { display: none; } .hcell { display: none; }
  .alarm-list li { flex-wrap: wrap; } .alarm-list .what { flex-basis: 100%; padding-left: 22px; } .alarm-n { font-size: 36px; }
  .lead-form { grid-template-columns: 1fr; } .inline-form { flex-wrap: wrap; } .inline-form input, .inline-form select { max-width: none; flex: 1; }
  .people-add input[name=name], .people-add input[name=email] { flex: 1 1 100%; }      /* «Add person» on a phone: name and e-mail full width */
  .people-list .people-acts { margin-left: 0; flex-basis: 100%; }                      /* round S1: the person's buttons under the name on a phone */
  .facts dd { text-align: left; } .facts { grid-template-columns: 1fr; gap: 2px 0; } .facts dt { margin-top: 8px; }
  .pc .facts { grid-template-columns: auto 1fr; gap: 6px 14px; } .pc .facts dd { text-align: right; } .pc .facts dt { margin-top: 0; }
  .hide-s { display: none; } .pcs { grid-template-columns: 1fr; } .scroll { max-height: 66vh; } .card.lines { padding: 2px 16px; } .line { font-size: 14px; }
  .scroll td:first-child, .scroll th:first-child { padding-left: 16px; } .scroll td:last-child, .scroll th:last-child { padding-right: 16px; }
  .search { max-width: none; } .toolbar { gap: 10px; }
  .pill, .seg a, .seg button { min-height: 44px; } input, select { min-height: 44px; } .pill.sm { min-height: 36px; }
  .top .brand, .top .who { min-height: 44px; display: inline-flex; align-items: center; } .top .who { padding: 0 8px; margin-right: -8px; }
}

/* ---- Ärenden v2 (docs/ARENDEN.md 2026-10-17): the thread as a chat, the customer at the left, Genomain at the right ----------- */
.card.chat { padding-bottom: 16px; } .thread-top { margin: 0 0 6px; } .thread-head { margin: 0; font-size: 14px; }
.thread { display: flex; flex-direction: column; gap: 10px; margin: 8px 0 14px; }
.msg { display: flex; } .msg.genomain { justify-content: flex-end; }
.bubble { max-width: min(78%, 620px); padding: 10px 14px 12px; border-radius: 18px; background: var(--glass-3); border: 1px solid var(--line); }
.msg.kund .bubble { border-bottom-left-radius: 6px; } .msg.genomain .bubble { border-bottom-right-radius: 6px; background: var(--acc-wash); border-color: var(--acc-line); }
.bubble .who { margin: 0 0 4px; font-size: 12px; color: var(--mut); } .bubble .text { margin: 0; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 15px; line-height: 1.45; }
.bubble .files { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.thumb { display: block; width: 132px; height: 132px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: color-mix(in srgb, var(--shade) 25%, transparent); }
.thumb img { width: 100%; height: 100%; object-fit: cover; display: block; } .file-chip { max-width: 100%; overflow: hidden; text-overflow: ellipsis; }
.reply { border-top: 1px solid var(--line-2); padding-top: 12px; } .reply textarea { min-height: 84px; margin: 0; } .reply .btns { margin-top: 10px; }
.reply .send { margin-left: auto; } .attach { position: relative; cursor: pointer; } .vh { position: absolute; width: 1px; height: 1px; opacity: 0; overflow: hidden; }
.picked { font-size: 13px; max-width: 220px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .dot-space { display: inline-block; width: 10px; }
@media (max-width: 760px) { .bubble { max-width: 88%; } .thumb { width: 112px; height: 112px; } .reply .send { margin-left: 0; } .attach, .reply .send, .thumb { min-height: 44px; } }
/* round S1 (account security): a person's tags and the staff's Pause · Reset · Sign out everywhere, at the row's end */
.people-list li { flex-wrap: wrap; } .people-list li > b { white-space: nowrap; } .people-list .tag { margin-left: 2px; }
.people-list .people-acts { margin-left: auto; display: flex; flex-wrap: wrap; gap: 6px; }
