/* ========================================
   Denkmal-Steuerrechner - Professional Theme
   Conservative, sophisticated financial calculator
   For high-income professionals (lawyers, doctors, executives)
   Light mode default with dark mode option
   ======================================== */

/* CSS Variables - Light Mode (Default) */
:root {
    /* Base - Clean warm whites */
    --bg-primary: #faf9f7;
    --bg-secondary: #f5f4f2;
    --bg-elevated: #ffffff;
    --bg-card: #ffffff;
    --bg-input: #ffffff;

    /* Accent - Warm gold/amber tones */
    --accent-primary: #b8860b;
    --accent-light: #c9a227;
    --accent-glow: rgba(184, 134, 11, 0.15);
    --accent-warm: #a67c00;
    --accent-copper: #996515;

    /* Text colors */
    --text-primary: #1a1816;
    --text-secondary: #5c5650;
    --text-muted: #807a70;
    --text-accent: #996515;

    /* Borders */
    --border-subtle: rgba(0, 0, 0, 0.06);
    --border-default: rgba(0, 0, 0, 0.1);
    --border-hover: rgba(0, 0, 0, 0.15);
    --border-accent: rgba(184, 134, 11, 0.4);

    /* Semantic */
    --success: #4a7c3a;
    --success-glow: rgba(74, 124, 58, 0.2);
    --warning: #b8860b;
    --error: #a54a4a;

    /* Shadows - subtle warm */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.12);
    --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.15);
    --shadow-glow: 0 0 20px var(--accent-glow);

    /* Radius - conservative, refined */
    --radius-sm: 4px;
    --radius: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;

    /* Transitions - subtle */
    --transition-fast: 150ms ease;
    --transition: 200ms ease;
    --transition-slow: 350ms ease;

    /* Legacy mappings for compatibility */
    --primary-900: #1a1816;
    --primary-800: #262420;
    --primary-700: #3a3632;
    --gray-900: #1a1816;
    --gray-800: #262420;
    --gray-700: #3a3632;
    --gray-600: #5c5650;
    --gray-500: #807a70;
    --gray-400: #a09890;
    --gray-300: #c5c0b8;
    --gray-200: rgba(0, 0, 0, 0.1);
    --gray-100: rgba(0, 0, 0, 0.06);
    --gray-50: #f5f4f2;
    --white: #ffffff;
    --accent-600: #b8860b;
    --accent-500: #c9a227;
    --accent-400: #d4b448;
    --accent-100: rgba(184, 134, 11, 0.1);

    /* Chart colors for light mode */
    --chart-line: #b8860b;
    --chart-fill-start: rgba(184, 134, 11, 0.25);
    --chart-fill-end: rgba(184, 134, 11, 0.02);
    --chart-grid: rgba(0, 0, 0, 0.06);
    --chart-text: #5c5650;
}

/* Dark Mode Override */
[data-theme="dark"] {
    /* Base - Deep charcoal with warm undertones */
    --bg-primary: #141210;
    --bg-secondary: #1a1816;
    --bg-elevated: #211f1c;
    --bg-card: #262420;
    --bg-input: #2d2b27;

    /* Accent - Warm gold/amber tones */
    --accent-primary: #c9a227;
    --accent-light: #d4b448;
    --accent-glow: rgba(201, 162, 39, 0.25);
    --accent-warm: #b8860b;
    --accent-copper: #b87333;

    /* Text colors */
    --text-primary: #f5f3f0;
    --text-secondary: #b5b0a8;
    --text-muted: #807a70;
    --text-accent: #d4b448;

    /* Borders */
    --border-subtle: rgba(255, 250, 240, 0.06);
    --border-default: rgba(255, 250, 240, 0.1);
    --border-hover: rgba(255, 250, 240, 0.15);
    --border-accent: rgba(201, 162, 39, 0.4);

    /* Semantic */
    --success: #5d8a4a;
    --success-glow: rgba(93, 138, 74, 0.3);
    --warning: #c9a227;

    /* Shadows - warm tinted */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.25);
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 16px 48px rgba(0, 0, 0, 0.5);

    /* Legacy dark mappings */
    --primary-900: #141210;
    --primary-800: #1a1816;
    --primary-700: #262420;
    --gray-900: #141210;
    --gray-800: #1a1816;
    --gray-700: #262420;
    --gray-600: #3a3632;
    --gray-500: #5c5650;
    --gray-400: #807a70;
    --gray-300: #b5b0a8;
    --gray-200: rgba(255, 250, 240, 0.1);
    --gray-100: rgba(255, 250, 240, 0.06);
    --gray-50: #1a1816;
    --white: #f5f3f0;
    --accent-600: #c9a227;
    --accent-500: #d4b448;

    /* Chart colors for dark mode */
    --chart-line: #c9a227;
    --chart-fill-start: rgba(201, 162, 39, 0.35);
    --chart-fill-end: rgba(184, 134, 11, 0.02);
    --chart-grid: rgba(255, 255, 255, 0.06);
    --chart-text: #737373;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden;
}

