/* De site van TurnByTurn, in de kleuren van de app (app/.../ui/Thema.kt): fel blauw #2B5BFF,
   het oranje van de kubus #FF7A1A, nacht #151927 en de achtergrond #F4F5F8; 's avonds de donkere
   versie (licht blauw #9DB4FF, licht oranje #FFB27A). Licht en donker volgen het toestel
   (prefers-color-scheme), net als de app. De kubus heeft overal de standaardkleuren van de app
   (Instellingen.kt) op een donker lichaam, zoals het icoon. Geen lettertypen van buiten: de letters
   van het toestel. Geen style-attributen (CSP). Richtingen met logische eigenschappen (inline-start
   en inline-end), zodat dir="rtl" (ar, he) vanzelf goed staat. De kubus en het horloge op de
   beginpagina zijn svg en HTML van tools/site-build.py (aria-hidden); ze staan vast op ltr, net als
   de notatie (class="notatie"). */

:root {
  --achter: #f4f5f8;
  --vlak: #eceef4;
  --kaart: #ffffff;
  --rand: #dfe2ea;
  --lijn: #c6cad6;
  --tekst: #151927;
  --tekst-zacht: #454a5a;
  --blauw: #2b5bff;
  --blauw-tekst: #1f45d6;
  --blauw-vlak: #dde5ff;
  --oranje: #ff7a1a;
  --oranje-vlak: #ffe2cc;
  --knop: #2b5bff;
  --knop-tekst: #ffffff;
  --link: #1f45d6;
  --diep: #e6e9f0;
  --schaduw: 0 1px 2px rgba(21, 25, 39, .06), 0 10px 28px rgba(43, 91, 255, .10);
  --kubus-schaduw: rgba(21, 25, 39, .22);
  --zonder: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --achter: #0f121c;
    --vlak: #151927;
    --kaart: #1b2030;
    --rand: #2a2f3d;
    --lijn: #3a4152;
    --tekst: #e4e6ee;
    --tekst-zacht: #c4c8d6;
    --blauw: #9db4ff;
    --blauw-tekst: #9db4ff;
    --blauw-vlak: #1f3fb8;
    --oranje: #ffb27a;
    --oranje-vlak: #7a3500;
    --knop: #9db4ff;
    --knop-tekst: #00218c;
    --link: #9db4ff;
    --diep: #0b0d15;
    --schaduw: 0 1px 2px rgba(0, 0, 0, .35), 0 12px 32px rgba(0, 0, 0, .35);
    --kubus-schaduw: rgba(157, 180, 255, .12);
  }
}

[hidden] { display: none !important; }

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
html:lang(ko) { word-break: keep-all; }
html:lang(ja) h1, html:lang(ja) h2, html:lang(ja) h3 { word-break: auto-phrase; }

body {
  margin: 0;
  background: var(--achter);
  color: var(--tekst);
  font-family: var(--zonder);
  font-size: 1.0625rem;
  line-height: 1.6;
}

h1, h2, h3, .merk, .voet-merk {
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -.01em;
  text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 5.4vw, 3.3rem); margin: 0 0 .5em; letter-spacing: -.02em; }
h2 { font-size: clamp(1.55rem, 3.4vw, 2.1rem); margin: 0 0 .6em; }
h3 { font-size: 1.15rem; margin: 0 0 .4em; font-weight: 700; }
html:lang(th) h1, html:lang(th) h2, html:lang(ja) h1, html:lang(ko) h1 { text-wrap: wrap; }

p { margin: 0 0 1em; }
a { color: var(--link); text-decoration-color: var(--oranje); text-underline-offset: .15em; }
a:hover { text-decoration-thickness: 2px; }
a:focus-visible, summary:focus-visible, .knop:focus-visible {
  outline: 3px solid var(--oranje);
  outline-offset: 2px;
  border-radius: 4px;
}
abbr[title] { text-decoration: underline dotted; text-underline-offset: .2em; cursor: help; }
ul, ol { padding-inline-start: 1.3em; }
li { margin: .25em 0; }

/* De notatie (R, U', F2) loopt in elke taal van links naar rechts, ook in een Arabische zin. */
.notatie { direction: ltr; unicode-bidi: isolate; font-weight: 700; white-space: nowrap; }

.wrap { max-width: 72rem; margin: 0 auto; padding: 0 1rem; }
.smal { max-width: 46rem; }
.lead { font-size: 1.2rem; }
.klein { font-size: .875rem; color: var(--tekst-zacht); }

.overslaan {
  position: absolute; inset-inline-start: 1rem; top: -4rem;
  background: var(--knop); color: var(--knop-tekst); font-weight: 700;
  padding: .5rem 1rem; border-radius: 0 0 8px 8px; z-index: 10;
}
.overslaan:focus { top: 0; }

