/* Browser-Default body-margin nur im Embed-Iframe entfernen.
 * Nicht global – wuerde Theme-Abstände auf der Hauptseite killen. */
.star-kc-embed-mode html,
.star-kc-embed-mode body,
iframe[name="star-kc-embed"] html,
iframe[name="star-kc-embed"] body { margin: 0; padding: 0; }


/**
 * Star Kreditrechner – Custom Stylesheet v2.2.0
 *
 * Kein Tailwind CDN mehr. Alle benötigten Utility-Klassen sind hier definiert.
 * Google Fonts (Poppins) + Font Awesome werden via wp_enqueue_style geladen.
 * Assets werden nur auf Seiten geladen, die den [star_kreditrechner] Shortcode verwenden.
 */

/* ── Tailwind-Ersatz: Utility-Klassen (kc-Namespace) ─────────────────────── */

/* Layout */
.kc-container       { max-width: 72rem; margin: 0 auto; padding: 2rem 1rem 0.5rem; }
.kc-flex-grow       { flex-grow: 1; }
.kc-flex-col        { display: flex; flex-direction: column; }
.kc-justify-between { justify-content: space-between; }
.kc-row-between     { display: flex; justify-content: space-between; align-items: center; }
.kc-mb-2            { margin-bottom: 0.5rem; }
.kc-mb-4            { margin-bottom: 1rem; }
.kc-mb-6            { margin-bottom: 1.5rem; }
.kc-ml-2            { margin-left: 0.5rem; }
.kc-p-6             { padding: 1.5rem; }
.kc-w-full          { width: 100%; }
.kc-text-center     { text-align: center; }
.kc-text-xs         { font-size: 0.75rem; }
.kc-font-medium     { font-weight: 500; }

/* Colors */
.kc-white           { background-color: #ffffff; }
.kc-white-text      { color: #ffffff !important; }
.kc-gray-800        { color: #1f2937; }
.kc-blue-500        { color: #3b82f6; }
.kc-green           { color: #22c55e; }
.kc-yellow          { color: #eab308; }
.kc-red             { color: #ef4444; }

/* Shapes */
.kc-rounded-xl      { border-radius: 0.75rem; }
/* Browser-Default body-margin nur im Embed-Iframe entfernen.
 * Nicht global – wuerde Theme-Abstände auf der Hauptseite killen. */
.star-kc-embed-mode html,
.star-kc-embed-mode body,
iframe[name="star-kc-embed"] html,
iframe[name="star-kc-embed"] body { margin: 0; padding: 0; }


/**
 * Star Kreditrechner – Custom Stylesheet v2.2.0
 *
 * Kein Tailwind CDN mehr. Alle benötigten Utility-Klassen sind hier definiert.
 * Google Fonts (Poppins) + Font Awesome werden via wp_enqueue_style geladen.
 * Assets werden nur auf Seiten geladen, die den [star_kreditrechner] Shortcode verwenden.
 */

/* ── Tailwind-Ersatz: Utility-Klassen (kc-Namespace) ─────────────────────── */

/* Layout */
.kc-container       { max-width: 72rem; margin: 0 auto; padding: 2rem 1rem 0.5rem; }
.kc-flex-grow       { flex-grow: 1; }
.kc-flex-col        { display: flex; flex-direction: column; }
.kc-justify-between { justify-content: space-between; }
.kc-row-between     { display: flex; justify-content: space-between; align-items: center; }
.kc-mb-2            { margin-bottom: 0.5rem; }
.kc-mb-4            { margin-bottom: 1rem; }
.kc-mb-6            { margin-bottom: 1.5rem; }
.kc-ml-2            { margin-left: 0.5rem; }
.kc-p-6             { padding: 1.5rem; }
.kc-w-full          { width: 100%; }
.kc-text-center     { text-align: center; }
.kc-text-xs         { font-size: 0.75rem; }
.kc-font-medium     { font-weight: 500; }

/* Colors */
.kc-white           { background-color: #ffffff; }
.kc-white-text      { color: #ffffff !important; }
.kc-gray-800        { color: #1f2937; }
.kc-blue-500        { color: #3b82f6; }
.kc-green           { color: #22c55e; }
.kc-yellow          { color: #eab308; }
.kc-red             { color: #ef4444; }

/* Shapes */
.kc-rounded-xl      { border-radius: 0.75rem; }
.kc-shadow          { box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06); }

/* Typography */
.kc-h2 {
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1.4;
    margin: 0 0 0.5rem;
}

/* Range labels (min/max) */
.kc-range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: #94a3b8;
    margin-top: 1rem;       /* Genug Abstand damit Thumb nicht überlappt */
    padding: 0 2px;
    letter-spacing: 0.01em;
}

/* v3.9: Max-Rate rechts im Slider (z.B. 9.95%) in Blau */
.kc-range-labels span:last-child {
    color: #3b82f6;
    font-weight: 600;
}

/* Label */
.kc-label {
    color: #3b82f6;    /* v3.9.7: Blau = Widget-Akzentfarbe */
    font-weight: 500;
    font-size: 0.9rem;
}
.kc-label--flex { display: flex; align-items: center; }

/* Amount badge (Kreditbetrag-Wert) */
.kc-amount-badge {
    font-size: 1.5rem;
    font-weight: 700;
    color: #16a34a;             /* Zinsgr&#xFC;n = Kundenwert */
    background: #f0fdf4;
    padding: 0.25rem 0.75rem;
    border-radius: 0.5rem;
    border: 1.5px solid #86efac;
    white-space: nowrap;
    position: relative;
    overflow: hidden;
}
.kc-amount-badge::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 45%; height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.65) 50%, transparent 100%);
    animation: kc-btn-shimmer-once 4.5s ease-in-out infinite;
    pointer-events: none;
}

/* Value badge (Laufzeit / Zinssatz) */
.kc-value-badge {
    color: #16a34a;  /* Zinsgr&#xFC;n = Kundenwert-Anzeige */
    font-weight: 600;
    font-size: 1rem;
}

/* Result card typography */
.kc-result-label    { font-size: 0.875rem; opacity: 0.8; margin: 0; color: #ffffff; }
.kc-result-main     { font-size: 1.875rem; font-weight: 700; margin: 0; line-height: 1.2; color: #ffffff; }
.kc-result-secondary{ font-size: 1.5rem; font-weight: 600; margin: 0; color: #ffffff; }
.kc-result-small    { font-size: 1.25rem; margin: 0; color: #ffffff; }

/* Gauge footer */
.kc-gauge-footer       { text-align: center; margin-top: 1rem; border-top: 1px solid #e5e7eb; padding-top: 1rem; }
.kc-gauge-footer-label { font-size: 0.875rem; color: #4b5563; margin: 0 0 0.25rem; }
.kc-gauge-footer-value { font-size: 1.125rem; font-weight: 600; color: #2563eb; margin: 0; }
/* Dynamischer Bonitäts-Label unter Bonitätsstufe */
.kc-gauge-boni-label {
    font-size: 1rem;
    font-weight: 700;
    margin: 0;
    min-height: 1.4em;
    transition: opacity 0.28s ease, color 0.28s ease;
    color: #22c55e;
    letter-spacing: -0.01em;
}

/* Amort card header */
.kc-amort-card   { margin-top: 1.5rem; position: relative; }
.kc-amort-header { display: flex; align-items: center; margin-bottom: 0.5rem; }

/* Info-Button Zeile: klar getrennt, kein Overlap mit den Raten */
.kc-amort-info-btn-row {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 12px;
    position: relative;
    z-index: 1;
}


/* Karten-Liste: immer sichtbar (Desktop + Mobile) */
#kcMobileAmortizationList {
    display: block;
}
.kc-amort-more {
    padding: 0.75rem;
    text-align: center;
    color: #6b7280;
    font-size: 0.875rem;
}

/* Show-all Button: ein Button, immer sichtbar */
.kc-show-all-btn--desktop { display: none !important; }
.kc-show-all-btn--mobile  { display: inline-block; }

.kc-show-all-wrap {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    padding: 28px 0 20px;
}


.kc-show-all-btn {
    color: #fff;
    border: none;
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
    padding: 10px 36px;
    border-radius: 99px;
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    -webkit-appearance: none;
    appearance: none;
    outline: none;
    user-select: none;
    box-shadow: 0 4px 16px rgba(59,130,246,.4);
    transition: transform .18s cubic-bezier(.34,1.56,.64,1), box-shadow .18s ease;
    position: relative;
    overflow: hidden;
}
.kc-show-all-btn::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 45%; height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.45) 50%, transparent 100%);
    animation: kc-btn-shimmer 5s ease-in-out infinite;
    pointer-events: none;
}
.kc-show-all-btn:hover,
.kc-show-all-btn:focus,
.kc-show-all-btn:active {
    outline: none !important;
    transform: scale(1.04);
    box-shadow: 0 6px 22px rgba(59,130,246,.55) !important;
}

/* ── WIE FUNKTIONIERT Button: Glanzeffekt / Shimmer ── */
@keyframes kc-btn-shimmer {
    /* v3.9.4: -200%→+280% mit width:45% → Center deckt 0-149% = komplett durch */
    0%   { transform: translateX(-200%) skewX(-20deg); }
    100% { transform: translateX(280%)  skewX(-20deg); }
}


/* Shimmer deaktiviert: animation-name:none zerstört die Animation komplett.
   Beim Entfernen dieser Klasse startet Browser IMMER eine frische Animation ab 0%. */
.kc-shimmer-paused::before {
    animation-name: none !important;
    opacity: 0 !important;
    transition: opacity 0.5s ease !important;
}
/* 2× Shimmer: genau 2 Durchläufe, dann stopp */
.kc-shimmer-2x::before {
    animation: kc-btn-shimmer 5s ease-in-out var(--kc-anim-phase, 0ms) 2 forwards !important;
    opacity: 1 !important;
}
/* 1× Shimmer: genau 1 Durchlauf, dann stopp */
.kc-shimmer-1x::before {
    animation: kc-btn-shimmer 5s ease-in-out 0ms 1 forwards !important;
    opacity: 1 !important;
}

/* Chevron-Puls: sanftes Blauleuchten der Öffnungs-Pfeile */
@keyframes kc-chevron-pulse {
    0%, 100% { color: #3b82f6; text-shadow: none; }
    50%       { color: #2563eb; text-shadow: 0 0 8px rgba(59,130,246,0.5); }
}
/* Chevron-Zoom: sehr deutlicher Bounce-Zoom auf den Pfeilen */
@keyframes kc-chevron-sparkle {
    0%   { transform: scale(1);    color: #3b82f6; filter: none; }
    25%  { transform: scale(3.5);  color: #fbbf24; filter: drop-shadow(0 0 10px rgba(251,191,36,1)) drop-shadow(0 0 20px rgba(251,191,36,0.6)); }
    55%  { transform: scale(2.8);  color: #f97316; filter: drop-shadow(0 0 8px rgba(249,115,22,0.8)); }
    80%  { transform: scale(1.5);  color: #3b82f6; filter: drop-shadow(0 0 5px rgba(59,130,246,0.5)); }
    100% { transform: scale(1);    color: #3b82f6; filter: none; }
}
.kc-chevron-sparkle {
    animation: kc-chevron-sparkle 1.4s cubic-bezier(0.34, 1.56, 0.64, 1) forwards !important;
    animation-play-state: running !important;
    transform-origin: center !important;
    will-change: transform !important;
}
/* Zoom nicht durch Row-Container abschneiden */
.kc-amort-row,
.kc-amort-row-main {
    overflow: visible !important;
}
.kc-amort-info-btn-th {
    position: relative !important;
    overflow: hidden !important;
}
.kc-amort-info-btn-th::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 45%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent  0%,
        rgba(255,255,255,0.75) 50%,
        transparent  100%
    );
    animation: kc-btn-shimmer 5s ease-in-out infinite;
    pointer-events: none;
}
.kc-amort-info-btn-th:hover,
.kc-amort-info-btn-th:focus,

/* Modal rows (Info-Modal Zinssatz) */
.kc-modal-row {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.kc-modal-row:last-child { margin-bottom: 0; }
.kc-modal-icon { font-size: 1.25rem; flex-shrink: 0; }

/* ── Base ──────────────────────────────────────────────────────────────── */

/* overflow-x: clip global auf html – PFLICHT wenn dieses CSS auf allen Seiten geladen wird.
   kreditrechner.css wird auch auf Seiten ohne Shortcode geladen (z.B. Homepage mit Blocks).
   AOS-Animationen (Spectra/UAGB) verwenden translateX → ohne diesen Schutz entsteht
   horizontaler Scroll / abgeschnittenes Layout auf Chrome Mobile.
   clip (≠ hidden): blockiert KEIN position:fixed/sticky → keine iOS-Safari-Seiteneffekte. */
html {
    overflow-x: clip;
}

.star-kreditrechner-wrapper {
    font-family: 'Poppins', sans-serif;
    background-color: transparent;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    /* overflow-x: clip redundant (html schützt bereits global), aber explizit für Klarheit */
    overflow-x: clip;
}

.star-kreditrechner-wrapper * {
    box-sizing: border-box;
}


/* ── Range Slider – modern mit Farbfüll-Effekt ──────────────────────────── */

.kc-slider {
    -webkit-appearance: none;
    appearance: none;
    height: 6px;
    border-radius: 999px;
    /* Dynamischer Füll-Effekt: blau links vom Thumb, grau rechts */
    background: linear-gradient(
        to right,
        #3b82f6 var(--slider-fill, 20%),
        #e2e8f0 var(--slider-fill, 20%)
    );
    outline: none;
    width: 100%;
    display: block;
    margin-top: 0.75rem;
    cursor: pointer;
    /* Kein transition auf background: wuerde Fill 100ms hinter Thumb zurueckfallen lassen */
    /* touch-action: pan-y → Browser behält vertikalen Scroll-Kontrolle auf Mobile.
       Verhindert dass Slider-Drag den Seiten-Scroll blockiert (Chrome Mobile). */
    touch-action: pan-y;
}

/* Tick-Marks und Browser-Default-Punkte im Track ausblenden */
.kc-slider::-webkit-slider-runnable-track {
    -webkit-appearance: none;
    height: 6px;
    border-radius: 999px;
    background: transparent;
    border: none;
    box-shadow: none;
    outline: none;
}

/* Gestrichelten Focus-Ring (Innenborder) auf allen Browsern entfernen */
.kc-slider:focus,
.kc-slider:focus-visible,
.kc-slider:focus-within,
.kc-slider:hover,
.kc-slider:active {
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
}
/* v3.9: Slider Range Track – Hover-Fläche grün */
.kc-slider:hover {
    background: linear-gradient(
        to right,
        #22c55e var(--slider-fill, 20%),
        #e2e8f0 var(--slider-fill, 20%)
    ) !important;
}
.kc-slider::-webkit-slider-thumb:focus,
.kc-slider::-webkit-slider-thumb:focus-visible {
    outline: none !important;
}
.kc-slider::-moz-range-thumb:focus,
.kc-slider::-moz-range-thumb:focus-visible {
    outline: none !important;
}
/* ── Thumb-Puls-Shimmer (Ruhezustand) ── */
@keyframes kc-thumb-pulse {
    0%, 100% {
        box-shadow: 0 2px 10px rgba(59,130,246,0.4), 0 0 0 0   rgba(59,130,246,0.25);
    }
    50% {
        box-shadow: 0 2px 16px rgba(59,130,246,0.7), 0 0 0 6px rgba(59,130,246,0);
    }
}

@keyframes kc-thumb-shimmer {
    0%   { background-position: -100% 0; }
    100% { background-position: 200% 0; }
}
/* Einmalig-Shimmer: 1 Durchlauf in 28% der Zeit, dann 72% unsichtbar warten */
@keyframes kc-thumb-shimmer-once {
    0%    { background-position: -100% 0; }
    47%   { background-position: 200% 0; }
    47.1% { background-position: -100% 0; }  /* unsichtbarer Reset */
    100%  { background-position: -100% 0; }  /* warten */
}
@keyframes kc-btn-shimmer-once {
    /* Sweep: 1 Durchlauf (28% der Zeit), Rest unsichtbar warten */
    0%    { transform: translateX(-200%) skewX(-20deg); opacity: 1; }
    28%   { transform: translateX( 280%) skewX(-20deg); opacity: 1; }
    28.1% { transform: translateX( 280%) skewX(-20deg); opacity: 0; }
    100%  { transform: translateX( 280%) skewX(-20deg); opacity: 0; }
}

/* Kacheln: Endlos-Shimmer von links nach rechts */
@keyframes kc-tile-shimmer-loop {
    0%   { transform: translateX(-100%); }
    100% { transform: translateX( 100%); }
}

.kc-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: linear-gradient(
        110deg,
        #ffffff 0%,
        rgba(219,234,254,0) 30%,
        rgba(219,234,254,0.95) 50%,
        rgba(219,234,254,0) 70%,
        #ffffff 100%
    );
    background-size: 200% 100%;
    border: 2.5px solid #3b82f6;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(59, 130, 246, 0.4), 0 1px 3px rgba(0, 0, 0, 0.1);
    animation: kc-thumb-shimmer-once 4.5s ease-in-out infinite, kc-thumb-pulse 2s ease-in-out infinite;
    transition: transform 0.1s ease, box-shadow 0.1s ease;
}

/* Hover nur auf Maus-Geräten (kein Sticky-Hover auf Touch/Mobile) */
@media (hover: hover) and (pointer: fine) {
    .kc-slider::-webkit-slider-thumb:hover {
        background: #f59e0b;
        border-color: #3b82f6;
        transform: scale(1.18);
        box-shadow: 0 3px 12px rgba(59,130,246,0.35), 0 0 0 3px rgba(245,158,11,0.25);
        animation: none;
    }
}
/* :active bleibt für alle Geräte (sofortiges Feedback beim Ziehen) */
.kc-slider:active::-webkit-slider-thumb {
    background: #f59e0b;
    border-color: #3b82f6;
    transform: scale(1.12);
    box-shadow: 0 3px 12px rgba(59,130,246,0.35);
    animation: none;
    transition: transform 0.08s ease, background 0.08s ease;
}

.kc-slider::-moz-range-thumb {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: linear-gradient(
        110deg,
        #ffffff 0%,
        rgba(219,234,254,0) 30%,
        rgba(219,234,254,0.95) 50%,
        rgba(219,234,254,0) 70%,
        #ffffff 100%
    );
    background-size: 200% 100%;
    border: 2.5px solid #3b82f6;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(59, 130, 246, 0.4);
    animation: kc-thumb-shimmer-once 4.5s ease-in-out infinite, kc-thumb-pulse 2s ease-in-out infinite;
    transition: transform 0.1s ease;
}

@media (hover: hover) and (pointer: fine) {
    .kc-slider::-moz-range-thumb:hover {
        background: #f59e0b;
        border-color: #3b82f6;
        transform: scale(1.18);
        animation: none;
    }
}
.kc-slider:active::-moz-range-thumb {
    background: #f59e0b;
    border-color: #3b82f6;
    transform: scale(1.12);
    animation: none;
    transition: transform 0.08s ease, background 0.08s ease;
}

.kc-slider::-moz-range-track {
    height: 6px;
    border-radius: 999px;
    background: #e2e8f0;
}

.kc-slider::-moz-range-progress {
    background: #3b82f6;
    border-radius: 999px;
    height: 6px;
}

/* ── Cards ──────────────────────────────────────────────────────────────── */

.kc-card {
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.kc-card:hover {
    transform: translateY(-5px);
    box-shadow:
        0 10px 25px -5px rgba(59, 130, 246, 0.1),
        0 8px 10px -6px rgba(59, 130, 246, 0.1);
}

.kc-result-card {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    height: 100%;
    display: flex;
    flex-direction: column;
}

/* ── Glanz-Trennlinien im Kreditangebot ────────────────────────────────── */
#kcResultCard .kc-mb-2:not(:last-of-type) {
    margin-bottom: 0;
    position: relative;
}

/* v3.9.7: Shimmer via background-position auf dem Element selbst
   → kein absolut positioniertes ::before mehr → kein Overflow ausserhalb Widget */
#kcResultCard .kc-mb-2:not(:last-of-type)::after {
    content: '';
    display: block;
    height: 1px;
    position: relative;
    background: linear-gradient(
        90deg,
        rgba(255,255,255,0.10) 0%,
        rgba(255,255,255,0.65) 50%,
        rgba(255,255,255,0.10) 100%
    );
    background-size: 200% 100%;
    animation: kc-sep-shimmer 2.8s ease-in-out infinite;
    margin: 6px 0;
    overflow: hidden;
}

/* Separator-Shimmer: sicher in der Breite des Elements eingeschlossen */
@keyframes kc-sep-shimmer {
    0%   { background-position: 220% 0; }
    100% { background-position: -120% 0; }
}

/* ::before nicht mehr verwendet – entfernt um Overflow zu verhindern */
#kcResultCard .kc-mb-2:not(:last-of-type)::before {
    display: none;
}

/* ── Calculating overlay ────────────────────────────────────────────────── */

/* Basis: langsame Rückkehr-Transition (sanftes Weglöschen des Milch-Effekts) */
#kcResultCard,
#kcAmortizationCard {
    transition: opacity 0.7s ease-out, filter 0.7s ease-out;
}

.kc-calculating-overlay {
    opacity: 0.55;
    pointer-events: none;
    filter: blur(3px);
    /* schnelles Einblenden – überschreibt die Basis-Transition */
    transition: opacity 0.15s ease, filter 0.15s ease;
}

/* ── Equal-height grid ──────────────────────────────────────────────────── */

/* ═══════════════════════════════════════════════════════════
   GRID: 3 Spalten immer (Desktop + Tablet + breite Screens)
   Nur Phone <420px stapelt auf 1 Spalte
   Media Queries greifen NICHT im iframe → alles ohne Query
   ═══════════════════════════════════════════════════════════ */

.kc-equal-height-container {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    grid-template-rows: auto !important;
    gap: 1rem;
    align-items: stretch;
}

/* Gauge zurücksetzen – kein Sonderverhalten mehr */
.kc-equal-height-container > *:nth-child(3) {
    grid-column: auto !important;
    order: unset !important;
}

/* Nur echte Phones stapeln */
@media (max-width: 420px) {
    .kc-equal-height-container {
        grid-template-columns: 1fr !important;
        gap: 0.75rem;
    }
}
/* ═══════════════════════════════════════════════════════════
   GAUGE SVG (Zinstacho) – SVG-basiertes Redesign
   ═══════════════════════════════════════════════════════════ */

.kc-gauge {
    width: 100%;
    max-width: 240px;
    margin: 0 auto;
    padding: 8px 0;
}

.kc-gauge-svg {
    width: 100%;
    height: auto;
    display: block;
    overflow: visible;
}

/* Zeiger: CSS-Transition via SVG transform-box */
#kcGaugeNeedle {
    transform-box: view-box;
    transform-origin: 110px 108px;
    transition: transform 1.9s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Zinswert-Text: weiche Farbüberblendung */
#kcGaugeValue {
    transition: fill 0.45s ease;
}

/* Gauge-Wrapper soll NICHT flex-wachsen → Footer sitzt nah am Tacho */
.kc-equal-height-container > *:nth-child(3) .kc-flex-grow {
    flex-grow: 0;
}

.kc-aic-cta-btn:focus {
    outline: none !important;
    transform: scale(1.05);
    box-shadow: 0 6px 22px rgba(59,130,246,.55) !important;
}

/* Tooltip 1: nur Titel + erster Punkt sichtbar */
.kc-tooltip .kc-tooltip-text .kc-tt-row ~ .kc-tt-row {
    display: none !important;
}


/* h2 Abstand – gleiches Niveau wie Kreditangebot (1rem) für korrektes Alignment */
.kc-card .kc-h2 {
    margin-bottom: 1rem;
}

/* 🟢 GRÜN: "Kredit"-Label auf gleiche Höhe wie "Monatliche Rate" –
   padding-top entfernt, kein extra Schub mehr nach unten */
.kc-equal-height-container > *:nth-child(1) .kc-mb-6:first-of-type {
    padding-top: 0;
}

/* 🟣 LILA: Doppelter Abstand nur zwischen "Kredit" Label/Badge-Zeile
   und dem Slider drunter (1. Karte, 1. Gruppe) */
.kc-equal-height-container > *:nth-child(1) .kc-mb-6:first-of-type .kc-row-between {
    margin-bottom: 1.75rem;
}

/* 🟡 ZINSTEILFARBE: Alle drei Slider-Labels in Gold/Amber */
label[for="kcLoanAmount"],
label[for="kcLoanTerm"],
label[for="kcInterestRate"] {
    color: #22c55e !important;
    font-weight: 600;
}

/* Section-Wrapper Abstände – mehr Luft zwischen den Slider-Gruppen */
.kc-card .kc-mb-6 {
    margin-bottom: 1.875rem;
}
.kc-card .kc-mb-6:last-of-type {
    margin-bottom: 0.25rem;
}

/* =====================================================================
   DESKTOP: "Monatliche Rate" auf gleiche Höhe wie "Kredit" Label
   → Inhalt der blauen Karte nach unten schieben
   ===================================================================== */
@media (min-width: 1024px) {
    #kcResultCard .kc-flex-grow > div:first-child {
        margin-top: 0.875rem;
    }
    /* Nur 1. Block (Monatliche Rate) mehr Abstand nach unten:
       +8px schiebt kumulativ alle Folge-Blöcke in Alignment:
       Gesamtkosten → Laufzeit,  Gesamtzinsen → Jahreszins */
    #kcResultCard .kc-flex-grow > div:first-child > .kc-mb-2:first-child {
        margin-bottom: 1rem;
    }
}

/* Mobile: Thumb grösser, genug vertikaler Touch-Bereich */
@media (max-width: 767px) {
    .kc-slider {
        margin-top: 0.75rem;
        height: 6px;
    }
    .kc-slider::-webkit-slider-thumb {
        width: 26px !important;
        height: 26px !important;
    }
    .kc-slider::-moz-range-thumb {
        width: 26px !important;
        height: 26px !important;
    }
    .kc-card .kc-mb-6 {
        margin-bottom: 1.25rem;
    }
    .kc-equal-height-container > *:nth-child(1),
    .kc-equal-height-container > *:nth-child(2) {
        padding: 16px !important;
    }
    .kc-equal-height-container {
        gap: 0.6rem !important;
    }
}

/* =====================================================================
   MODAL – Zinstacho Info
   FIX 1: Desktop = position:absolute in Section (Backdrop nur oben)
   FIX 2: Mobile  = position:fixed, Fade-Animation beim Schliessen
   ===================================================================== */

/* ── Animationen: Content-Box & Backdrop getrennt ── */
@keyframes kcFadeIn {
    from { opacity: 0; transform: scale(0.96); }
    to   { opacity: 1; transform: scale(1); }
}
@keyframes kcContentOut {
    /* Nur Content-Box: Scale + Fade */
    from { opacity: 1; transform: scale(1); }
    to   { opacity: 0; transform: scale(0.94); }
}
@keyframes kcBackdropOut {
    /* Nur Backdrop: KEIN Scale, nur Fade (mit 80ms Verzögerung via JS) */
    from { opacity: 1; }
    to   { opacity: 0; }
}

/* Desktop Modal: ganzes Element faded ein */
.kc-modal--desktop-open:not(.kc-modal--closing) {
    animation: kcFadeIn 0.22s ease forwards;
}

/* Mobile: NUR Content-Box faded ein (Backdrop sofort ohne Animation) */
@media (max-width: 767px) {
    .kc-modal[style*="flex"]:not(.kc-modal--closing) {
        animation: none !important;
    }
    .kc-modal[style*="flex"] .kc-modal-content:not(.kc-content--closing) {
        animation: kcFadeIn 0.12s ease 0s both;
    }
}

/* Schliessen: Backdrop (über .kc-modal--closing) – nur Opacity */
.kc-modal--closing {
    animation: kcBackdropOut 0.2s ease forwards !important;
    pointer-events: none !important;
}

/* ── Zins-Modals ────────────────────────────────────────── */
/* Zins- & Laufzeit-Modals: Fix Leerfeld (v3.9.7)
   Ursache: .kc-modal als flex-Container ohne align-items
   -> .kc-modal-leo streckte sich auf 100vh.
   Fix: Flex-Centering + content nur so hoch wie Inhalt. */
.kc-zins-modal[style*="flex"],
.kc-laufzeit-modal[style*="flex"] {
    display: flex !important;
    align-items: center;
    justify-content: center;
    padding: 16px;
}
.kc-zins-modal .kc-modal-leo,
.kc-laufzeit-modal .kc-modal-leo {
    margin: 0 !important;
    max-height: 80vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 20px;
    width: 100%;
}
.kc-zins-modal .kc-modal-row:last-child,

/* ── Desktop: Zins/Laufzeit Modal – vertikal am Button zentriert ──────────────
   --kc-zm-top : JS → padding-top (Mitte Modal = Mitte Button –60px höher).
   Horizontale Zentrierung via justify-content:center + margin:auto der Card.
   KEIN padding-left-Trick – der würde die Card zerquetschen (Root-Cause-Fix). */
@media (min-width: 992px) {
    .kc-zins-modal[style*="flex"],
    .kc-laufzeit-modal[style*="flex"] {
        align-items:     flex-start !important;
        justify-content: center     !important;
        padding-top:     var(--kc-zm-top, 30px) !important;
        padding-left:    16px !important;
        padding-right:   16px !important;
    }
}
.kc-laufzeit-modal .kc-modal-row:last-child {
    padding-bottom: 16px;
}

/* Schliessen: Content-Box (über .kc-content--closing) – Scale + Fade */
.kc-modal-content.kc-content--closing {
    animation: kcContentOut 0.25s ease forwards !important;
    pointer-events: none !important;
}

/* DESKTOP: Modal absolut in der Section – mit schönem Radius + Schatten */
@media (min-width: 768px) {
    .kc-modal--desktop-open {
        position: absolute !important;
        left:   0    !important;
        right:  0    !important;
        top:    0    !important;
        bottom: auto !important;
        display: flex !important;
        align-items: flex-start !important;
        justify-content: center !important;
        padding-top: 80px !important;
        padding-bottom: 20px !important;
        overflow: hidden !important;
        border-radius: 20px !important;
        box-shadow:
            0 20px 60px rgba(0, 0, 0, 0.45),
            0 0 0 1px rgba(255, 255, 255, 0.07) !important;
    }
} /* closes @media (min-width: 768px) */

/* MOBILE: Modal – Backdrop sofort, Content mit Abstand nach oben */
@media (max-width: 767px) {
    .kc-modal[style*="flex"] {
        flex-direction: column;
        align-items: flex-start;
        justify-content: flex-start;
        padding: 40px 12px 12px 12px !important;
    }
    .kc-modal-content {
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        touch-action: pan-y;
        max-height: calc(100dvh - 68px);
        width: 100% !important;
    }
}

/* #kcAmortInfoModal: transparent, schwebt als Box über der Karte */
#kcAmortInfoModal {
    position: absolute !important;
    background: transparent !important;
    border-radius: 16px !important;
    /* pointer-events bleibt auto: Klick auf Backdrop schliesst Modal */
}

/* DESKTOP: Modal zentriert in der Karte */
@media (min-width: 768px) {
    #kcAmortInfoModal[style*="flex"] {
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        padding: 24px !important;
        overflow: visible !important;
        box-shadow: none !important;
    }
    #kcAmortInfoModal .kc-modal-content {
        max-height: none;
        overflow-y: visible;
        width: min(520px, 92%);
        box-shadow:
            0 50px 120px rgba(0, 0, 0, 0.35),
            0 20px 48px  rgba(0, 0, 0, 0.20),
            0 6px  16px  rgba(0, 0, 0, 0.12),
            0 0 0  1px   rgba(0, 0, 0, 0.07) !important;
    }
}

/* MOBILE */
@media (max-width: 767px) {
    #kcAmortInfoModal[style*="flex"] {
        background: transparent !important;
        padding: 16px !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: center !important;
        overflow: visible !important;
        box-shadow: none !important;
    }
    #kcAmortInfoModal .kc-modal-content {
        max-height: none !important;
        overflow-y: visible !important;
        width: 100% !important;
        box-shadow:
            0 20px 50px rgba(0, 0, 0, 0.20),
            0 6px  16px rgba(0, 0, 0, 0.10),
            0 0 0  1px  rgba(0, 0, 0, 0.05) !important;
    }
}



    .kc-tacho-title-row .kc-info-button {
        align-self: center;
    }

/* ── Zinstacho Info-Button: moderner Pill-Stil (wie kc-amort-info-btn-th) ── */
.kc-info-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    width: auto;
    height: auto;
    border-radius: 20px;
    padding: 5px 13px;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.01em;
    white-space: nowrap;
    background: #dbeafe;
    border: 1.5px solid #3b82f6;
    color: #2563eb;
    cursor: pointer;
    transition: all 0.18s ease;
    animation: none;
    line-height: 1;
    position: relative;
    overflow: hidden;         /* nötig für ::before Shimmer */
    top: -1px;  /* optische Ausrichtung mit Titel-Baseline */
}
/* Shimmer-Pseudo-Element für Kreditangebot Button */
.kc-info-button::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 45%; height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.55) 50%, transparent 100%);
    animation-name: none; /* startet pausiert – JS steuert über kc-shimmer-1x */
    pointer-events: none;
}

.kc-info-button:hover {
    background: #bfdbfe;
    border-color: #1d4ed8;
    color: #1d4ed8;
    box-shadow: 0 2px 8px rgba(59,130,246,0.25);
}

.kc-info-button:active {
    transform: scale(0.97);
}

.kc-info-button i,
.kc-info-button .fas {
    display: inline;
    font-size: 0.66rem;
    line-height: 1;
}

/* ── Modal ──────────────────────────────────────────────────────────────── */

.kc-modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 100;
    width: 100%;
    height: 100%;
    overflow-y: auto;
    background-color: rgba(0, 0, 0, 0.5);
    box-sizing: border-box;
    pointer-events: none;
}
/* Nur wenn aktiv geoeffnet: Pointer-Events aktivieren */
.kc-modal[style*="flex"] {
    pointer-events: auto;
}


@media (min-width: 768px) {
    .kc-modal {
        padding-top: 0;
    }
}

.kc-modal-content {
    background-color: #fefefe;
    margin: 15% auto;
    padding: 20px;
    border-radius: 8px;
    box-shadow:
        0 4px 6px -1px rgba(0, 0, 0, 0.1),
        0 2px 4px -1px rgba(0, 0, 0, 0.06);
    width: 80%;
    max-width: 500px;
    position: relative;
}

.kc-close-modal {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

.kc-close-modal:hover {
    color: #000;
    text-decoration: none;
}

.kc-modal-title {
    padding-right: 20px;
    margin-bottom: 15px;
    font-size: 1.125rem;
    font-weight: 600;
}

.kc-modal-paragraph {
    margin-bottom: 12px;
    font-size: 0.95rem;
    line-height: 1.5;
}

.kc-modal-paragraph:last-child {
    margin-bottom: 0;
}

/* ── Leo Modal: Premium Design ──────────────────────────────────────────── */

.kc-modal-leo {
    background: linear-gradient(160deg, #ffffff 0%, #f0f6ff 100%);
    border-radius: 20px !important;
    padding: 0 !important;
    overflow: hidden;
    max-width: 520px;
    box-shadow:
        0 24px 60px rgba(37, 99, 235, 0.18),
        0 8px 24px rgba(0, 0, 0, 0.12) !important;
    margin: 10% auto;
}

@media (min-width: 768px) {
    .kc-modal-leo {
        max-width: 640px;
        margin: 6% auto;
    }
}

/* ── Mobile: #kcInfoModal – wird ausschliesslich via JS gesteuert ───────────
   WICHTIG: KEIN display:flex !important hier – das wuerde JS-display:none uebergehen! */
@media (max-width: 767px) {

    /* Overlay: kein Padding-Top-Offset, volle Fläche – nur wenn sichtbar */
    #kcInfoModal[style*="flex"] {
        padding-top: 0 !important;
        display: flex !important;
        align-items: flex-end !important;
        justify-content: stretch !important;
        background: rgba(0, 0, 0, 0.55) !important;
    }
    /* Sicherstellen dass display:none immer gewinnt */
    #kcInfoModal[style*="none"] {
        display: none !important;
    }

    /* Modal-Content: Fullscreen Bottom-Sheet */
    #kcInfoModal .kc-modal-leo {
        width: 100% !important;
        max-width: 100% !important;
        max-height: 92vh;
        margin: 0 !important;
        border-radius: 24px 24px 0 0 !important;
        overflow-y: auto;
        overflow-x: hidden;
        -webkit-overflow-scrolling: touch;
        animation: kc-slide-up 0.35s cubic-bezier(0.34, 1.10, 0.64, 1) both;
        /* Fix: weißer Hintergrund explizit – verhindert schwarze Ecken durch Overlay */
        background: linear-gradient(160deg, #ffffff 0%, #f0f6ff 100%) !important;
        /* Zusatzpadding unten: füllt Raum bis Bildschirmrand */
        padding-bottom: max(24px, env(safe-area-inset-bottom, 24px)) !important;
    }

    @keyframes kc-slide-up {
        from { transform: translateY(100%); opacity: 0.6; }
        to   { transform: translateY(0);    opacity: 1;   }
    }

    /* Leo Header: oben abgerundet passend zum Sheet */
    #kcInfoModal .kc-leo-header {
        border-radius: 24px 24px 0 0 !important;
        padding: 16px 16px 0 18px !important;
        min-height: 90px;
    }

    /* Leo Bild etwas grösser auf Mobile */
    #kcInfoModal .kc-leo-img {
        width: 88px !important;
    }

    /* Body-Bereich scrollt mit */
    #kcInfoModal .kc-modal-body {
        overflow-y: auto;
    }

    /* Swipe-Indikator: auf blauem Leo-Header (kein weisser Gap mehr) */
    #kcInfoModal .kc-modal-leo::before {
        display: none;
    }
    #kcInfoModal .kc-leo-header {
        position: relative;
    }
    #kcInfoModal .kc-leo-header::before {
        content: '';
        position: absolute;
        top: 8px;
        left: 50%;
        transform: translateX(-50%);
        width: 40px;
        height: 4px;
        background: rgba(255,255,255,0.45);
        border-radius: 2px;
        z-index: 10;
    }
}

