/* Praktijk Diede Stoop 2.0 */

:root {
  color-scheme: light dark;
  /* Deze drie zet de app vanuit het scherm Uiterlijk & teksten; de rest wordt eruit afgeleid. */
  --accent-base: #4d6447;
  --bg-base: #f6f5f1;
  --on-accent: #ffffff;

  --bg: var(--bg-base);
  --surface: #ffffff;
  --ink: #1e2620;
  --muted: #5d685f;
  --accent: var(--accent-base);
  --accent-ink: var(--on-accent);
  --accent-soft: color-mix(in srgb, var(--accent) 14%, var(--surface));
  --brand: color-mix(in srgb, var(--accent) 60%, var(--surface));
  --surface-2: color-mix(in srgb, var(--bg) 95%, var(--ink));
  --line: color-mix(in srgb, var(--bg) 88%, var(--ink));
  --danger: #a5402d;
  --danger-soft: #f7e6e1;
  --warn: #8a5a12;
  --warn-soft: #faf0d9;
  --shadow: 0 1px 2px rgb(30 38 32 / .06), 0 8px 24px rgb(30 38 32 / .08);
  --radius: 14px;
  --side-w: 264px;
  --tab-h: 64px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #141814;
    --surface: #1d221d;
    --ink: #ecefe8;
    --muted: #a3ab9f;
    --accent: color-mix(in srgb, var(--accent-base) 50%, white);
    --accent-ink: #162014;
    --accent-soft: color-mix(in srgb, var(--accent) 18%, var(--surface));
    --surface-2: color-mix(in srgb, var(--bg) 90%, var(--ink));
    --line: color-mix(in srgb, var(--bg) 86%, var(--ink));
    --danger: #ea9480;
    --danger-soft: #3b2420;
    --warn: #e7c27a;
    --warn-soft: #382e17;
    --shadow: 0 1px 2px rgb(0 0 0 / .4), 0 8px 24px rgb(0 0 0 / .35);
  }
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
  min-height: 100dvh;
  overflow-wrap: anywhere;
}

h1, h2, h3, p { margin: 0; }
h1 { font-size: 1.75rem; line-height: 1.2; font-weight: 650; letter-spacing: -.02em; }
h2 { font-size: 1.125rem; line-height: 1.3; font-weight: 650; letter-spacing: -.01em; }
h3 { font-size: 1rem; font-weight: 650; }
a { color: var(--accent); text-underline-offset: 2px; }
small, .muted { color: var(--muted); }
small { font-size: .8125rem; }
[hidden] { display: none !important; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }

.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

.ic { width: 1.25em; height: 1.25em; flex: none; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }

/* ---------- Knoppen ---------- */

button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; -webkit-tap-highlight-color: transparent; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 44px; padding: 0 16px;
  border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface); color: var(--ink);
  font-weight: 600; text-decoration: none; white-space: nowrap;
  transition: background .15s, border-color .15s, transform .05s;
}
.btn:hover { background: var(--surface-2); }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn-primary:hover { background: var(--accent); filter: brightness(1.08); }
.btn-danger { color: var(--danger); }
.btn-danger:hover { background: var(--danger-soft); border-color: transparent; }
.btn-quiet { border-color: transparent; background: transparent; color: var(--accent); padding: 0 10px; }
.btn-quiet:hover { background: var(--accent-soft); }
.btn-block { width: 100%; }
.btn-sm { min-height: 36px; padding: 0 12px; font-size: .875rem; border-radius: 10px; }
.btn:disabled { opacity: .5; cursor: default; }

.icon-btn {
  display: inline-grid; place-items: center; width: 44px; height: 44px; flex: none;
  border: 0; border-radius: 12px; background: transparent; color: var(--ink);
}
.icon-btn:hover { background: var(--surface-2); }
.icon-btn .ic { width: 22px; height: 22px; }

/* ---------- Raamwerk ---------- */

.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 4px;
  padding: calc(env(safe-area-inset-top) + 6px) 8px 6px;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.topbar-title { flex: 1; font-weight: 650; font-size: 1.0625rem; }