body {
    font-family:
        "Inter",
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        Roboto,
        sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--bg-primary);
    min-height: 100vh;
    transition:
        background-color var(--transition),
        color var(--transition);
    overflow-x: hidden;
}

/* Dark mode background gradient */
[data-theme="dark"] body {
    background-image:
        radial-gradient(
            ellipse 80% 50% at 50% -20%,
            rgba(201, 162, 39, 0.06),
            transparent
        ),
        radial-gradient(
            ellipse 60% 40% at 100% 50%,
            rgba(139, 90, 43, 0.04),
            transparent
        );
}

/* Container */
.container {
    max-width: 960px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1,
h2,
h3,
h4 {
    font-weight: 600;
    line-height: 1.25;
    color: var(--gray-900);
    letter-spacing: -0.025em;
}

h1 {
    font-size: 1.875rem;
}
h2 {
    font-size: 1.5rem;
    margin-bottom: 0.75rem;
}
h3 {
    font-size: 1.125rem;
    margin-bottom: 0.5rem;
}
h4 {
    font-size: 1rem;
    margin-bottom: 0.5rem;
    color: var(--gray-700);
    font-weight: 500;
}

p {
    margin-bottom: 1rem;
    color: var(--gray-600);
}

.hidden {
    display: none !important;
}

/* ========================================
   Header
   ======================================== */
.header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-subtle);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
    transition: background-color var(--transition);
}

[data-theme="dark"] .header {
    background: rgba(10, 10, 10, 0.8);
}

.header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
    letter-spacing: -0.02em;
}

.header-nav {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.nav-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: color var(--transition);
}

.nav-link:hover {
    color: var(--accent-primary);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.version-badge {
    background: var(--accent-primary);
    color: #ffffff;
    font-size: 0.6875rem;
    font-weight: 700;
    padding: 0.25rem 0.5rem;
    border-radius: var(--radius-sm);
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

/* Theme Toggle Button */
.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    background: var(--bg-card);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition);
}

.theme-toggle:hover {
    border-color: var(--accent-primary);
    color: var(--accent-primary);
}

.theme-toggle svg {
    width: 18px;
    height: 18px;
}

/* Light mode: show moon, hide sun */
.theme-toggle .icon-sun {
    display: none;
}
.theme-toggle .icon-moon {
    display: block;
}

/* Dark mode: show sun, hide moon */
[data-theme="dark"] .theme-toggle .icon-sun {
    display: block;
}
[data-theme="dark"] .theme-toggle .icon-moon {
    display: none;
}

/* ========================================
   Hero
   ======================================== */
.hero {
    background: transparent;
    padding: 3rem 0 2rem;
    text-align: center;
    position: relative;
}

.hero h1 {
    font-size: 2.25rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

.hero-subtitle {
    font-size: 1.125rem;
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.7;
}

/* ========================================
   Calculator Section
   ======================================== */
.calculator-section {
    padding: 1rem 0 4rem;
    margin-top: 0;
}

.calculator-card {
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-lg);
    padding: 2.5rem;
    border: 1px solid var(--border-default);
    position: relative;
    overflow: visible;
    max-width: 100%;
}

.calculator-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(
        90deg,
        transparent 10%,
        var(--accent-primary) 50%,
        transparent 90%
    );
    opacity: 0.6;
}

/* Quick Start */
.quick-start {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding-bottom: 1.5rem;
    margin-bottom: 2rem;
    border-bottom: 1px solid var(--border-subtle);
}

.quick-start-label {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.quick-start-btn {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--accent-light);
    background: rgba(201, 162, 39, 0.1);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius);
    cursor: pointer;
    transition: var(--transition);
}

.quick-start-btn:hover {
    background: rgba(201, 162, 39, 0.15);
    border-color: var(--accent-primary);
}

.quick-start-btn.active {
    background: var(--accent-primary);
    color: var(--bg-primary);
    border-color: var(--accent-primary);
}

