/* ==========================================================================
   1. THEME CONFIGURATION (EDIT ME!)
   ========================================================================== */
:root {
    /* ---------------- COLORS ---------------- */
    /* Main Brand Color (Deep Coffee)- Headings, Footer, Borders */
    /* Sampled from the "OLD OAK" text in the image */
    --primary-color: #3e2b22;

    /* Accent/Action Color (Forest/Moss Green) */
    /* A natural green that pairs beautifully with the dark brown and cream */
    --accent-color: #5d6e38;

    /* Hover Color (Darker Green) */
    --accent-hover: #455229;

    /* Backgrounds */
    --bg-white: #fdfbf5;    /* Main Background  */
    --bg-light: #fdfbf5;    /* Secondary Background  */

    /* Text Colors */
    --text-dark: #2a1f1d;   /* Very dark brown for body text */
    --text-light: #5c504a;  /* Muted warm brown */
    --text-white: #ffffff;  /* Text on dark backgrounds */

    /* Status Colors */
    --success-color: #5d6e38; /* Using the brand green */
    --error-color: #a63737;   /* Brick Red */
    --border-color: #d6d0c5;  /* Warm beige lines */

    /* ---------------- TYPOGRAPHY ---------------- */
    --font-heading: 'Playfair Display', serif; 
    --font-body: 'Inter', sans-serif;          
    --font-size-base: 16px;
    --line-height-base: 1.6;

    /* ---------------- LAYOUT & SPACING ---------------- */
    --container-width: 1200px;
    --container-padding: 1.5rem;
    --section-spacing: 4rem;
    --border-radius: 4px; /* Slightly sharper corners to match the square logo */

    /* ---------------- SHADOWS ---------------- */
    --shadow-soft: 0 25px 50px -12px rgba(42, 31, 27, 0.25), 0 2px 4px -1px rgba(62, 43, 34, 0.04);
    --shadow-hover: 0 10px 15px -3px rgba(62, 43, 34, 0.12), 0 4px 6px -2px rgba(62, 43, 34, 0.06);
    --shadow-deep: 0 25px 50px -12px rgba(62, 43, 34, 0.25);
    
    --transition-fast: 0.3s ease;

    --financing-color: #8b3a3a;
    --financing-glow: rgba(139, 58, 58, 0.4);
}

/* =========================================
   2. RESET & BASE STYLES
   ========================================= */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: var(--font-size-base);
    /* This allows the page to grow as long as it needs to be */
    min-height: 100%;
    
    /* TRICK: Set HTML background to footer color. 
       If any gap appears at the bottom, it will just look like the footer extending. */
    background-color: var(--primary-color);
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    
    /* Ensure the white background covers the content area */
    background-color: var(--bg-white);
    
    line-height: var(--line-height-base);
    
    /* STICKY FOOTER MAGIC */
    display: flex;
    flex-direction: column;
    min-height: 100vh; 
    margin: 0;
    position: relative; /* Helps with stacking contexts */
}

main {
    flex: 1; /* Pushes footer to bottom */
    width: 100%;
    background-color: var(--bg-white); /* Ensures main content stays white */
}

h1, h2, h3, h4 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition-fast);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul { list-style: none; }

/* =========================================
   3. UTILITIES & ICONS
   ========================================= */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--container-padding);
}

.section { padding: var(--section-spacing) 0; }
.bg-light { background-color: var(--bg-light); }
.text-center { text-align: center; }

/* Icons */
.icon-inline {
    width: 24px;
    height: 24px;
    vertical-align: middle;
    margin-right: 10px;
    display: inline-block;
}

.logo-img {
    height: 85px;
    width: auto;
    border-radius: 0px; 
    display: block;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background-color: var(--accent-color);
    color: var(--text-white);
    border-radius: var(--border-radius);
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: var(--transition-fast);
}

.btn:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-soft);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--accent-color);
    color: var(--accent-color);
}

