/* TiNi gaat op date — bordeaux op linnen, zusje van TiNi heeft honger. */

:root {
  --papier: #f6efe4;
  --vlak: #fffdf8;
  --ink: #2b2220;
  --ink-zacht: #7b6a62;
  --lijn: #e3d6c3;
  --wijn: #7a1f35;
  --wijn-diep: #5c1426;
  --wijn-zacht: #f5e4e7;
  --goud: #b8892b;
  --nacht: #2e0a14;
  --krijt: #d9675f;
  --krijt-diep: #c4524d;
  --op-donker: #fbeff1;
  --op-donker-zacht: rgba(251, 239, 241, .68);
  --roos: #ffe1d6;
  --schaduw: 0 1px 0 rgba(43, 34, 32, .04), 0 14px 30px -20px rgba(43, 34, 32, .55);
  --serif: Fraunces, Georgia, "Times New Roman", serif;
  --sans: Inter, system-ui, -apple-system, Arial, sans-serif;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
a, button, label, input, summary { -webkit-tap-highlight-color: transparent; }

html { background: var(--krijt-diep); -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.55;
  color: var(--ink);
  /* krijtrood zoals de Tidesco-letters, met wijnglaasjes en wat korrel */
  background:
    url("/tinigaatopdate/glaasjes.svg") 0 0 / 320px 320px repeat,
    url("/tinigaatopdate/korrel.svg") 0 0 / 200px 200px repeat,
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(255, 220, 205, .25), transparent 70%),
    linear-gradient(180deg, var(--krijt) 0%, var(--krijt-diep) 100%);
  background-attachment: fixed;
  min-height: 100vh;
}

button { font: inherit; color: inherit; cursor: pointer; }

main { max-width: 1080px; margin: 0 auto; padding: 0 16px 4rem; position: relative; z-index: 1; }

/* ── kop ── */
.kop {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(150, 48, 50, .78);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, .14);
  color: var(--op-donker);
}
.kop-binnen {
  max-width: 1080px; margin: 0 auto; padding: .65rem 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
}
.merk { color: inherit; text-decoration: none; }
.knop-sleutel {
  border: 1px solid var(--lijn); background: var(--vlak); border-radius: 99px;
  padding: .3rem .8rem; font-size: .82rem; font-weight: 500; white-space: nowrap;
}
.knop-sleutel.aan { background: var(--wijn-zacht); border-color: var(--wijn); color: var(--wijn); font-weight: 600; }
.sleutelvak { max-width: 1080px; margin: 0 auto; padding: 0 16px .9rem; font-size: .9rem; }
.sleutelvak label { display: block; font-weight: 600; margin-bottom: .35rem; }
.sleutelvak .knop-klein { background: var(--roos); color: var(--nacht); }
.sleutel-regel { display: flex; gap: .5rem; flex-wrap: wrap; }
.sleutel-regel input {
  flex: 1 1 180px; min-width: 0; font: inherit; padding: .45rem .8rem;
  border: 1px solid var(--lijn); border-radius: 99px; background: var(--vlak);
}
.knop-klein {
  border: 0; border-radius: 99px; padding: .45rem 1rem; background: var(--wijn); color: #fff; font-weight: 600;
}
.sleutel-melding { margin: .35rem 0 0; font-size: .82rem; color: var(--roos); min-height: 1em; }
.merk {
  font-family: var(--serif); font-weight: 600; font-size: 1.2rem;
  font-variation-settings: "SOFT" 40, "WONK" 1;
}

/* ── hero ── */
.hero {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 1.5rem; flex-wrap: wrap;
  padding: 2.4rem 0 1.6rem;
}
.bovenregel {
  margin: 0 0 .4rem; font-size: .78rem; letter-spacing: .14em;
  text-transform: uppercase; color: var(--wijn); font-weight: 600;
}
.hero-tekst { flex: 1 1 420px; }
.hero h1 {
  margin: 0; font-family: var(--serif); font-weight: 500; max-width: 17ch;
  font-size: clamp(1.9rem, 5vw, 3rem); line-height: 1.08; letter-spacing: -.02em;
  font-variation-settings: "SOFT" 60, "WONK" 1;
  color: var(--op-donker);
}
.hero h1 em { color: var(--roos); font-style: italic; }

.teller-blok { min-width: 200px; }
.teller-cijfer {
  font-family: var(--serif); font-size: 3.4rem; font-weight: 600;
  line-height: 1; color: #fff; font-variant-numeric: tabular-nums;
}
.teller-van { font-size: 1.6rem; color: var(--op-donker-zacht); font-weight: 400; margin-left: .15rem; }
.teller-label { font-size: .85rem; color: var(--op-donker-zacht); margin: .3rem 0 .5rem; }
.teller-fav { color: var(--roos); font-weight: 600; }
.balk { height: 6px; border-radius: 99px; background: rgba(255, 255, 255, .14); overflow: hidden; }
.balk span { display: block; height: 100%; width: 0; background: var(--roos); border-radius: inherit; transition: width .9s cubic-bezier(.2, .8, .2, 1); }

