:root {
  --bg: #f5f1e8; --panel: #fffaf0; --ink: #1f2933;
  --muted: #6b7280; --line: #dfd3bd; --accent: #1f6f78;
  --open: #1f6f78; --wacht: #9a7b2f; --dicht: #9aa0a6; --urgent: #a33a2a;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f0f0f; --panel: #1c1c1c; --ink: #f0e8dc;
    --muted: #9a9490; --line: #2e2e2e; --accent: #4ab8c4;
    --open: #4ab8c4; --wacht: #d3b264; --dicht: #6b6b6b; --urgent: #e5806e;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0 auto;
  padding: 1.25rem 1rem 3rem;
  max-width: 46rem;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", sans-serif;
}

h1 { font-size: 1.6rem; margin: 0 0 .2rem; }
h2 { font-size: 1.15rem; margin: 2rem 0 .75rem; }
a { color: var(--accent); }

.lichting { margin: 0 0 .75rem; color: var(--muted); }

.voorbehoud {
  margin: 0;
  padding: .6rem .8rem;
  border-left: 3px solid var(--wacht);
  background: var(--panel);
  color: var(--muted);
  font-size: .9rem;
}

/* Vandaag */
.kop-getal { font-size: 2.4rem; font-weight: 700; color: var(--open); line-height: 1; }
.kop-regel { margin: .35rem 0 0; }
.waarschuwing { margin: .5rem 0 0; color: var(--urgent); font-weight: 600; }

/* Tijdlijn */
.strip { position: relative; height: 2rem; margin: .4rem 0; }
.strip-blok {
  position: absolute; top: 0; height: 100%;
  min-width: 3px; border-radius: 2px;
  background: var(--accent); border: none; padding: 0;
  cursor: pointer;
}
.strip-blok[data-calculated="true"] {
  background: repeating-linear-gradient(
    45deg, var(--accent), var(--accent) 3px, transparent 3px, transparent 6px);
  border: 1px solid var(--accent);
}
.strip-blok[aria-pressed="true"] { outline: 2px solid var(--ink); outline-offset: 1px; }
.strip-stage {
  position: absolute; top: 0; height: 100%;
  border-radius: 2px; background: var(--line);
}
.strip-epa { position: absolute; top: 0; height: 100%; border-radius: 2px; opacity: .55; }
.strip-vandaag {
  position: absolute; top: -.2rem; bottom: -.2rem; width: 2px;
  background: var(--urgent);
}
.strip-label { font-size: .8rem; color: var(--muted); margin: 0 0 .15rem; }
.strip-as { display: flex; justify-content: space-between; font-size: .75rem; color: var(--muted); }

/* Filters */
.filters { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .9rem; }
.filters button {
  padding: .35rem .8rem; border: 1px solid var(--line); border-radius: 999px;
  background: var(--panel); color: var(--ink); font: inherit; font-size: .9rem;
  cursor: pointer;
}
.filters button[aria-pressed="true"] {
  background: var(--accent); border-color: var(--accent); color: var(--panel);
}

/* Vaardigheden */
.epa-groep { margin-bottom: 1.4rem; }
.epa-groep > h3 { font-size: 1rem; margin: 0 0 .4rem; }
.rij {
  display: flex; flex-wrap: wrap; gap: .4rem .6rem; align-items: baseline;
  padding: .55rem .7rem; border: 1px solid var(--line); border-radius: 6px;
  background: var(--panel); margin-bottom: .35rem;
}
.rij-naam { flex: 1 1 12rem; }
.rij-datum { color: var(--muted); font-size: .85rem; }
.rij[data-status="open"] { border-left: 3px solid var(--open); }
.rij[data-status="binnenkort"] { border-left: 3px solid var(--wacht); }
.rij[data-status="later"] { border-left: 3px solid var(--dicht); }

.badge {
  font-size: .72rem; padding: .1rem .45rem; border-radius: 999px;
  border: 1px solid var(--line); color: var(--muted); white-space: nowrap;
}
.badge-facultatief { font-style: italic; }
.badge-berekend { border-color: var(--wacht); color: var(--wacht); }

/* EPA's */
.epa-kaart {
  padding: .7rem .8rem; border: 1px solid var(--line); border-radius: 6px;
  background: var(--panel); margin-bottom: .5rem;
}
.epa-kaart[data-urgent="true"] { border-color: var(--urgent); }
.epa-kop { display: flex; justify-content: space-between; gap: .5rem; font-weight: 600; }
.epa-fase { font-weight: 400; color: var(--muted); font-size: .9rem; }
.epa-kaart[data-urgent="true"] .epa-fase { color: var(--urgent); font-weight: 600; }
.epa-datums { margin: .4rem 0 0; font-size: .85rem; color: var(--muted); }
.epa-datums span { margin-right: .9rem; white-space: nowrap; }

.leeg { color: var(--muted); font-style: italic; }

footer {
  margin-top: 2.5rem; padding-top: 1rem; border-top: 1px solid var(--line);
  font-size: .85rem; color: var(--muted);
}
footer p { margin: .3rem 0; }