/* ---------------------------------------------------------------- kop */

.kop { border-bottom: 1px solid var(--rand); background: var(--achter); }
.kop-rij { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.25rem; padding-top: .75rem; padding-bottom: .75rem; }
.merk { display: inline-flex; align-items: center; gap: .55rem; color: var(--tekst); text-decoration: none; font-size: 1.35rem; }
.merk .logo { width: 38px; height: 38px; flex: none; border-radius: 50%; }
.menu { display: flex; flex-wrap: wrap; gap: .25rem 1rem; margin-inline-start: auto; }
.menu a { color: var(--tekst); text-decoration: none; padding: .25rem 0; border-bottom: 2px solid transparent; }
.menu a:hover, .menu a[aria-current] { border-bottom-color: var(--oranje); }

.taalkeuze { position: relative; }
.taalkeuze summary {
  list-style: none; cursor: pointer; padding: .3rem .7rem; border: 1px solid var(--lijn);
  border-radius: 999px; font-size: .95rem; white-space: nowrap;
}
.taalkeuze summary::-webkit-details-marker { display: none; }
.taalkeuze summary::after { content: " \25BE"; color: var(--tekst-zacht); }
.taalkeuze[open] summary { background: var(--vlak); }
.talen {
  position: absolute; inset-inline-end: 0; top: calc(100% + .4rem); z-index: 5;
  list-style: none; margin: 0; padding: .4rem; min-width: 15rem; max-height: 70vh; overflow: auto;
  background: var(--kaart); border: 1px solid var(--lijn); border-radius: 12px; box-shadow: var(--schaduw);
  columns: 2; column-gap: .25rem;
}
.talen li { margin: 0; break-inside: avoid; }
.talen a { display: block; padding: .3rem .55rem; border-radius: 8px; color: var(--tekst); text-decoration: none; }
.talen a:hover { background: var(--vlak); }
.talen a[aria-current] { background: var(--blauw-vlak); font-weight: 600; }

/* ---------------------------------------------------------------- beginpagina */

.held { padding: 3rem 0 3.5rem; }
.held h1 { color: var(--blauw-tekst); }
.held-rij { display: grid; gap: 2.5rem; align-items: center; }
.held-klein { color: var(--tekst-zacht); font-size: .95rem; }
.held-beeld { display: flex; justify-content: center; }

.knop {
  display: inline-block; background: var(--knop); color: var(--knop-tekst); text-decoration: none;
  padding: .75rem 1.3rem; border-radius: 999px; font-weight: 700;
}
.knop-stil { background: transparent; color: var(--blauw-tekst); border: 2px solid var(--blauw); }