.topbar-logo { border-radius: 50%; margin-right: 6px; }

.scrim { position: fixed; inset: 0; z-index: 30; background: rgb(0 0 0 / .45); }

.side {
  position: fixed; inset: 0 auto 0 0; z-index: 40;
  width: min(var(--side-w), 86vw);
  display: flex; flex-direction: column; gap: 16px;
  padding: calc(env(safe-area-inset-top) + 16px) 12px calc(env(safe-area-inset-bottom) + 16px);
  background: var(--surface); border-right: 1px solid var(--line);
  transform: translateX(-102%); visibility: hidden;
  transition: transform .22s ease, visibility 0s .22s;
  overflow-y: auto;
}
.side.open { transform: none; visibility: visible; transition: transform .22s ease; box-shadow: var(--shadow); }
.side-brand { display: flex; align-items: center; gap: 12px; padding: 0 4px 0 8px; }
.side-brand img { border-radius: 50%; }
.side-brand div { flex: 1; line-height: 1.25; }
.side-brand strong { display: block; font-size: 1.0625rem; }
.side-brand span { color: var(--muted); font-size: .8125rem; }
.side-new { margin: 0 4px; }
.side nav { display: grid; gap: 2px; }
.side nav a {
  display: flex; align-items: center; gap: 12px;
  min-height: 44px; padding: 0 12px; border-radius: 10px;
  color: var(--ink); text-decoration: none; font-weight: 500;
}
.side nav a:hover { background: var(--surface-2); }
.side nav a[aria-current="page"] { background: var(--accent-soft); color: var(--accent); font-weight: 650; }
.side nav a .ic { color: var(--muted); }
.side nav a[aria-current="page"] .ic { color: inherit; }
.side nav .nav-label { margin: 14px 12px 4px; font-size: .75rem; font-weight: 650; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.side nav .nav-badge { margin-left: auto; font-size: .75rem; font-weight: 650; color: var(--muted); }

main {
  max-width: 880px; margin: 0 auto;
  padding: 20px 16px calc(var(--tab-h) + env(safe-area-inset-bottom) + 32px);
  outline: none;
}

.tabbar {
  position: fixed; inset: auto 0 0 0; z-index: 20;
  display: grid; grid-template-columns: repeat(5, 1fr); align-items: center;
  height: calc(var(--tab-h) + env(safe-area-inset-bottom));
  padding-bottom: env(safe-area-inset-bottom);
  background: color-mix(in srgb, var(--surface) 92%, transparent);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--line);
}
.tabbar a, .tabbar button {
  display: grid; justify-items: center; gap: 2px;
  height: 100%; align-content: center;
  border: 0; background: none; color: var(--muted);
  font-size: .6875rem; font-weight: 600; text-decoration: none;
}
.tabbar a .ic { width: 22px; height: 22px; }
.tabbar a[aria-current="page"] { color: var(--accent); }
.tabbar .tab-add span {
  display: grid; place-items: center; width: 52px; height: 52px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink); box-shadow: var(--shadow);
  transform: translateY(-10px);
}
.tabbar .tab-add .ic { width: 26px; height: 26px; stroke-width: 2.2; }

@media (min-width: 900px) {
  body { padding-left: var(--side-w); }
  .topbar, .tabbar, .scrim, .side-close { display: none !important; }
  .side { transform: none; visibility: visible; width: var(--side-w); box-shadow: none; background: var(--bg); padding: 24px 14px; }
  main { padding: 36px 32px 64px; }
  h1 { font-size: 2rem; }
}

/* ---------- Pagina-onderdelen ---------- */

.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 20px; }
.page-head p { color: var(--muted); margin-top: 2px; }
.page-head .head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

