/* House style: colours and fonts of ceciliakruibeke.be */
:root {
    --ink: #0C2B19;
    --ink-deep: #051B0E;
    --green: #137738;
    --green-dark: #005E26;
    --green-light: #9DDE9E;
    --text: #36473B;
    --muted: #485A4E;
    --paper: #F6F4ED;
    --paper-soft: #ECE8D9;
    --cream: #FAF8F3;
    --line: #D3D6CD;
    --line-strong: #A4AEA3;
    --red: #B03A2E;
    --red-text: #8E2B21;
    --red-bg: #F9E3E0;
    --ok-bg: #E3F1E1;
    --warn-text: #7A4F0F;
    --warn-bg: #FDF1DC;
    --warn-line: #C9962E;
    --display: Gloock, Georgia, serif;
    --sans: 'Instrument Sans', system-ui, sans-serif;
    --mono: 'JetBrains Mono', ui-monospace, monospace;
}
* { box-sizing: border-box; }
body { margin: 0; font: 15px/1.45 var(--sans); color: var(--text); background: var(--paper); }
:focus-visible { outline: 3px solid var(--green-light); outline-offset: 1px; }

nav { display: flex; flex-wrap: wrap; align-items: center; gap: 2px; background: var(--ink); padding: 6px 16px; }
nav .brand { display: flex; background: var(--cream); border-radius: 4px; padding: 3px 6px; margin-right: 12px; }
nav .brand img { height: 34px; width: auto; display: block; }
nav a { color: #C7D3CA; padding: 12px 10px; text-decoration: none; border-bottom: 3px solid transparent; }
nav a:hover { color: var(--cream); background: var(--ink-deep); }
nav a.active { color: var(--cream); font-weight: 600; border-bottom-color: var(--green-light); }
nav .brand:hover { background: var(--cream); }
nav .who { margin-left: auto; color: #C7D3CA; font-size: 13px; padding: 12px 0; }
nav .who a { padding: 0; color: var(--cream); border: 0; }
nav.sub { background: var(--cream); border-bottom: 1px solid var(--line); padding: 0 16px; }
nav.sub a { color: var(--ink); padding: 10px 10px; }
nav.sub a:hover { color: var(--ink); background: var(--paper); }
nav.sub a.active { color: var(--green-dark); border-bottom-color: var(--green); }

main { padding: 24px; max-width: 1400px; margin: 0 auto; }
.login-logo { height: 80px; width: auto; display: block; margin-bottom: 12px; }
h1 { margin: 0 0 16px; font: 400 36px/1.1 var(--display); color: var(--ink); }
h2 { margin: 22px 0 10px; font: 400 24px/1.2 var(--display); color: var(--ink); }
.card h2, .cols h2 { font: 600 17px/1.3 var(--sans); }
a { color: var(--green-dark); }
a:hover { color: var(--ink); }

input, select, textarea { font: inherit; color: var(--ink); background: #fff; border: 1px solid var(--line-strong); border-radius: 4px; padding: 6px 10px; min-height: 40px; }
textarea { min-height: 0; }
input[type=checkbox], input[type=radio] { min-height: 0; accent-color: var(--green); width: 18px; height: 18px; }
button, .button { display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border: 0; border-radius: 999px; background: var(--green); color: #fff; font: 600 15px var(--sans); cursor: pointer; text-decoration: none; }
button:hover, .button:hover { background: var(--green-dark); color: #fff; }
button.danger { background: var(--red); }
button.danger:hover { background: var(--red-text); }
button.link { background: none; color: var(--red-text); padding: 0 6px; min-height: 0; }
.num { width: 5em; }
.mono { font-family: var(--mono); }
.card ul.downloads { list-style: none; padding: 0; }
.toolbar { display: flex; flex-wrap: wrap; gap: 4px; margin: 12px 0 6px; }
.toolbar button { min-height: 34px; padding: 0 12px; background: var(--cream); color: var(--ink); border: 1px solid var(--line-strong); }
.toolbar button:hover { background: var(--paper); color: var(--ink); }
.toolbar .swatch { width: 34px; padding: 0; border: 2px solid #fff; box-shadow: 0 0 0 1px var(--line-strong); }
.editor { min-height: 260px; background: #fff; border: 1px solid var(--line-strong); border-radius: 4px; padding: 10px 14px;
    font: 15px/1.5 Arial, Helvetica, sans-serif; color: #0C2B19; }
.editor:focus { outline: 2px solid var(--green); }
details.mailing { border-top: 1px solid var(--line); padding: 8px 0; }
details.mailing summary { cursor: pointer; }
.person-search { min-width: 240px; }
.year { width: 6.5em; }
.inline { display: inline; }
form.inline, .inline-row { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 4px 0; }
.inline-row label:not(.check) { display: inline-flex; align-items: center; gap: 6px; font-size: 15px; font-weight: 400; }
.inline-row label:not(.check) input, .inline-row label:not(.check) select { width: auto; margin-top: 0; }
.card ul, .area ul { padding-left: 20px; }
.card li, .area li { margin: 8px 0; }
.spot li { margin: 3px 0; }
.spot > .inline-row, .spot > a { display: inline-flex; margin-top: 8px; }

.card { background: var(--cream); border: 1px solid var(--line); border-radius: 4px; padding: 14px 18px; margin: 14px 0; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px 16px; }
label { display: block; font-size: 13px; font-weight: 600; color: var(--ink); }
label input, label select, label textarea { display: block; width: 100%; margin-top: 4px; font-size: 15px; font-weight: 400; }
label.check { display: inline-flex; align-items: center; gap: 6px; margin-right: 14px; font-size: 15px; font-weight: 400; }
label.check input { width: 18px; margin: 0; }
fieldset { border: 0; padding: 0; margin: 0; }
/* Space above any button that starts its own line below a block (table, list, text, field). Rows of controls keep their own gap. */
:not(.inline-row, form.inline, .filters, .picker, .spot) > :is(table, ul, ol, p, div, label, fieldset, details, section) + :is(button, .button),
form:not(.inline) > input[type="hidden"] + :is(button, .button) { margin-top: 12px; }
.savebar { position: sticky; bottom: 0; z-index: 5; padding: 10px 0; background: var(--paper); border-top: 1px solid var(--line); }
/* First button in a form, so Enter in a field saves instead of pressing a × or Toevoegen. */
.default-submit { position: absolute; left: -9999px; }
.login { max-width: 340px; display: grid; gap: 12px; }

.flashes { position: fixed; top: 12px; right: 12px; z-index: 10; width: min(440px, calc(100% - 24px)); max-height: calc(100vh - 24px); overflow-y: auto; }
.flashes.at-button { position: absolute; right: auto; }
.flash { padding: 10px 14px; border-radius: 4px; margin: 6px 0; cursor: pointer; box-shadow: 0 2px 8px rgb(0 0 0 / .15); }
.flash.ok { background: var(--ok-bg); color: var(--green-dark); }
.flash.warn { background: var(--warn-bg); color: var(--warn-text); }
.flash.error { background: var(--red-bg); color: var(--red-text); }
.muted { color: var(--muted); }
.good { color: var(--green-dark); font-weight: 600; }
.bad { color: var(--red-text); }
td.muted { font-weight: 400; }

.stats { display: flex; flex-wrap: wrap; gap: 14px; }
.stats span { background: var(--cream); border: 1px solid var(--line); border-radius: 4px; padding: 12px 18px; min-width: 170px; font-size: 13px; color: var(--muted); }
.stats b { display: block; font: 500 28px/1.2 var(--mono); color: var(--ink); }
.stats .bad { border-top: 4px solid var(--warn-line); }
.cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 20px; }
.cols section { background: var(--cream); border: 1px solid var(--line); border-radius: 4px; padding: 4px 18px 12px; }

table { border-collapse: collapse; background: var(--cream); }
th, td { border: 1px solid var(--line); padding: 6px 10px; text-align: left; vertical-align: top; }
th { background: var(--paper-soft); color: var(--ink); font-size: 13px; }
table.list tr:hover td { background: #fff; }
table.grid td { text-align: center; min-width: 90px; padding: 5px; }
table.grid td a { display: block; border-radius: 999px; padding: 4px 0; font: 500 13px var(--mono); text-decoration: none; }
table.grid td.open a { background: var(--red-bg); color: var(--red-text); }
table.grid td.full a { background: var(--ok-bg); color: var(--green-dark); }
table.history td { text-align: center; color: var(--green-dark); }
table.history td:first-child { text-align: left; }
table.history tr.total th { font-family: var(--mono); }

.tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--line); }
.tabs a { padding: 10px 14px; color: var(--muted); text-decoration: none; border-bottom: 3px solid transparent; margin-bottom: -1px; }
.tabs a.active { color: var(--ink); font-weight: 600; border-bottom-color: var(--green); }

.area { background: var(--cream); border: 1px solid var(--line); border-radius: 4px; padding: 6px 18px 16px; margin: 16px 0; }
table.plan { width: 100%; margin: 10px 0; background: transparent; }
table.plan td:first-child input { min-height: 36px; }
td.spots { display: flex; flex-wrap: wrap; gap: 10px; }
.spot { border: 1px solid var(--line); border-top: 4px solid var(--green); border-radius: 4px; padding: 8px 10px; min-width: 200px; background: #fff; }
.spot.open { border-top-color: var(--red); }
.spot ul { margin: 6px 0; padding-left: 18px; }
.spot.add { background: none; border: 1px dashed var(--line-strong); }
li.conflict { color: var(--warn-text); font-weight: 600; }
li.conflict::after { content: " ⚠"; }
.filters, .picker { margin-bottom: 14px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }

/* Schedule: screen and A4 landscape print */
.schedule .block { background: #fff; margin: 0 0 16px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 4px; break-inside: avoid; }
.schedule .block header { display: flex; flex-wrap: wrap; gap: 6px 24px; align-items: center; border-bottom: 3px solid var(--ink); padding: 0 0 8px; margin-bottom: 8px; }
.schedule .block header h2 { margin: 0; font-size: 34px; }
.schedule .block header span { font-size: 17px; color: var(--ink); }
.schedule .block header .logo { margin-left: auto; height: 48px; width: auto; }
.schedule .block table { width: 100%; table-layout: fixed; background: #fff; }
.schedule .block th, .schedule .block td { border-color: var(--muted); }
.schedule .block th { font: 500 12px var(--mono); text-transform: uppercase; letter-spacing: 0.04em; }
.schedule .block th.time, .schedule .block td.time { width: 9.5em; }
.schedule .block td.time { font: 500 14px var(--mono); color: var(--ink); }
.schedule .block td div { padding: 1px 0; color: var(--ink); }
.schedule .block .empty { border-bottom: 1px dotted var(--muted); height: 1.4em; }
.schedule .na { color: var(--line-strong); }

@page { size: A4 landscape; margin: 8mm; }
@media print {
    body { background: #fff; font-size: 11pt; }
    nav, .no-print, main > h1 { display: none; }
    main { padding: 0; max-width: none; }
    .schedule .block { border: 0; padding: 0; }
    .schedule .block.split { break-after: page; }
    th { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
