/* ============================================================================
   KfW Helper — Design System & Landing Page Styles
   Clean, enterprise-grade 2026 design
   ============================================================================ */

/* ── Reset & Base ────────────────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
    /* Brand Colors */
    --brand-50: #eff6ff;
    --brand-100: #dbeafe;
    --brand-200: #bfdbfe;
    --brand-300: #93c5fd;
    --brand-400: #60a5fa;
    --brand-500: #3b82f6;
    --brand-600: #2563eb;
    --brand-700: #1d4ed8;
    --brand-800: #1e40af;
    --brand-900: #1e3a8a;

    /* Neutral */
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;

    /* Semantic */
    --success: #10b981;
    --warning: #f59e0b;
    --error: #ef4444;

    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

    /* Spacing */
    --section-y: 6rem;
    --container-max: 1200px;
    --container-px: 1.5rem;

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.07), 0 2px 4px -2px rgba(0,0,0,0.05);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.08), 0 4px 6px -4px rgba(0,0,0,0.04);
    --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.08), 0 8px 10px -6px rgba(0,0,0,0.04);

    /* Radius */
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --radius-full: 9999px;

    /* Transitions */
    --ease: cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-sans);
    color: var(--gray-800);
    background: white;
    line-height: 1.6;
    font-size: 16px;
}

a { color: var(--brand-600); text-decoration: none; transition: color 0.15s var(--ease); }
a:hover { color: var(--brand-700); }
img { max-width: 100%; height: auto; display: block; }

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-px);
}

/* ── Typography ──────────────────────────────────────────────────────────── */
h1, h2, h3, h4, h5 {
    color: var(--gray-900);
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: -0.02em;
}
h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h3 { font-size: 1.25rem; }
.text-sm { font-size: 0.875rem; }
.text-muted { color: var(--gray-500); }
.text-center { text-align: center; }

/* ── Buttons ─────────────────────────────────────────────────────────────── */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: var(--font-sans);
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s var(--ease);
    line-height: 1;
    white-space: nowrap;
}
.btn:focus-visible { outline: 2px solid var(--brand-500); outline-offset: 2px; }

.btn-primary {
    background: var(--brand-600);
    color: white;
    box-shadow: 0 1px 2px rgba(37,99,235,0.3);
}
.btn-primary:hover {
    background: var(--brand-700);
    box-shadow: 0 4px 12px rgba(37,99,235,0.3);
    transform: translateY(-1px);
    color: white;
}

.btn-secondary {
    background: white;
    color: var(--gray-700);
    border: 1px solid var(--gray-300);
}
.btn-secondary:hover {
    background: var(--gray-50);
    border-color: var(--gray-400);
    color: var(--gray-900);
}

.btn-lg { padding: 1rem 2rem; font-size: 1.0625rem; border-radius: var(--radius-lg); }
.btn-sm { padding: 0.5rem 1rem; font-size: 0.8125rem; }

/* ── Badge ───────────────────────────────────────────────────────────────── */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.8125rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    background: var(--brand-50);
    color: var(--brand-700);
    border: 1px solid var(--brand-200);
}

/* ── Navigation ──────────────────────────────────────────────────────────── */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(255,255,255,0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--gray-200);
    transition: box-shadow 0.3s var(--ease);
}
.nav.scrolled { box-shadow: var(--shadow-md); }

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4rem;
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 var(--container-px);
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.125rem;
    color: var(--gray-900);
}
.nav-logo-icon {
    width: 2rem;
    height: 2rem;
    background: var(--brand-600);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 800;
    font-size: 0.875rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}
.nav-links a {
    color: var(--gray-600);
    font-size: 0.9375rem;
    font-weight: 500;
    transition: color 0.15s var(--ease);
}
.nav-links a:hover { color: var(--gray-900); }

.nav-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.nav-mobile-toggle {
    display: none;
    background: none;
    border: none;
    padding: 0.5rem;
    cursor: pointer;
}

