/* ------------------------- */
/* --- DESIGN SYSTEM & SETUP --- */
/* ------------------------- */
:root {
    --primary: #059669;
    --secondary: #fbbf24;
    --accent: #0891b2;
    --background: #fffbeb;
    --surface: #ffffff;
    --card: #f0fdf4;
    --text: #1f2937;
    --muted: #6b7280;

    --font-headings: 'Quicksand', sans-serif;
    --font-body: 'Nunito', sans-serif;

    --shadow-soft: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -2px rgba(0, 0, 0, 0.05);
    --shadow-medium: 0 10px 15px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.08);
    --shadow-large: 0 20px 40px rgba(0,0,0,0.06);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 100%; /* 16px */
}

body {
    font-family: var(--font-body);
    font-size: 1.125rem; /* 18px */
    line-height: 1.7;
    color: var(--text);
    background-color: var(--background);
}
body::after {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: radial-gradient(var(--primary) 0.5px, transparent 0.5px);
    background-size: 20px 20px;
    opacity: 0.03;
    pointer-events: none;
    z-index: -2;
}
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--background);
    z-index: -1;
}

h1, h2, h3, h4 {
    font-family: var(--font-headings);
    font-weight: 700;
    line-height: 1.2;
    color: var(--text);
}

h1 { font-size: 3.5rem; }
h2 { font-size: 2.25rem; }
h3 { font-size: 1.5rem; }

p { margin-bottom: 1rem; }
a { color: var(--primary); text-decoration: none; transition: color 0.3s; }
a:hover { color: var(--accent); }
ul { list-style: none; }
img { max-width: 100%; display: block; }

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
}

/* ------------------------- */
/* --- REUSABLE COMPONENTS --- */
/* ------------------------- */
.btn {
    display: inline-block;
    padding: 0.8rem 2.5rem;
    border-radius: 50px;
    font-family: var(--font-headings);
    font-weight: 700;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
    border: none;
    cursor: pointer;
}
.btn-primary {
    background: linear-gradient(45deg, var(--primary), var(--accent));
    color: white;
}
.btn-primary:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-medium);
    color: white;
}
.btn-secondary {
    background: var(--surface);
    color: var(--primary);
    border: 2px solid var(--primary);
}
.btn-secondary:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-soft);
    background: var(--primary);
    color: white;
}

.card {
    background-color: var(--surface);
    border-radius: 24px;
    box-shadow: var(--shadow-large);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}
.card:hover {
    transform: scale(1.02);
    box-shadow: 0 25px 50px rgba(0,0,0,0.1);
}
.card h3 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin: 1.5rem 1.5rem 0.5rem;
    color: var(--primary);
}
.card h3 svg { stroke: var(--primary); }
.card p {
    margin: 0 1.5rem 1.5rem;
    color: var(--muted);
}
.card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.section-intro {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 3rem;
}
.section-intro h2 { margin-bottom: 1rem; }

.wave-separator {
    background-color: var(--background);
    color: var(--card);
}
.wave-separator svg { display: block; }
.wave-separator .shape-fill { fill: currentColor; }
.wave-separator.wave-inverted { transform: scaleY(-1); background-color: var(--card); color: var(--background); }

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary);
    color: white;
    padding: 8px;
    z-index: 100;
    transition: top 0.3s;
}
.skip-link:focus { top: 0; }

/* ------------------------- */
/* --- ANIMATIONS --- */
/* ------------------------- */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.animate-on-scroll:nth-child(2) { transition-delay: 0.1s; }
.animate-on-scroll:nth-child(3) { transition-delay: 0.2s; }
.animate-on-scroll:nth-child(4) { transition-delay: 0.3s; }


/* ------------------------- */
/* --- HEADER & NAVIGATION --- */
/* ------------------------- */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 1.5rem 0;
    transition: background-color 0.4s, box-shadow 0.4s, padding 0.4s;
}
.main-header.scrolled {
    background-color: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-soft);
    padding: 1rem 0;
}
.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-family: var(--font-headings);
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--text);
}
.logo svg { stroke: var(--primary); }
.logo:hover { color: var(--text); }

