/* Opmaak in de stijl van macOS. Systeemlettertype: SF Pro op Mac en iPhone, Segoe UI op Windows. */

:root {
  --window: #F5F5F7;
  --surface: #FFFFFF;
  --fill: rgba(120, 120, 128, .12);
  --fill-strong: rgba(120, 120, 128, .2);
  --label: #1D1D1F;
  --label-2: rgba(60, 60, 67, .64);
  --label-3: rgba(60, 60, 67, .34);
  --sep: rgba(60, 60, 67, .13);
  --sep-strong: rgba(60, 60, 67, .24);
  --blue: #007AFF;
  --blue-hover: #0068DA;
  --ok: #248A3D;
  --ok-dot: #34C759;
  --warn: #C93400;
  --warn-bg: rgba(255, 149, 0, .13);
  --bad: #D70015;
  --bad-bg: rgba(255, 59, 48, .1);
  --scan: #FF3B30;
  --glass: rgba(255, 255, 255, .6);
  --glass-edge: rgba(255, 255, 255, .75);
  --shadow: 0 0 0 .5px rgba(0, 0, 0, .05), 0 1px 3px rgba(0, 0, 0, .05), 0 6px 18px rgba(0, 0, 0, .045);
  --shadow-float: 0 0 0 .5px rgba(0, 0, 0, .06), 0 10px 40px rgba(0, 0, 0, .1);
  --tint-a: rgba(0, 122, 255, .09);
  --tint-b: rgba(175, 82, 222, .07);
  --font: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI Variable Text', 'Segoe UI', system-ui, sans-serif;
  --font-display: -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI Variable Display', 'Segoe UI', system-ui, sans-serif;
  --mono: ui-monospace, 'SF Mono', SFMono-Regular, Menlo, Consolas, monospace;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --window: #1C1C1E;
    --surface: #2C2C2E;
    --fill: rgba(118, 118, 128, .24);
    --fill-strong: rgba(118, 118, 128, .36);
    --label: #F5F5F7;
    --label-2: rgba(235, 235, 245, .62);
    --label-3: rgba(235, 235, 245, .3);
    --sep: rgba(84, 84, 88, .5);
    --sep-strong: rgba(84, 84, 88, .85);
    --blue: #0A84FF;
    --blue-hover: #409CFF;
    --ok: #30D158;
    --ok-dot: #30D158;
    --warn: #FF9F0A;
    --warn-bg: rgba(255, 159, 10, .16);
    --bad: #FF453A;
    --bad-bg: rgba(255, 69, 58, .16);
    --scan: #FF453A;
    --glass: rgba(44, 44, 46, .58);
    --glass-edge: rgba(255, 255, 255, .08);
    --shadow: 0 0 0 .5px rgba(255, 255, 255, .06), 0 1px 3px rgba(0, 0, 0, .3);
    --shadow-float: 0 0 0 .5px rgba(255, 255, 255, .08), 0 10px 40px rgba(0, 0, 0, .45);
    --tint-a: rgba(10, 132, 255, .12);
    --tint-b: rgba(191, 90, 242, .08);
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--label);
  font: 400 14px/1.45 var(--font);
  -webkit-font-smoothing: antialiased;
  background:
    radial-gradient(1100px 600px at 0% 0%, var(--tint-a), transparent 65%),
    radial-gradient(900px 520px at 100% 0%, var(--tint-b), transparent 60%),
    var(--window);
  background-attachment: fixed;
}
h1, h2, p { margin: 0; }
a { color: var(--blue); }
button, input, textarea, select { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid color-mix(in srgb, var(--blue) 45%, transparent); outline-offset: 1px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mono { font-family: var(--mono); font-size: 12.5px; }
.muted { color: var(--label-2); }

/* ---------- knoppen en velden ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  height: 32px; padding: 0 14px; border: 0; border-radius: 8px;
  background: var(--fill); color: var(--label);
  font-size: 13.5px; font-weight: 500; text-decoration: none; white-space: nowrap;
  cursor: pointer; transition: background-color .15s;
}
.btn:hover:not(:disabled) { background: var(--fill-strong); }
.btn:active:not(:disabled) { transform: scale(.98); }
.btn:disabled { opacity: .4; cursor: default; }
.btn-primary { background: var(--blue); color: #FFFFFF; }
.btn-primary:hover:not(:disabled) { background: var(--blue-hover); }
.btn-danger { color: var(--bad); }
.btn-lg { height: 52px; padding: 0 26px; border-radius: 14px; font-size: 15px; font-weight: 600; }
.btn-block { width: 100%; }
.link-btn { padding: 0; border: 0; background: none; color: var(--blue); font-size: 13px; cursor: pointer; }
.link-btn:hover { text-decoration: underline; }

input:not([type=checkbox]):not([type=file]), select, textarea {
  height: 32px; padding: 0 10px;
  border: .5px solid var(--sep-strong); border-radius: 8px;
  background: var(--surface); color: var(--label);
  box-shadow: 0 .5px 1px rgba(0, 0, 0, .04);
  transition: box-shadow .15s, border-color .15s;
}
textarea { width: 100%; height: auto; padding: 12px 14px; resize: vertical; font: 12.5px/1.6 var(--mono); tab-size: 20; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3.5px color-mix(in srgb, var(--blue) 28%, transparent); }
input::placeholder, textarea::placeholder { color: var(--label-3); }
input[type=checkbox] { width: 16px; height: 16px; margin: 0; accent-color: var(--blue); }

/* ---------- app-icoon ---------- */
.app-icon {
  display: grid; place-items: center; flex: none;
  width: 30px; height: 30px; border-radius: 8px;
  background: linear-gradient(165deg, #4DA3FF 0%, #0A6CFF 55%, #0052D4 100%);
  box-shadow: inset 0 0 0 .5px rgba(255, 255, 255, .25), 0 1px 2px rgba(0, 0, 0, .18);
}
.app-icon svg { width: 17px; height: 11px; fill: #FFFFFF; }
.app-icon-lg { width: 72px; height: 72px; border-radius: 17px; box-shadow: inset 0 0 0 .5px rgba(255, 255, 255, .25), 0 6px 18px rgba(0, 82, 212, .28); }
.app-icon-lg svg { width: 38px; height: 25px; }

/* ---------- login ---------- */
.login { min-height: 100vh; display: grid; place-items: center; padding: 24px; }
.login-card {
  width: min(360px, 100%); display: grid; justify-items: center; gap: 10px;
  padding: 36px 28px 28px; border-radius: 22px;
  background: var(--glass); border: 1px solid var(--glass-edge);
  backdrop-filter: blur(40px) saturate(180%); -webkit-backdrop-filter: blur(40px) saturate(180%);
  box-shadow: var(--shadow-float);
}
.login-title { margin-top: 8px; font: 700 22px/1.2 var(--font-display); letter-spacing: -.02em; }
.login-sub { margin-bottom: 10px; color: var(--label-2); font-size: 13.5px; text-align: center; }
.login-card input { width: 100%; height: 40px !important; border-radius: 10px !important; font-size: 15px; }
.login-card .btn { height: 40px; border-radius: 10px; font-size: 15px; margin-top: 4px; }
.form-error { color: var(--bad); font-size: 13px; text-align: center; }

/* ---------- indeling: zwevende zijbalk van glas ---------- */
.shell { display: grid; grid-template-columns: 252px minmax(0, 1fr); min-height: 100vh; }
.sidebar {
  position: sticky; top: 10px; height: calc(100vh - 20px); margin: 10px 0 10px 10px;
  display: flex; flex-direction: column; gap: 18px; padding: 14px 10px 12px;
  border-radius: 20px; border: 1px solid var(--glass-edge);
  background: var(--glass);
  backdrop-filter: blur(40px) saturate(180%); -webkit-backdrop-filter: blur(40px) saturate(180%);
  box-shadow: var(--shadow-float);
}
.app-id { display: flex; align-items: center; gap: 10px; padding: 4px 8px; color: var(--label); text-decoration: none; }
.app-name { font: 650 15px var(--font-display); letter-spacing: -.01em; }
.nav { display: grid; gap: 2px; }
.nav a {
  display: flex; align-items: center; gap: 10px; height: 36px; padding: 0 8px;
  border-radius: 10px; color: var(--label); text-decoration: none; font-size: 14px; font-weight: 500;
}
.nav a:hover { background: var(--fill); }
.nav a[aria-current=page] { background: var(--blue); color: #FFFFFF; }
.ico { display: grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 7px; color: #FFFFFF; box-shadow: inset 0 0 0 .5px rgba(0, 0, 0, .06); }
.ico svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 2.3; stroke-linecap: round; stroke-linejoin: round; }
.ico-blue { background: linear-gradient(180deg, #47A1FF, #007AFF); }
.ico-orange { background: linear-gradient(180deg, #FFB340, #FF9500); }
.ico-purple { background: linear-gradient(180deg, #CC73F0, #AF52DE); }
.ico-gray { background: linear-gradient(180deg, #A9A9AE, #8E8E93); }
.nav-badge { margin-left: auto; padding: 1px 8px; border-radius: 99px; background: var(--fill-strong); font-size: 11.5px; font-weight: 600; font-variant-numeric: tabular-nums; }
.nav a[aria-current=page] .nav-badge { background: rgba(255, 255, 255, .25); }
.sidebar-foot { margin-top: auto; display: grid; justify-items: start; gap: 6px; padding: 8px; }
.model { font: 11.5px var(--mono); color: var(--label-2); }
.role { font-size: 12px; font-weight: 600; color: var(--label); }

/* ---------- pagina ---------- */
.page { width: 100%; max-width: 1060px; justify-self: center; min-width: 0; padding: 40px 44px 96px; }
.view { display: grid; gap: 22px; }
.view > * { min-width: 0; }
h1 { font: 700 30px/1.12 var(--font-display); letter-spacing: -.025em; }
.view-head p { margin-top: 6px; max-width: 64ch; color: var(--label-2); font-size: 14px; }
.toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.toolbar-note { margin-left: 4px; color: var(--label-2); font-size: 13px; font-variant-numeric: tabular-nums; }
.alert { margin-bottom: 22px; padding: 12px 16px; border-radius: 12px; background: var(--warn-bg); color: var(--warn); font-size: 13.5px; }
.alert ul { margin: 4px 0 0; padding-left: 18px; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--blue); font-size: 14px; text-decoration: none; }
.back::before { content: ''; width: 8px; height: 8px; border-left: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); margin-right: 2px; }
.back:hover { text-decoration: underline; }
.empty-state { padding: 28px 4px; color: var(--label-2); }

/* ---------- zoekveld (Spotlight) ---------- */
.search-row { display: flex; gap: 10px; }
.search-field { position: relative; flex: 1; min-width: 0; }
.search-icon { position: absolute; left: 16px; top: 50%; width: 20px; height: 20px; transform: translateY(-50%); fill: none; stroke: var(--label-3); stroke-width: 2.2; stroke-linecap: round; pointer-events: none; }
.search-field input {
  width: 100%; height: 52px !important; padding: 0 140px 0 46px !important;
  border-radius: 14px !important; font-size: 18px; font-variant-numeric: tabular-nums; letter-spacing: .01em;
  box-shadow: var(--shadow) !important; border-color: var(--sep) !important;
}
.search-field input:focus { border-color: var(--blue) !important; box-shadow: 0 0 0 4px color-mix(in srgb, var(--blue) 25%, transparent), var(--shadow) !important; }
.search-code {
  position: absolute; top: 12px; right: 16px; bottom: 12px; width: 104px;
  display: flex; align-items: center; justify-content: flex-end;
  color: var(--label); pointer-events: none;
}
.search-code svg { display: block; width: 100%; height: 100%; fill: currentColor; }
.search-code .url-pill { max-width: 104px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 3px 10px; border-radius: 99px; background: var(--fill); color: var(--label-2); font-size: 12px; }
.search-code.is-scanning::after {
  content: ''; position: absolute; left: -4px; right: -4px; top: 0; height: 2px; border-radius: 2px;
  background: var(--scan); box-shadow: 0 0 8px var(--scan);
  animation: sweep 1.3s ease-in-out infinite alternate;
}
@keyframes sweep { from { top: 0; } to { top: calc(100% - 2px); } }
.search-hint { margin: 8px 0 0 4px; color: var(--label-2); font-size: 12.5px; }
.search-hint.is-bad { color: var(--bad); }
.filter-field { position: relative; }
.filter-field .search-icon { left: 10px; width: 15px; height: 15px; }
.filter { width: min(320px, 100%); padding-left: 32px !important; }

/* ---------- voortgang ---------- */
.run { display: grid; gap: 14px; padding: 18px 20px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); }
.run-head { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; }
.run-title { font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.run-time { color: var(--label-2); font-variant-numeric: tabular-nums; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.steps > li { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 10px; color: var(--label-3); }
.st { position: relative; width: 18px; height: 18px; margin-top: 1px; border-radius: 50%; border: 1.5px solid var(--sep-strong); }
.steps > li.is-active { color: var(--label); font-weight: 600; }
.steps > li.is-active .st { border-color: var(--fill-strong); border-top-color: var(--blue); animation: spin .8s linear infinite; }
.steps > li.is-done { color: var(--label-2); }
.steps > li.is-done .st { border: 0; background: var(--ok-dot); }
.steps > li.is-done .st::after { content: ''; position: absolute; left: 6.5px; top: 3.5px; width: 4px; height: 8px; border: solid #FFFFFF; border-width: 0 2px 2px 0; transform: rotate(45deg); }
@keyframes spin { to { transform: rotate(360deg); } }
.log { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 3px; font-weight: 400; color: var(--label); font-size: 13px; }
.log:empty { display: none; }
.log span { color: var(--label-2); }
.run-note { color: var(--label-2); font-size: 13px; }
.run-error { padding: 12px 16px; border-radius: 12px; background: var(--bad-bg); color: var(--bad); font-size: 13.5px; }

/* ---------- resultaat ---------- */
.result { display: grid; gap: 26px; }
.result-head {
  display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 28px;
  padding: 22px 24px; border-radius: 16px; background: var(--surface); box-shadow: var(--shadow);
}
.result-ean { color: var(--label-2); font-size: 13px; font-variant-numeric: tabular-nums; }
.result-name { margin-top: 2px; font: 700 26px/1.18 var(--font-display); letter-spacing: -.022em; overflow-wrap: anywhere; }
.result-code { width: 150px; padding: 8px 10px 6px; border-radius: 10px; background: #FFFFFF; color: #000000; box-shadow: inset 0 0 0 .5px rgba(0, 0, 0, .1); }
.result-code svg { display: block; width: 100%; height: auto; fill: currentColor; }
.stats { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 6px; }
.stats span { padding: 4px 10px; border-radius: 99px; background: var(--fill); color: var(--label-2); font-size: 12.5px; font-variant-numeric: tabular-nums; }
.stats b { color: var(--label); font-weight: 600; }
.stats .is-warn, .stats .is-warn b { background: var(--warn-bg); color: var(--warn); }
.result-actions { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 8px; padding-top: 16px; border-top: .5px solid var(--sep); }
.result > .alert { margin: 0; }

.section { display: grid; gap: 10px; min-width: 0; }
.section h2 { padding-left: 4px; font: 600 17px/1.3 var(--font-display); letter-spacing: -.012em; }
.section > p { max-width: 75ch; padding-left: 4px; }
.section > p.plain { padding: 16px 18px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); }

/* Groep: afgeronde witte container met ingesprongen scheidingslijnen */
.section > .scroll, .list {
  overflow-x: auto; padding: 0 18px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow);
}
.tbl { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.tbl th {
  padding: 12px 16px 9px 0; border-bottom: .5px solid var(--sep);
  color: var(--label-2); font-size: 12px; font-weight: 600; text-align: left; white-space: nowrap;
}
.tbl td { padding: 11px 16px 11px 0; border-bottom: .5px solid var(--sep); vertical-align: top; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl th:last-child, .tbl td:last-child { padding-right: 0; }
.tbl .attr { width: 1%; white-space: nowrap; color: var(--label-2); font: 12.5px/1.6 var(--mono); }
.tbl .val { font-weight: 600; overflow-wrap: anywhere; }
.tbl .why { color: var(--label-2); font-size: 13px; }
.tbl .fit { width: 1%; white-space: nowrap; }
.tbl a { color: var(--blue); text-decoration: none; overflow-wrap: anywhere; }
.tbl a:hover { text-decoration: underline; }
.tbl .sub { display: block; color: var(--label-2); font-size: 12px; }
.tbl .empty { color: var(--label-3); }
.flag { display: inline-block; margin-top: 4px; padding: 1px 8px; border-radius: 99px; background: var(--warn-bg); color: var(--warn); font: 600 11.5px var(--font); }
.cmp-note { display: block; min-width: 160px; margin-top: 4px; color: var(--label-2); font: 12px/1.45 var(--font); white-space: normal; }
.tbl-cmp tr.is-conflict td:not(:first-child) { color: var(--warn); font-weight: 600; }
.remarks-wrap { padding-left: 4px; font-size: 13.5px; }
.remarks-wrap ul { margin: 4px 0 0; padding-left: 18px; color: var(--label-2); }

.dot { display: inline-flex; align-items: center; gap: 6px; color: var(--label-2); font-size: 12.5px; white-space: nowrap; }
.dot::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--label-3); }
.dot-ok::before { background: var(--ok-dot); }
.dot-bad { color: var(--bad); }
.dot-bad::before { background: var(--scan); }
.dot-warn { color: var(--warn); }
.dot-warn::before { background: #FF9500; }
.dots { display: grid; gap: 3px; }

.audit { padding: 12px 16px; border-radius: 12px; background: var(--fill); color: var(--label-2); font-size: 13px; }
.audit summary { color: var(--label); font-weight: 600; cursor: pointer; }
.audit[open] summary { margin-bottom: 10px; }
.audit ul { margin: 0 0 10px; padding-left: 18px; display: grid; gap: 3px; }
.audit p + p { margin-top: 4px; }

/* ---------- batch en geschiedenis ---------- */
.batch-input { min-height: 140px; border-radius: 14px !important; box-shadow: var(--shadow) !important; border-color: var(--sep) !important; }
.list .tbl tbody tr.is-link { cursor: pointer; }
.list .tbl tbody tr.is-link:hover td { background: color-mix(in srgb, var(--blue) 6%, transparent); }
.num { width: 1%; white-space: nowrap; color: var(--label-2); font-variant-numeric: tabular-nums; }
.check { width: 1%; }
.status { font-weight: 600; white-space: nowrap; }
.status-wait, .status-skip { color: var(--label-3); }
.status-run { color: var(--blue); }
.status-done { color: var(--ok); }
.status-fail { color: var(--bad); }

/* ---------- instellingenlijsten ---------- */
.prefs { display: grid; gap: 28px; }
.pref { display: grid; gap: 8px; min-width: 0; }
.pref h2 { padding-left: 4px; font: 600 17px/1.3 var(--font-display); letter-spacing: -.012em; }
.pref-note { padding-left: 4px; color: var(--label-2); font-size: 13px; max-width: 75ch; }
.group { border-radius: 14px; background: var(--surface); box-shadow: var(--shadow); overflow: hidden; }
.pref-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 52px; margin: 0 18px; padding: 12px 0; border-bottom: .5px solid var(--sep); }
.pref-row:last-child { border-bottom: 0; }
.pref-label { display: grid; gap: 2px; min-width: 0; }
.pref-label label { font-weight: 500; }
.pref-label .help { color: var(--label-2); font-size: 12.5px; }
.pref-row select { width: min(280px, 100%); }
.pref-row input[type=number] { width: 90px; text-align: right; font-variant-numeric: tabular-nums; }
.pref-row input[type=password] { width: min(280px, 100%); }
.pw-pair { display: flex; gap: 8px; }
.pw-pair input[type=password] { width: 180px; }
.row-title { font-weight: 500; }
.row-value { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.usage { display: grid; justify-items: end; gap: 6px; }
.meter { display: block; width: 160px; height: 6px; border-radius: 3px; background: var(--fill); overflow: hidden; }
.meter > span { display: block; height: 100%; border-radius: 3px; background: var(--blue); }
.meter.is-warn > span { background: #FF9500; }
.meter.is-over > span { background: var(--scan); }
.group textarea { display: block; border: 0 !important; border-radius: 0 !important; box-shadow: none !important; background: transparent; }
.group textarea:focus { box-shadow: inset 0 0 0 2px color-mix(in srgb, var(--blue) 40%, transparent) !important; border-radius: 14px !important; }
.toolbar-end { justify-content: flex-end; }
.spec-stats { display: flex; flex-wrap: wrap; gap: 6px; padding-left: 4px; }
.spec-stats span { padding: 3px 10px; border-radius: 99px; background: var(--fill); color: var(--label-2); font-size: 12.5px; }
.spec-stats b { color: var(--label); font-weight: 600; }
.test-result { color: var(--label-2); font-size: 13px; }
.test-result.is-ok { color: var(--ok); }
.test-result.is-bad { color: var(--bad); }

/* ---------- melding (zoals een macOS-notificatie) ---------- */
.toast {
  position: fixed; top: 16px; right: 16px; z-index: 30; max-width: min(380px, calc(100vw - 32px));
  padding: 12px 16px; border-radius: 14px; border: 1px solid var(--glass-edge);
  background: var(--glass); color: var(--label); font-size: 13.5px;
  backdrop-filter: blur(40px) saturate(180%); -webkit-backdrop-filter: blur(40px) saturate(180%);
  box-shadow: var(--shadow-float);
  animation: drop .25s ease-out;
}
.toast.is-bad { color: var(--bad); font-weight: 600; }
@keyframes drop { from { opacity: 0; transform: translateY(-8px); } }

@media (prefers-reduced-motion: reduce) {
  .search-code.is-scanning::after { animation: none; top: 50%; }
  .steps > li.is-active .st { animation: none; border-color: var(--blue); }
  .toast { animation: none; }
  .btn:active:not(:disabled) { transform: none; }
}

/* ---------- smal scherm: tabbalk onderaan zoals op iPhone ---------- */
@media (max-width: 760px) {
  .shell { grid-template-columns: minmax(0, 1fr); grid-template-rows: auto 1fr; }
  .sidebar {
    position: static; height: auto; margin: 0; padding: 12px 16px 0;
    flex-direction: row; align-items: center; justify-content: space-between;
    border: 0; border-radius: 0; background: none; box-shadow: none;
    backdrop-filter: none; -webkit-backdrop-filter: none;
  }
  .sidebar-foot { margin: 0; padding: 0; }
  .model { display: none; }
  .nav {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 20;
    grid-auto-flow: column; grid-auto-columns: 1fr; gap: 0;
    padding: 6px 8px calc(6px + env(safe-area-inset-bottom, 0px));
    border-top: .5px solid var(--sep);
    background: var(--glass);
    backdrop-filter: blur(30px) saturate(180%); -webkit-backdrop-filter: blur(30px) saturate(180%);
  }
  .nav a { flex-direction: column; justify-content: center; gap: 2px; height: 50px; padding: 0; border-radius: 10px; color: var(--label-2); font-size: 10.5px; }
  .nav a:hover, .nav a[aria-current=page] { background: none; }
  .nav a[aria-current=page] { color: var(--blue); }
  .ico { width: 26px; height: 26px; background: none !important; box-shadow: none; color: inherit; }
  .ico svg { width: 23px; height: 23px; stroke-width: 1.9; }
  .nav-badge { display: none; }
  .page { padding: 20px 16px calc(96px + env(safe-area-inset-bottom, 0px)); }
  h1 { font-size: 28px; }
  .search-row { flex-direction: column; }
  .search-field input { padding-right: 100px !important; font-size: 16px; }
  .search-code { width: 76px; }
  .result-head { grid-template-columns: minmax(0, 1fr); padding: 18px; }
  .result-name { font-size: 22px; }
  .result-code { width: 140px; }
  .section > .scroll, .list { padding: 0 14px; }
  .scroll > .tbl { min-width: 600px; }
  .pref-row { flex-direction: column; align-items: stretch; margin: 0 14px; }
  .pref-row select, .pref-row input[type=number], .pref-row input[type=password] { width: 100%; text-align: left; }
  .pw-pair { flex-direction: column; }
  .pw-pair input[type=password] { width: 100%; }
  .usage { justify-items: start; }
  .role { display: none; }
  .toast { left: 12px; right: 12px; top: 12px; max-width: none; }
}

/* ---------- schakelaar (zoals in macOS) ---------- */
input[type=checkbox].switch {
  appearance: none; -webkit-appearance: none; flex: none; position: relative;
  width: 40px; height: 24px; margin: 0; border-radius: 99px;
  background: var(--fill-strong); cursor: pointer; transition: background-color .2s;
}
input[type=checkbox].switch::before {
  content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%;
  background: #FFFFFF; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .2s;
}
input[type=checkbox].switch:checked { background: var(--ok-dot); }
input[type=checkbox].switch:checked::before { transform: translateX(16px); }
input[type=checkbox].switch:disabled { opacity: .4; cursor: default; }
@media (prefers-reduced-motion: reduce) { input[type=checkbox].switch, input[type=checkbox].switch::before { transition: none; } }
@media (max-width: 760px) { .pref-row input[type=checkbox].switch { align-self: flex-start; } }
