/*
 * Kotra condoleanceregister. Alleen geladen op de registerpagina; alles onder .kcr
 * (plus enkele regels voor de vertaalwidget en de portretkolom via body.kcr-page).
 * Kleuren en maten volgen wp-content/DESIGN.md.
 */
.kcr {
	--kcr-teal: #009fa0;
	--kcr-teal-dark: #007f80;
	--kcr-navy: #02045e;
	--kcr-label: #103062;
	--kcr-text: #1e282e;
	--kcr-muted: #4c5a63;
	--kcr-light: #eaf4f9;
	--kcr-border: #d5d6de;
	--kcr-error: #b3123e;
	--kcr-radius-house: 0 55px 0 0;
	color: var(--kcr-text);
	max-width: 1170px;
	margin: 0 auto;
}

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

/* Taalbalk direct onder de titelbalk: taalkeuze + knop naar het formulier. */
.kcr-topbar {
	background: #fff;
	border-bottom: 1px solid #d5d6de;
}

.kcr .kcr-topbar__inner,
.kcr-topbar__inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 12px 24px;
	padding: 16px 15px;
}

.kcr .kcr-topbar__cta {
	padding: 10px 22px;
	font-size: 15px;
}

@media (max-width: 767px) {
	.kcr-topbar__inner {
		padding: 14px 16px;
	}

	.kcr .kcr-topbar__cta {
		width: 100%;
		justify-content: center;
	}
}

.kcr-lang {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 6px;
}

.kcr-lang__label {
	font-size: 15px;
	font-weight: 600;
	color: var(--kcr-label);
	margin-right: 6px;
}

.kcr .kcr-lang__opt {
	display: inline-block;
	padding: 6px 12px;
	border: 1px solid var(--kcr-border);
	border-radius: 3px;
	color: var(--kcr-navy);
	font-size: 15px;
	line-height: 1.3;
	text-decoration: none;
	background: #fff;
}

.kcr .kcr-lang__opt:hover {
	border-color: var(--kcr-teal);
	color: var(--kcr-teal);
}

.kcr .kcr-lang__opt[aria-pressed="true"] {
	background: var(--kcr-teal);
	border-color: var(--kcr-teal);
	color: #fff;
}

.kcr-translate-status {
	flex-basis: 100%;
	margin: 0;
	font-size: 15px;
	color: var(--kcr-muted);
}

.kcr-translate-status:empty {
	display: none;
}

/* Melding automatische vertaling, onderaan de taalbalk. */
.kcr-autonotice {
	flex-basis: 100%;
	background: var(--kcr-light);
	color: var(--kcr-text);
	font-size: 15px;
}

.kcr-autonotice p {
	margin: 0;
	padding: 10px 14px;
}

.kcr-autonotice__label {
	font-weight: 700;
	color: var(--kcr-navy);
}

.kcr-autonotice[hidden] {
	display: none;
}

.kcr-link-btn {
	background: none;
	border: 0;
	padding: 0;
	color: var(--kcr-teal-dark);
	text-decoration: underline;
	font: inherit;
	cursor: pointer;
}

/* Knoppen: bijna recht (3px), teal, iets omhoog bij hover zoals de CF7-knop. */
.kcr .kcr-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 14px 28px;
	border: 1px solid var(--kcr-teal);
	border-radius: 3px;
	font-family: inherit;
	font-size: 16px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	cursor: pointer;
	transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}

.kcr .kcr-btn--primary {
	background: var(--kcr-teal);
	color: #fff;
}

.kcr .kcr-btn--primary:hover,
.kcr .kcr-btn--primary:focus-visible {
	background: var(--kcr-teal-dark);
	color: #fff;
	transform: translateY(-2px);
	box-shadow: 0 6px 16px rgba(0, 159, 160, 0.25);
}

.kcr .kcr-btn--secondary {
	background: #fff;
	color: var(--kcr-teal-dark);
}

.kcr .kcr-btn--secondary:hover {
	background: var(--kcr-light);
}

.kcr .kcr-btn[disabled] {
	opacity: 0.6;
	cursor: progress;
	transform: none;
}

