/* Gewinnspiel & Familienprofil — Frontend
 * Farben aus dem Theme: primary #CF6800, Verlauf #FFA142 → #CF6800,
 * Text #574F46, Flaechen #F2F2F2. Schrift erbt die Seite (Poppins).
 */

.a148gs {
	--a148gs-primary: #cf6800;
	--a148gs-grad: linear-gradient(180deg, #ffa142 0%, #cf6800 100%);
	--a148gs-text: #574f46;
	--a148gs-muted: #8a8178;
	--a148gs-line: #e2ddd7;
	--a148gs-soft: #f7f3ee;
	--a148gs-error: #c62f2a;
	--a148gs-ok: #2e8b57;
	--a148gs-radius: 16px;

	box-sizing: border-box;
	margin: 2.5em 0;
	padding: 28px;
	background: #fff;
	border: 1px solid var(--a148gs-line);
	border-radius: var(--a148gs-radius);
	box-shadow: 0 6px 24px rgba(87, 79, 70, .08);
	color: var(--a148gs-text);
	font-size: 16px;
	line-height: 1.5;
}

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

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

.a148gs__head { margin-bottom: 18px; }

.a148gs__title {
	margin: 0 0 4px;
	font-size: 1.6em;
	line-height: 1.2;
	color: var(--a148gs-primary);
}

.a148gs__prize { margin: 0; font-size: 1.05em; }
.a148gs__intro { margin: 0 0 18px; }

/* ---- Felder ---- */

.a148gs-form fieldset {
	margin: 0 0 22px;
	padding: 0;
	border: 0;
	min-width: 0;
}

.a148gs-form legend {
	display: block;
	margin: 0 0 10px;
	padding: 0;
	font-weight: 600;
	font-size: 1.05em;
	color: var(--a148gs-text);
}

.a148gs-help { margin: -4px 0 12px; font-size: .9em; color: var(--a148gs-muted); }
.a148gs-help--lead { margin: 0 0 14px; font-size: .95em; }

.a148gs-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 0 14px;
}

.a148gs-row--loc { grid-template-columns: 110px 1fr 1fr; }

.a148gs-field {
	display: block;
	margin: 0 0 14px;
}

.a148gs-field > span {
	display: block;
	margin-bottom: 5px;
	font-size: .85em;
	font-weight: 600;
	color: var(--a148gs-text);
}

.a148gs-field input,
.a148gs-field select {
	display: block;
	width: 100%;
	height: 46px;
	margin: 0;
	padding: 0 14px;
	background: #fff;
	border: 1px solid #cfc8c0;
	border-radius: 10px;
	color: var(--a148gs-text);
	font: inherit;
	font-size: 16px; /* unter 16px zoomt iOS beim Fokus */
	box-shadow: none;
	appearance: none;
	-webkit-appearance: none;
}

.a148gs-field select {
	padding-right: 36px;
	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' stroke='%23574f46' stroke-width='1.8' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
}

.a148gs-field input:focus,
.a148gs-field select:focus {
	outline: none;
	border-color: var(--a148gs-primary);
	box-shadow: 0 0 0 3px rgba(207, 104, 0, .18);
}

.a148gs .has-error input,
.a148gs .has-error select,
.a148gs-field.has-error input,
.a148gs-field.has-error select { border-color: var(--a148gs-error); }

/* ---- Frage ---- */

.a148gs-question {
	padding: 18px !important;
	background: var(--a148gs-soft);
	border-radius: 12px !important;
}

.a148gs-question.has-error { box-shadow: inset 0 0 0 2px var(--a148gs-error); }

/* Legende in den Kasten holen statt auf dessen Kante */
.a148gs-question legend { float: left; width: 100%; margin-bottom: 12px; }
.a148gs-question legend + * { clear: both; }

.a148gs-answers { display: grid; gap: 8px; }
.a148gs-answers--tf { grid-template-columns: 1fr 1fr; }

.a148gs-answer {
	position: relative;
	display: flex;
	align-items: center;
	gap: 12px;
	min-height: 48px;
	margin: 0;
	padding: 10px 14px;
	background: #fff;
	border: 1px solid var(--a148gs-line);
	border-radius: 10px;
	cursor: pointer;
	transition: border-color .15s, box-shadow .15s;
}

