:root {
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 18px;
  --brand: #333365;
  --brand-dark: #242447;
  --brand-soft: #e8e8f2;
  --accent: #326b72;
  --accent-soft: #e6f0f0;
  --background: #eef3f3;
  --surface: #ffffff;
  --surface-soft: #f6f8f8;
  --text: #1f2933;
  --muted: #52606d;
  --border: #b8c7ca;
  --field-border: #717d8a;
  --success: #176b3a;
  --success-bg: #e7f5ec;
  --warning: #7a4100;
  --warning-bg: #fff1c9;
  --danger: #a11b16;
  --danger-bg: #fdecea;
  --info: #1e5a86;
  --info-bg: #e8f1f8;
  --focus: #005fcc;
  --radius: 10px;
}

/* Definitieve Hub-uitbreidingen */
html { color-scheme: light !important; }
.sidebar nav button b { width: 24px; text-align: center; color: var(--brand); font-size: 20px; }
.launch-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.launch-tile { position: relative; min-height: 220px; padding: 22px; display: grid; grid-template-columns: 54px 1fr; grid-template-rows: 1fr auto; gap: 14px 16px; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; box-shadow: 0 8px 24px rgba(36,36,71,.06); }
.launch-tile > .app-state { position: absolute; top: 14px; right: 14px; }
.launch-tile > div:nth-of-type(2) { padding-top: 30px; }
.launch-tile h3 { margin: 0 0 7px; font-size: 20px; }
.launch-tile p { margin: 0 0 10px; color: var(--muted); line-height: 1.5; }
.launch-tile small { display: block; color: var(--muted); }
.launch-tile > .button { grid-column: 1 / -1; justify-self: start; }
.launch-tile.is-disabled { background: #f6f8f8; }
.row-actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.data-table td small { display: block; margin-top: 4px; color: var(--muted); overflow-wrap: anywhere; }
.device-facts { display: grid; gap: 6px; padding: 12px; border-radius: 8px; background: var(--surface-soft); color: var(--muted); overflow-wrap: anywhere; }
.form-error { color: var(--danger); font-weight: 700; }
.modal form { display: grid; gap: 15px; }
.modal textarea { min-height: 82px; }
.button[disabled] { opacity: .55; cursor: not-allowed; }
.inline-form { display: grid; grid-template-columns: repeat(4,minmax(150px,1fr)) auto; gap: 12px; align-items: end; }
.inline-form label { min-width: 0; }
.inline-form input,.inline-form select { width: 100%; }
.release-history { margin-top: 20px; }

@media (max-width: 850px) {
  .launch-grid { grid-template-columns: 1fr; }
  .inline-form { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 620px) {
  .launch-tile { grid-template-columns: 46px 1fr; padding: 18px; }
  .launch-tile > div:nth-of-type(2) { padding-top: 38px; }
  .topbar .admin-user div { display: none; }
  .inline-form { grid-template-columns: 1fr; }
}

* { box-sizing: border-box; }
html { background: var(--background); }
body { margin: 0; min-width: 320px; color: var(--text); background: var(--background); line-height: 1.48; }
button, input, select, textarea { font: inherit; }
button, input, select { min-height: 48px; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, a:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
button:disabled { cursor: not-allowed; color: #5d6870; background: #e5eaeb; border-color: #9ba8ac; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: .35rem; color: #172832; font-size: 1.78rem; line-height: 1.18; }
h2 { margin-bottom: .35rem; font-size: 1.25rem; line-height: 1.25; }
h3 { margin-bottom: .25rem; font-size: 1rem; line-height: 1.3; }
p { margin-bottom: 0; color: var(--muted); }
img { display: block; max-width: 100%; }
.skip-link { position: fixed; z-index: 1000; left: 1rem; top: -100px; padding: .7rem 1rem; color: #fff; background: var(--brand); }
.skip-link:focus { top: 1rem; }
.icon { width: 24px; height: 24px; flex: 0 0 24px; }

.hub-shell { min-height: 100vh; display: grid; grid-template-columns: 250px 1fr; }
.sidebar { position: sticky; top: 0; min-height: 100vh; height: 100vh; display: flex; flex-direction: column; padding: 1.1rem .8rem; color: var(--text); background: var(--surface); border-right: 1px solid var(--border); }
.sidebar-brand { min-height: 92px; display: flex; align-items: center; gap: .7rem; padding: .45rem .55rem 1rem; color: var(--brand); text-decoration: none; border-bottom: 1px solid var(--border); }
.sidebar-brand img { width: 155px; padding: .2rem; }
.sidebar-brand span { font-size: 1.1rem; font-weight: 800; }
.sidebar nav { display: grid; gap: .35rem; padding-top: 1.05rem; }
.sidebar nav button { width: 100%; min-height: 54px; display: flex; align-items: center; gap: .75rem; padding: .68rem .8rem; color: var(--text); text-align: left; border: 1px solid transparent; border-radius: 8px; background: transparent; }
.sidebar nav button .icon { display: none; }
.sidebar nav button:hover { color: var(--brand); background: var(--surface-soft); }
.sidebar nav button.active { color: var(--brand); background: var(--accent-soft); border-color: transparent; box-shadow: inset 4px 0 0 var(--brand); font-weight: 800; }
.sidebar-foot { display: grid; gap: .15rem; margin-top: auto; padding: 1rem .8rem .35rem; border-top: 1px solid var(--border); }
.sidebar-foot span { color: var(--muted); font-size: .89rem; }
.sidebar-foot strong { font-size: .89rem; }
.hub-main { min-width: 0; }
.topbar { min-height: 78px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .7rem 1.6rem; background: var(--surface); border-bottom: 1px solid var(--border); }
.topbar > div:first-child { display: grid; }
.topbar > div:first-child span { color: var(--muted); font-size: .89rem; }
.topbar-actions { display: flex; align-items: center; gap: .65rem; }
.text-button { min-height: 48px; display: inline-flex; align-items: center; gap: .45rem; padding: .5rem .7rem; color: var(--text); border: 1px solid transparent; border-radius: 8px; background: transparent; }
.text-button:hover { border-color: var(--border); background: var(--surface-soft); }
.admin-user { display: flex; align-items: center; gap: .55rem; padding: 0 .65rem; border-left: 1px solid var(--border); border-right: 1px solid var(--border); }
.admin-user > div { display: grid; }
.admin-user span:last-child { color: var(--muted); font-size: .89rem; }
.avatar, .large-avatar { display: grid; place-items: center; border-radius: 50%; color: #fff; background: var(--brand); font-weight: 800; }
.avatar { width: 44px; height: 44px; }
.large-avatar { width: 62px; height: 62px; font-size: 1.15rem; }
.content { max-width: 1420px; min-height: calc(100vh - 78px); margin: 0 auto; padding: 1.6rem 2rem 4rem; }

.page-header { display: flex; align-items: end; justify-content: space-between; gap: 2rem; padding-bottom: 1.15rem; border-bottom: 1px solid var(--border); }
.page-header p { max-width: 780px; }
.page-action { flex: 0 0 auto; }
.breadcrumb { min-height: 26px; margin-bottom: .25rem; color: var(--accent); font-size: .89rem; font-weight: 700; }
.crumb-link { min-height: auto; padding: 0; color: var(--accent); border: 0; background: transparent; text-decoration: underline; }
.button { min-height: 48px; display: inline-flex; align-items: center; justify-content: center; padding: .6rem .9rem; color: var(--text); border: 1px solid var(--border); border-radius: 8px; background: var(--surface); font-weight: 750; }
.button:hover { background: #f1f4f4; border-color: #809296; }
.button.primary { color: #fff; border-color: var(--brand); background: var(--brand); }
.button.primary:hover { background: var(--brand-dark); }
.danger-button { color: #fff; border-color: var(--danger); background: var(--danger); }
.danger-button:hover { color: #fff; border-color: #7e1511; background: #7e1511; }

.calm-summary { display: grid; grid-template-columns: repeat(4, 1fr); margin: 1.25rem 0; background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.calm-summary > div { min-height: 88px; display: flex; align-items: center; gap: .65rem; padding: .85rem 1rem; border-right: 1px solid var(--border); }
.calm-summary > div:last-child { border-right: 0; }
.calm-summary strong { color: var(--brand); font-size: 1.55rem; }
.calm-summary span:not(.status):not(.status > span) { color: var(--muted); }
.section-block { margin-top: 1.2rem; padding: 1.15rem; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.quiet-section { background: #f8fafa; }
.section-heading { min-height: 54px; display: flex; align-items: start; justify-content: space-between; gap: 1rem; margin-bottom: .85rem; padding-bottom: .8rem; border-bottom: 1px solid var(--border); }
.attention-list, .app-list, .module-list, .integration-list, .access-list { display: grid; gap: .65rem; }
.attention-row, .app-row, .module-row, .integration-row, .access-list article { min-height: 82px; display: grid; grid-template-columns: auto minmax(260px,1fr) auto auto; align-items: center; gap: 1rem; padding: .8rem; border: 1px solid var(--border); border-radius: 8px; background: var(--surface); }
.attention-row.warning { border-left: 6px solid #ba7419; }
.attention-symbol { width: 44px; height: 44px; display: grid; place-items: center; color: var(--accent); border-radius: 7px; background: var(--accent-soft); font-weight: 900; }
.history-list { display: grid; }
.history-list > div { min-height: 54px; display: grid; grid-template-columns: 165px 1fr; align-items: center; gap: 1rem; border-bottom: 1px solid #d7e0e2; }
.history-list > div:last-child { border-bottom: 0; }
.history-list time { color: var(--muted); }
.status { min-height: 34px; display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .65rem; border-radius: 999px; white-space: nowrap; font-size: .89rem; font-weight: 800; }
.status > span { width: 20px; height: 20px; display: grid; place-items: center; border-radius: 50%; border: 1px solid currentColor; font-size: .78rem; line-height: 1; }
.status-good { color: var(--success); background: var(--success-bg); }
.status-warning { color: var(--warning); background: var(--warning-bg); }
.status-bad { color: var(--danger); background: var(--danger-bg); }
.status-neutral { color: var(--info); background: var(--info-bg); }
.app-mark { width: 52px; height: 52px; display: grid; place-items: center; border-radius: 8px; color: #fff; background: var(--brand); font-weight: 850; }
.app-mark.large { width: 62px; height: 62px; font-size: 1.05rem; }
.row-meta, .cell-sub, .field-label { display: block; margin-top: .18rem; color: var(--muted); font-size: .89rem; }
.identity-banner { min-height: 92px; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 1rem; margin: 1.15rem 0 0; padding: .85rem 1rem; border: 1px solid var(--border); border-left: 6px solid var(--brand); background: var(--surface); }
.identity-banner h2 { margin-bottom: .15rem; }
.tabs { display: flex; overflow-x: auto; gap: .2rem; margin-top: 1rem; border-bottom: 1px solid var(--border); }
.tabs button { min-height: 50px; flex: 0 0 auto; padding: .65rem .9rem; color: var(--muted); border: 0; border-bottom: 4px solid transparent; background: transparent; }
.tabs button.active { color: var(--brand); border-bottom-color: var(--brand); font-weight: 800; }
.split-layout { display: grid; grid-template-columns: 1.45fr 1fr; gap: 1rem; }
.plain-list { display: grid; }
.plain-list > div { min-height: 68px; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .7rem 0; border-bottom: 1px solid #d7e0e2; }
.plain-list > div:last-child { border-bottom: 0; }
.plain-list > div > div { display: grid; }
.plain-list span { color: var(--muted); }
.detail-list { margin: 0; }
.detail-list > div { min-height: 54px; display: grid; grid-template-columns: 180px 1fr; align-items: center; gap: .75rem; border-bottom: 1px solid #d7e0e2; }
.detail-list > div:last-child { border-bottom: 0; }
.detail-list dt { color: var(--muted); }
.detail-list dd { margin: 0; font-weight: 750; }
.access-list article { grid-template-columns: minmax(280px,1fr) auto auto; }
.module-row { grid-template-columns: minmax(300px,1.35fr) minmax(190px,.8fr) auto auto; }
.integration-row { grid-template-columns: auto minmax(300px,1fr) auto auto; }
.fine-print { margin-top: .75rem; font-size: .89rem; }

.toolbar { display: flex; align-items: end; flex-wrap: wrap; gap: .7rem; margin-bottom: 1rem; }
.toolbar label, .form-section label, .modal label { display: grid; gap: .3rem; color: var(--text); font-weight: 700; }
.toolbar label { min-width: 220px; }
input, select, textarea { width: 100%; padding: .62rem .72rem; color: var(--text); border: 1px solid var(--field-border); border-radius: 7px; background: var(--surface); }
textarea { min-height: 100px; resize: vertical; }
.data-table { width: 100%; border-collapse: collapse; }
.data-table th, .data-table td { min-height: 56px; padding: .72rem .7rem; text-align: left; border-bottom: 1px solid #d2dcde; vertical-align: middle; }
.data-table th { color: var(--muted); background: var(--surface-soft); font-size: .89rem; }
.data-table tbody tr:hover { background: #f8fafa; }
.data-table .button { min-height: 44px; }

.permission-list { display: grid; }
.permission-item { min-height: 68px; display: grid; grid-template-columns: auto 1fr 220px; align-items: center; gap: .8rem; padding: .65rem 0; border-bottom: 1px solid #d7e0e2; }
.permission-item:last-child { border-bottom: 0; }
.permission-item input { width: 24px; min-height: 24px; height: 24px; }
.permission-item:not(.editing) input { visibility: hidden; }
.permission-item > span { display: grid; }
.permission-item > span span, .permission-item small { color: var(--muted); font-size: .89rem; }
.permission-item small { text-align: right; }
.exception { display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: 1rem; }
.save-bar { position: sticky; bottom: 1rem; z-index: 10; min-height: 78px; display: grid; grid-template-columns: 1fr auto auto; align-items: center; gap: .75rem; margin-top: 1rem; padding: .75rem 1rem; color: #fff; background: var(--brand-dark); border-radius: 10px; }
.save-bar > div { display: grid; }
.save-bar > div span { color: #e8e9f2; font-size: .89rem; }
.save-bar .button:not(.primary) { color: #fff; border-color: #9da1ba; background: transparent; }
.save-bar .primary { color: var(--brand); border-color: #fff; background: #fff; }

.notice { display: grid; gap: .2rem; margin-top: 1rem; padding: .85rem 1rem; border-left: 6px solid var(--info); background: var(--info-bg); }
.notice span { color: #304d5e; }
.notice.warning { border-color: #ba7419; background: var(--warning-bg); }
.notice.danger { border-color: var(--danger); background: var(--danger-bg); }
.danger-zone { display: flex; align-items: center; justify-content: space-between; gap: 2rem; margin-top: 1.2rem; padding: 1rem; border: 1px solid #d8aaa7; border-left: 6px solid var(--danger); background: #fffafa; }
.stepper { display: grid; grid-template-columns: repeat(4,1fr); gap: .5rem; margin: 1.2rem 0; padding: 0; list-style: none; }
.stepper li { min-height: 68px; display: flex; align-items: center; gap: .6rem; padding: .65rem; color: var(--muted); border: 1px solid var(--border); background: var(--surface); }
.stepper li span { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; color: var(--muted); border: 1px solid var(--border); }
.stepper li.done span, .stepper li.active span { color: #fff; border-color: var(--brand); background: var(--brand); }
.stepper li.active { color: var(--brand); border: 3px solid var(--brand); }
.form-section { max-width: 760px; margin-top: 1rem; padding: 1.2rem; border: 1px solid var(--border); background: var(--surface); }
.form-section > label { margin-bottom: .85rem; }
.preview-box { display: grid; gap: .2rem; margin-top: 1rem; padding: .85rem; border-left: 5px solid var(--accent); background: var(--accent-soft); }
.form-actions { max-width: 760px; display: flex; align-items: center; justify-content: flex-end; gap: .7rem; padding-top: 1rem; }
.activation-code { display: grid; margin-right: auto; }
.activation-code span { color: var(--muted); font-size: .89rem; }
.activation-code strong { color: var(--brand); font-size: 1.2rem; letter-spacing: .05em; }

.update-summary { display: grid; grid-template-columns: 1fr 1fr 1.2fr; gap: 1rem; margin: 1rem 0; }
.update-summary > div { min-height: 92px; display: grid; align-content: center; gap: .2rem; padding: .8rem 1rem; border: 1px solid var(--border); }
.update-summary span, .update-summary small { color: var(--muted); }
.update-summary strong { color: var(--brand); font-size: 1.45rem; }
.safe-path { display: grid; gap: .55rem; padding: 0; list-style: none; }
.safe-path li { min-height: 70px; display: grid; grid-template-columns: auto 1fr; align-items: center; gap: .8rem; padding: .7rem; border-left: 4px solid var(--border); background: var(--surface-soft); }
.safe-path li > span { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 50%; border: 1px solid var(--border); }
.safe-path li.done { border-left-color: var(--success); }
.safe-path li.done > span { color: #fff; border-color: var(--success); background: var(--success); }
.safe-path li.active { border-left-color: var(--brand); background: var(--brand-soft); }
.safe-path li.active > span { color: #fff; border-color: var(--brand); background: var(--brand); }

.login-page { min-height: 100vh; display: grid; place-items: center; padding: 1rem; background: var(--background); }
.login-card { width: min(100%, 540px); padding: 2rem; border: 1px solid var(--border); border-top: 8px solid var(--brand); border-radius: 10px; background: var(--surface); }
.login-card > img { width: 260px; margin: 0 auto 1.6rem; }
.login-heading { text-align: center; }
.login-heading > span { color: var(--accent); font-weight: 750; }
.login-card form { display: grid; gap: .85rem; margin-top: 1.35rem; }
.login-card label { display: grid; gap: .3rem; font-weight: 700; }
.login-card .primary { width: 100%; margin-top: .35rem; }
.prototype-note { margin-top: 1rem; padding: .7rem; color: #41545e; background: var(--accent-soft); font-size: .89rem; }

.modal-backdrop { position: fixed; z-index: 100; inset: 0; display: grid; place-items: center; padding: 1rem; background: rgba(17,25,31,.55); }
.modal { width: min(100%, 650px); max-height: calc(100vh - 2rem); overflow: auto; padding: 1.2rem; border-top: 7px solid var(--brand); border-radius: 10px; background: var(--surface); }
.modal-head { display: flex; align-items: start; justify-content: space-between; gap: 1rem; }
.close-button { width: 48px; min-height: 48px; color: var(--text); border: 1px solid var(--border); background: var(--surface); font-size: 1.35rem; }
.modal label { margin-top: 1rem; }
.modal-actions { display: flex; justify-content: flex-end; gap: .7rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.modal-actions.three { justify-content: space-between; }
.form-error { margin-top: .4rem; color: var(--danger); font-weight: 800; }
.modal-steps { line-height: 1.7; }
.toast { position: fixed; z-index: 200; right: 1rem; bottom: 1rem; max-width: 460px; padding: .85rem 1rem; color: #fff; background: var(--brand-dark); border-left: 6px solid #7fb2b2; transform: translateY(140%); transition: transform .18s ease; }
.toast.visible { transform: translateY(0); }

@media (max-width: 1180px) {
  .hub-shell { grid-template-columns: 220px 1fr; }
  .content { padding-inline: 1.3rem; }
  .attention-row, .module-row, .integration-row { grid-template-columns: auto 1fr auto; }
  .attention-row > .button, .module-row > .button, .integration-row > .button { grid-column: 2 / -1; justify-self: start; }
  .module-row > div:nth-child(2) { display: none; }
  .split-layout { grid-template-columns: 1fr; }
}

@media (max-width: 880px) {
  .hub-shell { display: block; }
  .sidebar { position: static; min-height: auto; height: auto; padding: .7rem; }
  .sidebar-brand { min-height: 64px; padding: .25rem .4rem .65rem; }
  .sidebar-brand img { width: 145px; }
  .sidebar nav { grid-template-columns: repeat(3, 1fr); gap: .35rem; padding-top: .7rem; }
  .sidebar nav button { justify-content: center; min-height: 56px; }
  .sidebar-foot { display: none; }
  .topbar { min-height: 70px; }
  .topbar > div:first-child { display: none; }
  .topbar-actions { width: 100%; justify-content: flex-end; }
  .calm-summary { grid-template-columns: repeat(2, 1fr); }
  .calm-summary > div:nth-child(2) { border-right: 0; }
  .calm-summary > div:nth-child(-n+2) { border-bottom: 1px solid var(--border); }
  .stepper { grid-template-columns: repeat(2, 1fr); }
  .update-summary { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  :root { font-size: 18px; }
  .sidebar nav { grid-template-columns: repeat(2, 1fr); }
  .sidebar nav button { justify-content: flex-start; }
  .topbar { padding: .55rem 1rem; }
  .topbar-actions .text-button:first-child, .admin-user > div { display: none; }
  .content { padding: 1rem 1rem 5rem; }
  .page-header { align-items: stretch; flex-direction: column; gap: .8rem; }
  .page-action .button { width: 100%; }
  .calm-summary { grid-template-columns: 1fr; }
  .calm-summary > div { border-right: 0; border-bottom: 1px solid var(--border); }
  .calm-summary > div:last-child { border-bottom: 0; }
  .attention-row, .app-row, .module-row, .integration-row, .access-list article { grid-template-columns: auto 1fr; align-items: start; }
  .attention-row > .status, .app-row > .status, .module-row > .status, .integration-row > .status, .access-list article > .status { grid-column: 2; justify-self: start; }
  .attention-row > .button, .app-row > .button, .module-row > .button, .integration-row > .button, .access-list article > .button { grid-column: 2; width: 100%; }
  .history-list > div { grid-template-columns: 1fr; gap: .15rem; padding: .55rem 0; }
  .section-block { padding: .9rem; }
  .section-heading, .danger-zone { align-items: stretch; flex-direction: column; }
  .identity-banner { grid-template-columns: auto 1fr; }
  .identity-banner > .status { grid-column: 2; justify-self: start; }
  .permission-item { grid-template-columns: auto 1fr; }
  .permission-item small { grid-column: 2; text-align: left; }
  .exception { grid-template-columns: 1fr; }
  .save-bar { bottom: 0; grid-template-columns: 1fr 1fr; border-radius: 0; }
  .save-bar > div { grid-column: 1 / -1; }
  .save-bar .button { width: 100%; }
  .stepper { grid-template-columns: 1fr; }
  .form-actions { align-items: stretch; flex-direction: column; }
  .form-actions .button { width: 100%; }
  .activation-code { margin-right: 0; }
  .data-table, .data-table tbody, .data-table tr, .data-table td { display: block; width: 100%; }
  .data-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
  .data-table tr { margin-bottom: .75rem; padding: .65rem; border: 1px solid var(--border); }
  .data-table td { min-height: 44px; display: grid; grid-template-columns: 42% 1fr; align-items: center; gap: .6rem; padding: .45rem 0; border-bottom: 1px solid #d7e0e2; }
  .data-table td:last-child { border-bottom: 0; }
  .data-table td::before { content: attr(data-label); color: var(--muted); font-weight: 700; }
  .data-table .button { width: 100%; min-height: 48px; }
  .modal-actions, .modal-actions.three { align-items: stretch; flex-direction: column; }
  .modal-actions .button { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}

@media (forced-colors: active) {
  .status, .button, .sidebar nav button, .identity-banner, .section-block { border: 1px solid CanvasText; }
}


/* Precisie Klassiek v2 — compacte, rustige beheeromgeving */
:root { font-size: 16px; --radius: 8px; }
body { line-height: 1.42; }
h1 { font-size: 1.65rem; }
h2 { font-size: 1.12rem; }
button, input, select { min-height: 42px; }

.hub-shell { grid-template-columns: 212px minmax(0, 1fr); }
.sidebar { padding: 14px 10px; }
.sidebar-brand { min-height: 72px; gap: 8px; padding: 6px 8px 12px; }
.sidebar-brand img { width: 132px; padding: 0; }
.sidebar-brand span { font-size: 1rem; }
.sidebar nav { gap: 3px; padding-top: 12px; }
.sidebar nav button { min-height: 44px; gap: 10px; padding: 8px 11px; border-radius: 7px; }
.sidebar nav button b { width: 22px; font-size: .78rem; }
.sidebar-foot { padding: 12px 10px 4px; }

.topbar { min-height: 64px; padding: 8px 20px; }
.topbar-title { display: flex; align-items: center; gap: 10px; }
.topbar-title > div { display: grid; }
.topbar-title span, .admin-user span:last-child { font-size: .82rem; }
.avatar { width: 38px; height: 38px; }
.text-button { min-height: 42px; }
.content { max-width: 1180px; min-height: calc(100vh - 64px); padding: 24px 28px 48px; }
.page-header { align-items: center; gap: 18px; padding-bottom: 16px; }
.breadcrumb { min-height: 20px; margin-bottom: 2px; font-size: .8rem; }
.button { min-height: 42px; padding: 7px 12px; border-radius: 7px; }

.summary-strip, .compact-status-bar { display: grid; grid-template-columns: repeat(4, minmax(0,1fr)); margin: 16px 0; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.summary-strip > span, .compact-status-bar > span { min-height: 62px; display: flex; align-items: center; gap: 8px; padding: 10px 14px; color: var(--muted); border-right: 1px solid var(--border); }
.summary-strip > span:last-child, .compact-status-bar > span:last-child { border-right: 0; }
.summary-strip strong, .compact-status-bar strong { color: var(--brand); font-size: 1.35rem; }
.compact-status-bar { grid-template-columns: repeat(3, minmax(0,1fr)); }
.compact-status-bar .needs-attention { color: var(--warning); background: var(--warning-bg); }

.section-block { margin-top: 16px; padding: 16px; }
.section-heading { min-height: 0; margin-bottom: 12px; padding-bottom: 12px; }
.section-heading h2 { margin-bottom: 2px; }
.primary-section { padding: 18px; }
.quiet-button { background: var(--surface-soft); }
.launch-grid { gap: 12px; }
.launch-grid.single { grid-template-columns: minmax(0, 650px); }
.launch-tile { min-height: 142px; grid-template-columns: 44px minmax(0,1fr) auto; grid-template-rows: auto; align-items: start; gap: 10px 14px; padding: 16px; box-shadow: none; }
.launch-tile .app-mark { width: 44px; height: 44px; }
.launch-tile .tile-copy { min-width: 0; padding: 0; }
.launch-tile > div:nth-of-type(2) { padding-top: 0; }
.tile-title-line { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; padding-right: 0; }
.launch-tile h3 { margin: 0; font-size: 1.05rem; }
.launch-tile p { margin: 5px 0 8px; line-height: 1.4; }
.launch-tile > .button { grid-column: 3; align-self: center; justify-self: end; }
.development-strip { min-height: 60px; display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-top: 12px; padding: 10px 14px; border-top: 1px solid var(--border); }
.development-strip > div { display: grid; }
.development-strip span { color: var(--muted); font-size: .84rem; }

.app-list { gap: 8px; }
.app-row { min-height: 68px; grid-template-columns: 42px minmax(240px,1fr) auto auto; gap: 12px; padding: 10px 12px; }
.app-row .app-mark, .app-mark { width: 42px; height: 42px; }
.app-row p { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.app-row .row-meta { font-size: .82rem; }
.row-actions { gap: 6px; }
.module-row, .integration-row, .attention-row { min-height: 68px; padding: 10px 12px; }

.status { min-height: 28px; padding: 3px 9px; font-size: .82rem; }
.status > span { width: 17px; height: 17px; font-size: .7rem; }
.table-block { padding: 12px 14px; }
.data-table th, .data-table td { min-height: 50px; padding: 10px; }
.data-table th { font-size: .8rem; }
.data-table td small { font-size: .8rem; }
.device-table th:first-child { width: 21%; }
.device-table th:nth-child(2) { width: 22%; }
.device-table th:nth-child(3) { width: 34%; }
.status-action { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.help-disclosure { margin: 10px 2px 0; color: var(--muted); }
.help-disclosure summary { cursor: pointer; font-weight: 700; }
.help-disclosure p { max-width: 760px; margin-top: 8px; }

.disclosure { padding: 0; overflow: hidden; }
.disclosure > summary { min-height: 62px; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 16px; cursor: pointer; list-style: none; }
.disclosure > summary::-webkit-details-marker { display: none; }
.disclosure > summary > span:first-child { display: grid; }
.disclosure > summary small { color: var(--muted); font-weight: 400; }
.disclosure > summary > span:last-child { color: var(--brand); font-size: .84rem; font-weight: 750; }
.disclosure[open] > summary { border-bottom: 1px solid var(--border); }
.disclosure[open] > summary > span:last-child { font-size: 0; }
.disclosure[open] > summary > span:last-child::after { content: "Sluiten"; font-size: .84rem; }
.disclosure-content { padding: 14px 16px 16px; }
.section-intro { margin-bottom: 10px; }

.update-center { padding: 18px; }
.eyebrow-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-bottom: 4px; }
.eyebrow { color: var(--accent); font-size: .78rem; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.update-steps { display: grid; grid-template-columns: repeat(3,1fr); gap: 8px; margin: 14px 0 16px; padding: 0; list-style: none; }
.update-steps li { min-height: 58px; display: flex; align-items: center; gap: 9px; padding: 9px 11px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface-soft); }
.update-steps li > span { width: 28px; height: 28px; display: grid; place-items: center; flex: 0 0 28px; border-radius: 50%; color: var(--muted); border: 1px solid var(--border); font-weight: 800; }
.update-steps li div { display: grid; }
.update-steps small { color: var(--muted); }
.update-steps .done > span, .update-steps .current > span { color: #fff; border-color: var(--brand); background: var(--brand); }
.update-steps .current { border-color: var(--brand); background: var(--brand-soft); }
.update-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; padding: 14px; border: 1px solid var(--border); border-radius: 7px; background: var(--surface-soft); }
.update-form label { display: grid; gap: 5px; font-weight: 700; }
.update-form .full { grid-column: 1 / -1; }
.visually-hidden { position: absolute !important; width: 1px !important; height: 1px !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; clip-path: inset(50%) !important; white-space: nowrap !important; }
.file-picker { min-height: 46px; display: flex; align-items: center; gap: 12px; padding: 5px 7px; color: var(--muted); border: 1px solid var(--field-border); border-radius: 7px; background: var(--surface); cursor: pointer; }
.file-button { min-height: 34px; display: inline-flex; align-items: center; padding: 6px 11px; color: var(--brand); border: 1px solid var(--border); border-radius: 6px; background: var(--brand-soft); font-weight: 800; }
.file-field:hover .file-button { border-color: var(--brand); }
.file-field:focus-within .file-picker { outline: 3px solid var(--focus); outline-offset: 2px; }
.update-form-footer { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding-top: 4px; }
.update-form-footer p { max-width: 700px; font-size: .84rem; }
.inline-history { margin-top: 12px; }
.inline-history > summary { cursor: pointer; color: var(--brand); font-weight: 750; }
.backup-panel { display: flex; align-items: center; justify-content: space-between; gap: 18px; }

.mobile-menu-button, .nav-scrim { display: none; }

@media (max-width: 980px) {
  .content { padding-inline: 20px; }
  .launch-tile { grid-template-columns: 44px minmax(0,1fr); }
  .launch-tile > .button { grid-column: 2; justify-self: start; }
  .app-row { grid-template-columns: 42px minmax(220px,1fr) auto; }
  .app-row .row-actions { grid-column: 2 / -1; justify-content: flex-start; }
}

@media (max-width: 880px) {
  .hub-shell { display: block; }
  .sidebar { position: fixed; z-index: 80; inset: 0 auto 0 0; width: min(86vw, 300px); min-height: 100vh; height: 100vh; padding: 14px 10px; transform: translateX(-105%); transition: transform .18s ease; box-shadow: 12px 0 30px rgba(20,30,36,.14); }
  .nav-open { overflow: hidden; }
  .nav-open .sidebar { transform: translateX(0); }
  .sidebar-brand { min-height: 72px; }
  .sidebar-brand img { width: 132px; }
  .sidebar nav { grid-template-columns: 1fr; gap: 3px; padding-top: 12px; }
  .sidebar nav button { min-height: 46px; justify-content: flex-start; }
  .sidebar-foot { display: grid; }
  .nav-scrim { position: fixed; z-index: 70; inset: 0; width: 100%; height: 100%; border: 0; background: rgba(23,40,50,.36); }
  .nav-open .nav-scrim { display: block; }
  .mobile-menu-button { min-height: 40px; display: inline-flex; align-items: center; padding: 6px 11px; color: var(--brand); border: 1px solid var(--border); border-radius: 7px; background: var(--surface); font-weight: 800; }
  .topbar { position: sticky; z-index: 50; top: 0; min-height: 62px; padding: 8px 14px; }
  .topbar > div:first-child { display: flex; }
  .topbar-actions { width: auto; }
  .content { padding: 20px 18px 44px; }
  .summary-strip { grid-template-columns: repeat(2,1fr); }
  .summary-strip > span:nth-child(2) { border-right: 0; }
  .summary-strip > span:nth-child(-n+2) { border-bottom: 1px solid var(--border); }
}

@media (max-width: 640px) {
  :root { font-size: 16px; }
  .topbar-title > div { display: none; }
  .topbar-actions .admin-user { display: none; }
  .content { padding: 16px 12px 40px; }
  .page-header { align-items: stretch; flex-direction: column; gap: 10px; }
  .page-header p { font-size: .92rem; }
  .summary-strip, .compact-status-bar { grid-template-columns: 1fr; }
  .summary-strip > span, .compact-status-bar > span { min-height: 52px; border-right: 0; border-bottom: 1px solid var(--border); }
  .summary-strip > span:last-child, .compact-status-bar > span:last-child { border-bottom: 0; }
  .launch-grid { grid-template-columns: 1fr; }
  .launch-tile { min-height: 0; grid-template-columns: 40px minmax(0,1fr); padding: 14px; }
  .launch-tile .app-mark { width: 40px; height: 40px; }
  .launch-tile > .button { grid-column: 1 / -1; width: 100%; }
  .development-strip { align-items: stretch; flex-direction: column; gap: 5px; }
  .development-strip .text-button { align-self: flex-start; padding-inline: 0; }
  .app-row, .module-row, .integration-row, .attention-row, .access-list article { grid-template-columns: 40px minmax(0,1fr); }
  .app-row .status, .module-row .status, .integration-row .status, .attention-row .status { grid-column: 2; justify-self: start; }
  .app-row .row-actions, .module-row .row-actions, .integration-row .row-actions { grid-column: 1 / -1; }
  .app-row p { white-space: normal; }
  .section-block, .update-center { padding: 13px; }
  .disclosure { padding: 0; }
  .disclosure > summary { min-height: 58px; padding: 11px 13px; }
  .disclosure-content { padding: 12px 13px 14px; }
  .update-steps, .update-form { grid-template-columns: 1fr; }
  .update-form .full { grid-column: 1; }
  .update-form-footer, .backup-panel { align-items: stretch; flex-direction: column; }
  .update-form-footer .button, .backup-panel .button { width: 100%; }
  .file-picker { align-items: flex-start; flex-direction: column; gap: 6px; }
  .file-button { width: 100%; justify-content: center; }
  .device-table td { grid-template-columns: 38% minmax(0,1fr); }
  .status-action { align-items: stretch; flex-direction: column; }
  .status-action .status { align-self: flex-start; }
  .status-action .button { width: 100%; }
}

/* Houd afmelden op kleine schermen bereikbaar. */
@media (max-width: 640px) {
  .topbar-actions .text-button { display: inline-flex !important; }
}
/* Verberg lege toast volledig buiten beeld. */
.toast { visibility: hidden; opacity: 0; pointer-events: none; }
.toast.visible { visibility: visible; opacity: 1; }