.kcr a:focus-visible,
.kcr button:focus-visible,
.kcr input:focus-visible,
.kcr select:focus-visible,
.kcr textarea:focus-visible,
.kcr-autonotice button:focus-visible,
.kcr-live a:focus-visible {
	outline: 3px solid var(--kcr-navy);
	outline-offset: 2px;
}

/* Secties */
.kcr-section {
	margin-bottom: 60px;
}

.kcr .kcr-section__title {
	font-size: 40px;
	line-height: 1.2;
	margin: 0 0 0.3em;
	color: var(--kcr-navy);
}

.kcr .kcr-section__title--small {
	font-size: 24px;
}

@media (max-width: 767px) {
	.kcr .kcr-section__title {
		font-size: 32px;
		line-height: 1;
	}

	.kcr .kcr-section__title--small {
		font-size: 22px;
	}
}

/* Formulier: lichtblauw blok met de Kotra-hoek rechtsboven. */
.kcr-form-section {
	background: var(--kcr-light);
	border-radius: var(--kcr-radius-house);
	padding: 45px 45px 40px;
}

@media (max-width: 767px) {
	.kcr-form-section {
		padding: 30px 18px;
		border-radius: 0 40px 0 0;
	}
}

.kcr-form {
	max-width: 760px;
}

.kcr-form[hidden] {
	display: none;
}

.kcr-field {
	margin-bottom: 22px;
}

.kcr-field[hidden] {
	display: none;
}

.kcr-field label {
	display: block;
	font-weight: 600;
	color: var(--kcr-navy);
	margin-bottom: 2px;
}

.kcr-req {
	color: var(--kcr-teal-dark);
}

.kcr-help {
	margin: 0 0 6px;
	font-size: 15px;
	color: var(--kcr-muted);
}

.kcr input[type="text"],
.kcr input[type="email"],
.kcr select,
.kcr textarea {
	width: 100%;
	padding: 1em 2em;
	border: 1px solid var(--kcr-border);
	border-radius: 2px;
	background: #fff;
	color: var(--kcr-text);
	font-family: inherit;
	font-size: 17px;
	line-height: 1.47;
}

/* Native keuzelijst (class "select" sluit Hub's jQuery UI-selectmenu uit): de browser
   toont een scrollbare lijst, op mobiel de eigen picker. Pijl in de huisstijl. */
.kcr select {
	display: block;
	border-color: #ccc;
	padding-right: 3em;
	height: auto;
	-webkit-appearance: none;
	appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%2302045e' stroke-width='2'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 1.4em center;
	background-size: 12px 8px;
	cursor: pointer;
}

.kcr textarea {
	min-height: 180px;
	resize: vertical;
}

.kcr [aria-invalid="true"] {
	border-color: var(--kcr-error);
	box-shadow: 0 0 0 1px var(--kcr-error);
}

.kcr-error {
	margin: 6px 0 0;
	color: var(--kcr-error);
	font-size: 15px;
	font-weight: 600;
}

.kcr-error[hidden] {
	display: none;
}

.kcr-counter {
	margin: 4px 0 0;
	font-size: 14px;
	color: var(--kcr-muted);
	text-align: right;
}

/* Honeypot: buiten beeld, niet voor hulpmiddelen. */
.kcr-hp {
	position: absolute !important;
	left: -10000px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

.kcr-turnstile {
	margin-bottom: 16px;
}

.kcr-notice {
	font-size: 15px;
	line-height: 1.5;
	margin: 0 0 20px;
	max-width: 760px;
}

.kcr a {
	color: var(--kcr-teal-dark);
}

.kcr-alert {
	padding: 14px 18px;
	border-left: 4px solid var(--kcr-teal);
	background: #fff;
	margin: 0 0 20px;
}

.kcr-alert[hidden] {
	display: none;
}

.kcr-alert--error {
	border-left-color: var(--kcr-error);
	color: var(--kcr-error);
	font-weight: 600;
}

.kcr-alert--success {
	border-left-color: var(--kcr-teal);
	background: var(--kcr-light);
	color: var(--kcr-navy);
	font-weight: 600;
}

.kcr-alert:focus {
	outline: none;
}

.kcr-closed p {
	font-size: 19px;
}

/* Berichten */
.kcr-count {
	color: var(--kcr-muted);
	margin-bottom: 24px;
}

.kcr .kcr-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	gap: 20px;
}