.btn-outline:hover {
    background-color: var(--accent-color);
    color: var(--text-white);
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform;
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* =========================================
   4. NAVIGATION
   ========================================= */
header {
    background-color: var(--bg-white);
    box-shadow: var(--shadow-soft);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    height: 100px;
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    width: 100%; 
    padding: 0 2rem;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: var(--font-heading);
    font-size: 1.25rem;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    justify-self: start;
}

.nav-links {
    display: flex;
    gap: 2rem;
    justify-self: center;
}

.nav-links a { font-size: 0.95rem; font-weight: 500; }
.nav-links a:hover { color: var(--accent-color); }

.hamburger {
    display: none;
    cursor: pointer;
    font-size: 1.5rem;
    background: none;
    border: none;
    color: var(--primary-color);
    justify-self: end;
}

@media (max-width: 900px) {
    .nav-container {
        display: flex;
        justify-content: space-between;
    }
    .nav-links {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: var(--bg-white);
        padding: 1.5rem;
        box-shadow: var(--shadow-soft);
        text-align: center;
    }
    .nav-links.active { display: flex; }
    .hamburger { display: block; }
}

/* =========================================
   5. HOME PAGE SECTIONS
   ========================================= */
.hero {
    background: linear-gradient(rgba(60, 70, 80, 0.7), rgba(60, 70, 80, 0.7)), url('../assets/images/hero_old-oak-renovations-4th-remodel.webp');
    background-size: cover;
    background-position: center 60%;
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: var(--text-white);
}
@media (max-width: 768px) {
    .hero {
        background: 
            linear-gradient(rgba(60, 70, 80, 0.7), rgba(60, 70, 80, 0.7)),
            url('../assets/images/hero_old-oak-renovations-4th-remodel.webp');
            background-position: center 60%;
            height: 60vh;
    }
}
.hero h1 { color: var(--text-white); font-size: 3rem; margin-bottom: 1rem; }
.hero p { font-size: 1.25rem; margin-bottom: 2rem; max-width: 600px; margin-inline: auto; }
/* Improve hero text readability without making text bigger */
.hero .container {
        background: linear-gradient(
        rgba(0, 0, 0, 0.25),
        rgba(0, 0, 0, 0.15)
    );
    padding: 2rem 2.5rem;
    border-radius: 8px;
    display: inline-block;
    backdrop-filter: blur(2px);
} 

.hero h1,
.hero p {
    text-shadow: 
        0 2px 6px rgba(0, 0, 0, 0.55),
        0 0 2px rgba(0, 0, 0, 0.35);
}

/* =========================================
   MEET THE TEAM SECTION
   ========================================= */
.team-section {
    background-color: var(--bg-light);
}

.team-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    margin-top: 2rem;
}

.team-photo img {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--accent-color);
}

.team-text h3 {
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--primary-color);
}

.team-text p {
    font-size: 1.1rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

/* Mobile Stack */
@media (max-width: 768px) {
    .team-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
    
    .team-photo {
        order: 1; /* Photo first on mobile */
    }
    
    .team-text {
        order: 2;
        text-align: center;
    }
}

/* Team Caption Styling */
.team-photo figure {
    margin: 0;
    width: 100%;
}

.team-captions {
    display: flex;
    justify-content: space-around; /* Spreads them out evenly */
    align-items: flex-start;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color); /* Nice separator line */
    gap: 1rem;
}

.team-member {
    flex: 1;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.team-member strong {
    color: var(--primary-color);
    font-size: 1.1rem;
    line-height: 1.2;
}

.team-member .role {
    font-size: 0.9rem;
    color: var(--text-dark);
    font-weight: 500;
}

.team-member .tag {
    font-size: 0.8rem;
    color: var(--text-light);
    font-style: italic;
    opacity: 0.8;
}

/* Mobile Adjustment: Keep them side-by-side but shrink text slightly if needed */
@media (max-width: 480px) {
    .team-member strong { font-size: 1rem; }
    .team-member .role { font-size: 0.8rem; }
}

/* Services Grid */
.services-grid {
    display: flex;           
    flex-wrap: wrap;         
    justify-content: center; 
    gap: 2rem;
    margin-top: 2rem;
}

.service-card {
    flex: 1 1 300px;   
    max-width: 400px;  
    width: 100%;    
    
    /* EXISTING STYLES (Keep these) */
    background: var(--bg-white);
    padding: 2.5rem 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    transition: var(--transition-fast);
    
    border-top: 5px solid var(--accent-color);
    border-bottom: 1px solid var(--border-color);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
    border-bottom: 1px solid var(--accent-color); /* Bottom turns green on hover */
}

.service-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.service-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
    margin: 0; 
}

.service-card:hover .service-icon {
    transform: scale(1.1);
    opacity: 0.7;
}

.service-header h3 {
    margin-bottom: 0;
}

