/* app.monsternemer.nl: telefoon eerst, licht overdag (leesbaar in de zon), donker als het toestel donker staat.
   Zelfde familie als monsternemer.nl: Geist, inkt #121417, geel #FFCD00. */
@font-face { font-family: 'Geist'; src: url('/geist.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url('/geist-mono.woff2') format('woff2'); font-weight: 100 900; font-display: swap; }

:root {
  --papier: #FFFFFF; --inkt: #121417; --accent: #FFCD00; --op-accent: #121417; --groen: #00B37E;
  --vlak: #F3F3F0; --vlak-2: #E9E9E4; --lijn: rgba(18,20,23,.14); --zacht: rgba(18,20,23,.62); --rood: #C8381E;
  --tab-h: 62px; --r: 12px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root { --papier: #121417; --inkt: #FFFFFF; --vlak: #1B1E24; --vlak-2: #252932; --lijn: rgba(255,255,255,.16); --zacht: rgba(255,255,255,.68); --rood: #FF6B4A; color-scheme: dark; }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--papier); color: var(--inkt); font: 400 16px/1.5 'Geist', system-ui, sans-serif; -webkit-font-smoothing: antialiased;
  padding-bottom: calc(var(--tab-h) + env(safe-area-inset-bottom)); min-height: 100dvh; }
body.is-kaal { padding-bottom: 0; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 800; letter-spacing: -.03em; line-height: 1.1; overflow-wrap: anywhere; }
h2 { font-size: 20px; margin-bottom: 10px; }
h2 small { font-weight: 500; font-size: 14px; color: var(--zacht); letter-spacing: 0; }
p { margin: 0 0 10px; }
.klein { font-size: 13px; color: var(--zacht); }
.let { color: var(--rood); font-weight: 600; font-size: 12px; }
.leeg-tekst { color: var(--zacht); }

/* kop */
.kop { position: sticky; top: 0; z-index: 20; background: var(--papier); border-bottom: 1px solid var(--lijn); padding-top: env(safe-area-inset-top); }
.kop-in { display: flex; align-items: center; gap: 10px; min-height: 54px; padding: 0 16px; max-width: 760px; margin-inline: auto; }
.kop-merk, .kop-terug { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 36px; margin-left: -6px; color: var(--inkt); text-decoration: none; flex: none; }
.kop-merk .merk { width: 26px; }
.kop-terug .ic { width: 26px; height: 26px; }
.kop-titel { font-size: 19px; font-weight: 800; letter-spacing: -.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 1; min-width: 0; }
.hoofd { max-width: 760px; margin-inline: auto; padding: 14px 16px 24px; min-width: 0; }
.intro { font-size: 17px; }

/* tabbalk */
.tabbalk { position: fixed; inset: auto 0 0; z-index: 30; display: grid; grid-template-columns: repeat(5, 1fr); background: var(--papier); border-top: 1px solid var(--lijn);
  padding-bottom: env(safe-area-inset-bottom); height: calc(var(--tab-h) + env(safe-area-inset-bottom)); }
.tab { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; text-decoration: none; color: var(--zacht); font-size: 11px; font-weight: 500; position: relative; -webkit-tap-highlight-color: transparent; }
.tab .ic { width: 24px; height: 24px; }
.tab.is-actief { color: var(--inkt); font-weight: 600; }
.tab.is-actief::before { content: ""; position: absolute; top: -1px; left: 25%; right: 25%; height: 3px; background: var(--accent); border-radius: 0 0 3px 3px; }
@media (min-width: 900px) {
  .tabbalk { inset: 0 auto 0 0; width: 92px; grid-template-columns: 1fr; grid-auto-rows: 76px; align-content: start; padding-top: 80px; border-top: 0; border-right: 1px solid var(--lijn); height: auto; }
  .tab.is-actief::before { top: 10%; bottom: 10%; left: -1px; right: auto; width: 3px; height: auto; border-radius: 0 3px 3px 0; }
  body { padding-bottom: 0; padding-left: 92px; }
  body.is-kaal { padding-left: 0; }
}

/* tegels (stats) */
.tegels { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 14px 0 10px; }
.tegels-klein { margin-top: 10px; }
@media (min-width: 560px) { .tegels { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tegel { background: var(--vlak); border-radius: var(--r); padding: 12px 14px; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.tegel-link { text-decoration: none; display: contents; }
.t-getal { font-size: 30px; font-weight: 800; letter-spacing: -.035em; line-height: 1; font-variant-numeric: tabular-nums; }
.t-getal small { font-size: 16px; font-weight: 500; color: var(--zacht); letter-spacing: 0; }
.tegels-klein .t-getal { font-size: 22px; }
.t-label { font-size: 12px; color: var(--zacht); }
.balk { height: 6px; background: var(--vlak-2); border-radius: 3px; overflow: hidden; margin: 6px 0 4px; }
.balk i { display: block; height: 100%; background: var(--accent); border-radius: 3px; transition: width .4s; }

/* blokken en rijen */
.blok { margin: 22px 0 0; }
.blok-kop { margin-top: 0; }
.blok-accent { background: var(--vlak); border-left: 4px solid var(--accent); border-radius: var(--r); padding: 14px 14px 10px; }
.rijen { border-top: 1px solid var(--lijn); }
.rij { display: flex; align-items: center; gap: 8px; border-bottom: 1px solid var(--lijn); min-height: 56px; }
.rij-link { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; padding: 10px 0; text-decoration: none; }
.rij-link b { font-weight: 600; overflow-wrap: anywhere; }
.rij-sub { font-size: 13px; color: var(--zacht); }
.rij-stand { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 3px; }
.rij-datum { font-size: 12px; color: var(--zacht); }
.rij-bel, .vink { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; border-radius: 50%; background: var(--vlak); color: var(--inkt); border: 0; flex: none; cursor: pointer; text-decoration: none; }
.rij-bel .ic, .vink .ic { width: 22px; height: 22px; }
.vink { background: var(--accent); color: var(--op-accent); }
.rij-actie { flex: none; }
.rij-afspraak { flex-direction: column; align-items: flex-start; gap: 1px; padding: 10px 0; text-decoration: none; }
.rij-afspraak b { font-weight: 600; }
.rij-wanneer { font-size: 13px; font-weight: 600; color: var(--zacht); }
.rij-afspraak.is-vandaag .rij-wanneer { color: var(--inkt); }
.rij-afspraak.is-vandaag { border-left: 4px solid var(--accent); padding-left: 10px; }
.lijstje { margin: 8px 0 0; padding-left: 18px; }
.lijstje li { margin: 2px 0; }
.log { list-style: none; margin: 0; padding: 0; }
.log li { padding: 8px 0; border-bottom: 1px solid var(--lijn); font-size: 14px; }
.log .klein { display: inline-block; min-width: 96px; }

/* chips */
.chip { display: inline-block; font-size: 12px; font-weight: 600; padding: 2px 8px; border-radius: 6px; background: var(--vlak-2); color: var(--inkt); line-height: 1.5; white-space: nowrap; }
.chip.is-nieuw, .chip.is-open { background: var(--vlak-2); color: var(--zacht); }
.chip.is-gebeld { background: var(--vlak-2); }
.chip.is-afspraak { background: var(--accent); color: var(--op-accent); }
.chip.is-bezig { background: color-mix(in srgb, var(--accent) 35%, var(--vlak)); }
.chip.is-klaar, .chip.is-bemonsterd, .chip.is-verzonden { background: var(--groen); color: #fff; }
.chip.is-afgezegd, .chip.is-overgeslagen { background: transparent; box-shadow: inset 0 0 0 1px var(--lijn); color: var(--zacht); }

/* filters (bedrijven) */
.filters { display: flex; gap: 6px; overflow-x: auto; padding: 2px 0 10px; margin: 0 -16px; padding-inline: 16px; scrollbar-width: none; }
.filters::-webkit-scrollbar { display: none; }
.filter { flex: none; text-decoration: none; font-size: 14px; font-weight: 600; padding: 7px 12px; border-radius: 8px; background: var(--vlak); color: var(--zacht); }
.filter small { font-weight: 500; font-size: 12px; }
.filter.is-actief { background: var(--inkt); color: var(--papier); }
.streken { display: grid; gap: 10px; }
.streek { display: block; text-decoration: none; background: var(--vlak); border-radius: var(--r); padding: 12px 14px 10px; }
.streek-kop { display: flex; flex-direction: column; gap: 1px; }
.streek-kop span { font-size: 13px; color: var(--zacht); }

/* knoppen en formulieren */
.knop { display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--accent); color: var(--op-accent); border: 0; border-radius: 10px;
  font: 600 16px/1 'Geist', sans-serif; padding: 14px 18px; cursor: pointer; text-decoration: none; -webkit-tap-highlight-color: transparent; }
.knop:disabled { opacity: .55; cursor: wait; }
.knop.licht { background: transparent; color: var(--inkt); box-shadow: inset 0 0 0 1.5px var(--lijn); }
.knop.klein { font-size: 14px; padding: 10px 13px; }
.knop.groot { width: 100%; padding: 16px; font-size: 17px; }
.knop.is-klaar { background: var(--groen); color: #fff; }
.knop .ic { width: 18px; height: 18px; }
.knoppen { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0; }
.inline { display: inline; }
.formulier { display: grid; gap: 12px; }
.formulier .knop { justify-self: start; }
.veld { display: grid; gap: 5px; min-width: 0; }
.v-label { font-size: 13px; color: var(--zacht); }
input[type=text], input[type=number], input[type=datetime-local], input[type=email], select, textarea {
  width: 100%; font: 400 16px/1.4 'Geist', sans-serif; color: var(--inkt); background: var(--papier); border: 1.5px solid var(--lijn); border-radius: 10px; padding: 11px 12px; min-width: 0; }
textarea { resize: vertical; }
select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--zacht) 50%), linear-gradient(135deg, var(--zacht) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 34px; }
input:focus-visible, select:focus-visible, textarea:focus-visible, .knop:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.twee { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
details.blok summary { cursor: pointer; font-weight: 600; padding: 8px 0; }
.melding { background: var(--vlak); border-left: 4px solid var(--accent); border-radius: var(--r); padding: 10px 14px; margin: 0 0 14px; font-size: 14px; }
.melding.is-fout { border-color: var(--rood); }
.fout { color: var(--rood); font-size: 14px; min-height: 1em; margin: 8px 0 0; }
.adres { color: var(--zacht); font-size: 14px; margin-bottom: 4px; }
.adres a { color: inherit; }
.etiket { font: 500 15px/1.4 'Geist Mono', ui-monospace, monospace; background: var(--vlak); padding: 10px 12px; border-radius: 8px; overflow-wrap: anywhere; }

/* kaart */
.kaart { position: relative; margin: 0 0 12px; border-radius: var(--r); overflow: hidden; background: var(--vlak-2); width: 100%; }
.kaart img { position: absolute; display: block; user-select: none; -webkit-user-drag: none; }
.kaart svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.k-perceel { fill: rgba(255,205,0,.38); stroke: #FFCD00; stroke-width: 2.5; }
.k-perceel.is-klaar { fill: rgba(0,179,126,.38); stroke: #00B37E; }
.k-perceel.is-huidig { fill: rgba(255,205,0,.6); stroke: #121417; stroke-width: 4; }
.kaart a .k-perceel:hover { fill: rgba(255,205,0,.6); }
.k-naam { fill: #fff; font: 600 12px 'Geist', sans-serif; text-anchor: middle; paint-order: stroke; stroke: #121417; stroke-width: 3px; stroke-linejoin: round; pointer-events: none; }
.k-huis path { fill: #121417; stroke: #fff; stroke-width: 1.5; }
.k-huis text { fill: #fff; font: 600 11px 'Geist', sans-serif; text-anchor: middle; paint-order: stroke; stroke: #121417; stroke-width: 3px; stroke-linejoin: round; }
.k-schaal rect { fill: #121417; }
.k-schaal text { fill: #121417; font: 600 11px 'Geist', sans-serif; paint-order: stroke; stroke: #fff; stroke-width: 3px; }
.k-wissel { position: absolute; top: 8px; right: 8px; font: 600 12px 'Geist', sans-serif; background: #fff; color: #121417; border: 0; border-radius: 7px; padding: 6px 9px; cursor: pointer; box-shadow: 0 1px 4px rgba(0,0,0,.25); }
.kaart figcaption { position: absolute; left: 6px; bottom: 4px; font-size: 9px; color: #121417; background: rgba(255,255,255,.75); padding: 1px 5px; border-radius: 4px; }

/* protocol */
.proto ul, .proto ol { margin: 0; padding-left: 20px; }
.proto li { margin: 6px 0; }
.proto .blok-accent { margin-top: 22px; }

/* inloggen */
.inlog { max-width: 400px; margin: 12vh auto 0; display: flex; flex-direction: column; gap: 14px; align-items: flex-start; }
.inlog .merk { width: 56px; color: var(--inkt); }
.inlog h1 { font-size: 36px; letter-spacing: -.04em; }
.inlog .veld { width: 100%; }
.leeg { margin: 10vh auto 0; max-width: 480px; }