.kcr .kcr-message {
	margin: 0;
	padding: 0;
}

.kcr-message::before {
	display: none !important;
}

.kcr-card {
	background: #fff;
	border: 1px solid var(--kcr-border);
	border-radius: 0 30px 0 0;
	padding: 24px 28px;
}

.kcr-message--new .kcr-card {
	border-color: var(--kcr-teal);
	box-shadow: 0 0 0 1px var(--kcr-teal);
}

.kcr-card__header {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	justify-content: space-between;
	gap: 4px 16px;
	margin-bottom: 10px;
}

.kcr .kcr-card__name {
	font-size: 20px;
	line-height: 1.3;
	font-weight: 700;
	margin: 0;
	color: var(--kcr-navy);
	overflow-wrap: anywhere;
}

.kcr .kcr-card__company {
	font-size: 16px;
	font-weight: 400;
	color: var(--kcr-muted);
}

/* De webfont (Overpass) geeft de middenstip nulbreedte: scheidingsteken in een systeemfont. */
.kcr .kcr-card__sep {
	font-family: Arial, Helvetica, sans-serif;
}

.kcr-card__meta {
	margin: 0;
	font-size: 14px;
	color: var(--kcr-muted);
}

.kcr-card__text {
	overflow-wrap: anywhere;
}

.kcr-card__text p {
	margin: 0 0 0.8em;
}

.kcr-card__text p:last-child {
	margin-bottom: 0;
}

.kcr-pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 12px 24px;
	align-items: center;
	margin-top: 28px;
}

.kcr-pagination[hidden] {
	display: none;
}

.kcr-more-wrap {
	margin-top: 28px;
	text-align: center;
}

.kcr-more-status:empty {
	display: none;
}

/* Uitvaartgegevens: kleine notities onder de herdenkingstekst (inner row .kcr-notes). */
.kcr-page .kcr-notes {
	position: relative;
	margin-top: 28px;
	padding-top: 18px;
	font-size: 15px;
	line-height: 1.45;
}

/* Lijn gelijk met de tekst: de inner row heeft -15px marge, de kolommen 15px padding. */
.kcr-page .kcr-notes::before {
	content: "";
	position: absolute;
	top: 0;
	left: 15px;
	right: 15px;
	border-top: 1px solid #d5d6de;
}

.kcr-page .kcr-notes h6 {
	font-size: 13px;
	letter-spacing: 0.02em;
}

.kcr-page .kcr-notes p {
	margin-bottom: 12px;
}

/* Livestream: compact, hoort bij de notities. */
.kcr-live {
	margin: 4px 0 0;
}

.kcr-live .kcr-btn {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 9px 18px;
	border-radius: 3px;
	background: #009fa0;
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	line-height: 1.3;
	text-decoration: none;
}

.kcr-live .kcr-btn:hover {
	background: #007f80;
	color: #fff;
}

.kcr-live__icon {
	flex: none;
	width: 14px;
	height: 14px;
}

/* Alleen voor schermlezers (standaardpatroon). */
.kcr-sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	clip-path: inset(50%);
	white-space: nowrap;
	border: 0;
}

.kcr-live__note {
	margin-top: 8px;
	font-size: 14px;
}

.kcr-live__pending {
	margin: 0;
	font-size: 14px;
	font-style: italic;
	color: #4c5a63;
}

/* Portret: niet bijsnijden op het gezicht; rechtsboven de Kotra-hoek. */
.kcr-page .kcr-portrait img {
	width: 100%;
	height: auto;
	object-fit: cover;
	object-position: center top;
	border-radius: 0 55px 0 0;
}

.kcr-page .kcr-portrait-placeholder {
	aspect-ratio: 4 / 5;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #eaf4f9;
	color: #103062;
	border-radius: 0 55px 0 0;
	text-align: center;
	padding: 20px;
}

/* Google Translate: geen balk, tooltip of verschoven body. */
.kcr-gt,
body > .skiptranslate,
iframe.goog-te-banner-frame,
#goog-gt-tt,
.goog-te-balloon-frame {
	display: none !important;
}

body.kcr-page {
	top: 0 !important;
}

.kcr-page font {
	background: transparent !important;
	box-shadow: none !important;
}

