.retirement-calculator {
    max-width: 800px;
    margin: 0 auto;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
}

.calculator-section {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.calculator-section h2 {
    color: #2c3e50;
    font-size: 24px;
    font-weight: 600;
    margin: 0 0 15px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #3498db;
}

.calculator-section .description {
    color: #666;
    font-size: 14px;
    margin-bottom: 25px;
    line-height: 1.5;
}

.form-group {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.form-group label {
    font-weight: 500;
    color: #2c3e50;
    min-width: 200px;
    margin-right: 10px;
}

.form-group input[type="number"],
.form-group input[type="text"],
.form-group select {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 8px 12px;
    font-size: 14px;
    min-width: 120px;
    background: #fff;
    transition: border-color 0.3s ease;
}

.form-group input[type="number"]:focus,
.form-group input[type="text"]:focus,
.form-group select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.form-group .unit {
    color: #666;
    font-size: 13px;
    margin-left: 5px;
}

.form-group .description {
    color: #888;
    font-size: 12px;
    font-style: italic;
    margin-left: 10px;
}

.help-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    background: #3498db;
    color: white;
    border-radius: 50%;
    text-align: center;
    line-height: 16px;
    font-size: 10px;
    font-weight: bold;
    cursor: help;
    margin-left: 5px;
}

.subsection {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 20px;
    margin: 20px 0;
}

.subsection h3 {
    color: #2c3e50;
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid #dee2e6;
}

.button-group {
    display: flex;
    gap: 15px;
    margin: 25px 0;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.btn-calculate {
    background: #27ae60;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.btn-calculate:hover {
    background: #229954;
}

.btn-clear {
    background: #95a5a6;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-clear:hover {
    background: #7f8c8d;
}

.results {
    background: #e8f5e8;
    border: 1px solid #c3e6c3;
    border-radius: 6px;
    padding: 20px;
    margin-top: 20px;
}

.results h3 {
    color: #27ae60;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 15px 0;
}

.result-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #d4edda;
}

.result-item:last-child {
    border-bottom: none;
}

.result-item .label {
    font-weight: 500;
    color: #2c3e50;
}

.result-item .value {
    font-weight: 600;
    color: #27ae60;
    font-size: 16px;
}

/* Currency input formatting - REMOVED ALL RESTRICTIONS */
.currency-input {
    /* No restrictions - users can type anything */
}

/* Responsive design */
@media (max-width: 768px) {
    .calculator-section {
        padding: 20px;
        margin-bottom: 20px;
    }
    
    .form-group {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .form-group label {
        min-width: auto;
        margin-bottom: 5px;
    }
    
    .form-group input[type="number"],
    .form-group input[type="text"],
    .form-group select {
        width: 100%;
        min-width: auto;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .result-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
}

/* Loading state */
.calculating {
    opacity: 0.6;
    pointer-events: none;
}

.calculating .btn-calculate {
    background: #95a5a6;
}

/* Error states */
.form-group.error input {
    border-color: #e74c3c;
    box-shadow: 0 0 0 2px rgba(231, 76, 60, 0.2);
}

.error-message {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 5px;
}

/* Input error messages */
.inputErrMsg {
    color: #e74c3c;
    font-size: 12px;
    margin-top: 5px;
    font-weight: 500;
    visibility: hidden;
}

.form-group.error .inputErrMsg {
    visibility: visible;
}

/* Enhanced input styling */
.form-group input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.form-group.error input:focus {
    border-color: #e74c3c;
    box-shadow: 0 0 0 2px rgba(231, 76, 60, 0.2);
}

/* Success message */
.success-message {
    background: #d4edda;
    color: #155724;
    padding: 12px 16px;
    border: 1px solid #c3e6cb;
    border-radius: 6px;
    margin-bottom: 20px;
    font-weight: 500;
    animation: slideDown 0.3s ease-out;
}

/* Tooltip */
.tooltip {
    position: absolute;
    background: #333;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 1000;
    max-width: 250px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    pointer-events: none;
}

/* Save result section */
.save-result {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #d4edda;
    text-align: center;
}

.btn-save {
    background: #17a2b8;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.btn-save:hover {
    background: #138496;
}

/* Enhanced results styling for how_much_need calculator */
.result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #27ae60;
    color: white;
    padding: 12px 16px;
    border-radius: 6px 6px 0 0;
    margin: -20px -20px 20px -20px;
}

.result-title {
    font-weight: 600;
    font-size: 16px;
}

.result-save-icon {
    cursor: pointer;
    font-size: 14px;
}

.result-main {
    margin-bottom: 25px;
}

.result-statement {
    font-size: 18px;
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 10px;
}

.result-comparison {
    font-size: 14px;
    color: #666;
    line-height: 1.5;
}

/* Bar chart */
.bar-chart {
    margin: 25px 0;
}

.bar-item {
    margin-bottom: 15px;
}

.bar-label {
    font-weight: 500;
    color: #2c3e50;
    margin-bottom: 8px;
}

.bar-container {
    position: relative;
    background: #f8f9fa;
    border-radius: 4px;
    height: 30px;
    overflow: hidden;
}

.bar-fill {
    height: 100%;
    border-radius: 4px;
    transition: width 0.3s ease;
}

.bar-fill.current-plan {
    background: #f39c12;
}

.bar-fill.target-plan {
    background: #3498db;
}

.bar-text {
    position: absolute;
    top: 50%;
    left: 10px;
    transform: translateY(-50%);
    color: #2c3e50;
    font-weight: 500;
    font-size: 12px;
}

/* Income summaries */
.income-summaries {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin: 25px 0;
}

.income-box {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 15px;
}

.income-title {
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 14px;
}

.income-detail {
    color: #666;
    font-size: 13px;
    margin-bottom: 5px;
}

/* Savings guidance */
.savings-guidance {
    background: #e8f5e8;
    border: 1px solid #c3e6c3;
    border-radius: 6px;
    padding: 15px;
    margin: 25px 0;
}

.guidance-title {
    font-weight: 600;
    color: #27ae60;
    margin-bottom: 8px;
    font-size: 14px;
}

.guidance-text {
    color: #2c3e50;
    font-size: 13px;
    line-height: 1.5;
}

/* Success animation */
.results.show {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive design for income summaries */
@media (max-width: 768px) {
    .income-summaries {
        grid-template-columns: 1fr;
    }
}

/* Withdrawal schedule table */
.withdrawal-schedule {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #d4edda;
}

.withdrawal-schedule h4 {
    color: #27ae60;
    font-size: 16px;
    font-weight: 600;
    margin: 0 0 15px 0;
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.schedule-table th,
.schedule-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #eee;
}

.schedule-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #2c3e50;
}

.schedule-table td {
    color: #333;
}

.schedule-table tr:last-child td {
    border-bottom: none;
}

.schedule-table tr:hover {
    background: #f8f9fa;
}

/* New results format styles */
.savings-plans {
    margin-top: 20px;
}

.savings-plan {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 15px;
}

.plan-title {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #dee2e6;
}

.plan-details {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.plan-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 0;
}

.plan-item .label {
    font-weight: 500;
    color: #2c3e50;
    font-size: 13px;
}

.plan-item .value {
    font-weight: 600;
    color: #27ae60;
    font-size: 14px;
}

.result-section {
    margin-bottom: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
    border: 1px solid #e9ecef;
}

.section-title {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
    margin-bottom: 10px;
    padding-bottom: 5px;
    border-bottom: 1px solid #dee2e6;
}

.section-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 0;
}

.section-item .label {
    font-weight: 500;
    color: #2c3e50;
    font-size: 13px;
}

.section-item .value {
    font-weight: 600;
    color: #27ae60;
    font-size: 14px;
} 