.stack { display: grid; gap: 16px; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; }
.card > h2 { margin-bottom: 10px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.card-flush { padding: 0; overflow: hidden; }
.card-flush > h2, .card-flush > .card-head { padding: 16px 16px 0; }
.card-foot { padding: 4px 8px 8px; }

.stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.stat { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; min-width: 0; }
.stat small { display: block; }
.stat b { display: block; white-space: nowrap; font-size: 1.375rem; font-weight: 650; letter-spacing: -.02em; font-variant-numeric: tabular-nums; line-height: 1.3; }
.stat b.neg { color: var(--danger); }
@media (max-width: 420px) { .stat { padding: 10px; } .stat b { font-size: 1.125rem; } .seg button, .seg label span { padding: 0 11px; } }

.list { display: grid; }
.row {
  display: flex; align-items: center; gap: 12px; width: 100%;
  min-height: 60px; padding: 10px 16px;
  border: 0; border-top: 1px solid var(--line); background: none; text-align: left;
}
.list > .row:first-child { border-top: 0; }
button.row:hover { background: var(--surface-2); }
.row-time { flex: none; min-width: 3em; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.row-main { flex: 1; min-width: 0; display: grid; }
.row-main strong { font-weight: 600; }
.row-main small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-end { flex: none; display: grid; justify-items: end; gap: 2px; font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap; }
.row-end.plus { color: var(--accent); }
.row .ic.chev { color: var(--muted); }
.row.is-cancelled .row-main strong, .row.is-cancelled .row-time { text-decoration: line-through; color: var(--muted); }

.day-label { padding: 14px 16px 6px; font-size: .8125rem; font-weight: 650; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; border-top: 1px solid var(--line); }
.day-label:first-child { border-top: 0; }
.day-label + .row { border-top: 0; }
.day-label.is-today { color: var(--accent); }

.chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 99px; background: var(--surface-2); color: var(--muted); font-size: .75rem; font-weight: 600; white-space: nowrap; }
.chip-ok { background: var(--accent-soft); color: var(--accent); }
.chip-warn { background: var(--warn-soft); color: var(--warn); }
.chip .ic { width: 12px; height: 12px; }

.seg { display: inline-flex; padding: 3px; gap: 2px; background: var(--surface-2); border-radius: 12px; max-width: 100%; overflow-x: auto; }
.seg button, .seg label span {
  display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 0 14px;
  border: 0; border-radius: 9px; background: none; color: var(--muted); font-weight: 600; font-size: .9375rem; white-space: nowrap; cursor: pointer;
}
.seg button[aria-pressed="true"], .seg input:checked + span { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgb(0 0 0 / .12); }
.seg label { display: contents; }
.seg input { position: absolute; opacity: 0; pointer-events: none; }
.seg input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 1px; }
.seg-full { display: flex; }
.seg-full > *, .seg-full label span { flex: 1; }

.toolbar { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.month-nav { display: flex; align-items: center; gap: 2px; }
.month-nav b { min-width: 9.5em; text-align: center; font-weight: 650; text-transform: capitalize; }

.empty { padding: 28px 16px; text-align: center; display: grid; gap: 12px; justify-items: center; color: var(--muted); }
.empty .ic { width: 28px; height: 28px; opacity: .7; }

.banner { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 12px 14px; border-radius: var(--radius); background: var(--warn-soft); color: var(--warn); font-size: .9375rem; }
.banner span { flex: 1; min-width: 200px; }
.banner .btn { background: transparent; border-color: currentColor; color: inherit; }

.meter { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.meter i { display: block; height: 100%; border-radius: 99px; background: var(--accent); min-width: 2px; }
.meter-row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 6px; font-size: .9375rem; }
.meter-row strong { white-space: nowrap; font-variant-numeric: tabular-nums; }

.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; margin: 12px 0 16px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 500; }

/* ---------- Formulieren ---------- */

.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; min-width: 0; }
.field > span, .field-label { font-size: .875rem; font-weight: 600; }
.field em { font-style: normal; font-weight: 400; color: var(--muted); }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }

input[type="text"], input[type="number"], input[type="date"], input[type="time"], input[type="email"], select, textarea {
  width: 100%; min-height: 46px; padding: 10px 12px;
  border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface); color: var(--ink);
  font-size: 1rem; appearance: none; -webkit-appearance: none;
}
input[type="date"], input[type="time"] { min-width: 0; }
select {
  padding-right: 36px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23808a80' stroke-width='2.2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 12px center;
}
textarea { min-height: 220px; resize: vertical; line-height: 1.5; }
textarea.short { min-height: 130px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 2px solid var(--accent); outline-offset: 0; border-color: transparent; }
input[type="file"] { width: 100%; font-size: .9375rem; }
input[type="file"]::file-selector-button { min-height: 40px; margin-right: 12px; padding: 0 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); color: var(--ink); font: inherit; font-weight: 600; }
.sheet input:not([type="file"]), .sheet select, .sheet textarea { background: var(--bg); }

.form-error { padding: 10px 12px; border-radius: 10px; background: var(--danger-soft); color: var(--danger); font-size: .9375rem; }
.form-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.form-actions .btn-primary { flex: 1; }
.file-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 8px 12px; border: 1px solid var(--line); border-radius: 12px; }
.file-line span { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.switch { position: relative; width: 48px; height: 28px; flex: none; border: 0; border-radius: 99px; background: var(--line); transition: background .15s; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgb(0 0 0 / .3); transition: transform .15s; }
.switch[aria-checked="true"] { background: var(--accent); }
.switch[aria-checked="true"]::after { transform: translateX(20px); }

/* ---------- Startplan ---------- */

.task { display: flex; gap: 12px; align-items: flex-start; padding: 12px 16px; border-top: 1px solid var(--line); cursor: pointer; }
.task:hover { background: var(--surface-2); }
.task input { appearance: none; -webkit-appearance: none; flex: none; width: 24px; height: 24px; margin: 2px 0 0; border: 2px solid var(--brand); border-radius: 8px; display: grid; place-items: center; cursor: pointer; }
.task input:checked { background: var(--accent); border-color: var(--accent); }
.task input:checked::after { content: ""; width: 11px; height: 6px; border: solid var(--accent-ink); border-width: 0 0 2.5px 2.5px; transform: rotate(-45deg) translate(1px, -1px); }
.task span { display: grid; }
.task input:checked + span strong { text-decoration: line-through; color: var(--muted); font-weight: 500; }
.phase-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; padding: 16px 16px 10px; }

details.faq { border-top: 1px solid var(--line); }
details.faq:first-of-type { border-top: 0; }
details.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 16px; font-weight: 600; cursor: pointer; list-style: none; }
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary .ic { color: var(--muted); transition: transform .15s; }
details.faq[open] summary .ic { transform: rotate(180deg); }
details.faq .faq-body { padding: 0 16px 16px; display: grid; gap: 8px; }
.faq-group { padding: 16px 16px 4px; font-size: .8125rem; font-weight: 650; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }

.loc-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; }
.loc-grid .card { display: grid; gap: 6px; align-content: start; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips .chip { padding: 6px 6px 6px 12px; font-size: .875rem; color: var(--ink); }
.chips .chip button { display: grid; place-items: center; width: 24px; height: 24px; border: 0; border-radius: 50%; background: none; color: var(--muted); }
.chips .chip button:hover { background: var(--line); }
.inline-form { display: flex; gap: 8px; margin-top: 12px; }
.inline-form input { flex: 1; }

.calc-out { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; }
.note { font-size: .875rem; color: var(--muted); }
.setting { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; border-top: 1px solid var(--line); }
.setting:first-of-type { border-top: 0; }
.setting > div:first-child { display: grid; }
.setting input[type="number"] { width: 96px; text-align: right; }

/* ---------- Venster (onderaan op telefoon, midden op groot scherm) ---------- */

dialog.sheet {
  width: min(540px, 100%); max-width: 100%; max-height: min(90dvh, 780px);
  margin: auto; padding: 0; border: 0; border-radius: 20px;
  background: var(--surface); color: var(--ink); box-shadow: var(--shadow);
  overflow: hidden;
}
dialog.sheet::backdrop { background: rgb(0 0 0 / .45); }
dialog.sheet[open] { display: flex; }
.sheet-inner { display: flex; flex-direction: column; width: 100%; min-height: 0; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 12px 10px 4px 20px; }
.sheet-body { padding: 8px 20px calc(20px + env(safe-area-inset-bottom)); overflow-y: auto; overscroll-behavior: contain; }
.sheet-menu { display: grid; gap: 8px; }
.sheet-menu button { display: flex; align-items: center; gap: 14px; min-height: 60px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--bg); text-align: left; }
.sheet-menu button:hover { border-color: var(--accent); }
.sheet-menu button > .ic { width: 24px; height: 24px; color: var(--accent); }
.sheet-menu button span { display: grid; }
.sheet-menu button strong { font-weight: 600; }
.detail-when { color: var(--muted); }
.detail-title { font-size: 1.375rem; font-weight: 650; letter-spacing: -.02em; }
.actions { display: grid; gap: 8px; }
.preview { max-width: 100%; border-radius: 12px; border: 1px solid var(--line); }

