/* Moordoku - donkere recherchekamer, papieren plattegrond, dossierkaarten */

:root {
  --nacht: #12141a;
  --nacht-2: #1a1d25;
  --nacht-3: #242833;
  --nacht-4: #2e3340;
  --lijn: rgba(239, 231, 214, .12);
  --lijn-2: rgba(239, 231, 214, .2);
  --tekst: #efe7d6;
  --zacht: #a8a193;
  --papier: #f3ead7;
  --papier-2: #ebdfc6;
  --papier-3: #ddcca9;
  --inkt: #221f1a;
  --inkt-zacht: #5b5346;
  --rood: #c0392b;
  --rood-licht: #e0574a;
  --rood-donker: #8e2318;
  --goud: #d4a843;
  --groen: #3f9b5f;
  --radius: 14px;
  --schaduw: 0 10px 30px rgba(0, 0, 0, .45), 0 2px 6px rgba(0, 0, 0, .3);
  --display: 'Fraunces', Georgia, serif;
  --ui: 'Inter', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --typ: 'Courier Prime', 'Courier New', monospace;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  min-height: 100dvh;
  background-color: var(--nacht);
  background-image:
    radial-gradient(1200px 700px at 70% -10%, rgba(192, 57, 43, .13), transparent 60%),
    radial-gradient(900px 600px at -10% 110%, rgba(212, 168, 67, .07), transparent 60%),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 .05 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  color: var(--tekst);
  font-family: var(--ui);
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--goud); outline-offset: 2px; }
a { color: var(--goud); }
.verborgen { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ------------------------------------------------------------ knoppen */

.knop {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  border: 1px solid var(--lijn-2);
  background: var(--nacht-3);
  border-radius: 999px;
  padding: .6em 1.1em;
  font-weight: 600;
  letter-spacing: .01em;
  transition: background .15s, border-color .15s, transform .1s;
  white-space: nowrap;
}
.knop:hover { background: var(--nacht-4); border-color: rgba(239, 231, 214, .32); }
.knop:active { transform: scale(.97); }
.knop:disabled { opacity: .45; cursor: default; }
.knop.hoofd {
  background: linear-gradient(180deg, var(--rood-licht), var(--rood));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 6px 18px rgba(192, 57, 43, .35), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.knop.hoofd:hover { background: linear-gradient(180deg, #ea6559, var(--rood-licht)); }
.knop.klein { padding: .4em .8em; font-size: 13px; }
.knop.rond { width: 40px; height: 40px; padding: 0; }
.knop svg { width: 18px; height: 18px; flex: none; }
.knop .teller {
  min-width: 1.4em; height: 1.4em; padding: 0 .35em; border-radius: 999px; font-size: 11px;
  display: inline-grid; place-items: center; background: rgba(239, 231, 214, .14);
}

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--lijn-2); background: transparent; border-radius: 12px;
  padding: .55em .9em; text-align: left; line-height: 1.2;
  transition: background .15s, border-color .15s;
}
.chip small { display: block; color: var(--zacht); font-size: 12px; margin-top: 2px; }
.chip[aria-pressed="true"] { background: rgba(212, 168, 67, .14); border-color: var(--goud); }
.chip:hover { border-color: rgba(239, 231, 214, .35); }

/* ------------------------------------------------------------ start */

.start { max-width: 980px; margin: 0 auto; padding: 32px 16px 64px; }
.logo { display: flex; align-items: center; gap: 14px; }
.logo-merk {
  width: 52px; height: 52px; border-radius: 14px; flex: none;
  background: var(--papier); display: grid; place-items: center;
  box-shadow: var(--schaduw); transform: rotate(-4deg);
}
.logo-merk svg { width: 40px; height: 40px; }
.logo h1 { font-family: var(--display); font-weight: 900; font-size: clamp(40px, 8vw, 68px); margin: 0; line-height: 1; letter-spacing: -.02em; }
.logo h1 span { color: var(--rood-licht); }
.ondertitel { font-family: var(--typ); color: var(--zacht); font-size: 17px; margin: 14px 0 34px; max-width: 34em; }
.start-raster { display: grid; grid-template-columns: 1.25fr 1fr; gap: 20px; align-items: start; }
@media (max-width: 820px) { .start-raster { grid-template-columns: 1fr; } }
.paneel {
  background: linear-gradient(180deg, var(--nacht-2), #171a21);
  border: 1px solid var(--lijn);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: 0 1px 0 rgba(255, 255, 255, .03) inset;
}
.paneel h2 { font-family: var(--display); font-size: 22px; margin: 0 0 4px; font-weight: 700; }
.paneel .uitleg { color: var(--zacht); margin: 0 0 16px; font-size: 14px; }
.paneel h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--zacht); margin: 18px 0 10px; font-weight: 600; }
.paneel + .paneel { margin-top: 20px; }
.veld { display: flex; gap: 8px; }
.invoer {
  flex: 1; min-width: 0;
  background: var(--nacht); border: 1px solid var(--lijn-2); border-radius: 12px;
  padding: .65em .9em; font-size: 16px;
}
.invoer:focus { outline: none; border-color: var(--goud); box-shadow: 0 0 0 3px rgba(212, 168, 67, .2); }
.invoer.code { font-family: var(--typ); font-size: 22px; letter-spacing: .3em; text-transform: uppercase; text-align: center; }
.kleurkeuze { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }
.kleurkeuze button {
  width: 34px; height: 34px; border-radius: 50%; border: 3px solid transparent;
  background: var(--k); box-shadow: inset 0 0 0 2px rgba(0, 0, 0, .25);
}
.kleurkeuze button[aria-pressed="true"] { border-color: var(--tekst); transform: scale(1.1); }
.recent { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.recent a {
  display: flex; align-items: center; gap: 12px; text-decoration: none; color: inherit;
  padding: 10px 12px; border-radius: 12px; border: 1px solid var(--lijn); background: var(--nacht);
}
.recent a:hover { border-color: var(--lijn-2); }
.recent .code-tag { font-family: var(--typ); font-weight: 700; letter-spacing: .15em; color: var(--goud); }
.recent small { color: var(--zacht); display: block; }
.wie-ben-je { display: flex; align-items: center; gap: 10px; color: var(--zacht); font-size: 14px; margin-bottom: 22px; }
.wie-ben-je .stip { width: 12px; height: 12px; border-radius: 50%; background: var(--k); }
.wie-ben-je button { background: none; border: none; color: var(--goud); text-decoration: underline; padding: 0; }
.regels-kort { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.regels-kort li { display: flex; gap: 12px; align-items: flex-start; color: #d9d1c0; font-size: 14px; }
.regels-kort .nr {
  flex: none; width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center;
  background: var(--papier); color: var(--inkt); font-family: var(--display); font-weight: 900; font-size: 14px;
}

/* ------------------------------------------------------------ spelkop */

.kop {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 12px;
  padding: 10px 16px; padding-top: max(10px, env(safe-area-inset-top));
  background: rgba(18, 20, 26, .86);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--lijn);
}
.kop .merk { display: flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; }
.kop .merk .logo-merk { width: 34px; height: 34px; border-radius: 9px; }
.kop .merk .logo-merk svg { width: 26px; height: 26px; }
.kop .merk b { font-family: var(--display); font-weight: 900; font-size: 20px; letter-spacing: -.01em; }
.kop .zaakinfo { min-width: 0; flex: 1; display: flex; flex-direction: column; line-height: 1.2; }
.kop .zaakinfo .regel1 { font-family: var(--typ); font-size: 12px; color: var(--zacht); text-transform: uppercase; letter-spacing: .12em; }
.kop .zaakinfo .regel2 { font-family: var(--display); font-weight: 700; font-size: 17px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.klok { font-family: var(--typ); font-size: 16px; color: var(--tekst); background: var(--nacht-3); border-radius: 8px; padding: 4px 9px; border: 1px solid var(--lijn); }
.spelers { display: flex; align-items: center; }
.speler-bol {
  width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center;
  background: var(--k); color: #14161c; font-weight: 700; font-size: 13px;
  border: 2px solid var(--nacht); margin-left: -8px; position: relative;
}
.speler-bol:first-child { margin-left: 0; }
.speler-bol.ik::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid var(--k); opacity: .5; }
@media (max-width: 640px) {
  .kop { gap: 8px; padding-left: 12px; padding-right: 12px; }
  .kop .merk b { display: none; }
  .kop .zaakinfo .regel2 { font-size: 15px; }
  .kop .verberg-mobiel { display: none; }
  .klok { font-size: 14px; padding: 3px 7px; }
}

.verbinding {
  position: fixed; top: 70px; left: 50%; transform: translateX(-50%); z-index: 40;
  background: var(--rood-donker); color: #fff; border-radius: 999px; padding: 6px 14px; font-size: 13px; font-weight: 600;
  box-shadow: var(--schaduw);
}

/* ------------------------------------------------------------ spel-indeling */

.spel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 400px;
  gap: 22px;
  max-width: 1320px;
  margin: 0 auto;
  padding: 18px 16px 40px;
  align-items: start;
}
.bordkolom { position: sticky; top: 72px; display: flex; flex-direction: column; gap: 12px; min-width: 0; }
@media (max-width: 960px) {
  .spel { grid-template-columns: 1fr; gap: 14px; padding: 10px 10px 40px; }
  .bordkolom { position: static; }
}

.bordkaart {
  position: relative;
  background:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='p'><feTurbulence type='fractalNoise' baseFrequency='.6' numOctaves='4' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .45  0 0 0 0 .35  0 0 0 0 .2  0 0 0 .09 0'/></filter><rect width='100%' height='100%' filter='url(%23p)'/></svg>"),
    var(--papier);
  border-radius: 6px;
  padding: 10px;
  box-shadow: var(--schaduw), inset 0 0 60px rgba(120, 90, 40, .18);
  max-width: min(100%, calc(100dvh - 230px));
  margin: 0 auto;
  width: 100%;
}
@media (max-width: 960px) { .bordkaart { max-width: 640px; padding: 6px; } }
.bordkaart::before, .bordkaart::after {
  content: ''; position: absolute; width: 74px; height: 22px; background: rgba(240, 225, 180, .55);
  box-shadow: 0 1px 3px rgba(0, 0, 0, .2); top: -9px; z-index: 2;
}
.bordkaart::before { left: 26px; transform: rotate(-5deg); }
.bordkaart::after { right: 26px; transform: rotate(4deg); }
#bord { display: block; width: 100%; height: auto; touch-action: manipulation; user-select: none; -webkit-user-select: none; -webkit-touch-callout: none; }
#bord .klik { cursor: pointer; }
#bord .klik.geblokt { cursor: not-allowed; }
#bord .kamernaam { font-family: var(--ui); font-weight: 700; font-size: 14px; letter-spacing: .1em; fill: rgba(34, 31, 26, .62); pointer-events: none; }
#bord .assen text { font-family: var(--typ); font-weight: 700; font-size: 20px; fill: rgba(34, 31, 26, .55); }
#bord .assen .kompas-n { font-size: 12px; fill: var(--rood); }
#bord .fiche-letter { font-family: var(--display); font-weight: 900; fill: #fff; paint-order: stroke; stroke: rgba(0, 0, 0, .18); stroke-width: 2px; }
#bord .hint-teken { font-family: var(--display); font-weight: 900; font-size: 15px; fill: #221f1a; }
#bord .notitie text { font-family: var(--ui); font-weight: 700; font-size: 14px; fill: #fff; }
#bord .kruisje { stroke: var(--rood-donker); stroke-width: 7; stroke-linecap: round; opacity: .75; }
#bord .kijker-naam { font-family: var(--ui); font-weight: 700; font-size: 13px; fill: #14161c; }
#bord .licht { fill: rgba(255, 210, 80, .32); stroke: #d49a16; stroke-width: 3.5; animation: puls-licht 1.6s ease-in-out infinite; }
#bord .licht-extra { fill: none; stroke: #2f7fb5; stroke-width: 3; stroke-dasharray: 7 5; }
@keyframes puls-licht { 50% { fill: rgba(255, 210, 80, .14); } }
#bord .stuk { pointer-events: none; }
#bord .stuk .ring { fill: none; stroke: transparent; stroke-width: 5; }
#bord .stuk.gekozen .ring { stroke: var(--goud); stroke-dasharray: 9 6; animation: draai 6s linear infinite; transform-box: fill-box; transform-origin: center; }
#bord .stuk.botsing .ring { stroke: var(--rood); stroke-width: 6; stroke-dasharray: 4 5; }
#bord .stuk.fout .ring { stroke: var(--rood); stroke-width: 8; animation: knipper .5s steps(2) 6; }
#bord .stuk.dader .ring { stroke: var(--rood); stroke-width: 7; }
#bord .stuk.licht-persoon .stuk-binnen { animation: wip 1s ease-in-out infinite; }
#bord .stuk.nieuw .stuk-binnen { animation: neerzetten .35s cubic-bezier(.3, 1.6, .5, 1); }
#bord .stuk-binnen { transform-box: fill-box; transform-origin: center; }
@keyframes draai { to { transform: rotate(360deg); } }
@keyframes knipper { 50% { stroke-opacity: .15; } }
@keyframes wip { 50% { transform: scale(1.1); } }
@keyframes neerzetten { from { transform: scale(1.5) translateY(-6px); opacity: 0; } to { transform: none; opacity: 1; } }
#bord .ping-golf { transform-box: fill-box; transform-origin: center; animation: ping 1.1s ease-out forwards; opacity: 0; }
#bord .ping-golf.twee { animation-delay: .35s; }
#bord .ping-stip { animation: vervaag 2s ease-in forwards; }
@keyframes ping { 0% { transform: scale(.2); opacity: 1; } 100% { transform: scale(1.25); opacity: 0; } }
@keyframes vervaag { 70% { opacity: 1; } 100% { opacity: 0; } }

/* gereedschap */
.gereedschap { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; justify-content: center; }
.modus {
  display: inline-flex; background: var(--nacht-2); border: 1px solid var(--lijn); border-radius: 999px; padding: 4px;
}
.modus button {
  border: none; background: transparent; border-radius: 999px; padding: .45em .9em; display: inline-flex; align-items: center; gap: .45em;
  color: var(--zacht); font-weight: 600; font-size: 14px;
}
.modus button svg { width: 17px; height: 17px; }
.modus button[aria-pressed="true"] { background: var(--papier); color: var(--inkt); box-shadow: 0 2px 6px rgba(0, 0, 0, .3); }
.gereedschap .rest { display: inline-flex; gap: 6px; }
@media (max-width: 480px) {
  .modus button { padding: .45em .7em; font-size: 13px; }
  .gereedschap .knop.klein .lang { display: none; }
}

/* verdachtenrij */
.verdachtenrij {
  display: flex; gap: 6px; justify-content: center; flex-wrap: wrap;
  background: var(--nacht-2); border: 1px solid var(--lijn); border-radius: 18px; padding: 8px;
}
.vfiche {
  position: relative; border: none; background: transparent; padding: 4px 2px 6px; border-radius: 12px; width: 58px;
  display: flex; flex-direction: column; align-items: center; gap: 3px;
  transition: background .15s, transform .15s;
}
.vfiche:hover { background: rgba(239, 231, 214, .06); }
.vfiche .bol {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: var(--k); color: #fff; font-family: var(--display); font-weight: 900; font-size: 20px;
  border: 2.5px solid #fffaf0; box-shadow: 0 3px 8px rgba(0, 0, 0, .4);
  transition: transform .15s;
}
.vfiche.slachtoffer .bol { background: radial-gradient(#fff, #e6dccb); color: var(--rood-donker); border: 2.5px dashed var(--inkt); }
.vfiche .naam { font-size: 11px; color: var(--zacht); max-width: 56px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.vfiche[aria-pressed="true"] { background: rgba(212, 168, 67, .15); }
.vfiche[aria-pressed="true"] .bol { transform: scale(1.12); box-shadow: 0 0 0 3px var(--goud), 0 4px 12px rgba(0, 0, 0, .5); }
.vfiche[aria-pressed="true"] .naam { color: var(--tekst); font-weight: 600; }
.vfiche.geplaatst .bol::after {
  content: '✓'; position: absolute; top: 0; right: 6px; width: 17px; height: 17px; border-radius: 50%;
  background: var(--groen); color: #fff; font-size: 11px; font-family: var(--ui); display: grid; place-items: center; border: 2px solid var(--nacht-2);
}
.vfiche .kijkers { position: absolute; top: 0; left: 4px; display: flex; gap: 2px; }
.vfiche .kijkers i { width: 10px; height: 10px; border-radius: 50%; background: var(--k); border: 2px solid var(--nacht-2); }

/* focuskaart (mobiel) */
.focus { display: none; }
@media (max-width: 960px) { .focus { display: block; } .dossier .kaart.focus-dubbel { display: none; } }

/* ------------------------------------------------------------ dossier */

.dossier { display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.dossierkop { display: flex; align-items: baseline; justify-content: space-between; padding: 0 4px; }
.dossierkop h2 { font-family: var(--display); font-size: 24px; margin: 0; font-weight: 700; }
.dossierkop span { font-family: var(--typ); font-size: 13px; color: var(--zacht); }
.kaart {
  position: relative;
  background:
    repeating-linear-gradient(180deg, transparent 0 27px, rgba(80, 120, 170, .12) 27px 28px),
    var(--papier-2);
  color: var(--inkt);
  border-radius: 6px;
  padding: 12px 14px 12px 18px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, .35);
  border-left: 6px solid var(--k, var(--inkt));
  cursor: pointer;
  transition: transform .15s, box-shadow .15s;
}
.kaart:hover { transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0, 0, 0, .4); }
.kaart.gekozen { box-shadow: 0 0 0 3px var(--goud), 0 8px 22px rgba(0, 0, 0, .45); }
.kaart-kop { display: flex; align-items: center; gap: 12px; }
.kaart-kop .bol {
  width: 38px; height: 38px; border-radius: 50%; flex: none; display: grid; place-items: center;
  background: var(--k); color: #fff; font-family: var(--display); font-weight: 900; font-size: 19px;
  border: 2.5px solid #fffaf0; box-shadow: 0 2px 6px rgba(0, 0, 0, .3);
}
.kaart-kop h3 { margin: 0; font-family: var(--display); font-weight: 700; font-size: 17px; line-height: 1.15; }
.kaart-kop .rol { margin: 0; font-size: 12px; color: var(--inkt-zacht); font-family: var(--typ); }
.kaart-kop .plek {
  margin-left: auto; font-family: var(--typ); font-weight: 700; font-size: 13px;
  padding: 2px 8px; border-radius: 6px; background: rgba(34, 31, 26, .08); color: var(--inkt-zacht); white-space: nowrap;
}
.kaart-kop .plek.staat { background: var(--inkt); color: var(--papier); }
.verklaringen { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 4px; }
.verklaringen li {
  font-family: var(--typ); font-size: 15.5px; line-height: 1.4; padding: 3px 6px; margin: 0 -6px; border-radius: 6px;
  transition: background .12s;
}
.verklaringen li:hover, .verklaringen li.aan { background: rgba(212, 168, 67, .28); }
.verklaringen li::before { content: '„'; color: var(--inkt-zacht); }
.verklaringen li::after { content: '”'; color: var(--inkt-zacht); }
.verklaringen li.zwijgt { color: var(--inkt-zacht); font-style: italic; }
.verklaringen li.zwijgt:hover { background: none; }
.kaart.slachtoffer {
  border-left-color: var(--rood);
  background:
    repeating-linear-gradient(180deg, transparent 0 27px, rgba(80, 120, 170, .12) 27px 28px),
    #efe6d3;
}
.kaart.slachtoffer .bol { background: radial-gradient(#fff, #e6dccb); color: var(--rood-donker); border: 2.5px dashed var(--inkt); }
.stempel {
  display: inline-block; margin-top: 10px; font-family: var(--typ); font-weight: 700; text-transform: uppercase; letter-spacing: .08em;
  color: var(--rood); border: 2.5px solid var(--rood); border-radius: 4px; padding: 2px 8px; transform: rotate(-2deg); font-size: 13px;
  opacity: .9;
}
.kaart.sporen { border-left-color: #2f7fb5; cursor: default; }
.kaart.sporen:hover { transform: none; }
.kaart.sporen .bol { background: #2f7fb5; font-size: 18px; }
.ref-persoon { font-weight: 700; white-space: nowrap; }
.ref-persoon .mini-fiche {
  display: inline-grid; place-items: center; width: 1.25em; height: 1.25em; border-radius: 50%; background: var(--k); color: #fff;
  font-style: normal; font-family: var(--display); font-weight: 900; font-size: .78em; margin-right: .25em; vertical-align: .08em;
  border: 1.5px solid #fffaf0; box-shadow: 0 1px 2px rgba(0, 0, 0, .3);
}
.ref-kamer {
  font-weight: 700; padding: 0 .3em; border-radius: 4px; background: var(--t); box-shadow: inset 0 0 0 1.5px rgba(34, 31, 26, .25);
  white-space: nowrap;
}
.ref-obj { font-weight: 700; white-space: nowrap; }
.ref-plek { font-weight: 700; text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; text-decoration-color: rgba(34, 31, 26, .35); }
.mini-icoon { width: 1.35em; height: 1.35em; vertical-align: -.35em; margin-right: .1em; }

/* beschuldigen */
.beschuldig {
  background: linear-gradient(180deg, #2a1416, #1d1214);
  border: 1px solid rgba(192, 57, 43, .45);
  border-radius: var(--radius);
  padding: 16px;
  box-shadow: 0 8px 26px rgba(0, 0, 0, .35);
}
.beschuldig h2 { font-family: var(--display); margin: 0 0 2px; font-size: 21px; display: flex; align-items: center; gap: 8px; }
.beschuldig p { margin: 0 0 12px; color: #d8c7c2; font-size: 13.5px; }
.verdachten-keuze { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 8px; }
.verdachten-keuze button {
  display: flex; align-items: center; gap: 8px; text-align: left; padding: 7px 9px; border-radius: 11px;
  border: 1px solid rgba(239, 231, 214, .14); background: rgba(0, 0, 0, .25); font-size: 13.5px; font-weight: 600; position: relative;
  min-height: 46px; line-height: 1.15;
}
.verdachten-keuze button:hover { border-color: rgba(239, 231, 214, .35); }
.verdachten-keuze .bol { width: 28px; height: 28px; border-radius: 50%; flex: none; display: grid; place-items: center; background: var(--k); font-family: var(--display); font-weight: 900; color: #fff; border: 2px solid #fffaf0; font-size: 14px; }
.verdachten-keuze button.mijn { border-color: var(--s); background: color-mix(in srgb, var(--s) 18%, transparent); box-shadow: 0 0 0 1px var(--s); }
.verdachten-keuze .stemmers { position: absolute; top: -6px; right: -4px; display: flex; gap: 2px; }
.verdachten-keuze .stemmers i { width: 18px; height: 18px; border-radius: 50%; background: var(--k); border: 2px solid #1d1214; font-style: normal; font-size: 10px; font-weight: 800; color: #14161c; display: grid; place-items: center; }
.stemstatus { margin-top: 10px; font-size: 13px; color: #d8c7c2; min-height: 1.2em; }

/* ------------------------------------------------------------ vensters */

.venster-achter {
  position: fixed; inset: 0; z-index: 60; background: rgba(8, 9, 12, .72); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px);
  display: grid; place-items: center; padding: 16px; animation: in .2s ease-out;
}
@keyframes in { from { opacity: 0; } }
.venster {
  width: min(560px, 100%); max-height: calc(100dvh - 32px); overflow: auto;
  background: var(--nacht-2); border: 1px solid var(--lijn-2); border-radius: 18px; padding: 22px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, .6); animation: omhoog .25s cubic-bezier(.2, 1.2, .4, 1);
}
@keyframes omhoog { from { transform: translateY(16px) scale(.98); opacity: 0; } }
.venster h2 { font-family: var(--display); margin: 0 0 8px; font-size: 26px; }
.venster .acties { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; margin-top: 18px; }
.venster .sluit { float: right; margin: -6px -6px 0 8px; background: none; border: none; color: var(--zacht); font-size: 26px; line-height: 1; padding: 4px 8px; }
.uitnodig-code { font-family: var(--typ); font-size: 46px; letter-spacing: .25em; text-align: center; font-weight: 700; color: var(--goud); margin: 8px 0; padding-left: .25em; }
.linkveld { display: flex; gap: 8px; margin-top: 10px; }
.linkveld input { flex: 1; min-width: 0; font-family: var(--typ); font-size: 14px; }

.uitslag { text-align: center; position: relative; overflow: hidden; }
.uitslag .grote-stempel {
  display: inline-block; font-family: var(--typ); font-weight: 700; font-size: clamp(28px, 7vw, 40px); letter-spacing: .08em; text-transform: uppercase;
  color: var(--rood-licht); border: 5px solid var(--rood-licht); border-radius: 8px; padding: 6px 18px; transform: rotate(-6deg);
  margin: 12px 0 18px; animation: stempel .45s cubic-bezier(.2, 1.6, .4, 1) both .1s;
  mask-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='r'><feTurbulence baseFrequency='.9' numOctaves='2'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 -1.6 1.25'/></filter><rect width='120' height='120' filter='url(%23r)'/></svg>");
}
.uitslag.goed .grote-stempel { color: #5cc581; border-color: #5cc581; }
@keyframes stempel { from { transform: rotate(-6deg) scale(2.2); opacity: 0; } }
.uitslag .verhaal { font-family: var(--typ); font-size: 18px; line-height: 1.5; margin: 0 auto 16px; max-width: 26em; }
.uitslag .verhaal b { font-family: var(--display); }
.statrij { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin: 12px 0 6px; }
.stat { background: var(--nacht); border: 1px solid var(--lijn); border-radius: 12px; padding: 8px 14px; min-width: 92px; }
.stat b { display: block; font-family: var(--display); font-size: 22px; }
.stat small { color: var(--zacht); font-size: 12px; }
.uitslag .acties { justify-content: center; }
.moeilijkheid-keuze { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; margin-top: 14px; }

.dossierkast { list-style: none; padding: 0; margin: 12px 0 0; display: grid; gap: 6px; }
.dossierkast li { display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center; padding: 8px 10px; background: var(--nacht); border-radius: 10px; border: 1px solid var(--lijn); font-size: 14px; }
.dossierkast .uit { font-size: 18px; text-align: center; }
.dossierkast small { color: var(--zacht); display: block; font-size: 12px; }
.dossierkast .tijd { font-family: var(--typ); color: var(--zacht); }

.regels h3 { font-family: var(--display); font-size: 17px; margin: 18px 0 6px; }
.regels p, .regels li { color: #d9d1c0; font-size: 14.5px; }
.regels ul { padding-left: 18px; margin: 6px 0; }
.legenda { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 6px; margin: 8px 0; }
.legenda div { display: flex; align-items: center; gap: 8px; background: var(--papier); color: var(--inkt); border-radius: 8px; padding: 4px 8px; font-size: 13.5px; font-weight: 600; }
.legenda svg { width: 34px; height: 34px; flex: none; }
.legenda .nee { background: repeating-linear-gradient(45deg, var(--papier) 0 6px, #e6dcc6 6px 8px); }

.menu-lijst { display: grid; gap: 6px; }
.menu-lijst button { text-align: left; background: var(--nacht); border: 1px solid var(--lijn); border-radius: 12px; padding: 12px 14px; display: flex; gap: 12px; align-items: center; font-weight: 600; }
.menu-lijst button:hover { border-color: var(--lijn-2); }
.menu-lijst button small { display: block; color: var(--zacht); font-weight: 400; font-size: 12.5px; }
.menu-lijst svg { width: 20px; height: 20px; flex: none; color: var(--goud); }

/* bezig */
.bezig-scherm { position: fixed; inset: 0; z-index: 70; display: grid; place-items: center; background: rgba(8, 9, 12, .8); backdrop-filter: blur(5px); -webkit-backdrop-filter: blur(5px); }
.bezig-scherm .doos { text-align: center; font-family: var(--typ); font-size: 17px; }
.vergrootglas { width: 72px; height: 72px; margin: 0 auto 14px; animation: zoek 1.6s ease-in-out infinite; }
@keyframes zoek { 0%, 100% { transform: translate(-10px, 0) rotate(-8deg); } 50% { transform: translate(10px, -6px) rotate(8deg); } }

/* meldingen */
#meldingen { position: fixed; left: 50%; bottom: max(18px, env(safe-area-inset-bottom)); transform: translateX(-50%); z-index: 80; display: grid; gap: 8px; width: min(440px, calc(100% - 32px)); pointer-events: none; }
.melding {
  background: var(--papier); color: var(--inkt); border-radius: 12px; padding: 10px 14px; box-shadow: var(--schaduw);
  font-size: 14px; font-weight: 500; border-left: 5px solid var(--k, var(--goud)); animation: omhoog .25s ease-out;
}
.melding.weg { animation: weg .3s ease-in forwards; }
@keyframes weg { to { opacity: 0; transform: translateY(8px); } }
#emojis { position: fixed; inset: 0; pointer-events: none; z-index: 75; overflow: hidden; }
.zwevend { position: absolute; bottom: -60px; font-size: 42px; animation: zweef 2.6s ease-out forwards; text-align: center; }
.zwevend small { display: block; font-size: 12px; font-weight: 700; color: #14161c; background: var(--k); border-radius: 999px; padding: 1px 8px; margin-top: 2px; }
@keyframes zweef { 0% { transform: translateY(0) scale(.6); opacity: 0; } 15% { opacity: 1; transform: translateY(-120px) scale(1.1); } 100% { transform: translateY(-62vh) scale(1); opacity: 0; } }
.emojibalk { display: flex; gap: 2px; }
.emojibalk button { border: none; background: transparent; font-size: 20px; padding: 4px 6px; border-radius: 8px; line-height: 1; }
.emojibalk button:hover { background: var(--nacht-3); }
.confetti { position: fixed; top: -12px; width: 9px; height: 14px; z-index: 65; pointer-events: none; animation: val linear forwards; }
@keyframes val { to { transform: translateY(105vh) rotate(720deg); } }

.afgesloten-balk {
  display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap;
  background: var(--nacht-2); border: 1px solid var(--lijn-2); border-radius: 14px; padding: 10px 14px;
}
.afgesloten-balk b { font-family: var(--display); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition: none !important; }
}

/* ------------------------------------------------------------ aanvullingen voor de app */

#afgesloten:empty, #beschuldig-slot:empty, #focus:empty { display: none; }
#bord .klik:hover { fill: rgba(34, 31, 26, .06); }
#bord .klik.geblokt:hover { fill: transparent; }
.modus button:disabled, .vfiche:disabled { opacity: .55; cursor: default; }
.venster .klein { color: var(--zacht); font-size: 14px; margin: 0 0 10px; }
.venster > h3 { font-size: 12px; text-transform: uppercase; letter-spacing: .12em; color: var(--zacht); margin: 18px 0 10px; font-weight: 600; }
.kaart.slachtoffer .verklaringen li::before, .kaart.slachtoffer .verklaringen li::after,
.kaart.sporen .verklaringen li::before, .kaart.sporen .verklaringen li::after { content: none; }
.focus .kaart { cursor: default; }
.focus .kaart:hover { transform: none; }
@media (max-width: 640px) {
  .kop .knop.rond { width: 36px; height: 36px; }
  .spelers .speler-bol { width: 28px; height: 28px; font-size: 12px; }
}
.beschuldig h2 svg { width: 22px; height: 22px; flex: none; color: var(--rood-licht); }

/* openingsverhaal */
.intro .intro-kop { font-family: var(--typ); text-transform: uppercase; letter-spacing: .14em; font-size: 12px; color: var(--goud); margin: 0 0 4px; }
.intro-tekst p { font-family: var(--typ); font-size: 16.5px; line-height: 1.55; color: #e6dccb; margin: 0 0 12px; }
.intro-tekst p:last-child { color: var(--tekst); font-weight: 700; }
.intro-personen { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 14px; font-size: 14px; color: #d9d1c0; }
.kaart.verhaal { border-left-color: var(--goud); cursor: default; }
.kaart.verhaal:hover { transform: none; }
.kaart.verhaal summary { list-style: none; cursor: pointer; }
.kaart.verhaal summary::-webkit-details-marker { display: none; }
.kaart.verhaal summary::after { content: '▾'; margin-left: auto; color: var(--inkt-zacht); transition: transform .15s; }
.kaart.verhaal:not([open]) summary::after { transform: rotate(-90deg); }
.kaart.verhaal .bol { background: var(--goud); font-size: 18px; }
.verhaal-tekst p { font-family: var(--typ); font-size: 14.5px; line-height: 1.5; margin: 10px 0 0; }

/* mobiel: niets mag de pagina breder maken dan het scherm */
.start-raster > *, .spel > * { min-width: 0; }
.veld .invoer { width: 0; }

/* portretten in de rondjes; de letter in het hoekje is dezelfde als op het bord */
.bol.met-portret { position: relative; overflow: visible; }
.bol.met-portret .gezicht { position: absolute; inset: 0; border-radius: 50%; overflow: hidden; }
.portret { width: 100%; height: 100%; display: block; }
.bol.met-portret .letter {
  position: absolute; right: -5px; bottom: -3px; min-width: 18px; height: 18px; padding: 0 3px; border-radius: 9px;
  background: var(--k); color: #fff; font: 900 10.5px/15px var(--display); text-align: center; border: 1.5px solid #fffaf0;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .35);
}
.kaart.slachtoffer .bol.met-portret, .vfiche.slachtoffer .bol.met-portret { background: #f4efe4; }
.kaart.slachtoffer .bol.met-portret .letter, .vfiche.slachtoffer .bol.met-portret .letter { background: #f4efe4; color: var(--rood-donker); }
.kaart-kop .bol.met-portret { width: 46px; height: 46px; }
.vfiche .bol.met-portret { width: 44px; height: 44px; }
.vfiche.geplaatst .bol.met-portret::after { top: -5px; right: -7px; z-index: 1; }
.intro-personen { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px 12px; }
.intro-persoon { display: flex; align-items: center; gap: 10px; line-height: 1.2; font-weight: 600; color: var(--tekst); }
.intro-persoon small { display: block; font-weight: 400; color: var(--zacht); font-size: 12px; }
.intro-persoon .bol { width: 42px; height: 42px; border-radius: 50%; flex: none; background: var(--k); border: 2.5px solid #fffaf0; display: grid; place-items: center; }
.dader-portret { display: flex; justify-content: center; margin-top: 4px; }
.dader-portret .bol { width: 96px; height: 96px; border-radius: 50%; background: var(--k); border: 4px solid #fffaf0; box-shadow: 0 8px 24px rgba(0, 0, 0, .5); }
.verdachten-keuze .bol.met-portret { width: 32px; height: 32px; }

/* hint met uitleg */
.uitleg-lijst { list-style: none; margin: 4px 0 14px; padding: 0; display: grid; gap: 8px; }
.uitleg-lijst li {
  display: flex; align-items: center; gap: 10px; background: var(--papier-2); color: var(--inkt); border-radius: 8px;
  padding: 8px 10px; font-family: var(--typ); font-size: 15px; line-height: 1.35;
}
.uitleg-lijst .bol { width: 32px; height: 32px; border-radius: 50%; flex: none; background: var(--k); border: 2px solid #fffaf0; display: grid; place-items: center; }
.uitleg-lijst .bol.spoor { background: #2f7fb5; font-size: 15px; }

/* delen */
.kop .nodig-uit { height: 40px; }
@media (max-width: 640px) { .kop .nodig-uit { width: 36px; height: 36px; padding: 0; } .kop .nodig-uit .lang { display: none; } }
.deel-raster { display: grid; grid-template-columns: 168px 1fr; gap: 18px; align-items: center; margin: 6px 0 4px; }
@media (max-width: 480px) { .deel-raster { grid-template-columns: 1fr; justify-items: center; } }
.qr { width: 168px; height: 168px; background: #fff; border-radius: 12px; padding: 6px; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }
.qr svg { width: 100%; height: 100%; display: block; }
.deel-rechts { min-width: 0; display: grid; gap: 12px; }
.deel-rechts .uitnodig-code { margin: 0; font-size: 38px; text-align: left; }
@media (max-width: 480px) { .deel-rechts .uitnodig-code { text-align: center; } }
.deel-knoppen { display: flex; flex-wrap: wrap; gap: 8px; }
.knop.deel-wa { background: #1f9d55; border-color: transparent; color: #fff; text-decoration: none; }
.knop.deel-wa:hover { background: #23b061; }
.samen-kaart {
  display: flex; align-items: center; gap: 12px; position: relative;
  background: linear-gradient(180deg, #1d2a22, #18221c); border: 1px solid rgba(81, 207, 102, .35); border-radius: var(--radius);
  padding: 12px 34px 12px 14px;
}
.samen-kaart p { margin: 0; font-size: 13.5px; color: #cfe3d4; flex: 1; }
.samen-kaart .samen-icoon { flex: none; width: 36px; height: 36px; border-radius: 50%; background: rgba(81, 207, 102, .18); display: grid; place-items: center; color: #8ce99a; }
.samen-kaart .samen-icoon svg { width: 20px; height: 20px; }
.samen-weg { position: absolute; top: 4px; right: 6px; background: none; border: none; color: var(--zacht); font-size: 20px; line-height: 1; padding: 4px; }
#samen-kaart:empty { display: none; }

/* uitdagen */
.paneel.uitdaging { max-width: 560px; text-align: center; margin-top: 8px; }
.uitdaging-icoon { width: 56px; height: 56px; margin: 0 auto 10px; border-radius: 50%; display: grid; place-items: center; background: rgba(212, 168, 67, .16); color: var(--goud); }
.uitdaging-icoon svg { width: 30px; height: 30px; }
.paneel.uitdaging h2 { font-size: 28px; }
.uitdaging-zaak { font-family: var(--typ); color: var(--goud); margin: 4px 0 12px; }
.paneel.uitdaging .uitleg { font-size: 15.5px; color: #d9d1c0; }
.paneel.uitdaging #wie { text-align: left; margin: 14px 0; }
.uitdaging-knoppen { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 16px; }
.uitdaging-knoppen a.knop { text-decoration: none; color: inherit; }
.vergelijk { font-size: 14.5px; color: #d9d1c0; margin: 8px 0 0; }
.afgesloten-balk .knop svg { width: 16px; height: 16px; }
.uitleg-lijst .wie { display: block; font-family: var(--ui); font-size: 11.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--inkt-zacht); margin-bottom: 1px; }
.paneel.uitdaging { margin: 24px auto 0; }
.start:has(.uitdaging) .logo { justify-content: center; }