/* ── kiezer ── */
.kiezer {
  background: linear-gradient(135deg, rgba(140, 36, 52, .94), rgba(105, 26, 42, .94));
  border: 1px solid rgba(255, 230, 225, .25);
  color: #fbeee9;
  border-radius: 14px;
  padding: 1.4rem 1.4rem 1.5rem;
  box-shadow: var(--schaduw);
  margin-bottom: 1.6rem;
  position: relative; overflow: hidden;
}
.kiezer::after {
  content: "🍷"; position: absolute; right: -10px; top: -18px;
  font-size: 7rem; opacity: .08; transform: rotate(14deg); pointer-events: none;
}
.kiezer h2 {
  margin: 0 0 .9rem; font-family: var(--serif); font-weight: 500;
  font-size: 1.6rem; font-variation-settings: "SOFT" 60, "WONK" 1;
}
.kiezer-opties { display: flex; flex-wrap: wrap; gap: .7rem 1.2rem; align-items: center; margin-bottom: 1rem; }

.segment {
  display: inline-flex; padding: 3px; border-radius: 99px;
  background: rgba(0, 0, 0, .06); border: 1px solid var(--lijn);
}
.kiezer .segment { background: rgba(0, 0, 0, .18); border-color: transparent; }
.seg {
  border: 0; background: transparent; padding: .38rem .9rem; border-radius: 99px;
  font-size: .88rem; font-weight: 500; color: inherit; opacity: .75;
}
.seg.actief { background: var(--vlak); color: var(--wijn); opacity: 1; font-weight: 600; }

.vinkje { display: inline-flex; align-items: center; gap: .4rem; font-size: .9rem; cursor: pointer; }
.vinkje input { accent-color: var(--goud); width: 1rem; height: 1rem; }

.knop-kies {
  border: 0; border-radius: 99px; padding: .8rem 1.6rem;
  background: var(--goud); color: #2b1d0a; font-weight: 700; font-size: 1rem;
  box-shadow: 0 6px 16px -8px rgba(0, 0, 0, .5);
  transition: transform .12s;
}
.knop-kies:hover { transform: translateY(-1px); }
.knop-kies:active { transform: scale(.97); }

