/* KB DISC Groep — zelfde familie als de uitslagpagina (.kb-uitslag) van kleur-bekennen.nl */

.kbg {
	--kbg-d: #d64545;
	--kbg-i: #f2b134;
	--kbg-s: #4faf7c;
	--kbg-c: #4a78c9;
	--kbg-tekst: #1f2937;
	--kbg-zacht: #5f6b7a;
	--kbg-rand: #e7eaf0;
	--kbg-bg: #f8fbff;
	--kbg-schaduw: 0 18px 50px rgba(28, 42, 64, 0.10);
	--kbg-regenboog: linear-gradient(90deg, var(--kbg-d), var(--kbg-i), var(--kbg-s), var(--kbg-c));
	color: var(--kbg-tekst);
	max-width: 1080px;
	margin: 0 auto;
	display: grid;
	gap: 20px;
	box-sizing: border-box;
}

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

.kbg [hidden] { display: none !important; }

.kbg h2 { margin: 0 0 8px; font-size: clamp(1.6rem, 3vw, 2.2rem); line-height: 1.1; font-weight: 900; letter-spacing: -0.03em; }
.kbg h3 { margin: 0 0 14px; font-size: 1.2rem; font-weight: 800; }
.kbg h4 { margin: 0 0 8px; font-size: .95rem; font-weight: 800; color: var(--kbg-zacht); text-transform: uppercase; letter-spacing: .04em; }
.kbg p { margin: 0 0 12px; line-height: 1.7; }

.kbg-kaart {
	position: relative;
	padding: 28px;
	border: 1px solid var(--kbg-rand);
	border-radius: 24px;
	background: #fff;
	box-shadow: 0 8px 24px rgba(27, 39, 51, .05);
}

.kbg-maak,
.kbg-kop { box-shadow: var(--kbg-schaduw); }

.kbg-maak::before,
.kbg-kop::before {
	content: "";
	position: absolute;
	inset: 0 0 auto 0;
	height: 6px;
	border-radius: 24px 24px 0 0;
	background: var(--kbg-regenboog);
}

.kbg-badge {
	display: inline-block;
	margin-bottom: 12px;
	padding: 7px 14px;
	border: 1px solid var(--kbg-rand);
	border-radius: 999px;
	background: #fff;
	font-size: .85rem;
	font-weight: 800;
	color: var(--kbg-zacht);
}

.kbg-intro { color: var(--kbg-zacht); font-size: 1.05rem; max-width: 640px; }
.kbg-klein { font-size: .88rem; color: var(--kbg-zacht); margin: 12px 0 0; }

/* Meldingen */
.kbg-melding { padding: 14px 18px; border-radius: 16px; border: 1px solid var(--kbg-rand); background: var(--kbg-bg); line-height: 1.6; }
.kbg-melding.is-goed { border-color: rgba(79, 175, 124, .4); background: rgba(79, 175, 124, .08); }
.kbg-melding.is-fout { border-color: rgba(214, 69, 69, .4); background: rgba(214, 69, 69, .07); }

/* Formulieren */
.kbg-velden { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 20px 0 16px; }
.kbg-veld { display: grid; gap: 6px; font-weight: 700; }
.kbg-veld em { font-style: normal; font-weight: 500; color: var(--kbg-zacht); }
.kbg-veld small { font-weight: 500; color: var(--kbg-zacht); }
.kbg-breed { grid-column: 1 / -1; }
.kbg input[type="text"],
.kbg input[type="email"],
.kbg input[type="number"],
.kbg select {
	width: 100%;
	min-height: 50px;
	padding: 12px 14px;
	border: 1px solid #d6dce5;
	border-radius: 14px;
	background: #fff;
	font: inherit;
	color: var(--kbg-tekst);
}
.kbg input:focus,
.kbg select:focus { outline: 3px solid rgba(74, 120, 201, .25); border-color: var(--kbg-c); }
.kbg-vink { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 20px; font-weight: 600; cursor: pointer; }
.kbg-vink input { margin-top: 4px; width: 18px; height: 18px; }
.kbg-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }

