/**
 * Salary Indexation Calculator Styles
 * FGTB/ABVV - 2025
 */

/* Page Header */
.page-header {
    margin-top: 30px;
    margin-bottom: 40px;
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 2px solid #e74c3c;
}

.page-header h1 {
    color: #e74c3c;
    font-weight: bold;
    margin-bottom: 10px;
}

.page-header .lead {
    color: #666;
    font-size: 1.2em;
}

/* Calculator Form */
.calculator-form {
    max-width: 700px;
    margin: 30px auto;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.calculator-form .form-group {
    margin-bottom: 25px;
}

.calculator-form label {
    font-weight: bold;
    color: #333;
    margin-bottom: 8px;
    display: block;
}

.calculator-form .form-control {
    height: 45px;
    font-size: 16px;
    border: 2px solid #ddd;
    border-radius: 4px;
    transition: border-color 0.3s;
}

.calculator-form .form-control:focus {
    border-color: #e74c3c;
    box-shadow: 0 0 0 0.2rem rgba(231, 76, 60, 0.25);
}

.calculator-form .input-group-addon {
    background-color: #e74c3c;
    color: white;
    border: 2px solid #e74c3c;
    border-left: none;
    padding: 10px 15px;
    font-weight: bold;
    min-width: 50px;
    text-align: center;
}

.calculator-form .help-block {
    color: #6c757d;
    font-size: 14px;
    margin-top: 5px;
}

.calculator-form .alert-info {
    background-color: #e8f4f8;
    border-color: #bee5eb;
    color: #0c5460;
    margin-top: 20px;
}

.calculator-form .alert-info h4 {
    color: #0c5460;
    font-weight: bold;
    margin-bottom: 10px;
}

.calculator-form .alert-info ul {
    margin-bottom: 0;
}

.calculator-form .alert-info ul.scenario-list {
    list-style-type: none;
    padding-left: 0;
}

.calculator-form .alert-info ul.scenario-list li {
    margin-bottom: 8px;
    padding-left: 0;
}

/* Form Actions */
.form-actions {
    margin-top: 30px;
    text-align: center;
}

.form-actions .btn {
    min-width: 150px;
    margin: 0 10px;
    padding: 12px 30px;
    font-size: 16px;
    font-weight: bold;
    border-radius: 4px;
    transition: all 0.3s;
}

.form-actions .btn-primary {
    background-color: #e74c3c;
    border-color: #e74c3c;
}

.form-actions .btn-primary:hover {
    background-color: #c0392b;
    border-color: #c0392b;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.form-actions .btn-default {
    background-color: #95a5a6;
    border-color: #95a5a6;
    color: white;
}

.form-actions .btn-default:hover {
    background-color: #7f8c8d;
    border-color: #7f8c8d;
    color: white;
}

/* Result Section */
.result-section {
    max-width: 1000px;
    margin: 40px auto;
    padding: 30px;
    background: #ffffff;
    border: 2px solid #e74c3c;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(231, 76, 60, 0.2);
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-section h2 {
    color: #e74c3c;
    text-align: center;
    margin-bottom: 30px;
    font-weight: bold;
    font-size: 2em;
}

.result-section h3 {
    color: #333;
    margin-bottom: 20px;
    font-weight: bold;
    border-bottom: 2px solid #e74c3c;
    padding-bottom: 10px;
}

/* Chart Section */
.chart-section {
    margin-bottom: 40px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 6px;
}

.chart-section h3 {
    color: #333;
    margin-bottom: 20px;
    font-weight: bold;
    text-align: center;
}

#salaryChart {
    max-width: 100%;
    height: auto !important;
}

/* Two column layout */
.comparison-summary-container {
    margin-top: 30px;
}

/* Result Summary */
.result-summary {
    position: sticky;
    top: 20px;
}

.result-summary h3 {
    font-size: 1.2em;
}

/* Result Details */
.result-details {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.result-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #e9ecef;
}

.result-row:last-child {
    border-bottom: none;
}

.result-row.scenario1 {
    background-color: #d4edda;
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.result-row.scenario2 {
    background-color: #fff3cd;
    padding: 12px 15px;
    border-radius: 4px;
    margin-bottom: 8px;
}

.result-row.loss {
    background-color: #f8d7da;
    padding: 12px 15px;
    border-radius: 4px;
    margin-top: 15px;
}

.result-row.cumulative-loss {
    background-color: #dc3545;
    padding: 15px 15px;
    border-radius: 4px;
    margin-top: 10px;
}

.result-row.cumulative-loss .result-label,
.result-row.cumulative-loss .result-value {
    color: white;
    font-weight: bold;
}

.result-label {
    font-weight: 600;
    color: #495057;
    font-size: 15px;
}

.result-value {
    font-size: 18px;
    font-weight: bold;
    color: #212529;
}

.result-row.result-total {
    margin-top: 15px;
    padding-top: 20px;
    border-top: 3px solid #e74c3c;
}

.result-value.total {
    font-size: 24px;
    color: #c0392b;
}

/* Comparison Section */
.comparison-section {
    margin-top: 40px;
    margin-bottom: 30px;
}

.comparison-section table {
    margin-top: 20px;
}

.comparison-section .table {
    font-size: 14px;
}

.comparison-section .table thead {
    background-color: #e74c3c;
    color: white;
}

.comparison-section .table thead th {
    font-weight: bold;
    text-align: center;
    padding: 12px;
}

.comparison-section .table tbody td {
    text-align: center;
    padding: 10px;
}

.comparison-section .table tbody tr:nth-child(even) {
    background-color: #f8f9fa;
}

.comparison-section .table .text-danger {
    color: #c0392b !important;
}

/* Result Info */
.result-info {
    margin-top: 30px;
    padding: 15px;
    background: #fff3cd;
    border-radius: 6px;
    border-left: 4px solid #ffc107;
}

.result-info p {
    margin: 0;
    font-size: 14px;
    line-height: 1.6;
    color: #856404;
}

.result-info strong {
    color: #856404;
}

/* Responsive Design */
@media (max-width: 768px) {
    .calculator-form,
    .result-section {
        margin: 20px 15px;
        padding: 20px;
    }

    .form-actions .btn {
        display: block;
        width: 100%;
        margin: 10px 0;
    }

    .result-row {
        flex-direction: column;
        align-items: flex-start;
    }

    .result-value {
        margin-top: 5px;
    }

    .page-header h1 {
        font-size: 1.5em;
    }

    .result-section h2 {
        font-size: 1.5em;
    }

    .comparison-section .table {
        font-size: 12px;
    }

    .comparison-section .table thead th,
    .comparison-section .table tbody td {
        padding: 8px 4px;
    }
}

/* Print Styles */
@media print {
    .calculator-form,
    .form-actions {
        display: none;
    }

    .result-section {
        box-shadow: none;
        border: 1px solid #000;
    }
}