.nav-links {
    display: flex;
    gap: 2.5rem;
}
.nav-links a {
    font-family: var(--font-headings);
    font-weight: 600;
    color: var(--text);
    position: relative;
}
.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 3px;
    background: linear-gradient(45deg, var(--primary), var(--accent));
    border-radius: 2px;
    transition: width 0.3s;
}
.nav-links a:hover::after {
    width: 100%;
}
.hamburger { display: none; }

/* ------------------------- */
/* --- SECTION STYLES --- */
/* ------------------------- */

/* SECTION 1: HERO */
.hero-section {
    padding: 12rem 0 6rem;
    background: linear-gradient(180deg, var(--background) 70%, var(--surface) 100%);
    overflow: hidden;
}
.hero-grid {
    display: grid;
    grid-template-columns: 55fr 45fr;
    align-items: center;
    gap: 4rem;
}
.hero-content .badge {
    display: inline-block;
    padding: 0.5rem 1rem;
    background-color: var(--card);
    color: var(--primary);
    border-radius: 50px;
    font-weight: 600;
    margin-bottom: 1rem;
}
.hero-content h1 { margin-bottom: 1.5rem; }
.hero-content .subtitle { font-size: 1.2rem; color: var(--muted); max-width: 50ch; }
.hero-buttons { margin-top: 2rem; display: flex; gap: 1rem; }
.hero-image img { border-radius: 24px; box-shadow: var(--shadow-large); }

/* SECTION 2: TRUST BADGES */
.trust-badges-section {
    background-color: var(--surface);
    padding: 3rem 0;
    border-top: 1px solid #eee;
}
.trust-badges-grid {
    display: flex;
    justify-content: space-around;
    gap: 2rem;
    flex-wrap: wrap;
}
.badge-item {
    text-align: center;
    color: var(--muted);
}
.badge-item .icon { font-size: 2rem; }
.badge-item p { margin: 0.5rem 0 0; line-height: 1.4; }

/* SECTION 3: PROBLEM/INTRO */
.problem-section {
    padding: 6rem 0;
    background-color: var(--surface);
}
.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

/* SECTION 4: GRUNDLAGEN */
.grundlagen-section {
    padding: 6rem 0;
    background-color: var(--card);
}
.two-column-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 4rem;
}
.two-column-grid .text-content {
    grid-column: 1 / 2;
    grid-row: 1 / 2;
}
.two-column-grid .image-content {
    grid-column: 2 / 3;
    grid-row: 1 / 2;
}
.grundlagen-section img { border-radius: 24px; box-shadow: var(--shadow-large); }

/* SECTION 5: SPARMETHODEN */
.sparmethoden-section {
    padding: 6rem 0;
    background-color: var(--background);
}
.spar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

/* SECTION 6: SPAREN FÜR KINDER */
.kinder-sparen-section {
    background-color: var(--primary);
    color: white;
    padding: 6rem 0;
}
.kinder-sparen-section h2, .kinder-sparen-section p { color: white; }
.kinder-sparen-section .text-content { color: rgba(255,255,255,0.9); }
.timeline {
    border-left: 3px solid var(--secondary);
    padding-left: 2rem;
}
.timeline-item {
    position: relative;
    padding: 1rem 0 2rem;
}
.timeline-item::before {
    content: '';
    position: absolute;
    left: -2rem;
    top: 1.3rem;
    transform: translateX(-50%);
    width: 16px;
    height: 16px;
    background-color: var(--secondary);
    border: 3px solid var(--primary);
    border-radius: 50%;
}
.timeline-item span {
    font-family: var(--font-headings);
    font-weight: 700;
    font-size: 1.2rem;
    color: var(--secondary);
    display: block;
    margin-bottom: 0.25rem;
}

/* SECTION 7: TOOLS & TECHNOLOGIE */
.tools-section {
    padding: 6rem 0;
    background-color: var(--surface);
}
.two-column-grid-reversed .text-content { grid-column: 2 / 3; }
.two-column-grid-reversed .image-content { grid-column: 1 / 2; }
.tools-section img { border-radius: 24px; box-shadow: var(--shadow-large); }