.quick-start-divider {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.quick-start-hint {
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

/* Form Sections */
.form-section {
    margin-bottom: 2.5rem;
}

.form-section:last-of-type {
    margin-bottom: 2rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.section-icon {
    width: 26px;
    height: 26px;
    background: var(--accent-primary);
    color: var(--bg-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: 700;
}

/* Form Layout */
.form-row {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}

/* 3-column row with small last column */
.form-row:has(.form-group-small) {
    grid-template-columns: 1fr 1fr auto;
}

.form-group-small {
    min-width: 120px;
    max-width: 140px;
}

.form-row:last-child {
    margin-bottom: 0;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
}

.form-group.full-width {
    grid-column: span 2;
}

.form-group label {
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.375rem;
}

/* Tooltip */
.tooltip {
    width: 16px;
    height: 16px;
    background: var(--bg-input);
    color: var(--text-muted);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.625rem;
    font-weight: 600;
    cursor: help;
    position: relative;
    border: 1px solid var(--border-default);
}

.tooltip:hover {
    background: var(--accent-primary);
    color: var(--bg-primary);
    border-color: var(--accent-primary);
}

.tooltip:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    background: var(--bg-elevated);
    color: var(--text-primary);
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.8125rem;
    font-weight: 400;
    white-space: normal;
    max-width: 260px;
    width: max-content;
    z-index: 10;
    box-shadow: var(--shadow-lg);
    line-height: 1.5;
    border: 1px solid var(--border-default);
}

.tooltip:hover::before {
    content: "";
    position: absolute;
    bottom: calc(100% + 2px);
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-top-color: var(--bg-elevated);
}

/* Input Styles */
.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-wrapper input {
    width: 100%;
    padding: 0.75rem 1rem;
    padding-right: 2.5rem;
    font-size: 1rem;
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    background: var(--bg-input);
    transition: var(--transition);
    color: var(--text-primary);
}

.input-wrapper input::placeholder {
    color: var(--text-muted);
}

.input-suffix {
    position: absolute;
    right: 1rem;
    color: var(--text-muted);
    font-size: 0.875rem;
    font-weight: 500;
    pointer-events: none;
}

.input-wrapper input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(201, 162, 39, 0.15);
    background: var(--bg-elevated);
}

.input-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

/* Select */
select {
    width: 100%;
    padding: 0.75rem 1rem;
    padding-right: 2.5rem;
    font-size: 1rem;
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    background: var(--bg-input);
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23737373'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    background-size: 1rem;
    transition: var(--transition);
    color: var(--text-primary);
}

select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(201, 162, 39, 0.15);
    background: var(--bg-elevated);
}

select option {
    background: var(--bg-card);
    color: var(--text-primary);
}

/* Slider */
.slider-wrapper {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.slider-wrapper input[type="range"] {
    flex: 1;
    height: 6px;
    -webkit-appearance: none;
    background: var(--bg-input);
    border-radius: 3px;
    outline: none;
    border: 1px solid var(--border-subtle);
}

.slider-wrapper input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    background: var(--accent-primary);
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid var(--bg-card);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.slider-wrapper input[type="range"]::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.slider-wrapper input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    background: var(--accent-primary);
    border-radius: 50%;
    cursor: pointer;
    border: 2px solid var(--bg-card);
    box-shadow: var(--shadow-sm);
}

.slider-value {
    display: flex;
    align-items: center;
    gap: 0.375rem;
    min-width: 70px;
}

.slider-value input {
    width: 52px;
    padding: 0.5rem 0.5rem;
    text-align: center;
    font-size: 0.9375rem;
    font-weight: 600;
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    color: var(--text-primary);
    background: var(--bg-input);
}

.slider-value input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px var(--accent-glow);
}

.slider-value span {
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.9375rem;
}

/* Toggle Group */
.toggle-group {
    display: flex;
    gap: 0.625rem;
}

.toggle-option {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1rem;
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    text-align: center;
    background: var(--bg-input);
}

.toggle-option input {
    display: none;
}