/* Specific styling for buttons inside Service Cards */
.service-card .btn {
    width: 100%;           
    text-align: center;   
    margin-top: 1.5rem;    
    padding: 0.6rem;      
    font-size: 0.9rem;    
}

/* =========================================
   TESTIMONIALS (NEW CAROUSEL STYLE)
   ========================================= */
.testimonial-section {
    background-color: var(--bg-light);
    overflow: hidden; /* Hides the scrollbar */
    padding: 6rem 0;
}

/* The window we see the cards through */
.testimonial-wrapper {
    width: 100%;
    overflow: hidden;
    position: relative;
}

/* Fade effect on left and right edges */
.testimonial-wrapper::before,
.testimonial-wrapper::after {
    content: "";
    position: absolute;
    top: 0;
    width: 100px;
    height: 100%;
    z-index: 2;
}

.testimonial-wrapper::before {
    left: 0;
    background: linear-gradient(to right, var(--bg-light), transparent);
}

.testimonial-wrapper::after {
    right: 0;
    background: linear-gradient(to left, var(--bg-light), transparent);
}

/* The long track moving sideways */
.testimonial-track {
    display: flex;
    gap: 2rem;
    
    /* 10 Originals + 10 Clones = 20 Total Cards */
    width: calc((400px + 2rem) * 20); 
    animation: scroll 60s linear infinite; 
}

/* Pause on hover ONLY for devices with a mouse */
@media (hover: hover) {
    .testimonial-track:hover {
        animation-play-state: paused;
    }
}

@keyframes scroll {
    0% { transform: translateX(0); }
    /* Formula: Negative (400px card + 2rem gap) * 10 originals */
    100% { transform: translateX(calc(-1 * (400px + 2rem) * 10)); } 
}

/* The Individual Card Styling */
.testimonial-card {
    width: 400px; /* Fixed width for carousel stability */
    flex-shrink: 0;
    background: var(--bg-white);
    padding: 2rem;
    border-radius: var(--border-radius);
    
    /* REQUIREMENT 2: Outline + Shadow */
    border: 1px solid var(--accent-color);
    box-shadow: var(--shadow-soft);
    
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.star-rating {
    color: var(--accent-color);
    font-size: 1.5rem;
    margin-bottom: 1rem;
    letter-spacing: 5px;
}

.testimonial-text {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    line-height: 1.5;
    font-style: italic;
    color: var(--text-dark);
    margin-bottom: 1.5rem;
}

.testimonial-author {
    font-family: var(--font-body);
    font-weight: 700;
    color: var(--primary-color);
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Mobile Adjustment */
@media (max-width: 768px) {
    .testimonial-card { width: 300px; }
    
    /* Update Mobile Track Width for 20 cards */
    .testimonial-track { 
        width: calc((300px + 2rem) * 20); 
    }
    
    /* Update Mobile Animation for 10 originals */
    @keyframes scroll {
        100% { transform: translateX(calc(-1 * (300px + 2rem) * 10)); }
    }
}

/* Custom Map Container to Hide Header in service area map */
.map-wrapper {
    position: relative;
    width: 100%;
    max-width: 1200px;  
    height: 600px;      
    margin: 2rem auto 0 auto;
    border-radius: 8px; 
    box-shadow: var(--shadow-soft);
    overflow: hidden;   /* CRITICAL: This chops off the parts sticking out */
}

.map-wrapper iframe {
    width: 100%;
    height: 665px;      /* 65px taller than the wrapper */
    margin-top: -65px;  /* Pulls the map UP to hide the black bar leaving just a slim black line for contrast from background of site */
    border: 0;
    display: block;
}

/* Mobile Adjustments - Keep it readable on phones */
@media (max-width: 768px) {
    .map-wrapper {
        height: 350px; /* Shorter for phones */
    }
    .map-wrapper iframe {
        height: 410px; /* Still needs to be +60px taller */
    }
}

/* Contact Page Sidebar Map (Shorter Rectangle) */
.map-sidebar-wrapper {
    position: relative;
    width: 100%;
    height: 300px;      /* Reduced from 350px to 300px */
    margin-top: 2rem;
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
    overflow: hidden;   
}

.map-sidebar-wrapper iframe {
    width: 100%;
    height: 365px;      /* 300px wrapper + 65px offset */
    margin-top: -65px;  /* Same crop style */
    border: 0;
    display: block;
}

/* =========================================
   MINI GALLERY (Featured Projects)
   ========================================= */
.mini-gallery {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 2rem;
    margin-top: 2rem;
}

.project-card {
    flex: 1 1 300px; /* Grow to fill space, but ideally 300px wide */
    max-width: 400px; /* Don't get huge on wide screens */
    display: flex;
    flex-direction: column;
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.project-card:hover {
    transform: translateY(-5px);
}

.project-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: var(--border-radius);
    margin-bottom: 1rem;
    border-bottom: 1px solid var(--accent-color);
}

.project-card h3 {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--primary-color);
    margin: 0;
    transition: color 0.3s;
}

.project-card:hover h3 {
    color: var(--accent-color);
}

/* =========================================
   6. GALLERY PAGE (CARDS & MODAL)
   ========================================= */
.gallery-overview {
    display: flex; /* Changed from Grid to Flex */
    flex-wrap: wrap; /* Allows cards to wrap to the next line */
    justify-content: center; /* Centers the cards in the middle of the screen */
    gap: 2rem;
    padding-bottom: 4rem;
}

.gallery-card {
    background: var(--bg-white);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border: 1px solid var(--accent-color);
    
    /* Fixed width prevents the "oblong" stretching */
    width: 350px; 
    flex-shrink: 0;
}

.gallery-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.gallery-card-img {
    width: 100%;
    height: 250px; /* Increased height slightly to fit portrait photos better */
    object-fit: cover; 
    background-color: var(--bg-light);     
    display: block;
    transition: transform 0.5s ease;
    border-bottom: 1px solid var(--accent-color);
}

.gallery-card:hover .gallery-card-img {
    transform: scale(1.05);
}

.gallery-card-title {
    padding: 1.5rem;
    text-align: center;
    background: var(--bg-white);
    position: relative;
    z-index: 2;
}

.gallery-card-title h3 {
    margin: 0;
    font-size: 1.5rem;
    color: var(--primary-color);
}

.gallery-card-title p {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-top: 0.5rem;
}

/* =========================================
   PERFORMANCE OPTIMIZED MODAL (Dark Theme)
   ========================================= */
.gallery-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    /* UPDATED: Dark, shadowy background */
    background-color: rgba(0, 0, 0, 0.95); 
    
    z-index: 3000;
    
    /* Animation State */
    opacity: 0;
    visibility: hidden; 
    transition: opacity 0.2s ease-out, visibility 0.2s;
    
    /* Performance */
    overflow-y: auto;
    -webkit-overflow-scrolling: touch; 
}