.kbg-mee { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.kbg-mee h2 { font-size: 1.35rem; }
.kbg-mee p { margin: 0; color: var(--kbg-zacht); }
.kbg-mee .kbg-kopieer { flex: 1 1 320px; max-width: 460px; margin: 0; }
.kbg-mee input { text-transform: uppercase; letter-spacing: .08em; font-weight: 800; }

/* Knoppen */
.kbg-knop {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 52px;
	padding: 12px 22px;
	border: 0;
	border-radius: 16px;
	background: linear-gradient(135deg, var(--kbg-d), var(--kbg-i) 28%, var(--kbg-s) 67%, var(--kbg-c));
	color: #fff !important;
	font: inherit;
	font-weight: 800;
	text-decoration: none !important;
	cursor: pointer;
	box-shadow: 0 12px 22px rgba(74, 120, 201, .18);
	transition: transform .15s ease, box-shadow .15s ease;
}
.kbg-knop:hover { transform: translateY(-1px); box-shadow: 0 16px 26px rgba(74, 120, 201, .24); }
.kbg-knop-licht { background: #fff; color: var(--kbg-tekst) !important; border: 1px solid var(--kbg-rand); box-shadow: none; }
.kbg-knop-licht:hover { box-shadow: 0 6px 16px rgba(27, 39, 51, .08); }
.kbg-knop-tekst { background: none; color: var(--kbg-zacht) !important; box-shadow: none; text-decoration: underline !important; padding-inline: 8px; }
.kbg-knop-tekst:hover { box-shadow: none; color: var(--kbg-d) !important; }
.kbg-knop-rood { background: var(--kbg-d); box-shadow: none; min-height: 44px; }

/* Beheer */
.kbg-kop { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.kbg-kop h2 { margin: 0; }
.kbg-status { padding: 8px 16px; border-radius: 999px; font-weight: 800; font-size: .9rem; }
.kbg-status.is-open { background: rgba(79, 175, 124, .14); color: #2c7a52; }
.kbg-status.is-dicht { background: #eef1f5; color: var(--kbg-zacht); }

.kbg-raster { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 20px; }

.kbg-delen { text-align: center; display: grid; justify-items: center; align-content: start; gap: 12px; }
.kbg-delen h3 { margin: 0; }
.kbg-qr { width: 200px; max-width: 100%; aspect-ratio: 1; border-radius: 16px; overflow: hidden; border: 1px solid var(--kbg-rand); background: #fff; }
.kbg-qr svg { display: block; width: 100%; height: 100%; }
.kbg-code-regel { margin: 0; color: var(--kbg-zacht); }
.kbg-code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 1.15em; letter-spacing: .06em; color: var(--kbg-tekst); }
.kbg-kopieer { display: flex; gap: 8px; width: 100%; margin: 4px 0; }
.kbg-kopieer input { flex: 1; min-width: 0; font-size: .9rem; color: var(--kbg-zacht); }
.kbg-kopieer .kbg-knop { white-space: nowrap; min-height: 50px; padding-inline: 16px; }

.kbg-live { display: grid; gap: 18px; align-content: start; }
.kbg-teller { display: flex; align-items: baseline; gap: 10px; }
.kbg-teller span { font-size: clamp(2.6rem, 6vw, 3.6rem); font-weight: 900; line-height: 1; letter-spacing: -0.04em; }
.kbg-teller small { font-size: 1.05rem; font-weight: 700; color: var(--kbg-zacht); }

.kbg-ring-wrap { position: relative; display: grid; place-items: center; }
.kbg-ring { width: 220px; height: 220px; max-width: 100%; }
.kbg-ring-basis { fill: none; stroke: #eef1f5; stroke-width: 16; }
.kbg-ring-deel { fill: none; stroke-width: 16; transition: stroke-dasharray .6s ease, stroke-dashoffset .6s ease; }
.kbg-wacht { position: absolute; max-width: 150px; text-align: center; font-size: .85rem; color: var(--kbg-zacht); margin: 0; }

.kbg-legenda { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kbg-leg { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--kbg-rand); border-radius: 14px; }
.kbg-leg-stip { width: 14px; height: 14px; border-radius: 50%; flex: none; }
.kbg-leg-naam { flex: 1; font-weight: 800; }
.kbg-leg-naam small { font-weight: 500; color: var(--kbg-zacht); }
.kbg-leg-aantal { font-variant-numeric: tabular-nums; }
.kbg-leg-d .kbg-leg-stip { background: var(--kbg-d); }
.kbg-leg-i .kbg-leg-stip { background: var(--kbg-i); }
.kbg-leg-s .kbg-leg-stip { background: var(--kbg-s); }
.kbg-leg-c .kbg-leg-stip { background: var(--kbg-c); }

.kbg-profiel h3 { font-size: 1.5rem; font-weight: 900; }
.kbg-profiel-kolommen { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; margin-bottom: 20px; }
.kbg-profiel ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.kbg-profiel li { padding-left: 14px; border-left: 4px solid var(--kbg-rand); line-height: 1.6; }
.kbg-pk-d { border-left-color: var(--kbg-d) !important; }
.kbg-pk-i { border-left-color: var(--kbg-i) !important; }
.kbg-pk-s { border-left-color: var(--kbg-s) !important; }
.kbg-pk-c { border-left-color: var(--kbg-c) !important; }

.kbg-balken { display: grid; gap: 10px; }
.kbg-balk { display: grid; grid-template-columns: 70px 1fr 48px; align-items: center; gap: 12px; font-weight: 700; }
.kbg-balk-spoor { height: 12px; border-radius: 999px; background: #eef1f5; overflow: hidden; }
.kbg-balk-vul { display: block; height: 100%; border-radius: 999px; transition: width .6s ease; }
.kbg-balk-pct { text-align: right; font-variant-numeric: tabular-nums; }
.kbg-balk-d .kbg-balk-vul { background: var(--kbg-d); }
.kbg-balk-i .kbg-balk-vul { background: var(--kbg-i); }
.kbg-balk-s .kbg-balk-vul { background: var(--kbg-s); }
.kbg-balk-c .kbg-balk-vul { background: var(--kbg-c); }

.kbg-knoppen { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 16px; }
.kbg-weg { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 10px; font-weight: 600; }

/* Deelnemer: melding boven de test en blok na de uitslag */
.kbg-deelnemer,
.kbg-na {
	display: flex;
	align-items: center;
	gap: 14px;
	margin: 0 0 20px;
	padding: 16px 20px;
	border: 1px solid var(--kbg-rand, #e7eaf0);
	border-radius: 18px;
	background: #f8fbff;
	color: #1f2937;
}
.kbg-deelnemer strong,
.kbg-na strong { display: block; font-weight: 800; }
.kbg-deelnemer span,
.kbg-na span { display: block; color: #5f6b7a; font-size: .95rem; line-height: 1.5; }
.kbg-deelnemer-stip { flex: none; width: 34px; height: 34px; border-radius: 50%; background: conic-gradient(#d64545 0 25%, #f2b134 0 50%, #4faf7c 0 75%, #4a78c9 0); }
.kbg-deelnemer.is-dicht { background: #f4f6f9; }
.kbg-na { justify-content: space-between; flex-wrap: wrap; margin: 24px 0 0; }
.kbg-na .kbg-knop { display: inline-flex; align-items: center; min-height: 48px; padding: 10px 18px; border: 1px solid #e7eaf0; border-radius: 14px; background: #fff; color: #1f2937 !important; font-weight: 800; text-decoration: none !important; }

/* Uitleg-tooltips */
.kbg-tip { position: relative; display: inline-flex; vertical-align: middle; margin-left: 4px; text-transform: none; letter-spacing: 0; font-weight: 500; }
.kbg-tip-knop,
.kbg-tip-knop:visited {
	display: inline-flex; align-items: center; justify-content: center;
	width: 20px; height: 20px; min-height: 0; min-width: 0; padding: 0; margin: 0;
	border: 1px solid #d6dce5 !important; border-radius: 50% !important;
	background: #fff !important; color: #5f6b7a !important;
	font: italic 700 12px/1 Georgia, serif !important;
	cursor: help; box-shadow: none !important; transform: none !important;
	text-decoration: none !important; transition: background .15s ease, color .15s ease, border-color .15s ease;
}
/* Het thema kleurt knoppen bij hover donkerblauw; hier vast dezelfde donkere tint als het uitlegballonnetje. */
.kbg-tip-knop:hover,
.kbg-tip-knop:focus,
.kbg-tip-knop:focus-visible,
.kbg-tip-knop:active,
.kbg-tip.is-open .kbg-tip-knop {
	background: #1f2937 !important; color: #fff !important; border-color: #1f2937 !important;
	box-shadow: none !important; transform: none !important; outline: none;
}
.kbg-tip-knop:focus-visible { box-shadow: 0 0 0 3px rgba(31, 41, 55, .18) !important; }
.kbg-tip-tekst {
	position: absolute; z-index: 30;
	bottom: calc(100% + 10px); left: -10px;
	width: max-content; max-width: min(280px, 78vw);
	padding: 10px 12px; border-radius: 12px;
	background: #1f2937; color: #fff;
	font-size: .86rem; font-weight: 500; font-style: normal; line-height: 1.5; text-align: left; white-space: normal;
	box-shadow: 0 12px 28px rgba(15, 23, 42, .22);
	opacity: 0; visibility: hidden; transform: translateY(4px);
	transition: opacity .15s ease, transform .15s ease, visibility .15s;
	pointer-events: none;
}
.kbg-tip-tekst::after { content: ""; position: absolute; top: 100%; left: var(--kbg-pijl, 16px); border: 6px solid transparent; border-top-color: #1f2937; }
.kbg-tip:hover .kbg-tip-tekst,
.kbg-tip:focus-within .kbg-tip-tekst,
.kbg-tip.is-open .kbg-tip-tekst { opacity: 1; visibility: visible; transform: none; }
.kbg-teller .kbg-tip { align-self: center; }

/* Beheerlink kwijt */
.kbg-kwijt { padding: 18px 28px; box-shadow: none; }
.kbg-kwijt summary { cursor: pointer; font-weight: 800; color: var(--kbg-zacht); }
.kbg-kwijt[open] summary { margin-bottom: 12px; color: var(--kbg-tekst); }
.kbg-kwijt p { color: var(--kbg-zacht); }

/* Toestemmingsvinkje in het testformulier (de site stijlt keuzes als kaartjes met een rode rand) */
.gform_wrapper .gfield.kbg-toestemming .gfield_checkbox .gchoice {
	display: flex !important;
	align-items: center;
	gap: 12px;
	padding: 16px 18px;
	border: 1px solid #e7eaf0;
	border-radius: 18px;
	background: #f8fbff;
}
.gform_wrapper .gfield.kbg-toestemming .gchoice input[type="checkbox"] {
	flex: none;
	width: 20px !important;
	height: 20px !important;
	margin: 0 !important;
	position: static !important;
	opacity: 1 !important;
	accent-color: #4a78c9;
	cursor: pointer;
}
.gform_wrapper .gfield.kbg-toestemming .gchoice label {
	display: block !important;
	width: auto !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	background: none !important;
	box-shadow: none !important;
	font-weight: 600;
	line-height: 1.5;
	cursor: pointer;
}

/* Presenteerstand */
.kbg-scherm-body { margin: 0; min-height: 100vh; background: radial-gradient(circle at top left, rgba(214, 69, 69, .08), transparent 25%), radial-gradient(circle at top right, rgba(242, 177, 52, .10), transparent 25%), radial-gradient(circle at bottom left, rgba(79, 175, 124, .10), transparent 25%), radial-gradient(circle at bottom right, rgba(74, 120, 201, .10), transparent 25%), #fff; font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.kbg-scherm { max-width: none; min-height: 100vh; padding: 3vh 4vw; align-content: start; }
.kbg-scherm-kop { display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.kbg-scherm-kop h1 { margin: 0; font-size: clamp(2rem, 4.5vw, 4rem); font-weight: 900; letter-spacing: -0.04em; line-height: 1.05; }
.kbg-scherm-raster { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); gap: 5vw; align-items: center; margin-top: 3vh; }
.kbg-scherm-links { text-align: center; display: grid; justify-items: center; gap: 1.5vh; }
.kbg-qr-groot { width: min(34vw, 52vh); border-radius: 24px; box-shadow: var(--kbg-schaduw); }
.kbg-scherm-stap { font-size: clamp(1.2rem, 2.2vw, 2rem); font-weight: 900; margin: 0; }
.kbg-scherm-of { font-size: clamp(1rem, 1.6vw, 1.4rem); color: var(--kbg-zacht); margin: 0; }
.kbg-scherm-rechts { display: grid; gap: 3vh; justify-items: center; }
.kbg-scherm .kbg-ring { width: min(40vw, 54vh); height: auto; }
.kbg-scherm .kbg-ring-basis,
.kbg-scherm .kbg-ring-deel { stroke-width: 14; }
.kbg-ring-midden { position: absolute; display: grid; justify-items: center; }
.kbg-ring-midden span { font-size: clamp(3rem, 8vw, 7rem); font-weight: 900; line-height: 1; letter-spacing: -0.05em; }
.kbg-ring-midden small { font-size: clamp(1rem, 1.6vw, 1.5rem); font-weight: 700; color: var(--kbg-zacht); }
.kbg-scherm .kbg-wacht { position: static; max-width: none; font-size: clamp(1rem, 1.6vw, 1.4rem); }
.kbg-scherm .kbg-legenda { width: 100%; max-width: 760px; font-size: clamp(1rem, 1.5vw, 1.35rem); }
.kbg-scherm-titel { margin: 0; font-size: clamp(1.4rem, 2.6vw, 2.4rem); font-weight: 900; letter-spacing: -0.03em; }

@media (max-width: 860px) {
	.kbg-raster,
	.kbg-scherm-raster,
	.kbg-profiel-kolommen { grid-template-columns: 1fr; }
	.kbg-qr-groot { width: min(70vw, 320px); }
	.kbg-scherm .kbg-ring { width: min(80vw, 360px); }
}

@media (max-width: 560px) {
	.kbg-kaart { padding: 20px; border-radius: 20px; }
	.kbg-velden,
	.kbg-legenda { grid-template-columns: 1fr; }
	.kbg-kopieer { flex-direction: column; }
}