.a148gs-answer:hover { border-color: #cfc8c0; }

.a148gs-answer input {
	flex: none;
	width: 20px;
	height: 20px;
	margin: 0;
	accent-color: var(--a148gs-primary);
}

.a148gs-answer:has(input:checked) {
	border-color: var(--a148gs-primary);
	box-shadow: 0 0 0 1px var(--a148gs-primary);
}

.a148gs-answer:has(input:focus-visible) { box-shadow: 0 0 0 3px rgba(207, 104, 0, .25); }

.a148gs-answers--tf .a148gs-answer { justify-content: center; font-weight: 600; }

/* ---- Kinder ---- */

.a148gs-kids__list { display: grid; gap: 10px; margin-bottom: 10px; }

.a148gs-kid {
	display: grid;
	grid-template-columns: 1.3fr 1fr 40px;
	gap: 10px;
	align-items: end;
	padding: 12px;
	background: var(--a148gs-soft);
	border-radius: 12px;
}

.a148gs-kid .a148gs-field { margin: 0; }

/* Ohne Namensfeld: Datum und Entfernen */
.a148gs-kid:not(:has(.a148gs-field--kidname)) { grid-template-columns: 1fr 40px; }

.a148gs-field input[type="date"] { padding-right: 10px; }
.a148gs-field input[type="date"]::-webkit-date-and-time-value { text-align: left; }

.a148gs-kid__remove {
	width: 40px;
	height: 46px;
	padding: 0;
	background: transparent;
	border: 1px solid transparent;
	border-radius: 10px;
	color: var(--a148gs-muted);
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.a148gs-kid__remove:hover { color: var(--a148gs-error); border-color: var(--a148gs-line); background: #fff; }
.a148gs-kid:only-child .a148gs-kid__remove { visibility: hidden; }

.a148gs-kids.has-error .a148gs-kid { box-shadow: inset 0 0 0 2px var(--a148gs-error); }

.a148gs-add {
	padding: 8px 16px;
	background: #fff;
	border: 1px dashed var(--a148gs-primary);
	border-radius: 999px;
	color: var(--a148gs-primary);
	font: inherit;
	font-size: .9em;
	font-weight: 600;
	cursor: pointer;
}

.a148gs-add:hover { background: var(--a148gs-soft); }

/* ---- Interessen ---- */

.a148gs-interests legend small { font-weight: 400; color: var(--a148gs-muted); }
.a148gs-chips { display: flex; flex-wrap: wrap; gap: 8px; }

.a148gs-chip { position: relative; margin: 0; cursor: pointer; }

.a148gs-chip input {
	position: absolute;
	opacity: 0;
	width: 1px;
	height: 1px;
}

.a148gs-chip span {
	display: inline-block;
	padding: 7px 14px;
	background: #fff;
	border: 1px solid #cfc8c0;
	border-radius: 999px;
	font-size: .9em;
	transition: background .15s, border-color .15s, color .15s;
}

.a148gs-chip input:checked + span {
	background: var(--a148gs-primary);
	border-color: var(--a148gs-primary);
	color: #fff;
}

.a148gs-chip input:focus-visible + span { box-shadow: 0 0 0 3px rgba(207, 104, 0, .25); }

/* ---- Einwilligungen ---- */

.a148gs-consents { display: grid; gap: 10px; margin: 6px 0 20px; }

.a148gs-consent {
	display: flex;
	gap: 10px;
	align-items: flex-start;
	margin: 0;
	font-size: .9em;
	line-height: 1.45;
	cursor: pointer;
}

.a148gs-consent input {
	flex: none;
	width: 20px;
	height: 20px;
	margin: 1px 0 0;
	accent-color: var(--a148gs-primary);
}

.a148gs-consent a { color: var(--a148gs-primary); text-decoration: underline; }
.a148gs-consent.has-error span { color: var(--a148gs-error); }

/* ---- Absenden ---- */

.a148gs-submit {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 50px;
	padding: 12px 34px;
	background: var(--a148gs-grad);
	border: 0;
	border-radius: 999px;
	color: #fff !important;
	font: inherit;
	font-size: 1.05em;
	font-weight: 600;
	text-decoration: none !important;
	cursor: pointer;
	box-shadow: 0 4px 14px rgba(207, 104, 0, .3);
	transition: transform .1s, box-shadow .15s;
}

.a148gs-submit:hover { box-shadow: 0 6px 18px rgba(207, 104, 0, .4); }
.a148gs-submit:active { transform: translateY(1px); }
.a148gs-submit[disabled] { opacity: .6; cursor: wait; }

.a148gs-fine { margin: 14px 0 0; font-size: .8em; color: var(--a148gs-muted); }

/* Fangfeld: fuer Menschen unsichtbar, fuer Bots ein normales Feld */
.a148gs-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}

/* ---- Meldungen ---- */

.a148gs-notice {
	margin: 0 0 18px;
	padding: 14px 16px;
	border-radius: 12px;
	border-left: 4px solid var(--a148gs-primary);
	background: var(--a148gs-soft);
}

.a148gs-notice strong { display: block; margin-bottom: 2px; font-size: 1.02em; }
.a148gs-notice p { margin: 0; }
.a148gs-notice ul { margin: 6px 0 0 18px; padding: 0; list-style: disc; }
.a148gs-notice li { margin: 0; padding: 0; list-style: disc; }
.a148gs-notice li::before { content: none !important; display: none !important; }
.a148gs-notice--ok { border-left-color: var(--a148gs-ok); background: #eef8f2; }
.a148gs-notice--error { border-left-color: var(--a148gs-error); background: #fdf0ef; }
.a148gs-notice--muted { border-left-color: #c6c6c6; background: #f4f4f4; }

/* ---- Teilen ---- */

.a148gs-share { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--a148gs-line); }
.a148gs-share__title { margin: 0 0 10px; font-size: .9em; font-weight: 600; color: var(--a148gs-muted); }
.a148gs-share--big .a148gs-share__title { font-size: 1.05em; color: var(--a148gs-text); }
.a148gs-share--big { border-top: 0; padding-top: 4px; }

.a148gs-share__buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.a148gs-share [hidden] { display: none !important; }

.a148gs-share__btn {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	height: 40px;
	padding: 0 16px;
	background: #fff;
	border: 1px solid #cfc8c0;
	border-radius: 999px;
	color: var(--a148gs-text) !important;
	font: inherit;
	font-size: .88em;
	font-weight: 600;
	text-decoration: none !important;
	cursor: pointer;
	transition: border-color .15s, background .15s;
}

.a148gs-share__btn span { font-weight: 500; }
.a148gs-share__btn--native span { font-weight: 600; }
.a148gs-share__btn svg { width: 18px; height: 18px; fill: currentColor; flex: none; }
.a148gs-share__btn:hover { border-color: var(--a148gs-primary); }
.a148gs-share__btn--whatsapp svg { fill: #25d366; }
.a148gs-share__btn--facebook svg { fill: #1877f2; }
.a148gs-share__btn--native { background: var(--a148gs-grad); border: 0; color: #fff !important; }
.a148gs-share__btn--native svg { fill: #fff; }
.a148gs-share__btn.is-done { border-color: var(--a148gs-ok); color: var(--a148gs-ok) !important; }

.a148gs-share--big .a148gs-share__btn { height: 46px; padding: 0 20px; font-size: .95em; }

.a148gs-editnote {
	margin: 0 0 16px;
	padding: 8px 12px;
	background: #fcf3d7;
	border-radius: 8px;
	color: #6b5310;
	font-size: .85em;
}

/* ---- Profil ---- */

.a148fam-step2 {
	margin-top: 22px;
	padding-top: 22px;
	border-top: 1px solid var(--a148gs-line);
}

.a148fam-step2 h2,
.a148fam-page h2 { margin: 0 0 8px; font-size: 1.35em; color: var(--a148gs-text); }

.a148fam-p2,
.a148fam-delete {
	margin: 0 0 20px;
	padding: 12px 16px;
	border: 1px solid var(--a148gs-line);
	border-radius: 12px;
}

.a148fam-p2 summary,
.a148fam-delete summary { cursor: pointer; font-weight: 600; }
.a148fam-p2 summary small { font-weight: 400; color: var(--a148gs-muted); }
.a148fam-p2[open] summary { margin-bottom: 12px; }

.a148fam-delete { margin-top: 26px; border-style: dashed; }
.a148fam-delete summary { color: var(--a148gs-muted); font-weight: 400; font-size: .9em; }
.a148fam-delete[open] { display: grid; gap: 10px; }

.a148gs-link-danger {
	justify-self: start;
	padding: 8px 16px;
	background: #fff;
	border: 1px solid var(--a148gs-error);
	border-radius: 999px;
	color: var(--a148gs-error);
	font: inherit;
	font-size: .9em;
	cursor: pointer;
}

/* ---- Empfehlungen ---- */

.a148fam-recs { margin: 20px 0 0; }
.a148fam-recs h3 { margin: 0 0 10px; font-size: 1.1em; }
.a148fam-recs__list { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }

.a148fam-rec {
	display: block;
	overflow: hidden;
	background: #fff;
	border: 1px solid var(--a148gs-line);
	border-radius: 12px;
	color: var(--a148gs-text) !important;
	text-decoration: none !important;
	transition: box-shadow .15s;
}

.a148fam-rec:hover { box-shadow: 0 4px 16px rgba(87, 79, 70, .12); }

.a148fam-rec img,
.a148fam-rec i {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	object-fit: cover;
	background: var(--a148gs-soft);
}

.a148fam-rec span { display: block; padding: 10px 12px; font-size: .9em; font-weight: 600; line-height: 1.3; }

.a148fam-back { margin: 22px 0 0; }
.a148fam-back a { color: var(--a148gs-primary); font-weight: 600; }

/* ---- Eigene Seite (ohne Theme) ---- */

body.a148fam-standalone {
	margin: 0;
	background: #fafafa;
	color: #574f46;
	font-family: Poppins, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

.a148fam-top { padding: 18px 16px; background: #fff; border-bottom: 1px solid #ece7e1; text-align: center; }
.a148fam-top img { display: inline-block; max-height: 48px; width: auto; }
.a148fam-top span { font-size: 22px; font-weight: 700; color: #cf6800; }
.a148fam-top a { text-decoration: none; }

.a148fam-main { max-width: 720px; margin: 0 auto; padding: 8px 16px 30px; }
.a148fam-foot { padding: 0 16px 40px; text-align: center; font-size: 13px; color: #8a8178; }
.a148fam-foot a { color: inherit; }

/* ---- Schmal ---- */

@media (max-width: 640px) {
	.a148gs { padding: 20px 16px; border-radius: 12px; }
	.a148gs-row { grid-template-columns: 1fr; }
	.a148gs-row--loc { grid-template-columns: 100px 1fr; }
	.a148gs-row--loc .a148gs-field--land { grid-column: 1 / -1; }
	.a148gs-kid { grid-template-columns: 1fr 40px; }
	.a148gs-kid .a148gs-field--kidname { grid-column: 1 / -1; }
	.a148gs-kid .a148gs-kid__remove { grid-row: 2; grid-column: 2; }
	.a148gs-kid:not(:has(.a148gs-field--kidname)) .a148gs-kid__remove { grid-row: auto; }
	.a148gs-submit { width: 100%; }
	.a148fam-recs__list { grid-template-columns: 1fr; }
	.a148fam-rec { display: flex; align-items: center; }
	.a148fam-rec img, .a148fam-rec i { width: 96px; flex: none; }
}

/* Formular „Link zum Familienprofil": Abstand zum Hinweis darunter */
.a148fam-linkform { margin-bottom: 24px; }
.a148fam-linkform + .a148gs-help { margin-top: 0; }
.a148gs-notice--info { border-left-color: #2271b1; background: #eef5fb; }

/* Familienprofil: E-Mail-Adresse erst nach „ändern“ freigeschaltet */
.a148fam-mail input[readonly] { background: var(--a148gs-soft); color: var(--a148gs-muted); cursor: not-allowed; }
.a148fam-mail__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 14px; margin: -2px 0 8px; }
.a148fam-mail__actions [hidden] { display: none !important; }
.a148gs-btn-secondary {
	padding: 8px 18px;
	background: #fff;
	border: 1px solid var(--a148gs-primary);
	border-radius: 999px;
	color: var(--a148gs-primary);
	font: inherit;
	font-size: .9em;
	font-weight: 600;
	cursor: pointer;
}
.a148gs-btn-secondary:hover { background: var(--a148gs-soft); }
.a148fam-mail__send { width: auto; padding: 10px 22px; font-size: .95em; }
.a148gs-link { padding: 0; background: none; border: 0; color: var(--a148gs-muted); font: inherit; font-size: .9em; text-decoration: underline; cursor: pointer; }
