/* Roosterplatform — HTML-replica van de mobiele app (donker thema) */

:root {
  --bg: #1c1d22;
  --bg-sheet: #1e1f25;
  --surface-2: #2a2c33;
  --line: #34353c;
  --line-soft: #2a2b31;
  --text: #ffffff;
  --text-2: #e3e5ea;
  --text-muted: #9aa0ab;
  --text-dim: #6d717b;
  --accent: #a8c8ff;          /* licht blauw (actieve tab, segment, voortgang) */
  --primary: #0a7cff;         /* fel blauw (geselecteerde dag, knop, nu-lijn) */
  --primary-deep: #0b4a85;    /* avatarcirkels / icoontegels */
  --today-pill: #12355e;
  --event-bg: #e3ebf6;
  --event-text: #111318;
  --event-chip: #8e959f;
  --orange: #e38300;
  --chip-dark: #2a2b31;
  --search: #474a52;
  --salmon: #f4978e;
  --work-strip: rgba(46, 160, 67, 0.18);
  --work-strip-edge: rgba(46, 160, 67, 0.45);

  --slot: 84px;               /* hoogte van 30 minuten in de tijdlijn */
  --label-w: 54px;
  --tabbar-h: 64px;
  --statusbar-h: 40px;
  --radius-card: 14px;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  background: #0d0e11;
  color: var(--text);
  font-family: 'Lato', system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
input { font: inherit; color: inherit; }

.ms {
  font-family: 'Material Symbols Rounded';
  font-weight: normal;
  font-style: normal;
  font-size: 24px;
  line-height: 1;
  letter-spacing: normal;
  text-transform: none;
  white-space: nowrap;
  direction: ltr;
  display: inline-block;
  font-variation-settings: 'FILL' 0, 'wght' 400, 'GRAD' 0, 'opsz' 24;
  user-select: none;
}
.ms.fill { font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24; }

.visually-hidden { position: absolute; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* ---------- Toestel-frame ---------- */
.device { display: grid; place-items: center; min-height: 100%; padding: 24px 0; }
.app {
  position: relative;
  width: 412px;
  height: min(892px, calc(100vh - 48px));
  background: var(--bg);
  border-radius: 36px;
  overflow: hidden;
  box-shadow: 0 0 0 10px #050506, 0 30px 80px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
}
@media (max-width: 500px) {
  .device { padding: 0; display: block; height: 100%; }
  .app { width: 100%; height: 100dvh; border-radius: 0; box-shadow: none; }
  /* De statusbalk blijft ook op de telefoon: het demopaneel start ingeklapt in het midden ervan,
     tussen de tijd en de iconen (js/demo.js). */
}

.statusbar {
  height: var(--statusbar-h);
  flex: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 28px 0 34px;
  font-size: 15px;
  font-weight: 700;
}
.statusbar__icons { display: flex; gap: 4px; align-items: center; }
.statusbar__icons .ms { font-size: 17px; font-variation-settings: 'FILL' 1; }
.statusbar__battery { transform: rotate(90deg); }

.screen { flex: 1; min-height: 0; display: flex; flex-direction: column; position: relative; }

/* ---------- Tabbar ---------- */
/* Gelijk aan de tabbar in mijn-dag-19/19a.html — wijzig ze samen */
.tabbar {
  position: relative;
  height: var(--tabbar-h);
  flex: none;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  align-items: center;
  border-top: 1px solid var(--line-soft);
  background: var(--bg);
  z-index: 30;
}
.tab {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  color: var(--text-muted);
  font-size: 10.5px;
  letter-spacing: .2px;
}
.tab .ms { font-size: 24px; font-variation-settings: 'FILL' 0, 'wght' 300, 'GRAD' 0, 'opsz' 24; }
.tab:focus-visible { outline: none; }
.tab:focus-visible .ms { outline: 1px solid var(--accent); outline-offset: 4px; border-radius: 6px; }
.tab.is-active { color: var(--accent); }
.tab.is-active .ms { font-variation-settings: 'FILL' 1, 'wght' 300, 'GRAD' 0, 'opsz' 24; }
.tabbar__indicator { display: none; }

/* ---------- Gedeelde paginakop ---------- */
.page-head { flex: none; padding: 30px 17px 18px; border-bottom: 1px solid var(--line-soft); }
.page-head__sub { font-size: 15.5px; color: var(--text-2); }
.page-head__title { font-size: 23px; font-weight: 700; margin-top: 10px; }
.scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: none; }
.scroll::-webkit-scrollbar { display: none; }

/* ---------- Chips ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 7px;
  border-radius: 6px;
  background: var(--chip-dark);
  color: var(--text);
  font-size: 13px;
  line-height: 19px;
  white-space: nowrap;
}
.chip .ms { font-size: 15px; font-variation-settings: 'FILL' 1; }

/* ---------- Afspraak-kaart (lijst + sheet) ---------- */
.appt-list { padding: 14px 17px 20px; display: flex; flex-direction: column; gap: 10px; }
.appt-card { border: 1px solid var(--line); border-radius: var(--radius-card); }
.appt-card__time { display: flex; align-items: center; gap: 16px; padding: 18px 16px 18px; font-size: 15.5px; }
.progress { position: relative; flex: 1; height: 2px; background: #4a4c53; border-radius: 2px; }
.progress::before, .progress::after {
  content: ''; position: absolute; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: #5d6068;
}
.progress::before { left: -3px; }
.progress::after { right: -3px; }
.progress__fill { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 2px; }
.progress__fill::before, .progress__fill::after {
  content: ''; position: absolute; top: 50%; width: 8px; height: 8px; margin-top: -4px; border-radius: 50%; background: var(--accent);
}
.progress__fill::before { left: -4px; }
.progress__fill::after { right: -4px; }
.progress.is-full::before, .progress.is-full::after { display: none; }
.appt-card__divider { height: 1px; margin: 0 16px; background: var(--line); }
.appt-card__body { display: flex; align-items: center; gap: 8px; padding: 18px 16px 18px 16px; }
.appt-card__main { flex: 1; min-width: 0; padding-left: 18px; position: relative; }
.appt-card__main::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 3px; border-radius: 2px; background: var(--bar, #fff);
}
.appt-card__title { font-size: 19px; font-weight: 700; letter-spacing: 0.1px; }
.appt-card__toggle { width: 40px; height: 40px; display: grid; place-items: center; color: var(--text); transition: transform 220ms var(--ease); }
.appt-card.is-open .appt-card__toggle { transform: rotate(180deg); }
.appt-card__clients { border-top: 1px solid var(--line); }
.appt-card__clients .person-row:last-child { border-bottom: 0; }
.appt-card__sub { margin-top: 4px; font-size: 13px; color: var(--text-muted); }
/* Status uit Mijn dag */
.appt-card--loopt { border-color: rgba(10, 124, 255, .6); background: #12233a; }
.appt-card--vervallen, .appt-card--noshow { opacity: .45; }
.appt-card--vervallen .appt-card__title, .appt-card--noshow .appt-card__title { text-decoration: line-through; }

/* ---------- Persoonregel (cliënten in sheet/kaart) ---------- */
.section-title { font-size: 19px; font-weight: 700; padding: 46px 17px 14px; border-bottom: 1px solid var(--line-soft); }
.person-row {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 17px;
  border-bottom: 1px solid var(--line-soft);
  text-align: left;
  font-size: 18px;
  font-weight: 700;
}
.person-row:active { background: rgba(255, 255, 255, 0.04); }
.person-row__name { flex: 1; }
.avatar {
  flex: none;
  width: 38px; height: 38px;
  border-radius: 50%;
  background: var(--primary-deep);
  color: var(--accent);
  display: grid; place-items: center;
  font-size: 15px; font-weight: 400;
}

/* ---------- Cliëntkaarten ---------- */
.search {
  display: flex; align-items: center; gap: 14px;
  height: 46px; padding: 0 16px;
  border-radius: 14px;
  background: var(--search);
}
.search .ms { font-size: 22px; color: var(--text-2); }
.search input { flex: 1; min-width: 0; background: none; border: 0; outline: none; font-size: 16px; }
.search input::placeholder { color: var(--text-2); }
.client-list { display: flex; flex-direction: column; gap: 17px; padding: 17px; }
.client-card {
  width: 100%;
  display: flex; align-items: center; gap: 18px;
  padding: 16px 20px 16px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  text-align: left;
  transition: background 150ms;
}
.client-card:active { background: rgba(255, 255, 255, 0.04); }
.client-card .avatar { width: 38px; height: 38px; color: #dbe7ff; }
.client-card .avatar .ms { font-size: 20px; font-variation-settings: 'FILL' 1; }
.client-card__text { flex: 1; min-width: 0; }
.client-card__name { font-size: 17px; font-weight: 700; }
.client-card__number { font-size: 15px; color: var(--text-2); margin-top: 6px; letter-spacing: 0.6px; }
.client-card > .ms { font-size: 24px; }
.empty { padding: 40px 17px; color: var(--text-muted); text-align: center; font-size: 15px; }

/* ---------- Bottom sheets ---------- */
.sheet-root { position: absolute; left: 0; right: 0; top: 0; bottom: var(--tabbar-h); z-index: 20; pointer-events: none; }
.sheet-overlay {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, 0.62);
  opacity: 0; transition: opacity 240ms;
  pointer-events: auto;
}
.sheet {
  position: absolute; left: 0; right: 0; bottom: 0;
  top: var(--sheet-top, 26%);
  background: var(--bg-sheet);
  border-radius: 26px 26px 0 0;
  display: flex; flex-direction: column;
  transform: translateY(100%);
  transition: transform 300ms var(--ease);
  pointer-events: auto;
}
.sheet-root.is-open .sheet-overlay { opacity: 1; }
.sheet-root.is-open .sheet { transform: translateY(0); }
.sheet__head {
  flex: none; position: relative;
  height: 76px; display: grid; place-items: center;
  border-bottom: 1px solid var(--line);
  font-size: 18px; font-weight: 700;
}
.sheet__close { position: absolute; right: 22px; top: 50%; transform: translateY(-50%); width: 40px; height: 40px; display: grid; place-items: center; }
.sheet__close .ms { font-size: 30px; }
.sheet__body { flex: 1; min-height: 0; overflow-y: auto; scrollbar-width: none; }
.sheet__body::-webkit-scrollbar { display: none; }
.sheet__pad { padding: 17px; }

/* Detailregels (cliëntgegevens) */
.detail-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  min-height: 55px; padding: 0 17px;
  border-bottom: 1px solid var(--line);
  font-size: 16.5px;
}
.detail-row__label { display: flex; align-items: center; gap: 6px; font-weight: 700; }
.detail-row__value { font-weight: 700; text-align: right; }
.copy-btn { color: var(--text-muted); display: inline-grid; place-items: center; }
.copy-btn .ms { font-size: 15px; }
.map-card {
  margin: 17px; width: calc(100% - 34px);
  display: flex; align-items: center; gap: 18px;
  padding: 17px; border-radius: var(--radius-card);
  background: #40434b; border: 1px solid #5a5d65;
  text-align: left;
}
.map-card__icon { width: 50px; height: 50px; border-radius: 10px; background: #565a63; display: grid; place-items: center; color: var(--accent); }
.map-card__text { flex: 1; }
.map-card__title { color: var(--accent); font-size: 16px; font-weight: 700; }
.map-card__sub { margin-top: 6px; font-size: 15px; color: var(--text-2); }

/* Toevoegen-opties */
.option-list { padding: 17px; display: flex; flex-direction: column; gap: 14px; }
.option {
  width: 100%;
  display: flex; align-items: center; gap: 18px;
  padding: 24px 18px;
  border: 2px solid #3b3d44; border-radius: 16px;
  text-align: left;
}
.option:active { background: rgba(255, 255, 255, 0.04); }
.option__icon { flex: none; width: 50px; height: 50px; border-radius: 12px; background: var(--primary-deep); display: grid; place-items: center; color: var(--accent); }
.option__icon .ms { font-size: 26px; }
.option__title { font-size: 16px; font-weight: 700; }
.option__sub { margin-top: 6px; font-size: 16px; color: var(--text-2); line-height: 1.3; }

/* ---------- Toast ---------- */
.toast {
  position: absolute; left: 50%; bottom: calc(var(--tabbar-h) + 16px);
  transform: translate(-50%, 20px);
  background: #e3e5ea; color: #15171c;
  padding: 10px 16px; border-radius: 10px;
  font-size: 14px; font-weight: 700;
  opacity: 0; pointer-events: none;
  transition: opacity 200ms, transform 200ms var(--ease);
  z-index: 40; white-space: nowrap;
}
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Profiel ---------- */
.profile { padding: 0 22px 24px; }
.profile__head { display: flex; align-items: center; justify-content: space-between; padding: 26px 0 0; }
.profile__title { font-size: 25px; font-weight: 700; }
.profile__gear .ms { font-size: 28px; }
.profile__avatar {
  margin: 34px auto 0; width: 104px; height: 104px; border-radius: 50%;
  background: var(--salmon); display: grid; place-items: center;
  font-size: 40px; color: #fff; letter-spacing: 1px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.35);
}
.profile__name { text-align: center; font-size: 20px; font-weight: 700; margin-top: 30px; }
.profile__role {
  display: flex; width: max-content; margin: 16px auto 0;
  align-items: center; gap: 8px; padding: 6px 13px; border-radius: 6px;
  background: #0f2c4e; color: var(--accent); font-size: 15px; font-weight: 700;
}
.profile__role .ms { font-size: 18px; }
.card-group { margin-top: 34px; border: 1px solid var(--line-soft); border-radius: 18px; overflow: hidden; }
.card-group + .card-group { margin-top: 18px; }
.info-row { display: flex; align-items: center; gap: 22px; padding: 0 18px; min-height: 85px; }
.info-row + .info-row .info-row__text { border-top: 1px solid var(--line-soft); }
.info-row__text { flex: 1; align-self: stretch; display: flex; flex-direction: column; justify-content: center; }
.info-row__label { font-size: 15px; color: var(--text-2); }
.info-row__value { font-size: 17px; margin-top: 8px; letter-spacing: 0.3px; }
.link-row { width: 100%; display: flex; align-items: center; gap: 22px; padding: 0 18px; min-height: 62px; text-align: left; }
.link-row + .link-row .link-row__label { border-top: 1px solid var(--line-soft); }
.link-row__label { flex: 1; align-self: stretch; display: flex; align-items: center; font-size: 17px; letter-spacing: 0.3px; }
.link-row .ms:last-child { font-size: 20px; color: var(--text-muted); }
.btn-primary {
  display: block; width: 100%; margin-top: 34px; height: 58px; border-radius: 999px;
  background: var(--primary); color: #fff; font-size: 17px; font-weight: 700;
  box-shadow: 0 6px 22px rgba(10, 124, 255, 0.35);
  transition: transform 120ms;
}
.btn-primary:active { transform: scale(0.98); }

/* ---------- Mijn dag (abstractielaag) ---------- */
.tabbar--5 { grid-template-columns: repeat(5, 1fr); }
/* Mijn dag: de cirkel, gecentreerd in de balk en net groter dan de andere iconen */
.tab--up { color: #fff; }
.tab--up > span:not(.orb) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.tab--up .orb { width: 50px; height: 50px; border-radius: 50%; display: grid; place-items: center; background: var(--primary); color: #fff; transform: translateY(-18px); box-shadow: 0 0 0 4px var(--bg), 0 6px 14px rgba(0, 0, 0, .35); }
.tab--up .orb .ms, .tab--up.is-active .orb .ms { font-size: 27px; font-variation-settings: 'FILL' 1, 'wght' 400, 'GRAD' 0, 'opsz' 24; }

.dag-list { padding: 18px 17px 8px; display: flex; flex-direction: column; gap: 8px; }
.dag-stat { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 6px; }
.dag-stat__pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px; border-radius: 999px; background: var(--chip-dark);
  font-size: 12.5px; color: var(--text-2);
}
.dag-stat__pill.is-late { color: var(--orange); }
.dag-stat__pill .ms { font-size: 15px; }

.dag-item {
  display: grid; grid-template-columns: 22px 1fr auto; align-items: center; gap: 12px;
  width: 100%; text-align: left; color: inherit; padding: 15px 14px;
  background: var(--bg-sheet); border: 1px solid var(--line); border-radius: var(--radius-card);
  transition: transform 140ms var(--ease), border-color 140ms;
}
.dag-item:active { transform: scale(.985); }
.dag-item__dot { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--text-dim); justify-self: center; }
.dag-item__naam { font-size: 18px; font-weight: 700; line-height: 1.25; }
.dag-item__tijd { color: var(--accent); font-size: 14.5px; margin-top: 3px; }
.dag-item__tijd s { color: var(--text-dim); margin-right: 7px; }
.dag-item__tijd em { color: var(--orange); font-style: normal; }
.dag-item__meta { color: var(--text-dim); font-size: 12.5px; margin-top: 4px; display: flex; align-items: center; gap: 5px; }
.dag-item__meta .ms { font-size: 14px; }
.dag-item__r { display: flex; align-items: center; gap: 9px; }
.dag-item__chev { color: var(--text-dim); }
.dag-item.is-run { border-color: var(--primary); background: #10233c; }
.dag-item.is-run .dag-item__dot, .dag-item.is-done .dag-item__dot { border-color: #2ea043; background: #2ea043; }
.dag-item.is-run .dag-item__dot { box-shadow: 0 0 0 4px rgba(46, 160, 67, .2); }
.dag-item.is-done { opacity: .62; }
.dag-item.is-late .dag-item__tijd { color: var(--orange); }

.dag-gat {
  display: flex; align-items: center; gap: 8px; height: 26px;
  margin-left: 12px; padding-left: 13px; border-left: 2px dashed rgba(227, 131, 0, .5);
  color: var(--orange); font-size: 12.5px;
}
.dag-gat .ms { font-size: 15px; }

.dag-foot { padding: 14px 0 4px; }
.dag-foot__btn {
  width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 700; font-size: 15px; color: var(--accent);
  border: 1px solid var(--line); border-radius: 999px; padding: 13px 0;
}
.dag-foot__btn .ms { font-size: 20px; }

.dag-btn { font-weight: 700; font-size: 14px; padding: 9px 14px; border-radius: 999px; background: var(--surface-2); color: var(--text-2); }
.dag-btn--go { background: #2ea043; color: #fff; }
.dag-btn--stop { background: var(--primary); color: #fff; }
.dag-btn:active { transform: scale(.96); }

.dag-sheet__sub { color: var(--text-muted); font-size: 13.5px; padding: 0 17px 14px; }
.dag-sheet__sub s { color: var(--text-dim); margin-right: 7px; }
.dag-act { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 12px; padding: 14px 17px; border-top: 1px solid var(--line-soft); }
.dag-act__t { font-size: 16.5px; font-weight: 700; }
.dag-act__k { color: var(--text-muted); font-size: 12.5px; margin-top: 3px; }
.dag-act__k b { color: var(--accent); }
.dag-act.is-run .dag-act__t { color: #7fd394; }
.dag-regel { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 13px 17px; border-top: 1px solid var(--line-soft); }
.dag-regel__l { color: var(--text-muted); font-size: 14px; }
.dag-nudge { display: flex; align-items: center; gap: 10px; }
.dag-nudge button { width: 38px; height: 38px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface-2); display: grid; place-items: center; font-size: 20px; }
.dag-nudge b { font-size: 18px; min-width: 62px; text-align: center; color: var(--accent); }
.dag-schuif { color: var(--orange); font-size: 13.5px; font-weight: 700; }
.dag-weg { display: block; width: 100%; margin-top: 14px; color: var(--text-dim); font-size: 14px; padding: 10px 0; }
.dag-rij { display: grid; grid-template-columns: 62px 1fr auto; align-items: center; gap: 10px; padding: 11px 17px; border-top: 1px solid var(--line-soft); font-size: 15px; }
.dag-rij__t { color: var(--text-2); font-variant-numeric: tabular-nums; }
.dag-rij__t s { display: block; color: var(--text-dim); font-size: 12px; }
.dag-rij__t em { color: var(--orange); font-style: normal; font-size: 12px; }
.dag-rij__n { display: flex; align-items: center; gap: 9px; min-width: 0; }
.dag-rij__n i { flex: none; width: 4px; height: 20px; border-radius: 2px; background: var(--primary); }
.dag-rij__n span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dag-rij.is-gat .dag-rij__n i { background: var(--orange); }
.dag-rij.is-gat .dag-rij__n { color: var(--orange); font-size: 13.5px; }
.dag-rij.is-klaar .dag-rij__n i { background: #2ea043; }
.dag-rij.is-klaar .dag-rij__n { color: var(--text-muted); }
.dag-rij__b { color: var(--text-dim); font-size: 12.5px; }

/* Locatie bij de start van een activiteit: kaartje (Google Maps) en korte status. Gebruikt in Mijn dag en Mijn rooster. */
.geokaart { display: block; margin-top: 12px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.geokaart__kaart { display: block; width: 100%; height: 150px; border: 0; }
.geokaart__onder { display: flex; align-items: center; gap: 6px; padding: 9px 12px; font-size: 13px; color: var(--text-2); text-decoration: none; }
.geokaart__onder .ms { font-size: 16px; color: var(--accent); }
.geokaart__open { margin-left: auto; display: inline-flex; align-items: center; gap: 3px; color: var(--accent); font-weight: 700; }
.geokaart__open .ms { font-size: 14px; }
.geokaart__onder:focus-visible { outline: 2px solid var(--accent); outline-offset: -2px; }
.geokaart--wacht { padding: 14px 12px; }
.geo { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; white-space: nowrap; }
.geo .ms { font-size: 15px; }
.geo--ok { color: var(--accent); }
.geo--nee { color: var(--text-muted); }
.geo--bezig { color: var(--text-muted); }
.geo--bezig i { flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); animation: geoZoek 1s ease-in-out infinite; }
@keyframes geoZoek { 0%, 100% { opacity: .25; transform: scale(.7); } 50% { opacity: 1; transform: scale(1); } }
@media (prefers-reduced-motion: reduce) { .geo--bezig i { animation: none; } }