.blok { padding: 3.25rem 0; }
.blok-zacht { background: var(--vlak); border-top: 1px solid var(--rand); border-bottom: 1px solid var(--rand); }
.blok-accent { background: #1e2230; color: #e4e6ee; }
.blok-accent h2 { color: #ffb27a; }
.blok-accent a { color: #fff; text-decoration-color: #ff7a1a; }

.kaarten { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); }
.kaart {
  background: var(--kaart); border: 1px solid var(--rand); border-radius: 16px; padding: 1.25rem 1.25rem .5rem;
}
.kaart h3 { color: var(--blauw-tekst); }
.kaart-vol { border-color: var(--oranje); border-width: 2px; }

.twee { display: grid; gap: 2rem; }
.twee-midden { align-items: center; }
.prijs { margin-top: 1.5rem; gap: 1rem; }

/* Opsommingen met een klein vakje ervoor, zoals een sticker van de kubus. */
.vinkjes { list-style: none; padding: 0; }
.vinkjes li { position: relative; padding-inline-start: 1.7rem; }
.vinkjes li::before {
  content: ""; position: absolute; inset-inline-start: .1rem; top: .45em;
  width: .75rem; height: .75rem; border-radius: 3px; background: var(--oranje);
  box-shadow: 0 0 0 2px #15161a;
}

/* De zeven stappen als genummerde vakjes. */
.stappen { list-style: none; padding: 0; margin: 0; counter-reset: stap; display: grid; gap: .55rem; }
.stappen li {
  counter-increment: stap; position: relative; margin: 0;
  background: var(--kaart); border: 1px solid var(--rand); border-radius: 12px;
  padding: .6rem .9rem; padding-inline-start: 3.4rem; font-weight: 600;
}
.stappen li::before {
  content: counter(stap); position: absolute; inset-inline-start: .7rem; top: 50%; transform: translateY(-50%);
  width: 2rem; height: 2rem; border-radius: 6px; display: grid; place-items: center;
  background: var(--knop); color: var(--knop-tekst); font-weight: 800;
}

.vraag { border-bottom: 1px solid var(--lijn); padding: .75rem 0; }
.vraag summary { cursor: pointer; font-weight: 700; font-size: 1.1rem; }
.vraag summary::marker { color: var(--oranje); }
.vraag .antwoord { padding-top: .5rem; }

@media (min-width: 52rem) {
  .held-rij { grid-template-columns: 1.15fr 1fr; }
  .twee { grid-template-columns: 1fr 1fr; }
}

/* ---------------------------------------------------------------- de kubus (aria-hidden)
   Zoals het icoon: vlakke vakjes met donkere lijnen ertussen. Op de beginpagina een gehusselde
   kubus met de pijl van de volgende draai en de draaien eronder; de huidige in oranje. */

.speler { display: flex; flex-direction: column; align-items: center; gap: 1.25rem; direction: ltr; }
.kubus { width: 18rem; max-width: 76vw; height: auto; filter: drop-shadow(0 12px 24px var(--kubus-schaduw)); }
.kubus .s-w { fill: #f5f5f2; }
.kubus .s-r { fill: #c8102e; }
.kubus .s-g { fill: #009b48; }
.kubus .s-y { fill: #ffd500; }
.kubus .s-o { fill: #ff6a00; }
.kubus .s-b { fill: #0046ad; }
.kubus .rooster { fill: none; stroke: #15161a; stroke-width: 1.8; stroke-linecap: round; }
.kubus .omtrek { fill: none; stroke: #15161a; stroke-width: 2.2; stroke-linejoin: round; stroke-linecap: round; }
.kubus .pijl-rand { fill: none; stroke: #15161a; stroke-width: 3.2; stroke-linecap: round; stroke-linejoin: round; }
.kubus .pijl { fill: none; stroke: #ff7a1a; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.kubus .pijlpunt { fill: #ff7a1a; stroke: #15161a; stroke-width: 1; stroke-linejoin: round; }
.zetten { display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem; margin: 0; padding: 0; list-style: none; }
.zetten li {
  margin: 0; min-width: 3.2rem; padding: .35rem .8rem; border-radius: 999px; text-align: center;
  border: 2px solid var(--blauw); color: var(--blauw-tekst); background: var(--kaart);
  font-weight: 800; font-size: 1.25rem; line-height: 1.3;
}
.zetten li.nu { background: #ff7a1a; border-color: #ff7a1a; color: #151927; }

/* ---------------------------------------------------------------- het horloge (aria-hidden)
   Zoals Volgende.kt in wear: zwart rond scherm, een kleine kubus met de pijl, de draai groot in
   het blauw van het horloge en hoe ver je bent. */

.horloge-plek { display: flex; justify-content: center; }
.horloge {
  direction: ltr; width: 17rem; max-width: 80vw; aspect-ratio: 1; border-radius: 50%; padding: .9rem;
  background: linear-gradient(145deg, #3b3f46, #15171b); box-shadow: var(--schaduw);
}
.wijzerplaat {
  position: relative; width: 100%; height: 100%; border-radius: 50%; background: #000; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .1rem;
}
.wijzerplaat .kubus { width: 46%; max-width: none; filter: none; }
.pols-zet { color: #9db4ff; font-weight: 900; font-size: 3rem; line-height: 1; }
.pols-stap { color: #c4c8d6; font-size: .85rem; }

/* ---------------------------------------------------------------- tekstpagina's */

.tekst { max-width: 46rem; padding: 2.5rem 0 3rem; }
.tekst h1 { color: var(--blauw-tekst); }
.tekst h2 { margin-top: 2rem; font-size: clamp(1.3rem, 2.6vw, 1.6rem); }
.bijgewerkt { color: var(--tekst-zacht); font-size: .95rem; }
.tekst ol > li { margin: .6em 0; }

.bronnen { padding-inline-start: 1.1em; }
.bronnen li { margin: .45em 0; overflow-wrap: anywhere; }

/* ---------------------------------------------------------------- voet */

.voet { border-top: 1px solid var(--rand); background: var(--diep); padding: 2.5rem 0 2rem; font-size: .95rem; }
.voet-rij { display: grid; gap: 1.5rem; }
.voet-merk { display: flex; align-items: center; gap: .5rem; font-size: 1.2rem; margin-bottom: .5rem; }
.voet-merk .logo { width: 29px; height: 29px; border-radius: 50%; }
.voet-kop { font-weight: 700; margin-bottom: .25rem; }
.impressum { line-height: 1.5; }
.voet-links { list-style: none; padding: 0; margin: 0; }
.voet-links a { color: var(--tekst); }
@media (min-width: 46rem) { .voet-rij { grid-template-columns: 2fr 1fr; } }

/* 404 */
.terug { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: .4rem 1rem; }

@media print {
  .kop, .voet, .taalkeuze, .overslaan { display: none; }
  body { background: #fff; color: #000; }
}
