/* Agora Portfolio — huisstijl afgeleid van het papieren portfolio (Roboto, navy titels, oranje accent, kleur per onderdeel) */
@font-face { font-family: Roboto; font-weight: 400; font-display: swap; src: url(/fonts/roboto-latin-400-normal.woff2) format('woff2'); }
@font-face { font-family: Roboto; font-weight: 500; font-display: swap; src: url(/fonts/roboto-latin-500-normal.woff2) format('woff2'); }
@font-face { font-family: Roboto; font-weight: 700; font-display: swap; src: url(/fonts/roboto-latin-700-normal.woff2) format('woff2'); }

:root {
  --navy: #0f172a;
  --ink: #1e293b;
  --text: #334155;
  --muted: #64748b;
  --line: #e2e8f0;
  --line-soft: #f1f5f9;
  --bg: #f8fafc;
  --card: #ffffff;
  --brand: #ea580c;
  --brand-dark: #c2410c;
  --brand-soft: #fff7ed;
  --ok: #059669; --ok-bg: #ecfdf5;
  --warn: #b45309; --warn-bg: #fffbeb;
  --bad: #dc2626; --bad-bg: #fef2f2;
  --info: #0369a1; --info-bg: #f0f9ff;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 1px 3px rgba(15, 23, 42, .06);
  --shadow-lg: 0 10px 30px rgba(15, 23, 42, .15);
  --c: var(--brand);
  --soft: var(--brand-soft);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: Roboto, system-ui, -apple-system, 'Segoe UI', sans-serif; font-size: 15px; line-height: 1.5; color: var(--text); background: var(--bg); }
h1, h2, h3 { color: var(--navy); line-height: 1.25; margin: 0; font-weight: 700; }
h1 { font-size: 26px; letter-spacing: -.01em; }
h2 { font-size: 17px; }
h3 { font-size: 15px; }
p { margin: 0 0 .6em; }
a { color: var(--brand-dark); }
button, input, select, textarea { font: inherit; color: inherit; }
.icon { flex-shrink: 0; vertical-align: middle; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.center { text-align: center; }
.mono { font-family: ui-monospace, 'SF Mono', Menlo, Consolas, monospace; letter-spacing: .02em; }
.break { word-break: break-all; }
.nowrap { white-space: nowrap; }
.right { text-align: right; }
.spacer { flex: 1; }
.warn-text { color: var(--bad); }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid rgba(234, 88, 12, .45); outline-offset: 2px; border-radius: 6px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--navy); color: #fff; padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }

/* ---------- Topbar ---------- */
.topbar { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 20; }
.topbar-inner { max-width: 1320px; margin: 0 auto; padding: 0 20px; height: 60px; display: flex; align-items: center; gap: 20px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--navy); white-space: nowrap; }
.logo-text { font-size: 17px; }
.logo-text b { font-weight: 700; }
.logo-year { color: var(--brand); font-weight: 700; font-size: 15px; }
.brand-pill { display: inline-block; background: var(--navy); color: #fff; font-weight: 700; font-size: 11px; letter-spacing: .08em; padding: 4px 10px; border-radius: 6px; }
.main-nav { display: flex; gap: 4px; flex: 1; }
.nav-link { display: inline-flex; align-items: center; gap: 7px; padding: 8px 12px; border-radius: 8px; color: var(--text); text-decoration: none; font-weight: 500; background: none; border: 0; cursor: pointer; white-space: nowrap; }
.nav-link:hover { background: var(--line-soft); color: var(--navy); }
.nav-link.active { background: var(--brand-soft); color: var(--brand-dark); }
.user-menu { display: flex; gap: 2px; }

.main { max-width: 1320px; margin: 0 auto; padding: 24px 20px 40px; }
.main.with-sidebar { display: grid; grid-template-columns: 230px 1fr; gap: 28px; align-items: start; }
.content { min-width: 0; }
.page { max-width: 1040px; margin: 0 auto; display: flex; flex-direction: column; gap: 18px; }
.page.wide { max-width: none; }
.page.narrow { max-width: 680px; }
.with-sidebar .page { margin: 0; }
.footer { text-align: center; color: var(--muted); font-size: 12px; padding: 20px; border-top: 1px solid var(--line); }

/* ---------- Sidebar (leerling) ---------- */
.sidebar { position: sticky; top: 84px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; box-shadow: var(--shadow); }
.side-title { font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 4px 10px 8px; }
.side-link { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; text-decoration: none; color: var(--text); font-weight: 500; font-size: 14px; }
.side-link:hover { background: var(--line-soft); }
.side-link.active { background: color-mix(in srgb, var(--c) 10%, white); color: var(--c); }
.side-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--c); flex-shrink: 0; }
.side-name { flex: 1; }
.side-count { font-size: 12px; color: var(--muted); font-variant-numeric: tabular-nums; }
.side-count.complete { color: var(--ok); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid transparent; border-radius: 9px; padding: 9px 16px; font-weight: 500; cursor: pointer; text-decoration: none; transition: background .15s, border-color .15s, box-shadow .15s; white-space: nowrap; line-height: 1.2; }
.btn:disabled { opacity: .6; cursor: progress; }
.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover:not(:disabled) { background: var(--brand-dark); }
.btn-ghost { background: var(--card); border-color: var(--line); color: var(--ink); }
.btn-ghost:hover:not(:disabled) { background: var(--line-soft); border-color: #cbd5e1; }
.btn-danger { background: var(--bad); color: #fff; }
.btn-danger:hover:not(:disabled) { background: #b91c1c; }
.btn-ghost-danger { background: var(--card); border-color: var(--line); color: var(--bad); }
.btn-ghost-danger:hover:not(:disabled) { background: var(--bad-bg); border-color: #fecaca; }
.btn-sm { padding: 6px 10px; font-size: 13px; border-radius: 8px; }
.btn-block { width: 100%; }
.btn.loading { position: relative; color: transparent !important; }
.btn.loading::after { content: ''; position: absolute; width: 16px; height: 16px; border: 2px solid rgba(255,255,255,.6); border-top-color: transparent; border-radius: 50%; animation: spin .7s linear infinite; }
.btn-ghost.loading::after, .btn-ghost-danger.loading::after { border-color: var(--muted); border-top-color: transparent; }
.icon-btn { background: none; border: 0; padding: 6px; border-radius: 8px; cursor: pointer; color: var(--muted); display: inline-flex; }
.icon-btn:hover { background: var(--line-soft); color: var(--navy); }

/* ---------- Forms ---------- */
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field.inline { flex-direction: row; align-items: center; gap: 12px; }
.field-label { font-size: 13px; font-weight: 500; color: var(--ink); }
.field-hint { font-size: 12px; color: var(--muted); }
.req { color: var(--brand); }
input:not([type=checkbox]):not([type=radio]), select, textarea {
  width: 100%; border: 1px solid #cbd5e1; border-radius: 9px; padding: 9px 12px; background: #fff; min-height: 40px;
  transition: border-color .15s, box-shadow .15s;
}
textarea { resize: vertical; min-height: 70px; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(234, 88, 12, .15); }
input[type=number].num { width: 72px; text-align: center; }
input[type=checkbox] { width: 18px; height: 18px; accent-color: var(--brand); cursor: pointer; }
input.switch { appearance: none; width: 40px; height: 22px; border-radius: 22px; background: #cbd5e1; position: relative; transition: background .15s; flex-shrink: 0; }
input.switch::after { content: ''; position: absolute; top: 3px; left: 3px; width: 16px; height: 16px; background: #fff; border-radius: 50%; transition: left .15s; box-shadow: 0 1px 2px rgba(0,0,0,.2); }
input.switch:checked { background: var(--ok); }
input.switch:checked::after { left: 21px; }
.field-check { display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: 14px; }
.field-check.pad-top { padding-top: 26px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px 16px; }
.form-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.form-grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.form-grid > .field:has(textarea), .form-grid > .field-check { grid-column: 1 / -1; }
.form-error { background: var(--bad-bg); color: #991b1b; border: 1px solid #fecaca; padding: 10px 12px; border-radius: 9px; font-size: 14px; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }
.readonly { padding: 9px 0; color: var(--ink); font-weight: 500; }
.readonly.empty { color: var(--muted); font-weight: 400; font-style: italic; }
.code-input { font-size: 22px; letter-spacing: .3em; text-align: center; font-family: ui-monospace, Menlo, monospace; }
.pw-form { display: flex; flex-direction: column; gap: 14px; }
.pw-meter { height: 5px; background: var(--line); border-radius: 5px; overflow: hidden; margin-top: -6px; }
.pw-meter > div { height: 100%; width: 0; background: var(--bad); transition: width .2s; }
.pw-meter[data-level=mid] > div { background: #f59e0b; }
.pw-meter[data-level=high] > div { background: var(--ok); }

/* ---------- Login ---------- */
.login-page { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-brand { background: var(--card); padding: 64px 7vw; display: flex; flex-direction: column; justify-content: center; border-right: 1px solid var(--line); }
.cover-title { font-size: clamp(36px, 5vw, 56px); font-weight: 700; color: var(--navy); margin: 18px 0 6px; line-height: 1.05; letter-spacing: -.02em; }
.cover-title span { display: block; color: var(--brand); }
.cover-sub { color: var(--muted); font-size: 17px; margin-bottom: 28px; }
.cover-toc { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; max-width: 360px; border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px; background: #fcfcfd; }
.cover-toc li { display: flex; align-items: center; gap: 10px; color: var(--c); font-weight: 700; font-size: 14px; }
.cover-toc .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.login-card { display: flex; align-items: center; justify-content: center; padding: 40px 24px; }
.login-form { width: 100%; max-width: 380px; display: flex; flex-direction: column; gap: 16px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 32px; box-shadow: var(--shadow-lg); }
.login-form h2 { font-size: 22px; }
.login-help { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--muted); margin: 0; }
.login-help .icon { margin-top: 2px; }

/* ---------- Cards & common ---------- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; box-shadow: var(--shadow); }
.card > h2 { margin-bottom: 12px; display: flex; align-items: center; gap: 8px; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.card-head h2 { display: flex; align-items: center; gap: 8px; }
.card-head .icon { color: var(--brand); }
.card-actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.page-head p { margin: 4px 0 0; }
.block-title { margin-top: 6px; font-size: 19px; }
.back { display: inline-flex; align-items: center; gap: 4px; color: var(--muted); text-decoration: none; font-weight: 500; font-size: 14px; align-self: flex-start; }
.back:hover { color: var(--navy); }
.kv { display: grid; grid-template-columns: 160px 1fr; gap: 8px 16px; margin: 0; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 500; color: var(--ink); }
.ok-line { display: flex; align-items: center; gap: 8px; color: var(--ok); font-weight: 500; margin: 0; }
.empty { text-align: center; padding: 48px 20px; color: var(--muted); background: var(--card); border: 1px dashed var(--line); border-radius: var(--radius); }
.empty h3 { margin: 10px 0 4px; }
.loading-box { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 60px; color: var(--muted); }
.loading-box.boot { min-height: 100vh; }
.spinner { width: 22px; height: 22px; border: 3px solid var(--line); border-top-color: var(--brand); border-radius: 50%; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.noscript { padding: 40px; text-align: center; }
.dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 8px; vertical-align: middle; }

.note { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border-radius: 10px; font-size: 14px; border: 1px solid; }
.note .icon { margin-top: 2px; }
.note.big { font-size: 15px; padding: 14px 16px; }
.note-info { background: var(--info-bg); border-color: #bae6fd; color: #075985; }
.note-warn { background: var(--warn-bg); border-color: #fde68a; color: #92400e; }
.note-ok { background: var(--ok-bg); border-color: #a7f3d0; color: #065f46; }

/* ---------- Chips ---------- */
.chip { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: 12px; font-weight: 500; white-space: nowrap; border: 1px solid transparent; }
.chip-op-koers { background: var(--ok-bg); color: var(--ok); border-color: #a7f3d0; }
.chip-let-op { background: var(--warn-bg); color: var(--warn); border-color: #fde68a; }
.chip-achter { background: var(--bad-bg); color: var(--bad); border-color: #fecaca; }
.chip-neutral { background: var(--line-soft); color: var(--text); border-color: var(--line); }
.chip-e-todo { background: var(--line-soft); color: var(--muted); }
.chip-e-concept { background: #f1f5f9; color: #475569; border-color: var(--line); }
.chip-e-pending { background: var(--info-bg); color: var(--info); border-color: #bae6fd; }
.chip-e-returned { background: var(--warn-bg); color: var(--warn); border-color: #fde68a; }
.chip-e-done { background: var(--ok-bg); color: var(--ok); border-color: #a7f3d0; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.count-badge { display: inline-flex; min-width: 24px; height: 24px; padding: 0 8px; align-items: center; justify-content: center; border-radius: 12px; background: var(--info-bg); color: var(--info); font-weight: 700; font-size: 12px; }
.count-badge.neutral { background: var(--line-soft); color: var(--text); }

/* ---------- Voortgang ---------- */
.ring { position: relative; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.ring svg { position: absolute; inset: 0; }
.ring-val { transition: stroke-dasharray .6s ease; }
.ring-label { position: relative; font-weight: 700; color: var(--navy); font-size: 14px; font-variant-numeric: tabular-nums; }
.bar { position: relative; height: 8px; background: var(--line-soft); border-radius: 8px; overflow: visible; border: 1px solid var(--line); }
.bar-done, .bar-pending { position: absolute; top: -1px; bottom: -1px; left: 0; border-radius: 8px; }
.bar-pending { opacity: .35; border-radius: 0 8px 8px 0; }
.bar-marker { position: absolute; top: -4px; bottom: -4px; width: 2px; background: var(--navy); border-radius: 2px; transform: translateX(-1px); }
.time-bar { height: 6px; background: var(--line-soft); border-radius: 6px; overflow: hidden; margin-bottom: 8px; }
.time-bar > div { height: 100%; background: linear-gradient(90deg, #fdba74, var(--brand)); border-radius: 6px; }

/* ---------- Dashboard leerling ---------- */
.hero { display: flex; align-items: center; gap: 28px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 28px; box-shadow: var(--shadow); position: relative; overflow: hidden; }
.hero::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 6px; background: var(--brand); }
.hero-achter::before { background: var(--bad); }
.hero-let-op::before { background: #f59e0b; }
.hero-op-koers::before { background: var(--ok); }
.hero-text { flex: 1; }
.hero-hello { color: var(--brand); font-weight: 700; font-size: 15px; display: flex; align-items: center; gap: 10px; margin-bottom: 4px; }
.hero-group { background: var(--line-soft); color: var(--muted); font-weight: 500; font-size: 12px; padding: 2px 8px; border-radius: 6px; }
.hero h1 { font-size: 28px; margin-bottom: 6px; }
.hero p { color: var(--text); max-width: 560px; }
.hero-meta { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 10px; }
.hero-ring { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.hero-ring .ring-label { font-size: 28px; }
.hero-ring-cap { font-size: 12px; color: var(--muted); }
.dash-cols { display: grid; grid-template-columns: 1.15fr 1fr; gap: 18px; }
.steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.steps a { display: flex; align-items: center; gap: 12px; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--ink); font-weight: 500; transition: border-color .15s, background .15s; }
.steps a:hover { border-color: var(--c); background: color-mix(in srgb, var(--c) 5%, white); }
.step-icon { width: 32px; height: 32px; display: inline-flex; align-items: center; justify-content: center; border-radius: 8px; background: color-mix(in srgb, var(--c) 12%, white); color: var(--c); flex-shrink: 0; }
.steps a > span:nth-child(2) { flex: 1; }
.step-arrow { color: var(--muted); }
.period-card .days { font-size: 13px; font-weight: 700; color: var(--brand-dark); background: var(--brand-soft); padding: 3px 10px; border-radius: 999px; white-space: nowrap; }
.period-card .days.soon { color: var(--bad); background: var(--bad-bg); }
.goals { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 4px; }
.goal { display: flex; align-items: center; gap: 10px; font-size: 14px; padding: 4px 0; }
.goal a { flex: 1; color: var(--ink); text-decoration: none; }
.goal a:hover { color: var(--c); }
.goal-check { width: 20px; height: 20px; border-radius: 6px; border: 2px solid color-mix(in srgb, var(--c) 45%, white); display: inline-flex; align-items: center; justify-content: center; color: #fff; flex-shrink: 0; }
.goal.met .goal-check { background: var(--c); border-color: var(--c); }
.goal-num { font-variant-numeric: tabular-nums; font-weight: 700; color: var(--muted); font-size: 13px; }
.goal.met .goal-num { color: var(--c); }
.section-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.sec-card { display: flex; flex-direction: column; gap: 8px; padding: 16px; background: var(--card); border: 1px solid var(--line); border-top: 4px solid var(--c); border-radius: var(--radius); text-decoration: none; color: inherit; box-shadow: var(--shadow); transition: transform .15s, box-shadow .15s; }
.sec-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(15,23,42,.1); }
.sec-card-top { display: flex; justify-content: space-between; align-items: center; }
.sec-card-icon { width: 38px; height: 38px; border-radius: 10px; background: var(--soft); color: var(--c); display: inline-flex; align-items: center; justify-content: center; }
.sec-card h3 { color: var(--c); font-size: 17px; }
.sec-card-sub { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; color: color-mix(in srgb, var(--c) 75%, var(--navy)); margin-top: -6px; }
.sec-card-foot { display: flex; justify-content: space-between; font-size: 13px; }
.sec-card-foot b { color: var(--navy); }
.badges { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; }
.badge { text-align: center; padding: 12px 8px; border-radius: 12px; border: 1px dashed var(--line); color: var(--muted); }
.badge-icon { width: 52px; height: 52px; margin: 0 auto 8px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--line-soft); color: #94a3b8; }
.badge.earned { border-style: solid; border-color: #fed7aa; background: var(--brand-soft); color: var(--ink); }
.badge.earned .badge-icon { background: linear-gradient(135deg, #fb923c, var(--brand)); color: #fff; box-shadow: 0 4px 12px rgba(234,88,12,.3); }
.badge-title { font-weight: 700; font-size: 13px; color: inherit; }
.badge-desc { font-size: 11px; line-height: 1.35; margin-top: 2px; }
.badge.big { border: 0; background: none; }
.badge.big .badge-icon { width: 84px; height: 84px; }
.celebrate { text-align: center; }
.celebrate h3 { font-size: 20px; color: var(--brand-dark); }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.pillar { display: flex; gap: 12px; padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }
.pillar-icon { width: 34px; height: 34px; border-radius: 9px; background: var(--brand-soft); color: var(--brand); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.pillar h3 { margin-bottom: 2px; }
.pillar p { font-size: 13px; color: var(--muted); margin: 0; }

/* ---------- Onderdeel-pagina ---------- */
.sec-head { display: flex; align-items: center; gap: 16px; padding-bottom: 14px; border-bottom: 2px solid var(--c); }
.sec-icon { width: 48px; height: 48px; border-radius: 12px; background: var(--soft); color: var(--c); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.sec-icon.sm { width: 34px; height: 34px; border-radius: 9px; background: color-mix(in srgb, var(--c) 10%, white); color: var(--c); }
.sec-titles { flex: 1; }
.sec-head h1 { color: var(--c); font-size: 28px; }
.sec-sub { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--c); margin-top: 2px; }
.intro { background: var(--soft); border-left: 4px solid var(--c); border-radius: 0 10px 10px 0; padding: 14px 18px; color: var(--ink); font-size: 14.5px; border: 1px solid color-mix(in srgb, var(--c) 25%, white); border-left-width: 4px; }
.status-card { display: flex; flex-direction: column; gap: 10px; }
.status-line { display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; }
.extras { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.extras li { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.extras li.ok { color: var(--ok); }
.extras.compact { flex-direction: row; flex-wrap: wrap; gap: 6px 18px; margin: -4px 0 10px; }
.extras.compact li { font-size: 13px; }
.choice-card { padding: 14px 20px; }
.choice-card select { max-width: 240px; }
.rows { display: flex; flex-direction: column; gap: 8px; }
.row-group { font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--c); margin: 12px 0 2px; }
.row { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--card); border: 1px solid var(--line); border-radius: 10px; cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.row:hover { border-color: color-mix(in srgb, var(--c) 50%, white); box-shadow: var(--shadow); }
.row-status-dot { width: 26px; height: 26px; border-radius: 50%; border: 2px solid var(--line); display: inline-flex; align-items: center; justify-content: center; color: #fff; flex-shrink: 0; }
.row-afgetekend .row-status-dot, .row-klaar .row-status-dot { background: var(--c); border-color: var(--c); }
.row-ingeleverd .row-status-dot { border-color: var(--c); border-style: dashed; }
.row-terug .row-status-dot { border-color: #f59e0b; }
.row-terug { border-color: #fde68a; background: #fffdf5; }
.row-main { flex: 1; min-width: 0; }
.row-title { font-weight: 500; color: var(--navy); }
.row-meta { font-size: 13px; color: var(--muted); overflow: hidden; text-overflow: ellipsis; }
.row-feedback { display: flex; gap: 6px; align-items: flex-start; font-size: 13px; color: #92400e; margin-top: 4px; }
.row-feedback .icon { margin-top: 3px; }
.row-signed { font-size: 12px; color: var(--ok); margin-top: 2px; }
.row-side { display: flex; align-items: center; gap: 12px; }
.row-action { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; font-weight: 500; color: var(--c); }
.add-row { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 14px; border: 2px dashed color-mix(in srgb, var(--c) 40%, white); border-radius: 10px; background: color-mix(in srgb, var(--c) 4%, white); color: var(--c); font-weight: 500; cursor: pointer; }
.add-row:hover { background: color-mix(in srgb, var(--c) 9%, white); }

/* ---------- Modal ---------- */
.overlay { position: fixed; inset: 0; background: rgba(15, 23, 42, .5); display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px 16px; z-index: 50; overflow-y: auto; animation: fade .15s; }
@keyframes fade { from { opacity: 0; } }
.modal { background: var(--card); border-radius: 16px; width: 100%; max-width: 560px; box-shadow: var(--shadow-lg); animation: pop .18s ease-out; outline: none; }
.modal-wide { max-width: 860px; }
@keyframes pop { from { transform: translateY(8px) scale(.98); opacity: 0; } }
.modal-head { display: flex; align-items: center; justify-content: space-between; padding: 18px 20px 0; gap: 10px; }
.modal-head h2 { font-size: 19px; }
.modal-body { padding: 16px 20px; display: flex; flex-direction: column; gap: 14px; }
.modal-body > div { display: flex; flex-direction: column; gap: 14px; }
.modal-foot { display: flex; gap: 8px; padding: 14px 20px; border-top: 1px solid var(--line); background: #fcfcfd; border-radius: 0 0 16px 16px; flex-wrap: wrap; justify-content: flex-end; }
.modal-sec { display: flex !important; flex-direction: row !important; align-items: center; gap: 8px !important; color: var(--c); font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .05em; }
.modal-sec .chip { text-transform: none; letter-spacing: 0; margin-left: auto; }
.entry-form { display: flex; flex-direction: column; gap: 14px; }
.check-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; max-height: 260px; overflow-y: auto; padding: 4px; }
.totp-setup ol { padding-left: 20px; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.qr { display: block; margin: 4px auto; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 6px; }

/* ---------- Toasts ---------- */
.toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); display: flex; flex-direction: column; gap: 8px; z-index: 100; width: max-content; max-width: calc(100vw - 32px); }
.toast { display: flex; align-items: center; gap: 10px; background: var(--navy); color: #fff; padding: 11px 16px; border-radius: 10px; box-shadow: var(--shadow-lg); font-size: 14px; transition: opacity .3s, transform .3s; }
.toast-ok .icon { color: #4ade80; }
.toast-error { background: #7f1d1d; }
.toast.out { opacity: 0; transform: translateY(6px); }

/* ---------- Coach ---------- */
.seg { display: inline-flex; background: var(--line-soft); border: 1px solid var(--line); border-radius: 10px; padding: 3px; }
.seg button { border: 0; background: none; padding: 7px 14px; border-radius: 8px; cursor: pointer; font-weight: 500; color: var(--muted); }
.seg button.active { background: var(--card); color: var(--navy); box-shadow: var(--shadow); }
.tiles { display: grid; grid-template-columns: repeat(6, 1fr); gap: 12px; }
.tile { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: 12px; align-items: center; text-align: left; padding: 14px 16px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); cursor: pointer; box-shadow: var(--shadow); transition: border-color .15s, box-shadow .15s; --tc: var(--muted); }
.tile:hover { border-color: var(--tc); }
.tile.active { border-color: var(--tc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--tc) 18%, transparent); }
.tile-icon { grid-row: 1 / 3; width: 38px; height: 38px; border-radius: 10px; display: inline-flex; align-items: center; justify-content: center; background: color-mix(in srgb, var(--tc) 12%, white); color: var(--tc); }
.tile-num { font-size: 22px; font-weight: 700; color: var(--navy); line-height: 1.1; }
.tile-label { font-size: 12px; color: var(--muted); }
.tile-red { --tc: var(--bad); } .tile-orange { --tc: #d97706; } .tile-blue { --tc: var(--info); } .tile-purple { --tc: #7c3aed; } .tile-grey { --tc: #64748b; } .tile-neutral { --tc: var(--navy); }
.toolbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.toolbar > p { margin: 0; max-width: 640px; }
.toolbar select { width: auto; min-width: 160px; }
.search { position: relative; display: flex; align-items: center; min-width: 220px; }
.search .icon { position: absolute; left: 11px; color: var(--muted); }
.search input[type=search] { padding-left: 34px; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); margin-left: auto; }
.legend span { display: inline-flex; align-items: center; gap: 5px; }
.lg { display: inline-block; width: 14px; height: 8px; border-radius: 4px; }
.lg-done { background: var(--brand); } .lg-pending { background: var(--brand); opacity: .35; } .lg-marker { width: 2px; height: 12px; background: var(--navy); }
.table-wrap { overflow-x: auto; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.tbl { width: 100%; border-collapse: collapse; font-size: 14px; }
.tbl th { text-align: left; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; padding: 11px 12px; border-bottom: 1px solid var(--line); background: #fcfcfd; white-space: nowrap; }
.tbl td { padding: 10px 12px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.tbl tbody tr:last-child td { border-bottom: 0; }
.tbl tr.click { cursor: pointer; }
.tbl tr.click:hover td { background: #fffaf5; }
.tbl tr.inactive td { opacity: .55; }
.tbl .w-check { width: 36px; }
.th-sort { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-transform: inherit; letter-spacing: inherit; cursor: pointer; }
.th-sort.active { color: var(--brand-dark); }
.sec-th { color: var(--c) !important; text-align: center !important; }
.sec-td { min-width: 74px; }
.sec-td .bar { height: 7px; }
.mini-num { display: block; text-align: center; font-size: 11px; color: var(--muted); margin-top: 4px; font-variant-numeric: tabular-nums; }
.mini-num.achter { color: var(--bad); font-weight: 700; }
.mini-num.let-op { color: var(--warn); font-weight: 700; }
.name-cell { display: flex; align-items: center; gap: 10px; font-weight: 500; color: var(--navy); white-space: nowrap; }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--brand-soft); color: var(--brand-dark); display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; flex-shrink: 0; }
.avatar.big { width: 56px; height: 56px; font-size: 22px; }
.flag { color: #7c3aed; display: inline-flex; }
.flag .icon { fill: #7c3aed; }
.mine-tag { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; color: var(--brand-dark); background: var(--brand-soft); padding: 1px 6px; border-radius: 4px; font-weight: 700; }
.queue { display: flex; flex-direction: column; gap: 8px; }
.queue-item { display: flex; align-items: center; gap: 14px; padding: 14px 16px; background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--c); border-radius: 10px; box-shadow: var(--shadow); }
.q-sec { width: 34px; height: 34px; border-radius: 9px; background: color-mix(in srgb, var(--c) 10%, white); color: var(--c); display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; }
.q-main { flex: 1; min-width: 0; }
.q-student { font-weight: 700; color: var(--navy); text-decoration: none; }
.q-student:hover { text-decoration: underline; }
.q-top { font-size: 14px; }
.q-title { font-weight: 500; color: var(--ink); }
.q-actions { display: flex; gap: 8px; }
.student-head { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.sh-left { display: flex; align-items: center; gap: 16px; }
.sh-chips { display: flex; gap: 6px; margin-top: 8px; flex-wrap: wrap; }
.coach-note textarea { margin-bottom: 10px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.mini-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.mini-card { display: flex; flex-direction: column; gap: 8px; padding: 12px; background: var(--card); border: 1px solid var(--line); border-top: 3px solid var(--c); border-radius: 10px; text-decoration: none; color: inherit; }
.mini-card:hover { box-shadow: var(--shadow); }
.mini-top { display: flex; align-items: center; gap: 6px; color: var(--c); font-weight: 700; font-size: 13px; }
.mini-foot { display: flex; justify-content: space-between; align-items: center; font-size: 13px; font-weight: 700; color: var(--navy); }
.coach-sec { border-top: 3px solid var(--c); scroll-margin-top: 80px; }
.coach-sec-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; flex-wrap: wrap; }
.coach-sec-head h2 { color: var(--c); }
.coach-rows { display: flex; flex-direction: column; }
.crow { display: grid; grid-template-columns: 1fr auto 108px; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid var(--line-soft); }
.crow-main { min-width: 0; }
.crow .btn { justify-self: end; }
.crow-spacer { width: 1px; }

/* ---------- Beheer ---------- */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; }
.tab { display: inline-flex; align-items: center; gap: 7px; padding: 10px 14px; text-decoration: none; color: var(--muted); font-weight: 500; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tab:hover { color: var(--navy); }
.tab.active { color: var(--brand-dark); border-bottom-color: var(--brand); }
.page.wide > div:last-child { display: flex; flex-direction: column; gap: 16px; }
.group-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 14px; }
.group-card .card-head { margin-bottom: 10px; }
.bulk-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; background: var(--navy); color: #fff; padding: 10px 14px; border-radius: 10px; }
.bulk-bar select { width: auto; min-width: 150px; color: var(--ink); }
.period-box { border: 1px solid var(--line); border-radius: 10px; padding: 12px; display: flex; flex-direction: column; gap: 10px; }
.targets-tbl td, .targets-tbl th { text-align: center; }
.targets-tbl td:first-child, .targets-tbl th:first-child { text-align: left; white-space: nowrap; }
.privacy-list { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }
.danger-zone { border-color: #fecaca; }
.danger-zone h2 { color: var(--bad); }
.danger-zone .form-grid { margin: 12px 0 14px; }

/* Inlogkaarten */
.cards-sheet { display: grid !important; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px !important; max-height: 50vh; overflow-y: auto; padding: 2px; }
.login-card-print { border: 1.5px dashed #94a3b8; border-radius: 12px; padding: 14px 16px; background: #fff; break-inside: avoid; page-break-inside: avoid; }
.lcp-title { font-size: 16px; color: var(--navy); margin: 8px 0 2px; }
.lcp-name { font-weight: 700; color: var(--brand-dark); margin-bottom: 8px; }
.login-card-print dl { display: grid; grid-template-columns: auto 1fr; gap: 3px 10px; margin: 0 0 8px; font-size: 13px; }
.login-card-print dt { color: var(--muted); }
.login-card-print dd { margin: 0; color: var(--navy); font-weight: 500; word-break: break-all; }
.login-card-print dd.big { font-size: 17px; font-weight: 700; }
.login-card-print p { font-size: 11px; color: var(--muted); margin: 0; }
#print-area { display: none; }

@media print {
  body.printing > *:not(#print-area) { display: none !important; }
  body.printing #print-area { display: block; }
  #print-area .cards-sheet { grid-template-columns: repeat(2, 1fr); max-height: none; overflow: visible; gap: 10px; }
  body { background: #fff; }
  .brand-pill { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* ---------- Responsive ---------- */
.hide-sm, .hide-md { }
@media (max-width: 1100px) {
  .tiles { grid-template-columns: repeat(3, 1fr); }
  .hide-md { display: none; }
}
@media (max-width: 900px) {
  .main.with-sidebar { grid-template-columns: 1fr; gap: 16px; }
  .sidebar { position: static; padding: 8px; }
  .sidebar > div { display: flex; gap: 6px; overflow-x: auto; }
  .side-title { display: none; }
  .side-link { flex-shrink: 0; white-space: nowrap; }
  .dash-cols { grid-template-columns: 1fr; }
  .pillars { grid-template-columns: 1fr; }
  .login-page { grid-template-columns: 1fr; }
  .login-brand { padding: 32px 24px; border-right: 0; border-bottom: 1px solid var(--line); }
  .cover-toc { display: none; }
  .form-grid.cols-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  body { font-size: 14.5px; }
  .topbar-inner { padding: 0 12px; gap: 8px; }
  .logo-text, .logo-year, .hide-sm { display: none; }
  .nav-link { padding: 8px 9px; }
  .main { padding: 16px 16px 32px; }
  .hero { flex-direction: column-reverse; align-items: stretch; text-align: left; padding: 22px; gap: 14px; }
  .hero-ring { flex-direction: row; gap: 14px; }
  .hero h1 { font-size: 22px; }
  .tiles { grid-template-columns: repeat(2, 1fr); }
  .form-grid, .form-grid.cols-3, .form-grid.cols-4 { grid-template-columns: 1fr; }
  .row { flex-wrap: wrap; }
  .row-side { width: 100%; justify-content: space-between; padding-left: 40px; }
  .queue-item { flex-wrap: wrap; }
  .q-actions { width: 100%; justify-content: flex-end; }
  .crow { grid-template-columns: 1fr auto; }
  .crow .btn, .crow-spacer { grid-column: 1 / -1; justify-self: stretch; }
  .student-head { flex-direction: column; align-items: flex-start; }
  .kv { grid-template-columns: 1fr; gap: 2px; }
  .kv dd { margin-bottom: 8px; }
  .sec-head h1 { font-size: 22px; }
  .search { min-width: 0; flex: 1; }
  .check-list { grid-template-columns: 1fr; }
  .modal-foot .btn { flex: 1; }
  .modal-foot .spacer { display: none; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }
.field.field-check { flex-direction: row; align-items: center; justify-content: flex-start; gap: 10px; }
.field.field-check .field-label { font-size: 14px; font-weight: 400; color: var(--text); }