/* De titelbalk zet koppen in "capitalize"; voor een naam met tussenvoegsel ("de Koeijer") niet gewenst. */
.kcr-page .titlebar h1 {
	text-transform: none;
}

/* Portret: volledige foto, niet bijgesneden; optioneel zwart-wit (instelling in de metabox). */
.kcr-page .kcr-portrait .vc_single_image-wrapper,
.kcr-page .kcr-portrait .vc_single_image-img {
	display: block;
	width: 100%;
	max-width: 100%;
	height: auto;
}

/* De globale Custom CSS beperkt .vc_single_image-img tot 50%; voor het portret de volle kolom. */
.kcr-page .kcr-portrait img.vc_single_image-img {
	max-width: 100% !important;
}

.kcr-page .kcr-portrait .vc_single_image-wrapper {
	overflow: hidden;
	border-radius: 0 55px 0 0;
}

.kcr-portrait-gray .kcr-portrait img {
	filter: grayscale(1);
}

/* Introrij: portret op de volle halve breedte, herdenkingstekst verticaal in het midden. */
@media (min-width: 992px) {
	.kcr-page .kcr-intro-row .ld-row,
	.kcr-page .kcr-intro-row > .ld-container > .row {
		display: flex;
		align-items: center;
	}

	.kcr-page .kcr-memoir > .vc_column-inner {
		padding-left: 60px;
	}
}

.kcr-page .kcr-lifedates p,
.kcr-page p.kcr-lifedates {
	margin: 0 0 1.2em;
	color: #103062;
	font-size: 17px;
	font-weight: 600;
	letter-spacing: 0.01em;
}

/* Tekst boven het formulier en ondertekening van de families. */
.kcr-form-intro {
	max-width: 760px;
	margin-bottom: 8px;
}

.kcr-form-intro p {
	margin: 0 0 1em;
}

.kcr .kcr-signature {
	max-width: 760px;
	margin: 0 0 28px;
	color: var(--kcr-navy);
	font-style: italic;
	font-weight: 600;
}

.kcr .kcr-intro {
	font-size: 15px;
	color: var(--kcr-muted);
}

@media (max-width: 991px) {
	/* Gestapeld: ruimte tussen portret en "Ter nagedachtenis aan". */
	.kcr-page .kcr-memoir {
		margin-top: 36px;
	}
}

/* Een knop met [hidden] moet verborgen blijven ondanks display: inline-flex. */
.kcr .kcr-btn[hidden] {
	display: none;
}

/* Modal met het formulier (native <dialog>, staat in de top layer boven de Hub-header). */
html.kcr-modal-open {
	overflow: hidden;
}

/* Geen verspringende pagina onder de backdrop zodra de scrollbalk verdwijnt (op mobiel is de dialog fullscreen). */
@media (min-width: 601px) {
	html.kcr-modal-open {
		scrollbar-gutter: stable;
	}
}

.kcr .kcr-modal {
	width: min(720px, calc(100vw - 32px));
	max-width: none;
	max-height: 90dvh;
	margin: auto;
	padding: 0;
	overflow: auto;
	border: 0;
	border-radius: 0 40px 0 0;
	background: #fff;
	color: var(--kcr-text);
	/* Animatie: JS zet .is-open een frame na showModal() en haalt hem weg vóór close(). */
	opacity: 0;
	transform: translateY(24px) scale(0.98);
	transition: opacity 0.26s ease, transform 0.26s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.kcr .kcr-modal.is-open {
	opacity: 1;
	transform: none;
}

.kcr .kcr-modal::backdrop {
	background: rgb(0 0 0 / 70%);
	backdrop-filter: blur(3px);
	opacity: 0;
	transition: opacity 0.26s ease;
}

.kcr .kcr-modal.is-open::backdrop {
	opacity: 1;
}

@media (prefers-reduced-motion: reduce) {
	.kcr .kcr-modal,
	.kcr .kcr-modal::backdrop {
		transition: none;
	}
}

.kcr-modal__body {
	padding: 32px;
}

.kcr-modal__head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 8px;
}

.kcr .kcr-modal__title {
	margin: 0;
	font-size: 28px;
	line-height: 1.2;
	color: var(--kcr-navy);
}

