/* Early Repayment Calculator Specific Styles */

/* Calculator Page Layout */
.calculator-page {
    min-height: 100vh;
    background: #ffffff;
}

.calculator-layout {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    margin-top: 32px;
}

/* Page Header Enhancement */
.page-header {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
    padding: 60px 0;
    text-align: center;
    border-radius: 0 0 24px 24px;
    margin-bottom: 40px;
}

.page-header h1 {
    font-size: 42px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 16px;
    letter-spacing: -1px;
}

.page-header .lead {
    font-size: 20px;
    color: #204080;
    margin-bottom: 32px;
    font-weight: 600;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
}

.key-features {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    margin-top: 32px;
}

.feature {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #204080;
    font-weight: 600;
}

.feature i {
    font-size: 24px;
    opacity: 0.8;
}

/* Card Design */
.card {
    background: white;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.card-header {
    background: linear-gradient(135deg, #f8f9ff 0%, #e8f2ff 100%);
    padding: 32px;
    text-align: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.card-header h2 {
    font-size: 28px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 12px;
}

.card-header p {
    color: #666;
    font-size: 16px;
    margin: 0;
}

/* Form Sections */
.calculator-form-inner {
    padding: 40px;
}

.form-section {
    margin-bottom: 40px;
    padding-bottom: 32px;
    border-bottom: 1px solid #f0f0f0;
}

.form-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.form-section h3 {
    font-size: 20px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.form-section h3 i {
    font-size: 18px;
    opacity: 0.8;
}

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

.input-label {
    display: block;
    font-weight: 600;
    color: #204080;
    margin-bottom: 8px;
    font-size: 14px;
}

.input-label.required::after {
    content: " *";
    color: #e74c3c;
}

.input-field {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.2s ease;
    background: white;
    font-family: inherit;
}

.input-field:focus {
    outline: none;
    border-color: #204080;
    box-shadow: 0 0 0 3px rgba(32, 64, 128, 0.1);
}

.input-field:invalid {
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.input-field:valid {
    border-color: #27ae60;
}

/* Input with Symbol */
.input-with-symbol {
    position: relative;
}

.currency-symbol,
.percentage-symbol,
.unit-symbol {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    font-weight: 600;
    font-size: 14px;
    pointer-events: none;
}

.currency-symbol {
    left: 20px;
}

.percentage-symbol,
.unit-symbol {
    right: 20px;
}

.input-with-symbol .input-field:has(~ .currency-symbol) {
    padding-left: 45px;
}

.input-with-symbol .input-field:has(~ .percentage-symbol),
.input-with-symbol .input-field:has(~ .unit-symbol) {
    padding-right: 60px;
}

.help-text {
    font-size: 13px;
    color: #666;
    margin-top: 6px;
    line-height: 1.4;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 16px;
    margin-top: 40px;
    padding-top: 32px;
    border-top: 1px solid #f0f0f0;
}

.calculate-button,
.reset-button {
    flex: 1;
    padding: 18px 32px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.calculate-button {
    background: linear-gradient(135deg, #204080 0%, #3366cc 100%);
    color: white;
}

.calculate-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(32, 64, 128, 0.25);
}

.reset-button {
    background: linear-gradient(135deg, #666 0%, #888 100%);
    color: white;
}

.reset-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 102, 102, 0.25);
}

/* Results Section */
.calculator-results {
    margin-top: 40px;
}

.results-content {
    padding: 40px;
}

.erc-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.erc-item {
    background: #f8f9ff;
    border-radius: 16px;
    padding: 24px;
    text-align: center;
    border: 2px solid #e5e5e5;
    transition: all 0.2s ease;
}

.erc-item.primary {
    background: linear-gradient(135deg, #204080 0%, #3366cc 100%);
    color: white;
    border-color: #204080;
}

.erc-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.erc-label {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    opacity: 0.8;
}

.erc-item.primary .erc-label {
    opacity: 0.9;
}

.erc-value {
    font-size: 32px;
    font-weight: 700;
    margin: 0;
}

/* Scenario Comparison Table */
.scenario-comparison {
    margin-bottom: 40px;
}

.scenario-comparison h3 {
    font-size: 24px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 24px;
}

.scenario-comparison table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
}

.scenario-comparison th,
.scenario-comparison td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid #f0f0f0;
}

.scenario-comparison th {
    background: #f8f9ff;
    font-weight: 700;
    color: #204080;
    font-size: 14px;
}

.scenario-comparison tr:hover {
    background: #f8f9ff;
}

.scenario-comparison .total-row {
    background: #f0f8ff;
    font-weight: 700;
}

.scenario-comparison .total-row:hover {
    background: #e8f2ff;
}

/* Breakeven Analysis */
.breakeven-analysis {
    background: #f8f9ff;
    border-radius: 16px;
    padding: 32px;
    margin-bottom: 40px;
}

.breakeven-analysis h3 {
    font-size: 20px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 24px;
}

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

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

.breakdown-item .label {
    font-weight: 600;
    color: #333;
}

.breakdown-item .value {
    font-weight: 700;
    color: #204080;
}

/* Recommendation Section */
.recommendation {
    margin-bottom: 40px;
}

.recommendation h3 {
    font-size: 20px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 20px;
}

.recommendation-positive {
    background: linear-gradient(135deg, #27ae60 0%, #2ecc71 100%);
    color: white;
    padding: 24px;
    border-radius: 16px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.recommendation-neutral {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
    color: white;
    padding: 24px;
    border-radius: 16px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.recommendation-negative {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
    color: white;
    padding: 24px;
    border-radius: 16px;
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.recommendation i {
    font-size: 24px;
    margin-top: 4px;
    opacity: 0.9;
}

.recommendation p {
    margin: 0;
    line-height: 1.6;
}

.recommendation strong {
    font-weight: 700;
}

/* Next Steps */
.next-steps h3 {
    font-size: 20px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 20px;
}

.action-buttons {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px;
}

.action-button {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: #f8f9ff;
    border: 2px solid #e5e5e5;
    border-radius: 12px;
    text-decoration: none;
    color: #333;
    font-weight: 600;
    transition: all 0.2s ease;
}

.action-button:hover {
    border-color: #204080;
    background: white;
    color: #204080;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.action-button i {
    color: #204080;
    font-size: 18px;
}

/* Info Section */
.info-section {
    margin-top: 60px;
}

.row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 32px;
}

.info-card {
    background: white;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.info-card h3 {
    font-size: 20px;
    font-weight: 700;
    color: #204080;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.info-card h4 {
    font-size: 16px;
    font-weight: 700;
    color: #204080;
    margin: 20px 0 12px 0;
}

.info-card ul {
    list-style: none;
    padding: 0;
}

.info-card li {
    padding: 8px 0;
    color: #666;
    position: relative;
    padding-left: 20px;
}

.info-card li:before {
    content: "•";
    color: #204080;
    font-weight: bold;
    position: absolute;
    left: 0;
}

/* Responsive Design */
@media (max-width: 768px) {
    .key-features {
        gap: 20px;
    }
    
    .feature {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }
    
    .calculator-form-inner {
        padding: 24px;
    }
    
    .results-content {
        padding: 24px;
    }
    
    .erc-summary {
        grid-template-columns: 1fr;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .action-buttons {
        grid-template-columns: 1fr;
    }
    
    .row {
        grid-template-columns: 1fr;
    }
    
    .page-header h1 {
        font-size: 32px;
    }
    
    .breakdown-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .scenario-comparison {
        overflow-x: auto;
    }
    
    .scenario-comparison table {
        min-width: 600px;
    }
}

/* FAQ Section Styles */
.faq-section {
    background: #f8f9ff;
    padding: 60px 0;
    margin-top: 40px;
}

.faq-section h2 {
    font-size: 36px;
    font-weight: 700;
    color: #1a1a1a;
    text-align: center;
    margin-bottom: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
}

.faq-section h2 i {
    color: #204080;
    font-size: 32px;
}

.faq-container {
    max-width: 900px;
    margin: 0 auto;
}

.faq-item {
    background: white;
    border-radius: 16px;
    margin-bottom: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    border: 1px solid rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.faq-question {
    padding: 28px 32px;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: white;
    border-bottom: 1px solid transparent;
    transition: all 0.2s ease;
}

.faq-question:hover {
    background: #f8f9ff;
}

.faq-question h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1a1a1a;
    line-height: 1.4;
    flex: 1;
    padding-right: 20px;
}

.faq-question i {
    color: #204080;
    font-size: 16px;
    transition: transform 0.3s ease;
    min-width: 16px;
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 32px 32px;
    display: none;
    animation: fadeIn 0.3s ease;
}

.faq-item.active .faq-answer {
    display: block;
}

.faq-answer p {
    color: #444;
    line-height: 1.6;
    margin-bottom: 16px;
    font-size: 16px;
}

.faq-answer ul {
    color: #444;
    line-height: 1.6;
    margin: 16px 0;
    padding-left: 20px;
}

.faq-answer li {
    margin-bottom: 8px;
    font-size: 16px;
}

.faq-answer strong {
    color: #204080;
    font-weight: 600;
}

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

/* Color Contrast Fixes - Ensure proper header/footer styling */
.main-header {
    background: #183153 !important;
}

.main-header .header-container .logo h1 a {
    color: #fff !important;
    font-weight: 700;
}

.main-header .header-container .logo p {
    color: #b8c7d9 !important;
    font-weight: 500;
}

.main-header .main-nav a,
.main-header .main-nav ul li a {
    color: #fff !important;
    font-weight: 600;
}

.main-header .main-nav a:hover,
.main-header .main-nav ul li a:hover {
    background: #25416a !important;
    color: #ffd700 !important;
}

/* Footer - Homepage Style (Critical Override) */
.main-footer {
    background: #1a1a1a !important;
    color: white !important;
    padding: 50px 0 25px !important;
}

.footer-content {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 0 24px !important;
    display: grid !important;
    grid-template-columns: 2fr 1fr 1fr !important;
    gap: 40px !important;
}

.footer-section h3 {
    color: #204080 !important;
    font-size: 20px !important;
    font-weight: 700 !important;
    margin-bottom: 20px !important;
}

.footer-section p {
    color: #ccc !important;
    font-size: 16px !important;
    line-height: 1.6 !important;
    margin-bottom: 0 !important;
}

.footer-section ul {
    list-style: none !important;
    padding: 0 !important;
}

.footer-section li {
    margin-bottom: 12px !important;
}

.footer-section a {
    color: #ccc !important;
    text-decoration: none !important;
    font-size: 16px !important;
    transition: color 0.2s ease !important;
}

.footer-section a:hover {
    color: #204080 !important;
}

.footer-bottom {
    border-top: 1px solid #333 !important;
    margin-top: 40px !important;
    padding-top: 20px !important;
    text-align: center !important;
}

.footer-bottom p {
    color: #999 !important;
    font-size: 14px !important;
    margin: 0 !important;
}

/* Mobile responsive footer */
@media (max-width: 768px) {
    .footer-content {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }
}

@media (max-width: 768px) {
    .faq-section {
        padding: 40px 0;
    }
    
    .faq-section h2 {
        font-size: 28px;
        flex-direction: column;
        gap: 12px;
    }
    
    .faq-question {
        padding: 20px 24px;
    }
    
    .faq-question h3 {
        font-size: 16px;
        padding-right: 16px;
    }
    
    .faq-answer {
        padding: 0 24px 24px;
    }
    
    .faq-answer p,
    .faq-answer li {
        font-size: 15px;
    }
}

@media (max-width: 480px) {
    .page-header {
        padding: 40px 0;
    }
    
    .page-header h1 {
        font-size: 28px;
    }
    
    .page-header .lead {
        font-size: 18px;
    }
    
    .info-card {
        padding: 20px;
    }
    
    .erc-value {
        font-size: 24px;
    }
    
    .faq-question {
        padding: 16px 20px;
    }
    
    .faq-question h3 {
        font-size: 15px;
    }
    
    .faq-answer {
        padding: 0 20px 20px;
    }
} 