/* X-Button Standard – IMMER ORANGE (Zinsteil-Farbe) */
.kc-modal-leo .kc-close-modal {
    position: relative;
    flex-shrink: 0;
    align-self: flex-start;
    margin-top: 12px;
    margin-right: 2px;
    float: none;
    font-size: 22px;
    color: #f59e0b;
    z-index: 10;
    line-height: 1;
    padding: 6px 9px;
    background: rgba(245, 158, 11, 0.15);
    border: 1px solid rgba(245, 158, 11, 0.5);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
/* Hover: blau */
.kc-modal-leo .kc-close-modal:hover {
    background: rgba(37, 99, 235, 0.25);
    border-color: rgba(37, 99, 235, 0.5);
    color: #60a5fa;
    transform: rotate(90deg);
}

/* Gold-Klasse: identisch mit transparent-Stil */
.kc-close-modal--gold {
    color: rgba(255,255,255,0.85) !important;
    background: none !important;
    border: none !important;
}
.kc-close-modal--gold:hover {
    color: #ffffff !important;
    transform: none !important;
}

/* Leo Name: grosser fetter Vorname im Header */
.kc-leo-name {
    font-size: 1.45rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.01em;
    line-height: 1.1;
    margin-bottom: 2px;
    text-shadow: 0 1px 6px rgba(0,0,0,0.25);
}


/* ── Leo Header ── */
.kc-leo-header {
    display: flex;
    align-items: flex-start;
    background: linear-gradient(135deg, #1d4ed8 0%, #3b82f6 60%, #60a5fa 100%);
    padding: 16px 16px 0 20px;
    position: relative;
    overflow: hidden;
    min-height: 118px;
    border-radius: 20px 20px 0 0;
    gap: 4px;
}

.kc-leo-mascot-wrap {
    flex-shrink: 0;
    width: 115px;
    margin-bottom: -18px;
    position: relative;
    z-index: 2;
}

.kc-leo-img {
    width: 115px;
    height: auto;
    display: block;
    border-radius: 16px 16px 0 0;
    filter: drop-shadow(0 6px 16px rgba(0,0,0,0.25));
    animation: kc-leo-entrance 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both,
               kc-leo-wink 6s ease-in-out 2s infinite;
    transform-origin: bottom center;
}

@keyframes kc-leo-entrance {
    0%   { opacity: 0; transform: translateY(20px) scale(0.85); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes kc-leo-wink {
    0%   { transform: scale(1) rotate(0deg); }
    88%  { transform: scale(1) rotate(0deg); }
    91%  { transform: scale(1.04) rotate(-2deg); }
    94%  { transform: scale(1.04) rotate(-2deg) scaleX(0.97); }
    96%  { transform: scale(1.04) rotate(-2deg) scaleX(1); }
    100% { transform: scale(1) rotate(0deg); }
}

.kc-leo-header-text {
    flex: 1;
    padding: 16px 0 18px 14px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 0;
    min-width: 0;
}

.kc-leo-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(255,255,255,0.22);
    border: 1px solid rgba(255,255,255,0.4);
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 99px;
    margin-bottom: 10px;
    margin-top: 2px;
    align-self: flex-start;
}

.kc-leo-title {
    color: #ffffff !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    margin: 0 !important;
    padding-right: 36px;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

/* ── Leo Modal Body ── */
.kc-leo-intro-box {
    background: linear-gradient(135deg, #eff6ff, #f0fdf4);
    border-left: 4px solid #2563eb;
    border-radius: 0 10px 10px 0;
    margin: 22px 24px 16px 24px;
    padding: 13px 14px;
}
.kc-leo-intro-text {
    font-size: 0.88rem;
    line-height: 1.6;
    color: #1e40af;
    margin: 0;
}

.kc-modal-leo .kc-modal-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 24px;
    margin-bottom: 0;
}
.kc-modal-leo .kc-modal-icon {
    font-size: 1.15rem;
    flex-shrink: 0;
    margin-top: 4px;
    align-self: flex-start;
}
.kc-modal-leo .kc-modal-paragraph {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.6;
    color: #374151;
    padding: 0;
}

.kc-modal-row--promise {
    background: linear-gradient(135deg, rgba(37,99,235,0.06), rgba(16,185,129,0.06));
    border-radius: 12px;
    margin: 8px 20px 20px 20px !important;
    padding: 12px 16px !important;
    border: 1px solid rgba(37,99,235,0.15);
}

.kc-leo-link {
    color: #2563eb;
    text-decoration: underline;
    text-decoration-color: rgba(37,99,235,0.4);
    font-weight: 600;
    transition: color 0.2s ease;
}
.kc-leo-link:hover {
    color: #1d4ed8;
    text-decoration-color: #1d4ed8;
}

/* ─── Restauriert aus Backup 22:17: calculate-btn + close-modal--gold ─── */
/* Gold-Klasse: identisch mit transparent-Stil */
.kc-close-modal--gold {
    color: rgba(255,255,255,0.85) !important;
    background: none !important;
    border: none !important;
}
.kc-close-modal--gold:hover {
    color: #ffffff !important;
    transform: none !important;
}

/* Leo Name: grosser fetter Vorname im Header */
.kc-leo-name {
    font-size: 1.45rem;
    font-weight: 800;
    color: #ffffff;
    letter-spacing: 0.01em;
    line-height: 1.1;
    margin-bottom: 2px;
    text-shadow: 0 1px 6px rgba(0,0,0,0.25);
}


/* ── Leo Header ── */
.kc-leo-header {
    display: flex;
    align-items: flex-start;
    background: linear-gradient(135deg, #1d4ed8 0%, #3b82f6 60%, #60a5fa 100%);
    padding: 16px 16px 0 20px;
    position: relative;
    overflow: hidden;
    min-height: 118px;
    border-radius: 20px 20px 0 0;
    gap: 4px;
}

.kc-leo-mascot-wrap {
    flex-shrink: 0;
    width: 115px;
    margin-bottom: -18px;
    position: relative;
    z-index: 2;
}

.kc-leo-img {
    width: 115px;
    height: auto;
    display: block;
    border-radius: 16px 16px 0 0;
    filter: drop-shadow(0 6px 16px rgba(0,0,0,0.25));
    animation: kc-leo-entrance 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both,
               kc-leo-wink 6s ease-in-out 2s infinite;
    transform-origin: bottom center;
}

@keyframes kc-leo-entrance {
    0%   { opacity: 0; transform: translateY(20px) scale(0.85); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes kc-leo-wink {
    0%   { transform: scale(1) rotate(0deg); }
    88%  { transform: scale(1) rotate(0deg); }
    91%  { transform: scale(1.04) rotate(-2deg); }
    94%  { transform: scale(1.04) rotate(-2deg) scaleX(0.97); }
    96%  { transform: scale(1.04) rotate(-2deg) scaleX(1); }
    100% { transform: scale(1) rotate(0deg); }
}

.kc-leo-header-text {
    flex: 1;
    padding: 16px 0 18px 14px;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    gap: 0;
    min-width: 0;
}

.kc-leo-badge {
    display: inline-flex;
    align-items: center;
    background: rgba(255,255,255,0.22);
    border: 1px solid rgba(255,255,255,0.4);
    color: #ffffff;
    font-size: 0.65rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    padding: 3px 10px;
    border-radius: 99px;
    margin-bottom: 10px;
    margin-top: 2px;
    align-self: flex-start;
}

.kc-leo-title {
    color: #ffffff !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    margin: 0 !important;
    padding-right: 36px;
    line-height: 1.3;
    letter-spacing: -0.01em;
}

/* ── Leo Modal Body ── */
.kc-leo-intro-box {
    background: linear-gradient(135deg, #eff6ff, #f0fdf4);
    border-left: 4px solid #2563eb;
    border-radius: 0 10px 10px 0;
    margin: 22px 24px 16px 24px;
    padding: 13px 14px;
}
.kc-leo-intro-text {
    font-size: 0.88rem;
    line-height: 1.6;
    color: #1e40af;
    margin: 0;
}

.kc-modal-leo .kc-modal-row {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 10px 24px;
    margin-bottom: 0;
}
.kc-modal-leo .kc-modal-icon {
    font-size: 1.15rem;
    flex-shrink: 0;
    margin-top: 4px;
    align-self: flex-start;
}
.kc-modal-leo .kc-modal-paragraph {
    margin: 0;
    font-size: 0.88rem;
    line-height: 1.6;
    color: #374151;
    padding: 0;
}

.kc-modal-row--promise {
    background: linear-gradient(135deg, rgba(37,99,235,0.06), rgba(16,185,129,0.06));
    border-radius: 12px;
    margin: 8px 20px 20px 20px !important;
    padding: 12px 16px !important;
    border: 1px solid rgba(37,99,235,0.15);
}

.kc-leo-link {
    color: #2563eb;
    text-decoration: underline;
    text-decoration-color: rgba(37,99,235,0.4);
    font-weight: 600;
    transition: color 0.2s ease;
}
.kc-leo-link:hover {
    color: #1d4ed8;
    text-decoration-color: #1d4ed8;
}

/* ── Leo Modal: Farbige Icon-Badges ── */
.kc-ico {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    flex-shrink: 0;
    font-size: 0.82rem;
}
.kc-ico--red  { background: #fee2e2; color: #dc2626; }
.kc-ico--blue { background: #dbeafe; color: #2563eb; }
.kc-ico--gold { background: #fef3c7; color: #d97706; }
.kc-ico--green{ background: #d1fae5; color: #059669; }

/* Icon-Ausrichtung innerhalb der Modal-Zeilen anpassen */
.kc-modal-leo .kc-modal-icon {
    padding-top: 1px;
}

/* ── CTA Button „Unverbindliche Offerte" ────────────────────────────────── */

.calculate-btn-credit-offer {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 13px 16px;
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.85);
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    text-decoration: none !important;
    cursor: pointer;
    white-space: nowrap;
    transition: background 0.22s ease, color 0.22s ease, border-color 0.22s ease,
                transform 0.18s ease, box-shadow 0.22s ease;
    margin-top: 1rem;
    position: relative;
    overflow: hidden;
}
/* Shimmer auf UNVERBINDLICHE OFFERTE Button */
.calculate-btn-credit-offer::before {
    content: '';
    position: absolute;
    top: 0; left: 0;
    width: 45%; height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.35) 50%, transparent 100%);
    animation: kc-btn-shimmer 2.8s ease-in-out infinite;
    pointer-events: none;
}

/* Double-chevron icon via pseudo-element (replaces calculator icon) */
.calculate-btn-credit-offer .fa-calculator {
    display: none;
}

.calculate-btn-credit-offer::after {
    content: '\00BB\00BB'; /* »» */
    margin-left: 10px;
    font-size: 1rem;
    opacity: 0.9;
    transition: transform 0.2s ease;
    font-style: normal;
}

/* Hover state */
.calculate-btn-credit-offer:hover {
    background: #ffffff;
    color: #1d4ed8;
    border-color: #ffffff;
    text-decoration: none !important;
    transform: translateY(-2px);
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.18);
}

.calculate-btn-credit-offer:hover::after {
    transform: translateX(4px);
}

/* Fix: Button-Text immer lesbar – auch nach Klick (:visited/:focus/:active) */
.calculate-btn-credit-offer:visited {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.85);
    background: transparent;
    text-decoration: none !important;
}
.calculate-btn-credit-offer:visited::after {
    color: #ffffff;
}
.calculate-btn-credit-offer:focus {
    color: #ffffff;
    outline: none;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.4);
    text-decoration: none !important;
}
.calculate-btn-credit-offer:active {
    color: #ffffff;
    transform: translateY(0);
    text-decoration: none !important;
}

/* ═══════════════════════════════════════════════════════════════════
   TEMPLATE OVERRIDE STYLES
   Migriert von template.php (v3.7.2) – ehemals Inline-<style> Block
   Priorität via !important – überschreibt Theme-CSS zuverlässig
   ═══════════════════════════════════════════════════════════════════ */
/* ── Rate-Hauptzeile: garantiertes Flex-Layout ── */
.kc-amort-row-main{display:flex!important;align-items:center!important;justify-content:space-between!important;padding:13px 14px!important;gap:10px!important;cursor:pointer!important;transition:background .15s ease!important;}
.kc-amort-month-wrap{display:flex!important;flex-direction:column!important;gap:2px!important;flex:1!important;}
.kc-amort-right{flex:1!important;text-align:right!important;}
.kc-amort-payment{font-size:.97rem!important;font-weight:700!important;color:#1e293b!important;display:block!important;}
.kc-amort-balance{font-size:.72rem!important;color:#94a3b8!important;display:block!important;}
.kc-amort-chevron{font-size:1rem!important;color:#3b82f6!important;flex-shrink:0!important;margin:0 12px!important;display:inline-flex!important;align-items:center!important;justify-content:center!important;transition:transform .25s ease,color .2s ease!important;animation:kc-chevron-pulse 2.2s ease-in-out infinite!important;}
.kc-amort-month{font-size:.82rem!important;font-weight:700!important;color:#3b82f6!important;} /* v3.9: Blau */
.kc-amort-due{font-size:.68rem!important;color:#64748b!important;white-space:nowrap!important;}
.kc-amort-row--open .kc-amort-chevron{transform:rotate(180deg)!important;animation:none!important;color:#2563eb!important;}
/* ── Aufgeklappter Detail-Bereich ── */
.kc-amort-detail{max-height:0!important;overflow:hidden!important;transition:max-height .32s cubic-bezier(.4,0,.2,1)!important;background:linear-gradient(180deg,#f8fafc 0%,#fff 100%)!important;}
.kc-amort-row--open .kc-amort-detail{max-height:none!important;}
.kc-detail-inner{padding:10px 14px 14px!important;display:flex!important;flex-direction:column!important;gap:10px!important;border-top:1px solid #e2e8f0!important;}
.kc-detail-row{display:flex!important;align-items:center!important;gap:10px!important;}
.kc-detail-label{display:flex!important;align-items:center!important;gap:6px!important;font-size:.76rem!important;font-weight:600!important;color:#64748b!important;min-width:68px!important;white-space:nowrap!important;flex-shrink:0!important;}
.kc-detail-right{flex:1!important;min-width:0!important;}
.kc-detail-bar{height:5px!important;background:#e2e8f0!important;border-radius:3px!important;overflow:hidden!important;margin-bottom:5px!important;}
.kc-detail-fill{height:100%!important;border-radius:3px!important;transition:width .45s ease!important;}
.kc-detail-fill--blue{background:linear-gradient(90deg,#22c55e,#4ade80)!important;}
.kc-detail-fill--gold{background:linear-gradient(90deg,#3b82f6,#60a5fa)!important;}
.kc-detail-amount{font-size:.82rem!important;font-weight:700!important;color:#1e293b!important;}
/* ── Info-Button (blinkend, kein Kreis) – Zinsteil in Rate Detail ── */
.kc-amort-info-btn-inline{display:inline-flex!important;align-items:center!important;justify-content:center!important;background:transparent!important;border:none!important;border-radius:50%!important;width:26px!important;height:26px!important;min-width:26px!important;color:#3b82f6!important;font-size:0.8rem!important;cursor:pointer!important;padding:0!important;margin-left:6px!important;vertical-align:middle!important;line-height:1!important;flex-shrink:0!important;animation:kc-blink 1.8s ease-in-out infinite!important;transition:color .2s ease,transform .2s ease!important;box-sizing:border-box!important;box-shadow:none!important;}
/* ── Kombinierter Balken ── */
.kc-combined-bar-wrap{padding:12px 14px 14px!important;border-top:1px solid #e2e8f0!important;}
@media(max-width:600px){.kc-combined-bar-wrap{padding:10px 14px 6px!important;}}
.kc-combined-pct-row{display:flex!important;justify-content:space-between!important;margin-bottom:3px!important;}
.kc-pct-gold{font-size:.68rem!important;font-weight:600!important;color:#3b82f6!important;}
.kc-pct-blue{font-size:.68rem!important;font-weight:600!important;color:#3b82f6!important;}
.kc-combined-bar{display:flex!important;height:10px!important;border-radius:6px!important;overflow:hidden!important;margin-bottom:10px!important;gap:0!important;}
.kc-combined-fill{height:100%!important;flex-shrink:0!important;}
.kc-combined-fill--gold{background:linear-gradient(90deg,#3b82f6,#60a5fa)!important;}
.kc-combined-fill--blue{background:linear-gradient(90deg,#22c55e,#4ade80)!important;}
.kc-combined-labels{display:flex!important;align-items:center!important;gap:6px!important;width:100%!important;}
.kc-combined-label-left{display:flex!important;align-items:center!important;gap:3px!important;font-size:.74rem!important;color:#475569!important;white-space:nowrap!important;flex:1!important;min-width:0!important;}
.kc-combined-label-right{display:flex!important;align-items:center!important;justify-content:flex-end!important;gap:3px!important;font-size:.74rem!important;color:#475569!important;white-space:nowrap!important;flex:1!important;min-width:0!important;}
.kc-clabel-text{font-weight:600!important;color:#1e293b!important;}
.kc-clabel-val{font-weight:700!important;color:#1e293b!important;}
.kc-dot{width:8px!important;height:8px!important;border-radius:50%!important;display:inline-block!important;flex-shrink:0!important;}
.kc-dot--blue{background:#3b82f6!important;}
.kc-dot--gold{background:#3b82f6!important;}
/* Desktop: Button direkt nach Zinsteil (wie vorher) */
@media(min-width:601px){
  .kc-combined-label-left{flex:0 1 auto!important;}
  .kc-combined-label-right{flex:1!important;}
}
/* Mobile: alles auf einer Linie – Button zwischen Zinsteil und Tilgung */
@media(max-width:600px){
  .kc-combined-labels{display:flex!important;align-items:center!important;gap:3px!important;position:static!important;flex-wrap:nowrap!important;}
  .kc-combined-label-left{flex:1!important;font-size:.68rem!important;gap:2px!important;flex-wrap:nowrap!important;min-width:0!important;overflow:hidden!important;padding-right:0!important;flex-direction:row!important;}
  .kc-combined-label-right{flex:1!important;font-size:.68rem!important;gap:2px!important;justify-content:flex-end!important;min-width:0!important;overflow:hidden!important;padding-left:0!important;}
  .kc-combined-labels>.kc-amort-info-btn-inline,
  .kc-combined-label-left>.kc-amort-info-btn-inline{width:16px!important;height:16px!important;min-width:16px!important;font-size:.6rem!important;margin:0!important;flex-shrink:0!important;position:static!important;left:auto!important;transform:none!important;}
  .kc-combined-label-left>.kc-amort-info-btn-inline:hover,
  .kc-combined-label-left>.kc-amort-info-btn-inline:active,
  .kc-combined-label-left>.kc-amort-info-btn-inline:focus{transform:none!important;background:transparent!important;box-shadow:none!important;outline:none!important;}
}
/* ── Inline Info-Karte (ⓘ Button in der Rate) ── */
.kc-amort-inline-card{background:#fff!important;border-radius:14px!important;border:1px solid #e0ebff!important;box-shadow:0 6px 24px rgba(59,130,246,.12),0 2px 8px rgba(0,0,0,.06)!important;padding:14px 14px 12px!important;margin-top:10px!important;position:relative!important;max-height:500px!important;overflow:hidden!important;}
.kc-aic-close{position:absolute!important;top:8px!important;right:10px!important;background:none!important;border:none!important;font-size:1.1rem!important;color:#94a3b8!important;cursor:pointer!important;line-height:1!important;padding:2px 6px!important;}
.kc-aic-title{font-size:.85rem!important;font-weight:700!important;color:#1e293b!important;margin-bottom:6px!important;padding-right:24px!important;display:block!important;}
.kc-aic-intro{font-size:.76rem!important;color:#64748b!important;margin-bottom:10px!important;line-height:1.45!important;display:block!important;}
.kc-aic-row{display:flex!important;align-items:flex-start!important;gap:8px!important;padding:8px 10px!important;background:#f8fafc!important;border-radius:10px!important;margin-bottom:6px!important;border:1px solid #f1f5f9!important;}
.kc-aic-icon{font-size:1rem!important;line-height:1.3!important;flex-shrink:0!important;}
.kc-aic-row div{font-size:.76rem!important;line-height:1.45!important;color:#475569!important;}
.kc-aic-row span{color:#64748b!important;}
/* ── AmortInfo Modal (Wie funktioniert der Kreditzins?) ── */
/* Desktop: absolut über der Karte, zentriert */
#kcAmortInfoModal{position:absolute!important;inset:0!important;background:transparent!important;display:none;z-index:100!important;}
#kcAmortInfoModal[style*="flex"]{display:flex!important;align-items:center!important;justify-content:center!important;padding:16px!important;}
/* Mobile: gleiche Logik wie Infobox 1 (kcInfoModal) – inline im Seitenfluss */
@media(max-width:767px){
  #kcAmortInfoModal{
    position:static!important;         /* Inline im normalen Seitenfluss */
    inset:auto!important;
    background:transparent!important;
    display:none!important;
    width:100%!important;
    height:auto!important;
    overflow:visible!important;
    flex-direction:column!important;
    align-items:stretch!important;
    margin-top:14px!important;
    padding:0!important;
  }
  #kcAmortInfoModal[style*="flex"]{
    display:flex!important;
  }
  #kcAmortInfoModal .kc-modal-content{
    width:100%!important;
    max-width:100%!important;
    margin:0!important;
    border-radius:16px!important;
    max-height:none!important;
    overflow-y:visible!important;
  }
}
#kcAmortInfoModal .kc-modal-content{max-height:none!important;overflow-y:visible!important;width:100%!important;border-radius:16px!important;box-shadow:0 24px 60px rgba(0,0,0,.32),0 8px 28px rgba(0,0,0,.18),0 2px 8px rgba(59,130,246,.14)!important;}
/* ── Amort Modal Inhalt ── */
.kc-amort-diagram{background:#f8fafc!important;border-radius:12px!important;padding:14px 16px 10px!important;margin-bottom:16px!important;border:1px solid #e2e8f0!important;}
.kc-amort-svg{width:100%!important;height:auto!important;display:block!important;}

/* ── CSS Balken-Diagramm ── */
.kc-css-bars{display:flex!important;flex-direction:column!important;gap:8px!important;width:100%!important;}
.kc-bar-row{display:flex!important;align-items:center!important;gap:10px!important;width:100%!important;}
.kc-bar-label{flex-shrink:0!important;width:46px!important;font-size:.75rem!important;color:#94a3b8!important;font-weight:500!important;text-align:right!important;white-space:nowrap!important;}
.kc-bar-track{display:flex!important;flex:1!important;gap:0!important;border-radius:6px!important;overflow:hidden!important;}
.kc-bar{display:flex!important;align-items:center!important;justify-content:center!important;height:28px!important;font-size:.78rem!important;font-weight:700!important;color:#fff!important;white-space:nowrap!important;min-width:0!important;overflow:hidden!important;}
.kc-bar--zins{background:#3b82f6!important;border-radius:6px 0 0 6px!important;}  /* v3.9: Blau (Zins) */
.kc-bar--tilg{background:#22c55e!important;border-radius:0 6px 6px 0!important;}  /* v3.9: Grün (Tilgung) */

/* v3.9: Ratenplan Legende – Zinsteil=Blau, Tilgung=Grün (passend zu Balken) */
#kcAmortizationCard .kc-dot--gold { background: #3b82f6 !important; }  /* Zinsteil: Blau */
#kcAmortizationCard .kc-dot--blue { background: #22c55e !important; }  /* Tilgung: Grün */

/* v3.9: Kein Inhalt hier - #kcInfoModal mobile Regeln weiter unten in @media */




.kc-amort-tip-icon{font-size:1.1rem!important;flex-shrink:0!important;align-self:flex-start!important;margin-top:3px!important;}
.kc-title-icon{font-size:0.75em!important;vertical-align:middle!important;display:inline!important;white-space:nowrap!important;}
.kc-diag-legend{display:flex!important;align-items:center!important;gap:12px!important;font-size:.72rem!important;color:#64748b!important;justify-content:center!important;}
/* v3.9 Fix: .kc-modal[style*=flex] - NUR pointer-events global, kein flex-direction Override */
.kc-modal[style*="flex"] { pointer-events: auto; }  /* EINZIGE globale Regel */
.kc-modal-leo { position: relative !important; } /* Zoom-Overlay Anker */
.kc-modal-title{font-size:1.05rem!important;font-weight:700!important;margin-bottom:16px!important;padding-right:32px!important;color:#1e293b!important;line-height:1.4!important;}
.kc-modal-paragraph{font-size:.875rem!important;line-height:1.65!important;color:#374151!important;}
.kc-close-modal{position:absolute!important;top:6px!important;right:8px!important;color:rgba(255,255,255,0.85)!important;font-size:22px!important;background:none!important;border:none!important;cursor:pointer!important;padding:2px 4px!important;line-height:1!important;transition:color 0.15s ease!important;}
.kc-close-modal:hover{color:#ffffff!important;}
/* ── Fazit CTA-Button (Offerte anfragen in der Infobox) ── */
.kc-aic-cta-wrap{margin-top:16px!important;text-align:center!important;}
.kc-aic-cta-btn{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:7px!important;padding:10px 24px!important;border-radius:99px!important;font-size:.78rem!important;font-weight:700!important;letter-spacing:.04em!important;text-transform:uppercase!important;text-decoration:none!important;background:linear-gradient(135deg,#2563eb 0%,#3b82f6 100%)!important;color:#fff!important;border:none!important;cursor:pointer!important;box-shadow:0 4px 14px rgba(59,130,246,.35)!important;position:relative!important;overflow:hidden!important;transition:transform .18s cubic-bezier(.34,1.56,.64,1),box-shadow .18s ease!important;}
/* ── WIE FUNKTIONIERT Button (Pill-Style) ── */
.kc-amort-info-btn-th{display:inline-flex!important;align-items:center!important;justify-content:center!important;gap:6px!important;width:auto!important;height:auto!important;border-radius:99px!important;padding:10px 22px!important;font-size:.78rem!important;font-weight:700!important;letter-spacing:.04em!important;text-transform:uppercase!important;white-space:nowrap!important;background:linear-gradient(135deg,#2563eb 0%,#3b82f6 100%)!important;border:none!important;color:#fff!important;cursor:pointer!important;box-shadow:0 4px 16px rgba(59,130,246,.4)!important;transition:transform .18s cubic-bezier(.34,1.56,.64,1),box-shadow .18s ease!important;}
.kc-amort-info-btn-row{display:flex!important;justify-content:center!important;align-items:center!important;margin-top:6px!important;margin-bottom:24px!important;position:relative!important;z-index:1!important;}
/* ── Zinstacho Header: Titel + Button linksbündig nebeneinander ── */
.kc-tacho-title-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 1rem;
}

/* ── Zinstacho Info-Button: Icon-only, blinkend – UNABHÄNGIG von anderen Buttons ── */
.kc-info-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: #3b82f6;
    font-size: 1rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s ease, transform 0.2s ease;
    animation: kc-blink 1.8s ease-in-out infinite;
    position: relative;
    top: -9px;
}
/* ID-Selektor: NUR der Zinstacho-Button – doppelt so gross, vollständig unabhängig */
#kcInfoButton {
    font-size: 2rem !important;
    color: #3b82f6 !important;
    background: none !important;
    border: none !important;
    padding: 0 !important;
    top: 0 !important;
    position: relative !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    height: auto !important;
    cursor: pointer !important;
    line-height: 1 !important;
    animation: kc-blink 1.8s ease-in-out infinite !important;
    transition: color 0.2s ease, transform 0.2s ease !important;
}
#kcInfoButton i.fas {
    font-size: inherit !important;
    color: inherit !important;
}
/* ── Jahreszins Tooltip-Icon: dezent klein ── */
.kc-tooltip > i.fas {
    font-size: 1.0rem !important;
    color: #3b82f6;
    animation: kc-blink 1.8s ease-in-out infinite;
    transition: color 0.2s ease, transform 0.2s ease;
    cursor: pointer;
    line-height: 1;
    display: inline-flex;
    align-items: center;
}

.kc-info-button:hover {
    color: #1d4ed8;
    transform: scale(1.18);
    animation: none;
}

.kc-info-button:active {
    transform: scale(0.95);
}

@keyframes kc-blink {
    0%, 100% { opacity: 1; }
    50%       { opacity: 0.35; }
}

/* ── Jahreszins Regler: Label + Info-Button nebeneinander ── */
.kc-label-info-wrap {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
/* Laufzeit + Kreditzins: grun (Summe hat kein label-info-wrap = bleibt blau) */
.kc-label-info-wrap .kc-label {
    color: #16a34a;
}
.kc-jz-info-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: #3b82f6;
    font-size: 0.85rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    position: relative;
    top: -1px;
    animation: kc-blink 1.8s ease-in-out infinite;
    transition: color 0.2s ease, transform 0.2s ease;
}
.kc-jz-info-btn:hover {
    color: #1d4ed8;
    transform: scale(1.18);
    animation: none;
}
.kc-jz-info-btn:active  { transform: scale(0.95); }
.kc-jz-info-btn:focus,
.kc-jz-info-btn:focus-visible,
.kc-jz-info-btn:focus:not(:focus-visible) {
    outline: none !important;
    box-shadow: none !important;
    background: none !important;
    border: none !important;
    -webkit-tap-highlight-color: transparent !important;
}


/* ── Mobile: Jahreszins Info-Button Touch-Optimierung ── */
@media (hover: none), (pointer: coarse) {
    .kc-jz-info-btn {
        -webkit-tap-highlight-color: transparent;
        /* Tap-Ziel auf 44×44 vergrössern ohne den Button optisch zu verändern */
        padding: 10px;
        margin: -10px;
        font-size: 1rem;      /* etwas grösser → leichter treffbar */
        top: 0;
        touch-action: manipulation;
    }
    /* Hover-Effekt auf Touch-Geräten deaktivieren */
    .kc-jz-info-btn:hover {
        color: #3b82f6;       /* Originalfarbe beibehalten */
        transform: none;
        animation: kc-blink 1.8s ease-in-out infinite;
    }
    /* Visuelles Feedback beim Tippen */
    .kc-jz-info-btn:active {
        transform: scale(0.88);
        color: #1d4ed8;
    }
/* ── DESKTOP: Jahreszins Info-Popup ─────────────────────────────── */
.kc-jz-info-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-left: 6px;
}
.kc-jz-popup {
    position: absolute;
    bottom: calc(100% + 14px);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    width: 300px;
    background: #1e293b;
    color: #f1f5f9;
    border-radius: 14px;
    padding: 16px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.35), 0 8px 20px rgba(0,0,0,0.2);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.22s ease, visibility 0s linear 0.22s, transform 0.22s ease;
    z-index: 9999;
    box-sizing: border-box;
}
.kc-jz-popup-arrow {
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -8px;
    border: 8px solid transparent;
    border-top-color: #1e293b;
}
.kc-jz-popup-title {
    font-size: 0.88rem;
    font-weight: 700;
    color: #f8fafc;
    padding-bottom: 10px;
    margin: 0 0 10px;
    border-bottom: 1px solid rgba(255,255,255,0.15);
    text-align: center;
}
.kc-jz-popup-list {
    list-style: none; margin: 0; padding: 0;
    display: flex; flex-direction: column; gap: 8px;
}
.kc-jz-popup-list li {
    display: flex; align-items: flex-start; gap: 8px;
    font-size: 0.79rem; line-height: 1.55; color: #cbd5e1;
}
.kc-jz-popup-list li > span:first-child { flex-shrink: 0; font-size: 0.9rem; margin-top: 1px; }
.kc-jz-info-wrap:hover .kc-jz-popup,
.kc-jz-info-wrap.kc-jz-open .kc-jz-popup {
    opacity: 1; visibility: visible;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
    transition: opacity 0.22s ease, visibility 0s linear 0s, transform 0.22s ease;
}
@media (max-width: 767px) {
    .kc-jz-popup { display: none !important; }
    .kc-jz-info-wrap:hover .kc-jz-popup { display: none !important; }
    .kc-jz-sheet-overlay {
        position: fixed; inset: 0; background: rgba(0,0,0,0.45);
        z-index: 999998; opacity: 0; visibility: hidden;
        transition: opacity 0.3s ease, visibility 0s linear 0.3s;
    }
    .kc-jz-sheet-overlay.kc-jz-sheet-open { opacity: 1; visibility: visible; transition: opacity 0.3s ease; }
    .kc-jz-sheet {
        position: fixed; bottom: 0; left: 0; right: 0;
        z-index: 999999; background: #1e293b;
        border-radius: 20px 20px 0 0;
        transform: translateY(100%);
        transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
        overflow: hidden;
    }
    .kc-jz-sheet.kc-jz-sheet-open { transform: translateY(0); }
    .kc-jz-sheet-handle { width: 40px; height: 4px; background: rgba(255,255,255,0.25); border-radius: 2px; margin: 12px auto 0; }
    .kc-jz-sheet-inner { padding: 16px 20px 40px; max-height: 65vh; overflow-y: auto; -webkit-overflow-scrolling: touch; }
    .kc-jz-sheet-header { display: flex; align-items: center; justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,0.15); margin-bottom: 14px; }
    .kc-jz-sheet-title { font-size: 0.92rem; font-weight: 700; color: #f8fafc; }
    .kc-jz-sheet-close { background: rgba(255,255,255,0.1); border: none; color: #94a3b8; font-size: 0.85rem; cursor: pointer; width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: background 0.2s, color 0.2s; }
    .kc-jz-sheet-close:hover { background: rgba(255,255,255,0.2); color: #fff; }
    .kc-jz-sheet-rows { display: flex; flex-direction: column; gap: 10px; }
    .kc-jz-sheet-row { display: flex; align-items: flex-start; gap: 10px; background: rgba(255,255,255,0.07); border-radius: 10px; padding: 10px 12px; font-size: 0.82rem; line-height: 1.55; color: #cbd5e1; }
    .kc-jz-row-icon { flex-shrink: 0; font-size: 1rem; margin-top: 1px; }
}

    /* Wrapper-Gap auf Mobile etwas kleiner */
    .kc-label-info-wrap {
        gap: 3px;
    }
}
/* ── Mobile-only Zeilenumbruch ── */
.kc-mob-br { display: none; }
@media (max-width: 767px) {
    .kc-mob-br { display: inline; }
}

/* ── Leo In-Box Zoom ── */
.kc-leo-zoom {
    position: absolute !important;
    inset: 0 !important;
    z-index: 100 !important;
    background: rgba(255,255,255,0.97) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    border-radius: inherit !important;
    animation: kc-zoom-in 0.32s cubic-bezier(0.34,1.3,0.64,1) forwards;
}
@keyframes kc-zoom-in {
    from { opacity:0; transform:scale(0.75); }
    to   { opacity:1; transform:scale(1); }
}
.kc-leo-zoom img {
    max-width: 78% !important;
    max-height: 72% !important;
    object-fit: contain !important;
    border-radius: 14px 14px 0 0 !important;
    filter: drop-shadow(0 8px 24px rgba(0,0,0,0.15)) !important;
}
.kc-leo-zoom-label {
    text-align: center !important;
    line-height: 1.25 !important;
}
.kc-leo-zoom-name {
    display: block !important;
    font-size: 1.5rem !important;
    font-weight: 800 !important;
    color: #1e40af !important;
    letter-spacing: 0.01em !important;
}
.kc-leo-zoom-role {
    display: block !important;
    font-size: 0.82rem !important;
    font-weight: 500 !important;
    color: #64748b !important;
    letter-spacing: 0.03em !important;
}
.kc-leo-zoom-close {
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    background: #f59e0b !important;
    border: 2px solid rgba(255,255,255,0.7) !important;
    color: #fff !important;
    font-size: 20px !important;
    line-height: 1 !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 3px 10px rgba(0,0,0,0.25) !important;
    transition: background 0.2s, transform 0.2s !important;
    padding: 0 !important;
}
.kc-leo-zoom-close:hover {
    background: #3b82f6 !important;
    transform: rotate(90deg) !important;
}
/* Leo Bild: Klick-Cursor */
.kc-leo-img { cursor: zoom-in !important; }

/* Titel nach blauem Leo-Header in der Inline-Karte */
.kc-aic-section-title {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    padding: 12px 18px 4px 18px !important;
    line-height: 1.3 !important;
    letter-spacing: -0.01em !important;
}

/* Inline-Karte Header */
.kc-amort-inline-card .kc-leo-header--sm {
    position: relative !important;
    min-height: 76px !important;
    align-items: flex-start !important;
}
.kc-amort-inline-card .kc-leo-header-text {
    justify-content: flex-start !important;
    padding-bottom: 12px !important;
    gap: 4px !important;
}
/* Titel: Desktop eine Zeile, Mobile zwei Zeilen via kc-mob-br */
.kc-aic-card-title {
    white-space: nowrap !important;
    font-size: 0.9rem !important;
    line-height: 1.25 !important;
    padding-right: 28px !important;
}
@media (max-width: 767px) {
    .kc-aic-card-title {
        white-space: normal !important;
        word-break: normal !important;
        overflow-wrap: normal !important;
        font-size: 0.88rem !important;
        padding-right: 24px !important;
    }
}
/* Close-Button: nur X sichtbar, kein Hintergrund */
.kc-amort-inline-card .kc-aic-close {
    position: absolute !important;
    top: 6px !important;
    right: 8px !important;
    background: none !important;
    border: none !important;
    color: rgba(255,255,255,0.85) !important;
    font-size: 22px !important;
    line-height: 1 !important;
    padding: 2px 4px !important;
    border-radius: 0 !important;
    cursor: pointer !important;
    transition: color 0.15s ease !important;
}
.kc-amort-inline-card .kc-aic-close:hover {
    color: #ffffff !important;
}
/* Badge: kein Umbruch */
.kc-amort-inline-card .kc-leo-badge {
    white-space: nowrap !important;
    font-size: 0.55rem !important;
    padding: 2px 8px !important;
    margin: 0 0 3px 0 !important;
}
.kc-amort-inline-card .kc-leo-mascot-wrap--sm {
    margin-bottom: -8px !important;
    align-self: center !important;
}

/* ═══════════════════════════════════════════════════════════════
   KREDITBETRAG: Klickbarer Badge + Direkteingabe + Schnellauswahl
   ═══════════════════════════════════════════════════════════════ */

/* Badge: klickbar machen (Stift-Cursor, hover-Effekt) */
.kc-amount-badge--editable {
    cursor: pointer !important;
    position: relative !important;
    transition: background .18s ease, color .18s ease, transform .15s ease !important;
    user-select: none !important;
}
.kc-amount-badge--editable::after {
    content: ' ✎';
    font-size: .65em !important;
    opacity: 0.5;
    margin-left: 3px;
    transition: opacity .18s ease;
}
.kc-amount-badge--editable:hover::after,
.kc-amount-badge--editable:focus::after {
    opacity: 1;
}
.kc-amount-badge--editable.kc-editing::after {
    opacity: 0 !important;
}
.kc-amount-badge--editable:hover,
.kc-amount-badge--editable:focus {
    transform: scale(1.04) !important;
    outline: none !important;
    box-shadow: 0 0 0 2px rgba(59,130,246,0.28) !important;
}
@media (max-width: 767px) {
    .kc-jz-sheet {
        transform: translateY(100%);
        transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
        overflow: hidden;
    }
    .kc-jz-sheet.kc-jz-sheet-open { transform: translateY(0); }
    .kc-jz-sheet-handle { width: 40px; height: 4px; background: rgba(255,255,255,0.25); border-radius: 2px; margin: 12px auto 0; }
    .kc-jz-sheet-inner { padding: 16px 20px 40px; max-height: 65vh; overflow-y: auto; -webkit-overflow-scrolling: touch; }
    .kc-jz-sheet-header { display: flex; align-items: center; justify-content: space-between; padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,0.15); margin-bottom: 14px; }
    .kc-jz-sheet-title { font-size: 0.92rem; font-weight: 700; color: #f8fafc; }
    .kc-jz-sheet-close { background: rgba(255,255,255,0.1); border: none; color: #94a3b8; font-size: 0.85rem; cursor: pointer; width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: background 0.2s, color 0.2s; }
    .kc-jz-sheet-close:hover { background: rgba(255,255,255,0.2); color: #fff; }
    .kc-jz-sheet-rows { display: flex; flex-direction: column; gap: 10px; }
    .kc-jz-sheet-row { display: flex; align-items: flex-start; gap: 10px; background: rgba(255,255,255,0.07); border-radius: 10px; padding: 10px 12px; font-size: 0.82rem; line-height: 1.55; color: #cbd5e1; }
    .kc-jz-row-icon { flex-shrink: 0; font-size: 1rem; margin-top: 1px; }
}

    /* Wrapper-Gap auf Mobile etwas kleiner */
@media (max-width: 767px) {
    .kc-label-info-wrap {
        gap: 3px;
    }
}
/* ── Mobile-only Zeilenumbruch ── */
.kc-mob-br { display: none; }
@media (max-width: 767px) {
    .kc-mob-br { display: inline; }
}

/* ── Leo In-Box Zoom ── */
.kc-leo-zoom {
    position: absolute !important;
    inset: 0 !important;
    z-index: 100 !important;
    background: rgba(255,255,255,0.97) !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 10px !important;
    border-radius: inherit !important;
    animation: kc-zoom-in 0.32s cubic-bezier(0.34,1.3,0.64,1) forwards;
}
@keyframes kc-zoom-in {
    from { opacity:0; transform:scale(0.75); }
    to   { opacity:1; transform:scale(1); }
}
.kc-leo-zoom img {
    max-width: 78% !important;
    max-height: 72% !important;
    object-fit: contain !important;
    border-radius: 14px 14px 0 0 !important;
    filter: drop-shadow(0 8px 24px rgba(0,0,0,0.15)) !important;
}
.kc-leo-zoom-label {
    text-align: center !important;
    line-height: 1.25 !important;
}
.kc-leo-zoom-name {
    display: block !important;
    font-size: 1.5rem !important;
    font-weight: 800 !important;
    color: #1e40af !important;
    letter-spacing: 0.01em !important;
}
.kc-leo-zoom-role {
    display: block !important;
    font-size: 0.82rem !important;
    font-weight: 500 !important;
    color: #64748b !important;
    letter-spacing: 0.03em !important;
}
.kc-leo-zoom-close {
    position: absolute !important;
    top: 10px !important;
    right: 10px !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    background: #f59e0b !important;
    border: 2px solid rgba(255,255,255,0.7) !important;
    color: #fff !important;
    font-size: 20px !important;
    line-height: 1 !important;
    cursor: pointer !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 3px 10px rgba(0,0,0,0.25) !important;
    transition: background 0.2s, transform 0.2s !important;
    padding: 0 !important;
}
.kc-leo-zoom-close:hover {
    background: #3b82f6 !important;
    transform: rotate(90deg) !important;
}
/* Leo Bild: Klick-Cursor */
.kc-leo-img { cursor: zoom-in !important; }

/* Titel nach blauem Leo-Header in der Inline-Karte */
.kc-aic-section-title {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    padding: 12px 18px 4px 18px !important;
    line-height: 1.3 !important;
    letter-spacing: -0.01em !important;
}

/* Inline-Karte Header */
.kc-amort-inline-card .kc-leo-header--sm {
    position: relative !important;
    min-height: 76px !important;
    align-items: flex-start !important;
}
.kc-amort-inline-card .kc-leo-header-text {
    justify-content: flex-start !important;
    padding-bottom: 12px !important;
    gap: 4px !important;
}
/* Titel: Desktop eine Zeile, Mobile zwei Zeilen via kc-mob-br */
.kc-aic-card-title {
    white-space: nowrap !important;
    font-size: 0.9rem !important;
    line-height: 1.25 !important;
    padding-right: 28px !important;
}
@media (max-width: 767px) {
    .kc-aic-card-title {
        white-space: normal !important;
        word-break: normal !important;
        overflow-wrap: normal !important;
        font-size: 0.88rem !important;
        padding-right: 24px !important;
    }
}
/* Close-Button: nur X sichtbar, kein Hintergrund */
.kc-amort-inline-card .kc-aic-close {
    position: absolute !important;
    top: 6px !important;
    right: 8px !important;
    background: none !important;
    border: none !important;
    color: rgba(255,255,255,0.85) !important;
    font-size: 22px !important;
    line-height: 1 !important;
    padding: 2px 4px !important;
    border-radius: 0 !important;
    cursor: pointer !important;
    transition: color 0.15s ease !important;
}
.kc-amort-inline-card .kc-aic-close:hover {
    color: #ffffff !important;
}
/* Badge: kein Umbruch */
.kc-amort-inline-card .kc-leo-badge {
    white-space: nowrap !important;
    font-size: 0.55rem !important;
    padding: 2px 8px !important;
    margin: 0 0 3px 0 !important;
}
.kc-amort-inline-card .kc-leo-mascot-wrap--sm {
    margin-bottom: -8px !important;
    align-self: center !important;
}

/* ═══════════════════════════════════════════════════════════════
   KREDITBETRAG: Klickbarer Badge + Direkteingabe + Schnellauswahl
   ═══════════════════════════════════════════════════════════════ */

/* Badge: klickbar machen (Stift-Cursor, hover-Effekt) */
.kc-amount-badge--editable {
    cursor: pointer !important;
    position: relative !important;
    transition: background .18s ease, color .18s ease, transform .15s ease !important;
    user-select: none !important;
}
.kc-amount-badge--editable::after {
    content: ' ✎';
    font-size: .65em !important;
    opacity: 0.5;
    margin-left: 3px;
    transition: opacity .18s ease;
}
.kc-amount-badge--editable:hover::after,
.kc-amount-badge--editable:focus::after {
    opacity: 1;
}
.kc-amount-badge--editable.kc-editing::after {
    opacity: 0 !important;
}
.kc-amount-badge--editable:hover,
.kc-amount-badge--editable:focus {
    transform: scale(1.04) !important;
    outline: none !important;
    box-shadow: 0 0 0 2px rgba(22,163,74,0.28) !important;
}
.kc-amount-badge--editable.kc-editing {
    opacity: 0.45 !important;
    transform: scale(0.95) !important;
}

/* Direkteingabe-Zeile */
.kc-amount-input-wrap {
    display: flex !important;
    align-items: center !important;
    gap: 0 !important;
    margin-bottom: 10px !important;
    border: 2px solid #3b82f6 !important;
    border-radius: 12px !important;
    overflow: hidden !important;
    background: #fff !important;
    box-shadow: 0 0 0 4px rgba(59,130,246,.12) !important;
    animation: kcInputSlideIn .22s cubic-bezier(.34,1.2,.64,1) both !important;
}
@keyframes kcInputSlideIn {
    from { opacity:0; transform:translateY(-6px) scaleY(.85); }
    to   { opacity:1; transform:none; }
}
.kc-amount-input-prefix {
    padding: 10px 10px 10px 14px !important;
    font-size: .85rem !important;
    font-weight: 700 !important;
    color: #3b82f6 !important;
    background: #eff6ff !important;
    border-right: 1px solid #bfdbfe !important;
    white-space: nowrap !important;
    flex-shrink: 0 !important;
}
.kc-amount-direct-input {
    flex: 1 !important;
    border: none !important;
    outline: none !important;
    padding: 10px 10px !important;
    font-size: 1.05rem !important;
    font-weight: 700 !important;
    color: #1e293b !important;
    background: transparent !important;
    min-width: 0 !important;
    /* Pfeil-Spinner entfernen */
    -moz-appearance: textfield !important;
}
.kc-amount-direct-input::-webkit-outer-spin-button,
.kc-amount-direct-input::-webkit-inner-spin-button { -webkit-appearance: none !important; }
.kc-amount-confirm-btn {
    flex-shrink: 0 !important;
    border: none !important;
    background: #3b82f6 !important;
    color: #fff !important;
    padding: 10px 16px !important;
    font-size: 1.1rem !important;
    font-weight: 700 !important;
    cursor: pointer !important;
    transition: background .15s ease, transform .15s ease !important;
    line-height: 1 !important;
}
.kc-amount-confirm-btn:hover  { background: #2563eb !important; }
.kc-amount-confirm-btn:active { transform: scale(.92) !important; }

/* Fehlerstatus (Betrag ausserhalb Bereich) */
.kc-amount-input-wrap.kc-input-error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 4px rgba(239,68,68,.14) !important;
    animation: kcShake .3s ease !important;
}
@keyframes kcShake {
    0%,100%{transform:none} 25%{transform:translateX(-5px)} 75%{transform:translateX(5px)}
}

/* Versteckt */
.kc-hidden { display: none !important; }

/* ── Schnellauswahl-Buttons ── */
.kc-quick-amounts {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    margin-bottom: 10px !important;
    margin-top: 4px !important;
}
.kc-quick-btn {
    flex: 1 1 auto !important;
    min-width: 0 !important;
    padding: 5px 8px !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 8px !important;
    background: #f8fafc !important;
    color: #475569 !important;
    font-size: .76rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    white-space: nowrap !important;
    transition: border-color .15s ease, background .15s ease, color .15s ease, transform .12s ease !important;
    line-height: 1.4 !important;
}
.kc-quick-btn:hover {
    border-color: #3b82f6 !important;
    background: #eff6ff !important;
    color: #1d4ed8 !important;
    transform: translateY(-1px) !important;
}
.kc-quick-btn:active { transform: scale(.95) !important; }
.kc-quick-btn--active {
    border-color: #3b82f6 !important;
    background: linear-gradient(135deg,#3b82f6,#60a5fa) !important;
    color: #fff !important;
    box-shadow: 0 3px 10px rgba(59,130,246,.30) !important;
}
.kc-quick-btn--active:hover {
    background: linear-gradient(135deg,#2563eb,#3b82f6) !important;
    color: #fff !important;
    transform: translateY(-1px) !important;
}

/* Mobile: kleinere Schrift damit alle 6 in eine/zwei Zeilen passen */
@media (max-width: 400px) {
    .kc-quick-btn { font-size: .7rem !important; padding: 4px 5px !important; }
}

/* ── Schieberegler verstecken (bleibt im DOM für JS) ── */
.kc-slider--hidden {
    display: none !important;
}

/* ── "Beliebte Kreditdeals" Header ── */
.kc-deals-header {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    margin-bottom: 8px !important;
    margin-top: 2px !important;
}
.kc-deals-icon {
    font-size: .95rem !important;
    line-height: 1 !important;
}
.kc-deals-title {
    font-size: .9rem !important;  /* = .kc-label Größe */
    font-weight: 500 !important;  /* = .kc-label Gewicht, nicht fett */
    color: #3b82f6 !important;
    letter-spacing: .01em !important;
}

/* ── "⭐ Beliebt" Pip direkt auf dem Button ── */
.kc-quick-btn--popular {
    position: relative !important;
    flex-direction: column !important;
    gap: 2px !important;
    padding-bottom: 6px !important;
    padding-top: 6px !important;
}
.kc-popular-pip {
    display: block !important;
    font-size: .58rem !important;
    font-weight: 700 !important;
    color: rgba(255,255,255,0.9) !important;
    letter-spacing: .03em !important;
    line-height: 1 !important;
    white-space: nowrap !important;
    opacity: 0.85 !important;
}
/* Wenn Button NICHT aktiv ist: Pip in Blau */
.kc-quick-btn--popular:not(.kc-quick-btn--active) .kc-popular-pip {
    color: #3b82f6 !important;
    opacity: 1 !important;
}
/* Nach User-Interaktion: Beliebt-Badge ausblenden (kein irreführendes Highlight) */
.kc-quick-btn--no-badge .kc-popular-pip {
    display: none !important;
}
.kc-quick-btn--popular.kc-quick-btn--no-badge {
    flex-direction: row !important;
    gap: 0 !important;
    padding-bottom: 5px !important;
    padding-top: 5px !important;
}/* =====================================================================
   MOBILE: Kreditangebot Abstand zu Kreditdetails
   ===================================================================== */
@media (max-width: 767px) {
    .kc-equal-height-container > *:nth-child(2) {
        margin-top: 0 !important /* Browser-Agent Fix */;
    }
}

/* =====================================================================
   MOBILE: Anklickbare Raten im Rückzahlungsplan
   ===================================================================== */
@media (max-width: 767px) {

    /* Container */
    #kcMobileAmortizationList {
        border-radius: 14px;
        overflow: hidden;
        border: 1px solid #e5e7eb;
        box-shadow: 0 2px 8px rgba(0,0,0,0.06);
    }

    /* Raten-Zeile */
    .kc-amort-row {
        background: #fff;
        border-bottom: 1px solid #f1f5f9;
        cursor: pointer;
        transition: background 0.15s ease;
        -webkit-tap-highlight-color: transparent;
    }
    .kc-amort-row:last-child { border-bottom: none; }
    .kc-amort-row:active { background: #f8fafc; }

    /* Hauptzeile */
    .kc-amort-row-main {
        display: flex;
        align-items: center;
        padding: 13px 14px;
        gap: 10px;
    }

    .kc-amort-month {
        font-size: 0.82rem;
        font-weight: 700;
        color: #3b82f6 !important; /* v3.9: Blau */
        min-width: 52px;
    }

    .kc-amort-right {
        flex: 1;
        text-align: right;
    }

    .kc-amort-payment {
        font-size: 0.97rem;
        font-weight: 700;
        color: #1e293b;
    }

    .kc-amort-balance {
        font-size: 0.72rem;
        color: #94a3b8;
        margin-top: 2px;
    }

    /* Chevron-Pfeil */
    .kc-amort-chevron {
        font-size: 1.3rem;
        line-height: 1;
        color: #93c5fd;            /* Accent-Blau (heller) vor dem Öffnen */
        transition: transform 0.22s ease, color 0.15s ease;
        margin-left: 2px;
        user-select: none;
    }
    .kc-amort-row--open .kc-amort-chevron {
        transform: rotate(90deg);
        color: #3b82f6;
    }

    /* Detail-Bereich: max-height Animation */
    .kc-amort-detail {
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.32s cubic-bezier(0.4, 0, 0.2, 1);
        background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
    }

    /* Detail-Inhalt */
    .kc-detail-inner {
        padding: 10px 14px 14px 14px;
        display: flex;
        flex-direction: column;
        gap: 10px;
        border-top: 1px solid #e2e8f0;
    }

    .kc-detail-row {
        display: flex;
        align-items: center;
        gap: 10px;
    }

    .kc-detail-label {
        display: flex;
        align-items: center;
        gap: 6px;
        font-size: 0.76rem;
        font-weight: 600;
        color: #64748b;
        min-width: 68px;
        white-space: nowrap;
    }

    /* Farbige Punkte */
    .kc-dot {
        width: 8px;
        height: 8px;
        border-radius: 50%;
        display: inline-block;
        flex-shrink: 0;
    }
    .kc-dot--blue { background: #3b82f6; }
    .kc-dot--gold { background: #3b82f6; }

    .kc-detail-right { flex: 1; }

    /* Fortschrittsbalken */
    .kc-detail-bar {
        height: 5px;
        background: #e2e8f0;
        border-radius: 3px;
        overflow: hidden;
        margin-bottom: 5px;
    }

    .kc-detail-fill {
        height: 100%;
        border-radius: 3px;
        transition: width 0.45s ease;
    }
    .kc-detail-fill--blue { background: linear-gradient(90deg, #22c55e, #4ade80); }
    .kc-detail-fill--gold { background: linear-gradient(90deg, #3b82f6, #60a5fa); }

    .kc-detail-amount {
        font-size: 0.82rem;
        font-weight: 700;
        color: #1e293b;
    }
    .kc-detail-pct {
        font-weight: 400;
        color: #94a3b8;
        font-size: 0.74rem;
    }

    /* ── Mobile: Inline ⓘ neben Zinsteil-% – dynamischer Kreis-Button ── */
    .kc-amort-info-btn-inline {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        background: #eff6ff;
        border: 1.5px solid #93c5fd;
        border-radius: 50%;
        width: 18px;
        height: 18px;
        color: #3b82f6;
        font-size: 0.64rem;
        cursor: pointer;
        padding: 0;
        margin-left: 5px;
        vertical-align: middle;
        line-height: 1;
        flex-shrink: 0;
        transition: all 0.18s ease;
        -webkit-tap-highlight-color: transparent;
        animation: kcInfoPulse 2.5s ease-out 0.6s 2;
    }
    .kc-amort-info-btn-inline:active {
        background: #dbeafe;
        border-color: #3b82f6;
        transform: scale(1.18);


    }
}

/* ── Desktop: ⓘ neben "Zinsen" im Tabellen-Header ── */
.kc-amort-info-btn-th {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: #93c5fd;
    font-size: 0.78rem;
    cursor: pointer;
    padding: 0 0 0 4px;
    vertical-align: middle;
    line-height: 1;
    transition: color 0.2s ease, transform 0.15s ease;
}
.kc-amort-info-btn-th:hover {
    color: #3b82f6;
    transform: scale(1.15);
}
.kc-amort-info-btn-th:active {
    color: #1d4ed8;
}

/* =====================================================================
   AMORT INFO MODAL – SVG Diagramm + Tips + Dynamische Buttons
   ===================================================================== */

/* Modal-Content etwas breiter für Diagramm */
.kc-amort-modal-content {
    max-width: 440px !important;
}

@media (min-width: 768px) {
    .kc-amort-modal-content {
        max-width: 580px !important;
    }
}

/* Leo-Variante: kein eigenes Padding (Leo-Header übernimmt) */
.kc-amort-modal-content.kc-modal-leo {
    padding: 0 !important;
    border-radius: 20px !important;
    overflow: hidden;
}

/* Body-Wrapper */
.kc-amort-modal-body {
    padding: 18px 20px 16px;
}


/* SVG Diagramm-Container */
.kc-amort-diagram {
    background: #f8fafc;
    border-radius: 10px;
    padding: 8px 12px 7px 12px;
    margin-bottom: 12px;
    border: 1px solid #e2e8f0;
}

.kc-amort-svg {
    width: 100%;
    max-height: 62px;
    height: auto;
    display: block;
    margin-bottom: 5px;
}

/* Diagramm-Legende */
.kc-diag-legend {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.72rem;
    color: #64748b;
    justify-content: center;
}
.kc-diag-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: inline-block;
}
.kc-diag-dot--blue { background: #3b82f6; }
.kc-diag-dot--gold { background: #3b82f6; }

/* Tip-Karten */
.kc-amort-tips {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.kc-amort-tip {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #f8fafc;
    border-radius: 10px;
    padding: 10px 12px;
    border: 1px solid #e2e8f0;
}
.kc-amort-tip-icon {
    font-size: 1.1rem;
    line-height: 1.4;
    flex-shrink: 0;
}
.kc-amort-tip p {
    font-size: 0.82rem;
    line-height: 1.5;
    color: #475569;
    margin: 0;
}

/* ── Dynamische Info-Buttons (Desktop + Mobile) ── */

/* Puls-Keyframe */
@keyframes kcInfoPulse {
    0%   { box-shadow: 0 0 0 0 rgba(59,130,246,0.4); }
    70%  { box-shadow: 0 0 0 6px rgba(59,130,246,0); }
    100% { box-shadow: 0 0 0 0 rgba(59,130,246,0); }
}

/* Desktop: ⓘ im Zinsen-Header */
.kc-amort-info-btn-th {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #eff6ff;
    border: 1.5px solid #93c5fd;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    color: #3b82f6;
    font-size: 0.72rem;
    cursor: pointer;
    padding: 0;
    vertical-align: middle;
    margin-left: 5px;
    transition: all 0.2s ease;
    animation: kcInfoPulse 2.5s ease-out 1s 2;  /* 2x pulsieren nach Laden */
}
.kc-amort-info-btn-th:hover {
    background: #dbeafe;
    border-color: #3b82f6;
    color: #1d4ed8;
    transform: scale(1.18);
    box-shadow: 0 2px 8px rgba(59,130,246,0.3);
}
.kc-amort-info-btn-th:active {
    transform: scale(0.95);
}

/* Mobile: ⓘ inline im Zinsteil-Detail */
.kc-amort-info-btn-inline {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: #93c5fd;
    font-size: 0.78rem;
    cursor: pointer;
    padding: 0 0 0 5px;
    vertical-align: middle;
    line-height: 1;
    transition: color 0.15s ease, transform 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}
.kc-amort-info-btn-inline:active {
    color: #3b82f6;
    transform: scale(1.2);
}

/* =====================================================================
   MOBILE: Inline Amort-Info-Karte (kein dunkler Hintergrund!)
   ===================================================================== */
@media (max-width: 767px) {
    .kc-amort-inline-card {
        background: #fff;
        border-radius: 14px;
        border: 1px solid #e0ebff;
        box-shadow: 0 6px 24px rgba(59, 130, 246, 0.12), 0 2px 8px rgba(0,0,0,0.06);
        padding: 14px 14px 12px;
        margin-top: 4px;
        position: relative;
        max-height: 400px;
        overflow: hidden;
        opacity: 1;
        transition: opacity 0.2s ease, max-height 0.25s ease;
    }

    /* Close-Button oben rechts */
    .kc-aic-close {
        position: absolute;
        top: 8px;
        right: 10px;
        background: none;
        border: none;
        font-size: 1.1rem;
        color: #94a3b8;
        cursor: pointer;
        line-height: 1;
        padding: 2px 6px;
        transition: color 0.15s ease;
        -webkit-tap-highlight-color: transparent;
    }
    .kc-aic-close:active { color: #475569; }

    /* Titel */
    .kc-aic-title {
        font-size: 0.85rem;
        font-weight: 700;
        color: #1e293b;
        margin-bottom: 6px;
        padding-right: 24px;
    }

    /* Intro-Text */
    .kc-aic-intro {
        font-size: 0.76rem;
        color: #64748b;
        margin-bottom: 10px;
        line-height: 1.45;
    }

    /* Erklärungs-Reihen */
    .kc-aic-row {
        display: flex;
        align-items: flex-start;
        gap: 8px;
        padding: 8px 10px;
        background: #f8fafc;
        border-radius: 10px;
        margin-bottom: 6px;
        border: 1px solid #f1f5f9;
    }
    .kc-aic-row:last-child { margin-bottom: 0; }

    .kc-aic-icon {
        font-size: 1rem;
        line-height: 1.3;
        flex-shrink: 0;
    }

    .kc-aic-row div {
        font-size: 0.76rem;
        line-height: 1.45;
        color: #475569;
    }
    .kc-aic-row strong {
        color: #1e293b;
        display: block;
        margin-bottom: 1px;
    }
    .kc-aic-row span {
        color: #64748b;
    }
}

/* =====================================================================
   DESKTOP: Karten-Stil für Rückzahlungsübersicht (wie Mobile)
   ===================================================================== */

/* Container wie Mobile-Version aber für alle Grössen */
#kcMobileAmortizationList {
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #e5e7eb;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06);
}

.kc-amort-row {
    background: #fff;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
    transition: background 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}
.kc-amort-row:last-child { border-bottom: none; }
.kc-amort-row:hover { background: #fafcff; }
.kc-amort-row:active { background: #f0f6ff; }

/* ── Hauptzeile: GLOBAL – Flex für alle Geräte ── */
.kc-amort-row-main {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between;
    padding: 13px 14px;
    gap: 10px;
    cursor: pointer;
    transition: background 0.15s ease;
    -webkit-tap-highlight-color: transparent;
}
/* Linke Spalte: Rate-Nr + Fällig-Datum übereinander – GLOBAL */
.kc-amort-month-wrap {
    display: flex !important;
    flex-direction: column !important;
    gap: 2px;
    flex: 0 0 auto;
}
/* Rechte Spalte: CHF + Rest rechtsbündig – GLOBAL */
.kc-amort-right {
    flex: 1 !important;
    text-align: right !important;
    padding-right: 4px;  /* Kleiner Puffer zum Chevron */
    min-width: 0;        /* flex shrink erlauben */
}
/* Betrag gross */
.kc-amort-payment {
    font-size: 0.97rem;
    font-weight: 700;
    color: #1e293b;
    display: block;
    white-space: nowrap;   /* Nie umbrechen */
}
/* Restschuld klein */
.kc-amort-balance {
    font-size: 0.72rem;
    color: #94a3b8;
    display: block;
    white-space: nowrap;   /* Nie umbrechen */
}
/* Pfeil-Chevron – dezent blau, dynamisch */
.kc-amort-chevron {
    font-size: 1.2rem;
    color: #3b82f6;
    flex-shrink: 0;
    margin-left: 6px;
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1),
                color 0.2s ease,
                text-shadow 0.2s ease;
    opacity: 0.75;
}
.kc-amort-row:hover .kc-amort-chevron {
    color: #2563eb;
    opacity: 1;
    text-shadow: 0 0 8px rgba(59,130,246,0.35);
    transform: translateX(3px);   /* Leichtes Hervorspringen */
}
.kc-amort-row--open .kc-amort-chevron {
    transform: rotate(90deg);
    color: #2563eb;
    opacity: 1;
    text-shadow: 0 0 10px rgba(59,130,246,0.4);
}


@media (min-width: 768px) {
    .kc-amort-row-main {
        padding: 14px 20px;
        gap: 16px;
    }
    .kc-amort-month {
        font-size: 0.88rem;
        font-weight: 700;
        color: #3b82f6 !important; /* v3.9: Blau */
        min-width: 68px;
    }
    .kc-amort-payment {
        font-size: 1.05rem;
        font-weight: 700;
        color: #1e293b;
    }
    .kc-amort-balance {
        font-size: 0.78rem;
        color: #94a3b8;
        margin-top: 2px;
    }
    .kc-amort-chevron {
        font-size: 1.4rem;
        /* Farbe von global geerbt: #3b82f6 */
    }
    /* Desktop: Detail-Bereich breiter */
    .kc-detail-inner {
        padding: 12px 20px 16px 20px;
        flex-direction: row;
        gap: 24px;
    }
    .kc-detail-row {
        flex: 1;
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    .kc-detail-label {
        font-size: 0.8rem;
        min-width: unset;
    }
    .kc-detail-right { width: 100%; }
    .kc-detail-bar { height: 6px; }
    .kc-detail-amount { font-size: 0.9rem; }
}

/* ── Info-Button Ratenplan: als lesbarer Pill-Button (KEIN Kreis) ── */
.kc-amort-info-btn-th {
    width: auto !important;
    height: auto !important;
    border-radius: 20px !important;
    padding: 8px 20px !important;           /* mehr Rand */
    font-size: 0.72rem !important;
    font-weight: 700 !important;
    letter-spacing: 0.02em;
    white-space: nowrap !important;
    background: #dcfce7 !important;         /* Tilgungsgrün hell */
    border: 1.5px solid #22c55e !important;
    color: #15803d !important;              /* Dunkelgrün */
    gap: 5px;
    box-shadow: 0 3px 12px rgba(34,197,94,0.22) !important;
    animation: none !important;
}
.kc-amort-info-btn-th:hover {
    background: #bbf7d0 !important;
    border-color: #16a34a !important;
    color: #14532d !important;
    transform: none !important;
    box-shadow: 0 4px 16px rgba(34,197,94,0.35) !important;
}
.kc-amort-info-btn-th i,
.kc-amort-info-btn-th .fas {
    display: inline;
    line-height: 1;
    margin: 0;
    padding: 0;
    width: auto;
    text-align: unset;
}
/* Icon im runden Inline-Button: block für Zentrierung */
.kc-amort-info-btn-inline i,
.kc-amort-info-btn-inline .fas {
    display: block;
    line-height: 1;
    margin: 0;
    padding: 0;
    width: 100%;
    text-align: center;
}

/* Stärkere Akzentfarbe Mobile-Inline-Button */
@media (max-width: 767px) {
    .kc-amort-info-btn-inline {
        background: #dbeafe !important;
        border-color: #3b82f6 !important;
        color: #2563eb !important;
    }
    .kc-amort-info-btn-inline:active {
        background: #bfdbfe !important;
        border-color: #1d4ed8 !important;
        color: #1d4ed8 !important;
    }
}
/* Desktop version des inline buttons */
@media (min-width: 768px) {
    .kc-amort-info-btn-inline {
        display: inline-flex !important;
        align-items: center;
        justify-content: center;
        background: #dbeafe;
        border: 1.5px solid #3b82f6;
        border-radius: 50%;
        width: 20px;
        height: 20px;
        color: #2563eb;
        font-size: 0.7rem;
        cursor: pointer;
        padding: 0;
        margin-left: 6px;
        vertical-align: middle;
        line-height: 1;
        flex-shrink: 0;
        transition: none;
    }
    .kc-amort-info-btn-inline:hover,
    .kc-amort-info-btn-inline:active,
    .kc-amort-info-btn-inline:focus {
        transform: none !important;
        background: transparent !important;
        box-shadow: none !important;
    }
}

/* =====================================================================
   DESKTOP: Rückzahlungsübersicht – Zentrierung + Mobile-Stil 1:1
   ===================================================================== */

/* Amort-Karte auf Desktop zentrieren + max-width */
@media (min-width: 768px) {
    #kcAmortizationCard #kcMobileAmortizationList {
        max-width: 640px;
        margin: 0 auto;
    }

    /* Desktop: Detail-Bereich VERTIKAL wie Mobile (nicht side-by-side) */
    .kc-detail-inner {
        flex-direction: column !important;
        padding: 12px 20px 16px 20px;
        gap: 12px;
    }

    /* Desktop: Detail-Row identisch mit Mobile */
    .kc-detail-row {
        flex-direction: row !important;
        align-items: center;
        gap: 12px;
        flex: unset !important;
    }

    /* Desktop: Balken etwas dicker + Label breiter */
    .kc-detail-label {
        min-width: 76px !important;
        font-size: 0.82rem !important;
    }
    .kc-detail-bar { height: 7px !important; }
    .kc-detail-amount { font-size: 0.88rem !important; }

    /* Desktop: Raten-Hauptzeile mehr Luft */
    .kc-amort-row-main {
        padding: 15px 22px;
    }
    .kc-amort-month {
        min-width: 72px;
        font-size: 0.9rem;
        color: #3b82f6 !important; /* v3.9: Blau */
        font-weight: 700 !important;
    }
    .kc-amort-payment {
        font-size: 1.05rem;
    }
    .kc-amort-balance {
        font-size: 0.8rem;
    }

    /* Desktop: "Rate öffnen" Cursor + hover-Highlight auf der Hauptzeile */
    .kc-amort-row-main {
        cursor: pointer;
        transition: background 0.15s ease;
        border-radius: 4px;
    }

    /* Hintergrundfarbe des gesamten #kcMobileAmortizationList auf Desktop */
    #kcMobileAmortizationList {
        border-radius: 16px;
        overflow: hidden;
        border: 1px solid #e2e8f0;
        box-shadow: 0 4px 16px rgba(0,0,0,0.07);
    }

    /* Trennlinie zwischen Raten auf Desktop */
    .kc-amort-row {
        border-bottom: 1px solid #f0f4f8;
    }
    .kc-amort-row:last-child { border-bottom: none; }

    /* Chevron auf Desktop: stärkere Farbe */
    .kc-amort-chevron {
        font-size: 1.4rem !important;
        color: #60a5fa !important;
    }
    .kc-amort-row--open .kc-amort-chevron {
        transform: rotate(90deg);
        color: #2563eb !important;
    }
}

/* =====================================================================
   RÜCKZAHLUNGSÜBERSICHT: Titel zentriert + Fälligkeitsdatum-Styling
   ===================================================================== */

/* Punkt 1: Titel zentrieren */
#kcAmortizationCard > div > h2 {
    text-align: center;
    width: 100%;
}

/* Punkt 4: Fälligkeitsdatum in geschlossener Rate */
.kc-amort-due {
    font-size: 0.68rem;
    color: #60a5fa;
    font-weight: 500;
    margin-top: 2px;
    white-space: nowrap;
    letter-spacing: 0.01em;
}

@media (min-width: 768px) {
    .kc-amort-due {
        font-size: 0.72rem;
        color: #3b82f6;
    }
}

/* Fälligkeitsdatum ausblenden wenn die Rate geöffnet ist */
.kc-amort-row--open .kc-amort-due {
    display: none;
}

/* =====================================================================
   DESKTOP: Rückzahlungsübersicht – Mobile-Look, volle Breite (FINAL)
   ===================================================================== */
@media (min-width: 768px) {

    /* Container: volle Breite nutzen, kein max-width */
    #kcAmortizationCard #kcMobileAmortizationList {
        max-width: 100% !important;
        margin: 0 !important;
        border-radius: 14px !important;
        border: 1px solid #e2e8f0 !important;
        box-shadow: 0 4px 20px rgba(0,0,0,0.07) !important;
        overflow: hidden !important;
    }

    /* ── Hauptzeile: horizontal, volle Breite – wie Mobile ── */
    .kc-amort-row-main {
        display: flex !important;
        align-items: center !important;
        padding: 17px 28px !important;
        gap: 0 !important;
        cursor: pointer;
        transition: background 0.15s ease;
    }
    .kc-amort-row:hover .kc-amort-row-main {
        background: #f8fafc;
    }

    /* Links: Rate-Nr (+ ev. Fällig-Datum darunter) */
    .kc-amort-month {
        flex: 0 0 auto !important;
        min-width: 70px !important;
        font-size: 0.88rem !important;
        font-weight: 700 !important;
        color: #3b82f6 !important; /* v3.9: Blau */
    }

    /* Rechts: Betrag gross + Rest klein + Fällig blau */
    .kc-amort-right {
        flex: 1 !important;
        display: flex !important;
        flex-direction: column !important;
        align-items: flex-end !important;
        gap: 0 !important;
    }
    .kc-amort-payment {
        font-size: 1.05rem !important;
        font-weight: 700 !important;
        color: #1e293b !important;
        text-align: right;
    }
    .kc-amort-balance {
        font-size: 0.76rem !important;
        color: #94a3b8 !important;
        margin-top: 1px;
        text-align: right;
    }
    .kc-amort-due {
        font-size: 0.71rem !important;
        color: #60a5fa !important;
        margin-top: 1px;
        text-align: right;
        letter-spacing: 0.01em;
    }

    /* Chevron: ganz rechts */
    .kc-amort-chevron {
        flex: 0 0 auto !important;
        margin-left: 18px !important;
        font-size: 1.4rem !important;
        color: #93c5fd !important;
        transition: transform 0.22s ease, color 0.15s ease;
    }
    .kc-amort-row--open .kc-amort-chevron {
        transform: rotate(90deg);
        color: #3b82f6 !important;
    }

    /* Trennlinie */
    .kc-amort-row {
        border-bottom: 1px solid #f1f5f9 !important;
    }
    .kc-amort-row:last-child { border-bottom: none !important; }

    /* ── Detail-Bereich: VERTIKAL wie Mobile ── */
    .kc-detail-inner {
        flex-direction: column !important;
        padding: 8px 28px 18px 28px !important;
        gap: 10px !important;
    }
    .kc-detail-row {
        flex-direction: row !important;
        align-items: center !important;
        flex: unset !important;
        gap: 12px;
    }
    .kc-detail-label {
        min-width: 80px !important;
        font-size: 0.82rem !important;
    }
    .kc-detail-right { flex: 1; }
    .kc-detail-bar { height: 7px !important; }
    .kc-detail-amount { font-size: 0.88rem !important; margin-top: 3px; }
}

/* =====================================================================
   kc-amort-month-wrap: Rate-Nr + Fällig links – Mobile & Desktop
   ===================================================================== */

/* Wrapper für Rate-Nummer + Fällig (linke Spalte) */
.kc-amort-month-wrap {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 0 0 auto;
}

/* Mobile: min-width kleiner */
@media (max-width: 767px) {
    .kc-amort-month-wrap {
        min-width: 80px;
    }
    .kc-amort-due {
        font-size: 0.66rem;
        color: #1e293b;        /* Schwarz/Dunkelgrau */
        font-weight: 400;
        white-space: nowrap;
    }
}

/* Desktop: etwas breiter */
@media (min-width: 768px) {
    .kc-amort-month-wrap {
        min-width: 110px;
    }
    .kc-amort-due {
        font-size: 0.7rem !important;
        color: #1e293b !important;     /* Schwarz/Dunkelgrau */
        font-weight: 400;
        white-space: nowrap;
        text-align: left !important;
    }
}

/* Fällig-Datum ausblenden wenn Rate geöffnet */
.kc-amort-row--open .kc-amort-due {
    display: none;
}

/* =====================================================================
   DETAIL-BARS: Global (Mobile + Desktop) – Tilgung/Zinsteil Grafik
   ===================================================================== */

/* Detail-Bereich aufklappen */
.kc-amort-row--open .kc-amort-detail {
    max-height: none;
    transition: max-height 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ── Kombinierter Balken ── */
.kc-combined-bar-wrap {
    padding: 12px 14px 14px;
    border-top: 1px solid #e2e8f0;
}

/* Animation: Balken von links nach rechts einfahren */
@keyframes kcBarReveal {
    from {
        transform: scaleX(0);
        opacity: 0.4;
    }
    to {
        transform: scaleX(1);
        opacity: 1;
    }
}

/* Prozente über dem Balken */
.kc-combined-pct-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 3px;
}
.kc-pct-gold {
    font-size: 0.68rem;
    font-weight: 600;
    color: #f59e0b;
}
.kc-pct-blue {
    font-size: 0.68rem;
    font-weight: 600;
    color: #3b82f6;
}

/* Der Balken selbst: flex, nebeneinander */
.kc-combined-bar {
    display: flex;
    height: 10px;
    border-radius: 6px;
    overflow: hidden;
    background: #e2e8f0;
    margin-top: 0;
    margin-bottom: 10px;           /* Abstand zu den Labels darunter */
    gap: 0;
    transform-origin: left center;
    animation: kcBarReveal 0.55s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

.kc-combined-fill {
    height: 100%;
    transition: width 0.45s ease;
    flex-shrink: 0;
}
.kc-combined-fill--gold { background: linear-gradient(90deg, #3b82f6, #60a5fa); }
.kc-combined-fill--blue { background: linear-gradient(90deg, #22c55e, #4ade80); }

/* Labels: links Zinsteil, rechts Tilgung – ÜBER dem Balken */
.kc-combined-labels {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 6px;
    /* kein margin-bottom: Balken kommt darunter via margin-top */
}

.kc-combined-label-left,
.kc-combined-label-right {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.74rem;
    color: #475569;
    flex-wrap: nowrap;
    white-space: nowrap;
}

/* Linke Seite (Zinsteil) ist klickbar – grösseres Touch-Target */
.kc-combined-label-left {
    cursor: pointer;
    padding: 6px 8px 6px 0;
    min-height: 36px;
    border-radius: 6px;
    transition: opacity 0.15s ease;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
}
.kc-combined-label-left:active {
    opacity: 0.7;
}

.kc-clabel-text {
    font-weight: 600;
    color: #1e293b;
}

.kc-clabel-val {
    font-weight: 700;
    color: #1e293b;
}


/* Wrapper innerer Inhalt */
.kc-detail-inner {
    padding: 6px 16px 14px 16px;
    display: flex !important;
    flex-direction: column !important;
    gap: 10px;
    border-top: 1px solid #e2e8f0;
    background: linear-gradient(180deg, #f8fafc 0%, #fff 100%);
}

/* Eine Zeile Tilgung oder Zinsteil */
.kc-detail-row {
    display: flex !important;
    align-items: center !important;
    gap: 10px;
}

/* Label: Punkt + Name */
.kc-detail-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    color: #475569;
    min-width: 72px;
    flex-shrink: 0;
}

/* Rechte Seite: Bar + Betrag */
.kc-detail-right {
    flex: 1;
    min-width: 0;
}

/* Farbpunkt */
.kc-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
    display: inline-block;
}
.kc-dot--blue { background: #3b82f6; }
.kc-dot--gold { background: #3b82f6; }

/* Fortschrittsbalken-Spur */
.kc-detail-bar {
    height: 6px;
    background: #e2e8f0;
    border-radius: 99px;
    overflow: hidden;
    width: 100%;
}

/* Gefüllter Anteil */
.kc-detail-fill {
    height: 100%;
    border-radius: 99px;
    transition: width 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.kc-detail-fill--blue { background: linear-gradient(90deg, #22c55e, #4ade80); }
.kc-detail-fill--gold { background: linear-gradient(90deg, #3b82f6, #60a5fa); }

/* Betrag + % unter dem Balken */
.kc-detail-amount {
    font-size: 0.82rem;
    font-weight: 700;
    color: #1e293b;
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}
.kc-detail-pct {
    font-weight: 400;
    color: #64748b;
    font-size: 0.78rem;
}

/* Desktop: etwas mehr Padding */
@media (min-width: 768px) {
    .kc-detail-inner {
        padding: 8px 28px 16px 28px !important;
        gap: 12px;
    }
    .kc-detail-bar { height: 7px !important; }
    .kc-detail-label { min-width: 82px; }
    .kc-amort-row--open .kc-amort-detail {
        max-height: none;
    }
}

/* =====================================================================
   FIX: kc-amort-detail Basis-State GLOBAL (max-height: 0 für Desktop)
   ===================================================================== */
.kc-amort-detail {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.32s cubic-bezier(0.4, 0, 0.2, 1);
}
/* Geöffnet: max-height freigeben (override) */
.kc-amort-row--open .kc-amort-detail {
    max-height: none;
}

/* =====================================================================
   DESKTOP: Inline-Info-Karte im Ratenplan (kein Modal, kein Overlay)
   ===================================================================== */
@media (min-width: 768px) {
    .kc-amort-inline-card {
        background: #fff;
        border-radius: 14px;
        border: 1px solid #e0ebff;
        box-shadow: 0 8px 32px rgba(59, 130, 246, 0.14), 0 2px 10px rgba(0,0,0,0.07);
        padding: 18px 20px 16px;
        margin-top: 6px;
        position: relative;
        opacity: 1;
        transition: opacity 0.2s ease, max-height 0.25s ease;
        overflow: hidden;
    }

    /* Leo-Variante: kein eigenes Padding (Header übernimmt) */
    .kc-amort-inline-card--leo {
        padding: 0;
        border-radius: 16px;
    }

    /* Body-Wrapper für Leo-Variante */
    .kc-amort-inline-card--leo .kc-aic-body {
        padding: 14px 18px 16px;
    }

    /* ── Infobox 2 (Amort Modal) – scoped, wie Infobox 1 ── */
    .kc-leo-header--sm {
        min-height: 76px;
        padding: 10px 12px 0 14px;
        border-radius: 16px 16px 0 0;
    }
    /* Close-Button im kompakten Header */
    .kc-leo-header--sm .kc-close-modal {
        margin-top: 8px !important;
        font-size: 18px !important;
        padding: 4px 8px !important;
    }

    #kcAmortInfoModal .kc-leo-header--sm {
        min-height: 108px !important;
        padding: 10px 10px 0 12px !important;
        gap: 10px !important;
    }

    #kcAmortInfoModal .kc-leo-mascot-wrap--sm {
        width: 100px !important;
        margin-bottom: -14px !important;
    }

    #kcAmortInfoModal .kc-leo-img--sm {
        width: 100px !important;
        border-radius: 14px 14px 0 0 !important;
    }

    #kcAmortInfoModal .kc-leo-header-text {
        padding: 10px 0 12px 3px !important;
        gap: 3px !important;
        min-width: 0 !important;
        flex: 1 !important;
        overflow: hidden !important;
    }

    #kcAmortInfoModal .kc-leo-badge {
        font-size: 0.52rem !important;
        padding: 2px 7px !important;
        margin-bottom: 4px !important;
        margin-top: 0 !important;
        letter-spacing: 0.05em !important;
        white-space: nowrap !important;
        line-height: 1.3 !important;
    }

    #kcAmortInfoModal .kc-leo-title {
        font-size: 0.88rem !important;
        line-height: 1.3 !important;
        padding-right: 26px !important;
        white-space: normal !important;      /* Umbruch erlaubt */
        word-break: normal !important;       /* KEIN Umbruch mitten im Wort */
        overflow-wrap: normal !important;    /* KEIN Umbruch mitten im Wort */
        overflow: visible !important;
    }

    .kc-leo-mascot-wrap--sm {
        width: 72px;
        margin-bottom: -14px;
    }
    .kc-leo-img--sm {
        width: 72px !important;
        border-radius: 12px 12px 0 0;
    }

    /* Schliessen-Button (Inline-Karte Standard) */
    .kc-amort-inline-card .kc-aic-close {
        position: absolute;
        top: 10px;
        right: 14px;
        background: none;
        border: none;
        font-size: 1.1rem;
        color: #94a3b8;
        cursor: pointer;
        padding: 2px 6px;
        transition: color 0.15s ease;
        line-height: 1;
    }
    .kc-amort-inline-card .kc-aic-close:hover { color: #475569; }

    /* Schliessen-Button in Leo-Variante (weiss, im Header) */
    .kc-amort-inline-card--leo .kc-close-modal.kc-aic-close {
        position: relative;
        top: auto;
        right: auto;
        margin-top: 10px;
        background: rgba(255,255,255,0.15);
        border: 1px solid rgba(255,255,255,0.3);
        border-radius: 7px;
        color: #ffffff;
        font-size: 1rem;
        padding: 4px 7px;
        flex-shrink: 0;
        align-self: flex-start;
        cursor: pointer;
        transition: background 0.2s ease, transform 0.2s ease;
    }
    .kc-amort-inline-card--leo .kc-close-modal.kc-aic-close:hover {
        background: rgba(255,255,255,0.28);
        transform: rotate(90deg);
    }



    /* Titel */
    .kc-amort-inline-card .kc-aic-title {
        font-size: 0.92rem;
        font-weight: 700;
        color: #1e293b;
        margin-bottom: 6px;
        padding-right: 28px;
    }

    /* Intro */
    .kc-amort-inline-card .kc-aic-intro {
        font-size: 0.79rem;
        color: #64748b;
        margin-bottom: 12px;
        line-height: 1.5;
    }

    /* Erklärungszeilen */
    .kc-amort-inline-card .kc-aic-row {
        display: flex;
        align-items: flex-start;
        gap: 8px;
        padding: 8px 10px;
        background: #f8fafc;
        border-radius: 8px;
        margin-bottom: 8px;
        border: 1px solid #f1f5f9;
    }
    .kc-amort-inline-card .kc-aic-row:last-child { margin-bottom: 0; }
    .kc-amort-inline-card .kc-aic-icon { font-size: 1.1rem; flex-shrink: 0; line-height: 1.4; }
    .kc-amort-inline-card .kc-aic-row div { font-size: 0.79rem; line-height: 1.4; color: #475569; }
    .kc-amort-inline-card .kc-aic-row strong { display: block; margin-bottom: 0; }
    .kc-amort-inline-card .kc-aic-row span { color: #64748b; }
}

/* =====================================================================
   DESKTOP: Geöffnete Rate – verbessertes Layout der Detail-Ansicht
   ===================================================================== */
@media (min-width: 768px) {
    /* Detail-Bereich: mehr Padding, klarer getrennt */
    .kc-detail-inner {
        padding: 16px 32px 20px 32px !important;
        gap: 14px !important;
        background: linear-gradient(180deg, #f8fafc 0%, #fafbff 100%) !important;
        border-top: 1.5px solid #e0e7ff !important;
    }

    /* Label: grösser, klarer */
    .kc-detail-label {
        min-width: 90px !important;
        font-size: 0.84rem !important;
        font-weight: 700 !important;
        color: #334155 !important;
        gap: 8px;
    }

    /* Dot etwas grösser */
    .kc-detail-label .kc-dot {
        width: 10px;
        height: 10px;
    }

    /* Balken dicker auf Desktop */
    .kc-detail-bar {
        height: 9px !important;
        border-radius: 99px;
        box-shadow: inset 0 1px 3px rgba(0,0,0,0.08);
    }

    /* Betrag: grösser, mehr Abstand zum Balken */
    .kc-detail-amount {
        font-size: 0.95rem !important;
        margin-top: 5px !important;
        letter-spacing: -0.01em;
    }
    .kc-detail-pct {
        font-size: 0.82rem !important;
    }

    /* Inline-Karte: mehr padding, schönere Ränder */
    .kc-amort-inline-card {
        margin-top: 14px !important;
        padding: 20px 24px 18px !important;
        border-radius: 16px !important;
    }
    .kc-amort-inline-card .kc-aic-title {
        font-size: 0.95rem !important;
    }
    .kc-amort-inline-card .kc-aic-row {
        padding: 12px 14px !important;
        gap: 12px !important;
    }
}

/* =====================================================================
   SMART TIP & MAX-HEIGHT FIX – Mobile + Desktop
   ===================================================================== */

/* Smart Tip: Vorteil-Nachricht in der Info-Karte */
.kc-aic-tip {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    background: linear-gradient(135deg, #eff6ff 0%, #f0fdf4 100%);
    border: 1px solid #bfdbfe;
    border-radius: 8px;
    padding: 8px 12px;
    margin-top: 6px;
    font-size: 0.78rem;
    color: #1e40af;
    line-height: 1.45;
}
.kc-aic-tip-icon {
    font-size: 1rem;
    flex-shrink: 0;
    line-height: 1.4;
}
.kc-aic-tip strong {
    color: #1e3a8a;
    font-weight: 700;
    display: inline;
}

@media (min-width: 768px) {
    .kc-aic-tip {
        font-size: 0.82rem;
        padding: 13px 16px;
        margin-top: 12px;
    }

    /* Detail-Section: keine CSS max-height Beschränkung auf Desktop
       JS steuert die Höhe dynamisch via element.style.maxHeight */
    .kc-amort-row--open .kc-amort-detail {
        max-height: none !important; /* JS übernimmt via style.maxHeight */
    }
}

/* =====================================================================
   INFO-BOX CTA: Dezenter "Offerte anfragen" Button – Mobile + Desktop
   ===================================================================== */
.kc-aic-cta-wrap {
    margin-top: 8px;
    text-align: center;
}

.kc-aic-cta-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 9px 20px;
    border-radius: 99px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    text-decoration: none;
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
    color: #fff !important;
    border: none;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.2s ease;
    box-shadow: 0 4px 14px rgba(59, 130, 246, 0.35);
}

.kc-aic-cta-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.45);
    background: linear-gradient(135deg, #1d4ed8 0%, #2563eb 100%);
    color: #fff !important;
    text-decoration: none;
}

.kc-aic-cta-btn i {
    font-size: 0.75rem;
    transition: transform 0.15s ease;
}
.kc-aic-cta-btn:hover i {
    transform: translateX(3px);
}

@media (min-width: 768px) {
    .kc-aic-cta-btn {
        font-size: 0.8rem;
        padding: 10px 24px;
    }
}

/* =====================================================================
   FIX 1: CTA-Button Text immer lesbar (auch nach Klick / :visited)
   ===================================================================== */
#calculateBtn,
#calculateBtn:link,
#calculateBtn:visited,
#calculateBtn:active {
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.85) !important;
    background: transparent !important;
    text-decoration: none !important;
}
#calculateBtn:hover,
#calculateBtn:focus {
    color: #1d4ed8 !important;
    background: #ffffff !important;
    border-color: #ffffff !important;
}

/* =====================================================================
   FIX 2: ⓘ Info-Button – korrekte Zentrierung (Shadow + Icon mittig)
   ===================================================================== */
.kc-amort-info-btn-inline {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    vertical-align: middle !important;
    line-height: 1 !important;
    /* Kein extra padding – Icon bleibt mittig */
    padding: 0 !important;
    /* Gleiche Grösse oben/unten */
    width: 20px !important;
    height: 20px !important;
    /* Shadow zentriert: spread-radius gleich auf allen Seiten */
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12);
    /* Kein asymmetrischer margin-bottom */
    margin-left: 5px !important;
    margin-bottom: 0 !important;
    position: relative;
    top: -1px; /* optische Ausrichtung mit Texthöhe */
}

/* =====================================================================
   FIX 3: Mobile Info-Karte scrollbar + mehr sichtbarer Inhalt
   ===================================================================== */
@media (max-width: 767px) {
    .kc-amort-inline-card {
        max-height: 70vh !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
        /* Scrollbar dezent */
        scrollbar-width: thin;
        scrollbar-color: #93c5fd transparent;
    }
    /* max-height des Detail-Bereichs beim Öffnen der Info-Karte grosszügig */
    .kc-amort-row--open .kc-amort-detail {
        max-height: 85vh !important;
    }
}

/* =====================================================================
   Widget Entry Animation – Zoom-in beim Seitenladen
   ===================================================================== */
@keyframes kc-widget-zoom-in {
    from { opacity: 0; transform: scale(0.95); }
    to   { opacity: 1; transform: scale(1); }
}

.kc-widget-hidden {
    opacity: 0;
    transform: scale(0.95);
    transition: none;
}

.kc-widget-enter,
.kc-widget-enter-left,
.kc-widget-enter-right {
    animation: kc-widget-zoom-in 0.8s ease-out forwards;
}
.kc-widget-fade-in {
    animation: kc-widget-fade-in 1.1s ease-out forwards;
}

@keyframes kc-widget-fade-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ── Mobile: Widget-Einblend-Animation deaktiviert (verhindert Störung) ── */
@media (max-width: 600px) {
    .kc-widget-hidden {
        opacity: 1 !important;
        transform: none !important;
    }
    .kc-widget-enter,
    .kc-widget-enter-left,
    .kc-widget-enter-right,
    .kc-widget-fade-in {
        animation: none !important;
        opacity: 1 !important;
        transform: none !important;
    }
}

/* =====================================================================
   Rate Spotlight – Rate 1→2→3 sequenziell hervorheben
   ===================================================================== */
@keyframes kc-rate-spotlight {
    0%   {
        background: transparent;
        box-shadow: none;
        transform: translateX(0);
    }
    18%, 75% {
        background: linear-gradient(90deg, rgba(34,197,94,0.10) 0%, rgba(220,252,231,0.04) 100%); /* v3.9: Grün */
        box-shadow: inset 3px 0 0 #22c55e, 0 4px 18px rgba(34,197,94,0.22); /* v3.9: Grün */
        transform: translateX(3px);
        border-radius: 8px;
    }
    100% {
        background: transparent;
        box-shadow: none;
        transform: translateX(0);
    }
}

.kc-rate-spotlight {
    animation: kc-rate-spotlight 1.1s ease-in-out forwards;
}

/* ═══════════════════════════════════════════════════════════════════════════
   MOBILE OPTIMIERUNG – Leo Info-Boxen (beide Modals)
   Ziel: sauberes Layout, korrekte Textumbrüche, angepasste Abstände
   ═══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 767px) {

    /* ── Infobox 1 (Zinssatz Modal) – scoped, andere Infoboxen unverändert ── */
    #kcInfoModal .kc-leo-header {
        min-height: 120px !important;
        padding: 10px 10px 0 12px !important;
        gap: 10px !important;
        align-items: flex-start !important;
    }

    #kcInfoModal .kc-leo-mascot-wrap {
        width: 115px !important;
        margin-bottom: -16px !important;
        flex-shrink: 0 !important;
    }

    #kcInfoModal .kc-leo-img {
        width: 115px !important;
        border-radius: 16px 16px 0 0 !important;
    }

    #kcInfoModal .kc-leo-header-text {
        padding: 10px 0 12px 3px !important;   /* 3px statt 6px: weniger Abstand zum Bild */
        gap: 3px !important;
        min-width: 0 !important;
        flex: 1 !important;
        overflow: hidden !important;
    }

    /* Leo Name: eine Zeile, kein Umbruch */
    #kcInfoModal .kc-leo-name {
        font-size: 1.55rem !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
        margin-bottom: 1px !important;
    }

    /* Badge: eine Zeile, kein Umbruch */
    #kcInfoModal .kc-leo-badge {
        font-size: 0.5rem !important;
        padding: 2px 7px !important;
        margin-bottom: 4px !important;
        margin-top: 0 !important;
        letter-spacing: 0.05em !important;
        white-space: nowrap !important;
        line-height: 1.3 !important;
        overflow: hidden !important;
    }

    /* Titel: eine Zeile, kein Umbruch */
    #kcInfoModal .kc-leo-title {
        font-size: 0.88rem !important;
        line-height: 1.2 !important;
        padding-right: 26px !important;
        white-space: nowrap !important;
        overflow: hidden !important;
        text-overflow: ellipsis !important;
    }

    /* X-Button auf Mobile */
    .kc-modal-leo .kc-close-modal,
    .kc-leo-header .kc-close-modal {
        font-size: 18px !important;
        padding: 4px 7px !important;
        margin-top: 10px !important;
        border-radius: 7px !important;
        flex-shrink: 0 !important;
    }

    /* ── Leo Modal Body (Zinssatz Modal) ── */
    .kc-leo-intro-box {
        margin: 14px 14px 10px 14px !important;
        padding: 11px 12px !important;
        border-radius: 0 10px 10px 0 !important;
    }

    .kc-leo-intro-text {
        font-size: 0.82rem !important;
        line-height: 1.55 !important;
    }

    .kc-modal-leo .kc-modal-row {
        padding: 8px 14px !important;
        gap: 10px !important;
    }

    .kc-modal-leo .kc-modal-paragraph {
        font-size: 0.82rem !important;
        line-height: 1.55 !important;
    }

    /* Farbige Icon-Badges kleiner auf Mobile */
    .kc-ico {
        width: 26px !important;
        height: 26px !important;
        font-size: 0.75rem !important;
        border-radius: 7px !important;
        flex-shrink: 0 !important;
    }

    /* Versprechen-Box */
    .kc-modal-row--promise {
        margin: 6px 14px 14px 14px !important;
        padding: 10px 12px !important;
        border-radius: 10px !important;
    }

    /* ── CTA Button (Offerte anfragen) ── */
    .kc-aic-cta-wrap {
        padding: 0 14px 14px !important;
    }

    .kc-aic-cta-btn {
        font-size: 0.82rem !important;
        padding: 11px 18px !important;
        border-radius: 10px !important;
        width: 100% !important;
        justify-content: center !important;
    }

    /* ── Amort Modal (Kreditzins Modal) Body ── */
    .kc-amort-modal-body {
        padding: 12px 14px 14px !important;
    }

    .kc-amort-modal-content.kc-modal-leo {
        border-radius: 18px !important;
    }

    /* SVG Diagramm noch kompakter auf Mobile */
    .kc-amort-diagram {
        padding: 6px 10px 6px 10px !important;
        margin-bottom: 10px !important;
    }

    .kc-amort-svg {
        max-height: 55px !important;
        margin-bottom: 4px !important;
    }

    .kc-diag-legend {
        font-size: 0.66rem !important;
        gap: 8px !important;
    }

    /* Amort Tips kompakter */
    .kc-amort-tips {
        gap: 7px !important;
    }

    .kc-amort-tip {
        padding: 8px 10px !important;
        gap: 8px !important;
        font-size: 0.8rem !important;
        line-height: 1.45 !important;
        border-radius: 9px !important;
    }

    .kc-amort-tip-icon {
        font-size: 0.95rem !important;
    }

    /* Paragraph über SVG */
    .kc-modal-paragraph {
        font-size: 0.82rem !important;
        line-height: 1.5 !important;
    }

    /* Modal-Breite volle Breite auf Mobile */
    .kc-modal-leo {
        max-width: 100% !important;
        width: 100% !important;
        margin: 0 !important;
        border-radius: 18px !important;
    }
}

/* ═══ Zins-Modal: Header-Radius = Card-Radius (Mobile: 18px, Desktop: 20px) ═════ */
@media (max-width: 992px) {
    .kc-zins-modal .kc-leo-header {
        border-radius: 18px 18px 0 0 !important;  /* matcht Card-Radius auf Mobile */
    }
    .kc-zins-modal .kc-modal-leo {
        border-radius: 18px !important;
        overflow: hidden !important;
    }
}

/* Mobile: Infobox 2 (#kcAmortInfoModal) – gleicher Header-Stil wie Infobox 1 */
@media (max-width: 767px) {
    #kcAmortInfoModal .kc-leo-header--sm {
        min-height: 108px !important;
        padding: 10px 10px 0 12px !important;
        gap: 10px !important;
        align-items: flex-start !important;
    }
    #kcAmortInfoModal .kc-leo-mascot-wrap--sm {
        width: 100px !important;
        margin-bottom: -14px !important;
        flex-shrink: 0 !important;
    }
    #kcAmortInfoModal .kc-leo-img--sm {
        width: 100px !important;
        border-radius: 14px 14px 0 0 !important;
    }
    #kcAmortInfoModal .kc-leo-header-text {
        padding: 10px 0 12px 3px !important;
        gap: 3px !important;
        min-width: 0 !important;
        flex: 1 !important;
        overflow: hidden !important;
    }
    #kcAmortInfoModal .kc-leo-badge {
        font-size: 0.5rem !important;
        padding: 2px 7px !important;
        margin-bottom: 4px !important;
        margin-top: 0 !important;
        letter-spacing: 0.05em !important;
        white-space: nowrap !important;
        line-height: 1.3 !important;
    }
    #kcAmortInfoModal .kc-leo-title {
        font-size: 0.88rem !important;
        line-height: 1.2 !important;
        padding-right: 26px !important;
        white-space: normal !important;
        word-break: normal !important;
    }
}

/* Desktop: Infobox 1 Titel-Layout wie Infobox 2 */
@media (min-width: 768px) {
    #kcInfoModal .kc-leo-title {
        font-size: 0.88rem !important;
        line-height: 1.3 !important;
        padding-right: 26px !important;
        white-space: normal !important;
        word-break: normal !important;
    }
}

/* Desktop ONLY: Infobox 1 (#kcInfoModal) Header – Leo unten leicht abgeschnitten */
@media (min-width: 768px) {
    #kcInfoModal .kc-leo-header {
        min-height: 128px !important;
        height: 128px !important;
    }
    /* Leo: oben ausgerichtet, endet bei 123px -> 5px unten geclipt */
    #kcInfoModal .kc-leo-mascot-wrap {
        align-self: flex-start !important;
        margin-bottom: 0 !important;
        margin-top: 8px !important;
    }
    /* Text: Platz oben und unten */
    #kcInfoModal .kc-leo-header-text {
        padding-top: 12px !important;
        padding-bottom: 10px !important;
    }
}

/* PDF Download Button (v3.4.0) */
.kc-pdf-btn {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 7px; width: 100%; padding: 13px 22px;
    background: transparent; color: #ffffff;
    border: 2px solid rgba(255,255,255,0.85); border-radius: 5px;
    font-size: 0.8rem; font-weight: 600; letter-spacing: 0.09em;
    text-transform: uppercase; cursor: pointer; margin-top: 8px;
    transition: background 0.22s, color 0.22s, border-color 0.22s, transform 0.18s, box-shadow 0.22s;
    position: relative; overflow: hidden;
}
.kc-pdf-btn::before {
    content: ""; position: absolute; top: 0; left: 0;
    width: 45%; height: 100%;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.35) 50%, transparent 100%);
    animation: kc-btn-shimmer 3.5s ease-in-out infinite; pointer-events: none;
}
.kc-pdf-btn:hover {
    background: #ffffff; color: #1d4ed8;
    border-color: #ffffff;
    transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0,0,0,0.18);
}
.kc-pdf-btn:active { transform: translateY(0); color: #1d4ed8; }
.kc-pdf-btn.kc-pdf-loading { opacity: 0.7; cursor: wait; pointer-events: none; }

/* ── PDF Login Modal: Mobile Bottom-Sheet Overlay ──────────────────────────
 * Vorher: position:static (inline) → nachfolgender Seiteninhalt überlappt Modal.
 * Jetzt:  position:fixed Bottom-Sheet → liegt über allem, keine Überlappung möglich.
 * Backdrop: halbtransparent schwarz (wie Desktop-Overlay).
 * ─────────────────────────────────────────────────────────────────────────── */
@media(max-width:767px){
  #kcPdfLoginModal{
    position:fixed!important;
    inset:0!important;
    z-index:1000000!important;
    padding:0!important;
    background:rgba(0,0,0,.55)!important;
    display:none!important;
    width:100%!important;
    height:100%!important;
    overflow:hidden!important;
    flex-direction:column!important;
    align-items:stretch!important;
    justify-content:flex-end!important;  /* Bottom-Sheet: Karte von unten */
    margin-top:0!important;
    backdrop-filter:blur(3px)!important;
    -webkit-backdrop-filter:blur(3px)!important;
  }
  #kcPdfLoginModal[style*="flex"]{
    display:flex!important;
  }
  #kcPdfLoginModal .kc-modal-leo{
    width:100%!important;
    max-width:100%!important;
    max-height:92dvh!important;
    max-height:92vh!important;
    overflow-y:auto!important;
    -webkit-overflow-scrolling:touch!important;
    margin:0!important;
    border-radius:22px 22px 0 0!important;  /* Oben abgerundet, unten flach */
    box-shadow:0 -8px 40px rgba(0,0,0,.30),0 -2px 12px rgba(37,99,235,.15)!important;
    animation:kcSlideUpSheet .35s cubic-bezier(.34,1.1,.64,1) both!important;
  }
  #kcPdfLoginModal .kc-leo-header{
    border-radius:22px 22px 0 0!important;
  }
  /* Backdrop-Klick schliesst Modal (via JS) */
}

/* ── PDF Login Modal: Header-Neugestaltung ───────────────────────────────── */
/* Header: kein Padding mehr, stretch damit Kinder selbst ihre Höhe steuern  */
.kc-leo-header--pdf-dl {
    padding: 0 !important;
    align-items: stretch !important;
    gap: 0 !important;
    min-height: 118px !important;    /* kompakter, gleichmässige Abstände */
}

/* Titel-Block rechts: vertikal gestapelt + als Gruppe zentriert */
.kc-pdf-dl-title {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;       /* Text nach unten schieben */
    align-items: flex-start;
    padding: 10px 36px 16px 14px;    /* oben klein, unten 16px = gleichmässig */
}
.kc-pdf-dl-title h3 {
    color: #ffffff !important;
    font-size: 0.95rem !important;   /* kleiner → 2 Zeilen passen zuverlässig */
    font-weight: 800 !important;
    margin: 0 !important;
    line-height: 1.38;
    letter-spacing: -0.015em;
}

/* Leo-Bild LINKS: gleicher Abstand oben + links (14px), unten durch overflow:hidden begrenzt */
.kc-leo-mascot-wrap--pdf-dl {
    flex-shrink: 0;
    width: 120px;
    padding-top: 14px;               /* = padding-left → gleicher Abstand oben + links */
    padding-left: 14px;
    padding-right: 0;
    margin-bottom: 0;                /* kein overflow-Trick mehr nötig */
    display: flex;
    align-items: flex-start;         /* Bild von oben → padding-top wirkt korrekt */
}
.kc-leo-mascot-wrap--pdf-dl .kc-leo-img {
    width: 120px;
}

/* ── PDF Login Modal: Desktop-Optimierung (min-width: 768px) ─────────────── */
@media (min-width: 768px) {
    /* Modal breiter auf Desktop */
    #kcPdfLoginModal .kc-modal-content {
        max-width: 480px !important;
    }

    /* Header höher für grösseres Bild */
    #kcPdfLoginModal .kc-leo-header--pdf-dl {
        min-height: 138px !important;
    }

    /* Titel grösser + mehr Platz */
    #kcPdfLoginModal .kc-pdf-dl-title {
        padding: 14px 44px 32px 16px !important;  /* mehr bottom → Text höher */
    }
    #kcPdfLoginModal .kc-pdf-dl-title h3 {
        font-size: 1.05rem !important;
        line-height: 1.35;
    }
    #kcPdfLoginModal .kc-pdf-dl-title > div span:last-child {
        font-size: .82rem !important;
    }

    /* Leo-Bild grösser auf Desktop */
    #kcPdfLoginModal .kc-leo-mascot-wrap--pdf-dl {
        width: 145px !important;
        padding-top: 16px !important;
        padding-left: 16px !important;
    }
    #kcPdfLoginModal .kc-leo-mascot-wrap--pdf-dl .kc-leo-img {
        width: 145px !important;
    }
}

/* ── PDF Preview Modal (v3.4.0) ──────────────────────────────── */
.kc-pdf-preview-backdrop {
    position:fixed !important;
    inset:0 !important;
    z-index:2000000;
    width:100vw;
    height:100dvh;
    min-height:100vh;
    background:rgba(15,23,42,.78);
    display:flex;  /* KEIN !important – JS steuert display via Inline-Style; !important würde display:none im HTML überschreiben */
    align-items:center !important;   /* Vertikal zentriert */
    justify-content:center !important; /* Horizontal zentriert */
    padding:20px;
    box-sizing:border-box;
    backdrop-filter:blur(6px);-webkit-backdrop-filter:blur(6px);
    animation:kcFadeIn .22s ease;
    /* KEIN overflow:hidden – blockiert Touch-Events und verhindert Scroll */
    overflow:visible;
}
@keyframes kcFadeIn{from{opacity:0}to{opacity:1}}
.kc-pdf-preview-modal {
    background:#fff;border-radius:18px;
    box-shadow:0 32px 80px rgba(0,0,0,.35),0 8px 24px rgba(37,99,235,.18);
    display:flex;flex-direction:column;
    width:min(900px,95vw);
    height:min(calc(100dvh - 60px), 840px);
    height:min(calc(100vh - 60px), 840px);
    margin:auto;          /* Zentriert im Flex-Container */
    overflow:hidden;
    overscroll-behavior:contain;  /* Scroll bleibt im Modal, blockiert NICHT die Seite */
    animation:kcSlideUp .3s cubic-bezier(.34,1.1,.64,1);
}
@keyframes kcSlideUp{from{transform:translateY(32px);opacity:0}to{transform:translateY(0);opacity:1}}
.kc-pdf-preview-header {
    display:flex;align-items:center;justify-content:space-between;
    padding:16px 20px;
    background:linear-gradient(135deg,#1d4ed8 0%,#2563eb 60%,#3b82f6 100%);flex-shrink:0;
}
.kc-pdf-preview-title{display:flex;align-items:center;gap:12px;}
.kc-pdf-preview-icon{font-size:1.8rem;line-height:1;}
.kc-pdf-preview-label{color:#fff;font-size:1rem;font-weight:700;}
.kc-pdf-preview-sub{color:rgba(255,255,255,.75);font-size:.72rem;margin-top:2px;}
.kc-pdf-preview-close {
    background:rgba(255,255,255,.18);border:none;color:#fff;
    width:34px;height:34px;border-radius:50%;font-size:1.3rem;cursor:pointer;
    display:flex;align-items:center;justify-content:center;transition:background .18s;
}
.kc-pdf-preview-close:hover{background:rgba(255,255,255,.32);}
.kc-pdf-preview-body{flex:1;position:relative;background:#0f172a;overflow:hidden;}
.kc-pdf-preview-spinner {
    position:absolute;inset:0;display:flex;flex-direction:column;
    align-items:center;justify-content:center;gap:16px;color:rgba(255,255,255,.7);font-size:.88rem;
    background:#0f172a;
}
.kc-pdf-preview-spinner i{font-size:2.4rem;color:#3b82f6;animation:kcSpinPulse 1.2s ease-in-out infinite;}
@keyframes kcSpinPulse{0%,100%{opacity:.6;transform:scale(.95)}50%{opacity:1;transform:scale(1.05)}}
.kc-pdf-spinner-doc {
    width:56px;height:72px;border-radius:4px;
    background:linear-gradient(160deg,#1e3a6e 0%,#1d4ed8 100%);
    position:relative;display:flex;align-items:center;justify-content:center;
    animation:kcDocPulse 1.6s ease-in-out infinite;
    box-shadow:0 0 32px rgba(59,130,246,.4);
}
.kc-pdf-spinner-doc::before{
    content:'';position:absolute;top:8px;left:8px;right:8px;height:3px;
    background:rgba(255,255,255,.4);border-radius:2px;
    box-shadow:0 6px 0 rgba(255,255,255,.3),0 12px 0 rgba(255,255,255,.2);
}
.kc-pdf-spinner-doc::after{
    content:'PDF';position:absolute;bottom:10px;color:rgba(255,255,255,.9);
    font-size:.55rem;font-weight:700;letter-spacing:.12em;
}
@keyframes kcDocPulse{0%,100%{transform:translateY(0) scale(1);box-shadow:0 0 24px rgba(59,130,246,.3)}50%{transform:translateY(-6px) scale(1.04);box-shadow:0 12px 40px rgba(59,130,246,.55)}}
.kc-pdf-spinner-dots{display:flex;gap:6px;margin-top:4px;}
.kc-pdf-spinner-dots span{width:7px;height:7px;border-radius:50%;background:#3b82f6;animation:kcDotBounce 1.2s ease-in-out infinite;}
.kc-pdf-spinner-dots span:nth-child(2){animation-delay:.2s;}
.kc-pdf-spinner-dots span:nth-child(3){animation-delay:.4s;}
@keyframes kcDotBounce{0%,80%,100%{opacity:.3;transform:scale(.8)}40%{opacity:1;transform:scale(1.2)}}
.kc-pdf-preview-frame{width:100%;height:100%;border:none;transition:opacity .4s ease;}
.kc-pdf-preview-footer {
    display:grid;
    grid-template-columns:1fr auto 1fr;
    align-items:center;
    padding:12px 18px;background:#f8fafc;border-top:1px solid #e2e8f0;flex-shrink:0;gap:10px;
}
.kc-pdf-action-btn {
    display:inline-flex;align-items:center;gap:8px;padding:11px 22px;border-radius:50px;
    font-size:.85rem;font-weight:700;text-decoration:none;cursor:pointer;
    transition:transform .18s,box-shadow .18s;
}
.kc-pdf-action-btn--download {
    background:linear-gradient(135deg,#1d4ed8,#3b82f6);color:#fff;
    box-shadow:0 4px 14px rgba(37,99,235,.3);
    justify-self:start;
}
.kc-pdf-action-btn--download:hover{transform:translateY(-1px);box-shadow:0 6px 20px rgba(37,99,235,.4);color:#fff;text-decoration:none;}
.kc-pdf-share-btns{display:flex;align-items:center;justify-content:center;gap:8px;}
.kc-pdf-share-btn {
    width:40px;height:40px;border-radius:50%;border:1.5px solid #e2e8f0;
    background:#fff;font-size:1rem;cursor:pointer;
    display:flex;align-items:center;justify-content:center;
    transition:transform .18s,background .18s,border-color .18s;
}
.kc-pdf-share-btn:hover{transform:translateY(-2px);}
.kc-pdf-share-btn--wa{color:#25d366;}.kc-pdf-share-btn--wa:hover{background:#25d366;color:#fff;border-color:#25d366;}
.kc-pdf-share-btn--mail{color:#2563eb;}.kc-pdf-share-btn--mail:hover{background:#2563eb;color:#fff;border-color:#2563eb;}
.kc-pdf-share-btn--copy{color:#64748b;}.kc-pdf-share-btn--copy:hover{background:#64748b;color:#fff;border-color:#64748b;}
.kc-pdf-aff-btn {
    display:inline-flex;align-items:center;justify-content:center;gap:6px;
    height:40px;padding:0 16px;border-radius:99px;
    background:linear-gradient(135deg,#d4a017,#f5c400);color:#0a1222;
    border:none;font-size:.75rem;font-weight:800;letter-spacing:.04em;
    text-transform:uppercase;cursor:pointer;white-space:nowrap;
    transition:opacity .18s,transform .18s;
    justify-self:end;
}
.kc-pdf-aff-btn:hover{opacity:.9;transform:translateY(-1px);}

/* ── Mobile Seitennavigation (.kc-pdf-pagenav) ────────────────────────────── */
.kc-pdf-pagenav {
    display:flex;
    align-items:center;
    justify-content:space-between;
    background:#0f172a;
    border-bottom:1px solid rgba(255,255,255,.08);
    padding:0 8px;
    height:44px;
    flex-shrink:0;
    user-select:none;
    -webkit-user-select:none;
}
.kc-pdf-pagenav-btn {
    width:40px;height:40px;
    display:flex;align-items:center;justify-content:center;
    background:rgba(255,255,255,.08);
    border:1px solid rgba(255,255,255,.14);
    border-radius:10px;
    color:#fff;
    cursor:pointer;
    transition:background .18s,opacity .18s;
    -webkit-tap-highlight-color:transparent;
    flex-shrink:0;
}
.kc-pdf-pagenav-btn:hover  { background:rgba(255,255,255,.18); }
.kc-pdf-pagenav-btn:active { background:rgba(59,130,246,.35); }
.kc-pdf-pagenav-btn:disabled,
.kc-pdf-pagenav-btn[disabled] { opacity:.3; cursor:default; pointer-events:none; }
.kc-pdf-pagenav-info {
    display:flex;align-items:center;gap:5px;
    color:rgba(255,255,255,.85);font-size:.8rem;font-weight:600;
    letter-spacing:.02em;
}
/* Zoom-Controls: Mitte der Nav-Bar */
.kc-pdf-zoom-controls {
    display:flex; align-items:center; gap:8px; flex:1; justify-content:center;
}
.kc-pdf-zoom-btn {
    width:34px; height:34px;
    display:flex; align-items:center; justify-content:center;
    background:rgba(255,255,255,.1);
    border:1px solid rgba(255,255,255,.18);
    border-radius:9px;
    color:#fff; font-size:1.25rem; font-weight:300; line-height:1;
    cursor:pointer;
    transition:background .15s, transform .12s;
    -webkit-tap-highlight-color:transparent;
    flex-shrink:0; padding:0;
}
.kc-pdf-zoom-btn:hover  { background:rgba(255,255,255,.2); }
.kc-pdf-zoom-btn:active { background:rgba(59,130,246,.4); transform:scale(.93); }
.kc-pdf-zoom-btn:disabled,
.kc-pdf-zoom-btn[disabled] { opacity:.3; cursor:default; pointer-events:none; }
.kc-pdf-zoom-level {
    color:#60a5fa; font-size:.78rem; font-weight:700;
    min-width:42px; text-align:center; letter-spacing:.01em;
    background:rgba(96,165,250,.12);
    border:1px solid rgba(96,165,250,.25);
    border-radius:7px; padding:3px 6px;
}

@keyframes kcSlideUpSheet {
    from { transform: translateY(30px); opacity: 0; }
    to   { transform: translateY(0);    opacity: 1; }
}

/* ── Mobile: NUR Header/Footer kompakter ──────────────────────────────────────
   JS steuert Wrapper/Panel/Body/Frame via Inline-Styles (kein CSS !important noetig).
   KEINE display/position/z-index Overrides hier – wuerden JS-Inline-Styles schlagen!
   ─────────────────────────────────────────────────────────────────────────── */
@media(max-width:767px){
    /* Backdrop: kein Padding – Modal füllt ganzen Screen */
    .kc-pdf-preview-backdrop {
        padding:0 !important;
        align-items:stretch !important;
    }
    /* Modal: genau 1 Bildschirmhöhe, kein Radius unten */
    .kc-pdf-preview-modal {
        width:100% !important;
        max-width:100% !important;
        height:100dvh !important;
        height:100vh !important;
        max-height:100dvh !important;
        max-height:100vh !important;
        border-radius:0 !important;
        margin:0 !important;
    }
    .kc-pdf-preview-header { padding:10px 14px !important; }
    .kc-pdf-preview-label  { font-size:.85rem !important; }
    .kc-pdf-preview-sub    { font-size:.62rem !important; margin-top:1px !important; }
    .kc-pdf-preview-icon   { font-size:1.3rem !important; }


    /* Footer: 2-Zeilen-Layout – Download oben (volle Breite), Share unten (zentriert) */
    .kc-pdf-preview-footer {
        display:flex !important;
        flex-direction:column !important;
        align-items:stretch !important;
        padding:14px 16px !important;
        padding-bottom:max(20px, calc(14px + env(safe-area-inset-bottom, 10px))) !important;
        gap:10px !important;
        grid-template-columns:none !important;
        background:#f8fafc !important;
        border-top:1px solid #e2e8f0 !important;
        flex-shrink:0 !important;
    }
    /* Download-Button: volle Breite, Zeile 1 */
    .kc-pdf-action-btn--download {
        width:100% !important;
        box-sizing:border-box !important;
        justify-content:center !important;
        justify-self:auto !important;
        padding:13px 16px !important;
        font-size:.88rem !important;
        flex:none !important;
    }
    /* Share-Buttons: zentriert in Zeile 2 */
    .kc-pdf-share-btns {
        display:flex !important;
        justify-content:center !important;
        align-items:center !important;
        gap:14px !important;
        width:100% !important;
        flex-shrink:0 !important;
    }
    .kc-pdf-share-btn {
        width:46px !important;
        height:46px !important;
        font-size:1.05rem !important;
        flex-shrink:0 !important;
    }
    /* Affiliate-Button: volle Breite in Zeile 1 (ganz oben) */
    .kc-pdf-aff-btn {
        width:100% !important;
        box-sizing:border-box !important;
        justify-content:center !important;
        justify-self:auto !important;
        height:46px !important;
        padding:0 16px !important;
        font-size:.82rem !important;
        flex:none !important;
        order:1 !important;
    }
     /* Download: Zeile 2 */
    .kc-pdf-action-btn--download { order:2 !important; }
    /* Share-Buttons: Zeile 3 (ganz unten) */
    .kc-pdf-share-btns { order:3 !important; }
}

/* ═══════════════════════════════════════════════════
   PDF LOGIN MODAL – MOBILE FIXES
   In externer CSS-Datei damit Page-Cache kein Problem ist
   ═══════════════════════════════════════════════════ */

/* iOS-Zoom verhindert: font-size ≥ 16px ist Pflicht */
#kcPdfLoginModal input[type="email"],
#kcQuickRegEmail {
    font-size: 16px !important;
    -webkit-text-size-adjust: 100%;
}

/* Mobile (max 480px): Bottom-Sheet Karte ohne Radius unten */
@media (max-width: 480px) {
    #kcPdfLoginModal .kc-modal-content {
        /* Bottom-Sheet: kein Radius unten nötig (bündig am Bildschirmrand) */
        border-radius: 0 !important;
        max-width: 100% !important;
        -webkit-transform: translateZ(0);
        transform: translateZ(0);
    }
    #kcPdfLoginModal .kc-leo-mascot-wrap {
        border-radius: 0 !important;
    }
    /* margin-top:120px entfernt – Bottom-Sheet hat keinen Margin nötig */
}

/* ── Complianz + andere Cookie-Banner im iframe ausblenden ─────────────────
 * Im iframe-Kontext sind Cookie-Banner irrelevant und vergroessern scrollHeight.
 * Der Complianz-Banner laeuft auf dem Parent-Frame, nicht im iframe. ---------- */
#cmplz-manage-consent,
.cmplz-manage-consent,
#cmplz-cookiebanner-container,
.cmplz-cookiebanner,
#cookie-notice,
.cookie-notice-container,
#wp-gdpr-cookie-notice,
.cc-window,
.cc-banner {
    display: none !important;
}

/* ══════════════════════════════════════════════════════════════════════════
   Register-Modal: Desktop Floating Card – finale, korrekte Architektur
   Werden vom iframe via cssRules in den Parent-Overlay kopiert.
   HINWEIS: .kc-modal-content und .kc-modal-leo sind DASSELBE div-Element.
   ══════════════════════════════════════════════════════════════════════════ */

/* ─── Overlay: Gradient NUR hinter der Karte (rechts), links transparent ─── */
/* background-size: 510px = Kartenbreite (460px) + Abstand (50px)             */
/* background-position: right = rechts bündig wie die Karte                   */
html body #kcParentRegisterOverlay {
    align-items: flex-start !important;
    justify-content: flex-end !important;
    padding: 16px 24px 16px 0 !important;
    background:
        linear-gradient(
            to bottom,
            #0d1b35  0px,    /* Dunkelblau – Header-Start                  */
            #1a3260 55px,    /* Mittelblau  – Header-Gradient Mitte         */
            #1e4080 110px,   /* Hellblau    – Trennlinie Header / Inhalt    */
            #0d1b35 110px,   /* Dunkelblau  – ab Trennlinie (Card-Body)     */
            #0d1b35 100%     /* Dunkelblau  – bis ganz unten                */
        ) right center / 510px 100% no-repeat !important; /* nur 510px breit, rechts */
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
}



/* ─── Modal-Wrapper: Floating Card mit harter Rand-Clipping ─────────────── */
/* overflow:hidden + border-radius schneiden die dunklen Ecken ab            */
html body #kcParentRegisterOverlay #kcPdfLoginModal {
    position: relative !important;
    inset: auto !important;
    display: flex !important;
    flex-direction: column !important;
    width: min(460px, calc(100% - 48px)) !important;
    height: auto !important;
    max-height: calc(100vh - 32px) !important;
    overflow: hidden !important;    /* ← clippt dunkle Ecken des Inhalts */
    border-radius: 22px !important; /* ← aussen alle 4 Ecken gerundet    */
    pointer-events: auto !important;
    margin: 0 !important;
    background: none !important;
    backdrop-filter: none !important;
    z-index: auto !important;
    box-shadow: 0 12px 56px rgba(0, 0, 0, .45), 0 2px 16px rgba(0,0,0,.22) !important;
}

/* ─── .kc-modal-content = .kc-modal-leo (SAME element): Scroll-Container ── */
/* EINE kombinierte Regel – beide Klassen treffen denselben div              */
html body #kcParentRegisterOverlay .kc-modal-content {
    overflow-y: auto !important;
    overflow-x: hidden !important;
    scrollbar-width: none !important;
    -ms-overflow-style: none !important;
    max-height: calc(100vh - 32px) !important;
    border-radius: 0 !important;    /* Radius übernimmt Eltern-Wrapper       */
    padding: 0 !important;          /* Kinder regeln ihr eigenes Padding     */
    margin: 0 !important;
    display: flex !important;
    flex-direction: column !important;
    flex: none !important;
    max-width: 100% !important;
}

html body #kcParentRegisterOverlay .kc-modal-content::-webkit-scrollbar {
    display: none !important;
    width: 0 !important;
}

/* ─── Leo-Header: 110px, voller Inhalt sichtbar ─────────────────────────── */
html body #kcParentRegisterOverlay .kc-leo-header {
    border-radius: 0 !important;    /* wird vom Eltern-#kcPdfLoginModal geclipt */
    height: 110px !important;
    min-height: 110px !important;
    max-height: 110px !important;
    flex-shrink: 0 !important;
    overflow: hidden !important;
    padding: 0 12px 0 0 !important;
    gap: 12px !important;
    align-items: stretch !important;
}

html body #kcParentRegisterOverlay .kc-leo-mascot-wrap {
    width: 90px !important;
    min-width: 90px !important;
    flex-shrink: 0 !important;
    border-radius: 0 !important;
    align-self: stretch !important;
}

html body #kcParentRegisterOverlay .kc-leo-img {
    width: 90px !important;
    height: 100% !important;
    object-fit: cover !important;
    object-position: top center !important;
}

html body #kcParentRegisterOverlay .kc-leo-header-text {
    padding: 10px 0 10px 0 !important;
    gap: 3px !important;
    justify-content: center !important;
}

html body #kcParentRegisterOverlay .kc-leo-name {
    font-size: 1.2rem !important;
    margin-bottom: 2px !important;
}

html body #kcParentRegisterOverlay .kc-leo-badge {
    margin-bottom: 4px !important;
}

html body #kcParentRegisterOverlay .kc-leo-title {
    font-size: 0.88rem !important;
    line-height: 1.3 !important;
    white-space: normal !important;
    padding-right: 0 !important;
}

/* ─── Bonus-Voucher-Cards: kompakt ──────────────────────────────────────── */
html body #kcParentRegisterOverlay .kc-bonus-vouchers {
    gap: 6px !important;
    margin-bottom: 0 !important;
    padding: 12px 14px 8px 14px !important;
}

html body #kcParentRegisterOverlay .kc-bv-card {
    padding: 7px 5px !important;
    font-size: 0.72rem !important;
}

html body #kcParentRegisterOverlay .kc-bv-value {
    font-size: 0.7rem !important;
    line-height: 1.15 !important;
}

html body #kcParentRegisterOverlay .kc-bv-icon {
    font-size: 1.1rem !important;
    margin-bottom: 2px !important;
}

html body #kcParentRegisterOverlay .kc-bv-label {
    font-size: 0.58rem !important;
    margin-top: 1px !important;
}

/* ─── Bonus-Voucher-Cards: elegant & sportlich (v3.9.4) ──────────────────── */
.kc-bv-card {
    background: linear-gradient(135deg,
        rgba(255,255,255,0.13) 0%,
        rgba(255,255,255,0.06) 100%) !important;
    border: 1px solid rgba(255,255,255,0.22) !important;
    border-radius: 18px !important;
    backdrop-filter: blur(8px) !important;
    -webkit-backdrop-filter: blur(8px) !important;
    box-shadow: 0 2px 12px rgba(0,0,0,0.12), inset 0 1px 0 rgba(255,255,255,0.15) !important;
    transition: transform .2s ease, box-shadow .2s ease !important;
}
.kc-bv-card:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 20px rgba(0,0,0,0.18), inset 0 1px 0 rgba(255,255,255,0.2) !important;
}
.kc-bv-value {
    font-weight: 700 !important;
    color: #fff !important;
    letter-spacing: -0.01em !important;
}
.kc-bv-label {
    color: rgba(255,255,255,0.72) !important;
    letter-spacing: 0.02em !important;
}
/* ─── Form-Body: eigenes Padding ─────────────────────────────────────────── */
html body #kcParentRegisterOverlay .kc-pdf-login-body {
    padding: 4px 14px 20px 14px !important;
}

html body #kcParentRegisterOverlay .kc-pdf-login-body label:not(#kcAgbWrap) {
    font-size: 0.82rem !important;
    color: #ffffff !important;
    display: block !important;
    margin-bottom: 5px !important;
}

html body #kcParentRegisterOverlay .kc-pdf-login-body input[type="email"] {
    margin-bottom: 8px !important;
}

/* ─── Subtext: ausblenden ────────────────────────────────────────────────── */
html body #kcParentRegisterOverlay .kc-pdf-subtext {
    display: none !important;
}

/* ─── CTA-Button ─────────────────────────────────────────────────────────── */
html body #kcParentRegisterOverlay #kcQuickRegBtn {
    width: 100% !important;
    white-space: normal !important;
    line-height: 1.35 !important;
    font-size: 0.86rem !important;
    padding: 14px 20px !important;
    margin-top: 10px !important;
    margin-bottom: 0 !important;
    border-radius: 50px !important;
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 40%, #fbbf24 100%) !important;
    color: #1a1a1a !important;
    font-weight: 700 !important;
    border: none !important;
    box-shadow: 0 4px 18px rgba(245,158,11,0.45), 0 1px 4px rgba(0,0,0,0.18) !important;
    letter-spacing: 0.01em !important;
    transition: transform .2s ease, box-shadow .2s ease !important;
}

/* ══════════════════════════════════════════════════════════════════════════
   Mobile: kc-mob-br – Zeilenumbruch nur auf Mobile sichtbar
   ══════════════════════════════════════════════════════════════════════════ */
.kc-mob-br { display: none; }

/* ══════════════════════════════════════════════════════════════════════════
   Mobile: Register-Modal – zentriert, volle Breite
   ══════════════════════════════════════════════════════════════════════════ */
@media (max-width: 767px) {

    /* Mobile: Umbruch nach "Ihr" einblenden */
    .kc-mob-br { display: inline !important; }

    /* Overlay: zentriert, kein Gradient (würde Mobile-Layout verdecken) */
    html body #kcParentRegisterOverlay {
        align-items: flex-start !important;
        justify-content: center !important;
        padding: 12px 12px 0 12px !important;
        background: transparent !important;
    }

    /* Modal-Karte: volle Breite auf Mobile */
    html body #kcParentRegisterOverlay #kcPdfLoginModal {
        width: min(460px, calc(100% - 0px)) !important;
        border-radius: 16px !important;
        max-height: calc(100vh - 24px) !important;
    }

    /* Scroll-Container auf Mobile angepasst */
    html body #kcParentRegisterOverlay .kc-modal-content {
        max-height: calc(100vh - 24px) !important;
    }

    /* Leo-Header auf Mobile etwas kompakter */
    html body #kcParentRegisterOverlay .kc-leo-header {
        height: 100px !important;
        min-height: 100px !important;
        max-height: 100px !important;
    }

    html body #kcParentRegisterOverlay .kc-leo-mascot-wrap {
        width: 80px !important;
        min-width: 80px !important;
    }

    html body #kcParentRegisterOverlay .kc-leo-img {
        width: 80px !important;
    }
}


/* ═══════════════════════════════════════════════════
   PDF PREVIEW HEADER – BADGE UNTER TITEL (Mobile)
   Badge bricht auf neuer Zeile unter den Titel statt
   daneben – besseres Layout auf kleinen Bildschirmen.
   ═══════════════════════════════════════════════════ */
@media (max-width: 600px) {
    .kc-pdf-preview-header {
        flex-wrap: wrap;
        gap: 6px;
    }
    .kc-pdf-preview-title {
        flex: 1 1 0;
    }
    #kcPdfRemainingBadge {
        order: 10;
        flex: 0 0 100%;
        margin-top: 2px;
        border-radius: 6px;
    }
}



/* ═══════════════════════════════════════════════════════════════════════════
   ZINSVERGLEICH WIDGET (v3.8.0)
   Zwei-Spalten: Gewählter Zinssatz (blau) vs. Gesetzl. Maximum 10% (rot)
   Responsiv: Desktop nebeneinander, Mobile untereinander
   ═══════════════════════════════════════════════════════════════════════════ */

ting {
    animation: kc-cmp-pop 0.3s cubic-bezier(0.34,1.4,0.64,1) both !important;
}

/* ── Mobile: Zwei-Spalten-Layout erhalten, Zahlen kleiner ───────────────── */
@media (max-width: 480px) {
    .kc-compare-block {
        margin-top: 10px;
        border-radius: 10px;
    }
    .kc-compare-header {
        padding: 8px 12px 4px;
    }
    .kc-compare-cols-label {
        padding: 4px 12px 6px;
    }
    .kc-compare-row {
        padding: 8px 12px;
    }
    .kc-cmp-value {
        font-size: 0.82rem !important;
    }
    .kc-compare-rate-badge {
        font-size: 0.65rem;
        padding: 1px 5px;
    }
    .kc-compare-savings {
        font-size: 0.68rem;
        padding: 8px 12px;
    }
}

/* ── Sehr kleine Bildschirme (<360px): Labels etwas kompakter ────────────── */
@media (max-width: 360px) {
    .kc-compare-col-label span:not(.kc-compare-dot):not(.kc-compare-rate-badge) {
        display: none; /* "Ihr Zinssatz" / "Gesetz Max." ausblenden, nur Badge bleibt */
    }
    .kc-cmp-label { font-size: 0.6rem !important; }
    .kc-cmp-value { font-size: 0.78rem !important; }
}

/* ═══════════════════════════════════════════════════════════════════════════
   ZINSVERGLEICH WIDGET (v3.8.0)
   Zwei-Spalten-Vergleich: Gewählter Zinssatz vs. gesetzl. Max 10%
   Sitzt an der Stelle der alten Gesamtzinsen/Gesamtkosten-Zeilen
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Äusserer Container ─────────────────────────────────────────────────── */
.kc-compare-block {
    margin-top: 10px;
    margin-bottom: 12px;
    border-radius: 12px;
    overflow: hidden;
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.13);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* ── Header ─────────────────────────────────────────────────────────────── */
.kc-compare-header {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 9px 12px 7px;
}
.kc-compare-header-line {
    flex: 1;
    height: 1px;
    background: rgba(255,255,255,0.18);
}
.kc-compare-header-label {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.67rem;
    font-weight: 700;
    letter-spacing: 0.09em;
    text-transform: uppercase;
    color: #fff;
    white-space: nowrap;
    flex-shrink: 0;
}
.kc-compare-header-label i {
    font-size: 0.65rem;
    color: #fff;
}

/* ── Spalten-Label-Zeile ────────────────────────────────────────────────── */
.kc-compare-cols-label {
    display: grid;
    grid-template-columns: 1fr 1px 1fr;
    align-items: center;
    padding: 6px 12px 6px;
    background: rgba(255,255,255,0.04);
}
.kc-compare-col-label {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.70rem;
    font-weight: 600;
    color: rgba(255,255,255,0.78);
}
.kc-compare-col-label--right {
    justify-content: flex-end;
}
.kc-compare-col-title {
    flex-shrink: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ── Punkte ──────────────────────────────────────────────────────────────── */
.kc-compare-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}
/* v3.9.7: GRÜN = Ihr Zinssatz (Kunde/CTA), TIEFBLAU = Max. Zins (gesetzlich) */
.kc-compare-dot--blue { background: #22c55e; box-shadow: 0 0 6px rgba(34,197,94,0.7); }   /* Ihr Zinssatz → Grün */
.kc-compare-dot--red  { background: #ffffff; box-shadow: 0 0 5px rgba(255,255,255,0.6); }  /* Max. Zins – Weiß wie Textfarbe */

/* ── Rate-Badges ─────────────────────────────────────────────────────────── */
.kc-compare-rate-badge {
    font-size: 0.68rem;
    font-weight: 800;
    padding: 1px 6px;
    border-radius: 99px;
    background: rgba(34,197,94,0.15);  /* Ihr Zinssatz: Grün */
    color: #4ade80;
    border: 1px solid rgba(34,197,94,0.28);
    letter-spacing: 0.02em;
    flex-shrink: 0;
    transition: all 0.25s ease;
}
.kc-compare-rate-badge--red {
    background: rgba(29,78,216,0.15);  /* Max. Zins: Tiefblau */
    color: #93c5fd;
    border-color: rgba(29,78,216,0.30);
}

/* ── Vertikale Trennlinie ────────────────────────────────────────────────── */
.kc-compare-divider-v {
    width: 1px;
    background: rgba(255,255,255,0.15);
    align-self: stretch;
    flex-shrink: 0;
    margin: 0 8px;
}
.kc-compare-divider-v--row {
    min-height: 38px;
}

/* ── Horizontale Trennlinien ─────────────────────────────────────────────── */
.kc-compare-separator {
    height: 1px;
    background: rgba(255,255,255,0.10);
    margin: 0 12px;
}
.kc-compare-separator--top {
    margin: 0;      /* von Kante zu Kante unter Labels */
    background: rgba(255,255,255,0.13);
}

/* ── Daten-Zeilen ────────────────────────────────────────────────────────── */
.kc-compare-row {
    display: grid;
    grid-template-columns: 1fr 1px 1fr;
    align-items: center;
    padding: 9px 12px;
    transition: background 0.15s ease;
}
.kc-compare-row:hover {
    background: rgba(255,255,255,0.04);
}

/* ── Zellen ──────────────────────────────────────────────────────────────── */
.kc-compare-cell {
    display: flex;
    flex-direction: column;
    gap: 1px;
}
.kc-compare-cell--right {
    align-items: flex-end;
    text-align: right;
}
.kc-cmp-label {
    font-size: 0.62rem !important;
    font-weight: 500 !important;
    color: rgba(255,255,255,0.48) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.07em !important;
    margin: 0 !important;
    line-height: 1.2 !important;
}
.kc-cmp-value {
    font-size: 0.95rem !important;
    font-weight: 800 !important;
    margin: 0 !important;
    line-height: 1.25 !important;
    transition: all 0.28s ease !important;
}
.kc-cmp-value--blue {
    color: #4ade80 !important;                     /* v3.9.7: Ihr Zinssatz → Grün */
    text-shadow: 0 0 14px rgba(34,197,94,0.25) !important;
}
.kc-cmp-value--red {
    color: #93c5fd !important;                     /* v3.9.7: Max. Zins → Tiefblau */
    text-shadow: 0 0 10px rgba(29,78,216,0.20) !important;
}

/* ── Ersparnis-Banner ────────────────────────────────────────────────────── */
.kc-compare-savings {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 4px 6px;
    padding: 8px 12px;
    background: linear-gradient(135deg, rgba(34,197,94,0.15) 0%, rgba(16,185,129,0.09) 100%);
    border-top: 1px solid rgba(34,197,94,0.18);
    font-size: 0.70rem;
    color: rgba(255,255,255,0.70);
    line-height: 1.3;
    text-align: center;
}
.kc-compare-savings i {
    color: #4ade80;
    font-size: 0.80rem;
    flex-shrink: 0;
}
.kc-compare-savings strong {
    color: #4ade80 !important;
    font-weight: 800 !important;
    font-size: 0.82rem !important;
    white-space: nowrap;
}

/* ── Pop-Animation bei Wertänderung ─────────────────────────────────────── */
@keyframes kc-cmp-pop {
    0%   { transform: scale(1); opacity: 0.7; }
    50%  { transform: scale(1.07); opacity: 1; }
    100% { transform: scale(1); opacity: 1; }
}
.kc-cmp-value--updating {
    animation: kc-cmp-pop 0.30s cubic-bezier(0.34,1.4,0.64,1) both !important;
}

/* ── Mobile ≤ 480px ─────────────────────────────────────────────────────── */
@media (max-width: 480px) {
    .kc-compare-block { border-radius: 10px; margin-bottom: 10px; }
    .kc-compare-row   { padding: 8px 10px; }
    .kc-compare-cols-label { padding: 5px 10px; }
    .kc-compare-header { padding: 8px 10px 6px; }
    .kc-cmp-value { font-size: 0.85rem !important; }
    .kc-compare-savings { font-size: 0.66rem; padding: 7px 10px; }
}

/* ── Sehr kleine Screens ≤ 360px ─────────────────────────────────────────── */
@media (max-width: 360px) {
    .kc-compare-col-title { display: none; }
    .kc-cmp-value { font-size: 0.78rem !important; }
    .kc-cmp-label { font-size: 0.58rem !important; }
}
/* ── Hinweis-Text unter Ergebnis-Zeilen (z.B. "Inkl. fester Zinssatz") ─── */
.kc-result-hint {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 3px !important;
    font-size: 0.67rem !important;
    font-weight: 500 !important;
    color: rgba(255,255,255,0.42) !important;
    letter-spacing: 0.03em;
    line-height: 1.2 !important;
}
.kc-result-hint i {
    font-size: 0.60rem;
    opacity: 0.7;
}

/* ── Max-Zinssatz-Hinweis unter dem Jahreszins-Slider (KKG) ─────────────── */
.kc-max-rate-hint {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin-top: 7px !important;
    padding: 5px 10px;
    border-radius: 8px;
    background: rgba(34,197,94,0.07);
    border: 1px solid rgba(34,197,94,0.22);
    font-size: 0.70rem;
    color: #1e293b;
    line-height: 1.3;
    width: 100%;
    box-sizing: border-box;
}
.kc-max-rate-hint i {
    color: #3b82f6;             /* v3.9.7: Tiefblau = gesetzl. Max */
    font-size: 0.68rem;
    flex-shrink: 0;
}
.kc-max-rate-hint strong {
    color: #1d4ed8;             /* v3.9.7: Tiefblau = gesetzl. Max */
    font-weight: 700;
}
.kc-max-rate-link {
    color: #3b82f6 !important;  /* v3.9.7: Tiefblau statt Grün */
    text-decoration: underline;
    text-underline-offset: 2px;
    font-weight: 600;
    transition: color 0.15s ease;
}
.kc-max-rate-link:hover {
    color: #1d4ed8 !important;
}

/* ── kc-max-rate-hint: Umbruch-Schutz ───────────────────────────────────── */
.kc-max-rate-hint span {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
@media (max-width: 360px) {
    .kc-max-rate-hint { font-size: 0.63rem; padding: 4px 8px; gap: 4px; }
    .kc-max-rate-hint span { white-space: normal; }
}

/* ── Gesamtraten: "inkl. Zins" Suffix ───────────────────────────────────── */
.kc-result-small--inline {
    display: flex;
    align-items: baseline;
    flex-wrap: nowrap;
    gap: 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.kc-rate-suffix {
    font-size: 0.68rem !important;
    font-weight: 500;
    color: rgba(255,255,255,0.45);
    white-space: nowrap;
    flex-shrink: 0;
}



.kc-amort-header-btn    { display: none !important; }
.kc-mobile-show-all-wrap { display: none !important; }


/* ══ MOBILE: KKG Max-Rate Hinweis – zentriert, dezent, kompakt ══════════════ */
@media (max-width: 699px) {
    .kc-max-rate-hint {
        font-size: 0.65rem !important;
        opacity: 0.68 !important;
        margin-top: 1rem !important;
        padding: 3px 6px !important;
        background: transparent !important;
        border: none !important;
        box-shadow: none !important;
        justify-content: center !important;
        text-align: center !important;
        display: flex !important;
        gap: 4px !important;
    }
    .kc-max-rate-hint strong {
        font-weight: 600 !important;
    }
    .kc-max-rate-link {
        font-size: 0.63rem !important;
    }
    .kc-max-rate-hint i {
        font-size: 0.6rem !important;
    }
}
/* v3.9: kc-combined-label-left Farbe NICHT grün – Zinsteil CHF-Wert bleibt neutral */


/* ═══════════════════════════════════════════════════════════════
   v3.9.1: KACHELN – Laufzeit & Jahreszins  (Quick-Btn Stil)
   ═══════════════════════════════════════════════════════════════ */

/* ── Laufzeit-Kacheln (Stil = kc-quick-btn) ── */
.kc-term-tiles {
    display: grid !important;
    grid-template-columns: repeat(4, 1fr) !important;
    gap: 6px !important;
    margin-top: 8px !important;
}
.kc-term-tile {
    min-width: 0 !important;
    padding: 6px 8px !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 8px !important;
    background: #f8fafc !important;
    color: #475569 !important;
    font-size: .76rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    white-space: nowrap !important;
    transition: border-color .15s ease, background .15s ease, color .15s ease, transform .12s ease !important;
    line-height: 1.4 !important;
    text-align: center !important;
}
.kc-term-tile:hover {
    border-color: #3b82f6 !important;
    background: #eff6ff !important;
    color: #1d4ed8 !important;
    transform: translateY(-1px) !important;
}
.kc-term-tile:active { transform: scale(.95) !important; }
.kc-term-tile--active {
    border-color: #3b82f6 !important;
    background: linear-gradient(135deg,#3b82f6,#60a5fa) !important;
    color: #fff !important;
    box-shadow: 0 3px 10px rgba(59,130,246,.30) !important;
    position: relative !important;
    overflow: hidden !important;
}
.kc-term-tile--active:hover {
    background: linear-gradient(135deg,#2563eb,#3b82f6) !important;
    color: #fff !important;
    transform: translateY(-1px) !important;
}
/* ─── Laufzeit-Kacheln: kurz/lang Label Toggle ───────────────────────────── */
/* Inaktiv: nur kurze Form ("1 J."), lange Form versteckt                      */



/* Aktiv: kurze Form weg, lange Form ("1 Jahr") sichtbar                       */
.kc-term-tile--active 
.kc-term-tile--active 
/* Shimmer auf aktiver Laufzeit-Kachel: width:100% + translateX(-100%→+100%) */
.kc-term-tile--active::after {
    content: '' !important;
    position: absolute !important;
    top: 0; left: 0 !important;
    width: 100%; height: 100% !important;
    background: linear-gradient(105deg,
        transparent 20%,
        rgba(255,255,255,0.55) 50%,
        transparent 80%) !important;
    animation: kc-tile-shimmer-loop 2.2s ease-in-out infinite !important;
    pointer-events: none !important;
}

/* ── Zinssatz-Kacheln (Stil = kc-quick-btn, 2×2) ── */
.kc-zins-tiles {
    display: grid !important;
    grid-template-columns: 1fr 1fr !important;
    gap: 6px !important;
    margin-top: 8px !important;
}
.kc-zins-tile {
    position: relative !important;
    overflow: hidden !important;
    padding: 9px 10px 8px !important;
    border: 1.5px solid #e2e8f0 !important;
    border-radius: 8px !important;
    background: #f8fafc !important;
    color: #475569 !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: border-color .15s ease, background .15s ease, color .15s ease, transform .12s ease !important;
    -webkit-tap-highlight-color: transparent !important;
    user-select: none !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 2px !important;
}
.kc-zins-tile:hover {
    border-color: #3b82f6 !important;
    background: #eff6ff !important;
    color: #1d4ed8 !important;
    transform: translateY(-1px) !important;
}
.kc-zins-tile:active { transform: scale(.97) !important; }
.kc-zins-tile--active {
    border-color: #3b82f6 !important;
    background: linear-gradient(135deg,#3b82f6,#60a5fa) !important;
    color: #fff !important;
    box-shadow: 0 3px 10px rgba(59,130,246,.30) !important;
}
.kc-zins-tile--active:hover {
    background: linear-gradient(135deg,#2563eb,#3b82f6) !important;
    color: #fff !important;
    transform: translateY(-1px) !important;
}
/* Shimmer auf aktiver Zins-Kachel: width:100% + translateX(-100%→+100%) */
.kc-zins-tile--active::after {
    content: '' !important;
    position: absolute !important;
    top: 0; left: 0 !important;
    width: 100%; height: 100% !important;
    background: linear-gradient(105deg,
        transparent 20%,
        rgba(255,255,255,0.55) 50%,
        transparent 80%) !important;
    animation: kc-tile-shimmer-loop 2.2s ease-in-out infinite !important;
    pointer-events: none !important;
}
.kc-zins-tile__range {
    font-size: .82rem !important;
    font-weight: 700 !important;
    line-height: 1.2 !important;
    display: none !important;   /* Standardmässig versteckt */
}
.kc-zins-tile--active .kc-zins-tile__range {
    display: block !important;  /* Nur bei aktiver Kachel sichtbar */
}
.kc-zins-tile__label {
    font-size: .66rem !important;
    opacity: .75 !important;
    font-weight: 500 !important;
    line-height: 1.2 !important;
    display: block !important;
}
.kc-zins-tile--active .kc-zins-tile__label { opacity: .88 !important; }

/* ── Zins-Modals: padding-bottom siehe L808 ── */

@media (max-width: 400px) {
    .kc-zins-tile { padding: 8px 8px 7px !important; }
    .kc-zins-tile__range { font-size: .78rem !important; }
}

/* Leo-Bild bündig am unteren Header-Rand (Zins- + Laufzeit-Modals, v3.9.7) */
.kc-zins-modal .kc-leo-mascot-wrap,
.kc-laufzeit-modal .kc-leo-mascot-wrap {
    align-self: flex-end;
    margin-bottom: 0;
    flex-shrink: 0;
}
.kc-zins-modal .kc-leo-img,
.kc-laufzeit-modal .kc-leo-img {
    border-radius: 16px 16px 0 0;
    display: block;
    width: 115px;
}

/* ═══ Zins-Modal: Header + Scroll + Corner-Fixes (v3.9.9) ═══════════════ */

/* 1. Scroll im Modal auf iOS freischalten */
.kc-zins-modal .kc-modal-leo {
    -webkit-overflow-scrolling: touch !important;
    overscroll-behavior:        contain !important;
    margin:                     0 !important;          /* kein margin:10% – Modal ist flex-centered */
    transform:                  translateZ(0);          /* GPU: verhindert weisse Ecken (Bleed-Fix) */
    overflow:                   hidden !important;
}

/* 2. Scroll-Container: touch-action für iOS */
.kc-zins-modal {
    -webkit-overflow-scrolling: touch;
}

/* 3. Header: stretch-Layout damit Text = Bildhöhe */
.kc-zins-modal .kc-leo-header {
    align-items:  stretch !important;
    padding:      0 10px 0 0 !important;
    gap:          12px !important;
    min-height:   0 !important;
    border-radius: 20px 20px 0 0 !important;   /* muss exakt mit Card (20px) matchen */
    overflow:     hidden !important;            /* Ecken-Clipping am Header selbst */
}

/* 4. Bild-Container: gleicher Abstand oben + links (je 12px) */
.kc-zins-modal .kc-leo-mascot-wrap {
    display:      flex !important;
    align-self:   stretch !important;
    align-items:  flex-end !important;
    flex-shrink:  0 !important;
    padding-top:  12px !important;
    padding-left: 12px !important;
}

/* 5. Leo-Bild: Original-Radius beibehalten */
.kc-zins-modal .kc-leo-img {
    width:         105px !important;
    height:        auto;
    border-radius: 16px 16px 0 0 !important;   /* original: oben gerundet */
    display:       block;
    align-self:    flex-end;
}

/* 6. Text-Säule: vertikal zentriert */
.kc-zins-modal .kc-leo-header-text {
    flex:             1 !important;
    padding:          14px 4px 0 0 !important;
    display:          flex !important;
    flex-direction:   column !important;
    justify-content:  center !important;
    gap:              5px !important;
    min-width:        0 !important;
}

/* 7. Textstile */
.kc-zins-modal .kc-leo-name {
    font-size:   1.2rem !important;
    font-weight: 800 !important;
    color:       #fff !important;
    line-height: 1.1 !important;
    margin:      0 !important;
}
.kc-zins-modal .kc-leo-badge {
    font-size: 0.68rem !important;
    padding:   2px 8px !important;
}
.kc-zins-modal .kc-modal-title.kc-leo-title {
    font-size:     clamp(0.6rem, 2.8vw, 0.9rem) !important;
    line-height:   1.3 !important;
    margin:        0 !important;
    color:         #fff !important;
    white-space:   nowrap !important;
    overflow:      hidden !important;
    text-overflow: ellipsis !important;
}
.kc-zins-modal .kc-leo-header .kc-close-modal {
    align-self:  flex-start !important;
    margin-top:  10px !important;
}

/* Rate-Limit Overlay (#kcRLOverlay): gleiche Bild-Position wie Zins-Modals */
#kcRLOverlay .kc-leo-header {
    align-items:   stretch !important;
    padding:       0 10px 0 0 !important;
    gap:           12px !important;
    min-height:    0 !important;
    border-radius: 20px 20px 0 0 !important;
    overflow:      hidden !important;
}
#kcRLOverlay .kc-leo-mascot-wrap {
    display:      flex !important;
    align-self:   stretch !important;   /* überschreibt align-self:flex-end */
    align-items:  flex-end !important;  /* Bild bündig am Boden */
    flex-shrink:  0 !important;
    padding-top:  12px !important;      /* oben = links = 12px */
    padding-left: 12px !important;
}
#kcRLOverlay .kc-leo-img {
    width:         105px !important;
    height:        auto;
    border-radius: 16px 16px 0 0 !important;
    display:       block;
    align-self:    flex-end;
}
#kcRLOverlay .kc-leo-header-text {
    flex:             1 !important;
    padding:          14px 4px 0 0 !important;
    display:          flex !important;
    flex-direction:   column !important;
    justify-content:  center !important;
    gap:              5px !important;
    min-width:        0 !important;
}
#kcRLOverlay .kc-leo-name {
    font-size:   1.2rem !important;
    font-weight: 800 !important;
    color:       #fff !important;
    line-height: 1.1 !important;
    margin:      0 !important;
}
#kcRLOverlay .kc-leo-badge {
    font-size: 0.68rem !important;
    padding:   2px 8px !important;
}
#kcRLOverlay .kc-modal-title.kc-leo-title {
    font-size:   0.9rem !important;
    line-height: 1.3 !important;
    margin:      0 !important;
}
/* iOS Safari Ecken-Fix (Ergänzung) */
.kc-zins-modal .kc-modal-leo {
    -webkit-mask-image: -webkit-radial-gradient(circle, white 100%, black 100%) !important;
    isolation: isolate !important;
}