/* Base Styles */
:root {
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --accent-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --text-color: #333;
    --text-light: #777;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #fff;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
    font-size: 2.5rem;
    color: var(--primary-color);
    position: relative;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--secondary-color);
}

.btn {
    display: inline-block;
    padding: 12px 30px;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    cursor: pointer;
}

.btn:hover {
    background-color: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Header & Navigation */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
}

header.scrolled {
    background-color: white;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.logo h1 {
    font-size: 1.8rem;
    color: var(--primary-color);
    font-weight: 700;
}

.nav-menu {
    display: flex;
    list-style: none;
}

.nav-menu li {
    margin-left: 30px;
}

.nav-menu a {
    text-decoration: none;
    color: var(--text-color);
    font-weight: 500;
    transition: var(--transition);
    position: relative;
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--secondary-color);
    transition: var(--transition);
}

.nav-menu a:hover::after,
.nav-menu a.active::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), url('bg.avif');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
    padding-top: 80px;
}

.hero-content {
    max-width: 800px;
    padding: 0 20px;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 20px;
    animation: fadeInDown 1s ease;
}

.hero-content p {
    font-size: 1.2rem;
    margin-bottom: 30px;
    animation: fadeInUp 1s ease 0.3s forwards;
    opacity: 0;
}

.hero-content .btn {
    animation: fadeInUp 1s ease 0.6s forwards;
    opacity: 0;
}

/* Services Section */
.services {
    background-color: var(--light-color);
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    text-align: center;
    transition: var(--transition);
}

.service-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.service-card i {
    font-size: 3rem;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.service-card h3 {
    margin-bottom: 15px;
    color: var(--primary-color);
}

.service-card p {
    color: var(--text-light);
}

/* Testimonials Section */
.testimonials {
    background-color: white;
}

.testimonial-slider {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
    overflow: hidden;
    height: 300px;
}

.testimonial-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.testimonial-slide.active {
    opacity: 1;
}

.testimonial-content {
    text-align: center;
    padding: 30px;
    background-color: var(--light-color);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.testimonial-content p {
    font-style: italic;
    font-size: 1.1rem;
    margin-bottom: 20px;
    color: var(--text-color);
}

.client-info h4 {
    color: var(--primary-color);
    margin-bottom: 5px;
}

.client-info p {
    font-size: 0.9rem;
    margin-bottom: 0;
}

.slider-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-top: 30px;
}

.prev-btn, .next-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
    transition: var(--transition);
}

.prev-btn:hover, .next-btn:hover {
    color: var(--secondary-color);
}

.slider-dots {
    display: flex;
    margin: 0 20px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: #ccc;
    margin: 0 5px;
    cursor: pointer;
    transition: var(--transition);
}

.dot.active {
    background-color: var(--secondary-color);
}

/* Contact Section */
.contact {
    background-color: var(--light-color);
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 50px;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.info-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.info-item i {
    font-size: 1.5rem;
    color: var(--secondary-color);
}

.contact-form {
    background-color: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--secondary-color);
    outline: none;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.form-group textarea {
    height: 150px;
    resize: vertical;
}

.submit-btn {
    width: 100%;
}

#form-status {
    margin-top: 15px;
    text-align: center;
    font-weight: 500;
}

