/* Easy Flex CMS - zakelijke opmaak in de huisstijl van Easy Flex Solutions (oranje accent,
   lettertype Armata voor koppen). Geen externe bestanden: logo en lettertype staan in
   assets/login/ (ook gebruikt door het inlogscherm), iconen inline (Cms\Services\Icons). */

@font-face {
	font-family: "Armata";
	src: url("login/armata-latin-400.woff2") format("woff2");
	font-weight: 400;
	font-style: normal;
	font-display: swap;
}

:root {
	--ink: #1f2328;
	--muted: #646b73;
	--line: #e4e6ea;
	--paper: #f3f4f6;
	--white: #fff;
	--side: #1f2228;           /* zijbalk: antraciet */
	--side-ink: #f1f2f4;
	--side-muted: #9097a1;
	--side-line: rgba(255, 255, 255, .09);
	--accent: #e8830c;          /* knoppen, actieve tab: Easy Flex-oranje */
	--accent-dark: #c76d05;
	--accent-soft: #fff4e6;     /* lichte achtergrond bij actief menu-item */
	--link: var(--ink);         /* tekstlinks: donker (onderstreept); oranje alleen voor accenten */
	--ok: #2f7a3e;
	--ok-bg: #edf6ee;
	--error: #b42318;
	--error-bg: #fdf0ef;
	--info-bg: #eef4fb;
	--radius: 6px;
	--radius-lg: 10px;
	--shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 1px 3px rgba(16, 24, 40, .06);
	--heading: "Armata", "Segoe UI", Roboto, Arial, sans-serif;
}

* { box-sizing: border-box; }
html { font-size: 15px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: -apple-system, "Segoe UI", Roboto, Arial, sans-serif; line-height: 1.55; }
a { color: var(--link); text-underline-offset: 2px; }
a:hover { color: var(--ink); text-decoration-color: var(--accent); }
.table a:not(.btn) { text-decoration: none; font-weight: 600; }
.table a:not(.btn):hover { text-decoration: underline; }
h1, h2, h3 { margin: 0 0 .5em; line-height: 1.25; font-weight: 600; }
h1, h2 { font-family: var(--heading); font-weight: 400; font-synthesis: none; letter-spacing: .01em; }
h1 { font-size: 1.7rem; }
h2 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
code { font-size: .85em; background: var(--paper); padding: 1px 4px; border-radius: 3px; word-break: break-all; }
:focus-visible { outline: 3px solid rgba(232, 131, 12, .45); outline-offset: 2px; }