/* SECTION 8: CHECKLISTEN */
.checklisten-section {
    padding: 6rem 0;
    background-color: var(--card);
}
.checklisten-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}
.checklist {
    background-color: var(--surface);
    padding: 2rem;
    border-radius: 24px;
    box-shadow: var(--shadow-medium);
}
.checklist h3 { margin-bottom: 1.5rem; color: var(--primary); }
.checklist ul li {
    margin-bottom: 0.75rem;
    color: var(--muted);
}

/* SECTION 9: KALKULATOR */
.kalkulator-section {
    padding: 6rem 0;
    background-color: var(--background);
}
.kalkulator-card {
    background-color: var(--surface);
    padding: 3rem;
    border-radius: 24px;
    box-shadow: var(--shadow-large);
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}
.kalkulator-card h2 { margin-bottom: 1rem; }
.formula-box {
    border: 2px dashed var(--secondary);
    border-radius: 16px;
    padding: 1.5rem;
    margin: 2rem 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}
.formula-box p { font-size: 1.2rem; font-weight: 600; margin: 0; }
.formula-box span { font-size: 1.5rem; color: var(--primary); font-weight: 700; }
.beispiel-box {
    background-color: var(--card);
    padding: 1rem;
    border-radius: 16px;
    margin: 1.5rem 0;
}
.beispiel-box p { margin: 0; color: var(--muted); }

/* SECTION 10: TESTIMONIALS */
.testimonials-section {
    padding: 6rem 0;
    background-color: var(--surface);
}
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}
.testimonial-card {
    background-color: var(--card);
    padding: 2rem;
    border-radius: 24px;
    box-shadow: var(--shadow-soft);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.testimonial-card p { font-style: italic; color: var(--muted); margin: 0 0 1rem; }
.testimonial-card footer { border-top: 1px solid #ddd; padding-top: 1rem; }
.testimonial-card .rating { color: var(--secondary); }

/* SECTION 11: FAQ */
.faq-section {
    padding: 6rem 0;
    background-color: var(--card);
}
.accordion {
    max-width: 800px;
    margin: 0 auto;
}
.accordion details {
    background: var(--surface);
    border-radius: 16px;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-soft);
}
.accordion summary {
    padding: 1.5rem;
    font-family: var(--font-headings);
    font-weight: 600;
    font-size: 1.2rem;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
    content: '+';
    font-size: 1.5rem;
    color: var(--primary);
    transition: transform 0.3s;
}
.accordion details[open] summary::after {
    transform: rotate(45deg);
}
.accordion details[open] summary {
    color: var(--primary);
}
.accordion details p {
    padding: 0 1.5rem 1.5rem;
    margin: 0;
    color: var(--muted);
}

/* SECTION 12: KONTAKT */
.contact-section {
    padding: 6rem 0;
    background-color: var(--background);
}
.contact-form-wrapper h2, .contact-form-wrapper .subtitle {
    margin-bottom: 1rem;
}
.contact-form {
    display: grid;
    gap: 1.5rem;
}
.contact-form input, .contact-form select, .contact-form textarea {
    width: 100%;
    padding: 1rem;
    border: 1px solid #ccc;
    border-radius: 12px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(5, 150, 105, 0.2);
}
.checkbox-wrapper { display: flex; align-items: center; gap: 0.5rem; }
.checkbox-wrapper input { width: auto; }
.contact-info-wrapper {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}
.contact-info {
    background-color: var(--card);
    padding: 2rem;
    border-radius: 24px;
    box-shadow: var(--shadow-medium);
}
.contact-info p { margin-bottom: 1rem; }
.contact-info p:last-child { margin-bottom: 0; }
.contact-info a { font-weight: 600; }

/* SECTION 13: CTA BANNER */
.cta-banner {
    padding: 5rem 0;
    background: linear-gradient(45deg, var(--primary), var(--accent));
    color: white;
    text-align: center;
}
.cta-banner h2 { color: white; margin-bottom: 1rem; }
.cta-banner p { max-width: 60ch; margin: 0 auto 2rem; }
.cta-banner .btn-secondary { background: white; color: var(--primary); border-color: white; }
.cta-banner .btn-secondary:hover { background: transparent; color: white; }

/* ------------------------- */
/* --- FOOTER --- */
/* ------------------------- */
.main-footer {
    background-color: var(--primary);
    color: white;
}
.footer-wave {
    background-color: transparent;
    color: var(--primary);
    transform: scaleX(-1);
}
.footer-wave .shape-fill { fill: currentColor; }
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 3rem;
    padding: 4rem 0;
}
.footer-col h4 {
    font-family: var(--font-headings);
    color: var(--secondary);
    margin-bottom: 1.5rem;
}
.footer-col p, .footer-col a { color: rgba(255,255,255,0.85); }
.footer-col ul li { margin-bottom: 0.75rem; }
.footer-col ul a:hover { color: white; padding-left: 5px; }
.footer-logo { font-size: 1rem; margin-bottom: 1rem; color: white; }
.footer-logo svg { stroke: var(--secondary); }
.footer-logo:hover { color: white; }
.footer-col address { font-style: normal; line-height: 1.8; }
.footer-disclaimer {
    padding: 2rem 0;
    background-color: rgba(0,0,0,0.1);
}
.footer-disclaimer p { font-size: 0.8rem; color: rgba(255,255,255,0.7); margin: 0; }
.footer-bottom-bar {
    padding: 1.5rem 0;
    background-color: rgba(0,0,0,0.2);
    text-align: center;
}
.footer-bottom-bar p {
    font-size: 0.9rem;
    margin: 0;
    color: rgba(255,255,255,0.8);
}


