/*
 * alka4energy Stromrechner – Frontend
 * Version 1.0.0 · Philipp Ramsch · www.philippramsch.de
 * Alle Selektoren sind unter .a4e-app gekapselt. Farben/Rahmen von Schaltflächen und Feldern sind mit
 * !important abgesichert, damit Theme (Hello) und Elementor-Kit die Plugin-Farben nicht überschreiben.
 */
.a4e-app {
	--a4e-p: #C8441A;           /* Schaltflächen (Kontrast ≥ 4,5:1 mit Weiß) */
	--a4e-p-h: #A93812;
	--a4e-o: #E8582B;           /* Markenorange – nur dekorativ / große Zahlen */
	--a4e-a: #2FA8DC;           /* Markenhellblau – Flächen, Linien */
	--a4e-a-t: #0E6E9C;         /* Hellblau als Textfarbe (Kontrast ≥ 4,5:1) */
	--a4e-d: #0F1B26;           /* Dunkel */
	--a4e-t: #2B3640;           /* Fließtext */
	--a4e-m: #5B6670;           /* gedämpfter Text */
	--a4e-l: #DCE6EE;           /* Linien */
	--a4e-f: #F3F8FB;           /* Fläche hell */
	--a4e-ok: #23824A;
	--a4e-r: 16px;
	box-sizing: border-box;
	color: var(--a4e-t);
	font-size: 16px;
	line-height: 1.55;
}
.a4e-app *, .a4e-app *::before, .a4e-app *::after { box-sizing: border-box; }
.a4e-app .a4e-icon { width: 1.15em; height: 1.15em; flex: 0 0 auto; vertical-align: -0.2em; }
.a4e-app p { margin: 0 0 .6em; }
.a4e-app h3, .a4e-app h4 { margin: 0 0 .35em; line-height: 1.2; color: var(--a4e-d) !important; }