.uitslag {
  margin-top: 1.1rem; padding: 1rem 1.1rem; border-radius: 10px;
  background: rgba(255, 255, 255, .1); border: 1px dashed rgba(255, 255, 255, .35);
}
.uitslag-naam {
  font-family: var(--serif); font-size: 1.9rem; font-weight: 600; line-height: 1.15;
  font-variation-settings: "SOFT" 60, "WONK" 1;
}
.uitslag-naam.draait { opacity: .6; filter: blur(.5px); }
.uitslag-meta { font-size: .9rem; opacity: .85; margin: .2rem 0 .3rem; }
.kiezer .knop-tekst { color: #fbeee9; }

.knop-tekst {
  border: 0; background: none; padding: 0; font-size: .88rem; font-weight: 600;
  color: var(--wijn); text-decoration: underline; text-underline-offset: 3px;
}

/* ── kaart ── */
.kaart-blok { margin-bottom: 2rem; }
.regios { display: flex; gap: .4rem; flex-wrap: wrap; margin-bottom: .6rem; }
.regio {
  border: 1px solid var(--lijn); background: var(--vlak); border-radius: 99px;
  padding: .32rem .85rem; font-size: .85rem; font-weight: 500;
}
.regio.actief { background: var(--ink); border-color: var(--ink); color: var(--papier); }

.kaart {
  height: min(62vh, 520px); min-height: 340px;
  border-radius: 14px; border: 1px solid var(--lijn);
  box-shadow: var(--schaduw); background: #eae3d6;
}
.legende { display: flex; gap: 1rem; flex-wrap: wrap; font-size: .8rem; color: var(--ink-zacht); margin-top: .5rem; }
.legende span { display: inline-flex; align-items: center; gap: .35rem; }

.stip {
  display: inline-grid; place-items: center; width: 14px; height: 14px; border-radius: 50%;
  font-style: normal; font-size: 9px; line-height: 1;
}
.stip.vol { background: var(--wijn); border: 2px solid #fff; box-shadow: 0 0 0 1px var(--wijn); }
.stip.hol { background: #fff; border: 2.5px solid var(--wijn); }
.stip.ster { background: var(--goud); color: #fff; }
.stip.fav { background: #f2789a; color: #fff; font-size: 9px; }

/* kaarttegels iets warmer en rustiger, zodat de pins eruit springen */
.leaflet-tile-pane { filter: sepia(.28) saturate(.75) brightness(1.03); }

/* pins */
.pin { background: none; border: 0; }
.pin-stip {
  width: 22px; height: 22px; border-radius: 50%;
  display: grid; place-items: center; font-size: 11px;
  transition: transform .15s;
  box-shadow: 0 2px 6px rgba(0, 0, 0, .3);
}
.pin-stip.vol { background: var(--wijn); border: 2.5px solid #fff; color: #fff; }
.pin-stip.hol { background: #fff; border: 3px solid var(--wijn); color: var(--wijn); }
.pin-stip .s { color: var(--goud); font-size: 12px; }
.pin-stip.vol .s { color: #ffd77a; }
.pin-stip .h { color: #fff; font-size: 12px; line-height: 1; }
.pin-stip.fav { background: #f2789a; border-color: #fff; width: 26px; height: 26px; margin: -2px; }
.pin:hover .pin-stip, .pin.licht .pin-stip { transform: scale(1.35); }
.pin.licht .pin-stip { box-shadow: 0 0 0 6px rgba(184, 137, 43, .45); }

.leaflet-popup-content-wrapper { border-radius: 10px; font-family: var(--sans); }
.leaflet-popup-content { margin: .7rem .9rem; font-size: .88rem; line-height: 1.4; }
.pop-naam { font-family: var(--serif); font-size: 1.1rem; font-weight: 600; }
.pop-meta { color: var(--ink-zacht); font-size: .8rem; }
.pop-link { margin-top: .3rem; }
.pop-fav { color: #f2789a; }
.pop-comment { font-family: var(--serif); font-style: italic; margin-top: .25rem; }

/* ── lijst ── */
.filterbalk { display: flex; gap: .7rem; flex-wrap: wrap; align-items: center; margin-bottom: .8rem; }
.zoekveld {
  flex: 1 1 220px; display: flex; align-items: center; gap: .5rem;
  background: var(--vlak); border: 1px solid var(--lijn); border-radius: 99px; padding: .4rem .9rem;
}
.zoekveld input { border: 0; outline: 0; background: none; font: inherit; flex: 1; min-width: 0; }

.chips { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: .8rem; }
.tip { margin: 0 0 1.4rem; font-size: .85rem; color: var(--ink-zacht); }
.chip {
  border: 1px solid var(--lijn); background: var(--vlak); border-radius: 99px;
  padding: .3rem .75rem; font-size: .82rem;
}
.chip.actief { background: var(--wijn-zacht); border-color: var(--wijn); color: var(--wijn); font-weight: 600; }

.groep { margin-bottom: 1.8rem; }
.groep-kop { display: flex; align-items: baseline; gap: .8rem; margin-bottom: .5rem; }
.groep-kop h3 {
  margin: 0; font-family: var(--serif); font-weight: 600; font-size: 1.3rem;
  font-variation-settings: "SOFT" 60, "WONK" 1;
}
.groep-tel { font-size: .8rem; color: var(--ink-zacht); font-variant-numeric: tabular-nums; }
.groep-balk { flex: 1; max-width: 140px; height: 4px; border-radius: 99px; background: var(--lijn); overflow: hidden; align-self: center; }
.groep-balk span { display: block; height: 100%; background: var(--wijn); }
.badge { font-size: .75rem; }

.kaarten { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: .5rem; }

.resto {
  background: var(--vlak); border: 1px solid var(--lijn); border-radius: 10px;
  transition: border-color .15s, box-shadow .15s;
}
.resto.nog { background: transparent; border-style: dashed; }
.resto[open] { box-shadow: var(--schaduw); border-color: var(--wijn); }
.resto.licht { border-color: var(--goud); box-shadow: 0 0 0 3px rgba(184, 137, 43, .3); }
.resto summary {
  list-style: none; cursor: pointer; padding: .65rem .85rem;
  display: flex; align-items: center; gap: .6rem;
}
.resto summary::-webkit-details-marker { display: none; }
.vink {
  flex: none; width: 20px; height: 20px; border-radius: 50%;
  display: grid; place-items: center; font-size: 11px; font-weight: 700;
}
.resto.ja .vink { background: var(--wijn); color: #fff; }
.resto.nog .vink { border: 2px dashed var(--ink-zacht); }
.resto-naam { font-weight: 600; flex: 1; min-width: 0; }
.resto-naam small { font-weight: 400; color: var(--ink-zacht); font-size: .8rem; margin-left: .3rem; }
.resto-score { font-size: .8rem; color: var(--wijn); white-space: nowrap; }
.resto-hart { color: #f2789a; font-size: 1rem; line-height: 1; }
.resto.fav { border-color: #f7bccd; }
.resto-tag { font-size: .7rem; padding: .05rem .4rem; border-radius: 99px; background: var(--wijn-zacht); color: var(--wijn); font-weight: 600; }
.resto-tag.ster { background: #f6ebcf; color: #7a5a14; }

.resto-binnen { padding: 0 .85rem .8rem 2.95rem; font-size: .9rem; }
.vorkjes { font-size: 1.05rem; letter-spacing: .1em; }
.vorkjes .uit { opacity: .2; filter: grayscale(1); }
.comment { margin: .3rem 0 .4rem; font-family: var(--serif); font-style: italic; color: var(--ink); }
.zacht { color: var(--ink-zacht); font-size: .85rem; }

/* ── bewerken ── */
.bewerk { display: grid; gap: .55rem; margin-bottom: .5rem; }
.bewerk-rij { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }
.wissel {
  border: 1px solid var(--lijn); background: var(--vlak); border-radius: 99px;
  padding: .3rem .8rem; font-size: .84rem; font-weight: 500;
}
.wissel.geweest.aan { background: var(--wijn); border-color: var(--wijn); color: #fff; }
.wissel.hart.aan { background: #fde8ef; border-color: #f2789a; color: #c43d64; font-weight: 600; }
.vorken { display: flex; gap: .1rem; }
.vork {
  border: 0; background: none; padding: .15rem; font-size: 1.35rem; line-height: 1;
  opacity: .22; filter: grayscale(1); transition: opacity .12s, transform .12s;
}
.vork.aan { opacity: 1; filter: none; }
.vork:hover { transform: scale(1.15); }
.bewerk textarea {
  font: inherit; font-size: .9rem; padding: .5rem .7rem; resize: vertical;
  border: 1px solid var(--lijn); border-radius: 8px; background: #fff; width: 100%;
}
.knop-bewaar {
  border: 0; border-radius: 99px; padding: .4rem 1.1rem; background: var(--wijn); color: #fff; font-weight: 600; font-size: .88rem;
}
.knop-bewaar:disabled { opacity: .6; }
.bewerk-melding { font-size: .8rem; color: var(--ink-zacht); }

/* ── voorstellen ── */
.voorstellen-blok { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--lijn); }
.voorstellen-blok h2 {
  margin: 0 0 .2rem; font-family: var(--serif); font-weight: 500; font-size: 1.7rem;
  font-variation-settings: "SOFT" 60, "WONK" 1;
}
.voorstellen { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: .7rem; margin-top: 1rem; }
.voorstel {
  background: var(--vlak); border: 1px solid var(--lijn); border-radius: 12px; padding: .9rem 1rem;
}
.voorstel-kop { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; }
.voorstel h3 { margin: 0; font-family: var(--serif); font-size: 1.15rem; font-weight: 600; }
.voorstel-prijs { color: var(--goud); font-weight: 700; font-size: .85rem; }
.voorstel-soort { font-size: .78rem; text-transform: uppercase; letter-spacing: .08em; color: var(--wijn); font-weight: 600; margin: .1rem 0 .3rem; }
.voorstel p { margin: 0 0 .5rem; font-size: .9rem; }

.toast {
  position: fixed; left: 50%; bottom: calc(1.2rem + env(safe-area-inset-bottom)); transform: translateX(-50%);
  background: var(--ink); color: var(--papier); padding: .6rem 1rem; border-radius: 10px;
  font-size: .88rem; z-index: 2000; box-shadow: var(--schaduw); max-width: calc(100vw - 32px);
}

.leeg { color: var(--ink-zacht); text-align: center; padding: 2rem 0; }

.voet { text-align: center; color: var(--ink-zacht); font-size: .8rem; padding: 0 16px 2.5rem; }

@media (max-width: 600px) {
  .hero { padding-top: 1.6rem; }
  .teller-cijfer { font-size: 2.8rem; }
  .kiezer { padding: 1.2rem; }
  .resto-binnen { padding-left: .85rem; }
  .knop-sleutel { padding: .28rem .65rem; font-size: .78rem; }
}

/* ── op de bordeaux achtergrond ── */
.regio.actief { background: var(--roos); border-color: var(--roos); color: var(--nacht); }
.legende { color: var(--op-donker-zacht); }
.legende .stip.hol { background: transparent; border-color: var(--roos); }
.lijst-blok, .voorstellen-blok {
  background: var(--papier);
  border-radius: 18px;
  padding: 1.4rem 1.4rem 1.6rem;
  box-shadow: 0 30px 60px -30px rgba(0, 0, 0, .6);
}
.voorstellen-blok { margin-top: 1.6rem; border-top: 0; }
@media (max-width: 600px) {
  .lijst-blok, .voorstellen-blok { padding: 1.1rem .9rem 1.3rem; border-radius: 14px; }
}
.knop-sleutel { color: var(--ink); }
.seg { white-space: nowrap; }
.filterbalk .segment { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.filterbalk .segment::-webkit-scrollbar { display: none; }