.gallery-modal.open {
    opacity: 1;
    visibility: visible;
}

/* UPDATED: Close Button must be white */
.modal-close-btn {
    position: fixed;
    top: 20px;
    right: 30px;
    color: #ffffff; 
    font-size: 3rem;
    cursor: pointer;
    z-index: 3001;
    line-height: 1;
    transition: transform 0.2s;
}
.modal-close-btn:hover { transform: scale(1.1); color: var(--accent-color); }

.modal-content {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 1rem;
    content-visibility: auto; 
}

.modal-title {
    text-align: center;
    color: #ffffff; 
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: 2rem;
}

.modal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 1rem;
    transform: translateZ(0); 
}

.modal-grid img {
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
    
    /* UPDATED: Dark placeholder while loading */
    background-color: #222; 
    
    opacity: 0;
    transition: opacity 0.3s ease;
    will-change: opacity;
}

.modal-grid img.loaded {
    opacity: 1;
}

/* Remove the old @keyframes fadeIn block, it causes issues */


#gallery-source-data { display: none; }

/* =========================================
   7. CONTACT PAGE (ENHANCED FORM)
   ========================================= */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start; /* Aligns form to top */
}

.contact-info-item {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    gap: 1rem;
}

/* The Enhanced Contact Form Box */
.contact-form {
    background: var(--bg-white);
    padding: 2.5rem; /* Default Desktop Padding */
    border-radius: var(--border-radius);
    
    /* NEW: Deep Shadow */
    box-shadow: var(--shadow-deep);
    
    /* NEW: Top Accent Border for 'pop' */
    border-top: 5px solid var(--accent-color);
}

.form-group { margin-bottom: 1.5rem; }
.form-group label { display: block; margin-bottom: 0.5rem; font-weight: 500; }

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-family: inherit;
    transition: border-color 0.3s;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--accent-color);
}