/* ───── Schaltflächen ───── */
.a4e-app .a4e-btn,
.a4e-app button.a4e-btn {
	display: inline-flex !important; align-items: center; justify-content: center; gap: .55em;
	min-height: 48px; padding: 12px 22px !important; border-radius: 10px !important;
	background: var(--a4e-p) !important; color: #fff !important; border: 2px solid var(--a4e-p) !important;
	font-family: inherit !important; font-size: 16px !important; font-weight: 700 !important; letter-spacing: .01em;
	text-decoration: none !important; text-transform: none !important; cursor: pointer; line-height: 1.2 !important;
	box-shadow: 0 6px 18px rgba(200, 68, 26, .22) !important; transition: background .2s, transform .2s, box-shadow .2s;
}
.a4e-app .a4e-btn:hover, .a4e-app .a4e-btn:focus-visible { background: var(--a4e-p-h) !important; border-color: var(--a4e-p-h) !important; color: #fff !important; transform: translateY(-1px); }
.a4e-app .a4e-btn--hell { background: #fff !important; color: var(--a4e-d) !important; border-color: var(--a4e-l) !important; box-shadow: none !important; }
.a4e-app .a4e-btn--hell:hover, .a4e-app .a4e-btn--hell:focus-visible { background: var(--a4e-f) !important; color: var(--a4e-d) !important; border-color: var(--a4e-a) !important; }
.a4e-app .a4e-btn--blau { background: var(--a4e-a-t) !important; border-color: var(--a4e-a-t) !important; box-shadow: 0 6px 18px rgba(14, 110, 156, .22) !important; }
.a4e-app .a4e-btn--blau:hover { background: #0B5A80 !important; border-color: #0B5A80 !important; }
.a4e-app .a4e-btn--voll { width: 100%; }
.a4e-app .a4e-btn[disabled] { opacity: .6; cursor: wait; transform: none; }
.a4e-app .a4e-link { background: none !important; border: 0 !important; padding: 6px 0 !important; color: var(--a4e-a-t) !important; font: inherit !important; font-weight: 600 !important; cursor: pointer; text-decoration: underline !important; text-underline-offset: 3px; box-shadow: none !important; min-height: 44px; display: inline-flex; align-items: center; gap: .4em; }
.a4e-app :focus-visible { outline: 3px solid var(--a4e-a) !important; outline-offset: 2px !important; }

/* ───── Rechner ───── */
.a4e-rechner {
	position: relative; background: #fff; border-radius: 22px; padding: 0; overflow: hidden;
	box-shadow: 0 24px 60px rgba(15, 27, 38, .14), 0 2px 6px rgba(15, 27, 38, .06);
	border: 1px solid rgba(15, 27, 38, .06);
}
.a4e-rechner .a4e-laden { display: flex; gap: 8px; justify-content: center; padding: 80px 0; }
.a4e-rechner .a4e-laden span { width: 10px; height: 10px; border-radius: 50%; background: var(--a4e-a); animation: a4e-puls 1s infinite alternate; }
.a4e-rechner .a4e-laden span:nth-child(2) { animation-delay: .2s; } .a4e-rechner .a4e-laden span:nth-child(3) { animation-delay: .4s; }
@keyframes a4e-puls { from { opacity: .25; transform: scale(.8); } to { opacity: 1; transform: scale(1); } }

.a4e-schritte { display: flex; margin: 0; padding: 0; list-style: none; background: linear-gradient(100deg, var(--a4e-d) 0%, #16324A 60%, #1B4766 100%); }
.a4e-schritte li { flex: 1 1 0; display: flex; align-items: center; gap: 10px; padding: 16px 20px; color: rgba(255,255,255,.62) !important; font-size: 14px; font-weight: 600; position: relative; margin: 0 !important; }
.a4e-schritte li::before { content: none !important; }
.a4e-schritte li .a4e-nr { width: 28px; height: 28px; border-radius: 50%; display: inline-grid; place-items: center; border: 2px solid rgba(255,255,255,.35); font-size: 13px; flex: 0 0 auto; }
.a4e-schritte li.ist-aktiv { color: #fff !important; }
.a4e-schritte li.ist-aktiv .a4e-nr { background: var(--a4e-o); border-color: var(--a4e-o); color: #fff; }
.a4e-schritte li.ist-fertig .a4e-nr { background: var(--a4e-a); border-color: var(--a4e-a); color: var(--a4e-d); }
.a4e-schritte li + li::after { content: ""; position: absolute; left: 0; top: 50%; width: 1px; height: 24px; transform: translateY(-50%); background: rgba(255,255,255,.18); }

.a4e-schritt { padding: 30px 32px 32px; }
.a4e-schritt[hidden] { display: none !important; }
.a4e-frage { font-size: 21px; font-weight: 800; color: var(--a4e-d) !important; margin: 0 0 16px; line-height: 1.25; }
.a4e-unterfrage { font-size: 15px; font-weight: 700; color: var(--a4e-d) !important; margin: 22px 0 10px; }

.a4e-kacheln { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; border: 0; padding: 0; margin: 0; }
.a4e-kachel { position: relative; margin: 0; }
.a4e-kachel input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.a4e-kachel span {
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; text-align: center;
	min-height: 104px; padding: 14px 10px; border-radius: 14px; border: 2px solid var(--a4e-l); background: #fff;
	font-weight: 700; color: var(--a4e-d) !important; transition: border-color .2s, background .2s, transform .2s, box-shadow .2s;
}
.a4e-kachel .a4e-kachel-icon { width: 34px; height: 34px; color: var(--a4e-a-t); }
.a4e-kachel input:hover + span { border-color: var(--a4e-a); transform: translateY(-2px); }
.a4e-kachel input:checked + span { border-color: var(--a4e-o); background: #FFF5F0; box-shadow: 0 8px 22px rgba(232, 88, 43, .16); }
.a4e-kachel input:checked + span .a4e-kachel-icon { color: var(--a4e-o); }
.a4e-kachel input:focus-visible + span { outline: 3px solid var(--a4e-a); outline-offset: 2px; }

.a4e-felder { display: grid; grid-template-columns: 1fr 1.6fr; gap: 16px 20px; margin-top: 22px; }
.a4e-feld { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.a4e-feld label, .a4e-feld .a4e-label { font-size: 14px; font-weight: 700; color: var(--a4e-d) !important; }
.a4e-feld small { color: var(--a4e-m) !important; font-size: 13px; }
.a4e-eingabe { position: relative; display: flex; align-items: center; }
.a4e-app .a4e-eingabe input,
.a4e-app input.a4e-input,
.a4e-app textarea.a4e-input {
	width: 100% !important; min-height: 50px; padding: 12px 14px !important; border: 2px solid var(--a4e-l) !important; border-radius: 10px !important;
	background: #fff !important; color: var(--a4e-d) !important; font: inherit !important; font-size: 17px !important; font-weight: 600 !important;
	box-shadow: none !important; transition: border-color .2s; margin: 0 !important;
}
.a4e-app textarea.a4e-input { min-height: 96px; font-weight: 400 !important; font-size: 16px !important; resize: vertical; }
.a4e-app .a4e-eingabe input:focus, .a4e-app .a4e-input:focus { border-color: var(--a4e-a) !important; outline: none !important; box-shadow: 0 0 0 4px rgba(47, 168, 220, .18) !important; }
.a4e-eingabe .a4e-einheit { position: absolute; right: 14px; color: var(--a4e-m); font-weight: 600; pointer-events: none; font-size: 15px; }
.a4e-eingabe input { padding-right: 86px !important; }
.a4e-app .ist-fehler input, .a4e-app .ist-fehler .a4e-input { border-color: #C0392B !important; }
.a4e-feldfehler { color: #B03A2E !important; font-size: 13px; font-weight: 600; min-height: 1em; }

.a4e-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 8px; }
.a4e-app .a4e-chip {
	min-height: 40px; padding: 8px 14px !important; border-radius: 999px !important; border: 1.5px solid var(--a4e-l) !important; background: var(--a4e-f) !important;
	color: var(--a4e-d) !important; font: inherit !important; font-size: 14px !important; font-weight: 600 !important; cursor: pointer; box-shadow: none !important; line-height: 1.2 !important;
}
.a4e-app .a4e-chip:hover { border-color: var(--a4e-a) !important; }
.a4e-app .a4e-chip[aria-pressed="true"] { background: var(--a4e-d) !important; color: #fff !important; border-color: var(--a4e-d) !important; }

.a4e-regler { width: 100%; accent-color: var(--a4e-o); margin: 8px 0 0; }
.a4e-regler-wert { font-weight: 800; color: var(--a4e-o); }

.a4e-segment { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.a4e-app .a4e-segment button {
	min-height: 54px; padding: 10px 12px !important; border-radius: 12px !important; border: 2px solid var(--a4e-l) !important; background: #fff !important;
	color: var(--a4e-d) !important; font: inherit !important; font-size: 14px !important; font-weight: 700 !important; cursor: pointer; line-height: 1.25 !important; box-shadow: none !important;
}
.a4e-app .a4e-segment button[aria-pressed="true"] { border-color: var(--a4e-o) !important; background: #FFF5F0 !important; }
.a4e-modusfelder { margin-top: 18px; display: grid; grid-template-columns: 1fr 1fr; gap: 16px 20px; }
.a4e-modusfelder .a4e-hinweisbox { grid-column: 1 / -1; }
.a4e-hinweisbox { display: flex; gap: 10px; align-items: flex-start; padding: 14px 16px; border-radius: 12px; background: var(--a4e-f); box-shadow: inset 4px 0 0 var(--a4e-a); font-size: 14px; color: var(--a4e-t) !important; }
.a4e-hinweisbox .a4e-icon { color: var(--a4e-a-t); margin-top: 2px; }

.a4e-flex { margin-top: 20px; }
.a4e-flex[hidden] { display: none !important; }
.a4e-fuss-hinweis { margin: 0 !important; flex: 1 1 300px; text-align: right; }
.a4e-aktionen { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 12px; margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--a4e-l); }
.a4e-meldung { margin-top: 14px; padding: 12px 14px; border-radius: 10px; background: #FDECEA; color: #8E2A1F !important; font-weight: 600; font-size: 14px; }
.a4e-meldung[hidden] { display: none !important; }

/* ───── Ergebnis ───── */
.a4e-ergebnis-kopf { display: grid; grid-template-columns: 200px 1fr; gap: 28px; align-items: center; padding: 6px 0 22px; }
.a4e-kreis { position: relative; width: 200px; height: 200px; }
.a4e-kreis svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.a4e-kreis .a4e-kreis-bg { stroke: var(--a4e-f); }
.a4e-kreis .a4e-kreis-wert { stroke: url(#a4eVerlauf); stroke-linecap: round; transition: stroke-dashoffset 1.2s cubic-bezier(.2,.8,.2,1); }
.a4e-kreis-text { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.a4e-kreis-text strong { font-size: 40px; line-height: 1; color: var(--a4e-d); font-weight: 800; letter-spacing: -.02em; }
.a4e-kreis-text span { font-size: 13px; color: var(--a4e-m); font-weight: 600; margin-top: 6px; }
.a4e-ergebnis-titel { font-size: 26px; font-weight: 800; color: var(--a4e-d) !important; line-height: 1.2; margin: 0 0 8px; }
.a4e-ergebnis-titel em { font-style: normal; color: var(--a4e-ok); }
.a4e-region { display: inline-flex; align-items: center; gap: 6px; font-size: 14px; color: var(--a4e-m) !important; font-weight: 600; margin-bottom: 14px; }
.a4e-region .a4e-icon { color: var(--a4e-o); }
.a4e-balken { display: grid; gap: 10px; }
.a4e-balken-zeile { display: grid; grid-template-columns: 150px 1fr 110px; gap: 12px; align-items: center; font-size: 14px; }
.a4e-balken-zeile span:first-child { font-weight: 700; color: var(--a4e-d); }
.a4e-balken-spur { height: 14px; border-radius: 99px; background: var(--a4e-f); overflow: hidden; }
.a4e-balken-spur i { display: block; height: 100%; border-radius: 99px; width: 0; transition: width 1s cubic-bezier(.2,.8,.2,1); }
.a4e-balken-spur i.alt { background: #9AA6B0; }
.a4e-balken-spur i.neu { background: linear-gradient(90deg, var(--a4e-a), var(--a4e-o)); }
.a4e-balken-zeile b { text-align: right; color: var(--a4e-d); }

.a4e-ergebnisliste { display: grid; gap: 16px; margin-top: 8px; }
.a4e-tarif { position: relative; display: grid; grid-template-columns: 1.4fr 1fr auto; gap: 18px 24px; align-items: center; padding: 22px 24px; border-radius: 16px; border: 2px solid var(--a4e-l); background: #fff; }
.a4e-tarif.ist-beste { border-color: var(--a4e-o); box-shadow: 0 14px 36px rgba(232, 88, 43, .14); }
.a4e-tarif .a4e-band { position: absolute; top: -12px; left: 20px; }
.a4e-band { display: inline-block; padding: 4px 12px; border-radius: 999px; background: var(--a4e-o); color: #fff !important; font-size: 12px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.a4e-band--blau { background: var(--a4e-a-t); }
.a4e-tarif-name { font-size: 19px; font-weight: 800; color: var(--a4e-d) !important; margin: 0 0 4px; }
.a4e-tarif-kurz { color: var(--a4e-m) !important; font-size: 14px; margin: 0 0 8px; }
.a4e-tarif-daten { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 13px; color: var(--a4e-m); }
.a4e-tarif-daten b { color: var(--a4e-d); }
.a4e-tarif-zahlen { text-align: right; }
.a4e-tarif-zahlen .a4e-jahr { font-size: 26px; font-weight: 800; color: var(--a4e-d); line-height: 1.1; display: block; }
.a4e-tarif-zahlen small { display: block; color: var(--a4e-m); font-size: 13px; }
.a4e-plus { display: inline-block; margin-top: 6px; padding: 4px 10px; border-radius: 8px; background: #E8F5EE; color: var(--a4e-ok) !important; font-weight: 800; font-size: 14px; }
.a4e-minus { display: inline-block; margin-top: 6px; padding: 4px 10px; border-radius: 8px; background: #F1F3F5; color: var(--a4e-m) !important; font-weight: 700; font-size: 13px; }
.a4e-tarif-knoepfe { display: flex; flex-direction: column; gap: 8px; min-width: 230px; }
.a4e-tarif-details { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: 6px 24px; padding-top: 14px; border-top: 1px dashed var(--a4e-l); }
.a4e-liste { list-style: none !important; margin: 0 !important; padding: 0 !important; display: grid; gap: 6px; }
.a4e-liste li { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; margin: 0 !important; padding: 0 !important; color: var(--a4e-t) !important; }
.a4e-liste li::before { content: none !important; }
.a4e-liste .a4e-icon { color: var(--a4e-ok); margin-top: 2px; }
.a4e-tarif-hinweis { grid-column: 1 / -1; font-size: 13px; color: var(--a4e-m) !important; margin: 0; }

.a4e-formular { margin-top: 22px; padding: 24px; border-radius: 16px; background: var(--a4e-f); border: 1px solid var(--a4e-l); }
.a4e-formular[hidden] { display: none !important; }
.a4e-formular-gitter { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; }
.a4e-formular-gitter .a4e-breit { grid-column: 1 / -1; }
.a4e-einwilligung { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; color: var(--a4e-t) !important; }
.a4e-einwilligung input { width: 20px; height: 20px; margin-top: 2px; accent-color: var(--a4e-o); flex: 0 0 auto; }
.a4e-einwilligung a { color: var(--a4e-a-t) !important; }
.a4e-honig { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.a4e-erfolg { display: flex; gap: 12px; align-items: flex-start; padding: 18px 20px; border-radius: 14px; background: #E8F5EE; color: #1B5E37 !important; font-weight: 600; }
.a4e-erfolg .a4e-icon { color: var(--a4e-ok); width: 26px; height: 26px; }
.a4e-kleingedruckt { margin-top: 20px; font-size: 13px; color: var(--a4e-m) !important; }
.a4e-noscript { padding: 24px; }

/* ───── Day-Ahead ───── */
.a4e-da { background: #fff; border-radius: 22px; padding: 26px 28px 20px; box-shadow: 0 20px 50px rgba(15, 27, 38, .12); border: 1px solid rgba(15, 27, 38, .06); }
.a4e-da-kopf { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; }
.a4e-da-eyebrow { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--a4e-a-t) !important; }
.a4e-da-datum { font-size: 22px; font-weight: 800; color: var(--a4e-d) !important; margin: 4px 0 0 !important; }
.a4e-da-schalter, .a4e-da-ansicht { display: inline-flex; padding: 4px; border-radius: 12px; background: var(--a4e-f); gap: 4px; }
.a4e-app .a4e-da-schalter button, .a4e-app .a4e-da-ansicht button {
	min-height: 44px; padding: 8px 16px !important; border-radius: 9px !important; border: 0 !important; background: transparent !important; color: var(--a4e-d) !important;
	font: inherit !important; font-size: 14px !important; font-weight: 700 !important; cursor: pointer; box-shadow: none !important; line-height: 1.2 !important;
}
.a4e-app .a4e-da-schalter button[aria-pressed="true"], .a4e-app .a4e-da-ansicht button[aria-pressed="true"] { background: var(--a4e-d) !important; color: #fff !important; }
.a4e-da-werte { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 20px 0 8px; }
.a4e-da-wert { padding: 16px 16px 14px; border-radius: 14px; background: var(--a4e-f); box-shadow: inset 0 4px 0 var(--a4e-a); }
.a4e-da-wert span { display: block; font-size: 13px; font-weight: 700; color: var(--a4e-m); }
.a4e-da-wert strong { display: block; font-size: 24px; font-weight: 800; color: var(--a4e-d); line-height: 1.2; margin: 2px 0; }
.a4e-da-wert small { font-size: 12px; color: var(--a4e-m); }
.a4e-da-wert--gut { box-shadow: inset 0 4px 0 var(--a4e-ok); }
.a4e-da-wert--teuer { box-shadow: inset 0 4px 0 #C0392B; }
.a4e-da-wert--tipp { box-shadow: inset 0 4px 0 var(--a4e-o); }
.a4e-da-leer { grid-column: 1 / -1; padding: 16px; border-radius: 12px; background: var(--a4e-f); margin: 0; }
.a4e-da-diagramm { position: relative; margin-top: 12px; }
.a4e-da-diagramm svg { display: block; width: 100%; height: auto; overflow: visible; }
.a4e-da-diagramm .a4e-da-achse { font-size: 11px; fill: var(--a4e-m); font-family: inherit; }
.a4e-da-diagramm .a4e-da-gitter { stroke: var(--a4e-l); stroke-width: 1; }
.a4e-da-diagramm .a4e-da-null { stroke: var(--a4e-d); stroke-width: 1; opacity: .4; }
.a4e-da-diagramm rect.a4e-da-bar { transition: opacity .2s; cursor: pointer; }
.a4e-da-diagramm rect.a4e-da-bar:hover, .a4e-da-diagramm rect.a4e-da-bar.ist-aktiv { opacity: .75; }
.a4e-da-diagramm .a4e-da-fenster { fill: rgba(232, 88, 43, .09); }
.a4e-da-diagramm .a4e-da-jetzt { stroke: var(--a4e-o); stroke-width: 2; stroke-dasharray: 4 3; }
.a4e-da-tipp { position: absolute; pointer-events: none; padding: 8px 10px; border-radius: 8px; background: var(--a4e-d); color: #fff; font-size: 13px; font-weight: 600; white-space: nowrap; transform: translate(-50%, -110%); opacity: 0; transition: opacity .15s; z-index: 3; }
.a4e-da-tipp.ist-sichtbar { opacity: 1; }
.a4e-da-fuss { display: flex; justify-content: space-between; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 16px; }
.a4e-da-tabelle summary { cursor: pointer; font-weight: 700; color: var(--a4e-a-t); min-height: 44px; display: flex; align-items: center; }
.a4e-da-tabelle table { width: 100%; border-collapse: collapse; font-size: 14px; margin-top: 8px; }
.a4e-da-tabelle th, .a4e-da-tabelle td { padding: 6px 10px; border-bottom: 1px solid var(--a4e-l); text-align: right; }
.a4e-da-tabelle th:first-child, .a4e-da-tabelle td:first-child { text-align: left; }
.a4e-da-tabelle-inhalt { max-height: 360px; overflow: auto; }
.a4e-app.ist-laedt .a4e-da-diagramm, .a4e-app.ist-laedt .a4e-da-werte { opacity: .55; transition: opacity .2s; }
.a4e-da-quelle { font-size: 12px; color: var(--a4e-m) !important; margin: 14px 0 0 !important; }
.a4e-da--kompakt .a4e-da-werte { grid-template-columns: repeat(2, minmax(0, 1fr)); }

/* ───── Tarifkarten ───── */
.a4e-tarife { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 18px; }
.a4e-tarife:has(> .a4e-tarifkarte:nth-child(4):last-child) { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.a4e-tarife:has(> .a4e-tarifkarte:nth-child(3):last-child) { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.a4e-tarife:has(> .a4e-tarifkarte:nth-child(2):last-child) { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.a4e-tarife:has(> .a4e-tarifkarte:only-child) { grid-template-columns: minmax(0, 420px); }
/* Tablet/Handy: Flex statt Grid, damit eine unvollständige letzte Reihe mittig steht (keine leere Lücke). */
@media (max-width: 1199px) {
	.a4e-tarife { display: flex; flex-wrap: wrap; justify-content: center; }
	.a4e-tarife > .a4e-tarifkarte { flex: 0 1 calc((100% - 36px) / 3); }
}
@media (max-width: 700px) { .a4e-tarife > .a4e-tarifkarte { flex-basis: calc((100% - 18px) / 2); } }
@media (max-width: 600px) { .a4e-tarife > .a4e-tarifkarte { flex-basis: 100%; } }
.a4e-tarifkarte { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 26px 20px 20px; min-width: 0; border-radius: 18px; background: #fff; border: 1px solid var(--a4e-l); box-shadow: 0 10px 28px rgba(15, 27, 38, .07); transition: transform .25s, box-shadow .25s; }
.a4e-tarifkarte:hover { transform: translateY(-4px); box-shadow: 0 18px 40px rgba(15, 27, 38, .12); }
.a4e-tarifkarte::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 5px; border-radius: 18px 18px 0 0; background: linear-gradient(90deg, var(--a4e-a), #5AA5DC); }
.a4e-tarifkarte--top { border-color: var(--a4e-o); }
.a4e-tarifkarte--top::before { background: linear-gradient(90deg, var(--a4e-o), #F2922A); }
.a4e-tarifkarte .a4e-band { position: absolute; top: -12px; right: 18px; }
.a4e-tarifkarte-icon { width: 54px; height: 54px; border-radius: 14px; display: grid; place-items: center; background: #EAF6FC; color: var(--a4e-a-t); }
.a4e-tarifkarte--top .a4e-tarifkarte-icon { background: #FFF1EA; color: var(--a4e-p); }
.a4e-tarifkarte-icon .a4e-icon { width: 28px; height: 28px; }
.a4e-tarifkarte-name { font-size: 19px !important; font-weight: 800 !important; margin: 4px 0 0 !important; line-height: 1.2 !important; hyphens: auto; -webkit-hyphens: auto; }
.a4e-tarifkarte-kurz { color: var(--a4e-m) !important; font-size: 14px; margin: 0 !important; min-height: 2.6em; }
.a4e-tarifkarte-preis { padding: 12px 0; border-top: 1px solid var(--a4e-l); border-bottom: 1px solid var(--a4e-l); }
.a4e-tarifkarte-preis strong { display: block; font-size: 26px; font-weight: 800; color: var(--a4e-d); line-height: 1.15; }
.a4e-tarifkarte-preis span { display: block; font-size: 13px; color: var(--a4e-t); }
.a4e-tarifkarte-preis small { display: block; font-size: 12px; color: var(--a4e-m); margin-top: 2px; }
.a4e-tarifkarte .a4e-liste { flex: 1 1 auto; align-content: start; }
.a4e-tarifkarte .a4e-btn { margin-top: 8px; padding: 12px 14px !important; font-size: 15px !important; white-space: nowrap; }

/* ───── Responsive ───── */
@media (max-width: 1024px) {
	.a4e-kacheln { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.a4e-segment { grid-template-columns: repeat(2, minmax(0, 1fr)); }
	.a4e-tarif { grid-template-columns: 1fr auto; }
	.a4e-tarif-knoepfe { grid-column: 1 / -1; flex-direction: row; min-width: 0; }
	.a4e-tarif-knoepfe .a4e-btn { flex: 1 1 0; }
	.a4e-da-werte { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
	.a4e-schritt { padding: 22px 18px 24px; }
	.a4e-schritte li { padding: 12px 8px; font-size: 12px; justify-content: center; }
	.a4e-schritte li .a4e-text { display: none; }
	.a4e-schritte li.ist-aktiv .a4e-text { display: inline; }
	.a4e-frage { font-size: 19px; }
	.a4e-kachel span { min-height: 92px; font-size: 14px; }
	.a4e-felder, .a4e-modusfelder, .a4e-formular-gitter { grid-template-columns: 1fr; }
	.a4e-app .a4e-segment button { font-size: 13px !important; padding: 8px 8px !important; white-space: normal; hyphens: auto; -webkit-hyphens: auto; }
	.a4e-aktionen { flex-direction: column-reverse; align-items: stretch; }
	.a4e-aktionen .a4e-btn { width: 100%; }
	.a4e-fuss-hinweis { flex: 0 0 auto !important; text-align: left !important; }
	.a4e-ergebnis-kopf { grid-template-columns: 1fr; justify-items: center; text-align: center; gap: 14px; }
	.a4e-kreis { width: 170px; height: 170px; }
	.a4e-kreis-text strong { font-size: 34px; }
	.a4e-ergebnis-titel { font-size: 22px; }
	.a4e-balken { width: 100%; text-align: left; }
	.a4e-balken-zeile { grid-template-columns: 1fr auto; }
	.a4e-balken-zeile .a4e-balken-spur { grid-column: 1 / -1; grid-row: 2; }
	.a4e-tarif { grid-template-columns: 1fr; padding: 22px 18px 18px; }
	.a4e-tarif-zahlen { text-align: left; }
	.a4e-tarif-knoepfe { flex-direction: column; }
	.a4e-tarif-details { grid-template-columns: 1fr; }
	.a4e-formular { padding: 18px; }
	.a4e-da { padding: 20px 16px 16px; border-radius: 18px; }
	.a4e-da-datum { font-size: 19px; }
	.a4e-da-wert strong { font-size: 20px; }
	.a4e-da-schalter, .a4e-da-ansicht { width: 100%; }
	.a4e-da-schalter button, .a4e-da-ansicht button { flex: 1 1 0; }
}
@media (prefers-reduced-motion: reduce) {
	.a4e-app *, .a4e-app *::before, .a4e-app *::after { transition: none !important; animation: none !important; }
}