.kcr .kcr-modal__close {
	flex: none;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 40px;
	height: 40px;
	margin: -6px -8px 0 0;
	padding: 0;
	border: 2px solid transparent;
	border-radius: 3px;
	background: transparent;
	color: var(--kcr-navy);
	cursor: pointer;
}

.kcr .kcr-modal__close:hover {
	background: var(--kcr-light);
}

.kcr .kcr-modal__close:focus-visible {
	outline: 3px solid var(--kcr-navy);
	outline-offset: 1px;
	background: var(--kcr-light);
	border-color: var(--kcr-teal);
}

.kcr .kcr-modal .kcr-intro {
	margin: 0 0 18px;
}

.kcr .kcr-modal .kcr-form {
	max-width: none;
}

/* Twee kolommen: naam | bedrijf en e-mailadres | nationaliteit. */
.kcr-form__grid {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 0 20px;
}

/* Compactere velden in de modal. */
.kcr .kcr-modal .kcr-field {
	margin-bottom: 14px;
}

.kcr .kcr-modal .kcr-field label {
	margin-bottom: 0;
}

.kcr .kcr-modal .kcr-help {
	margin: 0 0 4px;
	font-size: 14px;
}

.kcr .kcr-modal input[type="text"],
.kcr .kcr-modal input[type="email"],
.kcr .kcr-modal select,
.kcr .kcr-modal textarea {
	padding: 0.75em 1em;
}

.kcr .kcr-modal select {
	padding-right: 2.75em;
	background-position: right 1em center;
}

.kcr .kcr-modal textarea {
	min-height: 120px;
}

.kcr .kcr-modal .kcr-error {
	margin-top: 4px;
	font-size: 14px;
}

.kcr .kcr-modal .kcr-notice {
	margin: 0 0 14px;
	font-size: 14px;
}

.kcr .kcr-modal .kcr-turnstile {
	margin-bottom: 0;
}

.kcr .kcr-modal .kcr-alert {
	margin-bottom: 14px;
}

/* Desktop: het formulier past zonder scrollen in het venster (vanaf ~720px hoogte).
   Hulptekst op dezelfde regel als het label, iets kleinere velden en tekstvak. Mobiel
   (≤600px) blijft fullscreen en scrollbaar. */
@media (min-width: 601px) {
	.kcr .kcr-modal {
		max-height: calc(100dvh - 40px);
	}

	.kcr-modal__body {
		padding: 26px 32px 28px;
	}

	.kcr .kcr-modal .kcr-intro {
		margin-bottom: 12px;
		font-size: 14px;
	}

	.kcr .kcr-modal .kcr-field {
		margin-bottom: 12px;
	}

	.kcr .kcr-modal .kcr-field label {
		display: inline;
	}

	.kcr .kcr-modal .kcr-help {
		display: inline;
		margin: 0 0 0 6px;
		font-size: 13px;
	}

	.kcr .kcr-modal .kcr-field input[type="text"],
	.kcr .kcr-modal .kcr-field input[type="email"],
	.kcr .kcr-modal .kcr-field select,
	.kcr .kcr-modal .kcr-field textarea {
		display: block;
		margin-top: 5px;
		padding-top: 0.6em;
		padding-bottom: 0.6em;
	}

	/* Vier regels tekst zichtbaar; het vak blijft verticaal te vergroten. */
	.kcr .kcr-modal textarea {
		min-height: 0;
		height: calc(4 * 1.47em + 1.2em);
	}

	.kcr .kcr-modal .kcr-counter {
		margin-top: 2px;
		font-size: 13px;
	}

	.kcr .kcr-modal .kcr-notice {
		margin-bottom: 12px;
		font-size: 13px;
		line-height: 1.45;
	}
}

@media (max-width: 600px) {
	.kcr .kcr-modal {
		width: 100vw;
		height: 100dvh;
		max-height: 100dvh;
		margin: 0;
		border-radius: 0;
	}

	.kcr-modal__body {
		padding: 20px 16px 24px;
	}

	.kcr .kcr-modal__title {
		font-size: 24px;
	}

	.kcr-form__grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.kcr .kcr-modal .kcr-submit {
		width: 100%;
		justify-content: center;
	}
}

/* Na het plaatsen scrolt de succesmelding in beeld, onder de vaste Hub-header. */
.kcr #kcr-success {
	scroll-margin-top: 150px;
}