.toggle-option span {
    font-weight: 500;
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

.toggle-option small {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.toggle-option:hover {
    border-color: var(--border-hover);
    background: var(--bg-elevated);
}

.toggle-option:has(input:checked) {
    border-color: var(--accent-primary);
    background: rgba(201, 162, 39, 0.1);
}

.toggle-option:has(input:checked) span {
    color: var(--accent-light);
    font-weight: 600;
}

.toggle-option:has(input:checked) small {
    color: var(--text-secondary);
}

.usage-toggle .toggle-option {
    padding: 1rem 1.25rem;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    font-size: 1rem;
    font-weight: 600;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    letter-spacing: 0.01em;
}

.btn-primary {
    background: var(--accent-primary);
    color: var(--bg-primary);
    width: 100%;
    box-shadow: var(--shadow);
}

.btn-primary:hover {
    background: var(--accent-light);
    box-shadow: var(--shadow-md);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-calculate {
    font-size: 1.0625rem;
    padding: 1rem 2rem;
    margin-top: 1rem;
}

.btn-accent {
    background: var(--accent-primary);
    color: var(--bg-primary);
    width: 100%;
    box-shadow: var(--shadow);
}

.btn-accent:hover {
    background: var(--accent-light);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background: transparent;
    color: var(--accent-light);
    border: 1px solid var(--border-accent);
}

.btn-outline:hover {
    background: rgba(201, 162, 39, 0.1);
    border-color: var(--accent-primary);
}

/* ========================================
   Results Section
   ======================================== */
.results-section {
    margin-top: 2.5rem;
    padding-top: 2.5rem;
    border-top: 1px solid var(--border-subtle);
    animation: fadeIn 0.5s ease;
    max-width: 100%;
    overflow-x: hidden;
}

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

/* Summary Cards */
.results-summary {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2.5rem;
    max-width: 100%;
}

.summary-card {
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    text-align: center;
    transition: var(--transition);
    min-width: 0;
    overflow: hidden;
}

.summary-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-2px);
}

.summary-card.highlight {
    background: rgba(201, 162, 39, 0.08);
    border-color: var(--accent-primary);
}

.summary-label {
    display: block;
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.summary-card.highlight .summary-label {
    color: var(--accent-light);
}

.summary-value {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    word-break: break-word;
}

.summary-card.highlight .summary-value {
    color: var(--accent-light);
    font-size: 1.75rem;
}

.summary-period {
    display: block;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.summary-card.highlight .summary-period {
    color: var(--text-secondary);
}

/* Charts */
.charts-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 2.5rem;
    max-width: 100%;
}

.chart-container {
    background: var(--bg-elevated);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    overflow: hidden;
    min-width: 0;
}

.chart-container h4 {
    margin-bottom: 1.25rem;
    text-align: center;
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-secondary);
}

/* Bar Chart */
.bar-chart {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 160px;
    gap: 6px;
    padding: 0 4px;
    border-bottom: 1px solid var(--border-subtle);
    padding-bottom: 10px;
    max-width: 100%;
    overflow: hidden;
}

.bar-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
    justify-content: flex-end;
}

.bar-stack {
    width: 100%;
    height: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
}

.bar {
    width: 100%;
    max-width: 32px;
    border-radius: 4px 4px 0 0;
    transition: all 0.4s ease;
}

.bar.denkmal {
    background: var(--accent-primary);
}

.bar.altbau {
    background: rgba(201, 162, 39, 0.35);
    border-radius: 0;
}

.bar-group:hover .bar {
    filter: brightness(1.2);
}

.bar-label {
    font-size: 0.6875rem;
    color: var(--text-muted);
    margin-top: 0.5rem;
    font-weight: 500;
}

.bar-value {
    font-size: 0.625rem;
    color: var(--text-secondary);
    font-weight: 600;
    margin-bottom: 0.375rem;
    white-space: nowrap;
}

.chart-legend {
    display: flex;
    justify-content: center;
    gap: 1.5rem;
    margin-top: 1rem;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: var(--text-secondary);
}

.legend-color {
    width: 14px;
    height: 14px;
    border-radius: 3px;
}

.legend-color.denkmal {
    background: var(--accent-primary);
}
.legend-color.altbau {
    background: rgba(201, 162, 39, 0.4);
}

/* Cumulative Chart */
.cumulative-chart {
    display: flex;
    flex-direction: column;
}

.line-chart-wrapper {
    position: relative;
    width: 100%;
    height: 160px;
    background: var(--bg-input);
    border-radius: var(--radius-md);
    border: 1px solid var(--border-subtle);
}

.line-chart-wrapper canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.cumulative-milestone {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.25rem;
    background: rgba(201, 162, 39, 0.08);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-md);
    margin-top: 1rem;
}

.milestone-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.milestone-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--accent-light);
}

/* Results Table */
.table-container {
    margin-bottom: 2rem;
}

.table-container h4 {
    margin-bottom: 1rem;
    color: var(--text-secondary);
}

.table-scroll {
    overflow-x: auto;
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-default);
}

.results-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.8125rem;
    table-layout: fixed;
}

.results-table th,
.results-table td {
    padding: 0.5rem 0.375rem;
    text-align: right;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-secondary);
    overflow: hidden;
    text-overflow: ellipsis;
}