/* --- MOBILE RESPONSIVENESS FIX --- */
@media (max-width: 768px) {
    .contact-wrapper { 
        grid-template-columns: 1fr; /* Stack vertically */
        gap: 3rem; 
    }

    .contact-form {
        padding: 1.5rem; /* Reduce padding so input fields aren't squished */
    }
}

@media (max-width: 480px) {
    /* Rules for very small phones */
    .container {
        padding: 0 1rem; /* Give more width to content */
    }

    .contact-form {
        padding: 1.25rem; /* Minimal padding to maximize input width */
    }
    
    .hero h1 {
        font-size: 2.2rem; /* Ensure hero text doesn't break layout */
    }
}
/* =========================================
   8. FOOTER
   ========================================= */
footer {
    background-color: var(--primary-color);
    color: var(--text-white);
    padding: 1.5rem 0 1rem 0; 
    margin-top: auto;
    font-size: 0.85rem;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 1rem;
    margin-bottom: 1rem;
}

.footer-address h3 {
    color: var(--text-white);
    font-size: 1rem;
    margin-bottom: 0.2rem;
}

.footer-address p { color: #ccc; margin: 0; }

.footer-nav { display: flex; gap: 1.2rem; }
.footer-nav a { color: #ccc; }
.footer-nav a:hover { color: var(--accent-color); text-decoration: underline; }

.copyright {
    text-align: center;
    color: rgba(255,255,255,0.8);
    font-size: 0.75rem;
}

@media (max-width: 768px) {
    .footer-content { flex-direction: column; text-align: center; }
}

/* =========================================
   LIGHTBOX (FULL SCREEN IMAGE VIEWER)
   ========================================= */
.lightbox-modal {
    position: fixed;
    z-index: 4000;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    
    /* UPDATED: Back to "Shadowy" low opacity black */
    background-color: rgba(0, 0, 0, 0.95); 
    
    display: none; 
    justify-content: center;
    align-items: center;
    opacity: 0;
    transition: opacity 0.2s ease-out;
}

.lightbox-modal.open {
    display: flex;
    opacity: 1;
}

.lightbox-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    pointer-events: none; 
}

/* HIGH PERFORMANCE IMAGE RENDERING */
.lightbox-content img {
    pointer-events: auto;
    
    /* Sizing logic */
    width: auto;
    height: auto;
    max-width: 100vw;
    max-height: 95vh;
    object-fit: contain; 
    
    /* PERFORMANCE FIXES */
    border: none;
    box-shadow: none; /* Expensive shadow removed */
    transform: translateZ(0); /* Force GPU Acceleration */
    will-change: transform, opacity; /* Hint to browser */
    image-rendering: -webkit-optimize-contrast; /* Sharpening without lag */
}

/* Lightbox Controls */
.lightbox-close {
    position: absolute;
    top: 20px;
    right: 20px;
    color: white;
    font-size: 3rem;
    cursor: pointer;
    z-index: 4001;
    line-height: 1;
    opacity: 0.7;
    padding: 10px; /* Larger touch target */
}

.lightbox-close:hover { opacity: 1; }

.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: white;
    background: transparent; /* Remove background blur calculation */
    border: none;
    font-size: 4rem; /* Larger, simpler arrows */
    padding: 2rem;
    cursor: pointer;
    opacity: 0.6;
    transition: opacity 0.2s;
    z-index: 4002;
    /* Hardware acceleration for buttons too */
    transform: translateY(-50%) translateZ(0); 
}

.lightbox-prev:hover,
.lightbox-next:hover {
    opacity: 1;
    color: var(--accent-color);
}

.lightbox-prev { left: 0; }
.lightbox-next { right: 0; }

@media (max-width: 768px) {
    .lightbox-prev, .lightbox-next {
        font-size: 2.5rem; 
        padding: 1rem;
    }
}

/* =========================================
   FINAL CTA CARD (Floating Style)
   ========================================= */
.cta-box {
    background-color: var(--accent-color);
    color: var(--text-white);
    text-align: center;
    padding: 3rem 2rem;
    border-radius: 12px; /* Makes it a rounded card */
    max-width: 600px;    /* Prevents it from being too wide */
    margin: 0 auto;      /* Centers the card */
    
    /* The "Hovering" Effect */
    box-shadow: 0 20px 40px -10px rgba(0,0,0,0.15); 
}

.cta-box h2 {
    color: var(--text-white);
    margin-bottom: 1rem;
    font-size: 2rem;
}