/* ── Hero ────────────────────────────────────────────────────────────────── */
.hero {
    padding: 8rem 0 var(--section-y);
    background: linear-gradient(180deg, var(--brand-50) 0%, white 100%);
}
.hero-inner {
    max-width: 720px;
    margin: 0 auto;
    text-align: center;
}
.hero h1 {
    margin-bottom: 1.25rem;
}
.hero h1 span { color: var(--brand-600); }
.hero-subtitle {
    font-size: 1.25rem;
    color: var(--gray-600);
    line-height: 1.7;
    margin-bottom: 2rem;
    max-width: 580px;
    margin-left: auto;
    margin-right: auto;
}
.hero-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 2.5rem;
}
.hero-proof {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    color: var(--gray-500);
    font-size: 0.875rem;
}
.hero-proof-item {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}
.hero-proof-icon { color: var(--success); }

/* ── Stats Bar ───────────────────────────────────────────────────────────── */
.stats-bar {
    padding: 3rem 0;
    border-bottom: 1px solid var(--gray-200);
}
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    text-align: center;
}
.stat-value {
    font-size: 2rem;
    font-weight: 800;
    color: var(--brand-600);
    line-height: 1;
    margin-bottom: 0.5rem;
}
.stat-label {
    font-size: 0.875rem;
    color: var(--gray-500);
}

/* ── How It Works ────────────────────────────────────────────────────────── */
.how-it-works { padding: var(--section-y) 0; }
.section-header {
    text-align: center;
    margin-bottom: 3rem;
}
.section-header p {
    color: var(--gray-500);
    font-size: 1.125rem;
    margin-top: 0.75rem;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}
.step-card {
    text-align: center;
    padding: 2rem;
    border-radius: var(--radius-xl);
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    transition: all 0.2s var(--ease);
}
.step-card:hover {
    border-color: var(--brand-200);
    box-shadow: var(--shadow-md);
}
.step-number {
    width: 3rem;
    height: 3rem;
    border-radius: var(--radius-full);
    background: var(--brand-600);
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    margin-bottom: 1rem;
}
.step-card h3 { margin-bottom: 0.5rem; }
.step-card p { color: var(--gray-500); font-size: 0.9375rem; }

/* ── Features ────────────────────────────────────────────────────────────── */
.features {
    padding: var(--section-y) 0;
    background: var(--gray-50);
}
.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}
.feature-card {
    background: white;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 1.75rem;
    transition: all 0.2s var(--ease);
}
.feature-card:hover {
    border-color: var(--brand-200);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}
.feature-icon {
    width: 2.5rem;
    height: 2.5rem;
    border-radius: var(--radius-md);
    background: var(--brand-50);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1rem;
    font-size: 1.25rem;
}
.feature-card h3 { margin-bottom: 0.5rem; font-size: 1.0625rem; }
.feature-card p { color: var(--gray-500); font-size: 0.9375rem; line-height: 1.6; }

/* ── ROI Calculator ──────────────────────────────────────────────────────── */
.roi-section { padding: var(--section-y) 0; }
.roi-card {
    background: var(--gray-900);
    border-radius: var(--radius-xl);
    padding: 3rem;
    color: white;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
}
.roi-content h2 { color: white; margin-bottom: 1rem; }
.roi-content p { color: var(--gray-400); font-size: 1.0625rem; margin-bottom: 1.5rem; }
.roi-highlight {
    font-size: 3.5rem;
    font-weight: 800;
    color: var(--brand-400);
    line-height: 1;
    margin-bottom: 0.5rem;
}
.roi-highlight-label { color: var(--gray-400); font-size: 0.875rem; }

.roi-table { width: 100%; }
.roi-table tr { border-bottom: 1px solid rgba(255,255,255,0.1); }
.roi-table td { padding: 0.75rem 0; font-size: 0.9375rem; }
.roi-table td:first-child { color: var(--gray-400); }
.roi-table td:last-child { text-align: right; font-weight: 600; color: white; }