.results-table th {
    background: var(--bg-input);
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.results-table th:first-child,
.results-table td:first-child {
    text-align: center;
    width: 2.5rem;
}

.results-table th.highlight-col,
.results-table td.highlight-col {
    background: rgba(184, 134, 11, 0.1);
    font-weight: 600;
    color: var(--accent-light);
}

.results-table tbody tr:hover {
    background: rgba(255, 255, 255, 0.02);
}

.results-table tfoot tr {
    background: var(--bg-elevated);
    font-weight: 600;
}

.results-table tfoot td {
    border-bottom: none;
    color: var(--text-primary);
}

/* Disclaimer */
.disclaimer {
    background: var(--bg-elevated);
    border-left: 3px solid var(--warning);
    padding: 1.25rem 1.5rem;
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.disclaimer strong {
    color: var(--text-primary);
}

/* ========================================
   Recommendation Section
   ======================================== */
.recommendation-section {
    padding: 3rem 0;
    background: transparent;
}

.recommendation-card {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    position: relative;
}

.recommendation-badge {
    position: absolute;
    top: -12px;
    left: 2rem;
    background: linear-gradient(
        135deg,
        var(--accent-primary),
        var(--accent-warm)
    );
    color: var(--bg-primary);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.375rem 0.875rem;
    border-radius: var(--radius);
}

.recommendation-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.recommendation-header h2 {
    margin-bottom: 0;
    color: var(--text-primary);
    font-size: 1.5rem;
}

.recommendation-tag {
    background: rgba(168, 85, 247, 0.15);
    color: var(--accent-light);
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.375rem 0.625rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-accent);
}

.recommendation-description {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1rem;
    line-height: 1.7;
}

.recommendation-stats {
    display: flex;
    gap: 3rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.stat {
    text-align: center;
}

.stat-value {
    display: block;
    font-size: 1.75rem;
    font-weight: 700;
    background: linear-gradient(
        135deg,
        var(--text-primary),
        var(--accent-light)
    );
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stat-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: 0.25rem;
}

.recommendation-features {
    list-style: none;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.recommendation-features li {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

.check-icon {
    width: 18px;
    height: 18px;
    background: linear-gradient(
        135deg,
        var(--accent-primary),
        var(--accent-warm)
    );
    border-radius: 50%;
    position: relative;
    flex-shrink: 0;
    box-shadow: 0 0 10px var(--accent-glow);
}

.check-icon::after {
    content: "";
    position: absolute;
    left: 6px;
    top: 3px;
    width: 5px;
    height: 8px;
    border: solid var(--bg-primary);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.recommendation-cta {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-subtle);
}

.recommendation-cta .btn {
    display: inline-flex;
    width: auto;
}

/* ========================================
   CTA Section
   ======================================== */
.cta-section {
    padding: 3rem 0;
    background: transparent;
}

.cta-card {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta-card::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(
        90deg,
        transparent,
        var(--accent-primary),
        var(--accent-warm),
        transparent
    );
}

.cta-card h2 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.cta-card > p {
    color: var(--text-secondary);
    margin-bottom: 2rem;
    font-size: 1rem;
}

.tally-embed {
    background: var(--bg-elevated);
    border-radius: var(--radius-lg);
    padding: 2rem;
    border: 1px solid var(--border-subtle);
}

.lead-form {
    text-align: left;
}

.lead-form .form-row {
    margin-bottom: 1.25rem;
}

.lead-form .form-group label {
    margin-bottom: 0.375rem;
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.lead-form input,
.lead-form select {
    width: 100%;
    padding: 0.75rem 1rem;
    font-size: 1rem;
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    transition: var(--transition);
    background: var(--bg-input);
    color: var(--text-primary);
}

.lead-form input::placeholder {
    color: var(--text-muted);
}

.lead-form input:focus,
.lead-form select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 2px rgba(201, 162, 39, 0.15);
    background: var(--bg-elevated);
}

.form-privacy {
    font-size: 0.8125rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 1.25rem;
    margin-bottom: 0;
}

.form-privacy a {
    color: var(--accent-light);
    text-decoration: none;
}

.form-privacy a:hover {
    text-decoration: underline;
}

/* Form Success */
.form-success {
    text-align: center;
    padding: 2.5rem 1.5rem;
}

.success-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--success), var(--accent-warm));
    color: var(--bg-primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.25rem;
    box-shadow: 0 0 30px var(--success-glow);
}

.form-success h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.form-success p {
    color: var(--text-secondary);
    margin-bottom: 0;
    font-size: 1rem;
}

/* ========================================
   Info Section
   ======================================== */
.info-section {
    padding: 4rem 0;
    background: var(--bg-secondary);
}

.info-section h2 {
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--text-primary);
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.info-card {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    transition: var(--transition);
}

.info-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
}

.info-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(
        135deg,
        var(--accent-primary),
        var(--accent-warm)
    );
    color: var(--bg-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9375rem;
    margin-bottom: 1rem;
    box-shadow: 0 0 20px var(--accent-glow);
}

.info-card h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1.125rem;
}

.info-card p {
    color: var(--text-secondary);
    margin-bottom: 0;
    font-size: 0.9375rem;
    line-height: 1.6;
}

.info-note {
    background: var(--bg-elevated);
    border-left: 3px solid var(--accent-primary);
    border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
    padding: 1.5rem 2rem;
    max-width: 760px;
    margin: 0 auto;
}

.info-note h3 {
    color: var(--accent-light);
    margin-bottom: 0.5rem;
    font-size: 1.125rem;
}

.info-note p {
    color: var(--text-secondary);
    margin-bottom: 0;
    font-size: 1rem;
    line-height: 1.7;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--bg-primary);
    border-top: 1px solid var(--border-subtle);
    padding: 2rem 0;
    text-align: center;
}

