/* ========================================
   VOLTUX — Cookietoestemming (2026-09-18)
   Melding als zwevende kaart linksonder (telefoon: onderaan over de volle
   breedte) en een voorkeurenvenster. HTML: includes/inc-cookies.php,
   gedrag: site/site-cookies.js. Alles begint met vc-.
   Alleen geladen als er een dienst aan staat (of ?cookies=test).
   ======================================== */

.vc-banner, .vc-overlay, .vc-banner *, .vc-overlay * { box-sizing: border-box; }
.vc-banner[hidden], .vc-overlay[hidden] { display: none !important; }

.vc-icoon { display: block; width: 20px; height: 20px; }

/* ── Melding ── */
.vc-banner {
    position: fixed; left: 24px; bottom: 24px; z-index: 9998;
    width: 400px; max-width: calc(100vw - 32px);
    padding: 22px 22px 16px;
    background: #ffffff; color: #0f172a;
    border-radius: 22px;
    box-shadow: 0 28px 70px -20px rgba(15, 23, 42, 0.38), 0 0 0 1px rgba(15, 23, 42, 0.06);
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    opacity: 0; transform: translateY(20px) scale(0.98);
    transition: opacity 0.35s ease, transform 0.45s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.vc-banner.toon { opacity: 1; transform: none; }

.vc-banner-kop { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.vc-badge {
    width: 40px; height: 40px; flex-shrink: 0; border-radius: 12px;
    display: grid; place-items: center;
    background: #E8F7F1; color: #0F6E56;
}
.vc-badge .vc-icoon { width: 22px; height: 22px; }

.vc-titel { margin: 0; font-size: 17px; line-height: 1.3; font-weight: 800; letter-spacing: -0.2px; color: #0f172a; }
.vc-tekst { margin: 0; font-size: 14px; line-height: 1.55; color: #475569; }
.vc-tekst a { color: #0F6E56; font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

.vc-knoppen { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.vc-knop {
    min-height: 46px; padding: 0 14px; border-radius: 12px; border: 0; cursor: pointer;
    font: inherit; font-size: 14.5px; font-weight: 700; line-height: 1.2;
    transition: background 0.15s, transform 0.1s;
}
.vc-knop:active { transform: scale(0.98); }
.vc-knop:focus-visible, .vc-link:focus-visible, .vc-sluit:focus-visible, .vc-footer-link:focus-visible,
.vc-cat summary:focus-visible { outline: 3px solid #6DD2B3; outline-offset: 2px; }
.vc-knop-donker { background: #0f172a; color: #ffffff; }
.vc-knop-donker:hover { background: #1e293b; }
.vc-knop-licht { background: #f1f5f9; color: #0f172a; }
.vc-knop-licht:hover { background: #e2e8f0; }

.vc-link {
    display: block; margin: 12px auto 0; padding: 4px 8px;
    background: none; border: 0; cursor: pointer; border-radius: 6px;
    font: inherit; font-size: 13.5px; font-weight: 600; color: #475569;
    text-decoration: underline; text-underline-offset: 3px;
}
.vc-link:hover { color: #0f172a; }

/* Link in de voettekst */
.vc-footer-link {
    background: none; border: 0; padding: 0; cursor: pointer;
    font: inherit; color: inherit; text-decoration: underline; text-underline-offset: 2px;
}

/* ── Voorkeurenvenster ── */
.vc-overlay {
    position: fixed; inset: 0; z-index: 9999;
    display: flex; align-items: center; justify-content: center; padding: 16px;
    background: rgba(15, 23, 42, 0.55);
    -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
    font-family: 'Inter', 'Segoe UI', system-ui, sans-serif;
    opacity: 0; transition: opacity 0.25s ease;
}
.vc-overlay.toon { opacity: 1; }
.vc-venster {
    width: 100%; max-width: 560px; max-height: min(86vh, 760px);
    display: flex; flex-direction: column;
    background: #ffffff; border-radius: 24px; overflow: hidden;
    box-shadow: 0 40px 90px -20px rgba(15, 23, 42, 0.5);
    transform: translateY(16px) scale(0.98); transition: transform 0.35s cubic-bezier(0.2, 0.8, 0.2, 1);
}
.vc-overlay.toon .vc-venster { transform: none; }

.vc-venster-kop { display: flex; align-items: flex-start; gap: 16px; padding: 24px 24px 16px; border-bottom: 1px solid #e2e8f0; }
.vc-venster-kop .vc-titel { font-size: 21px; margin-bottom: 6px; }
.vc-sluit {
    flex-shrink: 0; width: 40px; height: 40px; margin: -4px -6px 0 auto; border-radius: 50%;
    display: grid; place-items: center; border: 0; cursor: pointer;
    background: #f1f5f9; color: #334155;
}
.vc-sluit:hover { background: #e2e8f0; }

.vc-venster-inhoud { overflow-y: auto; padding: 16px 24px; display: grid; gap: 12px; overscroll-behavior: contain; }
.vc-cat { border: 1px solid #e2e8f0; border-radius: 16px; padding: 16px 18px; }
.vc-cat-kop { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.vc-cat h3 { margin: 0; font-size: 15.5px; font-weight: 700; color: #0f172a; }
.vc-cat p { margin: 6px 0 0; font-size: 13.5px; line-height: 1.5; color: #475569; }
.vc-altijd { padding: 4px 10px; border-radius: 999px; background: #E8F7F1; color: #0F6E56; font-size: 12px; font-weight: 700; white-space: nowrap; }

.vc-cat details { margin-top: 10px; }
.vc-cat summary {
    display: inline-flex; align-items: center; gap: 4px; cursor: pointer; list-style: none; border-radius: 6px;
    font-size: 13px; font-weight: 600; color: #0F6E56;
}
.vc-cat summary::-webkit-details-marker { display: none; }
.vc-cat summary .vc-icoon { width: 16px; height: 16px; transition: transform 0.2s; }
.vc-cat details[open] summary .vc-icoon { transform: rotate(180deg); }
.vc-diensten { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 8px; }
.vc-diensten li { padding: 10px 12px; border-radius: 10px; background: #f8fafc; font-size: 13px; color: #334155; }
.vc-diensten li span { color: #64748b; }
.vc-diensten li small { display: block; margin-top: 2px; font-size: 12.5px; line-height: 1.45; color: #64748b; }

/* Schakelaar */
.vc-schakel { position: relative; flex-shrink: 0; cursor: pointer; }
.vc-schakel input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.vc-schakel-knop {
    display: block; position: relative; width: 46px; height: 28px; border-radius: 999px;
    background: #cbd5e1; transition: background 0.2s;
}
.vc-schakel-knop::after {
    content: ''; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%;
    background: #ffffff; box-shadow: 0 1px 3px rgba(15, 23, 42, 0.3);
    transition: transform 0.2s cubic-bezier(0.3, 1.3, 0.5, 1);
}
.vc-schakel input:checked + .vc-schakel-knop { background: #1D9E75; }
.vc-schakel input:checked + .vc-schakel-knop::after { transform: translateX(18px); }
.vc-schakel input:focus-visible + .vc-schakel-knop { outline: 3px solid #6DD2B3; outline-offset: 2px; }

.vc-venster-voet { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 16px 24px 20px; border-top: 1px solid #e2e8f0; }

/* ── Telefoon ── */
@media (max-width: 600px) {
    .vc-banner {
        left: 0; right: 0; bottom: 0; width: 100%; max-width: none;
        padding: 20px 16px calc(14px + env(safe-area-inset-bottom, 0px));
        border-radius: 22px 22px 0 0;
        transform: translateY(100%);
    }
    .vc-overlay { align-items: flex-end; padding: 0; }
    .vc-venster { max-width: none; max-height: 92vh; border-radius: 24px 24px 0 0; transform: translateY(40px); }
    .vc-venster-kop { padding: 20px 16px 14px; }
    .vc-venster-inhoud { padding: 14px 16px; }
    .vc-venster-voet { padding: 14px 16px calc(14px + env(safe-area-inset-bottom, 0px)); }
}

@media (prefers-reduced-motion: reduce) {
    .vc-banner, .vc-overlay, .vc-venster { transition: none !important; }
}
