/* IE Immobilien-Rechner */

/* Breadcrumb */
.ie-breadcrumb {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 16px;
    flex-wrap: wrap;
}
.ie-breadcrumb a {
    color: #4a4a4a;
    text-decoration: none;
    font-weight: 500;
}
.ie-breadcrumb a:hover { text-decoration: underline; }
.ie-breadcrumb__sep { color: #d1d5db; }

/* Anleitung Toggle */
.ie-anleitung { margin-bottom: 16px; }
.ie-anleitung__toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 10px 14px;
    background: var(--ie-gray-50, #f9fafb);
    border: 1px solid var(--ie-gray-200, #e5e7eb);
    border-radius: var(--ie-radius, 8px);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-gray-700, #374151);
    text-align: left;
    transition: background .2s;
}
.ie-anleitung__toggle:hover { background: var(--ie-gray-100, #f3f4f6); }
.ie-anleitung__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: var(--ie-primary, #4a4a4a);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    flex-shrink: 0;
}
.ie-anleitung__arrow {
    margin-left: auto;
    font-size: 10px;
    transition: transform .2s;
}
.ie-anleitung--open .ie-anleitung__arrow { transform: rotate(180deg); }
.ie-anleitung__content {
    display: none;
    padding: 14px 16px;
    margin-top: 4px;
    background: var(--ie-gray-50, #f9fafb);
    border: 1px solid var(--ie-gray-200, #e5e7eb);
    border-radius: var(--ie-radius, 8px);
    font-size: 13px;
    line-height: 1.6;
    color: var(--ie-gray-700, #374151);
}
.ie-anleitung--open .ie-anleitung__content { display: block; }
.ie-anleitung__content p { margin: 0 0 10px; }
.ie-anleitung__content p:last-child { margin-bottom: 0; }
.ie-anleitung__content ol { margin: 0 0 10px; padding-left: 20px; }
.ie-anleitung__content li { margin-bottom: 6px; }

:root {
    --ie-primary: #4a4a4a;
    --ie-primary-dark: #333333;
    --ie-primary-light: rgba(74,74,74,.06);
    --ie-accent: #c8975c;
    --ie-accent-light: rgba(200,151,92,.10);
    --ie-success: #16a34a;
    --ie-danger: #dc2626;
    --ie-warning: #d97706;
    --ie-gray-50: #f9fafb;
    --ie-gray-100: #f3f4f6;
    --ie-gray-200: #e5e7eb;
    --ie-gray-300: #d1d5db;
    --ie-gray-500: #6b7280;
    --ie-gray-700: #374151;
    --ie-gray-900: #111827;
    --ie-radius: 10px;
    --ie-shadow: 0 2px 8px rgba(0,0,0,.08);
    --ie-font-heading: 'Montserrat', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    --ie-font-accent: 'Oswald', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

.ie-rechner {
    max-width: 960px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 14px;
    color: var(--ie-gray-900);
    line-height: 1.5;
}

.ie-rechner *, .ie-rechner *::before, .ie-rechner *::after {
    box-sizing: border-box;
}

/* Header / Step Navigation */
.ie-rechner__header {
    margin-bottom: 24px;
}

.ie-rechner__title {
    font-family: var(--ie-font-heading);
    font-size: 22px;
    font-weight: 700;
    margin: 0 0 16px;
}

.ie-rechner__steps-nav {
    display: flex;
    gap: 4px;
    border-bottom: 2px solid var(--ie-gray-200);
    padding-bottom: 0;
}

.ie-step-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-size: 13px;
    color: var(--ie-gray-500);
    transition: all .2s;
}

.ie-step-btn:hover {
    color: var(--ie-gray-700);
}

.ie-step-btn--active {
    color: var(--ie-primary);
    border-bottom-color: var(--ie-primary);
}

.ie-step-btn--completed {
    color: var(--ie-success);
}

.ie-step-btn__num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--ie-gray-200);
    font-size: 12px;
    font-weight: 600;
}

.ie-step-btn--active .ie-step-btn__num {
    background: var(--ie-primary);
    color: #fff;
}

.ie-step-btn--completed .ie-step-btn__num {
    background: var(--ie-success);
    color: #fff;
}

/* Footer / Navigation buttons */
.ie-rechner__footer {
    margin-top: 24px;
    padding: 20px 24px;
    background: var(--ie-gray-50);
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
}

/* Progress bar in footer */
.ie-progress {
    margin-bottom: 16px;
}

.ie-progress__steps {
    display: flex;
    align-items: center;
    gap: 0;
}

.ie-progress__step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    flex-shrink: 0;
}

.ie-progress__dot {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--ie-gray-200);
    color: var(--ie-gray-500);
    font-size: 13px;
    font-weight: 700;
    transition: all .3s;
}

.ie-progress__step--active .ie-progress__dot {
    background: var(--ie-primary);
    color: #fff;
    box-shadow: 0 0 0 4px rgba(74,74,74,.15);
}

.ie-progress__step--completed .ie-progress__dot {
    background: var(--ie-success);
    color: #fff;
}

.ie-progress__step--completed .ie-progress__dot::after {
    content: '\2713';
    font-size: 15px;
}

.ie-progress__step--completed .ie-progress__dot {
    font-size: 0;
}

.ie-progress__steplabel {
    font-size: 11px;
    font-weight: 600;
    color: var(--ie-gray-500);
    white-space: nowrap;
}

.ie-progress__step--active .ie-progress__steplabel {
    color: var(--ie-primary);
}

.ie-progress__step--completed .ie-progress__steplabel {
    color: var(--ie-success);
}

.ie-progress__connector {
    flex: 1;
    height: 3px;
    background: var(--ie-gray-200);
    margin: 0 4px;
    border-radius: 2px;
    margin-bottom: 18px;
}

.ie-progress__connector-fill {
    height: 100%;
    width: 0;
    background: var(--ie-success);
    border-radius: 2px;
    transition: width .4s ease;
}

.ie-progress__connector--filled .ie-progress__connector-fill {
    width: 100%;
}

.ie-footer__buttons {
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.ie-footer__buttons .ie-btn--primary {
    margin-left: auto;
}

.ie-btn__icon {
    font-size: 16px;
    vertical-align: middle;
}

.ie-btn {
    padding: 10px 24px;
    border: none;
    border-radius: var(--ie-radius);
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
}

.ie-btn--primary {
    background: var(--ie-primary);
    color: #fff;
    padding: 12px 32px;
    font-size: 15px;
}

.ie-btn--primary:hover {
    background: var(--ie-primary-dark);
}

.ie-btn--secondary {
    background: var(--ie-gray-100);
    color: var(--ie-gray-700);
}

.ie-btn--secondary:hover {
    background: var(--ie-gray-200);
}

.ie-btn--outline {
    background: #fff;
    color: var(--ie-primary);
    border: 1px solid var(--ie-primary);
    padding: 8px 16px;
    font-size: 13px;
}

.ie-btn--outline:hover {
    background: var(--ie-gray-50);
}

/* Step content */
.ie-step__title {
    font-family: var(--ie-font-heading);
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 16px;
}

/* Form sections */
.ie-form-section {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 20px;
    margin-bottom: 24px;
    box-shadow: var(--ie-shadow);
}

.ie-form-section__title {
    font-family: var(--ie-font-accent);
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 14px;
    color: var(--ie-gray-700);
    text-transform: uppercase;
    letter-spacing: .3px;
}

.ie-form-row {
    display: flex;
    gap: 16px;
}

.ie-form-section--half {
    flex: 1;
    min-width: 0;
}

.ie-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}

.ie-form-grid--single {
    grid-template-columns: 1fr;
}

.ie-field {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.ie-field label {
    font-size: 12px;
    font-weight: 500;
    color: var(--ie-gray-500);
}

.ie-field input,
.ie-field select {
    padding: 7px 10px;
    border: 1px solid var(--ie-gray-300);
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
    transition: border-color .2s;
}

.ie-field input:focus,
.ie-field select:focus {
    outline: none;
    border-color: var(--ie-primary);
    box-shadow: 0 0 0 2px rgba(74,74,74,.12);
}

/* Validation */
.ie-field--warning {
    border-color: var(--ie-warning) !important;
}

.ie-field--error {
    border-color: var(--ie-danger) !important;
}

.ie-field__message {
    font-size: 11px;
    margin-top: 2px;
    line-height: 1.3;
}

.ie-field__message--warning {
    color: var(--ie-warning);
}

.ie-field__message--error {
    color: var(--ie-danger);
}

.ie-field__hint {
    font-size: 11px;
    color: var(--ie-gray-500);
    margin-top: 2px;
}

.ie-field--divider {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid var(--ie-gray-200);
}

/* Investments table */
.ie-investments-table {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.ie-investments-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 32px;
    gap: 8px;
    align-items: center;
}

.ie-investments-row--header {
    font-size: 12px;
    font-weight: 600;
    color: var(--ie-gray-500);
}

.ie-investments-row input,
.ie-investments-row select {
    padding: 7px 10px;
    border: 1px solid var(--ie-gray-300);
    border-radius: 4px;
    font-size: 14px;
}

.ie-btn--small {
    padding: 6px 12px;
    font-size: 12px;
    background: var(--ie-gray-100);
    border: 1px solid var(--ie-gray-300);
    border-radius: 4px;
    cursor: pointer;
    margin-top: 8px;
    color: var(--ie-gray-700);
    font-weight: 600;
}

.ie-btn--small:hover {
    background: var(--ie-gray-200);
}

.ie-btn--remove {
    padding: 4px 8px;
    background: none;
    border: 1px solid var(--ie-gray-300);
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
    color: var(--ie-gray-500);
    line-height: 1;
}

.ie-btn--remove:hover {
    background: #fef2f2;
    color: var(--ie-danger);
    border-color: var(--ie-danger);
}

/* Info box (computed values) */
.ie-info-box {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 12px 16px;
    margin-top: 12px;
}

.ie-info-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    font-size: 13px;
}

.ie-info-row--total {
    font-weight: 700;
    border-top: 1px solid var(--ie-gray-200);
    margin-top: 4px;
    padding-top: 8px;
}

/* Results actions */
.ie-results-actions {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.ie-results-actions select {
    padding: 8px 12px;
    border: 1px solid var(--ie-gray-300);
    border-radius: var(--ie-radius);
    font-size: 13px;
}

/* Share Buttons */
.ie-share-buttons {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-left: auto;
}
.ie-share-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--ie-gray-500, #6b7280);
}
.ie-share-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    border: 1px solid var(--ie-gray-300, #d1d5db);
    background: #fff;
    color: var(--ie-gray-600, #4b5563);
    cursor: pointer;
    transition: all .2s;
}
.ie-share-btn:hover { background: var(--ie-gray-50, #f9fafb); transform: translateY(-1px); }
.ie-share-btn--whatsapp:hover { color: #25d366; border-color: #25d366; }
.ie-share-btn--email:hover { color: #2563eb; border-color: #2563eb; }
.ie-share-btn--copy:hover { color: var(--ie-primary, #4a4a4a); border-color: var(--ie-primary, #4a4a4a); }

/* Contextual Hints */
.ie-contextual-hint {
    padding: 8px 14px;
    border-radius: var(--ie-radius, 10px);
    font-size: 13px;
    line-height: 1.5;
    margin: 8px 0;
}
.ie-contextual-hint--info { background: #eff6ff; border: 1px solid #bfdbfe; color: #1e40af; }
.ie-contextual-hint--success { background: #dcfce7; border: 1px solid #bbf7d0; color: #166534; }
.ie-contextual-hint--warn { background: #fef3c7; border: 1px solid #fde68a; color: #92400e; }

/* Lage-Bewertung */
.ie-lage-bewertung {
    margin: 12px 0 16px;
}
.ie-lage-bewertung__badge {
    padding: 8px 14px;
    border-radius: var(--ie-radius, 10px);
    font-size: 13px;
    line-height: 1.5;
    margin-bottom: 8px;
}
.ie-lage-bewertung__badge--good { background: #dcfce7; color: #166534; border: 1px solid #bbf7d0; }
.ie-lage-bewertung__badge--warn { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.ie-lage-bewertung__badge--bad { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.ie-lage-bewertung__table {
    display: flex;
    gap: 12px;
    font-size: 12px;
    color: var(--ie-gray-500, #6b7280);
    flex-wrap: wrap;
}
.ie-lage-bewertung__table span {
    background: var(--ie-gray-50, #f9fafb);
    padding: 4px 10px;
    border-radius: 6px;
    border: 1px solid var(--ie-gray-200, #e5e7eb);
}
.ie-lage-bewertung__table span:last-child {
    background: var(--ie-accent-light, rgba(200,151,92,.10));
    border-color: var(--ie-accent, #c8975c);
    color: var(--ie-gray-900, #111827);
}

/* Kaufnebenkosten Breakdown */
.ie-nk-breakdown {
    background: var(--ie-gray-50, #f9fafb);
    border: 1px solid var(--ie-gray-200, #e5e7eb);
    border-radius: var(--ie-radius, 10px);
    padding: 14px 16px;
}
.ie-nk-breakdown__grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 16px;
}
.ie-nk-breakdown__item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 0;
}
.ie-nk-breakdown__item--total {
    grid-column: 1 / -1;
    border-top: 2px solid var(--ie-accent, #c8975c);
    margin-top: 4px;
    padding-top: 8px;
}
.ie-nk-breakdown__label {
    font-size: 13px;
    color: var(--ie-gray-600, #4b5563);
    flex: 1;
}
.ie-nk-breakdown__item--total .ie-nk-breakdown__label {
    font-weight: 700;
    color: var(--ie-gray-900, #111827);
}
.ie-nk-breakdown__value {
    font-family: var(--ie-font-heading, 'Montserrat', sans-serif);
    font-size: 14px;
    font-weight: 700;
    color: var(--ie-gray-900, #111827);
}
.ie-nk-breakdown__item--total .ie-nk-breakdown__value {
    color: var(--ie-accent, #c8975c);
    font-size: 16px;
}
.ie-nk-breakdown__pct {
    font-size: 12px;
    color: var(--ie-gray-500, #6b7280);
    min-width: 40px;
}
@media (max-width: 480px) {
    .ie-nk-breakdown__grid {
        grid-template-columns: 1fr;
    }
}

/* Schnellrechner Tabs Scroll */
.ie-schnell__tabs {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}

/* KPI Grid */
.ie-kpi-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    margin-bottom: 20px;
}

.ie-kpi {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 12px;
    text-align: center;
}

.ie-kpi__label {
    display: block;
    font-size: 11px;
    color: var(--ie-gray-500);
    margin-bottom: 4px;
}

.ie-kpi__value {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: var(--ie-gray-900);
}

.ie-kpi__value--positive {
    color: var(--ie-success);
}

.ie-kpi__value--negative {
    color: var(--ie-danger);
}

/* KPI rating badges */
.ie-kpi__rating {
    display: inline-block;
    font-size: 9px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .3px;
    padding: 2px 6px;
    border-radius: 3px;
    margin-top: 4px;
}

.ie-kpi__rating--good {
    background: #dcfce7;
    color: #166534;
}

.ie-kpi__rating--ok {
    background: #fef3c7;
    color: #92400e;
}

.ie-kpi__rating--bad {
    background: #fef2f2;
    color: #991b1b;
}

/* Year slider */
.ie-year-slider {
    background: var(--ie-gray-50);
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 12px 16px;
    margin-bottom: 16px;
}

.ie-year-slider label {
    display: block;
    font-size: 13px;
    margin-bottom: 6px;
}

.ie-year-slider input[type="range"] {
    width: 100%;
    cursor: pointer;
}

/* Tabs */
.ie-tabs {
    display: flex;
    gap: 2px;
    margin-bottom: 0;
    border-bottom: 2px solid var(--ie-gray-200);
}

.ie-tab {
    padding: 8px 16px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 500;
    color: var(--ie-gray-500);
    transition: all .2s;
}

.ie-tab:hover {
    color: var(--ie-gray-700);
}

.ie-tab--active {
    color: var(--ie-primary);
    border-bottom-color: var(--ie-primary);
}

.ie-tab-content {
    display: none;
    padding: 16px 0;
}

.ie-tab-content--active {
    display: block;
}

/* Tables */
.ie-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.ie-table th, .ie-table td {
    padding: 6px 10px;
    text-align: right;
    border-bottom: 1px solid var(--ie-gray-100);
}

.ie-table th {
    font-weight: 600;
    font-size: 12px;
    color: var(--ie-gray-500);
    background: var(--ie-gray-50);
    text-transform: uppercase;
    letter-spacing: .3px;
}

.ie-table th:first-child,
.ie-table td:first-child {
    text-align: left;
}

.ie-table tr.ie-table__total td {
    font-weight: 700;
    border-top: 2px solid var(--ie-gray-300);
}

.ie-table-scroll {
    max-height: 500px;
    overflow-y: auto;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
}

.ie-table--compact th, .ie-table--compact td {
    padding: 4px 8px;
    font-size: 12px;
}

/* Charts */
.ie-chart-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

.ie-chart-wrap {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 16px;
}

.ie-chart-wrap h4 {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 10px;
}

.ie-chart-wrap canvas {
    max-height: 300px;
}

/* Sale scenario */
.ie-kpi-grid--sale {
    grid-template-columns: repeat(3, 1fr);
}

.ie-sale-note {
    font-size: 12px;
    color: var(--ie-gray-500);
    margin: 0 0 12px;
}

.ie-sale-status {
    margin-top: 12px;
    padding: 10px 14px;
    border-radius: var(--ie-radius);
    font-size: 13px;
    font-weight: 600;
    text-align: center;
}

.ie-sale-status--free {
    background: #dcfce7;
    color: #166534;
}

.ie-sale-status--taxed {
    background: #fef2f2;
    color: #991b1b;
}

.ie-sale-status--neutral {
    background: var(--ie-gray-50);
    color: var(--ie-gray-700);
}

/* Tooltips */
.ie-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-left: 4px;
    cursor: help;
    vertical-align: middle;
}

.ie-tooltip__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--ie-gray-500);
    color: #fff !important;
    font-size: 10px;
    font-weight: 700;
    font-style: normal;
    line-height: 1;
    flex-shrink: 0;
}

.ie-tooltip__text {
    display: none;
    position: absolute;
    bottom: calc(100% + 6px);
    left: 50%;
    transform: translateX(-50%);
    width: 280px;
    max-width: 280px;
    padding: 10px 12px;
    background: #fff;
    color: #374151 !important;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.5;
    border-radius: 6px;
    border: 1px solid #e5e7eb;
    z-index: 100;
    box-shadow: 0 4px 16px rgba(0,0,0,.12);
    pointer-events: none;
}

.ie-tooltip__text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #e5e7eb;
}

.ie-tooltip:hover .ie-tooltip__text,
.ie-tooltip--active .ie-tooltip__text {
    display: block;
}

/* Address autocomplete */
.ie-address-wrap {
    position: relative;
}

.ie-address-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: 0 0 6px 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,.12);
    z-index: 100;
    max-height: 200px;
    overflow-y: auto;
}

.ie-address-dropdown__item {
    padding: 8px 12px;
    font-size: 13px;
    cursor: pointer;
    border-bottom: 1px solid var(--ie-gray-100);
    line-height: 1.4;
    color: var(--ie-gray-700);
}

.ie-address-dropdown__item:hover {
    background: var(--ie-gray-50);
}

.ie-address-dropdown__item:last-child {
    border-bottom: none;
}

/* Warning box */
.ie-warning-box {
    background: #fef3cd;
    border: 1px solid #ffc107;
    border-radius: var(--ie-radius);
    padding: 10px 14px;
    margin-top: 10px;
    font-size: 13px;
    color: #856404;
    line-height: 1.5;
}

/* Summary section */
.ie-summary {
    margin-bottom: 16px;
}

.ie-summary__toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 10px 14px;
    background: var(--ie-gray-50, #f9fafb);
    border: 1px solid var(--ie-gray-200, #e5e7eb);
    border-radius: var(--ie-radius);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-gray-700);
    text-align: left;
}

.ie-summary__toggle:hover {
    background: var(--ie-gray-100, #f3f4f6);
}

.ie-summary__arrow {
    font-size: 10px;
}

.ie-summary__content {
    border: 1px solid var(--ie-gray-200);
    border-top: none;
    border-radius: 0 0 var(--ie-radius) var(--ie-radius);
    padding: 14px;
    background: #fff;
}

.ie-summary__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.ie-summary__section h5 {
    font-size: 12px;
    font-weight: 600;
    color: var(--ie-gray-500);
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: .3px;
}

.ie-summary__row {
    display: flex;
    justify-content: space-between;
    padding: 3px 0;
    font-size: 13px;
}

.ie-summary__row--total {
    font-weight: 700;
    border-top: 1px solid var(--ie-gray-200);
    margin-top: 4px;
    padding-top: 6px;
}

/* Journey */
.ie-journey-toggle {
    display: block;
    width: 100%;
    padding: 12px 16px;
    margin-bottom: 16px;
    background: var(--ie-accent-light);
    border: 1px solid var(--ie-accent);
    border-left: 3px solid var(--ie-accent);
    border-radius: var(--ie-radius);
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-primary);
    text-align: left;
    transition: background .2s;
}

.ie-journey-toggle:hover {
    background: rgba(200,151,92,.15);
}

.ie-journey__progress {
    height: 4px;
    background: var(--ie-gray-200);
    border-radius: 2px;
    margin-bottom: 20px;
    overflow: hidden;
}

.ie-journey__progress-bar {
    height: 100%;
    background: var(--ie-primary);
    border-radius: 2px;
    transition: width .3s ease;
}

.ie-journey__step {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 24px;
    box-shadow: var(--ie-shadow);
}

.ie-journey__step-title {
    font-family: var(--ie-font-heading);
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px;
    color: var(--ie-primary);
}

.ie-journey__step-desc {
    font-size: 14px;
    color: var(--ie-gray-700);
    margin: 0 0 20px;
    line-height: 1.6;
}

.ie-journey__fields {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
    margin-bottom: 16px;
}

.ie-journey__field {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.ie-journey__field label {
    font-size: 12px;
    font-weight: 500;
    color: var(--ie-gray-500);
}

.ie-journey__field input,
.ie-journey__field select {
    padding: 10px 12px;
    border: 1px solid var(--ie-gray-300);
    border-radius: 6px;
    font-size: 15px;
    background: #fff;
}

.ie-journey__field input:focus,
.ie-journey__field select:focus {
    outline: none;
    border-color: var(--ie-primary);
    box-shadow: 0 0 0 2px rgba(74,74,74,.12);
}

.ie-journey__tip {
    background: #faf6f1;
    border-left: 3px solid var(--ie-accent);
    padding: 10px 14px;
    margin-bottom: 20px;
    font-size: 13px;
    color: var(--ie-gray-700);
    border-radius: 0 6px 6px 0;
    line-height: 1.5;
}

.ie-journey__nav {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
}

.ie-journey__nav .ie-btn {
    min-width: 120px;
    text-align: center;
}

/* Journey Summary */
.ie-journey__summary h5 {
    font-size: 14px;
    font-weight: 700;
    margin: 0 0 12px;
    color: var(--ie-gray-900, #111827);
}
.ie-journey__summary-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    border-bottom: 1px solid var(--ie-gray-100, #f3f4f6);
    font-size: 13px;
}
.ie-journey__summary-row span {
    color: var(--ie-gray-500, #6b7280);
}
.ie-journey__summary-row strong {
    color: var(--ie-gray-900, #111827);
}

/* Checkliste Suggestion (after results) */
.ie-checkliste-cta {
    margin-top: 20px;
    padding: 14px 18px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: var(--ie-radius, 10px);
    display: flex;
    align-items: center;
    gap: 12px;
}
.ie-checkliste-cta__icon { font-size: 24px; }
.ie-checkliste-cta__text {
    flex: 1;
    font-size: 13px;
    color: #166534;
    line-height: 1.4;
}
.ie-checkliste-cta__text strong { display: block; font-size: 14px; margin-bottom: 2px; }
.ie-checkliste-cta__link {
    display: inline-block;
    padding: 6px 16px;
    background: #166534;
    color: #fff !important;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}
.ie-checkliste-cta__link:hover { background: #14532d; color: #fff !important; text-decoration: none; }

/* Dashboard */
.ie-dashboard__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.ie-dashboard__title {
    font-family: var(--ie-font-heading);
    font-size: 20px;
    font-weight: 700;
    margin: 0;
}

.ie-dashboard__actions {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 16px;
}

.ie-dashboard__selected-count {
    font-size: 12px;
    color: var(--ie-gray-500);
}

.ie-dashboard__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 16px;
}

.ie-dashboard__card {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 16px;
    box-shadow: var(--ie-shadow);
    transition: box-shadow .2s;
}

.ie-dashboard__card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,.12);
}

.ie-dashboard__card-header {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    margin-bottom: 10px;
}

.ie-dashboard__card-header strong {
    font-size: 14px;
}

.ie-dashboard__card-header small {
    font-size: 12px;
    color: var(--ie-gray-500);
}

.ie-dashboard__checkbox {
    margin-top: 3px;
    cursor: pointer;
}

.ie-dashboard__kpis {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px;
    margin-bottom: 10px;
    font-size: 12px;
    color: var(--ie-gray-700);
}

.ie-dashboard__card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top: 1px solid var(--ie-gray-100);
    padding-top: 8px;
}

.ie-dashboard__card-footer small {
    font-size: 11px;
    color: var(--ie-gray-500);
}

.ie-dashboard__empty {
    font-size: 14px;
    color: var(--ie-gray-500);
    text-align: center;
    padding: 40px 0;
}

/* Comparison */
.ie-comparison {
    margin-top: 20px;
}

.ie-comparison__title {
    font-family: var(--ie-font-heading);
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 12px;
}

.ie-comparison__table-wrap {
    overflow-x: auto;
    margin-top: 12px;
}

.ie-comparison__table th,
.ie-comparison__table td {
    min-width: 120px;
}

/* Inline mini charts */
.ie-inline-chart {
    background: #fff;
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 10px 12px;
    margin-bottom: 12px;
}

.ie-inline-chart canvas {
    max-height: 120px;
}

/* First year box */
.ie-first-year-box {
    background: #fef2f2;
    border-color: #fca5a5;
}

/* Tax effect box */
.ie-tax-effect-box {
    background: var(--ie-gray-50);
    border-color: var(--ie-gray-200);
}

/* Yearly overview KPIs */
.ie-yearly-kpis {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}

/* Yearly overview table */
.ie-table-scroll--yearly {
    max-height: 600px;
    overflow-x: auto;
}

.ie-table--yearly th,
.ie-table--yearly td {
    white-space: nowrap;
    min-width: 80px;
}

/* Sticky first column for wide tables */
.ie-table--yearly th:first-child,
.ie-table--yearly td:first-child {
    position: sticky;
    left: 0;
    z-index: 2;
    background: #fff;
}

.ie-table--yearly thead th:first-child {
    background: var(--ie-gray-50);
    z-index: 3;
}

.ie-yearly-breakeven td:first-child {
    background: #dcfce7 !important;
}

/* Mobile tab scroll indicator */
.ie-tabs {
    position: relative;
}

.ie-tabs::after {
    content: '';
    position: absolute;
    right: 0;
    top: 0;
    bottom: 2px;
    width: 24px;
    background: linear-gradient(to right, transparent, rgba(255,255,255,.9));
    pointer-events: none;
    opacity: 0;
    transition: opacity .2s;
}

.ie-tabs--scrollable::after {
    opacity: 1;
}

/* Break-Even row highlight */
.ie-yearly-breakeven {
    background: #dcfce7 !important;
}

.ie-yearly-breakeven td {
    font-weight: 700;
    color: #166534;
}

/* Value coloring in tables */
.ie-val--pos { color: var(--ie-success); }
.ie-val--neg { color: var(--ie-danger); }

/* Responsive */
@media (max-width: 768px) {
    .ie-rechner {
        padding: 0 12px;
        padding-bottom: 70px; /* Space for sticky footer */
    }

    .ie-rechner__title {
        font-size: 18px;
    }

    .ie-form-row {
        flex-direction: column;
    }

    .ie-form-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .ie-summary__grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .ie-kpi-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }

    .ie-kpi {
        padding: 10px 8px;
    }

    .ie-kpi__value {
        font-size: 16px;
    }

    .ie-kpi__label {
        font-size: 10px;
    }

    .ie-step-btn__label {
        display: none;
    }

    .ie-step-btn {
        padding: 8px 10px;
    }

    .ie-tabs {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        flex-wrap: nowrap;
    }

    .ie-tabs::-webkit-scrollbar {
        display: none;
    }

    .ie-tab {
        white-space: nowrap;
        flex-shrink: 0;
        padding: 8px 12px;
        font-size: 12px;
    }

    .ie-kpi-grid--sale {
        grid-template-columns: repeat(2, 1fr);
    }

    .ie-investments-row {
        grid-template-columns: 1fr;
        gap: 4px;
        padding-bottom: 10px;
        border-bottom: 1px solid var(--ie-gray-200);
        margin-bottom: 6px;
    }

    .ie-investments-row--header {
        display: none;
    }

    .ie-investments-row input,
    .ie-investments-row select {
        font-size: 13px;
        min-height: 44px;
    }

    .ie-table-scroll {
        max-height: 400px;
    }

    .ie-yearly-kpis {
        grid-template-columns: 1fr;
        gap: 8px;
    }

    .ie-table-scroll--yearly {
        max-height: 400px;
        -webkit-overflow-scrolling: touch;
    }

    .ie-table--compact th,
    .ie-table--compact td {
        padding: 3px 5px;
        font-size: 11px;
    }

    .ie-chart-wrap {
        padding: 12px 8px;
    }

    .ie-chart-wrap canvas {
        max-height: 220px;
    }

    .ie-btn {
        padding: 10px 16px;
        font-size: 13px;
    }

    .ie-anleitung__toggle {
        font-size: 12px;
        padding: 8px 10px;
    }

    .ie-anleitung__content {
        font-size: 12px;
        padding: 10px 12px;
    }

    .ie-form-section {
        padding: 14px;
    }

    .ie-year-slider {
        padding: 10px 12px;
    }

    .ie-results-actions {
        gap: 6px;
    }

    .ie-results-actions .ie-btn--outline {
        font-size: 12px;
        padding: 7px 12px;
    }

    /* Touch-friendly inputs */
    .ie-field input,
    .ie-field select {
        min-height: 44px;
        font-size: 16px; /* Prevents iOS zoom */
    }

    /* Sticky bottom navigation */
    .ie-rechner__footer {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        background: #fff;
        border: none;
        border-top: 1px solid var(--ie-gray-200);
        border-radius: 0;
        padding: 8px 12px 10px;
        margin-top: 0;
        z-index: 50;
        box-shadow: 0 -2px 8px rgba(0,0,0,.1);
    }

    .ie-progress {
        margin-bottom: 8px;
    }

    .ie-progress__dot {
        width: 24px;
        height: 24px;
        font-size: 11px;
    }

    .ie-progress__steplabel {
        font-size: 9px;
    }

    .ie-progress__connector {
        margin-bottom: 14px;
    }

    .ie-footer__buttons {
        gap: 8px;
    }

    .ie-footer__buttons .ie-btn {
        flex: 1;
        text-align: center;
    }

    .ie-footer__buttons .ie-btn--primary {
        padding: 14px 16px;
        font-size: 15px;
    }

    .ie-journey__nav {
        flex-direction: column-reverse;
    }

    .ie-journey__nav .ie-btn {
        width: 100%;
        text-align: center;
    }

    .ie-journey__nav .ie-btn--primary {
        margin-bottom: 8px;
    }

    .ie-field {
        gap: 4px;
    }

    .ie-header-actions {
        flex-direction: column;
    }

    .ie-header-actions__right {
        align-self: flex-end;
    }

    .ie-progress__text {
        font-size: 11px;
        margin-bottom: 4px;
    }
}

@media (max-width: 480px) {
    .ie-rechner {
        padding: 0 8px;
        padding-bottom: 70px;
        font-size: 13px;
    }

    .ie-rechner__title {
        font-size: 16px;
    }

    .ie-kpi-grid {
        grid-template-columns: 1fr;
    }

    .ie-kpi__value {
        font-size: 14px;
    }

    .ie-step__title {
        font-size: 15px;
    }

    .ie-table th,
    .ie-table td {
        padding: 5px 6px;
        font-size: 12px;
    }

    .ie-info-row {
        font-size: 12px;
    }
}

/* Progress text */
.ie-progress__text {
    font-size: 12px;
    font-weight: 600;
    color: var(--ie-gray-500);
    text-align: center;
    margin-bottom: 8px;
}

/* Header actions (journey toggle + reset + demo) */
.ie-header-actions {
    display: flex;
    gap: 8px;
    align-items: stretch;
    margin-bottom: 16px;
}

.ie-header-actions .ie-journey-toggle {
    flex: 1;
    margin-bottom: 0;
}

.ie-header-actions__right {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.ie-btn--demo {
    white-space: nowrap;
    font-size: 12px !important;
    padding: 8px 12px !important;
    color: var(--ie-primary) !important;
    border-color: var(--ie-primary) !important;
    background: var(--ie-primary-light) !important;
}

.ie-btn--demo:hover {
    background: rgba(74,74,74,.12) !important;
}

.ie-btn--reset {
    white-space: nowrap;
    font-size: 12px !important;
    padding: 8px 12px !important;
    color: var(--ie-gray-500) !important;
    border-color: var(--ie-gray-300) !important;
}

.ie-btn--reset:hover {
    color: var(--ie-danger) !important;
    border-color: var(--ie-danger) !important;
}

/* Disclaimer */
.ie-disclaimer {
    margin-top: 20px;
    padding: 12px 16px;
    background: var(--ie-gray-50);
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    font-size: 11px;
    color: var(--ie-gray-500);
    line-height: 1.5;
}

.ie-disclaimer p {
    margin: 0;
}

.ie-disclaimer__meta {
    margin-top: 6px !important;
    font-size: 10px;
    opacity: .7;
}

/* Yearly actions */
.ie-yearly-actions {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 10px;
}

.ie-btn--small {
    font-size: 12px !important;
}

/* Loading state */
.ie-rechner__loader {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 40px 20px;
    font-size: 14px;
    color: var(--ie-gray-500);
}

.ie-rechner__spinner {
    width: 24px;
    height: 24px;
    border: 3px solid var(--ie-gray-200);
    border-top-color: var(--ie-primary);
    border-radius: 50%;
    animation: ie-spin .8s linear infinite;
}

@keyframes ie-spin {
    to { transform: rotate(360deg); }
}

.ie-rechner--loading .ie-rechner__header,
.ie-rechner--loading .ie-rechner__body,
.ie-rechner--loading .ie-rechner__footer,
.ie-rechner--loading #ie-dashboard,
.ie-rechner--loading .ie-mode-select,
.ie-rechner--loading .ie-schnell,
.ie-rechner--loading .ie-rechner__main {
    display: none !important;
}

/* Year slider calendar year */
.ie-year-slider__calendar {
    font-weight: 400;
    font-size: 12px;
    color: var(--ie-gray-500);
}

/* ═══ MODE SELECTION DASHBOARD ═══ */
.ie-mode-select {
    text-align: center;
    padding: 20px 0 40px;
}

.ie-mode-select__title {
    font-family: var(--ie-font-heading);
    font-size: 26px;
    font-weight: 700;
    margin: 0 0 6px;
    color: var(--ie-gray-900);
}

.ie-mode-select__subtitle {
    font-size: 15px;
    color: var(--ie-gray-500);
    margin: 0 0 28px;
}

.ie-mode-select__grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

.ie-mode-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 28px 20px 24px;
    background: #fff;
    border: 2px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    cursor: pointer;
    transition: all .25s ease;
    text-align: center;
    box-shadow: var(--ie-shadow);
}

.ie-mode-card:hover {
    border-color: var(--ie-accent);
    box-shadow: 0 4px 20px rgba(200,151,92,.15);
    transform: translateY(-2px);
}

.ie-mode-card__icon {
    font-size: 40px;
    line-height: 1;
}

.ie-mode-card__title {
    font-family: var(--ie-font-heading);
    font-size: 18px;
    font-weight: 700;
    color: var(--ie-gray-900);
}

.ie-mode-card__desc {
    font-size: 13px;
    color: var(--ie-gray-500);
    line-height: 1.5;
}

.ie-mode-card__badge {
    display: inline-block;
    padding: 4px 12px;
    background: #faf6f1;
    color: var(--ie-accent);
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .3px;
    margin-top: 4px;
}

/* Back button */
.ie-mode-back {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    padding: 6px 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-gray-500);
    cursor: pointer;
    transition: color .2s;
}

.ie-mode-back:hover {
    color: var(--ie-primary);
}

.ie-rechner__header-top {
    margin-bottom: 12px;
}

/* ═══ SCHNELLRECHNER ═══ */
.ie-schnell__header {
    margin-bottom: 16px;
}

.ie-schnell__back {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    padding: 6px 0;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-gray-500);
    cursor: pointer;
    margin-bottom: 8px;
}

.ie-schnell__back:hover {
    color: var(--ie-primary);
}

.ie-schnell__title {
    font-family: var(--ie-font-heading);
    font-size: 22px;
    font-weight: 700;
    margin: 0;
}

.ie-schnell__tabs {
    display: flex;
    gap: 2px;
    border-bottom: 2px solid var(--ie-gray-200);
    margin-bottom: 20px;
    overflow-x: auto;
}

.ie-schnell__tab {
    padding: 8px 16px;
    background: none;
    border: none;
    border-bottom: 2px solid transparent;
    margin-bottom: -2px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-gray-500);
    white-space: nowrap;
    transition: all .2s;
}

.ie-schnell__tab:hover {
    color: var(--ie-gray-700);
}

.ie-schnell__tab--active {
    color: var(--ie-primary);
    border-bottom-color: var(--ie-primary);
}

.ie-schnell__body {
    min-height: 200px;
}

.ie-schnell__cta {
    margin-top: 28px;
    padding: 20px;
    background: var(--ie-primary-light);
    border: 1px solid rgba(74,74,74,.15);
    border-radius: var(--ie-radius);
    text-align: center;
}

.ie-schnell__cta p {
    margin: 0 0 12px;
    font-size: 14px;
    color: var(--ie-gray-700);
}

/* Schnellrechner form fields */
.ie-schnell__form {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
}

.ie-schnell__field {
    flex: 1 1 240px;
}

.ie-schnell__field label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--ie-gray-500);
    margin-bottom: 4px;
}

.ie-schnell__field input,
.ie-schnell__field select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--ie-gray-300);
    border-radius: 6px;
    font-size: 15px;
    font-weight: 600;
    color: var(--ie-gray-900);
    background: #fff;
    box-sizing: border-box;
}

.ie-schnell__field input:focus,
.ie-schnell__field select:focus {
    outline: none;
    border-color: var(--ie-primary);
    box-shadow: 0 0 0 3px rgba(74,74,74,.08);
}

.ie-schnell__field--checkbox {
    display: flex;
    align-items: center;
    padding-top: 22px;
    flex: 0 0 auto;
}

.ie-schnell__field--checkbox label {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    margin-bottom: 0;
}

.ie-schnell__field--checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--ie-primary);
}

/* Schnell results */
.ie-schnell__results {
    animation: ieSchnellSlide .3s ease;
}

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

.ie-schnell__kpi-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

.ie-schnell__kpi-grid--3 {
    grid-template-columns: 1fr 1fr 1fr;
}

.ie-schnell__kpi {
    background: var(--ie-gray-50);
    border: 1px solid var(--ie-gray-200);
    border-radius: var(--ie-radius);
    padding: 14px 16px;
    text-align: center;
}

.ie-schnell__kpi--highlight {
    background: var(--ie-accent-light);
    border-color: var(--ie-accent);
}

.ie-schnell__kpi--total {
    grid-column: 1 / -1;
}

.ie-schnell__kpi-label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    color: var(--ie-gray-500);
    text-transform: uppercase;
    letter-spacing: .3px;
    margin-bottom: 4px;
}

.ie-schnell__kpi-value {
    display: block;
    font-family: var(--ie-font-heading);
    font-size: 22px;
    font-weight: 700;
    color: var(--ie-gray-900);
}

.ie-schnell__kpi--highlight .ie-schnell__kpi-value {
    color: var(--ie-accent);
}

.ie-schnell__kpi-sub {
    display: block;
    font-size: 12px;
    color: var(--ie-gray-500);
    margin-top: 2px;
}

/* Rating badge */
.ie-schnell__rating {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 12px;
}

.ie-schnell__rating--good { background: #dcfce7; color: #166534; }
.ie-schnell__rating--warn { background: #fef3c7; color: #92400e; }
.ie-schnell__rating--bad { background: #fee2e2; color: #991b1b; }

/* Scale bar */
.ie-schnell__scale { position: relative; margin: 16px 0; }
.ie-schnell__scale-bar { display: flex; border-radius: var(--ie-radius); overflow: hidden; font-size: 11px; font-weight: 600; text-align: center; }
.ie-schnell__scale-zone { flex: 1; padding: 8px 4px; color: #fff; }
.ie-schnell__scale-zone--good { background: #16a34a; }
.ie-schnell__scale-zone--ok { background: #65a30d; }
.ie-schnell__scale-zone--warn { background: #d97706; }
.ie-schnell__scale-zone--bad { background: #dc2626; }
.ie-schnell__scale-marker {
    position: absolute; bottom: -8px; transform: translateX(-50%);
    background: var(--ie-gray-900); color: #fff; padding: 2px 8px;
    border-radius: 10px; font-size: 12px; font-weight: 700; white-space: nowrap;
}
.ie-schnell__scale-marker::before {
    content: ''; position: absolute; top: -5px; left: 50%; transform: translateX(-50%);
    border-left: 5px solid transparent; border-right: 5px solid transparent;
    border-bottom: 5px solid var(--ie-gray-900);
}

/* Schnell table */
.ie-schnell__table-wrap {
    margin-top: 16px; max-height: 300px; overflow-y: auto;
    border: 1px solid var(--ie-gray-200); border-radius: var(--ie-radius);
}
.ie-schnell__table { width: 100%; border-collapse: collapse; font-size: 13px; }
.ie-schnell__table th {
    position: sticky; top: 0; background: var(--ie-gray-100);
    padding: 8px 12px; text-align: left; font-weight: 600; font-size: 12px;
    text-transform: uppercase; color: var(--ie-gray-500);
    border-bottom: 1px solid var(--ie-gray-200);
}
.ie-schnell__table td { padding: 8px 12px; border-bottom: 1px solid var(--ie-gray-100); }
.ie-schnell__table tr:last-child td { border-bottom: none; }
.ie-schnell__table-active { background: var(--ie-primary-light); font-weight: 600; }
.ie-schnell__table-active td:first-child { border-left: 3px solid var(--ie-primary); }

/* Schnell bar chart */
.ie-schnell__bar-chart { margin-top: 16px; }
.ie-schnell__bar { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.ie-schnell__bar-label { flex: 0 0 80px; font-size: 12px; font-weight: 600; color: var(--ie-gray-500); text-align: right; }
.ie-schnell__bar-fill { display: block; height: 28px; line-height: 28px; border-radius: 6px; font-size: 12px; font-weight: 700; color: #fff; padding: 0 8px; min-width: 2px; transition: width .4s ease; white-space: nowrap; overflow: hidden; }
.ie-schnell__bar--grest .ie-schnell__bar-fill { background: var(--ie-primary); }
.ie-schnell__bar--makler .ie-schnell__bar-fill { background: #d97706; }
.ie-schnell__bar--notar .ie-schnell__bar-fill { background: #2563eb; }
.ie-schnell__bar--grundbuch .ie-schnell__bar-fill { background: #7c3aed; }

/* Info box */
.ie-schnell__info {
    background: #eff6ff; border: 1px solid #bfdbfe; border-radius: var(--ie-radius);
    padding: 10px 14px; font-size: 13px; color: #1e40af; margin-top: 12px;
}

/* Restore banner (G1.4) */
.ie-restore-banner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    margin-bottom: 16px;
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    border-radius: var(--ie-radius, 8px);
    font-size: 13px;
}
.ie-restore-banner__text { flex: 1; color: #1e40af; font-weight: 500; }
.ie-restore-banner .ie-btn--sm { padding: 6px 14px; font-size: 12px; }
@media (max-width: 600px) {
    .ie-restore-banner { flex-wrap: wrap; }
    .ie-restore-banner__text { width: 100%; }
}

/* Knowledge expandable sections (E1) */
.ie-knowledge { margin-top: 4px; }
.ie-knowledge__toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    width: 100%;
    padding: 6px 10px;
    background: transparent;
    border: 1px dashed var(--ie-gray-200, #e5e7eb);
    border-radius: var(--ie-radius, 8px);
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    color: var(--ie-accent, #c8975c);
    text-align: left;
    transition: background .2s, border-color .2s;
}
.ie-knowledge__toggle:hover {
    background: var(--ie-gray-50, #f9fafb);
    border-color: var(--ie-accent, #c8975c);
}
.ie-knowledge__icon { font-size: 14px; }
.ie-knowledge__arrow {
    margin-left: auto;
    font-size: 10px;
    transition: transform .2s;
}
.ie-knowledge--open .ie-knowledge__arrow { transform: rotate(180deg); }
.ie-knowledge__content {
    padding: 12px 14px;
    margin-top: 4px;
    background: #fef7f0;
    border: 1px solid #fde2c8;
    border-radius: var(--ie-radius, 8px);
    font-size: 13px;
    line-height: 1.6;
    color: var(--ie-gray-700, #374151);
}
.ie-knowledge__content ul {
    margin: 8px 0;
    padding-left: 20px;
}
.ie-knowledge__content li { margin-bottom: 4px; }
.ie-knowledge__content strong { color: var(--ie-gray-900, #111827); }

/* Wide schnell forms (Mieten-Kaufen, EK-Optimierer, Grundsteuer-neu, Erbpacht) */
.ie-schnell__form--wide {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}
@media (max-width: 600px) {
    .ie-schnell__form--wide { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 400px) {
    .ie-schnell__form--wide { grid-template-columns: 1fr; }
}

/* EK table in Schnellrechner */
.ie-schnell__table--ek { min-width: 580px; }
.ie-schnell__table--ek th,
.ie-schnell__table--ek td { text-align: center; padding: 8px 10px; }
.ie-schnell__table--ek td:first-child { text-align: left; }

/* Positive/negative value colors */
.ie-schnell__val--pos { color: #16a34a !important; }
.ie-schnell__val--neg { color: #dc2626 !important; }

/* Eigennutz badge */
.ie-eigennutz-badge {
    display: inline-block;
    padding: 4px 12px;
    background: #dbeafe;
    color: #1e40af;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    margin-left: 8px;
}

/* Responsive mode select */
@media (max-width: 768px) {
    .ie-mode-select__grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .ie-mode-card {
        padding: 20px 16px;
    }
    .ie-mode-select__title { font-size: 20px; }
    .ie-schnell__tabs { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .ie-schnell__kpi-grid--3 { grid-template-columns: 1fr; }
    .ie-schnell__bar-label { flex: 0 0 60px; font-size: 11px; }
}

@media (max-width: 480px) {
    .ie-mode-card__icon { font-size: 30px; }
    .ie-mode-card__title { font-size: 16px; }
    .ie-schnell__kpi-value { font-size: 18px; }
}

/* Print styles */
@media print {
    .ie-rechner {
        max-width: 100%;
        padding: 0;
    }

    .ie-rechner__footer,
    .ie-journey-toggle,
    .ie-header-actions,
    .ie-anleitung,
    .ie-results-actions,
    .ie-yearly-actions,
    .ie-year-slider,
    #ie-view-toggle,
    #ie-dashboard,
    #ie-journey,
    .ie-btn--reset,
    .ie-btn--demo,
    .ie-mode-select,
    .ie-schnell,
    .ie-mode-back {
        display: none !important;
    }

    .ie-rechner__main {
        display: block !important;
    }

    .ie-form-section,
    .ie-kpi,
    .ie-chart-wrap {
        box-shadow: none;
        break-inside: avoid;
    }

    .ie-step {
        display: block !important;
    }

    .ie-tab-content {
        display: block !important;
        padding: 12px 0;
        break-before: auto;
    }

    .ie-tabs {
        display: none;
    }

    .ie-kpi-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .ie-disclaimer {
        border: none;
        font-size: 10px;
    }

    .ie-kpi__rating {
        border: 1px solid #ccc;
    }

    .ie-stepper {
        display: none;
    }

    .ie-en-overlay {
        position: static !important;
        background: none !important;
    }

    .ie-en-tabs {
        display: none;
    }

    .ie-en-tab-pane {
        display: block !important;
        break-inside: avoid;
        margin-bottom: 12px;
    }

    .ie-mfh-summary {
        break-inside: avoid;
    }

    .ie-share-buttons,
    .ie-summary__toggle {
        display: none !important;
    }

    .ie-tooltip {
        display: none !important;
    }

    body { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* MFH Toggle */
.ie-mfh-toggle {
    margin-bottom: 16px;
}
.ie-mfh-toggle__buttons {
    display: inline-flex;
    background: var(--ie-gray-100, #f3f4f6);
    border-radius: 10px;
    padding: 3px;
    gap: 2px;
}
.ie-mfh-toggle__btn {
    padding: 8px 20px;
    border: none;
    border-radius: 8px;
    background: transparent;
    font-size: 13px;
    font-weight: 600;
    color: var(--ie-gray-600, #4b5563);
    cursor: pointer;
    transition: all .2s;
}
.ie-mfh-toggle__btn--active {
    background: #fff;
    color: var(--ie-primary, #4a4a4a);
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.ie-mfh-toggle__btn:hover:not(.ie-mfh-toggle__btn--active) {
    color: var(--ie-gray-800, #1f2937);
}

/* Mieterliste */
.ie-mieterliste {
    background: var(--ie-gray-50, #f9fafb);
    border: 1px solid var(--ie-gray-200, #e5e7eb);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}
.ie-mieterliste__header {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.2fr 1fr 70px 70px 36px;
    gap: 6px;
    padding: 0 0 8px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--ie-gray-500, #6b7280);
    border-bottom: 2px solid var(--ie-gray-200, #e5e7eb);
}
.ie-mieterliste__row {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1.2fr 1fr 70px 70px 36px;
    gap: 6px;
    padding: 6px 0;
    align-items: center;
    border-bottom: 1px solid var(--ie-gray-100, #f3f4f6);
}
.ie-mieterliste__row input[type="text"] {
    padding: 6px 8px;
    border: 1px solid var(--ie-gray-300, #d1d5db);
    border-radius: 6px;
    font-size: 13px;
    width: 100%;
    box-sizing: border-box;
}
.ie-ml-check {
    display: flex;
    justify-content: center;
    cursor: pointer;
}
.ie-ml-check input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}
.ie-ml-remove {
    border: none;
    background: none;
    color: var(--ie-gray-400, #9ca3af);
    font-size: 20px;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}
.ie-ml-remove:hover {
    color: #dc2626;
}
.ie-mieterliste__footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 12px;
    flex-wrap: wrap;
    gap: 8px;
}
.ie-mieterliste__summary {
    font-size: 13px;
    color: var(--ie-gray-600, #4b5563);
    display: flex;
    flex-direction: column;
    gap: 2px;
}

/* MFH Results Summary (Step 4) */
.ie-mfh-summary {
    background: linear-gradient(135deg, #eff6ff 0%, #f0f9ff 100%);
    border: 1px solid #bfdbfe;
    border-radius: 10px;
    padding: 16px 20px;
    margin: 12px 0;
}
.ie-mfh-summary__title {
    font-size: 14px;
    font-weight: 700;
    color: #1e40af;
    margin: 0 0 12px;
}
.ie-mfh-kpis {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
.ie-mfh-kpi {
    background: #fff;
    border-radius: 8px;
    padding: 10px 12px;
    text-align: center;
    border: 1px solid #e5e7eb;
}
.ie-mfh-kpi--warn {
    border-color: #fbbf24;
    background: #fffbeb;
}
.ie-mfh-kpi--info {
    border-color: #93c5fd;
    background: #eff6ff;
}
.ie-mfh-kpi__label {
    display: block;
    font-size: 10px;
    text-transform: uppercase;
    color: #6b7280;
    font-weight: 600;
    letter-spacing: 0.3px;
}
.ie-mfh-kpi__value {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #1e3a5f;
    margin-top: 2px;
}
.ie-mfh-hint {
    margin-top: 10px;
    font-size: 12px;
    color: #4b5563;
    padding: 8px 12px;
    background: #f3f4f6;
    border-radius: 6px;
    line-height: 1.4;
}
.ie-mfh-hint--warn {
    background: #fef3c7;
    color: #92400e;
    border: 1px solid #fbbf24;
}
@media (max-width: 768px) {
    .ie-mfh-kpis {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Eigennutz Chart */
.ie-eigennutz-chart {
    max-height: 300px;
}

@media (max-width: 768px) {
    .ie-mieterliste__header {
        display: none;
    }
    .ie-mieterliste__row {
        grid-template-columns: 1fr 1fr;
        gap: 4px;
        padding: 10px 0;
    }
    .ie-mieterliste__row input[type="text"] {
        font-size: 14px;
    }
    .ie-ml-check {
        justify-content: flex-start;
    }
}

/* Accessibility - Focus Visible */
.ie-btn:focus-visible,
.ie-step-btn:focus-visible,
.ie-mode-card:focus-visible,
.ie-schnell__tab:focus-visible,
.ie-share-btn:focus-visible {
    outline: 2px solid var(--ie-primary, #4a4a4a);
    outline-offset: 2px;
}

.ie-tab:focus-visible,
.ie-en-tab:focus-visible {
    outline: 2px solid #1e40af;
    outline-offset: 2px;
}

.ie-kpi:focus-visible {
    outline: 2px solid var(--ie-primary, #4a4a4a);
    outline-offset: 2px;
}

/* Skip to results link (screen readers) */
.ie-skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--ie-primary, #4a4a4a);
    color: #fff;
    padding: 8px 16px;
    z-index: 100;
    font-size: 14px;
    border-radius: 0 0 4px 0;
}
.ie-skip-link:focus {
    top: 0;
}