/* Footer */
footer {
    background-color: var(--primary-color);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo h2 {
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.footer-links h3,
.footer-social h3 {
    margin-bottom: 20px;
    font-size: 1.2rem;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #ecf0f1;
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--secondary-color);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icons a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    color: white;
    transition: var(--transition);
}

.social-icons a:hover {
    background-color: var(--secondary-color);
    transform: translateY(-3px);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-logo .nmls-id {
    margin-top: 10px;
    font-size: 0.9rem;
    color: #ecf0f1;
}

.equal-housing {
    display: flex;
    align-items: center;
    margin-top: 15px;
}

.equal-housing img {
    margin-right: 10px;
    background-color: white;
    padding: 3px;
    border-radius: 4px;
}

.equal-housing span {
    font-size: 0.9rem;
    color: #ecf0f1;
}

/* Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Responsive Design */
@media (max-width: 992px) {
    .contact-wrapper {
        grid-template-columns: 1fr;
    }
    
    .hero-content h1 {
        font-size: 2.8rem;
    }
}

@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }
    
    .nav-menu {
        position: fixed;
        top: 80px;
        left: -100%;
        flex-direction: column;
        background-color: white;
        width: 100%;
        text-align: center;
        transition: 0.3s;
        box-shadow: 0 10px 10px rgba(0, 0, 0, 0.1);
        padding: 20px 0;
    }
    
    .nav-menu.active {
        left: 0;
    }
    
    .nav-menu li {
        margin: 15px 0;
    }
    
    .hero-content h1 {
        font-size: 2.2rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
}

@media (max-width: 576px) {
    .hero-content h1 {
        font-size: 1.8rem;
    }
    
    .hero-content p {
        font-size: 1rem;
    }
    
    .section-title {
        font-size: 1.8rem;
    }
    
    .testimonial-content {
        padding: 20px;
    }
    
    .contact-form {
        padding: 20px;
    }
}

/* Calculator Section */
.calculator {
    background-color: white;
}

.calculator-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
}

.calculator-form {
    background-color: var(--light-color);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.calculator-form .form-group {
    margin-bottom: 20px;
}

.calculator-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--primary-color);
}

.calculator-form input {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: var(--transition);
}

.calculator-form input:focus {
    border-color: var(--secondary-color);
    outline: none;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.calculator-form .btn {
    width: 100%;
    margin-top: 10px;
}

.calculator-results {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.result-card {
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.result-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
    text-align: center;
}

.result-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--secondary-color);
    text-align: center;
    margin-bottom: 20px;
}

.payment-breakdown, .summary-item {
    margin-top: 10px;
}

.breakdown-item, .summary-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

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

.chart-container {
    background-color: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    height: 300px;
}

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

/* Payoff Calculator Additions */
.highlight {
    font-weight: 700;
    color: var(--secondary-color);
}

.secondary-btn {
    background-color: var(--primary-color);
    margin-top: 20px;
    width: 100%;
    text-align: center;
}

.secondary-btn:hover {
    background-color: #1e2b38;
}

.amortization-schedule {
    margin-top: 20px;
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.amortization-schedule.hidden {
    display: none;
}

.table-container {
    overflow-x: auto;
    max-height: 400px;
    overflow-y: auto;
}

#amortization-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

#amortization-table th,
#amortization-table td {
    padding: 10px;
    text-align: right;
    border-bottom: 1px solid #eee;
}

#amortization-table th {
    background-color: var(--light-color);
    position: sticky;
    top: 0;
    z-index: 10;
}

#amortization-table tr:hover {
    background-color: #f9f9f9;
}

#amortization-table th:first-child,
#amortization-table td:first-child {
    text-align: center;
}

.calculator-form h3 {
    margin: 25px 0 15px;
    color: var(--primary-color);
    font-size: 1.2rem;
}

.calculator-form h3:first-child {
    margin-top: 0;
}

/* Add this to your existing CSS */
input.error {
    border-color: var(--accent-color);
    background-color: rgba(231, 76, 60, 0.05);
}

/* Make sure text inputs have the same styling as number inputs */
.calculator-form input[type="text"] {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    transition: var(--transition);
}