.footer-links {
    margin-bottom: 1rem;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    margin: 0 1rem;
    font-size: 0.875rem;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--accent-light);
}

.footer-copyright {
    color: var(--text-muted);
    font-size: 0.8125rem;
    margin-bottom: 0;
}

/* ========================================
   Responsive
   ======================================== */
@media (max-width: 900px) {
    .charts-wrapper {
        grid-template-columns: 1fr;
    }

    .results-summary {
        grid-template-columns: repeat(2, 1fr);
    }

    .info-grid {
        grid-template-columns: 1fr;
    }

    .recommendation-features {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 20px;
    }

    .hero {
        padding: 2rem 0 1.5rem;
    }

    .hero h1 {
        font-size: 1.75rem;
    }

    .calculator-card {
        padding: 1.5rem;
    }

    .quick-start {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .form-row:has(.form-group-small) {
        grid-template-columns: 1fr 1fr;
    }

    .form-group-small {
        min-width: unset;
        max-width: unset;
    }

    .form-group.full-width {
        grid-column: span 1;
    }

    .toggle-group {
        flex-direction: column;
    }

    .usage-toggle {
        flex-direction: row;
    }

    .slider-wrapper {
        flex-direction: column;
        align-items: stretch;
    }

    .slider-value {
        justify-content: center;
        margin-top: 0.5rem;
    }

    .results-summary {
        grid-template-columns: 1fr;
    }

    .summary-card.highlight {
        order: -1;
    }

    .bar-chart {
        height: 120px;
    }

    .bar-stack {
        height: 100px;
    }

    .bar-value {
        display: none;
    }

    .cumulative-milestone {
        flex-direction: column;
        text-align: center;
        gap: 0.375rem;
    }

    .recommendation-stats {
        justify-content: space-around;
    }

    .cta-card {
        padding: 1.5rem;
    }

    .tally-embed {
        padding: 1.25rem;
    }

    .lead-form .form-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 640px) {
    .header-nav {
        display: none;
    }
}

@media (max-width: 480px) {
    .hero h1 {
        font-size: 1.375rem;
    }

    .section-title {
        font-size: 0.875rem;
    }

    .tooltip:hover::after {
        left: 0;
        transform: none;
        max-width: 180px;
    }

    .btn-calculate {
        font-size: 0.9375rem;
        padding: 0.75rem 1rem;
    }

    .summary-value {
        font-size: 1.125rem;
    }

    .summary-card.highlight .summary-value {
        font-size: 1.25rem;
    }

    .results-table {
        font-size: 0.6875rem;
    }

    .results-table th,
    .results-table td {
        padding: 0.5rem 0.25rem;
    }

    .recommendation-card {
        padding: 1.25rem;
    }

    .stat-value {
        font-size: 1.25rem;
    }
}

/* Print */
@media print {
    .header,
    .hero,
    .btn,
    .cta-section,
    .recommendation-section,
    .footer,
    .quick-start {
        display: none;
    }

    .calculator-section {
        padding: 0;
        margin: 0;
    }

    .calculator-card {
        box-shadow: none;
        padding: 0;
        border: none;
    }

    .results-section {
        display: block !important;
    }
}

/* ========================================
   Action Cards (Project + PDF)
   ======================================== */
.action-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
}

.action-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.action-card-project {
    background: linear-gradient(
        135deg,
        rgba(184, 134, 11, 0.06),
        rgba(184, 134, 11, 0.02)
    );
    border-color: var(--border-accent);
}

.action-card-content {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.action-card-label {
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    color: var(--text-muted);
}

.action-card-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.8125rem;
    white-space: nowrap;
}

@media (max-width: 640px) {
    .action-cards {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .action-card {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
    }
}

/* ========================================
   FAQ Section
   ======================================== */
.faq-section {
    padding: 4rem 0;
    background: var(--bg-secondary);
}

.faq-section h2 {
    text-align: center;
    margin-bottom: 2.5rem;
    color: var(--text-primary);
}

.faq-list {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    margin-bottom: 0.75rem;
    overflow: hidden;
}

.faq-question {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1.25rem 1.5rem;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-primary);
    list-style: none;
    transition: background-color var(--transition);
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-question::after {
    content: "+";
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--accent-primary);
    transition: transform var(--transition);
}

.faq-item[open] .faq-question::after {
    content: "−";
}

.faq-item[open] .faq-question {
    border-bottom: 1px solid var(--border-subtle);
}

.faq-question:hover {
    background: var(--bg-elevated);
}