/* ── Pricing ─────────────────────────────────────────────────────────────── */
.pricing {
    padding: var(--section-y) 0;
    background: var(--gray-50);
}
.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    align-items: start;
}
.pricing-card {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-xl);
    padding: 2rem;
    transition: all 0.2s var(--ease);
    position: relative;
}
.pricing-card.featured {
    border-color: var(--brand-500);
    box-shadow: var(--shadow-xl);
    transform: scale(1.03);
}
.pricing-card.featured .pricing-badge {
    position: absolute;
    top: -0.75rem;
    left: 50%;
    transform: translateX(-50%);
    background: var(--brand-600);
    color: white;
    padding: 0.25rem 1rem;
    border-radius: var(--radius-full);
    font-size: 0.8125rem;
    font-weight: 600;
    white-space: nowrap;
}
.pricing-name {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}
.pricing-desc {
    font-size: 0.875rem;
    color: var(--gray-500);
    margin-bottom: 1.5rem;
}
.pricing-price {
    display: flex;
    align-items: baseline;
    gap: 0.25rem;
    margin-bottom: 1.5rem;
}
.pricing-amount {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--gray-900);
    line-height: 1;
}
.pricing-period {
    color: var(--gray-500);
    font-size: 0.9375rem;
}
.pricing-features {
    list-style: none;
    margin-bottom: 1.5rem;
}
.pricing-features li {
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
    padding: 0.5rem 0;
    font-size: 0.9375rem;
    color: var(--gray-700);
}
.pricing-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 700;
    flex-shrink: 0;
}
.pricing-card .btn { width: 100%; }

/* ── FAQ ─────────────────────────────────────────────────────────────────── */
.faq { padding: var(--section-y) 0; }
.faq-list {
    max-width: 720px;
    margin: 0 auto;
}
.faq-item {
    border-bottom: 1px solid var(--gray-200);
}
.faq-question {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 0;
    background: none;
    border: none;
    cursor: pointer;
    font-family: var(--font-sans);
    font-size: 1rem;
    font-weight: 600;
    color: var(--gray-900);
    text-align: left;
    transition: color 0.15s var(--ease);
}
.faq-question:hover { color: var(--brand-600); }
.faq-chevron {
    width: 1.25rem;
    height: 1.25rem;
    transition: transform 0.2s var(--ease);
    flex-shrink: 0;
    color: var(--gray-400);
}
.faq-item.open .faq-chevron { transform: rotate(180deg); }
.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s var(--ease), padding 0.3s var(--ease);
}
.faq-item.open .faq-answer {
    max-height: 500px;
    padding-bottom: 1.25rem;
}
.faq-answer p {
    color: var(--gray-600);
    font-size: 0.9375rem;
    line-height: 1.7;
}

/* ── CTA ─────────────────────────────────────────────────────────────────── */
.cta-section {
    padding: var(--section-y) 0;
    background: var(--brand-600);
    color: white;
    text-align: center;
}
.cta-section h2 { color: white; margin-bottom: 1rem; }
.cta-section p { color: rgba(255,255,255,0.8); font-size: 1.125rem; margin-bottom: 2rem; max-width: 560px; margin-left: auto; margin-right: auto; }
.btn-white {
    background: white;
    color: var(--brand-700);
    font-weight: 700;
}
.btn-white:hover {
    background: var(--gray-100);
    color: var(--brand-800);
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

/* ── Footer ──────────────────────────────────────────────────────────────── */
.footer {
    padding: 3rem 0;
    border-top: 1px solid var(--gray-200);
    background: var(--gray-50);
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.footer-links {
    display: flex;
    gap: 1.5rem;
    list-style: none;
}
.footer-links a { color: var(--gray-500); font-size: 0.875rem; }
.footer-links a:hover { color: var(--gray-700); }
.footer-copy { color: var(--gray-400); font-size: 0.875rem; }

/* ── Responsive ──────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    :root {
        --section-y: 4rem;
        --container-px: 1.25rem;
    }

    .nav-links { display: none; }
    .nav-mobile-toggle { display: block; }

    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
    .steps-grid { grid-template-columns: 1fr; gap: 1.5rem; }
    .features-grid { grid-template-columns: 1fr; }
    .pricing-grid { grid-template-columns: 1fr; max-width: 400px; margin: 0 auto; }
    .pricing-card.featured { transform: none; }

    .roi-card { grid-template-columns: 1fr; gap: 2rem; }
    .roi-highlight { font-size: 2.5rem; }

    .hero { padding: 6rem 0 3rem; }
    .hero-actions { flex-direction: column; align-items: center; }
    .hero-actions .btn { width: 100%; max-width: 320px; }

    .footer-inner { flex-direction: column; text-align: center; }
}

@media (max-width: 480px) {
    .stats-grid { grid-template-columns: 1fr 1fr; gap: 1rem; }
    .stat-value { font-size: 1.5rem; }
    .roi-card { padding: 2rem 1.5rem; }
}
