/* LIINI Ratgeber – Geburtstermin-Rechner [liini_geburtstermin].
   Selektoren bewusst stark (html body .lgr.lgr … :not(#lgrx)) und bei Formularelementen mit !important,
   weil Theme, Elementor und das Ratgeber-CSS Absätze, Knöpfe und Felder global gestalten.
   Kontraste: Text #2B2620 / Nebentext #6E6558 auf Weiss 5.7:1, auf #FAF8F5 5.4:1, auf #F3EEE6 5.0:1;
   Feldrand #958873 auf Weiss 3.5:1 (Bedienelemente ≥ 3:1). */
.lgr {
	--lgr-bg: #FAF8F5;
	--lgr-karte: #FFFFFF;
	--lgr-rand: #E7E0D4;
	--lgr-feld: #958873;
	--lgr-text: #2B2620;
	--lgr-neben: #6E6558;
	--lgr-akzent: #B8A88F;
	--lgr-sand: #F3EEE6;
	--lgr-spur: #EFE9DF;
	--lgr-gelb: #7A5810;
	--lgr-gelb-bg: #FBF3E0;
	--lgr-gelb-rand: #F0E2BF;
}

/* ---------- Grundgerüst ---------- */
html body .lgr.lgr:not(#lgrx) {
	display: block;
	box-sizing: border-box;
	width: 100%;
	max-width: 100%;
	container-type: inline-size;
	container-name: lgr;
	background: var(--lgr-bg);
	color: var(--lgr-text);
	border: 0;
	border-radius: 24px;
	padding: clamp(16px, 4vw, 32px);
	margin: 2em 0;
	font-family: inherit;
	font-size: 16px;
	font-style: normal;
	line-height: 1.45;
	text-align: left;
	text-transform: none;
	letter-spacing: 0;
	-webkit-font-smoothing: antialiased;
}
html body .lgr.lgr *:not(#lgrx),
html body .lgr.lgr *:not(#lgrx)::before,
html body .lgr.lgr *:not(#lgrx)::after { box-sizing: border-box; }
html body .lgr.lgr p:not(#lgrx) {
	margin: 0;
	padding: 0;
	font-family: inherit;
	font-size: 16px;
	font-style: normal;
	font-weight: 400;
	line-height: 1.45;
	color: inherit;
	text-transform: none;
	letter-spacing: 0;
	text-align: left;
	border: 0;
	background: none;
}
html body .lgr.lgr [hidden]:not(#lgrx) { display: none !important; }
html body .lgr.lgr .lgr__sr:not(#lgrx),
html body .lgr.lgr .lgr__status:not(#lgrx) {
	position: absolute !important;
	width: 1px !important;
	height: 1px !important;
	margin: -1px !important;
	padding: 0 !important;
	overflow: hidden !important;
	clip: rect(0 0 0 0) !important;
	clip-path: inset(50%) !important;
	white-space: nowrap !important;
	border: 0 !important;
}

/* ---------- Kopf ---------- */
html body .lgr.lgr .lgr__kopf:not(#lgrx) { margin: 0 0 20px; }
html body .lgr.lgr p.lgr__titel:not(#lgrx) {
	font-size: 13px;
	font-weight: 800;
	line-height: 1.3;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--lgr-neben);
	margin: 0 0 6px;
}
html body .lgr.lgr p.lgr__intro:not(#lgrx) {
	font-size: clamp(18px, 2.4vw, 24px);
	font-weight: 800;
	line-height: 1.25;
	letter-spacing: -0.01em;
	color: var(--lgr-text);
	max-width: 680px;
	text-wrap: pretty;
}

/* ---------- Raster: mobil eine Spalte, breit Eingabe links / Ergebnis rechts ---------- */
html body .lgr.lgr .lgr__raster:not(#lgrx) {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 16px;
	align-items: stretch;
}
@container lgr (min-width: 640px) {
	html body .lgr.lgr .lgr__raster:not(#lgrx) { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 20px; }
}
@supports not (container-type: inline-size) {
	@media (min-width: 900px) {
		html body .lgr.lgr .lgr__raster:not(#lgrx) { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 20px; }
	}
}
html body .lgr.lgr .lgr__karte:not(#lgrx) {
	position: relative;
	min-width: 0;
	background: var(--lgr-karte);
	border: 1px solid var(--lgr-rand);
	border-radius: 20px;
	padding: 22px;
	margin: 0;
}
@container lgr (max-width: 420px) {
	html body .lgr.lgr .lgr__karte:not(#lgrx) { padding: 18px; border-radius: 18px; }
}

/* ---------- Eingabe ---------- */
html body .lgr.lgr .lgr__eingabe:not(#lgrx) { display: grid; gap: 22px; align-content: start; }
html body .lgr.lgr .lgr__feld:not(#lgrx) { display: grid; gap: 8px; min-width: 0; margin: 0; padding: 0; border: 0; }
html body .lgr.lgr .lgr__flabel:not(#lgrx) {
	display: block;
	margin: 0;
	padding: 0;
	font-family: inherit;
	font-size: 15px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--lgr-text);
	text-transform: none;
	letter-spacing: 0;
	cursor: default;
}
html body .lgr.lgr label.lgr__flabel:not(#lgrx) { cursor: pointer; }
html body .lgr.lgr p.lgr__hilfe:not(#lgrx) { font-size: 14px; line-height: 1.45; color: var(--lgr-neben); }

/* Methode: zwei Chips als Umschalter */
html body .lgr.lgr .lgr__chips:not(#lgrx) {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 4px;
	padding: 4px;
	margin: 0;
	border: 2px solid var(--lgr-feld);
	border-radius: 16px;
	background: var(--lgr-karte);
}
html body .lgr.lgr button.lgr__chip:not(#lgrx),
html body .lgr.lgr button.lgr__chip:not(#lgrx):hover,
html body .lgr.lgr button.lgr__chip:not(#lgrx):focus,
html body .lgr.lgr button.lgr__chip:not(#lgrx):active {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	width: 100% !important;
	min-width: 0 !important;
	min-height: 46px !important;
	height: auto !important;
	margin: 0 !important;
	padding: 8px 10px !important;
	border: 0 !important;
	border-radius: 11px !important;
	background: transparent !important;
	background-image: none !important;
	color: var(--lgr-text) !important;
	font-family: inherit !important;
	font-size: 15px !important;
	font-weight: 700 !important;
	font-style: normal !important;
	line-height: 1.2 !important;
	text-align: center !important;
	text-transform: none !important;
	text-decoration: none !important;
	letter-spacing: 0 !important;
	white-space: normal !important;
	box-shadow: none !important;
	opacity: 1 !important;
	transform: none !important;
	cursor: pointer;
	transition: background-color .15s ease, color .15s ease;
}
html body .lgr.lgr button.lgr__chip:not(#lgrx):hover { background: var(--lgr-sand) !important; }
html body .lgr.lgr button.lgr__chip.is-aktiv:not(#lgrx),
html body .lgr.lgr button.lgr__chip.is-aktiv:not(#lgrx):hover,
html body .lgr.lgr button.lgr__chip.is-aktiv:not(#lgrx):focus,
html body .lgr.lgr button.lgr__chip.is-aktiv:not(#lgrx):active {
	background: var(--lgr-text) !important;
	color: #FFFFFF !important;
}

/* Datum */
html body .lgr.lgr input.lgr__datum:not(#lgrx),
html body .lgr.lgr input.lgr__datum:not(#lgrx):hover,
html body .lgr.lgr input.lgr__datum:not(#lgrx):focus {
	display: block !important;
	width: 100% !important;
	max-width: 100% !important;
	min-width: 0 !important;
	height: auto !important;
	min-height: 52px !important;
	margin: 0 !important;
	padding: 12px 14px !important;
	border: 2px solid var(--lgr-feld) !important;
	border-radius: 14px !important;
	background: var(--lgr-karte) !important;
	background-image: none !important;
	color: var(--lgr-text) !important;
	font-family: inherit !important;
	font-size: 17px !important;
	font-weight: 600 !important;
	line-height: 1.3 !important;
	text-align: left !important;
	text-transform: none !important;
	letter-spacing: 0 !important;
	box-shadow: none !important;
	-webkit-appearance: none;
	appearance: none;
	color-scheme: light;
}
html body .lgr.lgr input.lgr__datum:not(#lgrx):hover { border-color: var(--lgr-text) !important; }
html body .lgr.lgr input.lgr__datum::-webkit-date-and-time-value { text-align: left; min-height: 1.3em; }
html body .lgr.lgr input.lgr__datum::-webkit-calendar-picker-indicator { cursor: pointer; opacity: .75; }

/* Zykluslänge: − Zahl + */
html body .lgr.lgr .lgr__stepper:not(#lgrx) {
	display: flex;
	align-items: stretch;
	width: 100%;
	max-width: 280px;
	min-height: 52px;
	margin: 0;
	padding: 0;
	border: 2px solid var(--lgr-feld);
	border-radius: 14px;
	background: var(--lgr-karte);
}
html body .lgr.lgr button.lgr__step:not(#lgrx),
html body .lgr.lgr button.lgr__step:not(#lgrx):hover,
html body .lgr.lgr button.lgr__step:not(#lgrx):focus,
html body .lgr.lgr button.lgr__step:not(#lgrx):active {
	display: flex !important;
	align-items: center !important;
	justify-content: center !important;
	flex: 0 0 52px !important;
	width: 52px !important;
	min-width: 0 !important;
	height: auto !important;
	min-height: 48px !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 12px !important;
	background: transparent !important;
	background-image: none !important;
	color: var(--lgr-text) !important;
	font-family: inherit !important;
	font-size: 26px !important;
	font-weight: 600 !important;
	line-height: 1 !important;
	text-transform: none !important;
	letter-spacing: 0 !important;
	box-shadow: none !important;
	opacity: 1 !important;
	transform: none !important;
	cursor: pointer;
}
html body .lgr.lgr button.lgr__step:not(#lgrx):hover { background: var(--lgr-sand) !important; }
html body .lgr.lgr button.lgr__step[aria-disabled="true"]:not(#lgrx),
html body .lgr.lgr button.lgr__step[aria-disabled="true"]:not(#lgrx):hover { color: var(--lgr-akzent) !important; background: transparent !important; cursor: not-allowed; }
html body .lgr.lgr .lgr__stepwert:not(#lgrx) {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	min-width: 0;
	border-left: 1px solid var(--lgr-rand);
	border-right: 1px solid var(--lgr-rand);
}
html body .lgr.lgr input.lgr__zahl:not(#lgrx),
html body .lgr.lgr input.lgr__zahl:not(#lgrx):hover,
html body .lgr.lgr input.lgr__zahl:not(#lgrx):focus {
	display: block !important;
	width: 2.6ch !important;
	min-width: 0 !important;
	max-width: none !important;
	height: 40px !important;
	min-height: 0 !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	border-radius: 6px !important;
	background: transparent !important;
	background-image: none !important;
	color: var(--lgr-text) !important;
	font-family: inherit !important;
	font-size: 20px !important;
	font-weight: 800 !important;
	line-height: 40px !important;
	text-align: right !important;
	box-shadow: none !important;
	font-variant-numeric: tabular-nums;
	-moz-appearance: textfield;
	appearance: textfield;
}
html body .lgr.lgr input.lgr__zahl::-webkit-outer-spin-button,
html body .lgr.lgr input.lgr__zahl::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
html body .lgr.lgr .lgr__einheit:not(#lgrx) { font-size: 16px; font-weight: 600; color: var(--lgr-neben); line-height: 1; }

html body .lgr.lgr button.lgr__chip:not(#lgrx)::before,
html body .lgr.lgr button.lgr__chip:not(#lgrx)::after,
html body .lgr.lgr button.lgr__step:not(#lgrx)::before,
html body .lgr.lgr button.lgr__step:not(#lgrx)::after { content: none !important; display: none !important; }

/* Sichtbarer Fokus (Tastatur) */
html body .lgr.lgr button.lgr__chip:not(#lgrx):focus-visible,
html body .lgr.lgr button.lgr__step:not(#lgrx):focus-visible,
html body .lgr.lgr input.lgr__datum:not(#lgrx):focus-visible,
html body .lgr.lgr input.lgr__zahl:not(#lgrx):focus-visible {
	outline: 3px solid var(--lgr-text) !important;
	outline-offset: 2px !important;
}
html body .lgr.lgr input.lgr__datum:not(#lgrx):focus { border-color: var(--lgr-text) !important; outline: 3px solid var(--lgr-text) !important; outline-offset: 2px !important; }
html body .lgr.lgr input.lgr__zahl:not(#lgrx):focus { outline: 3px solid var(--lgr-text) !important; outline-offset: 3px !important; }
html body .lgr.lgr button.lgr__chip.is-aktiv:not(#lgrx):focus-visible { outline-offset: 3px !important; }

html body .lgr.lgr p.lgr__privat:not(#lgrx) {
	font-size: 13.5px;
	line-height: 1.45;
	color: var(--lgr-neben);
	border-top: 1px solid var(--lgr-rand);
	padding-top: 14px;
}

/* ---------- Ergebnis ---------- */
html body .lgr.lgr .lgr__ergebnis:not(#lgrx) {
	display: flex;
	flex-direction: column;
	gap: 18px;
	container-type: inline-size;
	container-name: lgr-erg;
}
html body .lgr.lgr p.lgr__leer:not(#lgrx) {
	flex: 1 1 auto;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 160px;
	padding: 24px 20px;
	border: 2px dashed #D9CEBC;
	border-radius: 16px;
	font-size: 16px;
	line-height: 1.5;
	color: var(--lgr-neben);
	text-align: center;
	text-wrap: balance;
}
html body .lgr.lgr p.lgr__label:not(#lgrx) {
	font-size: 14px;
	font-weight: 700;
	line-height: 1.3;
	color: var(--lgr-neben);
	margin: 0 0 4px;
}
html body .lgr.lgr .lgr__haupt:not(#lgrx) {
	background: var(--lgr-sand);
	border-radius: 16px;
	padding: 18px 20px 16px;
}
@container lgr-erg (max-width: 340px) {
	html body .lgr.lgr .lgr__haupt:not(#lgrx) { padding: 16px 16px 14px; }
}
html body .lgr.lgr .lgr__haupt p.lgr__label:not(#lgrx) {
	font-size: 12.5px;
	font-weight: 800;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	margin: 0 0 8px;
}
html body .lgr.lgr p.lgr__termin:not(#lgrx) {
	font-size: 32px;
	font-size: clamp(26px, 9cqi, 42px);
	font-weight: 800;
	line-height: 1.08;
	letter-spacing: -0.015em;
	color: var(--lgr-text);
	margin: 0 0 6px;
	text-wrap: balance;
	overflow-wrap: break-word;
}
html body .lgr.lgr p.lgr__wochentag:not(#lgrx) { font-size: 17px; font-weight: 600; line-height: 1.3; color: var(--lgr-neben); }

html body .lgr.lgr .lgr__details:not(#lgrx) { display: grid; gap: 18px; }
html body .lgr.lgr p.lgr__ssw:not(#lgrx) { font-size: 22px; font-weight: 800; line-height: 1.15; color: var(--lgr-text); margin: 0 0 4px; }
html body .lgr.lgr p.lgr__satz:not(#lgrx) { font-size: 16px; line-height: 1.45; color: var(--lgr-text); }
/* Fortschritt 0 bis 40+0 (nur Zierde, aria-hidden) */
html body .lgr.lgr .lgr__balken:not(#lgrx) {
	position: relative;
	display: block;
	height: 8px;
	margin: 14px 7px 4px 0;
	border-radius: 999px;
	background: var(--lgr-spur);
}
html body .lgr.lgr .lgr__fuellung:not(#lgrx) {
	position: relative;
	display: block;
	height: 100%;
	width: 0;
	min-width: 8px;
	border-radius: 999px;
	background: var(--lgr-akzent);
	transition: width .35s ease;
}
html body .lgr.lgr .lgr__fuellung:not(#lgrx)::after {
	content: "";
	position: absolute;
	right: -7px;
	top: 50%;
	width: 14px;
	height: 14px;
	margin-top: -7px;
	border-radius: 50%;
	background: var(--lgr-text);
	border: 2px solid var(--lgr-karte);
}

html body .lgr.lgr .lgr__fakten:not(#lgrx) {
	display: grid;
	grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
	gap: 16px 18px;
	padding-top: 16px;
	border-top: 1px solid var(--lgr-rand);
}
html body .lgr.lgr .lgr__fakt:not(#lgrx) { min-width: 0; }
html body .lgr.lgr .lgr__fakt--breit:not(#lgrx) { grid-column: 1 / -1; }
html body .lgr.lgr p.lgr__wert:not(#lgrx) { font-size: 18px; font-size: clamp(17px, 5cqi, 19px); font-weight: 800; line-height: 1.25; color: var(--lgr-text); overflow-wrap: break-word; }
html body .lgr.lgr p.lgr__zeitraum:not(#lgrx) { font-size: 17px; margin: 0 0 4px; }
html body .lgr.lgr .lgr__zeitraum span:not(#lgrx) { white-space: nowrap; }

html body .lgr.lgr p.lgr__meldung:not(#lgrx) {
	font-size: 15px;
	line-height: 1.5;
	background: var(--lgr-gelb-bg);
	color: var(--lgr-gelb);
	border: 1px solid var(--lgr-gelb-rand);
	border-radius: 14px;
	padding: 12px 14px;
	font-weight: 600;
}
html body .lgr.lgr p.lgr__meldung--ohnejs:not(#lgrx) { margin: 0; }
html body .lgr.lgr p.lgr__richtwert:not(#lgrx) {
	margin-top: auto;
	padding-top: 14px;
	border-top: 1px solid var(--lgr-rand);
	font-size: 14px;
	line-height: 1.5;
	color: var(--lgr-neben);
}

@media (prefers-reduced-motion: reduce) {
	html body .lgr.lgr .lgr__fuellung:not(#lgrx),
	html body .lgr.lgr button.lgr__chip:not(#lgrx) { transition: none !important; }
}
