/* Huisstijl afgeleid van smartenergycontrol.be (src/styles/global.css) */
:root {
  --navy: #17324C; --blue: #0A7CC4; --green: #3DA81A;
  --ground: #F4F8FB; --surface: #FFFFFF; --surface-2: #F7FAFC;
  --ink: #16304A; --ink-soft: #48606F; --line: #DBE6EC; --line-strong: #C4D3DB;
  --accent-ink: #0A6AAB; --accent-soft: #E1F0F9;
  --ok-bg: #E7F4DF; --ok-ink: #2E8214; --ok-dot: #3DA81A;
  --red-bg: #FDE7E5; --red-ink: #B42318; --red-dot: #D92D20;
  --amber-bg: #FFF1D6; --amber-ink: #7A4F00;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 14px/1.45 Inter, system-ui, sans-serif; }
a { color: var(--accent-ink); }
h1, h2 { font-family: Sora, Inter, sans-serif; color: var(--navy); font-weight: 600; }
h1 { font-size: 28px; margin: 0; }
h2 { font-size: 16px; margin: 0 0 12px; }
.wrap { max-width: 1360px; margin: 0 auto; padding: 0 24px; }
main.wrap { padding-top: 24px; padding-bottom: 48px; display: flex; flex-direction: column; gap: 20px; }
.muted { color: var(--ink-soft); }
.small { font-size: 13px; }
.center { text-align: center; padding: 28px; }
.right { text-align: right; white-space: nowrap; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.envbar { background: var(--amber-bg); color: var(--amber-ink); text-align: center; font-weight: 600; font-size: 12px; padding: 4px; }
.top { background: var(--surface); border-bottom: 1px solid var(--line); }
.bar { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); }
.brand img { border-radius: 8px; }
.brand > span { display: flex; flex-direction: column; line-height: 1.15; }
.wordmark { font-family: Sora, sans-serif; font-weight: 700; font-size: 17px; letter-spacing: -.02em; }
.wordmark .acc { color: var(--accent-ink); }
.sub { font-size: 12px; color: var(--ink-soft); font-weight: 600; }
.nav { display: flex; gap: 4px; flex-wrap: wrap; }
.nav a { padding: 8px 14px; border-radius: 8px; text-decoration: none; color: var(--ink-soft); font-weight: 500; }
.nav a.on { background: var(--accent-soft); color: var(--accent-ink); font-weight: 600; }
.who { margin-left: auto; }
.chip { font-size: 13px; padding: 6px 12px; border: 1px solid var(--line-strong); border-radius: 999px; }
.chip.green { background: var(--ok-bg); color: var(--ok-ink); border-color: transparent; font-weight: 600; }

.impbar { background: var(--navy); color: #fff; }
.impbar form { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; padding: 8px 0; }
.impbar select, .impbar button { font: inherit; padding: 6px 10px; border-radius: 8px; border: 0; }
.impbar .note { color: #C9D8E3; }

.head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; }
.head p { margin: 6px 0 0; }
.crumbs { font-size: 13px; color: var(--ink-soft); }

.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.tile { display: flex; flex-direction: column; gap: 6px; min-height: 110px; padding: 18px 20px; border-radius: 14px;
        background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--ink); }
.tile .lbl { font-size: 13px; display: flex; align-items: center; gap: 8px; }
.tile .num { font-family: Sora, sans-serif; font-size: 40px; font-weight: 600; }
.tile .hint { font-size: 12px; color: var(--ink-soft); }
.tile.dark, .tile.on { background: var(--navy); border-color: var(--navy); color: #fff; }
.tile.on .hint, .tile.dark .hint { color: #C9D8E3; }
.tile.on.red { background: var(--red-dot); border-color: var(--red-dot); }
.tile.on.blue { background: var(--blue); border-color: var(--blue); }
.tile.on.green { background: var(--ok-ink); border-color: var(--ok-ink); }
.dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; }
.dot.red { background: var(--red-dot); } .dot.blue { background: var(--blue); } .dot.green { background: var(--ok-dot); }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px; }
.card.flush { padding: 0; overflow: hidden; }
.card.notice.actie { background: var(--red-bg); border-color: #F5C2BD; }
.card.notice.beheer { background: var(--accent-soft); border-color: #B9D9EF; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { display: inline-flex; gap: 8px; align-items: center; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line-strong);
        text-decoration: none; color: var(--ink); }
.pill.on { border-color: var(--blue); background: var(--accent-soft); }
.badge { border-radius: 999px; padding: 1px 7px; font-size: 12px; font-weight: 700; }
.badge.red { background: var(--red-bg); color: var(--red-ink); }

.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.toolbar input[type=search] { font: inherit; width: 320px; max-width: 100%; padding: 9px 12px; border: 1px solid var(--line-strong); border-radius: 10px; }
button, .btn { font: inherit; font-weight: 600; padding: 9px 14px; border-radius: 10px; border: 0; background: var(--blue); color: #fff; cursor: pointer; text-decoration: none; display: inline-block; }
.btn.ghost { background: var(--surface); color: var(--ink); border: 1px solid var(--line-strong); font-weight: 500; }
.btn.small { padding: 7px 12px; background: var(--surface); color: var(--ink); border: 1px solid var(--line-strong); font-weight: 500; }

.scroll { overflow-x: auto; }
table { width: 100%; min-width: 1100px; border-collapse: collapse; }
th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--ink-soft); background: var(--surface-2); padding: 12px; }
td { padding: 12px; border-top: 1px solid #E6EEF3; vertical-align: top; }
tr:hover td { background: var(--surface-2); }
.host { font-weight: 600; text-decoration: none; }
.msg { max-width: 260px; }

.state { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; font-weight: 600; font-size: 12px; white-space: nowrap; margin-right: 4px; }
.state i { width: 8px; height: 8px; border-radius: 50%; }
.state.ok { background: var(--ok-bg); color: var(--ok-ink); } .state.ok i { background: var(--ok-dot); }
.state.actie { background: var(--red-bg); color: var(--red-ink); } .state.actie i { background: var(--red-dot); }
.state.beheer, .state.onboarding { background: var(--accent-soft); color: var(--accent-ink); }
.state.beheer i, .state.onboarding i { background: var(--blue); }
.state.onbekend, .state.stock { background: var(--surface-2); color: var(--ink-soft); }
.state.onbekend i, .state.stock i { background: var(--line-strong); }
meter.soc { width: 70px; height: 10px; vertical-align: middle; }

.grid3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; }
.kpi { border: 1px solid var(--line); border-radius: 12px; padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.kpi.sun { background: #FFF8EA; border-color: #F3D9A4; }
.kpi .lbl { font-size: 12px; color: var(--ink-soft); font-weight: 600; }
.kpi .num { font-family: Sora, sans-serif; font-size: 26px; font-weight: 600; }
.facts { display: grid; grid-template-columns: 160px 1fr; gap: 8px 16px; margin: 0; }
.facts dt { color: var(--ink-soft); }
.facts dd { margin: 0; }

/* dossier en bewerken */
.cardhead { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; }
.cardhead h2 { margin: 0; }
h3 { font-family: Sora, Inter, sans-serif; color: var(--navy); font-size: 14px; font-weight: 600; margin: 18px 0 8px; }
.changes { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; }
.changes > li { border-top: 1px solid var(--line); padding-top: 10px; }
.changes ul { margin: 6px 0 0; padding-left: 18px; }
.changes s { color: var(--ink-soft); }
.form h2 { margin-top: 8px; }
.form h2 ~ h2 { margin-top: 24px; }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 14px 18px; }
.fields label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 13px; color: var(--ink-soft); }
.fields .wide { grid-column: 1 / -1; }
.fields input, .fields select { font: inherit; font-weight: 400; color: var(--ink); padding: 9px 12px; border: 1px solid var(--line-strong); border-radius: 10px; background: var(--surface); }
.fields input:focus, .fields select:focus { outline: 2px solid var(--blue); outline-offset: 1px; }
.code-veld { display: flex; align-items: stretch; }
.code-veld .prefix { display: flex; align-items: center; padding: 0 10px; border: 1px solid var(--line-strong); border-right: 0;
  border-radius: 10px 0 0 10px; background: var(--line); color: var(--ink-soft); font-weight: 600; letter-spacing: .04em; }
.code-veld input { flex: 1; min-width: 0; border-radius: 0 10px 10px 0; letter-spacing: .08em; font-size: 18px; text-transform: uppercase; }
.actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
@media (max-width: 600px) { .facts { grid-template-columns: 1fr; gap: 2px; } .facts dd { margin-bottom: 8px; } }

/* installateurs */
table.narrow { min-width: 640px; }
form.inline { display: inline; }
.btn.small.danger { color: var(--red-ink); border-color: #F5C2BD; }
.toolbar h2 { margin: 0; }

/* actie installateur */
.notice .big { font-size: 16px; font-weight: 600; margin: 0 0 6px; }
.resolve { margin-top: 14px; align-items: end; }
.resolve input { background: var(--surface); }
details.ask summary { cursor: pointer; font-family: Sora, Inter, sans-serif; font-weight: 600; color: var(--navy); }
details.ask[open] summary { margin-bottom: 14px; }
.fields textarea { font: inherit; color: var(--ink); padding: 9px 12px; border: 1px solid var(--line-strong); border-radius: 10px; resize: vertical; }
.changes p { margin: 6px 0 0; }

/* instellingenoverzicht */
.tablewrap { overflow-x: auto; }
table.settings { min-width: 0; margin-bottom: 4px; }
table.settings th, table.settings td { padding: 8px 10px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 13px; }

/* klantlogin en app */
.appinvite { display: flex; gap: 24px; align-items: flex-start; flex-wrap: wrap; }
.appinvite .qr { width: 200px; max-width: 100%; flex: none; background: #fff; border: 1px solid var(--line-strong); border-radius: 10px; padding: 6px; }
.appinvite .qr svg { display: block; width: 100%; height: auto; }
.appinvite ol { margin: 0; padding-left: 20px; flex: 1 1 260px; line-height: 1.6; }

/* opdrachten */
.appinvite .steps { flex: 1 1 260px; }
.appinvite .steps ol { padding-left: 20px; }
p.code { font-size: 26px; font-weight: 700; letter-spacing: .06em; color: var(--navy); margin: 0 0 12px; }
details.unlink { margin-top: 14px; }
details.unlink summary { cursor: pointer; color: var(--ink-soft); font-size: .9rem; }
details.unlink[open] summary { margin-bottom: 8px; }

/* publieke planpagina (stap Ander toestel) */
.plan { max-width: 760px; display: flex; flex-direction: column; gap: 16px; padding-top: 24px; padding-bottom: 48px; }
.plan h2 { font-size: 18px; margin: 0 0 8px; }
.plan-steps { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 10px; }
form.wizardfeat { display: flex; gap: 10px; align-items: end; margin-top: 12px; flex-wrap: wrap; }
details.wizardfeat, details.filled { margin-top: 10px; }
details.wizardfeat summary, details.filled summary { cursor: pointer; }
details.wizardfeat[open] summary, details.filled[open] summary { margin-bottom: 8px; }
table.compact { width: 100%; min-width: 0; border-collapse: collapse; font-size: .9rem; }
table.compact td { padding: 3px 6px; border-bottom: 1px solid var(--line, #e3ecf1); vertical-align: top; overflow-wrap: anywhere; }
table.compact td:first-child { width: 45%; }
.profiles .steps { columns: 2; column-gap: 24px; }
.profiles .steps label { display: block; break-inside: avoid; }
@media (max-width: 600px) { .profiles .steps { columns: 1; } }
.profiles fieldset.smarthome { border: 1px solid var(--line, #e3ecf1); border-radius: 8px; padding: 6px 12px 8px; margin: 10px 0; }
.profiles fieldset.smarthome legend { padding: 0 4px; font-weight: 600; }
.profiles fieldset.smarthome > label { display: block; margin-left: 18px; }
.devphotos + .devphotos { margin-top: 14px; }
.devphotos .thumbs { display: flex; gap: 8px; flex-wrap: wrap; }
.devphotos .thumbs img { width: 140px; height: 105px; object-fit: cover; border-radius: 8px; border: 1px solid var(--line); }
.sendgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.sendgrid form h3 { margin-top: 0; }
@media (max-width: 760px) { .sendgrid { grid-template-columns: 1fr; } }
.notice-ok { background: #E8F6EE; border: 1px solid #BFE3CC; border-radius: 10px; padding: 8px 12px; }
.notice-err { background: #FDE7E5; border: 1px solid #F5C2BD; border-radius: 10px; padding: 8px 12px; }
details.otheraddr { margin: 10px 0; }
details.otheraddr summary { cursor: pointer; font-size: 13px; color: var(--ink-soft); }
details.otheraddr[open] summary { margin-bottom: 8px; }
.fields.techfields { grid-template-columns: 1fr 1fr; max-width: 720px; }
@media (max-width: 600px) { .fields.techfields { grid-template-columns: 1fr; } }


/* ---------- resourceboom (enkel ILSE-beheer) ---------- */
.bm-head { display: flex; flex-wrap: wrap; gap: 20px; align-items: center; }
.bm-title { display: flex; flex-direction: column; gap: 6px; min-width: 260px; }
.bm-ean { font-size: 13px; display: flex; gap: 8px; align-items: center; }
.bm-ean code { font-size: 13px; }
.bm-stats { display: flex; flex-wrap: wrap; gap: 10px; margin-left: auto; }
.bm-stat { background: var(--surface-2); border: 1px solid var(--line); border-radius: 10px; padding: 8px 14px; min-width: 112px; }
.bm-stat small { display: block; color: var(--ink-soft); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 150px; }
.bm-stat strong { font-family: Sora, Inter, sans-serif; font-size: 19px; }
.imp { color: #0A7CC4; } .exp { color: #2E8214; } .zero { color: var(--ink-soft); }
.bm-toolbar { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.bm-seg { display: inline-flex; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 10px; padding: 3px; }
.bm-seg button { font: inherit; font-weight: 600; font-size: 13px; border: 0; background: none; padding: 6px 14px; border-radius: 7px; cursor: pointer; color: var(--ink-soft); }
.bm-seg button[aria-pressed="true"] { background: var(--navy); color: #fff; }
.bm-legend { display: flex; gap: 12px; flex-wrap: wrap; font-size: 12px; color: var(--ink-soft); align-items: center; }
.bm-legend .imp, .bm-legend .exp { font-weight: 700; }
.bm-grid { display: grid; grid-template-columns: minmax(0, 1fr) 380px; gap: 16px; align-items: start; }
@media (max-width: 1100px) { .bm-grid { grid-template-columns: 1fr; } }
.bm-view { padding: 10px 8px 14px; }
.bm-tree, .bm-kids { list-style: none; margin: 0; padding: 0; }
.bm-kids { margin-left: 26px; padding-left: 14px; border-left: 2px solid var(--line); }
.bm-node.closed > .bm-kids { display: none; }
.bm-row { display: grid; grid-template-columns: 30px minmax(130px, 1fr) 108px 76px 266px; gap: 10px; align-items: center;
  padding: 7px 10px; margin: 3px 0; border-radius: 10px; cursor: pointer; border: 1px solid transparent; position: relative; }
.bm-kids > .bm-node > .bm-row::before { content: ""; position: absolute; left: -16px; top: 50%; width: 14px; border-top: 2px solid var(--line); }
.bm-row:hover { background: var(--surface-2); }
.bm-row.sel { background: var(--accent-soft); border-color: #B9DCF2; }
.bm-row:focus-visible, .bm-rm:focus-visible { outline: 2px solid var(--blue); outline-offset: 1px; }
@media (max-width: 760px) { .bm-row { grid-template-columns: 30px 1fr 82px; } .bm-meter, .bm-caps { grid-column: 2 / -1; } }
.bm-ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; flex: none; }
.bm-ico svg { width: 17px; height: 17px; fill: none; stroke: #fff; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.bm-ico svg .f { fill: #fff; stroke: none; }
.t-site { background: var(--navy); } .t-meter, .t-other { background: #6B7F8C; } .t-ev { background: #0A7CC4; }
.t-plug { background: #4C9BD6; } .t-pv { background: #D99A00; } .t-battery { background: #3DA81A; }
.t-boiler { background: #D9622B; } .t-heatpump { background: #B5487A; }
.bm-lbl { min-width: 0; }
.bm-n { font-weight: 600; display: flex; align-items: center; gap: 2px; min-width: 0; }
.bm-n > span:first-of-type { overflow-wrap: anywhere; }
.bm-m { font-size: 12px; color: var(--ink-soft); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bm-cnt { display: none; }
.bm-node.closed > .bm-row .bm-cnt { display: inline; }
.bm-kind { font-size: 10px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-soft); }
.bm-ct .bm-kind { margin-left: 6px; }
.bm-tog { border: 0; background: none; cursor: pointer; color: var(--ink-soft); font-size: 12px; padding: 0 4px 0 0; transition: transform .15s; }
.bm-node.closed > .bm-row .bm-tog { transform: rotate(-90deg); }
.bm-meter { display: flex; flex-direction: column; gap: 3px; }
.bm-meter small { font-size: 11px; color: var(--ink-soft); }
.bm-track { height: 7px; background: #EAF0F4; border-radius: 999px; overflow: hidden; }
.bm-fill { height: 100%; border-radius: 999px; background: #0A7CC4; width: 0; }
.bm-fill.exp { background: #3DA81A; }
.bm-kw { font-family: Sora, Inter, sans-serif; font-weight: 600; text-align: right; white-space: nowrap; }
.bm-caps { display: flex; flex-direction: column; gap: 4px; }
.bm-verbs { display: flex; gap: 3px; flex-wrap: wrap; }
.bm-verb { font-size: 11px; padding: 1px 7px; border-radius: 999px; border: 1px solid var(--line); color: #A9B7C0; background: var(--surface); }
.bm-verb.on { color: var(--navy); border-color: var(--line-strong); background: #EEF4F8; font-weight: 600; }
.bm-std { display: flex; gap: 4px; flex-wrap: wrap; }
.bm-b { font-size: 10.5px; font-weight: 700; padding: 1px 7px; border-radius: 6px; white-space: nowrap; }
.bm-b.oadr { background: #E6EEF6; color: #1F4E79; }
.bm-b.s2 { background: #EEE7F7; color: #5B3A8C; }
.bm-b.dim { opacity: .55; }
.bm-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 4px; vertical-align: middle; }
.bm-dot.act { background: #3DA81A; } .bm-dot.sch { background: #9B7BD0; } .bm-dot.lees { background: #0A7CC4; } .bm-dot.niet { background: #C4D3DB; }
.bm-side { position: sticky; top: 16px; display: flex; flex-direction: column; }
.bm-detail { display: flex; flex-direction: column; gap: 14px; }
.bm-detail[hidden] { display: none; }
.bm-dhead { display: flex; gap: 10px; align-items: center; }
.bm-dhead h2 { margin: 0; font-size: 17px; }
.bm-dhead .mono { word-break: break-all; }
.bm-big { display: flex; align-items: baseline; gap: 10px; }
.bm-big .bm-kw { font-size: 26px; }
.bm-sec h3 { margin: 0 0 6px; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--ink-soft); font-weight: 600; font-family: Inter, sans-serif; }
.bm-sec p { margin: 6px 0 0; }
.bm-chain { display: flex; flex-direction: column; gap: 4px; }
.bm-chain div { display: flex; justify-content: space-between; gap: 10px; font-size: 13px; padding: 5px 9px; border-radius: 7px; background: var(--surface-2); border: 1px solid var(--line); }
.bm-chain .tight { border-color: #F2C46B; background: #FFF8E8; }
.bm-sig { display: flex; flex-direction: column; gap: 5px; }
.bm-sig div { font-size: 12.5px; display: flex; gap: 8px; align-items: baseline; }
.bm-sig code { font-size: 11px; background: #E6EEF6; color: #1F4E79; padding: 1px 6px; border-radius: 5px; white-space: nowrap; }
.bm-kv { display: grid; grid-template-columns: auto 1fr; gap: 3px 12px; font-size: 13px; margin: 0; }
.bm-kv dt { color: var(--ink-soft); } .bm-kv dd { margin: 0; }
.bm-intro { padding: 6px 10px; margin: 0; font-size: 13px; color: var(--ink-soft); }
.mono { font-family: ui-monospace, Consolas, monospace; font-size: 12px; }
.bm-table tr[data-sel] { cursor: pointer; }
.bm-table tr.sel td { background: var(--accent-soft); }
.bm-rms { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; padding: 10px; }
.bm-rm { border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: flex; gap: 10px; align-items: flex-start; cursor: pointer; }
.bm-rm:hover { background: var(--surface-2); }
.bm-rm.sel { background: var(--accent-soft); border-color: #B9DCF2; }
.bm-ct { font-family: Sora, Inter, sans-serif; font-weight: 700; color: #5B3A8C; font-size: 15px; }
.bm-rmn { font-weight: 600; }
.bm-fill.p0 { width: 0; } .bm-fill.p5 { width: 5%; } .bm-fill.p10 { width: 10%; } .bm-fill.p15 { width: 15%; }
.bm-fill.p20 { width: 20%; } .bm-fill.p25 { width: 25%; } .bm-fill.p30 { width: 30%; } .bm-fill.p35 { width: 35%; }
.bm-fill.p40 { width: 40%; } .bm-fill.p45 { width: 45%; } .bm-fill.p50 { width: 50%; } .bm-fill.p55 { width: 55%; }
.bm-fill.p60 { width: 60%; } .bm-fill.p65 { width: 65%; } .bm-fill.p70 { width: 70%; } .bm-fill.p75 { width: 75%; }
.bm-fill.p80 { width: 80%; } .bm-fill.p85 { width: 85%; } .bm-fill.p90 { width: 90%; } .bm-fill.p95 { width: 95%; }
.bm-fill.p100 { width: 100%; }
fieldset.included { border: 1px solid var(--line, #e3ecf1); border-radius: 8px; padding: 6px 12px 8px; margin: 10px 0; }
fieldset.included legend { padding: 0 4px; font-weight: 600; }


/* ---------- schema-baseline (enkel ILSE-beheer) ---------- */
.bl-head { display: grid; grid-template-columns: 1fr auto; gap: 10px 20px; align-items: start; }
.bl-head .chips { grid-column: 1 / -1; }
.bl-head p { margin: 4px 0 0; }
@media (max-width: 760px) { .bl-head { grid-template-columns: 1fr; } }
.bl-nav { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; }
.bm-seg a { font-weight: 600; font-size: 13px; padding: 6px 14px; border-radius: 7px; color: var(--ink-soft); text-decoration: none; }
.bm-seg a[aria-current="page"] { background: var(--navy); color: #fff; }
.bl-pick { display: flex; gap: 6px; align-items: center; }
.bl-pick a { text-decoration: none; font-size: 18px; padding: 0 6px; color: var(--ink-soft); }
.bl-pick input { font: inherit; padding: 4px 6px; border: 1px solid var(--line-strong); border-radius: 6px; }
.chip.bl-late { background: var(--red-bg); color: var(--red-ink); border-color: transparent; font-weight: 600; }
.bl-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 10px; }
.bl-kpis .bm-stat span { display: block; font-size: 12px; color: var(--ink-soft); }
.bl-kpis .bm-stat strong { display: block; }
.bl-chart { width: 100%; height: auto; display: block; }
.bl-chart .grid { stroke: #EAF0F4; } .bl-chart .axis0 { stroke: #9FB3C0; stroke-width: 1.2; }
.bl-chart .tick { font: 11px Inter, sans-serif; fill: #48606F; }
.bl-chart .bar.imp { fill: #0A7CC4; opacity: .35; } .bl-chart .bar.exp { fill: #3DA81A; opacity: .4; }
.bl-chart .d1 { fill: none; stroke: #17324C; stroke-width: 2.2; }
.bl-chart .q15 { fill: none; stroke: #9B7BD0; stroke-width: 1.6; stroke-dasharray: 4 3; }
.bl-chart .now { stroke: #D92D20; stroke-width: 1.5; } .bl-chart .nowt { font: 11px Inter, sans-serif; fill: #B42318; }
.bl-chart .hit { fill: transparent; } .bl-chart .hit:hover { fill: rgba(23, 50, 76, .06); }
.bl-key { display: inline-block; width: 18px; height: 3px; vertical-align: middle; margin-right: 5px; border-radius: 2px; }
.bl-key.d1 { background: #17324C; } .bl-key.q15 { background: #9B7BD0; } .bl-key.m { background: #0A7CC4; height: 8px; opacity: .5; }
.bl-h3 { font-size: 13px; margin: 14px 0 6px; font-family: Inter, sans-serif; color: var(--navy); }
.bl-strip { display: grid; gap: 1px; }
.bl-strip.bl-n92 { grid-template-columns: repeat(92, 1fr); } .bl-strip.bl-n96 { grid-template-columns: repeat(96, 1fr); }
.bl-strip.bl-n100 { grid-template-columns: repeat(100, 1fr); }
.bl-strip span, .bl-sw { height: 22px; border-radius: 2px; }
.bl-sw { display: inline-block; width: 16px; height: 10px; vertical-align: middle; margin-right: 5px; }
.bl-strip .ok, .bl-sw.ok { background: #E7EEF3; }
.bl-strip .meer1 { background: #BFDDF3; } .bl-strip .meer2, .bl-sw.meer2 { background: #7FB8E6; } .bl-strip .meer3 { background: #0A7CC4; }
.bl-strip .minder1 { background: #FBDDB8; } .bl-strip .minder2, .bl-sw.minder2 { background: #F2B36B; } .bl-strip .minder3 { background: #E0841F; }
.bl-strip .leeg, .bl-sw.leeg { background: repeating-linear-gradient(45deg, #EEF2F5, #EEF2F5 3px, #FFF 3px, #FFF 6px); }
.bl-striplbl { display: flex; justify-content: space-between; font-size: 11px; color: var(--ink-soft); margin-top: 3px; }
.bl-leg2 { margin-top: 8px; }
.bl-proof { display: flex; flex-direction: column; gap: 12px; }
.bl-proof h2 { margin: 0; }
.bl-step { display: flex; gap: 10px; align-items: flex-start; }
.bl-step > i { flex: none; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; color: #fff;
  font-size: 12px; font-weight: 700; font-style: normal; background: #3DA81A; }
.bl-step > i.wait { background: #C4D3DB; } .bl-step > i.bad { background: #D92D20; }
.bl-step b { display: block; font-size: 13px; font-weight: 600; } .bl-step span { font-size: 12px; color: var(--ink-soft); }
.bl-step .okt { display: inline; color: var(--ok-ink); } .bl-step .badt { display: inline; color: var(--red-ink); }
/* ---------- magazijn ---------- */
.clock { display: flex; align-items: center; gap: 8px; margin: 0; }
.flows { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; margin-bottom: 16px; }
.flow { display: block; padding: 20px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); text-decoration: none; }
.flow h2 { margin: 0 0 4px; }
.flow .num { font-family: Sora, sans-serif; font-size: 34px; font-weight: 600; color: var(--blue); }
.flow:hover { border-color: var(--blue); }
.picklist { list-style: none; margin: 0; padding: 0; }
.picklist li { display: flex; align-items: center; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.picklist li:last-child { border-bottom: 0; }
.picklist .loc { margin-left: auto; font-family: ui-monospace, monospace; font-weight: 600; background: var(--surface-2); padding: 4px 10px; border-radius: 8px; }
.picklist input[type=checkbox] { width: 26px; height: 26px; }
.picklist .scan { display: flex; flex-direction: column; gap: 6px; }
.picklist .scan input { font-family: ui-monospace, monospace; width: 200px; }
.inline { display: inline-flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 0; }
.inline input, .inline select { width: auto; }
.low { color: var(--red-ink); font-weight: 600; }

/* ---------- opdracht-editor: boom omvormer > dakvlakken / batterij (presales fase 1) ---------- */
.ems-tree { display: grid; gap: .75rem; margin: .5rem 0 1rem; }
.ems-inv { border: 1px solid var(--line, #d9dee5); border-radius: 10px; padding: .75rem 1rem 1rem; margin: 0; }
.ems-inv legend { font-weight: 600; padding: 0 .35rem; }
.ems-sub { margin: .5rem 0 0 1rem; padding-left: .9rem; border-left: 2px solid var(--line, #d9dee5); }
.ems-sub h3 { font-size: .95rem; margin: .5rem 0 .25rem; }
.ems-arr, .ems-bat { align-items: end; }
.btn.small { padding: .3rem .6rem; font-size: .85rem; }
label.check { display: flex; gap: .5rem; align-items: center; margin: .25rem 0 .5rem; }
.ems-preview pre { margin: 0; white-space: pre-wrap; font-size: .9rem; }
.src-badge { display: inline-block; font-size: .75rem; font-weight: 600; border-radius: 999px; padding: .05rem .5rem;
  margin-left: .35rem; vertical-align: middle; }
.src-badge.found { background: #e6f0ff; color: #1d4ed8; }
.src-badge.check { background: #fff1e0; color: #b45309; }
.import-info ul { margin: .25rem 0 .5rem 1.2rem; }
.ems-view, .ems-view ul { list-style: none; margin: 0; padding-left: 1.25rem; }
.ems-view { padding-left: 0; }
.ems-view li { margin: .35rem 0; }
.ems-view li > span { vertical-align: middle; }
.ems-view .bm-ico { display: inline-flex; width: 1.4rem; height: 1.4rem; margin-right: .35rem; }
.ems-view .bm-ico svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 1.6; }
.ems-view .bm-ico .f { fill: currentColor; fill-opacity: .25; }
.ems-tree [hidden], form [data-size-note][hidden], .ems-preview[hidden] { display: none !important; }
label > .src-badge { justify-self: start; width: max-content; margin: 0 0 .2rem; }

/* ---------- dakvlakken en 3D-woning (docs/dakvlakken.md) ---------- */
.roof { display: flex; flex-direction: column; gap: 16px; }
.roof-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 16px; }
.roof-faces-card { grid-column: 1 / -1; }
@media (max-width: 1000px) { .roof-grid { grid-template-columns: 1fr; } }
.roof-tools { display: flex; gap: 8px; flex-wrap: wrap; }
.roof-map { position: relative; line-height: 0; border-radius: 10px; overflow: hidden; background: #DDE6EC; }
.roof-map img { width: 100%; height: auto; display: block; }
.roof-map svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.roof.drawing .roof-map svg { cursor: crosshair; }
.roof-bld { fill: none; stroke: #fff; stroke-width: .25; stroke-dasharray: .8 .5; }
.roof-nb { fill: rgba(255, 255, 255, .12); stroke: rgba(255, 255, 255, .55); stroke-width: .12; }
.roof-face polygon:first-child { fill-opacity: .38; stroke-width: .25; cursor: pointer; }
.roof-face.off polygon:first-child { fill-opacity: .12; stroke-dasharray: .6 .4; }
.roof-face.sel polygon:first-child { fill-opacity: .55; stroke: #fff; stroke-width: .45; }
.roof-panel { fill: rgba(16, 32, 58, .82); stroke: rgba(255, 255, 255, .7); stroke-width: .06; pointer-events: none; }
.roof-num { font: 700 1.6px Inter, sans-serif; fill: #fff; text-anchor: middle; dominant-baseline: middle; pointer-events: none;
  paint-order: stroke; stroke: rgba(0, 0, 0, .55); stroke-width: .25; }
.roof-drawline { fill: none; stroke: #FFD400; stroke-width: .3; }
.roof-drawpt { fill: #FFD400; stroke: #16304A; stroke-width: .1; }
.roof-3d-card canvas { width: 100%; display: block; border-radius: 10px; cursor: grab; touch-action: none; }
.roof-sun { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.roof-table { min-width: 760px; }
.roof-table th { text-align: left; font-size: 12px; color: var(--ink-soft); padding: 4px 6px; }
table.compact.roof-table td:first-child { width: 44px; white-space: nowrap; }
.roof-table tr.sel td { background: var(--accent-soft); }
.roof-table input[type="text"] { width: 100%; min-width: 120px; }
.roof-n { width: 70px; }
.roof-dot { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.roof-save { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-end; margin-top: 12px; }
.roof-mode { border: 1px solid var(--line); border-radius: 10px; padding: 6px 12px; display: flex; flex-direction: column; gap: 2px; }
.roof-table td { white-space: nowrap; vertical-align: middle; }
.roof-table td:nth-child(3) { white-space: normal; width: 30%; }
.badge.amber { background: var(--amber-bg); color: var(--amber-ink); cursor: help; }
.roof [hidden] { display: none !important; }

/* Demo-omgeving (docs/demo-omgeving.md): vaste vermelding bovenaan en watermerk over de hele pagina. */
.demobar { position: sticky; top: 0; z-index: 1000; background: #7c2d12; color: #fff; text-align: center;
  font-weight: 700; font-size: 13px; letter-spacing: .01em; padding: 6px 12px; }
.demo-wm { position: fixed; inset: 0; z-index: 2147483647; pointer-events: none; user-select: none;
  background-image: url("/demo/watermerk.svg"); background-repeat: repeat; background-size: 420px 240px; }
@media print { .demo-wm { position: fixed; } }
.demo-out { display: inline; margin-left: 8px; }
.demo-login { max-width: 440px; padding-top: 48px; }
.demo-login .brand { margin-bottom: 16px; }
.demo-login label { display: block; font-weight: 600; margin: 14px 0 4px; }
.demo-login input[type=email], .demo-login input[type=password] { width: 100%; box-sizing: border-box; }
