:root {
  color-scheme: light;
  --forest: #173d34;
  --forest-deep: #12332c;
  --forest-mid: #2a5a4e;
  --leaf: #d4eb91;
  --leaf-deep: #b9d76e;
  --paper: #f6f5f0;
  --surface: #ffffff;
  --surface-soft: #fbfaf7;
  --line: #e9e8e0;
  --line-strong: #dcddd3;
  --ink: #202a27;
  --ink-soft: #66716c;
  --muted: #89918c;
  --coral: #ed896e;
  --lilac: #a99bc5;
  --amber: #e5b864;
  --blue: #85aeb3;
  --shadow: 0 18px 60px rgba(24, 46, 39, .08);
  --sans: -apple-system, BlinkMacSystemFont, 'Aptos', 'Segoe UI', sans-serif;
  --serif: 'Iowan Old Style', 'Palatino Linotype', 'Book Antiqua', Georgia, serif;
}

* { box-sizing: border-box; }

html { min-width: 320px; background: var(--paper); scroll-behavior: smooth; scroll-padding-top: 16px; }

body {
  min-height: 100vh;
  min-height: 100dvh;
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: var(--sans);
  font-size: 14px;
  -webkit-font-smoothing: antialiased;
}

button, input, select, textarea { font: inherit; }
button { color: inherit; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
button, a, select { touch-action: manipulation; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(128, 168, 124, .65); outline-offset: 3px; }
[hidden] { display: none !important; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; }

/* Inloggen en account aanmaken */
.auth-screen { min-height: 100vh; display: grid; grid-template-columns: minmax(430px, 1.02fr) minmax(430px, .98fr); background: var(--surface); }
.auth-story { min-height: 100vh; min-height: 100dvh; position: relative; isolation: isolate; overflow: hidden; display: flex; flex-direction: column; padding: 38px clamp(38px, 6.2vw, 102px) 26px; color: #f4f4e9; background: var(--forest); }
.auth-story::before, .auth-story::after { content: ''; position: absolute; z-index: -1; border-radius: 50%; pointer-events: none; }
.auth-story::before { width: 660px; height: 660px; left: -330px; top: 20%; border: 1px solid rgba(212, 235, 145, .10); box-shadow: 0 0 0 54px rgba(212, 235, 145, .025), 0 0 0 108px rgba(212, 235, 145, .022), 0 0 0 162px rgba(212, 235, 145, .018); }
.auth-story::after { width: 340px; height: 340px; right: -210px; bottom: -145px; background: rgba(212, 235, 145, .055); }
.brand { display: inline-flex; width: fit-content; align-items: center; gap: 11px; color: inherit; text-decoration: none; }
.brand-name { font-size: 23px; letter-spacing: -.075em; font-weight: 700; }
.brand-name > span { color: var(--leaf); }
.brand-symbol { display: inline-flex; align-items: flex-end; gap: 3px; height: 25px; padding: 4px 5px; border: 1px solid rgba(212, 235, 145, .46); border-radius: 8px; }
.brand-symbol span { width: 3px; border-radius: 3px; background: var(--leaf); }
.brand-symbol span:nth-child(1) { height: 7px; opacity: .7; }
.brand-symbol span:nth-child(2) { height: 13px; }
.brand-symbol span:nth-child(3) { height: 9px; opacity: .83; }
.story-copy { margin-top: clamp(50px, 8vh, 92px); max-width: 500px; }
.eyebrow { margin: 0 0 10px; color: #8b978f; font-size: 10px; font-weight: 700; letter-spacing: .13em; line-height: 1.5; }
.eyebrow-light { display: flex; align-items: center; gap: 9px; color: #b8c6ad; }
.eyebrow-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--leaf); box-shadow: 0 0 0 4px rgba(212, 235, 145, .1); }
.story-copy h1 { margin: 21px 0 19px; color: #f5f4eb; font-family: var(--serif); font-size: clamp(54px, 6vw, 78px); font-weight: 400; letter-spacing: -.045em; line-height: .99; }
.story-copy h1 em { color: var(--leaf); font-weight: 400; }
.story-copy > p:last-child { max-width: 380px; margin: 0; color: #b9c6be; font-size: 15px; line-height: 1.8; }
.story-preview { width: min(100%, 416px); margin: auto 0 16px; padding: 21px 24px 14px; color: var(--ink); background: #f7f6f0; border: 1px solid rgba(255,255,255,.38); border-radius: 16px; box-shadow: 0 26px 80px rgba(0,0,0,.2); transform: rotate(-1.1deg); }
.preview-topline, .preview-date, .preview-event, .preview-bottom { display: flex; align-items: center; }
.preview-topline { justify-content: space-between; color: #8c968f; font-size: 8px; font-weight: 700; letter-spacing: .14em; }
.preview-date { position: relative; gap: 11px; padding: 11px 0 14px; border-bottom: 1px solid #e4e4da; }
.preview-date > strong { font-family: var(--serif); font-size: 37px; font-weight: 400; line-height: 1; }
.preview-date > span:nth-child(2) { color: #68726c; font-size: 10px; line-height: 1.45; }
.preview-sun { margin-left: auto; color: #aac56e; font-size: 29px; }
.preview-event { min-height: 48px; gap: 10px; border-bottom: 1px solid #ecebe3; }
.preview-time { width: 38px; color: #7b857f; font-size: 10px; font-variant-numeric: tabular-nums; }
.preview-event-mark { width: 4px; height: 27px; border-radius: 5px; background: #60927d; }
.preview-event-peach .preview-event-mark { background: var(--coral); }
.preview-event-lilac .preview-event-mark { background: var(--lilac); }
.preview-event > span:last-child { display: grid; gap: 2px; }
.preview-event strong { font-size: 11px; font-weight: 600; }
.preview-event small { color: #89928c; font-size: 9px; }
.preview-bottom { gap: 8px; padding-top: 12px; color: #818b84; font-size: 9px; }
.preview-avatar { width: 20px; height: 20px; display: grid; place-items: center; color: var(--forest); background: var(--leaf); border-radius: 50%; font-size: 9px; font-weight: 700; }
.preview-check { margin-left: auto; color: #69927b; font-size: 16px; }
.story-note { display: flex; justify-content: space-between; width: min(100%, 416px); margin: 4px 0 0; color: #a8b6ae; font-size: 10px; letter-spacing: .04em; }
.story-note span { color: var(--leaf); }
.auth-panel { position: relative; display: flex; flex-direction: column; justify-content: center; padding: 48px clamp(38px, 7vw, 112px); background: var(--surface); }
.auth-panel-inner { width: min(100%, 420px); margin: 8px auto; }
.auth-mobile-brand { display: none; }
.auth-heading-block { margin-bottom: 27px; }
.auth-heading-block .eyebrow { color: #879187; }
.auth-heading-block h2 { margin: 0 0 7px; color: var(--ink); font-family: var(--serif); font-size: 36px; font-weight: 400; letter-spacing: -.025em; }
.auth-heading-block > p:last-child { margin: 0; color: var(--ink-soft); font-size: 13px; line-height: 1.65; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 3px; margin-bottom: 22px; padding: 4px; background: #f3f4ef; border-radius: 9px; }
.auth-tab { min-height: 39px; padding: 7px 12px; color: #778079; background: transparent; border: 0; border-radius: 6px; cursor: pointer; font-size: 12px; font-weight: 600; transition: color .18s ease, background .18s ease, box-shadow .18s ease; }
.auth-tab.is-active { color: var(--forest); background: #fff; box-shadow: 0 2px 8px rgba(34, 54, 43, .08); }
.auth-form { display: grid; gap: 15px; }
.field { display: grid; min-width: 0; gap: 7px; }
.field > span { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; color: #3b4640; font-size: 11px; font-weight: 600; }
.field > span small { color: #9ca49d; font-size: 10px; font-weight: 400; }
.field input, .field select, .field textarea { width: 100%; min-height: 43px; padding: 10px 12px; color: var(--ink); background: #fff; border: 1px solid #dedfd7; border-radius: 7px; outline: none; transition: border-color .17s ease, box-shadow .17s ease; }
.field textarea { resize: vertical; line-height: 1.55; }
.field input::placeholder, .field textarea::placeholder { color: #adb3ae; }
.field input:hover, .field select:hover, .field textarea:hover { border-color: #bec7bd; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: #719985; box-shadow: 0 0 0 3px rgba(113, 153, 133, .13); }
.auth-form .field { gap: 8px; }
.auth-submit { width: 100%; margin-top: 5px; }
.button { display: inline-flex; min-height: 39px; align-items: center; justify-content: center; gap: 9px; padding: 9px 15px; border: 1px solid transparent; border-radius: 7px; cursor: pointer; font-size: 12px; font-weight: 600; transition: background .17s ease, color .17s ease, border-color .17s ease, transform .17s ease, box-shadow .17s ease; }
.button:active { transform: translateY(1px) scale(.985); }
.button-primary { color: #23372d; background: var(--leaf); border-color: var(--leaf); box-shadow: 0 3px 8px rgba(116, 147, 70, .09); }
.button-primary:hover { background: #c9e47f; border-color: #c9e47f; box-shadow: 0 4px 14px rgba(116, 147, 70, .19); }
.button-primary:disabled { opacity: .65; cursor: wait; }
.button-primary > span { font-size: 16px; line-height: .7; }
.button-quiet { color: #536159; background: #fff; border-color: var(--line-strong); }
.button-quiet:hover { color: var(--forest); background: #f7f8f2; border-color: #b6c0b5; }
.button-danger { color: #b65041; background: #fff; border-color: #efd2cb; }
.button-danger:hover { background: #fff6f3; border-color: #e9b8ac; }
.form-message { min-height: 18px; margin: 0; color: #b55245; font-size: 11px; line-height: 1.6; }
.form-message:empty { display: none; }
.form-message.is-success { color: #4e7655; }
.auth-security { display: flex; align-items: center; gap: 8px; margin: 24px 0 0; padding-top: 18px; color: #818b84; border-top: 1px solid #ecece6; font-size: 10px; }
.auth-security span { color: #789d81; font-size: 17px; }
.auth-step-copy { margin: -3px 0 1px; color: #748078; font-size: 11px; line-height: 1.65; }
.signup-address { display: grid; gap: 3px; margin: -2px 0 2px; padding: 11px 13px; background: #f7f8f3; border: 1px solid #edf0e6; border-radius: 7px; }
.signup-address > span { color: #8e988f; font-size: 9px; }
.signup-address > strong { overflow-wrap: anywhere; color: #41594a; font-size: 11px; }
.text-link { width: fit-content; padding: 0; color: #577a62; background: transparent; border: 0; cursor: pointer; font-size: 10px; text-decoration: underline; text-underline-offset: 2px; }
.text-link:hover { color: #2d523b; }
.resend-row { display: flex; flex-wrap: wrap; align-items: center; gap: 5px; margin: -7px 0 0; color: #929b94; font-size: 10px; }
.resend-row button:disabled { color: #9da79f; cursor: wait; }
.auth-back-link { justify-self: center; margin-top: 0; }
.auth-admin-link { display: block; margin: 16px auto 0; padding: 5px; color: #87928a; background: transparent; border: 0; cursor: pointer; font-size: 10px; }
.auth-admin-link:hover { color: #48634e; }
.auth-admin-link span { margin-left: 3px; }
.auth-footer { position: absolute; right: 38px; bottom: 22px; left: 38px; margin: 0; color: #9aa19b; text-align: center; font-size: 10px; letter-spacing: .02em; }

/* Ingelogde agenda */
.app-shell { min-height: 100vh; min-height: 100dvh; display: grid; grid-template-columns: 238px minmax(0, 1fr); }
.sidebar { position: sticky; top: 0; display: flex; height: 100vh; height: 100dvh; min-height: 660px; flex-direction: column; padding: 27px max(18px, env(safe-area-inset-right)) calc(16px + env(safe-area-inset-bottom)) max(18px, env(safe-area-inset-left)); color: #f0f3ea; background: var(--forest); }
.sidebar-brand { margin: 0 0 49px 8px; }
.sidebar .brand-name { font-size: 21px; }
.sidebar-section-label { margin: 0 0 13px 11px; color: #91a49a; font-size: 9px; font-weight: 700; letter-spacing: .13em; }
.primary-nav { display: grid; gap: 6px; }
.nav-item { position: relative; display: flex; min-height: 42px; align-items: center; gap: 11px; padding: 0 11px; color: #bbcac0; background: transparent; border: 0; border-radius: 7px; cursor: pointer; text-align: left; font-size: 12px; transition: color .15s ease, background .15s ease, transform .15s ease; }
.nav-item:active { transform: scale(.985); }
.nav-item:hover { color: #fff; background: rgba(255,255,255,.055); }
.nav-item.is-active { color: #f6f6ea; background: rgba(236, 244, 219, .115); }
.nav-item.is-active::before { position: absolute; top: 9px; bottom: 9px; left: 0; width: 3px; border-radius: 0 3px 3px 0; background: var(--leaf); content: ''; }
.nav-item > svg { width: 17px; height: 17px; flex: 0 0 auto; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.nav-count { display: grid; min-width: 21px; height: 20px; place-items: center; margin-left: auto; color: #bdcabf; background: rgba(255,255,255,.085); border-radius: 6px; font-size: 10px; font-variant-numeric: tabular-nums; }
.nav-item.is-active .nav-count { color: #ecf0dc; background: rgba(212,235,145,.15); }
.sidebar-rule { height: 1px; margin: 24px 9px 23px; background: rgba(226, 235, 224, .13); }
.sidebar-section-flex { display: flex; align-items: center; justify-content: space-between; margin-right: 9px; }
.sidebar-text-button { padding: 0; color: #c4d5ae; background: none; border: 0; cursor: pointer; font-size: 9px; }
.sidebar-text-button:hover { color: #fff; }
.sidebar-day-card { display: flex; min-height: 61px; align-items: center; gap: 11px; padding: 8px 10px; background: rgba(255,255,255,.07); border: 1px solid rgba(255,255,255,.045); border-radius: 9px; }
.sidebar-day-number { display: grid; width: 34px; height: 37px; place-items: center; color: var(--forest); background: var(--leaf); border-radius: 7px; font-size: 15px; font-weight: 700; }
.sidebar-day-card > span:nth-child(2) { display: grid; gap: 3px; }
.sidebar-day-card strong { color: #eef1e8; font-size: 11px; font-weight: 600; }
.sidebar-day-card small { color: #a9b8ac; font-size: 9px; }
.sidebar-day-spark { margin-left: auto; align-self: flex-start; color: var(--leaf); font-size: 15px; }
.category-label { margin-top: 31px; }
.category-legend { display: grid; gap: 13px; padding: 2px 10px; color: #bbc9c0; font-size: 10px; }
.category-legend > span { display: flex; align-items: center; gap: 10px; }
.legend-dot { width: 7px; height: 7px; border-radius: 50%; }
.dot-work { background: #94bea0; }
.dot-personal { background: #eeaa8e; }
.dot-health { background: #c2b0e0; }
.dot-family { background: #e7c66e; }
.dot-other { background: #93b7bd; }
.sidebar-spacer { flex: 1; min-height: 25px; }
.sidebar-account { display: flex; min-height: 53px; align-items: center; gap: 9px; padding: 9px 6px 0; border-top: 1px solid rgba(226, 235, 224, .13); }
.user-avatar { display: grid; width: 30px; height: 30px; flex: 0 0 auto; place-items: center; color: var(--forest); background: var(--leaf); border-radius: 50%; font-size: 10px; font-weight: 700; }
.account-label { display: grid; min-width: 0; gap: 3px; }
.account-label strong, .account-label small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.account-label strong { max-width: 120px; color: #edf1e8; font-size: 10px; font-weight: 600; }
.account-label small { max-width: 130px; color: #9eafa4; font-size: 9px; }
.icon-button { display: grid; width: 32px; height: 32px; flex: 0 0 auto; place-items: center; color: #66716a; background: transparent; border: 1px solid transparent; border-radius: 7px; cursor: pointer; transition: background .16s ease, border .16s ease, color .16s ease, transform .16s ease; }
.icon-button:active { transform: scale(.94); }
.icon-button:hover { color: var(--forest); background: #f3f5ef; border-color: #e7e9e1; }
.icon-button > svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.sidebar-logout { width: 29px; height: 29px; margin-left: auto; color: #abc0b3; }
.sidebar-logout:hover { color: var(--forest); }

.main-content { min-width: 0; max-width: 1780px; width: 100%; margin: 0 auto; padding: calc(27px + env(safe-area-inset-top)) max(clamp(24px, 4vw, 64px), env(safe-area-inset-right)) calc(17px + env(safe-area-inset-bottom)) max(clamp(24px, 4vw, 64px), env(safe-area-inset-left)); }
.topbar { display: flex; min-height: 67px; align-items: center; justify-content: space-between; gap: 24px; }
.page-heading .eyebrow { margin-bottom: 3px; }
.page-heading h1 { display: inline; margin: 0; color: var(--ink); font-family: var(--serif); font-size: 29px; font-weight: 400; letter-spacing: -.02em; }
.page-date { display: inline; margin: 0 0 0 10px; color: #909890; font-size: 11px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.search-box { display: flex; width: min(245px, 22vw); min-height: 39px; align-items: center; gap: 8px; padding: 0 9px 0 11px; background: #fff; border: 1px solid var(--line); border-radius: 7px; transition: border-color .15s ease, box-shadow .15s ease; }
.search-box:focus-within { border-color: #adc2aa; box-shadow: 0 0 0 3px rgba(113, 153, 133, .09); }
.search-box > svg { width: 15px; height: 15px; flex: 0 0 auto; fill: none; stroke: #87928b; stroke-width: 1.7; stroke-linecap: round; }
.search-box input { width: 100%; min-width: 0; padding: 0; color: var(--ink); background: transparent; border: 0; outline: 0; font-size: 10px; }
.search-box input::placeholder { color: #a0a8a1; }
.search-box kbd { flex: 0 0 auto; padding: 3px 4px; color: #9ba39c; background: #f5f5f1; border: 1px solid #eeefe9; border-radius: 4px; font-family: var(--sans); font-size: 8px; }
.top-add-button { min-height: 38px; white-space: nowrap; }
.dashboard-intro { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin: 31px 0 19px; }
.dashboard-intro .eyebrow { margin-bottom: 5px; color: #929b92; }
.dashboard-intro h2 { margin: 0; color: var(--forest); font-family: var(--serif); font-size: clamp(25px, 2.6vw, 32px); font-weight: 400; letter-spacing: -.025em; }
.intro-note { display: inline-flex; align-items: center; gap: 7px; padding-bottom: 4px; color: #7e8b80; font-size: 10px; white-space: nowrap; }
.intro-note > span { color: #a3bd76; font-size: 14px; }
.summary-row { display: flex; min-height: 70px; align-items: center; gap: clamp(15px, 2.3vw, 32px); margin-bottom: 17px; padding: 11px 17px; background: var(--surface); border: 1px solid #eeeee8; border-radius: 9px; }
.summary-card { display: flex; min-width: 115px; align-items: center; gap: 10px; transition: transform .18s ease; }
.summary-main { min-width: 190px; }
.summary-icon { display: grid; width: 31px; height: 31px; flex: 0 0 auto; place-items: center; color: #65866a; background: #edf3e5; border-radius: 9px; font-size: 15px; }
.summary-icon-amber { color: #ad8545; background: #fbf1df; }
.summary-icon-lilac { color: #8273a5; background: #f0edf7; }
.summary-card > div { display: flex; align-items: baseline; gap: 7px; white-space: nowrap; }
.summary-card strong { color: #25342d; font-size: 16px; font-weight: 700; font-variant-numeric: tabular-nums; }
.summary-card span:last-child { color: #828b84; font-size: 10px; }
.summary-divider { width: 1px; height: 30px; background: #ecece6; }
.export-button { display: inline-flex; min-height: 35px; align-items: center; gap: 7px; margin-left: auto; padding: 0 9px; color: #69796d; background: #f7f8f3; border: 1px solid #e9ede3; border-radius: 6px; cursor: pointer; font-size: 9px; transition: background .15s ease, border-color .15s ease; }
.export-button:hover { background: #edf2e4; border-color: #d9e4cf; }
.export-button svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }

.view-section { display: none; }
.view-section.is-visible { display: block; animation: section-arrive .2s ease-out both; }
@keyframes section-arrive { from { opacity: .65; transform: translateY(5px); } to { opacity: 1; transform: translateY(0); } }
.calendar-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(272px, 316px); align-items: stretch; gap: 16px; }
.panel { min-width: 0; background: var(--surface); border: 1px solid #edeee8; border-radius: 10px; box-shadow: 0 3px 10px rgba(37, 51, 43, .018); }
.calendar-panel { overflow: hidden; padding: 0 19px 14px; }
.calendar-scroll { min-width: 0; }
.calendar-toolbar { display: flex; min-height: 72px; align-items: center; justify-content: space-between; gap: 13px; border-bottom: 1px solid #f0f0eb; }
.calendar-period-control { display: flex; align-items: center; gap: 5px; }
.period-arrow { width: 27px; height: 28px; }
.period-arrow > svg { width: 14px; height: 14px; }
.calendar-period-control h2 { min-width: 125px; margin: 0 8px; color: #28362f; font-family: var(--serif); font-size: 20px; font-weight: 400; letter-spacing: -.01em; }
.calendar-period-control .button { min-height: 29px; margin-left: 3px; padding: 5px 9px; font-size: 9px; }
.calendar-toolbar-side { display: flex; align-items: center; gap: 9px; }
.filter-select-label select { max-width: 132px; min-height: 30px; padding: 4px 22px 4px 9px; color: #6d7971; background-color: #fff; border: 1px solid #eceee7; border-radius: 6px; font-size: 9px; }
.view-switch { display: flex; padding: 3px; background: #f3f4ef; border-radius: 6px; }
.view-switch button { min-height: 25px; padding: 4px 8px; color: #7c857f; background: transparent; border: 0; border-radius: 4px; cursor: pointer; font-size: 9px; transition: color .16s ease, background .16s ease, box-shadow .16s ease, transform .16s ease; }
.view-switch button.is-active { color: #33483b; background: #fff; box-shadow: 0 1px 4px rgba(40,54,42,.1); font-weight: 600; }
.weekday-row { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); min-height: 34px; align-items: center; border-bottom: 1px solid #f1f1ec; }
.weekday-row span { padding-left: 7px; color: #9aa29b; font-size: 9px; font-weight: 600; }
.calendar-grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); grid-template-rows: repeat(6, minmax(94px, auto)); }
.calendar-day { min-width: 0; min-height: 94px; overflow: hidden; padding: 7px 5px 5px; text-align: left; background: #fff; border: 0; border-right: 1px solid #f0f0eb; border-bottom: 1px solid #f0f0eb; cursor: pointer; transition: background .13s ease; }
.calendar-day:nth-child(7n) { border-right: 0; }
.calendar-day.selected { background: #f7f8f2; box-shadow: inset 0 0 0 1px rgba(84, 125, 95, .18); }
.calendar-day:active { background: #eef4e7; transform: scale(.99); }
.calendar-day.is-selected-pop { animation: selected-day-pop .24s cubic-bezier(.2,.8,.2,1) both; }
@keyframes selected-day-pop { 0% { transform: scale(.97); } 65% { transform: scale(1.012); } 100% { transform: scale(1); } }
@media (hover: hover) { .calendar-day:hover { background: #fbfcf8; } }
.calendar-day.outside .day-number { color: #c6cbc5; }
.calendar-day.today .day-number { color: #fff; background: var(--forest-mid); }
.day-number { display: grid; width: 23px; height: 23px; place-items: center; margin: 0 0 5px 1px; color: #536058; border-radius: 50%; font-size: 10px; font-weight: 500; font-variant-numeric: tabular-nums; }
.calendar-day.today.selected .day-number { background: #244b3f; }
.day-events { display: grid; gap: 3px; }
.mini-event { display: block; overflow: hidden; padding: 3px 5px; color: #42634e; background: #eaf1e5; border-left: 2px solid #82a987; border-radius: 3px; text-overflow: ellipsis; white-space: nowrap; font-size: 8px; line-height: 1.35; }
.mini-event.personal { color: #975d4f; background: #fbede8; border-left-color: #e39a7b; }
.mini-event.health { color: #695984; background: #f1edf8; border-left-color: #a798c5; }
.mini-event.family { color: #846b39; background: #faf3df; border-left-color: #ddbb68; }
.mini-event.other { color: #4c7479; background: #eaf2f2; border-left-color: #86adb2; }
.mini-event.completed { opacity: .59; text-decoration: line-through; }
.mini-event.all-day { font-weight: 600; }
.more-events { padding: 2px 4px; color: #88928b; font-size: 8px; }
.calendar-grid.week-mode { grid-template-rows: minmax(242px, auto); }
.calendar-grid.week-mode .calendar-day { min-height: 242px; padding: 9px 7px; }
.calendar-grid.week-mode .mini-event { padding: 5px 5px; white-space: normal; }
.calendar-grid.week-mode .day-events { gap: 5px; }
.calendar-grid.week-mode .day-number { margin-bottom: 11px; }
.calendar-list { padding: 8px 0; }
.list-day-group[data-scroll-reveal], .task-date-group[data-scroll-reveal], .timeline-task[data-scroll-reveal] { opacity: 1; }
@media (prefers-reduced-motion: no-preference) {
  .list-day-group[data-scroll-reveal], .task-date-group[data-scroll-reveal], .timeline-task[data-scroll-reveal] { opacity: 0; transform: translateY(8px); transition: opacity .24s ease, transform .24s cubic-bezier(.2,.8,.2,1); }
  .list-day-group[data-scroll-reveal].is-revealed, .task-date-group[data-scroll-reveal].is-revealed, .timeline-task[data-scroll-reveal].is-revealed,
  .list-day-group[data-scroll-reveal]:focus-within, .task-date-group[data-scroll-reveal]:focus-within, .timeline-task[data-scroll-reveal]:focus-within { opacity: 1; transform: translateY(0); }
}
.list-day-group { padding: 14px 2px 9px; border-bottom: 1px solid #efefe9; }
.list-day-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.list-day-heading h3 { margin: 0; color: #405146; font-size: 11px; font-weight: 700; }
.list-day-heading span { color: #9aa29b; font-size: 9px; }
.list-event-row { display: flex; min-height: 40px; align-items: center; gap: 10px; padding: 5px 8px; border-radius: 5px; cursor: pointer; transition: background .14s ease; }
.list-event-row:hover { background: #f7f8f3; }
.list-event-time { width: 43px; flex: 0 0 auto; color: #88948a; font-size: 9px; font-variant-numeric: tabular-nums; }
.list-event-mark { width: 3px; height: 24px; flex: 0 0 auto; border-radius: 4px; background: #83a989; }
.list-event-mark.personal { background: #e39a7b; }
.list-event-mark.health { background: #a798c5; }
.list-event-mark.family { background: #ddbb68; }
.list-event-mark.other { background: #86adb2; }
.list-event-row > div { display: grid; gap: 2px; }
.list-event-row strong { color: #334139; font-size: 10px; font-weight: 600; }
.list-event-row small { color: #959e97; font-size: 9px; }
.list-event-row.completed strong { color: #9aa29b; text-decoration: line-through; }

.day-panel { display: flex; flex-direction: column; min-height: 680px; padding: 20px 17px 12px; }
.day-panel-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; padding: 0 0 15px; border-bottom: 1px solid #eff0ea; }
.day-panel-top .eyebrow { margin-bottom: 5px; }
.day-panel-top h2 { max-width: 225px; margin: 0; color: #2d3b33; font-family: var(--serif); font-size: 19px; font-weight: 400; letter-spacing: -.01em; }
.round-add { display: grid; width: 28px; height: 28px; flex: 0 0 auto; place-items: center; color: #426148; background: #edf3e5; border: 1px solid #e4ecd9; border-radius: 50%; cursor: pointer; font-size: 17px; line-height: 1; transition: background .15s ease, transform .15s ease; }
.round-add:hover { background: var(--leaf); transform: rotate(90deg); }
.day-overview { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px; padding: 12px 0 10px; color: #839087; font-size: 9px; }
.day-summary-slot { display: contents; }
.day-overview strong { color: #53655a; font-size: 10px; font-weight: 600; }
.day-progress { grid-column: 1 / -1; width: 100%; height: 4px; overflow: hidden; appearance: none; border: 0; background: #eef0e8; border-radius: 5px; }
.day-progress::-webkit-progress-bar { background: #eef0e8; border-radius: 5px; }
.day-progress::-webkit-progress-value { background: #8fac7f; border-radius: 5px; transition: width .2s ease; }
.day-progress::-moz-progress-bar { background: #8fac7f; border-radius: 5px; }
.day-timeline { display: grid; align-content: start; flex: 1; }
.timeline-task { display: grid; grid-template-columns: 39px minmax(0, 1fr) 25px; gap: 8px; padding: 12px 0; border-bottom: 1px solid #f1f1ec; }
.timeline-time { padding-top: 2px; color: #929c94; font-size: 9px; font-variant-numeric: tabular-nums; }
.timeline-time.all-day-time { color: #809681; font-size: 8px; font-weight: 600; }
.timeline-main { min-width: 0; cursor: pointer; }
.timeline-main > strong { display: block; overflow-wrap: anywhere; color: #344039; font-size: 10px; font-weight: 600; line-height: 1.45; }
.timeline-main:hover > strong { color: #4e7655; }
.timeline-meta { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 6px; }
.tag { display: inline-flex; align-items: center; padding: 3px 5px; color: #7d8980; background: #f5f6f1; border-radius: 4px; font-size: 8px; line-height: 1; }
.tag.priority-high { color: #a05744; background: #fbede7; }
.timeline-task.completed .timeline-main > strong { color: #9ca49e; text-decoration: line-through; }
.task-check { display: grid; width: 20px; height: 20px; place-items: center; padding: 0; color: transparent; background: #fff; border: 1px solid #dfe4da; border-radius: 6px; cursor: pointer; font-size: 12px; transition: color .14s ease, background .14s ease, border .14s ease; }
.task-check:hover { border-color: #83a889; }
.task-check.checked { color: #fff; background: #7c9d7b; border-color: #7c9d7b; }
.day-panel-bottom { display: flex; align-items: center; gap: 8px; margin-top: auto; padding: 12px 8px 4px; color: #869288; background: #f7f8f3; border-radius: 6px; font-size: 9px; }
.day-bottom-star { color: #a6bc77; font-size: 14px; }
.empty-state { display: grid; justify-items: center; padding: 36px 16px; text-align: center; }
.empty-state-symbol { display: grid; width: 37px; height: 37px; place-items: center; margin-bottom: 10px; color: #66856a; background: #eff4e9; border-radius: 50%; font-family: var(--serif); font-size: 18px; }
.empty-state strong { color: #536259; font-family: var(--serif); font-size: 16px; font-weight: 400; }
.empty-state p { max-width: 210px; margin: 6px 0 0; color: #98a099; font-size: 9px; line-height: 1.65; }
.empty-state-button { margin-top: 13px; padding: 7px 10px; color: #516d55; background: #eff4e8; border: 1px solid #e3ebd9; border-radius: 6px; cursor: pointer; font-size: 9px; font-weight: 600; }
.empty-state-button:hover { background: #e5efd9; }

/* Takenlijst */
.tasks-panel { min-height: 470px; padding: 24px 27px; }
.tasks-heading-row { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding-bottom: 19px; border-bottom: 1px solid #eeefe9; }
.tasks-heading-row .eyebrow { margin-bottom: 4px; }
.tasks-heading-row h2 { margin: 0; color: #2e3c34; font-family: var(--serif); font-size: 26px; font-weight: 400; }
.tasks-heading-row p:last-child { margin: 4px 0 0; color: #8b958e; font-size: 10px; }
.task-toolbar { display: flex; min-height: 58px; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid #f0f0eb; }
.task-filters { display: flex; align-items: center; gap: 5px; }
.filter-chip { display: inline-flex; min-height: 29px; align-items: center; gap: 7px; padding: 5px 9px; color: #818c84; background: transparent; border: 1px solid transparent; border-radius: 6px; cursor: pointer; font-size: 9px; transition: color .16s ease, background .16s ease, border-color .16s ease, transform .16s ease; }
.filter-chip:active { transform: scale(.97); }
.filter-chip > span { min-width: 17px; padding: 2px 4px; color: #939b94; background: #f1f2ed; border-radius: 5px; text-align: center; font-size: 8px; }
.filter-chip:hover { color: #506657; background: #f7f8f4; }
.filter-chip.is-active { color: #3a5342; background: #f0f4ea; border-color: #e7eddf; font-weight: 600; }
.filter-chip.is-active > span { color: #577451; background: #e1ebd6; }
.task-result-label { color: #9aa19b; font-size: 9px; }
.all-tasks-list { display: grid; }
.task-date-group { padding: 14px 0 6px; }
.task-date-heading { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.task-date-heading > span { color: #8c978e; font-size: 9px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; }
.task-date-heading > i { width: 100%; height: 1px; background: #f0f1eb; }
.list-task { display: grid; grid-template-columns: 23px minmax(0, 1fr) auto; align-items: center; gap: 11px; min-height: 57px; padding: 8px 7px; border-bottom: 1px solid #f3f3ee; border-radius: 5px; }
.list-task:hover { background: #fcfcf9; }
.list-task-main { min-width: 0; cursor: pointer; }
.list-task-main strong { display: block; overflow: hidden; color: #36443b; text-overflow: ellipsis; white-space: nowrap; font-size: 10px; font-weight: 600; }
.list-task-main p { margin: 4px 0 0; color: #929b94; font-size: 9px; }
.list-task.completed .list-task-main strong { color: #a2aaa3; text-decoration: line-through; }
.list-task-action { display: flex; align-items: center; gap: 7px; }
.list-task-category { padding: 4px 6px; color: #69816e; background: #eff4e9; border-radius: 5px; font-size: 8px; }
.list-task-category.personal { color: #976552; background: #fbefe9; }
.list-task-category.health { color: #786891; background: #f2eff8; }
.list-task-category.family { color: #8b7140; background: #faf4e3; }
.list-task-category.other { color: #52767c; background: #edf4f4; }
.edit-link { padding: 5px 6px; color: #75847a; background: transparent; border: 0; cursor: pointer; font-size: 9px; }
.edit-link:hover { color: #3c6649; }
.settings-view { padding-bottom: 12px; }
.settings-heading { margin: 5px 0 17px; }
.settings-heading h2 { margin: 0; color: var(--forest); font-family: var(--serif); font-size: clamp(25px, 2.6vw, 32px); font-weight: 400; letter-spacing: -.025em; }
.settings-heading p:last-child { max-width: 560px; margin: 6px 0 0; color: var(--ink-soft); font-size: 12px; line-height: 1.65; }
.settings-layout { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(260px, .75fr); align-items: start; gap: 14px; }
.settings-card { padding: 22px; }
.settings-card-heading { display: flex; align-items: center; gap: 12px; padding-bottom: 16px; border-bottom: 1px solid #eff0ea; }
.settings-card-heading h3 { margin: 0; color: #35453a; font-family: var(--serif); font-size: 19px; font-weight: 400; }
.settings-card-heading p { margin: 4px 0 0; color: #909a92; font-size: 10px; line-height: 1.5; }
.settings-icon { display: grid; width: 38px; height: 38px; flex: 0 0 auto; place-items: center; color: #587856; background: #eef4e8; border-radius: 11px; font-size: 19px; }
.settings-icon-soft { color: #718578; background: #f3f5f0; }
.settings-field { display: flex; min-height: 67px; align-items: center; justify-content: space-between; gap: 18px; padding: 12px 0; border-bottom: 1px solid #f1f2ec; cursor: pointer; }
.settings-field > span { display: grid; gap: 4px; }
.settings-field strong { color: #405047; font-size: 11px; font-weight: 600; }
.settings-field small { color: #929b94; font-size: 9px; line-height: 1.45; }
.settings-field select { width: min(210px, 42%); min-height: 40px; padding: 7px 28px 7px 10px; color: #526257; background: #fff; border: 1px solid #e3e7df; border-radius: 7px; font-size: 11px; }
.settings-form-footer { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 16px; }
.settings-save-status { min-height: 0; margin: 0; color: #628166; }
.settings-save-status.is-error { color: #b55245; }
.settings-account { display: flex; align-items: center; gap: 12px; padding: 18px 0; }
.settings-account .user-avatar { width: 42px; height: 42px; font-size: 13px; }
.settings-account > div { display: grid; min-width: 0; gap: 4px; }
.settings-account strong { overflow: hidden; color: #3e4f44; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.settings-account > div > span { overflow-wrap: anywhere; color: #8c968f; font-size: 10px; }
.settings-sync-note { display: flex; align-items: flex-start; gap: 8px; margin: 0; padding: 12px; color: #738178; background: #f6f8f3; border: 1px solid #eef1e9; border-radius: 7px; font-size: 9px; line-height: 1.6; }
.settings-sync-note > span { color: #6f946f; font-size: 13px; font-weight: 700; line-height: 1.2; }
.app-footer { display: flex; justify-content: space-between; margin-top: 15px; padding: 0 3px; color: #a1a9a2; font-size: 9px; }
.app-footer i { margin-left: 3px; color: #9eb675; font-style: normal; }

/* Afspraakvenster */
.event-dialog { width: min(500px, calc(100% - 26px)); max-height: min(90vh, 760px); max-height: min(90dvh, 760px); overflow: auto; overscroll-behavior: contain; padding: 0; color: var(--ink); background: #fff; border: 1px solid rgba(29, 51, 40, .1); border-radius: 13px; box-shadow: 0 25px 100px rgba(17, 37, 29, .23); }
.event-dialog[open] { animation: dialog-arrive .18s ease-out both; }
.event-dialog::backdrop { background: rgba(17, 34, 27, .42); -webkit-backdrop-filter: blur(3px); backdrop-filter: blur(3px); }
@keyframes dialog-arrive { from { opacity: .6; transform: translateY(8px) scale(.99); } to { opacity: 1; transform: translateY(0) scale(1); } }
.event-form { display: grid; gap: 14px; padding: 22px 25px 20px; }
.dialog-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-bottom: 10px; border-bottom: 1px solid #eeefe9; }
.dialog-heading .eyebrow { margin-bottom: 4px; }
.dialog-heading h2 { margin: 0; color: #2d3b33; font-family: var(--serif); font-size: 22px; font-weight: 400; }
.dialog-close { color: #8b948d; }
.dialog-close svg { width: 15px; height: 15px; }
.event-form .field { gap: 6px; }
.event-form .field input, .event-form .field select, .event-form .field textarea { min-height: 39px; padding: 9px 10px; font-size: 11px; }
.event-form .field textarea { min-height: 70px; }
.event-form .field > span { font-size: 10px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.field-title input { min-height: 43px !important; font-size: 13px !important; }
.all-day-toggle, .complete-toggle { display: inline-flex; align-items: center; gap: 8px; width: fit-content; color: #69766d; cursor: pointer; font-size: 10px; }
.all-day-toggle input { position: absolute; width: 1px; height: 1px; opacity: 0; }
.custom-checkbox { display: grid; width: 15px; height: 15px; place-items: center; background: #fff; border: 1px solid #cdd5cb; border-radius: 4px; transition: background .15s ease, border .15s ease; }
.all-day-toggle input:checked + .custom-checkbox { background: #6f946f; border-color: #6f946f; }
.all-day-toggle input:checked + .custom-checkbox::after { width: 7px; height: 4px; border-bottom: 1.5px solid #fff; border-left: 1.5px solid #fff; content: ''; transform: translateY(-1px) rotate(-45deg); }
.all-day-toggle input:focus-visible + .custom-checkbox { outline: 3px solid rgba(128, 168, 124, .45); outline-offset: 2px; }
.complete-toggle { padding: 4px 0; }
.complete-toggle input { accent-color: #6f946f; }
.dialog-actions { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 1px; padding-top: 14px; border-top: 1px solid #eeefe9; }
.dialog-actions-right { display: flex; align-items: center; gap: 7px; margin-left: auto; }
.dialog-actions .button { min-height: 35px; font-size: 10px; }
.event-conflict-notice { margin: -6px 0 0; padding: 9px 11px; color: #8b6242; background: #fbf5e9; border: 1px solid #f0e4c9; border-radius: 6px; font-size: 10px; line-height: 1.55; }
.toast { position: fixed; z-index: 10; right: 24px; bottom: 23px; max-width: min(380px, calc(100vw - 32px)); padding: 11px 15px; color: #f6f6ef; background: var(--forest); border: 1px solid rgba(255,255,255,.12); border-radius: 8px; box-shadow: 0 10px 32px rgba(22, 45, 35, .2); font-size: 11px; opacity: 0; pointer-events: none; transform: translateY(8px); transition: opacity .18s ease, transform .18s ease; }
.toast.is-visible { opacity: 1; transform: translateY(0); }
.toast.is-error { background: #934f42; }
.mobile-nav { display: none; }
.not-found-screen { min-height: 100vh; display: grid; place-items: center; padding: 24px; color: var(--forest); background: var(--paper); font-family: var(--sans); text-align: center; }
.not-found-screen > main { max-width: 420px; }
.not-found-screen .not-found-symbol { color: #a3bd76; font-size: 34px; }
.not-found-screen h1 { margin: 5px 0 8px; font-family: var(--serif); font-size: 34px; font-weight: 400; }
.not-found-screen p { color: var(--ink-soft); font-size: 12px; }
.not-found-screen a { color: #426148; font-weight: 600; }

/* Beheercentrum */
.admin-shell { min-height: 100vh; min-height: 100dvh; background: var(--paper); }
.admin-topbar { display: flex; min-height: 68px; align-items: center; justify-content: space-between; gap: 16px; padding: 10px clamp(20px, 5vw, 70px); background: #fff; border-bottom: 1px solid #e9e8e0; }
.admin-topbar .brand-name { color: var(--forest); }
.admin-topbar .brand-symbol { border-color: rgba(23, 61, 52, .23); }
.admin-topbar .brand-symbol span { background: #83a45e; }
.admin-topbar-actions { display: flex; align-items: center; gap: 14px; }
.admin-topbar-actions > span { display: grid; gap: 3px; text-align: right; }
.admin-topbar-actions strong { color: #3f5145; font-size: 11px; }
.admin-topbar-actions small { color: #929b94; font-size: 9px; }
.admin-topbar-actions .button { min-height: 33px; font-size: 10px; }
.admin-content { width: min(1180px, calc(100% - 48px)); margin: 0 auto; padding: 36px 0 24px; }
.admin-heading { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; }
.admin-heading .eyebrow, .admin-section-heading .eyebrow, .admin-password-panel .eyebrow { margin-bottom: 5px; }
.admin-heading h1 { margin: 0; color: #2e3c34; font-family: var(--serif); font-size: 31px; font-weight: 400; }
.admin-heading p:last-child { margin: 6px 0 0; color: #858f88; font-size: 11px; }
.admin-status { display: inline-flex; align-items: center; gap: 7px; padding: 8px 11px; color: #657b68; background: #f0f4ea; border: 1px solid #e4ecda; border-radius: 20px; font-size: 9px; }
.admin-status i { width: 6px; height: 6px; border-radius: 50%; background: #7da47a; }
.admin-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 11px; margin-bottom: 16px; }
.admin-stat-card { display: grid; gap: 9px; min-height: 91px; padding: 15px 17px; background: #fff; border: 1px solid #ecebe4; border-radius: 9px; box-shadow: 0 4px 18px rgba(24, 46, 39, .025); }
.admin-stat-card span { color: #879189; font-size: 10px; }
.admin-stat-card strong { color: #35473b; font-family: var(--serif); font-size: 25px; font-weight: 400; }
.admin-users-panel { padding: 20px 22px 6px; }
.admin-section-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; padding-bottom: 16px; }
.admin-section-heading h2, .admin-password-panel h2 { margin: 0; color: #35453a; font-family: var(--serif); font-size: 21px; font-weight: 400; }
.admin-section-heading p:last-child, .admin-password-panel > div > p:last-child { margin: 5px 0 0; color: #929b94; font-size: 10px; line-height: 1.55; }
.admin-search { width: min(100%, 260px); min-height: 35px; margin: 0 0 2px; padding: 0 9px; background: #fff; }
.admin-search input { font-size: 10px; }
.admin-search svg { width: 15px; height: 15px; }
.admin-table-wrap { width: 100%; overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; text-align: left; }
.admin-table th { padding: 11px 10px; color: #919b93; border-top: 1px solid #eff0ea; border-bottom: 1px solid #eff0ea; font-size: 9px; font-weight: 600; }
.admin-table td { padding: 12px 10px; color: #6f7c72; border-bottom: 1px solid #f0f1eb; font-size: 10px; white-space: nowrap; }
.admin-table th:first-child, .admin-table td:first-child { padding-left: 2px; }
.admin-account-cell { display: grid; gap: 4px; white-space: normal !important; }
.admin-account-cell strong { color: #384a3e; font-size: 10px; font-weight: 600; }
.admin-account-cell small { color: #929b94; font-size: 9px; }
.status-badge { display: inline-flex; align-items: center; padding: 4px 7px; border-radius: 20px; font-size: 9px; }
.status-badge.is-active { color: #51704f; background: #edf4e7; }
.status-badge.is-paused { color: #956456; background: #fbefea; }
.admin-user-action { padding: 6px 8px; color: #58775f; background: #f2f5ee; border: 1px solid #e7eddf; border-radius: 5px; cursor: pointer; font-size: 9px; }
.admin-user-action:hover { background: #eaf0e3; }
.admin-user-action.is-danger { color: #9d6656; background: #fff; border-color: #efdfd9; }
.admin-user-action.is-danger:hover { background: #fff6f2; }
.admin-empty { padding: 22px 8px; color: #929b94; text-align: center; font-size: 10px; }
.admin-password-panel { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(0, 1.2fr); gap: 25px; margin-top: 14px; padding: 20px 22px; }
.admin-password-form { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; gap: 10px; }
.admin-password-form .field { gap: 6px; }
.admin-password-form .field > span { font-size: 9px; }
.admin-password-form .field input { min-height: 36px; padding: 7px 8px; font-size: 10px; }
.admin-password-form .button { grid-column: 3; min-height: 34px; font-size: 9px; }
.admin-password-form .form-message { grid-column: 1 / 3; align-self: center; font-size: 9px; }
.admin-password-form .form-message:empty { display: block; }

@media (max-width: 1290px) {
  .main-content { padding-right: 25px; padding-left: 25px; }
  .calendar-layout { grid-template-columns: minmax(0, 1fr) 280px; gap: 12px; }
  .calendar-panel { padding-right: 13px; padding-left: 13px; }
  .calendar-toolbar { align-items: flex-start; flex-direction: column; justify-content: center; padding: 10px 0; }
  .calendar-toolbar-side { justify-content: space-between; width: 100%; }
  .day-panel { padding-right: 14px; padding-left: 14px; }
  .summary-row { gap: 16px; }
  .summary-main { min-width: 170px; }
}

@media (max-width: 1020px) {
  .app-shell { grid-template-columns: 205px minmax(0, 1fr); }
  .sidebar { padding-right: 13px; padding-left: 13px; }
  .main-content { padding-right: 20px; padding-left: 20px; }
  .topbar { align-items: flex-start; flex-direction: column; gap: 14px; }
  .topbar-actions { width: 100%; justify-content: flex-end; }
  .search-box { width: min(100%, 300px); margin-right: auto; }
  .calendar-layout { grid-template-columns: minmax(0, 1fr); }
  .day-panel { min-height: auto; }
  .day-timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 18px; }
  .day-panel-bottom { margin-top: 11px; }
  .calendar-grid { grid-template-rows: repeat(6, minmax(88px, auto)); }
  .calendar-day { min-height: 88px; }
  .calendar-grid.week-mode { grid-template-rows: minmax(205px, auto); }
  .calendar-grid.week-mode .calendar-day { min-height: 205px; }
}

@media (max-width: 760px) {
  .auth-screen { grid-template-columns: 1fr; min-height: 100vh; min-height: 100dvh; }
  .auth-story { display: none; }
  .auth-panel { min-height: 100vh; min-height: 100dvh; justify-content: center; padding: calc(28px + env(safe-area-inset-top)) max(24px, env(safe-area-inset-right)) calc(58px + env(safe-area-inset-bottom)) max(24px, env(safe-area-inset-left)); }
  .auth-mobile-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 38px; color: var(--forest); }
  .auth-mobile-brand .brand-symbol { border-color: rgba(23, 61, 52, .23); }
  .auth-mobile-brand .brand-name > span { color: #87a853; }
  .auth-heading-block h2 { font-size: 32px; }
  .admin-content { width: min(560px, calc(100% - 26px - env(safe-area-inset-left) - env(safe-area-inset-right))); padding-top: 24px; }
  .admin-heading { align-items: flex-start; flex-direction: column; }
  .admin-heading h1 { font-size: 27px; }
  .admin-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .admin-stat-card { min-height: 79px; padding: 11px 12px; }
  .admin-stat-card strong { font-size: 22px; }
  .admin-users-panel { padding: 16px 12px 6px; }
  .admin-section-heading { align-items: stretch; flex-direction: column; gap: 11px; }
  .admin-search { width: 100%; }
  .admin-table { min-width: 610px; }
  .admin-password-panel { grid-template-columns: 1fr; gap: 16px; padding: 16px 13px; }
  .admin-password-form { grid-template-columns: 1fr; }
  .admin-password-form .button, .admin-password-form .form-message { grid-column: auto; }
  .admin-password-form .form-message:empty { display: none; }
  .admin-topbar { padding: calc(10px + env(safe-area-inset-top)) max(14px, env(safe-area-inset-right)) 10px max(14px, env(safe-area-inset-left)); }
  .admin-topbar-actions { gap: 8px; }
  .admin-topbar-actions .button { padding: 6px 9px; }
  .auth-footer { bottom: 19px; }
  .app-shell { display: block; min-height: 100vh; min-height: 100dvh; padding-bottom: calc(66px + env(safe-area-inset-bottom)); }
  .sidebar { display: none; }
  .main-content { padding: calc(19px + env(safe-area-inset-top)) max(15px, env(safe-area-inset-right)) calc(18px + env(safe-area-inset-bottom)) max(15px, env(safe-area-inset-left)); }
  .topbar { min-height: 0; flex-direction: row; align-items: center; gap: 8px; }
  .page-heading h1 { font-size: 24px; }
  .page-heading .eyebrow { font-size: 8px; }
  .page-date { display: block; margin: 3px 0 0; font-size: 9px; }
  .topbar-actions { width: auto; gap: 7px; }
  .search-box { width: 44px; min-height: 44px; justify-content: center; margin: 0; padding: 0; border-color: transparent; background: transparent; }
  .search-box:focus-within { width: min(185px, 43vw); padding: 0 8px; background: #fff; border-color: var(--line); }
  .search-box input { width: 0; opacity: 0; }
  .search-box:focus-within input { width: 100%; opacity: 1; }
  .search-box kbd { display: none; }
  .top-add-button { width: 44px; min-width: 44px; min-height: 44px; padding: 0; font-size: 0; }
  .top-add-button > span { font-size: 20px; }
  .dashboard-intro { align-items: flex-start; flex-direction: column; gap: 7px; margin: 22px 0 14px; }
  .dashboard-intro h2 { font-size: 26px; }
  .intro-note { font-size: 9px; }
  .summary-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) 44px; min-height: 0; align-items: center; gap: 5px; overflow: visible; margin: 0 0 13px; padding: 8px 0; }
  .summary-card { min-width: 0; gap: 5px; }
  .summary-main { min-width: 0; }
  .summary-icon { width: 24px; height: 24px; flex: 0 0 24px; border-radius: 7px; font-size: 11px; }
  .summary-card > div { display: grid; gap: 0; }
  .summary-card strong { font-size: 14px; }
  .summary-card span:last-child { max-width: none; font-size: 9px; line-height: 1.25; }
  .summary-divider { display: none; }
  .export-button { width: 44px; min-width: 44px; min-height: 44px; justify-content: center; margin: 0; padding: 0; }
  .export-button > span { display: none; }
  .calendar-layout { gap: 11px; }
  .calendar-panel { padding: 0 9px 10px; }
  .calendar-toolbar { gap: 8px; min-height: 81px; align-items: stretch; padding: 10px 0 9px; }
  .calendar-period-control { justify-content: space-between; width: 100%; gap: 3px; }
  .calendar-period-control h2 { flex: 1; min-width: 0; margin: 0 4px; font-size: 18px; }
  .calendar-period-control .button { margin-left: 4px; }
  .calendar-toolbar-side { gap: 5px; }
  .filter-select-label select { max-width: 132px; min-height: 44px; font-size: 10px; }
  .view-switch { min-height: 48px; align-items: center; padding: 2px; }
  .view-switch button { min-height: 44px; padding: 6px 8px; font-size: 10px; }
  .weekday-row { min-height: 29px; }
  .weekday-row span { padding-left: 2px; text-align: center; font-size: 8px; }
  .weekday-row.week-mode { width: 630px; grid-template-columns: repeat(7, 90px); overflow: visible; }
  .calendar-scroll.week-mode { overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; scroll-behavior: smooth; scroll-snap-type: x proximity; scrollbar-width: thin; }
  .calendar-scroll.week-mode .calendar-grid { width: 630px; }
  .weekday-row.week-mode span, .calendar-grid.week-mode .calendar-day { scroll-snap-align: start; }
  .calendar-grid { grid-template-rows: repeat(6, minmax(66px, auto)); }
  .calendar-day { min-height: 66px; padding: 4px 2px 3px; }
  .day-number { width: 20px; height: 20px; margin: 0 auto 3px; font-size: 9px; }
  .day-events { gap: 2px; }
  .mini-event { width: 100%; height: 4px; padding: 0; border-left: 0; border-radius: 4px; font-size: 0; }
  .mini-event.all-day { height: 5px; }
  .more-events { padding: 0; text-align: center; font-size: 7px; }
  .calendar-grid.week-mode { width: 630px; grid-template-columns: repeat(7, 90px); grid-template-rows: minmax(210px, auto); overflow: visible; }
  .calendar-grid.week-mode .calendar-day { min-height: 210px; padding: 7px 5px; }
  .calendar-grid.week-mode .day-number { margin: 0 0 8px 2px; }
  .calendar-grid.week-mode .mini-event { height: auto; padding: 4px; border-left: 2px solid; font-size: 8px; }
  .calendar-grid.week-mode .mini-event.personal { border-left-color: #e39a7b; }
  .calendar-grid.week-mode .mini-event.health { border-left-color: #a798c5; }
  .calendar-grid.week-mode .mini-event.family { border-left-color: #ddbb68; }
  .calendar-grid.week-mode .mini-event.other { border-left-color: #86adb2; }
  .calendar-list { min-height: 160px; }
  .day-panel { padding: 16px 13px 11px; }
  .day-panel-top h2 { font-size: 18px; }
  .day-timeline { grid-template-columns: 1fr; }
  .tasks-panel { min-height: 400px; padding: 17px 12px; }
  .tasks-heading-row { align-items: flex-start; padding-bottom: 14px; }
  .tasks-heading-row h2 { font-size: 23px; }
  .tasks-heading-row p:last-child { max-width: 230px; line-height: 1.5; }
  .tasks-heading-row .button { min-height: 34px; padding: 7px 9px; font-size: 9px; white-space: nowrap; }
  .settings-layout { grid-template-columns: 1fr; gap: 11px; }
  .settings-heading { margin: 8px 0 12px; }
  .settings-heading h2 { font-size: 26px; }
  .settings-heading p:last-child { font-size: 11px; }
  .settings-card { padding: 17px 14px; }
  .settings-card-heading { align-items: flex-start; }
  .settings-card-heading h3 { font-size: 18px; }
  .settings-field { align-items: stretch; flex-direction: column; gap: 8px; }
  .settings-field strong { font-size: 12px; }
  .settings-field small { font-size: 10px; }
  .settings-field select { width: 100%; min-height: 44px; font-size: 16px; }
  .settings-form-footer { align-items: stretch; flex-direction: column-reverse; }
  .settings-form-footer .button { width: 100%; }
  .settings-save-status { min-height: 16px; }
  .task-toolbar { min-height: 49px; }
  .task-filters { gap: 1px; }
  .filter-chip { min-height: 44px; gap: 5px; padding: 6px 8px; font-size: 10px; }
  .task-result-label { display: none; }
  .list-task { grid-template-columns: 44px minmax(0, 1fr) auto; gap: 8px; padding-right: 3px; padding-left: 3px; }
  .task-check { width: 44px; height: 44px; }
  .list-task-main p { font-size: 9px; }
  .list-task-category { display: none; }
  .edit-link { min-width: 44px; min-height: 44px; font-size: 9px; }
  .app-footer { display: none; }
  .mobile-nav { position: fixed; z-index: 5; right: 0; bottom: 0; left: 0; display: flex; height: calc(62px + env(safe-area-inset-bottom)); align-items: center; justify-content: space-around; padding: 3px max(22px, env(safe-area-inset-right)) calc(3px + env(safe-area-inset-bottom)) max(22px, env(safe-area-inset-left)); background: rgba(255,255,255,.98); border-top: 1px solid #e7e9e1; box-shadow: 0 -4px 16px rgba(30, 49, 39, .05); }
  .mobile-nav-item { display: grid; min-width: 63px; min-height: 44px; justify-items: center; align-content: center; gap: 3px; padding: 4px; color: #929c93; background: none; border: 0; cursor: pointer; transition: color .16s ease, transform .16s ease; }
  .mobile-nav-item > svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
  .mobile-nav-item small { font-size: 9px; }
  .mobile-nav-item.is-active { color: #446b4c; }
  .mobile-nav-item.is-active small { font-weight: 700; }
  .mobile-add { display: grid; width: 48px; height: 48px; place-items: center; margin-top: -20px; color: #21372b; background: var(--leaf); border: 4px solid var(--paper); border-radius: 50%; box-shadow: 0 3px 10px rgba(41, 76, 51, .17); cursor: pointer; font-size: 25px; line-height: 1; transition: transform .16s ease, box-shadow .16s ease; }
  .mobile-add:active { transform: scale(.94); }
  .period-arrow { width: 44px; height: 44px; }
  .calendar-period-control .button { min-height: 44px; margin-left: 4px; font-size: 10px; }
  .round-add { width: 44px; height: 44px; }
  .text-link, .auth-admin-link { min-height: 44px; display: inline-flex; align-items: center; justify-content: center; }
  .auth-admin-link { display: flex; min-height: 44px; margin: 12px auto 0; }
  .button, .auth-tab, .admin-user-action { min-height: 44px; }
  .admin-user-action { padding: 8px 10px; }
  .field input, .field select, .field textarea,
  .event-form .field input, .event-form .field select, .event-form .field textarea,
  .search-box input, .filter-select-label select, .admin-search input { font-size: 16px !important; }
  .event-form .field input, .event-form .field select { min-height: 44px; }
  .event-form .field textarea { min-height: 88px; }
  .all-day-toggle, .complete-toggle { min-height: 44px; }
  .dialog-actions .button { min-height: 44px; font-size: 11px; }
  .dialog-close { width: 44px; height: 44px; }
  .toast { right: 12px; bottom: 75px; left: 12px; max-width: none; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; scroll-snap-type: none !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* Leesbare bediening en consistente agendaweergave. */
:root { --muted: #647268; --ink-soft: #53645a; --line: #dfe5da; }
html { min-width: 0; }
.main-content { max-width: 1600px; }
.sidebar-section-label, .sidebar-day-card small, .category-legend, .account-label small { font-size: 11px; }
.nav-item { min-height: 48px; font-size: 14px; }
.sidebar-day-card strong, .account-label strong { font-size: 12px; }
.eyebrow { font-size: 11px; }
.topbar { position: relative; }
.page-date { font-size: 13px; color: #627066; }
.search-box { width: min(310px, 25vw); min-height: 44px; }
.search-box input { font-size: 14px; }
.search-toggle { display: none; }
.top-add-button, .button { min-height: 44px; font-size: 13px; }
.button:disabled, button:disabled { cursor: wait; opacity: .6; }
.sync-status { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 8px; color: #647268; font-size: 11px; }
.sync-dot { width: 6px; height: 6px; background: #669565; border-radius: 50%; }
.sync-status[data-state="loading"] .sync-dot, .sync-status[data-state="syncing"] .sync-dot { background: #b08c49; }
.sync-status[data-state="offline"] .sync-dot, .sync-status[data-state="error"] .sync-dot { background: #bd725b; }
.sync-status .text-link { min-height: 24px; font-size: 11px; }
.dashboard-intro { margin-top: 23px; }
.intro-note { color: #647268; font-size: 12px; }
.summary-row { min-height: 82px; padding: 14px 18px; border-color: #e3e7de; box-shadow: 0 4px 16px rgba(28,57,44,.025); }
.summary-card { flex: 1; min-width: 0; gap: 12px; }
.summary-main { min-width: 0; }
.summary-card > div { display: grid; gap: 2px; white-space: normal; }
.summary-card strong { font-size: 24px; }
.summary-card span:last-child { color: #657369; font-size: 12px; }
.summary-icon { width: 36px; height: 36px; }
.export-button { min-height: 44px; font-size: 12px; }
.panel { border-color: #e0e6da; border-radius: 14px; box-shadow: 0 6px 22px rgba(29,52,40,.025); }
.calendar-layout { grid-template-columns: minmax(0,1fr) 330px; }
.calendar-toolbar { min-height: 82px; flex-wrap: wrap; }
.calendar-period-control h2 { font-size: 23px; }
.period-arrow, .icon-button { width: 40px; height: 40px; }
.calendar-period-control .button { min-height: 40px; font-size: 12px; }
.filter-select-label select { min-height: 40px; max-width: 160px; font-size: 13px; color: #53665a; }
.view-switch button { min-height: 36px; padding: 6px 10px; font-size: 12px; }
.calendar-quickbar { display: flex; min-height: 58px; align-items: center; flex-wrap: wrap; justify-content: space-between; gap: 10px; padding: 8px 0; border-bottom: 1px solid #edf0e8; }
.date-jump { display: flex; align-items: center; gap: 9px; color: #647268; font-size: 12px; }
.date-jump input { min-width: 0; width: 154px; min-height: 40px; padding: 7px 9px; background: #fafbf7; color: #354a3e; border: 1px solid #dce5d7; border-radius: 7px; font-size: 13px; }
.filter-feedback { display: flex; align-items: center; gap: 10px; font-size: 12px; color: #617265; }
.text-link { min-height: 36px; font-size: 12px; }
.weekday-row { min-height: 37px; }
.weekday-row span { font-size: 12px; color: #66756b; }
.calendar-grid { grid-template-rows: none; grid-auto-rows: minmax(110px,auto); }
.calendar-day { min-height: 110px; padding: 8px 6px; transition: background .16s ease, box-shadow .16s ease; }
.calendar-day:focus-visible { outline-offset: -3px; }
.day-number { width: 26px; height: 26px; font-size: 13px; color: #445d4c; }
.calendar-day.outside .day-number { color: #86948a; }
.mini-event { font-size: 11px; padding: 4px 5px; }
.more-events { font-size: 10px; }
.calendar-grid.week-mode { grid-template-rows: none; grid-auto-rows: minmax(240px,auto); }
.selected-day-strip { display: flex; align-items: center; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding-top: 11px; color: #627368; font-size: 12px; }
.selected-day-strip button { display: none; }
.day-panel { min-height: 0; scroll-margin-top: 20px; }
.day-panel-top h2 { font-size: 22px; }
.round-add { width: 40px; height: 40px; }
.day-overview, .day-overview strong { font-size: 12px; }
.timeline-task { grid-template-columns: 42px minmax(0,1fr) 44px; align-items: start; padding: 16px 0; }
.timeline-time, .timeline-time.all-day-time { font-size: 11px; color: #617366; }
.timeline-main > strong { font-size: 14px; }
.tag { color: #576a5d; font-size: 11px; line-height: 1.25; }
.task-check { width: 44px; height: 44px; border-color: #b3c4b0; border-radius: 10px; font-size: 16px; }
.day-panel-bottom { font-size: 12px; color: #617565; }
.empty-state p { color: #647568; font-size: 13px; }
.empty-state strong { font-size: 21px; }
.empty-state-button { min-height: 44px; font-size: 13px; }
.list-event-row { width: 100%; min-height: 58px; padding: 10px; text-align: left; background: transparent; border: 0; }
.list-event-row > span:last-child { display: grid; min-width: 0; gap: 4px; }
.list-event-row strong, .list-day-heading h3 { font-size: 14px; }
.list-event-row small, .list-day-heading span { color: #647568; font-size: 12px; overflow-wrap: anywhere; }
.list-event-time { width: 74px; font-size: 12px; }
.tasks-heading-row p:last-child { color: #647568; font-size: 13px; }
.task-toolbar { flex-wrap: wrap; padding: 10px 0; }
.filter-chip { min-height: 44px; font-size: 13px; color: #566a5c; }
.filter-chip > span { font-size: 11px; }
.task-result-label { color: #617366; font-size: 12px; }
.task-refinements { display: flex; flex-wrap: wrap; align-items: end; gap: 14px; padding: 15px 0; border-bottom: 1px solid #edf0e8; }
.task-refinements label { display: grid; min-width: 0; gap: 6px; font-size: 12px; color: #617366; }
.task-refinements select { min-height: 42px; padding: 8px 24px 8px 10px; color: #3e5645; background: #fff; border: 1px solid #dae3d5; border-radius: 7px; font-size: 13px; }
.task-date-heading > span { font-size: 12px; color: #617366; white-space: nowrap; }
.list-task { grid-template-columns: 44px minmax(0,1fr) auto; min-height: 74px; }
.list-task-main strong { font-size: 14px; line-height: 1.5; white-space: normal; }
.list-task-main p { font-size: 12px; line-height: 1.5; color: #627469; overflow-wrap: anywhere; }
.list-task-category { font-size: 11px; }
.edit-link { min-width: 44px; min-height: 44px; font-size: 12px; }
.app-shell[data-view="settings"] .dashboard-intro, .app-shell[data-view="settings"] .summary-row, .app-shell[data-view="settings"] .topbar-actions { display: none; }
.settings-view { margin-top: 22px; }
.settings-card-heading p, .settings-field small, .settings-account > div > span, .settings-sync-note { font-size: 12px; color: #627469; }
.settings-field strong, .settings-account strong { font-size: 14px; }
.settings-field select { min-height: 44px; font-size: 14px; }
.settings-field { min-height: 86px; }
.event-dialog { width: min(560px,calc(100% - 24px)); max-height: min(92dvh,850px); }
.event-form .field > span { font-size: 13px; }
.event-form .field input, .event-form .field select, .event-form .field textarea, .event-form .field-title input { min-height: 44px; font-size: 16px !important; }
.repeat-fields { padding: 12px; background: #f7f9f2; border: 1px solid #e6ecdd; border-radius: 9px; }
.field-help { margin: 9px 0 0; color: #647568; font-size: 12px; line-height: 1.6; }
.all-day-toggle, .complete-toggle { min-height: 40px; font-size: 13px; }
.event-edit-actions { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; }
.delete-link { color: #a95243; }
.dialog-actions .button { min-height: 44px; font-size: 13px; }
.confirmation-dialog h2 { margin: 0; font: 25px var(--serif); color: var(--forest); }
.confirmation-dialog p { margin: 0 0 8px; font-size: 14px; line-height: 1.6; }
.admin-table th, .admin-table td, .admin-account-cell strong, .admin-user-action { font-size: 13px; }
.admin-account-cell small, .admin-section-heading p:last-child { font-size: 12px; }
.admin-password-form .field > span { font-size: 12px; }
.admin-password-form .field input { min-height: 44px; font-size: 16px; }
html[data-density="compact"] .calendar-grid:not(.week-mode) { grid-auto-rows: minmax(86px,auto); }
html[data-density="compact"] .calendar-day { min-height: 86px; }
html[data-density="compact"] .list-task { min-height: 58px; padding-top: 5px; padding-bottom: 5px; }
@media (max-width:1290px) { .calendar-layout { grid-template-columns: minmax(0,1fr) 300px; } }
@media (max-width:1020px) { .calendar-layout { grid-template-columns: minmax(0,1fr); } .settings-layout { grid-template-columns: 1fr; } .search-box { width: 300px; } }
@media (max-width:760px) {
  .main-content { padding-top: calc(19px + env(safe-area-inset-top)); }
  .page-heading h1 { font-size: 25px; }
  .page-heading .eyebrow { font-size: 10px; }
  .page-date { font-size: 12px; }
  .topbar-actions { gap: 4px; }
  .page-heading { min-width: 0; }
  .calendar-toolbar-side { flex-wrap: wrap; }
  .search-toggle { display: grid; width: 44px; height: 44px; }
  .search-box { display: none; }
  .search-open .topbar { padding-bottom: 62px; }
  .search-open .search-box, .search-open .search-box:focus-within { position: absolute; right: 0; bottom: 0; left: 0; display: flex; width: 100%; min-height: 46px; justify-content: initial; padding: 0 10px; background: #fff; border: 1px solid #cbd8c4; }
  .search-open .search-box input { width: 100%; opacity: 1; font-size: 16px; }
  .top-add-button { font-size: 0; }
  .sync-status { font-size: 10px; max-width: 240px; }
  .dashboard-intro { margin-top: 21px; }
  .dashboard-intro h2 { font-size: 25px; line-height: 1.15; }
  .intro-note { font-size: 11px; }
  .summary-row { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)) 44px; padding: 10px 8px; gap: 5px; min-height: 76px; }
  .summary-card { display: block; }
  .summary-card strong { font-size: 21px; }
  .summary-card span:last-child { font-size: 11px; line-height: 1.35; }
  .summary-icon { display: none; }
  .calendar-panel { padding: 0 9px 11px; }
  .calendar-period-control { gap: 0; }
  .calendar-period-control h2 { margin: 0 4px; font-size: 20px; }
  .calendar-period-control .button { min-height: 44px; font-size: 12px; }
  .period-arrow { width: 36px; height: 44px; }
  .filter-select-label select { max-width: 146px; min-height: 44px; font-size: 16px; }
  .view-switch button { font-size: 12px; padding: 6px 8px; }
  .weekday-row span { font-size: 11px; }
  .calendar-grid { grid-template-rows: none; grid-auto-rows: minmax(61px,auto); }
  .calendar-day { min-height: 61px; padding: 4px 2px; }
  .day-number { width: 23px; height: 23px; font-size: 12px; }
  .mini-event { height: 5px; padding: 0; font-size: 0; }
  .more-events { font-size: 9px; }
  .weekday-row.week-mode, .calendar-scroll.week-mode .calendar-grid { width: 700px; grid-template-columns: repeat(7,100px); }
  .calendar-grid.week-mode { grid-template-rows: none; grid-auto-rows: minmax(205px,auto); }
  .calendar-grid.week-mode .calendar-day { min-height: 205px; }
  .calendar-grid.week-mode .mini-event { font-size: 11px; line-height: 1.45; }
  .selected-day-strip { font-size: 12px; }
  .selected-day-strip button { display: inline-flex; min-height: 44px; font-size: 12px; }
  .calendar-quickbar { min-height: 58px; }
  .date-jump input { font-size: 16px; width: 163px; min-height: 44px; }
  .day-panel-top h2 { font-size: 22px; }
  .tasks-heading-row { flex-wrap: wrap; }
  .tasks-heading-row .button { min-height: 44px; font-size: 12px; }
  .task-toolbar { gap: 4px; }
  .task-result-label { display: block; font-size: 12px; }
  .task-filters { flex-wrap: wrap; }
  .filter-chip { font-size: 12px; padding: 6px 7px; }
  .task-refinements { gap: 8px; }
  .task-refinements label { flex: 1; }
  .task-refinements select { width: 100%; font-size: 16px; }
  .list-task { gap: 8px; }
  .list-task-main p { font-size: 12px; }
  .edit-link { font-size: 12px; padding: 5px 3px; }
  .settings-field strong { font-size: 14px; }
  .settings-field small, .settings-card-heading p { font-size: 12px; }
  .settings-field select { font-size: 16px; }
  .settings-heading p:last-child { font-size: 13px; }
  .mobile-nav { padding-right: max(8px,env(safe-area-inset-right)); padding-left: max(8px,env(safe-area-inset-left)); }
  .mobile-nav-item { min-width: 60px; }
  .mobile-nav-item small { font-size: 10px; }
  .mobile-nav-item > svg { width: 20px; height: 20px; }
  .event-form { padding: 18px; }
  .event-form .field > span { font-size: 12px; }
  .toast { bottom: calc(78px + env(safe-area-inset-bottom)); }
  html[data-density="compact"] .calendar-grid:not(.week-mode) { grid-auto-rows: minmax(49px,auto); }
  html[data-density="compact"] .calendar-day { min-height: 49px; }
}
html[data-motion="reduced"] *, html[data-motion="reduced"] *::before, html[data-motion="reduced"] *::after { animation: none !important; transition-duration: .01ms !important; scroll-behavior: auto !important; scroll-snap-type: none !important; }
html[data-motion="reduced"] [data-scroll-reveal] { opacity: 1 !important; transform: none !important; }
@media (prefers-reduced-motion:reduce) { [data-scroll-reveal] { opacity: 1 !important; transform: none !important; } }