.calculator-form input[type="text"]:focus {
    border-color: var(--secondary-color);
    outline: none;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.error-message {
    color: var(--accent-color);
    font-size: 0.85rem;
    margin-top: 5px;
    display: none;
}

input.error + .error-message {
    display: block;
}

.calculator-form .form-group {
    position: relative;
    margin-bottom: 25px;
}

/* Cookie Consent Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: rgba(44, 62, 80, 0.95);
    color: white;
    padding: 20px;
    z-index: 9999;
    box-shadow: 0 -5px 10px rgba(0, 0, 0, 0.1);
    transform: translateY(100%);
    transition: transform 0.4s ease-in-out;
}

.cookie-banner.show {
    transform: translateY(0);
}

.cookie-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.cookie-content h3 {
    margin: 0;
    font-size: 1.3rem;
}

.cookie-content p {
    margin: 0;
    line-height: 1.5;
    font-size: 0.95rem;
}

.cookie-buttons {
    display: flex;
    gap: 15px;
}

.cookie-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.accept-btn {
    background-color: var(--secondary-color);
    color: white;
}

.accept-btn:hover {
    background-color: #2980b9;
}

.decline-btn {
    background-color: transparent;
    border: 1px solid white;
    color: white;
}

.decline-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.cookie-policy-link {
    color: var(--secondary-color);
    text-decoration: underline;
    font-size: 0.9rem;
    align-self: flex-start;
}

@media (min-width: 768px) {
    .cookie-content {
        flex-direction: row;
        align-items: center;
        flex-wrap: wrap;
    }
    
    .cookie-content h3 {
        flex: 0 0 100%;
    }
    
    .cookie-content p {
        flex: 1;
        margin-right: 20px;
    }
    
    .cookie-buttons {
        flex: 0 0 auto;
    }
    
    .cookie-policy-link {
        flex: 0 0 100%;
    }
}

/* Cookie Policy Page Styles */
.policy-section {
    padding: 100px 0 60px;
    background-color: #f9f9f9;
}

.policy-title {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 30px;
    text-align: center;
}

.policy-content {
    background-color: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.policy-content h2 {
    font-size: 1.2rem;
    color: var(--text-light);
    margin-bottom: 30px;
    text-align: center;
}

.policy-block {
    margin-bottom: 30px;
}

.policy-block h3 {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.policy-block h4 {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin: 20px 0 10px;
}

.policy-block p, .policy-block li {
    margin-bottom: 15px;
    line-height: 1.7;
}

.policy-block ul {
    padding-left: 20px;
    margin-bottom: 20px;
}

.policy-block a {
    color: var(--secondary-color);
    text-decoration: none;
    transition: var(--transition);
}

.policy-block a:hover {
    text-decoration: underline;
}

.cookie-table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
}

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

.cookie-table th {
    background-color: var(--light-color);
    font-weight: 600;
}

.cookie-table tr:hover {
    background-color: #f9f9f9;
}

@media (max-width: 768px) {
    .policy-content {
        padding: 25px;
    }
    
    .cookie-table {
        display: block;
        overflow-x: auto;
    }
}

/* Mobile responsiveness fixes for payoff calculator */
@media (max-width: 768px) {
    .calculator-wrapper {
        grid-template-columns: 1fr;
        padding: 15px;
    }
    
    .calculator-results {
        margin-top: 30px;
    }
    
    .result-card {
        padding: 15px;
    }
    
    .amortization-schedule {
        padding: 15px;
        width: 100%;
        max-width: 100%;
        overflow-x: hidden;
    }
    
    .table-container {
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    #amortization-table {
        min-width: 650px; /* Ensure table has minimum width for all columns */
    }
    
    #amortization-table th,
    #amortization-table td {
        padding: 8px 6px;
        font-size: 0.8rem;
    }
    
    .cookie-banner {
        padding: 15px;
    }
    
    .cookie-content {
        gap: 10px;
    }
    
    .cookie-buttons {
        width: 100%;
        justify-content: space-between;
    }
    
    .cookie-btn {
        padding: 8px 15px;
        font-size: 0.9rem;
    }
}

/* Fix for very small screens */
@media (max-width: 480px) {
    .calculator {
        padding: 40px 10px;
    }
    
    .container {
        padding: 0 10px;
    }
    
    .section-title {
        font-size: 1.8rem;
        margin-bottom: 20px;
    }
    
    #amortization-table {
        min-width: 600px;
    }
    
    #amortization-table th,
    #amortization-table td {
        padding: 6px 4px;
        font-size: 0.75rem;
    }
} 