/* Retirement Calculator Styles */
/* Extends and reuses patterns from SIP calculator */

.calculator-section {
    background: linear-gradient(180deg, #1E1F2E 0%, #252736 100%);
    min-height: 100vh;
    padding: 100px 0 60px;
}

.calculator-header {
    text-align: center;
    margin-bottom: 50px;
}

.calculator-header h1 {
    font-size: 42px;
    font-weight: 700;
    background: linear-gradient(135deg, #FFD500 0%, #FF8C00 50%, #9a20bc 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: 15px;
}

.calculator-header .subtitle {
    font-size: 18px;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 400;
    margin-bottom: 20px;
}

/* Mode Toggle */
.mode-toggle {
    margin-top: 15px;
}

.mode-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 25px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mode-btn:hover {
    background: rgba(255, 213, 0, 0.1);
    border-color: #FFD500;
    color: #FFD500;
}

.mode-btn.active {
    background: rgba(255, 213, 0, 0.15);
    border-color: #FFD500;
    color: #FFD500;
}

.mode-btn i {
    font-size: 18px;
}

/* Mode Toggle (Bottom of Results) */
.mode-toggle-bottom {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.mode-btn-subtle {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: transparent;
    border: 1px dashed rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    color: rgba(255, 255, 255, 0.5);
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.mode-btn-subtle:hover {
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 213, 0, 0.3);
    color: rgba(255, 255, 255, 0.8);
}

.mode-btn-subtle i {
    font-size: 16px;
    color: rgba(255, 213, 0, 0.6);
}

/* Emergency Fund Tip */
.emergency-fund-tip {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    background: linear-gradient(135deg, rgba(255, 152, 0, 0.08) 0%, rgba(255, 152, 0, 0.03) 100%);
    border: 1px solid rgba(255, 152, 0, 0.2);
    border-radius: 12px;
    padding: 16px 20px;
    margin-top: 25px;
}

.emergency-fund-tip>i {
    font-size: 24px;
    color: #FF9800;
    margin-top: 2px;
}

.tip-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tip-title {
    font-size: 14px;
    font-weight: 600;
    color: #FF9800;
}

.tip-text {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.5;
}

.tip-text strong {
    color: #FFB74D;
    font-weight: 600;
}

.tip-link {
    color: #64B5F6;
    font-weight: 600;
    text-decoration: none;
    margin-left: 8px;
}

.tip-link:hover {
    text-decoration: underline;
}

/* Wizard Progress Bar */
.wizard-progress {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    max-width: 800px;
    margin: 0 auto 40px;
    padding: 0 20px;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    position: relative;
    z-index: 2;
}

.step-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: 2px solid rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.step-circle i {
    font-size: 18px;
}

.progress-step.active .step-circle,
.progress-step.completed .step-circle {
    background: linear-gradient(135deg, #FFD500 0%, #FF8C00 100%);
    border-color: #FFD500;
    color: #1E1F2E;
}

.progress-step.completed .step-circle {
    background: #4CAF50;
    border-color: #4CAF50;
}

.step-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.progress-step.active .step-label,
.progress-step.completed .step-label {
    color: rgba(255, 255, 255, 0.8);
}

.progress-line {
    flex: 1;
    height: 2px;
    background: rgba(255, 255, 255, 0.1);
    min-width: 30px;
    max-width: 80px;
    margin: 0 5px;
    margin-bottom: 20px;
    transition: background 0.3s ease;
}

.progress-step.completed+.progress-line {
    background: #4CAF50;
}

/* Wizard Container */
.wizard-container {
    max-width: 700px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

.wizard-step {
    display: none;
}

.wizard-step.active {
    display: block;
    animation: slideInRight 0.35s ease;
}

.wizard-step.slide-out-left {
    animation: slideOutLeft 0.35s ease forwards;
}

.wizard-step.slide-in-left {
    animation: slideInLeft 0.35s ease;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes slideOutLeft {
    from {
        opacity: 1;
        transform: translateX(0);
    }

    to {
        opacity: 0;
        transform: translateX(-50px);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.step-content {
    background: linear-gradient(145deg, #2F3142 0%, #252736 100%);
    border-radius: 24px;
    padding: 30px 35px 20px;
}

.step-header {
    text-align: center;
    margin-bottom: 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.step-icon {
    font-size: 40px;
    color: #FFD500;
    margin-bottom: 0;
}

.step-header h2 {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}

.step-description {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
}

.step-fields {
    max-width: 500px;
    margin: 0 auto;
}

.step-insight {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(76, 175, 80, 0.1);
    border: 1px solid rgba(76, 175, 80, 0.2);
    border-radius: 12px;
    padding: 16px;
    margin-top: 20px;
}

.step-insight i {
    color: #4CAF50;
    font-size: 22px;
}

.step-insight span {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
}

.step-insight strong {
    color: #4CAF50;
}

.input-hint {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 8px;
    font-style: italic;
}

.skip-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 8px;
    padding: 12px 16px;
    margin-top: 20px;
}

.skip-hint i {
    color: rgba(255, 255, 255, 0.4);
    font-size: 18px;
}

.skip-hint span {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
}

/* Results Step */
.results-step .step-content {
    background: transparent;
    padding: 0;
}

.results-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

/* Wizard Navigation */
.wizard-nav {
    display: flex;
    justify-content: space-between;
    max-width: 700px;
    margin: 30px auto 0;
    padding: 0 20px;
}

.nav-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.nav-btn.prev {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.7);
}

.nav-btn.prev:hover:not(:disabled) {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.nav-btn.prev:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.nav-btn.next {
    background: linear-gradient(135deg, #FFD500 0%, #FF8C00 100%);
    border: none;
    color: #1E1F2E;
}

.nav-btn.next:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 213, 0, 0.25);
}

.nav-btn.next.finish {
    background: linear-gradient(135deg, #4CAF50 0%, #2E7D32 100%);
    color: #fff;
}

.nav-btn i {
    font-size: 20px;
}

/* Inputs Column Wrapper (Advanced Mode Only) */
.inputs-column {
    display: contents;
    /* In wizard mode, makes wrapper transparent */
}

/* Advanced Mode */
.advanced-mode .wizard-progress,
.advanced-mode .wizard-nav,
.advanced-mode .skip-hint {
    display: none;
}

.advanced-mode .wizard-container {
    max-width: 1200px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

.advanced-mode .inputs-column {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.advanced-mode .wizard-step {
    display: block !important;
    animation: none;
}

.advanced-mode .wizard-step[data-step="6"] {
    grid-column: 2;
    grid-row: 1;
    position: sticky;
    top: 100px;
    height: fit-content;
}

.advanced-mode .step-content {
    background: transparent;
    padding: 0;
    margin-bottom: 0;
}

.advanced-mode .step-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin-bottom: 20px;
    text-align: center;
}

.advanced-mode .step-fields {
    max-width: 100%;
}

.advanced-mode .results-step {
    display: block !important;
}

.advanced-mode .results-step .step-content {
    background: linear-gradient(145deg, #2F3142 0%, #252736 100%);
    border-radius: 24px;
    padding: 35px;
}

.advanced-mode .results-step .step-header {
    display: block;
    margin-bottom: 25px;
}

.advanced-mode .results-step .step-header h2 {
    font-size: 22px;
}

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

/* Hide timeline/table in wizard mode until results */
.wizard-mode .timeline-section {
    display: none;
}

.wizard-mode.show-results .timeline-section {
    display: block;
}

/* Responsive for wizard */
@media (max-width: 768px) {
    .wizard-progress {
        flex-wrap: wrap;
        gap: 10px;
    }

    .progress-line {
        display: none;
    }

    .step-circle {
        width: 32px;
        height: 32px;
        font-size: 12px;
    }

    .step-label {
        font-size: 9px;
    }

    .step-content {
        padding: 25px 20px;
    }

    .step-header h2 {
        font-size: 22px;
    }

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

    .nav-btn {
        padding: 12px 20px;
        font-size: 14px;
    }
}

.calculator-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto;
}

/* Section Titles */
.section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 30px 0 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.section-title:first-child {
    margin-top: 0;
}

.section-title i {
    color: #FFD500;
    font-size: 24px;
}

.section-title span {
    font-size: 16px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Input Groups */
.input-group-custom {
    margin-bottom: 20px;
}

.input-group-custom.compact {
    margin-bottom: 12px;
}

.age-inputs,
.assumption-inputs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.input-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.input-label-row label {
    font-size: 14px;
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
}

.input-value-display {
    display: flex;
    align-items: center;
    gap: 4px;
    background: rgba(255, 213, 0, 0.1);
    padding: 8px 14px;
    border-radius: 8px;
    border: 1px solid rgba(255, 213, 0, 0.2);
}

.input-value-display .currency {
    color: #FFD500;
    font-weight: 600;
    font-size: 14px;
}

.input-value-display .unit {
    color: rgba(255, 255, 255, 0.6);
    font-size: 13px;
}

.inline-input {
    background: transparent;
    border: none;
    color: #FFD500;
    font-size: 16px;
    font-weight: 700;
    width: 140px;
    text-align: right;
    outline: none;
    font-family: inherit;
}

.inline-input.rate-input {
    width: 40px;
}

.inline-input.age-input {
    width: 35px;
}

/* Sliders */
input[type="range"].slider {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(90deg, #FFD500 0%, #9a20bc 100%);
    outline: none;
    margin: 5px 0;
    border: none;
}

input[type="range"].slider::-webkit-slider-runnable-track {
    -webkit-appearance: none;
    appearance: none;
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(90deg, #FFD500 0%, #9a20bc 100%);
}

input[type="range"].slider::-webkit-slider-thumb {
    -webkit-appearance: none !important;
    appearance: none !important;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border: 3px solid #FFD500;
    margin-top: -8px;
    /* Center the thumb on the track */
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

input[type="range"].slider::-webkit-slider-thumb:hover {
    transform: scale(1.15);
    box-shadow: 0 6px 16px rgba(255, 213, 0, 0.4);
}

input[type="range"].slider::-moz-range-track {
    height: 8px;
    border-radius: 4px;
    background: linear-gradient(90deg, #FFD500 0%, #9a20bc 100%);
}

input[type="range"].slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    border: 3px solid #FFD500;
}

.range-labels {
    display: flex;
    justify-content: space-between;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
    margin-top: 5px;
}

/* Preset Chips */
.preset-chips {
    display: flex;
    gap: 8px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.chip {
    padding: 8px 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.7);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chip:hover {
    background: rgba(255, 213, 0, 0.1);
    border-color: rgba(255, 213, 0, 0.3);
}

.chip.active {
    background: rgba(255, 213, 0, 0.15);
    border-color: #FFD500;
    color: #FFD500;
}

/* Results Panel */
.calculator-results {
    background: linear-gradient(145deg, #2F3142 0%, #252736 100%);
    border-radius: 24px;
    padding: 35px;
    position: sticky;
    top: 100px;
    height: fit-content;
}

.result-card {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 12px 16px;
    border-radius: 16px;
    margin-bottom: 20px;
}

.result-card.primary {
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.08) 0%, rgba(154, 32, 188, 0.08) 100%);
    border: 1px solid rgba(255, 213, 0, 0.2);
}

.result-card.highlight {
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.15) 0%, rgba(255, 193, 7, 0.1) 100%);
    border: 1px solid rgba(76, 175, 80, 0.3);
}

.result-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 213, 0, 0.15);
    flex-shrink: 0;
}

.result-icon i {
    color: #FFD500;
    font-size: 22px;
}

.result-card.highlight .result-icon {
    background: rgba(76, 175, 80, 0.2);
}

.result-card.highlight .result-icon i {
    color: #4CAF50;
}

/* Coast FIRE Card */
.result-card.coast-fire {
    border: 1px solid rgba(0, 188, 212, 0.3);
    background: linear-gradient(145deg, rgba(0, 188, 212, 0.08) 0%, rgba(0, 188, 212, 0.02) 100%);
}

.result-card.coast-fire .result-icon {
    background: rgba(0, 188, 212, 0.2);
}

.result-card.coast-fire .result-icon i {
    color: #00BCD4;
}

.result-card.coast-fire .result-value {
    color: #00BCD4;
}

.result-card.coast-fire.not-achieved {
    opacity: 0.5;
    border-color: rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.02);
}

.result-card.coast-fire.not-achieved .result-icon {
    background: rgba(255, 255, 255, 0.05);
}

.result-card.coast-fire.not-achieved .result-icon i,
.result-card.coast-fire.not-achieved .result-value {
    color: rgba(255, 255, 255, 0.4);
}

/* FIRE Level Tabs */
.fire-level-tabs {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    justify-content: center;
}

.fire-tab {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 100px;
}

.fire-tab:hover {
    background: rgba(255, 255, 255, 0.06);
    border-color: rgba(255, 255, 255, 0.2);
}

.fire-tab.active {
    background: rgba(255, 213, 0, 0.12);
    border-color: #FFD500;
}

.fire-tab .tab-label {
    font-size: 13px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.7);
}

.fire-tab.active .tab-label {
    color: #FFD500;
}

.fire-tab .tab-desc {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
}

.fire-tab.active .tab-desc {
    color: rgba(255, 213, 0, 0.7);
}

/* Monte Carlo Card */
.result-card.monte-carlo {
    border: 1px solid rgba(156, 39, 176, 0.3);
    background: linear-gradient(145deg, rgba(156, 39, 176, 0.08) 0%, rgba(156, 39, 176, 0.02) 100%);
}

.result-card.monte-carlo .result-icon {
    background: rgba(156, 39, 176, 0.2);
}

.result-card.monte-carlo .result-icon i {
    color: #9C27B0;
}

.result-card.monte-carlo .result-value {
    color: #CE93D8;
    font-size: 24px;
}

/* Success Bar */
.success-bar-container {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
    margin: 6px 0;
}

.success-bar {
    height: 100%;
    background: linear-gradient(90deg, #f44336 0%, #ff9800 30%, #4caf50 60%, #4caf50 100%);
    border-radius: 4px;
    transition: width 0.5s ease;
}

/* Success bar color based on percentage */
.success-bar.low {
    background: linear-gradient(90deg, #f44336, #ff5722);
}

.success-bar.medium {
    background: linear-gradient(90deg, #ff9800, #ffc107);
}

.success-bar.high {
    background: linear-gradient(90deg, #8bc34a, #4caf50);
}

.success-bar.very-high {
    background: linear-gradient(90deg, #4caf50, #2e7d32);
}

/* Info Tooltip */
.info-tooltip {
    position: relative;
    display: inline-flex;
    align-items: center;
    margin-left: 6px;
    cursor: help;
}

.info-icon {
    font-size: 16px;
    color: rgba(255, 255, 255, 0.4);
    transition: color 0.2s ease;
}

.info-tooltip:hover .info-icon {
    color: #CE93D8;
}

.tooltip-text {
    visibility: hidden;
    opacity: 0;
    position: absolute;
    bottom: 130%;
    left: 50%;
    transform: translateX(-50%);
    width: 280px;
    background: rgba(30, 30, 30, 0.98);
    border: 1px solid rgba(156, 39, 176, 0.3);
    border-radius: 10px;
    padding: 14px;
    font-size: 12px;
    font-weight: 400;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
    text-transform: none;
    letter-spacing: 0;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 100;
    transition: all 0.2s ease;
}

.tooltip-text::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 8px solid transparent;
    border-top-color: rgba(30, 30, 30, 0.98);
}

.info-tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

.tooltip-link {
    color: #CE93D8;
    text-decoration: none;
    font-weight: 600;
    display: inline-block;
    margin-top: 4px;
}

.tooltip-link:hover {
    text-decoration: underline;
}

/* SWR Card */
.result-card.swr-card {
    border: 1px solid rgba(255, 152, 0, 0.3);
    background: linear-gradient(145deg, rgba(255, 152, 0, 0.08) 0%, rgba(255, 152, 0, 0.02) 100%);
}

.result-card.swr-card .result-icon {
    background: rgba(255, 152, 0, 0.2);
}

.result-card.swr-card .result-icon i {
    color: #FF9800;
}

.result-card.swr-card .result-value {
    color: #FFB74D;
}

/* SWR Status Colors */
.result-card.swr-card.safe .result-value {
    color: #4CAF50;
}

.result-card.swr-card.caution .result-value {
    color: #FFC107;
}

.result-card.swr-card.high-risk .result-value {
    color: #f44336;
}

/* Corpus Multiple Card */
.result-card.corpus-multiple {
    border: 1px solid rgba(124, 58, 237, 0.3);
    background: linear-gradient(145deg, rgba(124, 58, 237, 0.08) 0%, rgba(91, 33, 182, 0.02) 100%);
}

.result-card.corpus-multiple .result-icon {
    background: rgba(124, 58, 237, 0.2);
}

.result-card.corpus-multiple .result-icon i {
    color: #7C3AED;
}

.result-card.corpus-multiple .result-value {
    font-size: 3.5rem;
    font-weight: 700;
    color: #A78BFA;
}

.result-card.corpus-multiple.safe .result-value {
    color: #10b981;
}

/* Advanced Insights Accordion */
.advanced-insights-accordion {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    margin-bottom: 20px;
    overflow: hidden;
}

.advanced-insights-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.advanced-insights-header:hover {
    background: rgba(255, 255, 255, 0.03);
}

.advanced-insights-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.advanced-insights-title .material-icons {
    font-size: 22px;
    color: #A78BFA;
}

.advanced-insights-arrow {
    font-size: 24px;
    color: rgba(255, 255, 255, 0.5);
    transition: transform 0.3s ease;
}

.advanced-insights-accordion.expanded .advanced-insights-arrow {
    transform: rotate(180deg);
}

.advanced-insights-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
    padding: 0 20px;
}

.advanced-insights-accordion.expanded .advanced-insights-content {
    max-height: 2000px;
    padding: 0 20px 20px;
}

/* Multiple Comparison Section */
.multiple-comparison-section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 20px;
}

.comparison-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.comparison-header .material-icons {
    font-size: 24px;
    color: #7C3AED;
}

.comparison-table {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.comparison-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1.5fr;
    gap: 16px;
    padding: 12px 16px;
    background: rgba(255, 255, 255, 0.02);
    border-radius: 8px;
    font-size: 0.95rem;
    transition: all 0.2s ease;
}

.comparison-row.header-row {
    background: rgba(255, 255, 255, 0.05);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.comparison-row:not(.header-row):hover {
    background: rgba(255, 255, 255, 0.05);
    transform: translateX(4px);
}

.comparison-row.highlight-row {
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.15), rgba(91, 33, 182, 0.15));
    border: 2px solid rgba(124, 58, 237, 0.3);
    font-weight: 600;
}

.multiple-label {
    color: rgba(255, 255, 255, 0.9);
}

.comparison-row .swr-value {
    color: rgba(255, 255, 255, 0.7);
}

.success-value {
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 600;
}

.success-value.high {
    color: #10b981;
}

.success-value.medium {
    color: #f59e0b;
}

.success-value.low {
    color: #ef4444;
}

.success-value::before {
    content: '';
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
}

/* Time vs Money Trade-off Section */
.time-vs-money-section {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 20px;
}

.tradeoff-header {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 20px;
}

.tradeoff-header .material-icons {
    font-size: 28px;
    color: #60A5FA;
    margin-top: 2px;
}

.tradeoff-title-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tradeoff-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.tradeoff-subtitle {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.5);
}

.tradeoff-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.tradeoff-option {
    display: grid;
    grid-template-columns: 140px 40px 120px 1fr;
    align-items: center;
    gap: 16px;
    padding: 14px 18px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    transition: all 0.2s ease;
}

.tradeoff-option:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(96, 165, 250, 0.3);
    transform: translateX(4px);
}

.tradeoff-option.current {
    background: linear-gradient(135deg, rgba(96, 165, 250, 0.1), rgba(59, 130, 246, 0.05));
    border-color: rgba(96, 165, 250, 0.3);
}

.tradeoff-timing {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.timing-label {
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.timing-age {
    font-size: 1rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.tradeoff-arrow {
    color: rgba(255, 255, 255, 0.3);
    font-size: 1.2rem;
    text-align: center;
}

.tradeoff-result {
    display: flex;
    align-items: baseline;
    gap: 8px;
}

.result-success {
    font-size: 1.4rem;
    font-weight: 700;
    color: #60A5FA;
}

.result-success.high {
    color: #10b981;
}

.result-success.medium {
    color: #f59e0b;
}

.result-success.low {
    color: #ef4444;
}

.result-label {
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.5);
}

.tradeoff-delta {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #10b981;
    font-size: 0.9rem;
    font-weight: 600;
}

.tradeoff-delta .material-icons {
    font-size: 18px;
}

.tradeoff-insight {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 16px;
    padding: 12px 16px;
    background: rgba(96, 165, 250, 0.08);
    border-left: 3px solid #60A5FA;
    border-radius: 8px;
}

.tradeoff-insight .material-icons {
    color: #60A5FA;
    font-size: 20px;
}

.tradeoff-insight span {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.5;
}

.result-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.result-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.result-value {
    font-size: 28px;
    font-weight: 700;
    color: #FFD500;
}

.result-value.large {
    font-size: 36px;
    color: #4CAF50;
}

.result-subtitle {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    font-style: italic;
}

/* Result Breakdown */
.result-breakdown {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
}

.breakdown-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.breakdown-row:last-child {
    border-bottom: none;
}

.breakdown-label {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
}

.breakdown-value {
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.breakdown-value.positive {
    color: #4CAF50;
}

/* CTA Section */
.cta-section {
    text-align: center;
}

.download-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(135deg, #FFD500 0%, #FF8C00 100%);
    color: #1E1F2E;
    padding: 14px 28px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(255, 213, 0, 0.25);
    color: #1E1F2E;
}

/* Timeline Section */
.timeline-section {
    margin-top: 60px;
    background: linear-gradient(145deg, #2F3142 0%, #252736 100%);
    border-radius: 24px;
    padding: 40px;
}

.section-header {
    text-align: center;
    margin-bottom: 30px;
}

.section-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 10px;
}

.section-subtitle {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.6);
}

.timeline-legend {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 25px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
}

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

.legend-color.accumulation {
    background: linear-gradient(135deg, #FFD500, #9a20bc);
}

.legend-color.retirement {
    background: linear-gradient(135deg, #4CAF50, #2E7D32);
}

.timeline-chart {
    position: relative;
    height: 300px;
    margin-top: 20px;
}

.chart-container {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    height: 100%;
    gap: 3px;
    padding: 0 10px;
}

.chart-bar-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    max-width: 30px;
}

.chart-bar {
    width: 100%;
    border-radius: 4px 4px 0 0;
    transition: all 0.3s ease;
    min-height: 2px;
    position: relative;
}

.chart-bar.accumulation {
    background: linear-gradient(to top, #FFD500, #9a20bc);
}

.chart-bar.retirement {
    background: linear-gradient(to top, #4CAF50, #2E7D32);
}

.chart-bar.peak {
    border: 2px solid #FFD500;
    box-shadow: 0 0 15px rgba(255, 213, 0, 0.4);
}

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

.chart-bar-label {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 8px;
    white-space: nowrap;
    text-align: center;
}

.chart-bar-label.highlight {
    color: #FFD500;
    font-weight: 600;
    font-size: 12px;
}

/* Coast FIRE Marker on Chart */
.chart-bar.coast-fire {
    background: linear-gradient(180deg, #00BCD4 0%, #0097A7 100%);
    border: 2px solid #00BCD4;
    box-shadow: 0 0 12px rgba(0, 188, 212, 0.4);
    position: relative;
}

.chart-bar.coast-fire::after {
    content: '🌴';
    position: absolute;
    top: -24px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 16px;
}

.chart-bar-label.coast-fire {
    color: #00BCD4;
    font-weight: 600;
}

/* Info Section */
.info-section {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 50px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
    padding: 0 40px;
}

.info-card {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 16px;
    padding: 28px;
    text-align: center;
    transition: all 0.3s ease;
}

.info-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 213, 0, 0.2);
    transform: translateY(-4px);
}

.info-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.15) 0%, rgba(154, 32, 188, 0.1) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.info-icon i {
    font-size: 28px;
    color: #FFD500;
}

.info-card h3 {
    font-size: 18px;
    font-weight: 600;
    color: #fff;
    margin-bottom: 10px;
}

.info-card p {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.6;
    margin-bottom: 12px;
}

.info-card-link {
    display: inline-block;
    color: #64B5F6;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
}

.info-card-link:hover {
    color: #90CAF9;
    text-decoration: underline;
}

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

    .calculator-results {
        position: static;
    }

    .age-inputs,
    .assumption-inputs {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 768px) {
    .calculator-header h1 {
        font-size: 32px;
    }

    .calculator-section {
        padding: 80px 15px 40px;
    }

    .result-value {
        font-size: 24px;
    }

    .result-value.large {
        font-size: 28px;
    }

    .result-card.corpus-multiple .result-value {
        font-size: 2.5rem;
    }

    .comparison-row {
        grid-template-columns: 80px 1fr 1fr;
        gap: 8px;
        padding: 10px 12px;
        font-size: 0.85rem;
    }

    .comparison-header {
        font-size: 1rem;
    }

    .multiple-comparison-section {
        padding: 16px;
    }

    .tradeoff-option {
        grid-template-columns: 1fr;
        gap: 8px;
        padding: 12px 14px;
    }

    .tradeoff-arrow {
        display: none;
    }

    .tradeoff-delta {
        justify-content: flex-end;
    }
}

/* Milestones Section */
.section-description {
    font-size: 14px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 15px;
    margin-top: -10px;
}

.milestone-quick-add {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
    align-items: center;
}

.quick-add-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    margin-right: 5px;
}

.chip-add {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.8);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chip-add:hover {
    background: rgba(255, 213, 0, 0.15);
    border-color: #FFD500;
    color: #FFD500;
    transform: translateY(-2px);
}

.chip-add i {
    font-size: 16px;
}

.chip-add.custom {
    border-style: dashed;
}

/* Milestone Item */
.milestones-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.milestone-item {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 40px;
    gap: 12px;
    background: rgba(0, 0, 0, 0.2);
    padding: 12px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    align-items: center;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.milestone-input-group label {
    display: block;
    font-size: 11px;
    color: rgba(255, 255, 255, 0.4);
    margin-bottom: 4px;
}

.milestone-input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 6px 10px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: all 0.2s ease;
}

.milestone-input:focus {
    border-color: #FFD500;
    background: rgba(255, 213, 0, 0.05);
}

.btn-delete {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 59, 48, 0.1);
    border: none;
    color: #FF3B30;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-top: 14px;
    /* Align with inputs */
}

.btn-delete:hover {
    background: #FF3B30;
    color: #fff;
    transform: rotate(90deg);
}

.btn-delete i {
    font-size: 18px;
}

@media (max-width: 576px) {
    .milestone-item {
        position: relative;
        display: flex;
        flex-direction: column;
        gap: 12px;
        padding: 16px;
        padding-top: 44px;
        /* Room for delete button at top */
    }

    .milestone-item .milestone-input-group {
        width: 100%;
    }

    .milestone-item .btn-delete {
        position: absolute;
        top: 8px;
        right: 8px;
        margin-top: 0;
    }
}

/* Info Section padding fix */
.info-section {
    padding-bottom: 40px;
}

/* Yearly Breakdown Section */
.yearly-breakdown-section {
    margin-top: 60px;
    background: linear-gradient(145deg, #2F3142 0%, #252736 100%);
    border-radius: 24px;
    padding: 40px;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.breakdown-header {
    text-align: center;
    margin-bottom: 30px;
}

.breakdown-header h2 {
    font-size: 28px;
    font-family: "Raleway", sans-serif;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}

.breakdown-subtitle {
    font-size: 15px;
    color: rgba(255, 255, 255, 0.6);
    margin-bottom: 0;
}

/* Yearly Table */
.yearly-table-container {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
}

.table-toggle {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    border: none;
    padding: 12px;
    cursor: pointer;
    color: rgba(255, 255, 255, 0.6);
    font-size: 14px;
    font-weight: 500;
    transition: color 0.3s ease;
}

.table-toggle:hover {
    color: #FFD500;
}

.table-toggle i {
    font-size: 20px;
    transition: transform 0.3s ease;
}

.table-toggle.expanded i {
    transform: rotate(180deg);
}

.yearly-table-wrapper {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease;
}

.yearly-table-wrapper.show {
    max-height: 800px;
    overflow-y: auto;
}

.yearly-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 16px;
}

.yearly-table thead th {
    text-align: left;
    padding: 12px 14px;
    font-size: 12px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.yearly-table tbody tr {
    transition: background 0.2s ease;
}

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

.yearly-table tbody tr.goal-row {
    background: rgba(255, 213, 0, 0.08);
}

.yearly-table tbody tr.retirement-row {
    background: rgba(76, 175, 80, 0.1);
    border-top: 2px solid rgba(76, 175, 80, 0.3);
}

.yearly-table tbody tr.depleted-row {
    background: rgba(255, 59, 48, 0.1);
}

.yearly-table tbody td {
    padding: 12px 14px;
    font-size: 13px;
    color: rgba(255, 255, 255, 0.85);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.yearly-table tbody td:first-child {
    font-weight: 600;
}

.positive-value {
    color: #4CAF50;
}

.negative-value {
    color: #FF5252;
}

.goal-indicator {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    background: rgba(255, 213, 0, 0.15);
    border-radius: 4px;
    font-size: 11px;
    color: #FFD500;
}

.goal-indicator i {
    font-size: 14px;
}

.phase-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 500;
}

.phase-badge.accumulation {
    background: linear-gradient(135deg, rgba(255, 213, 0, 0.15), rgba(154, 32, 188, 0.15));
    color: #FFD500;
}

.phase-badge.retirement {
    background: rgba(76, 175, 80, 0.15);
    color: #4CAF50;
}

@media (max-width: 768px) {
    .yearly-table-wrapper {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }

    .yearly-table-wrapper.show {
        overflow-x: auto;
        overflow-y: auto;
    }

    .yearly-table {
        font-size: 12px;
        min-width: 600px;
        /* Force horizontal scroll on narrow screens */
    }

    .yearly-table thead th,
    .yearly-table tbody td {
        padding: 8px 6px;
        white-space: nowrap;
    }

    .yearly-breakdown-section {
        padding: 20px;
    }
}

/* Advanced Mode Mobile Responsive Styles */
@media (max-width: 992px) {
    .advanced-mode .wizard-container {
        grid-template-columns: 1fr;
        gap: 20px;
        padding-top: 20px;
    }

    .advanced-mode .wizard-step[data-step="6"] {
        grid-column: 1;
        grid-row: auto;
        position: static;
        margin-top: 20px;
    }

    /* Move inputs to appear first naturally */
    .advanced-mode .wizard-step:not([data-step="6"]) {
        grid-column: 1;
    }

    .advanced-mode .results-step .step-content {
        padding: 20px;
    }

    .advanced-mode .mode-toggle-bottom {
        margin-top: 20px;
        padding: 15px 10px;
    }

    .advanced-mode .mode-btn-subtle {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 768px) {
    .advanced-mode .wizard-container {
        padding: 25px 20px;
    }

    .advanced-mode .step-content {
        padding: 0;
    }

    .advanced-mode .input-label-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .advanced-mode .input-label-row label {
        font-size: 13px;
    }

    .advanced-mode .input-value-display {
        width: 100%;
        justify-content: center;
    }

    .advanced-mode .section-title {
        margin: 20px 0 15px;
    }

    .advanced-mode .section-title span {
        font-size: 14px;
    }

    .advanced-mode .age-inputs,
    .advanced-mode .assumption-inputs {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .advanced-mode .results-step .step-content {
        padding: 15px;
        border-radius: 16px;
    }

    .advanced-mode .results-step .step-header h2 {
        font-size: 18px;
    }

    .advanced-mode .result-card {
        padding: 16px;
        gap: 12px;
    }

    .advanced-mode .result-icon {
        width: 40px;
        height: 40px;
    }

    .advanced-mode .result-icon i {
        font-size: 20px;
    }

    .advanced-mode .result-value {
        font-size: 22px;
    }

    .emergency-fund-tip {
        flex-direction: column;
        padding: 14px;
    }

    .tip-link {
        margin-left: 0;
        margin-top: 8px;
        display: inline-block;
    }
}

/* ========================================
   ENHANCED MOBILE UI/UX IMPROVEMENTS
   ======================================== */

/* Mobile-specific improvements (max-width: 576px) */
@media (max-width: 576px) {

    /* --- FIRE Type Buttons: Stack Vertically --- */
    .fire-level-tabs {
        flex-direction: column;
        gap: 10px;
    }

    .fire-tab {
        width: 100%;
        flex-direction: row;
        justify-content: space-between;
        padding: 16px 20px;
        min-height: 54px;
    }

    .fire-tab .tab-label {
        font-size: 15px;
    }

    .fire-tab .tab-desc {
        font-size: 12px;
        text-align: right;
    }

    /* --- Preset Chips: Larger Touch Targets --- */
    .preset-chips {
        gap: 10px;
    }

    .chip {
        padding: 12px 18px;
        min-height: 44px;
        font-size: 14px;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    /* --- Slider Improvements --- */
    input[type="range"].slider {
        -webkit-appearance: none !important;
        appearance: none !important;
        height: 10px !important;
        margin: 10px 0 !important;
        background: linear-gradient(90deg, #FFD500 0%, #9a20bc 100%) !important;
        border: none !important;
    }

    input[type="range"].slider::-webkit-slider-runnable-track {
        -webkit-appearance: none !important;
        appearance: none !important;
        height: 10px !important;
        background: linear-gradient(90deg, #FFD500 0%, #9a20bc 100%) !important;
        border-radius: 5px !important;
    }

    input[type="range"].slider::-webkit-slider-thumb {
        -webkit-appearance: none !important;
        appearance: none !important;
        width: 28px !important;
        height: 28px !important;
        border: 3px solid #FFD500 !important;
        border-radius: 50% !important;
        background: #fff !important;
        margin-top: -9px !important;
        cursor: pointer !important;
    }

    .range-labels {
        font-size: 12px;
        padding: 0 4px;
        margin-top: 8px;
    }

    /* --- Quick-Add Milestone Chips: Horizontally Scrollable --- */
    .milestone-quick-add {
        flex-wrap: nowrap;
        overflow-x: auto;
        padding: 4px 4px 10px 4px;
        /* Prevent chip borders from being cut off */
        margin: -4px -4px 15px -4px;
        /* Compensate for padding */
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }

    .milestone-quick-add::-webkit-scrollbar {
        display: none;
    }

    .chip-add {
        padding: 12px 18px;
        min-height: 44px;
        min-width: max-content;
        flex-shrink: 0;
    }

    .quick-add-label {
        min-width: max-content;
        flex-shrink: 0;
    }

    /* --- Result Cards: Better Mobile Layout --- */
    .result-card {
        padding: 18px;
        gap: 14px;
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .result-icon {
        width: 56px;
        height: 56px;
    }

    .result-icon i {
        font-size: 28px;
    }

    .result-content {
        align-items: center;
    }

    .result-value {
        font-size: 26px;
    }

    .result-value.large {
        font-size: 32px;
    }

    /* --- Progress Bar: Horizontally Scrollable Mobile --- */
    .wizard-progress {
        padding: 0 15px;
        gap: 0;
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        /* Firefox */
        scroll-behavior: smooth;
        margin-bottom: 30px;
    }

    .wizard-progress::-webkit-scrollbar {
        display: none;
        /* Chrome, Safari */
    }

    .progress-step {
        gap: 6px;
        flex: 0 0 auto;
        /* Don't grow, don't shrink, auto width */
        min-width: 65px;
        /* Fixed minimum width for each step */
        padding: 0 5px;
    }

    .step-circle {
        width: 40px;
        height: 40px;
        font-size: 14px;
        flex-shrink: 0;
    }

    .step-circle i {
        font-size: 16px;
    }

    .step-label {
        font-size: 9px;
        max-width: 60px;
        text-align: center;
        line-height: 1.3;
        white-space: nowrap;
    }

    /* --- Input Groups: Better Spacing --- */
    .input-group-custom {
        margin-bottom: 24px;
    }

    .input-label-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }

    .input-value-display {
        width: 100%;
        justify-content: center;
        padding: 12px 16px;
    }

    .inline-input {
        font-size: 18px;
        text-align: center;
    }

    /* --- Step Content: More Padding --- */
    .step-content {
        padding: 24px 18px;
    }

    .step-header h2 {
        font-size: 20px;
    }

    .step-description {
        font-size: 13px;
    }

    .step-icon {
        font-size: 36px;
    }

    /* --- Navigation Buttons: Full Width --- */
    .wizard-nav {
        flex-direction: column;
        gap: 12px;
        padding: 0;
    }

    .nav-btn {
        width: 100%;
        justify-content: center;
        padding: 16px 24px;
        font-size: 16px;
    }

    .nav-btn.next {
        order: -1;
    }

    /* --- Info Cards: Better Mobile Layout --- */
    .info-section {
        gap: 16px;
    }

    .info-card {
        padding: 24px 20px;
    }

    .info-icon {
        width: 50px;
        height: 50px;
    }

    .info-icon i {
        font-size: 24px;
    }

    /* --- Timeline Section: Mobile Optimized --- */
    .timeline-section {
        padding: 24px 16px;
        border-radius: 16px;
    }

    .section-header h2 {
        font-size: 22px;
    }

    .section-subtitle {
        font-size: 13px;
    }

    .timeline-legend {
        gap: 16px;
        flex-wrap: wrap;
    }

    .legend-item {
        font-size: 12px;
    }

    /* --- Table Toggle: Larger Touch Target --- */
    .table-toggle {
        padding: 16px;
        min-height: 52px;
    }

    /* --- Success Bar: Better Mobile Visibility --- */
    .success-bar-container {
        height: 12px;
        border-radius: 6px;
        margin: 10px 0;
    }

    /* --- Tooltips: Mobile Friendly --- */
    .info-tooltip .tooltip-text {
        /* Reset desktop positioning */
        left: 50%;
        right: auto;
        transform: translateX(-90%);
        /* Shift left more to stay in viewport */
        width: min(280px, calc(100vw - 32px));
        /* Constrain width to viewport */
        max-width: 280px;
        font-size: 12px;
    }

    /* Arrow follows tooltip center */
    .info-tooltip .tooltip-text::after {
        left: 90%;
        transform: translateX(-50%);
    }

    /* --- Calculator Header --- */
    .calculator-header h1 {
        font-size: 28px;
    }

    .calculator-header .subtitle {
        font-size: 15px;
    }

    /* --- Breakdown Section --- */
    .result-breakdown {
        padding: 16px;
    }

    .breakdown-row {
        padding: 12px 0;
    }

    .breakdown-label {
        font-size: 13px;
    }

    .breakdown-value {
        font-size: 14px;
    }
}

/* ========================================
   ACCORDION SECTION STYLES
   ======================================== */

/* Collapsible Section Container */
.collapsible-section {
    margin-bottom: 20px;
}

.collapsible-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.collapsible-header:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: rgba(255, 255, 255, 0.15);
}

.collapsible-header.active {
    background: rgba(255, 213, 0, 0.08);
    border-color: rgba(255, 213, 0, 0.2);
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

.collapsible-title {
    display: flex;
    align-items: center;
    gap: 12px;
}

.collapsible-title i {
    color: #FFD500;
    font-size: 22px;
}

.collapsible-title span {
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.collapsible-arrow {
    color: rgba(255, 255, 255, 0.5);
    font-size: 24px;
    transition: transform 0.3s ease;
}

.collapsible-header.active .collapsible-arrow {
    transform: rotate(180deg);
    color: #FFD500;
}

.collapsible-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease;
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-top: none;
    border-radius: 0 0 12px 12px;
}

.collapsible-content.show {
    max-height: 1000px;
    padding: 20px;
}

/* Accordion animation */
.collapsible-content-inner {
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.collapsible-content.show .collapsible-content-inner {
    opacity: 1;
    transform: translateY(0);
}

/* ========================================
   TABLET IMPROVEMENTS (max-width: 768px)
   ======================================== */

@media (max-width: 768px) {

    /* FIRE tabs partial stack */
    .fire-level-tabs {
        flex-wrap: wrap;
    }

    .fire-tab {
        flex: 1 1 calc(50% - 4px);
        min-width: 140px;
    }

    /* Larger slider for tablet */
    input[type="range"].slider::-webkit-slider-thumb {
        -webkit-appearance: none !important;
        appearance: none !important;
        width: 26px !important;
        height: 26px !important;
        border: 3px solid #FFD500 !important;
        border-radius: 50% !important;
        background: #fff !important;
        margin-top: -8px !important;
        cursor: pointer !important;
    }

    /* Result cards side by side on tablet */
    .results-grid {
        gap: 16px;
    }

    /* Timeline chart height */
    .timeline-chart {
        height: 250px;
    }
}

/* ========================================
   TOUCH DEVICE IMPROVEMENTS
   ======================================== */

@media (hover: none) and (pointer: coarse) {

    /* Remove hover effects on touch devices */
    .chip:hover,
    .fire-tab:hover,
    .collapsible-header:hover,
    .nav-btn.prev:hover:not(:disabled) {
        background: inherit;
        border-color: inherit;
        color: inherit;
    }

    /* Active state replacements */
    .chip:active {
        background: rgba(255, 213, 0, 0.2);
        transform: scale(0.98);
    }

    .fire-tab:active {
        background: rgba(255, 255, 255, 0.08);
    }

    .nav-btn:active {
        transform: scale(0.98);
    }

    /* Ensure minimum touch targets */
    button,
    a,
    .chip,
    .chip-add,
    .fire-tab {
        min-height: 44px;
    }
}

/* ========================================
   SMOOTH SCROLLING AND ANIMATIONS
   ======================================== */

@media (prefers-reduced-motion: no-preference) {
    .collapsible-content {
        transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .chip,
    .fire-tab,
    .nav-btn,
    .chip-add {
        transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    }
}

/* Respect reduced motion preference */
@media (prefers-reduced-motion: reduce) {

    .collapsible-content,
    .chip,
    .fire-tab,
    .nav-btn,
    .chip-add,
    .wizard-step {
        transition: none !important;
        animation: none !important;
    }
}

/* ========================================
   STICKY BOTTOM NAVIGATION BAR
   ======================================== */

/* Desktop: Normal flow (no sticky behavior) */
/* Sticky behavior only applies on mobile via media query below */

.wizard-nav-placeholder {
    display: none;
}

/* Mobile Only: Sticky bottom navigation within calculator section */
@media (max-width: 768px) {

    /* The wizard-container needs to allow overflow for sticky to work */
    /* overflow: hidden in base styles breaks position: sticky */
    .wizard-container {
        position: relative;
        overflow: visible !important;
    }

    .wizard-nav.sticky-nav {
        position: sticky;
        bottom: 0;
        z-index: 100;
        background: rgba(30, 31, 46, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        padding: 16px 20px;
        display: flex;
        justify-content: center;
        gap: 16px;
        box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.4);
        border-top: 1px solid rgba(255, 255, 255, 0.1);
        margin: 0 -15px;
        /* Extend to container edges */
        width: calc(100% + 30px);
    }

    /* Nav buttons in sticky mode */
    .wizard-nav.sticky-nav .nav-btn {
        flex: 1;
        max-width: none;
    }

    .wizard-nav.sticky-nav .nav-btn.prev {
        flex: 0.7;
    }

    .wizard-nav.sticky-nav .nav-btn.next {
        flex: 1.3;
    }

    /* Hide placeholder on mobile - sticky doesn't need it */
    .wizard-nav-placeholder {
        display: none;
    }
}

/* Extra small mobile adjustments */
@media (max-width: 576px) {
    .wizard-nav.sticky-nav {
        padding: 12px 16px;
        padding-bottom: calc(12px + env(safe-area-inset-bottom, 0px));
        gap: 12px;
    }

    .wizard-nav.sticky-nav .nav-btn {
        padding: 14px 20px;
        font-size: 15px;
    }
}

/* Results page sticky nav variant */
.wizard-nav.sticky-nav.results-nav {
    justify-content: center;
}

.wizard-nav.sticky-nav.results-nav .nav-btn {
    max-width: 250px;
}

/* Start Over button style */
.nav-btn.start-over {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.7);
}

.nav-btn.start-over:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

/* See Results button (finish step) */
.nav-btn.see-results {
    background: linear-gradient(135deg, #4CAF50 0%, #2E7D32 100%);
    color: #fff;
}

/* Safe area padding for notch devices */
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .wizard-nav.sticky-nav {
        padding-bottom: calc(16px + env(safe-area-inset-bottom));
    }
}

/* ========================================
   ACCORDION ENHANCEMENTS FOR RESULTS
   ======================================== */

/* Result breakdown accordion header */
.breakdown-accordion-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 0;
}

.breakdown-accordion-header:hover {
    background: rgba(0, 0, 0, 0.3);
}

.breakdown-accordion-header.active {
    border-radius: 12px 12px 0 0;
    background: rgba(255, 213, 0, 0.1);
}

.breakdown-accordion-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
}

.breakdown-accordion-title i {
    color: #FFD500;
    font-size: 20px;
}

.breakdown-accordion-arrow {
    color: rgba(255, 255, 255, 0.5);
    font-size: 22px;
    transition: transform 0.3s ease;
}

.breakdown-accordion-header.active .breakdown-accordion-arrow {
    transform: rotate(180deg);
    color: #FFD500;
}

/* Breakdown content with accordion animation */
.result-breakdown.accordion-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border-radius: 0 0 12px 12px;
    margin-top: 0;
}

.result-breakdown.accordion-content.show {
    max-height: 500px;
}

/* Summary row that shows when collapsed */
.breakdown-summary {
    display: flex;
    gap: 16px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
}

.breakdown-summary-item {
    display: flex;
    align-items: center;
    gap: 4px;
}

.breakdown-summary-item .value {
    color: #FFD500;
    font-weight: 600;
}

/* Hide summary when expanded */
.breakdown-accordion-header.active .breakdown-summary {
    display: none;
}

/* ========================================
   DESKTOP-ONLY: Always expanded breakdown
   ======================================== */
@media (min-width: 769px) {

    /* Hide the accordion toggle header on desktop */
    .breakdown-accordion-header {
        display: none;
    }

    /* Always show breakdown content expanded on desktop */
    .result-breakdown.accordion-content {
        max-height: none;
        overflow: visible;
    }
}

/* ========================================
   ADVANCED MODE: Ensure nav buttons hidden
   ======================================== */
.advanced-mode .wizard-nav,
.advanced-mode .wizard-nav-placeholder {
    display: none !important;
}

/* ========================================
   VALIDATION TOAST NOTIFICATION
   ======================================== */
.validation-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: rgba(255, 59, 48, 0.95);
    /* Error Red */
    color: white;
    padding: 12px 24px;
    border-radius: 50px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    font-size: 14px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 10px;
    z-index: 10000;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none;
    backdrop-filter: blur(5px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    min-width: 280px;
    justify-content: center;
}

.validation-toast.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.validation-toast i {
    font-size: 18px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    padding: 2px;
}

@media (min-width: 769px) {
    .validation-toast {
        bottom: auto;
        top: 30px;
        min-width: auto;
    }
}

/* Success Toast (green) */
.validation-toast.success {
    background: rgba(76, 175, 80, 0.95);
}

/* Info Toast (blue) */
.validation-toast.info {
    background: rgba(33, 150, 243, 0.95);
}

/* ========================================
   FOOTER STYLES OVERRIDE
   ======================================== */
/* Ensure footer social icons match main site design */
#vrid-footer .footer-social li a {
    height: 36px;
    width: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff !important;
    color: #1E1735 !important;
    border-radius: 50%;
    text-decoration: none;
    transition: all 0.3s ease;
}

#vrid-footer .footer-social li a:hover {
    color: #fff !important;
    /* Hover color is handled by inline style var or could be forced here if needed */
    background: var(--hover-color, #9a20bc) !important;
}

#vrid-footer .footer-social li {
    list-style: none;
    margin: 0 5px;
}

#vrid-footer ul.footer-social {
    display: flex;
    padding: 0;
    margin: 0;
    justify-content: flex-end;
}

@media (max-width: 991px) {
    #vrid-footer ul.footer-social {
        justify-content: center !important;
        margin-top: 20px;
    }
}

/* Share Plan Section */
.share-plan-section {
    background: linear-gradient(135deg, rgba(33, 150, 243, 0.08) 0%, rgba(156, 39, 176, 0.08) 100%);
    border: 1px solid rgba(33, 150, 243, 0.2);
    border-radius: 12px;
    padding: 20px;
    margin-top: 25px;
}

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

.share-header i {
    font-size: 22px;
    color: #2196F3;
}

.share-header span {
    font-size: 15px;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
}

.share-buttons {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.share-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
}

.share-btn.copy-link {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: rgba(255, 255, 255, 0.9);
}

.share-btn.copy-link:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.3);
}

.share-btn.copy-link.copied {
    background: rgba(76, 175, 80, 0.2);
    border-color: #4CAF50;
    color: #4CAF50;
}

.share-btn.whatsapp {
    background: #25D366;
    color: #fff;
}

.share-btn.whatsapp:hover {
    background: #1DA851;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(37, 211, 102, 0.3);
}

.share-btn i {
    font-size: 18px;
}

@media (max-width: 480px) {
    .share-buttons {
        flex-direction: column;
    }

    .share-btn {
        justify-content: center;
        width: 100%;
    }
}

/* ========================================
   WHAT-IF SCENARIOS SECTION
   ======================================== */
.what-if-section {
    margin-top: 30px;
    padding: 24px;
    background: linear-gradient(135deg, rgba(76, 175, 80, 0.05) 0%, rgba(255, 193, 7, 0.05) 100%);
    border: 1px solid rgba(76, 175, 80, 0.15);
    border-radius: 16px;
    transition: all 0.4s ease;
}

/* Prominent styling when plan is failing */
.what-if-section.urgent {
    background: linear-gradient(135deg, rgba(255, 152, 0, 0.12) 0%, rgba(244, 67, 54, 0.12) 100%);
    border: 2px solid rgba(255, 152, 0, 0.4);
    box-shadow: 0 0 20px rgba(255, 152, 0, 0.15);
}

.what-if-header {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    margin-bottom: 20px;
}

.what-if-header>i {
    font-size: 28px;
    color: #4CAF50;
    margin-top: 2px;
}

.what-if-section.urgent .what-if-header>i {
    color: #FF9800;
}

.what-if-title-group {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.what-if-title {
    font-size: 18px;
    font-weight: 700;
    color: #fff;
    font-family: "Raleway", sans-serif;
}

.what-if-subtitle {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
}

.what-if-section.urgent .what-if-subtitle {
    color: #FF9800;
    font-weight: 500;
}

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

/* What-If Cards */
.what-if-card {
    background: linear-gradient(145deg, rgba(47, 49, 66, 0.9) 0%, rgba(37, 39, 54, 0.9) 100%);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 14px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.what-if-card:hover {
    transform: translateY(-4px);
    border-color: rgba(76, 175, 80, 0.4);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.what-if-card.recommended {
    border-color: rgba(76, 175, 80, 0.6);
    background: linear-gradient(145deg, rgba(76, 175, 80, 0.15) 0%, rgba(37, 39, 54, 0.9) 100%);
    box-shadow: 0 0 20px rgba(76, 175, 80, 0.2);
}

.what-if-card.recommended::before {
    content: "★ BEST";
    position: absolute;
    top: 0;
    left: 0;
    background: linear-gradient(135deg, #4CAF50, #8BC34A);
    color: #000;
    font-size: 10px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 14px 0 10px 0;
    letter-spacing: 0.5px;
}

.what-if-card-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.what-if-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    background: rgba(76, 175, 80, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.what-if-icon i {
    font-size: 20px;
    color: #4CAF50;
}

.what-if-card-title {
    font-size: 15px;
    font-weight: 600;
    color: #fff;
}

.what-if-change {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.7);
    padding: 10px 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    line-height: 1.5;
}

.what-if-change strong {
    color: #FFD500;
}

.what-if-results {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.what-if-result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.what-if-result-row .result-label {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.5);
}

.what-if-result-row .result-value {
    font-size: 14px;
    font-weight: 600;
    color: #fff;
}

/* Success/Failure Badge */
.what-if-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    background: rgba(76, 175, 80, 0.15);
    color: #4CAF50;
}

.what-if-badge i {
    font-size: 16px;
}

.what-if-badge.improved {
    background: rgba(255, 193, 7, 0.15);
    color: #FFC107;
}

.what-if-badge.failed {
    background: rgba(244, 67, 54, 0.15);
    color: #F44336;
}

/* Apply Button */
.what-if-apply {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 12px;
    background: linear-gradient(135deg, #4CAF50 0%, #8BC34A 100%);
    border: none;
    border-radius: 10px;
    color: #000;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: auto;
}

.what-if-apply:hover {
    transform: scale(1.02);
    box-shadow: 0 6px 20px rgba(76, 175, 80, 0.4);
}

.what-if-apply i {
    font-size: 18px;
}

/* Responsive What-If */
@media (max-width: 992px) {
    .what-if-grid {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .what-if-card {
        padding: 18px;
    }
}

@media (max-width: 480px) {
    .what-if-section {
        padding: 18px;
        margin-top: 24px;
    }

    .what-if-header>i {
        font-size: 24px;
    }

    .what-if-title {
        font-size: 16px;
    }

    .what-if-card-title {
        font-size: 14px;
    }

    .what-if-card.recommended::before {
        font-size: 9px;
        padding: 3px 8px;
    }

    /* Mobile Chart Improvements */
    .timeline-chart {
        height: 200px;
        margin-top: 15px;
    }

    .chart-container {
        gap: 1px;
        padding: 0 5px;
    }

    .chart-bar-wrapper {
        max-width: 10px;
    }

    /* Hide all bar labels on mobile - they crowd the chart */
    .chart-bar-label {
        display: none;
    }

    /* Simplify Coast FIRE on mobile */
    .chart-bar.coast-fire::after {
        font-size: 12px;
        top: -18px;
    }

    /* Chart legend - stack on mobile */
    .chart-legend {
        flex-wrap: wrap;
        gap: 8px;
        justify-content: center;
    }

    /* Reduce chart age marker size */
    .age-marker {
        font-size: 10px;
    }
}

/* Spinner Animation */
@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

.spinning {
    animation: spin 1s linear infinite;
}