.skip { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 12px; z-index: 10; }
.skip:focus { left: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.icon { flex: none; width: 20px; height: 20px; }

/* Opbouw: donkere zijbalk met wit logo, witte tekst en iconen; de huidige pagina oranje */
.app { display: grid; grid-template-columns: 260px minmax(0, 1fr); min-height: 100vh; }
.sidebar { position: sticky; top: 0; display: flex; flex-direction: column; gap: 12px; height: 100vh; overflow-y: auto; scrollbar-width: thin; scrollbar-color: #3b4049 transparent; padding: 18px 14px 12px; background: var(--side); color: var(--side-ink); }
.brand { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 6px 8px 16px; border-bottom: 1px solid var(--side-line); color: var(--side-ink); text-decoration: none; }
.brand img { display: block; width: 200px; max-width: 100%; height: auto; }
.brand:hover { color: var(--side-ink); }
.site-switch { display: flex; flex-direction: column; gap: 6px; padding: 0 6px; }
.site-switch label, .site-switch .label { font-size: .7rem; text-transform: uppercase; letter-spacing: .12em; color: var(--side-muted); }
.site-switch strong { color: #fff; font-weight: 600; }
.site-switch select { width: 100%; max-width: 100%; min-width: 0; padding: 8px 10px; border: 1px solid #3b4049; border-radius: var(--radius); background: #2a2e35; color: #fff; font: inherit; font-size: .9rem; }
.site-switch select:focus { border-color: var(--accent); }
.nav { display: flex; flex-direction: column; gap: 2px; }
.nav a { display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: var(--radius); color: var(--side-ink); text-decoration: none; font-size: .94rem; transition: background-color .12s; }
.nav a .icon { width: 18px; height: 18px; color: #fff; opacity: .9; }
.nav a:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.nav a[aria-current="page"] { background: var(--accent); color: #fff; font-weight: 600; }
.nav a[aria-current="page"] .icon { opacity: 1; }
.nav-group { margin: 12px 12px 4px; font-size: .68rem; text-transform: uppercase; letter-spacing: .14em; color: var(--side-muted); }
.nav-group-plain { margin: 8px 12px; border-top: 1px solid var(--side-line); }
.account { margin-top: auto; display: flex; flex-direction: column; gap: 2px; padding: 12px 0 0; border-top: 1px solid var(--side-line); }
.account a, .account .link { display: flex; align-items: center; gap: 12px; padding: 8px 12px; border-radius: var(--radius); color: var(--side-ink); text-decoration: none; font-size: .92rem; width: 100%; }
.account .icon { width: 18px; height: 18px; color: #fff; opacity: .9; }
.account a:hover, .account .link:hover { background: rgba(255, 255, 255, .08); color: #fff; }
.account-name { font-weight: 600; }
.account a[aria-current="page"] { background: var(--accent); color: #fff; }
.publisher { margin: 4px 12px 0; font-size: .7rem; color: var(--side-muted); }
@media (prefers-reduced-motion: reduce) { .nav a { transition: none; } }.main { padding: 30px 40px 60px; max-width: 1180px; }

/* Koppen */
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; margin-bottom: 22px; }
.page-head p { margin: 4px 0 0; }
.eyebrow { margin: 0 0 4px !important; font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
.eyebrow a { color: inherit; }

/* Kaarten, tegels, tabs */
.card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); padding: 22px 24px; margin-bottom: 20px; box-shadow: var(--shadow); }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; margin-bottom: 26px; }
.tile { display: grid; grid-template-columns: auto minmax(0, 1fr); align-content: start; gap: 2px 14px; align-items: start; padding: 16px; background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-lg); color: var(--ink); text-decoration: none; box-shadow: var(--shadow); transition: border-color .15s, box-shadow .15s, transform .15s; }
.tile:hover { border-color: #f3c48d; color: var(--ink); box-shadow: 0 6px 18px rgba(16, 24, 40, .08); transform: translateY(-1px); }
.tile-icon { grid-row: span 2; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; background: var(--accent-soft); color: var(--accent); }
.tile strong { font-weight: 600; }
.tile span:not(.tile-icon) { color: var(--muted); font-size: .88rem; }
.tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 18px; border-bottom: 1px solid var(--line); }
.tabs a { padding: 9px 14px; color: var(--muted); text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs a:hover { color: var(--ink); }
.tabs a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); font-weight: 600; }
@media (prefers-reduced-motion: reduce) { .tile { transition: none; } .tile:hover { transform: none; } }
/* Tabellen */
.table { width: 100%; border-collapse: collapse; }
.table th, .table td { padding: 10px 8px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.table th { font-size: .75rem; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); font-weight: 600; }
.table tbody tr:hover td { background: #fafafa; }
.table tr:last-child td { border-bottom: 0; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 999px; background: var(--paper); color: var(--muted); font-size: .8rem; }
.badge-ok { background: var(--ok-bg); color: var(--ok); }
.badge-error { background: var(--error-bg); color: var(--error); }

/* Formulieren */
.form .field, fieldset.field { margin: 0 0 18px; }
fieldset.field { border: 0; padding: 0; }
legend, .field > label { display: block; margin-bottom: 6px; font-weight: 600; }
.field-inline { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 16px; align-items: center; }
.field-inline label { margin: 0; font-weight: 400; }
.field-inline label span { display: block; }
input[type="text"], input[type="email"], input[type="password"], input[type="date"], input[type="url"], input[type="tel"], input[type="number"], select, textarea {
	width: 100%; padding: 9px 11px; border: 1px solid #cfd3d8; border-radius: var(--radius); background: #fff; color: var(--ink); font: inherit;
}
input:focus, select:focus, textarea:focus { border-color: var(--accent); outline: 0; box-shadow: 0 0 0 3px rgba(232, 131, 12, .2); }
textarea { resize: vertical; }
input[type="file"] { font: inherit; font-size: .9rem; color: var(--muted); }
input[type="file"]::file-selector-button { margin-right: 10px; padding: 7px 14px; border: 1px solid #cfd3d8; border-radius: var(--radius); background: #fff; color: var(--ink); font: inherit; font-weight: 600; cursor: pointer; }
input[type="file"]::file-selector-button:hover { background: #fafafa; border-color: #9aa0a8; }
.has-error input, .has-error select, .has-error textarea, .has-error .editor { border-color: var(--error); }
.help { margin: 5px 0 0; color: var(--muted); font-size: .85rem; }
.error { margin: 5px 0 0; color: var(--error); font-size: .9rem; font-weight: 600; }
.check { display: flex; gap: 8px; align-items: center; font-weight: 400; }
.check-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 6px 16px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 20px; }
.prefix-field { display: flex; }
.prefix-field span { padding: 9px 10px; background: var(--paper); border: 1px solid #c4cad1; border-right: 0; border-radius: var(--radius) 0 0 var(--radius); color: var(--muted); }
.prefix-field input { border-radius: 0 var(--radius) var(--radius) 0; }
.color-field { display: flex; gap: 8px; max-width: 260px; }
.color-field input[type="color"] { width: 46px; height: 40px; padding: 2px; border: 1px solid #c4cad1; border-radius: var(--radius); background: #fff; }
.image-preview { display: flex; flex-wrap: wrap; gap: 10px 16px; align-items: center; margin-bottom: 10px; padding: 10px; background: var(--paper); border-radius: var(--radius); }
.image-preview img { max-width: 220px; max-height: 120px; object-fit: contain; background: #fff; border: 1px solid var(--line); }
.actions { display: flex; gap: 10px; margin-top: 8px; }
.sticky-actions { position: sticky; bottom: 0; padding: 12px 0; background: var(--paper); }
.upload-form { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; }
.upload-form label { font-weight: 600; }
.danger-zone { margin-top: 10px; }

/* Knoppen */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; padding: 9px 16px; border: 1px solid #c4cad1; border-radius: var(--radius); background: #fff; color: var(--ink); font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn:hover { border-color: #9aa0a8; background: #fafafa; color: var(--ink); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); border-color: var(--accent-dark); color: #fff; }
.btn-danger { color: var(--error); border-color: #e6b4af; }
.btn-danger:hover { background: var(--error); border-color: var(--error); color: #fff; }
.btn-small { padding: 5px 10px; font-size: .85rem; }
.btn-block { width: 100%; }
.link { padding: 0; border: 0; background: none; color: var(--link); font: inherit; cursor: pointer; text-align: left; }
.link-danger { color: var(--error); }

/* Meldingen */
.alert { padding: 11px 14px; margin-bottom: 18px; border-radius: var(--radius); border: 1px solid transparent; }
.alert-success { background: var(--ok-bg); border-color: #c8e3cc; color: #1f5a2b; }
.alert-error { background: var(--error-bg); border-color: #f2c7c3; color: #8a1c13; }
.alert-info { background: var(--info-bg); border-color: #cfe0f3; color: #1d4f86; }

/* Editor */
.editor { border: 1px solid #c4cad1; border-radius: var(--radius); background: #fff; }
.editor-toolbar { display: flex; flex-wrap: wrap; gap: 4px; padding: 6px; border-bottom: 1px solid var(--line); background: var(--paper); }
.editor-toolbar button { padding: 4px 9px; border: 1px solid transparent; border-radius: 3px; background: none; color: var(--ink); font: inherit; font-size: .85rem; cursor: pointer; }
.editor-toolbar button:hover { background: #fff; border-color: var(--line); }
.editor-area { min-height: 260px; padding: 12px 14px; outline: 0; }
.editor-area:focus { box-shadow: inset 0 0 0 2px #8ab4e8; }
.editor-area h2 { font-size: 1.3rem; margin: 1em 0 .4em; }
.editor-area h3 { font-size: 1.1rem; margin: 1em 0 .4em; }
.editor-area p { margin: 0 0 .8em; }

/* Pagina's: boomstructuur en volgorde */
.inline { display: inline; }
.btn-icon { min-width: 32px; padding: 4px 8px; font-size: .95rem; line-height: 1; }
.btn-icon[disabled] { opacity: .35; cursor: default; }
.tree-child td:first-child { padding-left: 26px; }
.tree-line { margin-right: 8px; color: #9aa5b1; }
.card-legend { padding: 0; margin-bottom: 14px; font-size: 1.15rem; font-weight: 600; }
fieldset.card { min-width: 0; }
/* Een <legend> tekent de browser standaard óp de rand van de fieldset. Zwevend
   (float) wordt het een gewone kop binnen het kader, net als <h2> in een .card. */
fieldset.card > legend.card-legend { float: left; width: 100%; margin: 0 0 14px; padding: 0; }
fieldset.card > legend.card-legend ~ * { clear: both; }
.counter { float: right; font-size: .8rem; color: var(--muted); }
.counter.over { color: var(--error); font-weight: 600; }
input[readonly] { background: var(--paper); color: var(--muted); }
textarea.code { font-family: ui-monospace, Consolas, "Courier New", monospace; font-size: .85rem; line-height: 1.5; white-space: pre; overflow-x: auto; }

/* Media */
.media-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 14px; }
.media-item { margin: 0; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.media-item img { display: block; width: 100%; height: 140px; object-fit: cover; background: var(--paper); }
.media-item figcaption { display: flex; flex-direction: column; gap: 4px; padding: 10px; }
.media-item figcaption span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.media-item input { font-size: .8rem; padding: 5px 7px; }

/* Foutpagina (errors/standalone.php) */
.guest { display: grid; place-items: center; min-height: 100vh; padding: 20px; }
.guest-card { width: 100%; max-width: 520px; padding: 30px; background: #fff; border: 1px solid var(--line); border-top: 3px solid var(--accent); border-radius: var(--radius-lg); box-shadow: var(--shadow); }
.details { max-height: 300px; overflow: auto; font-size: .75rem; white-space: pre-wrap; background: var(--paper); padding: 10px; }

/* Smal scherm */
@media (max-width: 860px) {
	.app { grid-template-columns: minmax(0, 1fr); }
	.sidebar { position: static; height: auto; gap: 12px; }
	.brand { flex-direction: row; justify-content: space-between; padding-bottom: 10px; }
	.brand img { width: 160px; }
	/* Menu als één horizontaal schuifbare strook */
	.nav { flex-direction: row; flex-wrap: nowrap; gap: 6px; overflow-x: auto; margin: 0 -14px; padding: 2px 14px 6px; scrollbar-width: thin; }
	.nav a { flex: none; white-space: nowrap; }
	.nav a { padding: 6px 10px; font-size: .88rem; border: 1px solid var(--side-line); }
	.nav a .icon { width: 16px; height: 16px; }
	.nav-group { display: none; }
	.account { margin-top: 0; flex-direction: row; justify-content: space-between; }
	.account a, .account .link { width: auto; }
	.publisher { display: none; }
	.main { padding: 22px 16px 40px; }
	.grid-2, .field-inline { grid-template-columns: 1fr; gap: 0; }
	.field-inline { gap: 6px; }
	.page-head { flex-direction: column; align-items: flex-start; }
}

/* Projecten: fotoalbum */
.album-upload { margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--line); }
.album-upload .help { flex-basis: 100%; margin: 0; }
.media-grid + .album-upload, .card > .media-grid { margin-top: 12px; }

/* Slider */
.slide-thumb { width: 132px; }
.slide-thumb img { display: block; width: 120px; height: 64px; object-fit: cover; border-radius: 4px; background: var(--paper); }
.page-head .btn { white-space: nowrap; }
.page-head .btn .icon { width: 16px; height: 16px; }

/* Formulieren: keuzelijsten */
.option-table th:first-child, .option-table td:first-child { width: 64px; }
.option-table th:last-child, .option-table td:last-child { width: 120px; }
.option-list .field .check { margin-bottom: 4px; }
.prefix-field span { white-space: nowrap; }

/* Aanvragen */
.filter-form { display: flex; flex-wrap: wrap; gap: 12px 16px; align-items: flex-end; }
.filter-form .field { margin: 0; min-width: 160px; }
.filter-form .actions { margin: 0; }
.pager { display: flex; gap: 12px; align-items: center; justify-content: center; margin-top: 14px; }
.table.compact td, .table.compact th { padding-top: 6px; padding-bottom: 6px; }

/* Formuliervelden */
.form-fields-table td { vertical-align: middle; }
.form-fields-table td:nth-child(2), .form-fields-table td:nth-child(3) { width: 90px; }
.form-fields-table tr.has-error td { background: #fdf0f0; }
.extra-field { border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px; margin: 0 0 14px; min-width: 0; }
.extra-field > legend { float: left; width: 100%; margin: 0 0 10px; padding: 0; }
.extra-field > legend ~ * { clear: both; }
.extra-field.has-error { border-color: #d9534f; }
.extra-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1.2fr) 110px; gap: 0 14px; }
@media (max-width: 720px) { .extra-grid { grid-template-columns: 1fr; } }
.site-switch .site-id { display: block; margin-top: 6px; font-size: .8rem; opacity: .75; }

/* Hulp (handleiding) */
.help-toc { max-width: 860px; }
.help-toc ol { columns: 2; column-gap: 30px; margin: 0; padding-left: 20px; }
.help-toc li { margin-bottom: 4px; break-inside: avoid; }
.help-doc { max-width: 860px; }
.help-doc .card { scroll-margin-top: 16px; }
.help-doc h3 { margin: 18px 0 6px; font-size: 1rem; }
.help-doc li { margin-bottom: 6px; line-height: 1.55; }
.help-doc p { line-height: 1.6; }
.help-doc pre { margin: 8px 0; padding: 10px 12px; overflow-x: auto; background: #f6f7f9; border: 1px solid var(--line); border-radius: var(--radius); font-size: .85rem; white-space: pre; }
.help-faq dt { margin-top: 12px; font-weight: 600; }
.help-faq dd { margin: 4px 0 0; color: var(--muted); }
.help-doc kbd { padding: 1px 6px; border: 1px solid var(--line); border-radius: 4px; background: #f6f7f9; font-size: .85em; }
@media (max-width: 720px) { .help-toc ol { columns: 1; } }

/* Link onder het inlogformulier ("Wachtwoord vergeten?") */
.guest-link { margin: 16px 0 0; text-align: center; font-size: .9rem; }

/* Melding "je wordt bijna uitgelogd" / "je bent uitgelogd" (cms.js); boven de editor op volledig scherm */
.session-banner { position: fixed; right: 16px; bottom: 16px; left: 16px; z-index: 100001; display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; max-width: 720px; margin: 0 auto; padding: 12px 16px; background: var(--info-bg); border: 1px solid var(--accent); border-radius: var(--radius); box-shadow: 0 4px 16px rgba(31, 41, 51, .18); }
.session-banner p { flex: 1 1 260px; margin: 0; }

/* Foto slepen en uitsnede kiezen (assets/crop.js) */
.crop-drop { position: relative; display: flex; align-items: center; justify-content: center; min-height: 110px; padding: 18px; border: 2px dashed #cfd3d8; border-radius: var(--radius-lg); background: #fafbfc; color: var(--muted); text-align: center; transition: border-color .12s, background-color .12s; }
.crop-drop strong { color: var(--ink); }
.crop-drop input[type="file"] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.crop-drop.is-over, .crop-drop:focus-within { border-color: var(--accent); background: var(--accent-soft); }
.crop-drop.is-compact { min-height: 0; padding: 10px 14px; }
.crop-panel { margin-top: 12px; }
.crop-toolbar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin-bottom: 10px; }
.crop-formats { display: flex; flex-wrap: wrap; gap: 6px; margin-right: auto; }
.crop-formats .btn[aria-pressed="true"] { border-color: var(--accent); background: var(--accent-soft); }
.crop-stage { height: 440px; overflow: hidden; background: #1f2228; border-radius: var(--radius); }
.crop-stage img { display: block; max-width: 100%; }
.crop-info { margin: 8px 0 0; font-size: .88rem; color: var(--muted); }
.crop-info.crop-warning { color: #8a4b00; }
/* Kader in Easy Flex-oranje (specifieker dan vendor/cropper/cropper.min.css, dat later laadt) */
.crop-stage .cropper-view-box { outline-color: var(--accent); }
.crop-stage .cropper-line, .crop-stage .cropper-point { background-color: var(--accent); }
.crop-shade { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(90deg, rgba(20, 27, 31, .85) 0%, rgba(20, 27, 31, .65) 28%, rgba(20, 27, 31, .12) 72%, rgba(20, 27, 31, 0)); }
.crop-shade-label { position: absolute; top: 50%; left: 6%; transform: translateY(-50%); color: #fff; font-size: .8rem; letter-spacing: .12em; text-transform: uppercase; opacity: .8; }
@media (max-width: 720px) { .crop-stage { height: 300px; } }
@media (prefers-reduced-motion: reduce) { .crop-drop { transition: none; } }