@media (max-width: 599px) {
  dialog.sheet { margin: auto 0 0; width: 100%; border-radius: 20px 20px 0 0; max-height: 92dvh; }
}

@media (prefers-reduced-motion: no-preference) {
  dialog.sheet[open] { animation: sheet-in .22s ease; }
  dialog.sheet[open]::backdrop { animation: fade-in .22s ease; }
  .toast { animation: toast-in .2s ease; }
  main.enter { animation: page-in .18s ease; }
}
@keyframes sheet-in { from { transform: translateY(24px); opacity: 0; } }
@keyframes fade-in { from { opacity: 0; } }
@keyframes page-in { from { opacity: 0; transform: translateY(6px); } }
@keyframes toast-in { from { transform: translateY(8px); opacity: 0; } }

/* ---------- Meldingen ---------- */

.toasts { position: fixed; z-index: 60; left: 12px; right: 12px; bottom: calc(var(--tab-h) + env(safe-area-inset-bottom) + 18px); display: grid; gap: 8px; justify-items: center; pointer-events: none; }
.toast { display: flex; align-items: center; gap: 12px; max-width: 460px; padding: 10px 10px 10px 16px; border-radius: 12px; background: var(--ink); color: var(--bg); box-shadow: var(--shadow); pointer-events: auto; font-size: .9375rem; }
.toast button { min-height: 36px; padding: 0 10px; border: 0; border-radius: 8px; background: none; color: inherit; font-weight: 700; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
@media (min-width: 900px) { .toasts { bottom: 24px; left: calc(var(--side-w) + 12px); } }

@media print {
  .topbar, .tabbar, .side, .toasts, .btn, .seg { display: none !important; }
  body { padding: 0; background: #fff; }
  .card, .stat { border-color: #ccc; }
}

/* Rij met een aanklikbaar deel en een schakelaar ernaast */
.row-link { flex: 1; min-width: 0; min-height: 40px; display: grid; align-content: center; padding: 0; border: 0; background: none; text-align: left; }
.row-link strong { font-weight: 600; }
.row-link:hover strong { color: var(--accent); }

/* ---------- Uiterlijk & teksten ---------- */

.swatches { display: flex; flex-wrap: wrap; gap: 8px; }
.swatch { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px 0 10px; border: 1px solid var(--line); border-radius: 99px; background: var(--surface); font-weight: 600; font-size: .875rem; }
.swatch i { width: 20px; height: 20px; border-radius: 50%; border: 1px solid rgb(0 0 0 / .15); }
.swatch i + i { margin-left: -8px; }
.swatch span { margin-left: 8px; }
.swatch[aria-pressed="true"] { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
input[type="color"] { width: 100%; height: 46px; padding: 4px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); cursor: pointer; }
code { padding: 1px 5px; border-radius: 5px; background: var(--surface-2); font-size: .875em; }

/* ---------- Jaaroverzicht ---------- */

.fill { display: grid; margin-top: 4px; }
.fill-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 11px 0; border-top: 1px solid var(--line); }
.fill-row:first-child { border-top: 0; }
.fill-row > span:first-child { display: grid; gap: 2px; min-width: 0; }
.fill-row strong { font-weight: 600; hyphens: auto; overflow-wrap: break-word; }
.fill-row small { color: var(--muted); font-size: .8125rem; line-height: 1.4; }
.fill-row b { font-size: 1.0625rem; font-weight: 650; font-variant-numeric: tabular-nums; white-space: nowrap; }
.fill-row.total { border-top: 2px solid var(--ink); }
.fill-row.total b { color: var(--accent); }
.fill-row .pair { display: flex; gap: 8px; flex: none; }
.fill-row .pair > * { min-width: 4.1em; text-align: right; }
.fill-row .pair b { font-size: 1rem; }
.fill-head { padding-bottom: 0; }
.fill-head + .fill-row { border-top: 0; }
a.row { color: inherit; text-decoration: none; }
a.row:hover { background: var(--surface-2); }
.icon-btn:disabled { opacity: .3; pointer-events: none; }
.month-nav b { font-variant-numeric: tabular-nums; }
.setting input[data-bank] { width: 120px; }

@media print {
  .no-print, .banner, .icon-btn, .head-actions, .toolbar .seg, .form-actions { display: none !important; }
  .fill-row.total b { color: inherit; }
}

/* Teller bij Vandaag in de tabbalk */
.tabbar a { position: relative; }
.tabbar .nav-badge { position: absolute; top: 4px; left: calc(50% + 5px); min-width: 16px; height: 16px; padding: 0 4px; border-radius: 8px; background: var(--warn); color: var(--surface); font-size: .6875rem; font-weight: 700; line-height: 16px; text-align: center; }

/* ---------- Toegangscode ---------- */

dialog.lock { width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 24px; border: 0; background: var(--bg); color: var(--ink); }
dialog.lock[open] { display: grid; place-items: center; }
dialog.lock::backdrop { background: var(--bg); }
.lock-box { display: grid; gap: 14px; justify-items: stretch; width: min(100%, 300px); text-align: center; }
.lock-box img { justify-self: center; }
.lock-box h2 { font-size: 1.25rem; }
.lock-box p { color: var(--muted); font-size: .9375rem; }
input.pin { -webkit-text-security: disc; text-align: center; font-size: 1.5rem; letter-spacing: .3em; }
.form input.pin { text-align: left; font-size: 1.125rem; }
@media print { dialog.lock { display: none !important; } }

/* ---------- Kop op het scherm Vandaag ---------- */

:root { --hero-bg: color-mix(in srgb, var(--accent) 6%, var(--surface)); }
.hero {
  position: relative; overflow: hidden;
  margin: -20px -16px 16px; padding: 0 16px 78px;
  background: var(--hero-bg);
}
.hero-brand { position: relative; z-index: 1; display: flex; align-items: center; justify-content: center; gap: 12px; }
.hero-brand img { border-radius: 50%; flex: none; }
.hero-brand div { display: grid; gap: 1px; min-width: 0; }
.hero-brand strong { font-size: 1.0625rem; font-weight: 650; line-height: 1.2; color: var(--accent); }
.hero-brand span { font-size: .8125rem; color: var(--muted); }
/* De golf uit het concept: links een lichte baan die naar het midden zakt, rechts een heuvel die oploopt. */
.hero-wave { position: absolute; inset: auto 0 0 0; display: block; width: 100%; height: clamp(80px, 21vw, 124px); }
.hero-wave .w1 { fill: color-mix(in srgb, var(--accent) 20%, var(--hero-bg)); }
.hero-wave .w2 { fill: color-mix(in srgb, var(--accent) 34%, var(--hero-bg)); }
.hero-wave .w3 { fill: var(--bg); }
body.on-home .topbar { background: color-mix(in srgb, var(--hero-bg) 90%, transparent); border-bottom-color: transparent; }
body.on-home .topbar-title, body.on-home .topbar-logo { visibility: hidden; }
@media (min-width: 900px) { .hero { margin: 0 0 28px; padding-top: 28px; border-radius: var(--radius); } }
@media print { .hero { display: none; } }