/* ------------------------- */
/* --- RESPONSIVE DESIGN --- */
/* ------------------------- */
@media (max-width: 992px) {
    h1 { font-size: 2.8rem; }
    h2 { font-size: 2rem; }
    
    .hero-grid { grid-template-columns: 1fr; text-align: center; }
    .hero-content { order: 2; }
    .hero-image { order: 1; margin-bottom: 2rem; }
    .hero-content .subtitle { margin-left: auto; margin-right: auto; }
    .hero-buttons { justify-content: center; }

    .two-column-grid, .two-column-grid-reversed { grid-template-columns: 1fr; }
    .two-column-grid .text-content,
    .two-column-grid .image-content,
    .two-column-grid-reversed .text-content,
    .two-column-grid-reversed .image-content {
        grid-column: 1 / 2;
        text-align: center;
    }
    .two-column-grid .image-content, .two-column-grid-reversed .image-content {
        margin-bottom: 2rem;
    }
    .checklisten-grid { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .nav-links {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        height: 100vh;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        background-color: var(--surface);
        box-shadow: var(--shadow-large);
        transition: right 0.4s ease-in-out;
        gap: 3rem;
    }
    .nav-links.active { right: 0; }
    .nav-links a { font-size: 1.5rem; }

    .hamburger {
        display: flex;
        flex-direction: column;
        justify-content: space-around;
        width: 30px;
        height: 25px;
        background: transparent;
        border: none;
        cursor: pointer;
        z-index: 1001;
    }
    .hamburger span {
        width: 30px;
        height: 3px;
        background-color: var(--text);
        border-radius: 2px;
        transition: all 0.3s linear;
        transform-origin: 1px;
    }
    .hamburger.active span:nth-child(1) { transform: rotate(45deg); }
    .hamburger.active span:nth-child(2) { opacity: 0; transform: translateX(20px); }
    .hamburger.active span:nth-child(3) { transform: rotate(-45deg); }

    .trust-badges-grid { grid-template-columns: 1fr 1fr; }
    .footer-grid { text-align: center; }
    .footer-col address, .footer-col ul { text-align: center; }
}

@media (max-width: 480px) {
    h1 { font-size: 2.2rem; }
    .hero-section { padding: 9rem 0 4rem; }
    .trust-badges-grid { grid-template-columns: 1fr; gap: 1rem; }
    .kalkulator-card { padding: 1.5rem; }
    .formula-box { flex-direction: column; }
    .btn { width: 100%; }
    .hero-buttons { flex-direction: column; }
}