.cta-box p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    opacity: 0.95;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Specific button style for inside the green card */
.btn-white {
    background-color: var(--bg-white);
    color: var(--accent-color) !important; /* Force green text */
    border: none;
    display: inline-block;
    padding: 0.75rem 2rem;
    border-radius: var(--border-radius);
    font-weight: 600;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn-white:hover {
    background-color: var(--primary-color);
    color: var(--text-white) !important;
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

@media (max-width: 768px) {
    .cta-box {
        padding: 2rem 1.5rem;
        margin-left: 1rem;
        margin-right: 1rem;
    }
    .cta-box h2 { font-size: 1.5rem; }
}

/* =========================================
   FINANCING BADGE & NOTICES 
   ========================================= */

/* Financing Banner (Below Hero) */
.financing-banner {
    background: var(--bg-light);
    padding: 1.5rem 0;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.financing-banner .container {
    display: flex;
    justify-content: center;
    align-items: center;
}

.financing-banner .financing-badge {
    margin-top: 0; 
}

/* Financing Badge (Used in Banner) */
.financing-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(139, 58, 58, 0.9);
    color: white;
    padding: 0.6rem 1.2rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    margin-top: 1.5rem;
    backdrop-filter: blur(10px);
    box-shadow: 
        0 4px 20px var(--financing-glow),
        0 0 40px var(--financing-glow),
        0 0 60px rgba(139, 58, 58, 0.2);
    transition: all 0.3s ease;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    width: fit-content;
    max-width: 100%;
}

.financing-badge:hover {
    background: rgba(139, 58, 58, 1);
    transform: translateY(-3px) scale(1.02);
    box-shadow: 
        0 8px 30px var(--financing-glow),
        0 0 60px var(--financing-glow),
        0 0 80px rgba(139, 58, 58, 0.3);
}

.financing-icon {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.5));
}

/* Contact Form Financing Notice */
.financing-notice {
    background: linear-gradient(135deg, 
                rgba(139, 58, 58, 0.08) 0%, 
                rgba(139, 58, 58, 0.03) 100%);
    border-left: 4px solid var(--financing-color);
    padding: 1.25rem 1.5rem;
    border-radius: 6px;
    margin-bottom: 2rem;
    box-shadow: 0 2px 8px rgba(139, 58, 58, 0.1);
    width: 100%;
    box-sizing: border-box;
}

.financing-notice-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 0.75rem;
    flex-wrap: nowrap;
}

.financing-notice-icon {
    width: 28px;
    height: 28px;
    flex-shrink: 0;
    filter: invert(25%) sepia(45%) saturate(1500%) hue-rotate(340deg) brightness(85%);
}

.financing-notice h3 {
    font-family: var(--font-heading);
    color: var(--financing-color);
    font-size: 1.2rem;
    margin: 0;
    flex: 1;
}

.financing-notice p {
    color: var(--text-dark);
    line-height: 1.6;
    margin: 0 0 0.75rem 0;
    width: 100%;
}

.financing-link {
    color: var(--financing-color);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-fast);
    font-size: 0.95rem;
    display: inline-block;
    width: auto;
}

.financing-link:hover {
    color: #6d2d2d;
    text-decoration: underline;
}

/* Service Card Financing Badge */
.service-financing-badge {
    background: var(--financing-color);
    color: white;
    padding: 0.25rem 0.6rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 0.5rem;
    white-space: nowrap;
    display: inline-block;
    vertical-align: middle;
}

/* Footer Financing Notice */
.footer-financing {
    font-size: 0.85rem;
    margin-top: 0.5rem;
    opacity: 0.9;
    width: auto;
}

/* Gallery Page Financing CTA */
.gallery-financing-cta {
    text-align: center;
    margin-top: 3rem;
    color: var(--text-light);
    width: 100%;
    display: block;
}

.gallery-financing-cta a {
    color: var(--accent-color);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition-fast);
    display: inline;
}

.gallery-financing-cta a:hover {
    color: var(--accent-hover);
    text-decoration: underline;
}

@media (max-width: 768px) {
    .financing-badge {
        font-size: 0.85rem;
        padding: 0.5rem 1rem;
    }
    
    .service-financing-badge {
        display: block;
        margin-left: 0;
        margin-top: 0.5rem;
        width: fit-content;
    }
    
    .financing-notice {
        padding: 1rem;
    }
    
    .financing-banner {
        padding: 1.25rem 0;
    }
}