.faq-answer {
    padding: 1.25rem 1.5rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.faq-answer p {
    margin-bottom: 1rem;
}

.faq-answer p:last-child {
    margin-bottom: 0;
}

.faq-answer ul {
    margin: 0.75rem 0;
    padding-left: 1.5rem;
}

.faq-answer li {
    margin-bottom: 0.5rem;
}

/* ========================================
   Callback Section
   ======================================== */
.callback-section {
    padding: 3rem 0;
    background: var(--bg-primary);
}

.callback-card {
    background: linear-gradient(
        135deg,
        var(--accent-primary),
        var(--accent-warm)
    );
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    flex-wrap: wrap;
}

.callback-content h2 {
    color: #ffffff;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.callback-content p {
    color: rgba(255, 255, 255, 0.9);
    margin: 0;
}

.callback-form {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.callback-fields {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.callback-fields input,
.callback-fields select {
    padding: 0.75rem 1rem;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: var(--radius);
    background: rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-size: 0.9375rem;
    min-width: 160px;
}

.callback-fields input::placeholder {
    color: rgba(255, 255, 255, 0.7);
}

.callback-fields select option {
    background: var(--bg-card);
    color: var(--text-primary);
}

.callback-form .btn {
    white-space: nowrap;
}

.callback-success {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: #ffffff;
    font-weight: 600;
}

.callback-success svg {
    stroke: #ffffff;
}

@media (max-width: 768px) {
    .callback-card {
        flex-direction: column;
        text-align: center;
    }

    .callback-form {
        width: 100%;
        flex-direction: column;
    }

    .callback-fields {
        width: 100%;
        flex-direction: column;
    }

    .callback-fields input,
    .callback-fields select {
        width: 100%;
    }

    .callback-form .btn {
        width: 100%;
    }
}

/* ========================================
   Modal
   ======================================== */
.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.modal.hidden {
    display: none;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: var(--bg-card);
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    max-width: 420px;
    width: 100%;
    box-shadow: var(--shadow-lg);
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-20px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    width: 32px;
    height: 32px;
    border: none;
    background: var(--bg-elevated);
    border-radius: var(--radius);
    font-size: 1.5rem;
    line-height: 1;
    color: var(--text-muted);
    cursor: pointer;
    transition: all var(--transition);
}

.modal-close:hover {
    background: var(--bg-input);
    color: var(--text-primary);
}

.modal-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.modal-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(
        135deg,
        var(--accent-primary),
        var(--accent-warm)
    );
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.modal-icon svg {
    width: 32px;
    height: 32px;
    stroke: #ffffff;
}

.modal-header h3 {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.modal-header p {
    color: var(--text-secondary);
    margin: 0;
}

.modal-form .form-group {
    margin-bottom: 1rem;
}

.modal-form input {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 1rem;
}

.modal-form input:focus {
    outline: none;
    border-color: var(--accent-primary);
}

.btn-full {
    width: 100%;
}

.modal-privacy {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
    margin-top: 1rem;
    margin-bottom: 0;
}

.modal-success {
    text-align: center;
    padding: 1rem 0;
}

.success-checkmark {
    width: 64px;
    height: 64px;
    background: var(--success);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1rem;
}

.success-checkmark svg {
    width: 32px;
    height: 32px;
    stroke: #ffffff;
}

.modal-success h3 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.modal-success p {
    color: var(--text-secondary);
    margin: 0;
}

/* ========================================
   Optional Section (Financing)
   ======================================== */
.optional-section {
    border: 1px solid var(--border-subtle);
    border-radius: var(--radius);
    background: var(--bg-elevated);
    padding: 0.875rem 1rem;
    margin-top: 0.5rem;
}

.optional-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.optional-toggle {
    position: relative;
    cursor: pointer;
}

.optional-toggle input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-switch {
    display: block;
    width: 36px;
    height: 20px;
    background: var(--border-default);
    border-radius: 10px;
    transition: background var(--transition);
}

.toggle-switch::after {
    content: "";
    position: absolute;
    top: 2px;
    left: 2px;
    width: 16px;
    height: 16px;
    background: #ffffff;
    border-radius: 50%;
    transition: transform var(--transition);
}

.optional-toggle input:checked + .toggle-switch {
    background: var(--accent-primary);
}

.optional-toggle input:checked + .toggle-switch::after {
    transform: translateX(16px);
}

.optional-label {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
}

.optional-title {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary);
}

.optional-hint {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.optional-content {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-subtle);
}

.optional-content.hidden {
    display: none;
}

.financing-summary {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin-top: 0.75rem;
}

.financing-stat {
    text-align: center;
    padding: 0.5rem 0.375rem;
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border-subtle);
}

.financing-stat.highlight {
    background: rgba(74, 124, 58, 0.08);
    border-color: var(--success);
}

.financing-label {
    display: block;
    font-size: 0.625rem;
    color: var(--text-muted);
    margin-bottom: 0.125rem;
    text-transform: uppercase;
    letter-spacing: 0.02em;
}

.financing-value {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-primary);
}

.financing-stat.highlight .financing-value {
    color: var(--success);
}

@media (max-width: 640px) {
    .financing-summary {
        grid-template-columns: 1fr;
    }
}

/* ========================================
   Footer
   ======================================== */
.footer {
    padding: 2rem 0;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border-subtle);
}

.footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-links {
    display: flex;
    gap: 1.5rem;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.875rem;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: var(--accent-primary);
}

.footer-copyright {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin: 0;
}

@media (max-width: 640px) {
    .footer .container {
        flex-direction: column;
        text-align: center;
    }
}

/* ========================================
   Cities Section
   ======================================== */
.cities-section {
    padding: 4rem 0;
    background: var(--bg-primary);
}

.cities-section h2 {
    text-align: center;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.cities-intro {
    text-align: center;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2rem;
    font-size: 1rem;
}

.cities-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.cities-more {
    margin-top: 0;
}

.city-link {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius);
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all var(--transition);
}

.city-link:hover {
    border-color: var(--accent-primary);
    background: rgba(184, 134, 11, 0.05);
    color: var(--accent-primary);
    transform: translateY(-2px);
}

.cities-toggle {
    display: block;
    margin: 0 auto;
    margin-top: 1rem;
}

.cities-toggle .toggle-hide {
    display: none;
}

.cities-toggle .toggle-show.hidden {
    display: none;
}

.cities-toggle .toggle-hide.hidden {
    display: none;
}

.cities-toggle:not(.hidden) .toggle-hide:not(.hidden) {
    display: inline;
}

@media (max-width: 900px) {
    .cities-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 640px) {
    .cities-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .city-link {
        padding: 0.625rem 0.5rem;
        font-size: 0.8125rem;
    }
}

@media (max-width: 480px) {
    .cities-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ========================================
   Blog Section & Pages
   ======================================== */
.blog-section {
    padding: 4rem 0;
    background: var(--bg-secondary);
}

.blog-section h1 {
    text-align: center;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
}

.blog-intro {
    text-align: center;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 2.5rem;
    font-size: 1.0625rem;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.blog-card {
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all var(--transition);
}

.blog-card:hover {
    border-color: var(--border-hover);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.blog-card-content {
    padding: 1.5rem;
}

.blog-card-date {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.blog-card h3 {
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    font-size: 1.125rem;
    line-height: 1.4;
}

.blog-card h3 a {
    color: inherit;
    text-decoration: none;
    transition: color var(--transition);
}

.blog-card h3 a:hover {
    color: var(--accent-primary);
}

.blog-card-excerpt {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.blog-card-link {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    color: var(--accent-primary);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    transition: gap var(--transition);
}

.blog-card-link:hover {
    gap: 0.625rem;
}

.blog-card-link::after {
    content: "→";
}

/* Blog Article Page */
.article-section {
    padding: 3rem 0 4rem;
    background: var(--bg-primary);
}

.article-header {
    max-width: 720px;
    margin: 0 auto 2.5rem;
    text-align: center;
}

.article-meta {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.article-header h1 {
    font-size: 2rem;
    line-height: 1.3;
    margin-bottom: 1rem;
}

.article-intro {
    font-size: 1.125rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.article-content {
    max-width: 720px;
    margin: 0 auto;
}

.article-content h2 {
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    font-size: 1.5rem;
    color: var(--text-primary);
}

.article-content h3 {
    margin-top: 2rem;
    margin-bottom: 0.75rem;
    font-size: 1.25rem;
    color: var(--text-primary);
}

.article-content p {
    margin-bottom: 1.25rem;
    font-size: 1.0625rem;
    line-height: 1.8;
    color: var(--text-secondary);
}

.article-content ul,
.article-content ol {
    margin-bottom: 1.25rem;
    padding-left: 1.5rem;
}

.article-content li {
    margin-bottom: 0.5rem;
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--text-secondary);
}

.article-content strong {
    color: var(--text-primary);
}

.article-content a {
    color: var(--accent-primary);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.article-content a:hover {
    color: var(--accent-light);
}

.article-cta {
    margin-top: 3rem;
    padding: 2rem;
    background: rgba(184, 134, 11, 0.08);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-lg);
    text-align: center;
}

.article-cta h3 {
    margin-top: 0;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.article-cta p {
    margin-bottom: 1.25rem;
    color: var(--text-secondary);
}

.article-back {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2.5rem;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9375rem;
    transition: color var(--transition);
}

.article-back:hover {
    color: var(--accent-primary);
}

.article-back::before {
    content: "←";
}

@media (max-width: 768px) {
    .blog-grid {
        grid-template-columns: 1fr;
    }

    .article-header h1 {
        font-size: 1.5rem;
    }

    .article-content h2 {
        font-size: 1.25rem;
    }

    .article-content p,
    .article-content li {
        font-size: 1rem;
    }
}
