/* 1. THE BASIC SCROLL FIX */
html {
    scroll-behavior: smooth !important;
    scroll-padding-top: 110px !important; /* Adjust this number to stop exactly where you want */
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    color: var(--dark-gray);
    background-color: var(--white);
    overflow-x: hidden;
}

/* 2. THE STABLE SECTION (No more VH or Flex breaking things) */
section {
    padding: 100px 10%; 
    background-color: var(--white);
    position: relative;
    display: block; /* This keeps your columns side-by-side */
    width: 100%;
    box-sizing: border-box;
}

/* 3. THE HOME SECTION (Just the essentials) */
#home {
    min-height: 80vh; /* Shorter, so it doesn't push content too far */
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), 
                url('img/hero-tree.jpg') no-repeat center center;
    background-size: cover;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--white);
}


/* 3. FIX FOR SERVICE COLUMNS & CONTACT FORM */
.services-container, .contact-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

#services {
    padding-top: 150px !important;
}

:root {
    --primary-green: #4CAF50; 
    --accent-gold: #f4b41a;
    --dark-gray: #333;
    --light-gray: #f9f9f9;
    --white: #ffffff;
}

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

h1, h2, h3 { font-family: 'Montserrat', sans-serif; text-transform: uppercase; }


/* 1. THE TOP BAR - Locked to the very top */
.top-contact-bar {
    position: fixed !important;
    top: 0 !important;
    left: 0;
    width: 100% !important;
    height: 40px; 
    z-index: 9999 !important; 
    background-color: #1a1a1a !important;
    display: flex;
    align-items: center;
    border-bottom: 1px solid #333;
}

/* 2. THE WRAPPER - Keeps the 3 items in a line */
.contact-info-wrapper {
    display: flex !important;
    flex-direction: row !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 20px !important;
    margin: 0 auto !important;
}

/* 3. THE ITEMS - Text and spacing */
.contact-item {
    color: #ffffff !important;
    font-size: 14px !important;
    display: flex !important;
    align-items: center !important;
    white-space: nowrap !important;
    font-family: Arial, sans-serif;
}

.contact-item a {
    color: #ffcc00 !important; /* Your Gold */
    text-decoration: none !important;
    font-weight: bold !important;
}

/* 4. THE ICONS - Your Green #4caf50 */
.contact-item i {
    color: #4caf50 !important; 
    margin-right: 8px !important;
}

/* 5. THE NAV - Pushed down so it doesn't hide the bar */
nav {
    position: fixed !important;
    top: 40px !important; /* Starts exactly where the bar ends */
    left: 0;
    width: 100%;
    z-index: 9998 !important;
}

/* 8. MOBILE - Hides location on tiny screens */
@media (max-width: 550px) {
    .contact-item:first-child {
        display: none !important;
    }
}

/* --- THE ULTIMATE NAV SHADOW FIX --- */
nav {
    background: var(--white);
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 5%;
    position: fixed;
    width: 100%;
    top: 45px;
    left: 0;
    /* Force the nav to be on the very top layer */
    z-index: 1000; 
    
    /* We use a slightly deeper, more solid shadow to survive the gray background */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35); 
}


/* --- THE SECTION FIX --- */

header {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    min-height: 100vh;
    padding-top: 150px; /* This creates the space so your text isn't hidden */
    box-sizing: border-box;
}

/* --- UPDATED SERVICES SECTION --- */

.logo-container {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 15px;
}

.site-logo { height: 120px; width: auto; }

.logo-text-wrapper { display: flex; flex-direction: column; line-height: 1.1; }

.logo-line-one {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 1rem;
    color: var(--primary-green);
    letter-spacing: 1px;
}

.logo-line-two {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    font-size: 1.3rem;
    color: var(--dark-gray);
}

.logo-line-three {
    font-family: 'Roboto', sans-serif;
    font-weight: 700;
    font-size: 0.75rem;
    color: #777;
    margin-top: 2px;
    letter-spacing: 0.5px;
}

.nav-links { display: flex; list-style: none; margin-left: auto; }
.nav-links li { padding: 0 15px; }
.nav-links a { 
    text-decoration: none; 
    color: var(--dark-gray); 
    font-weight: 700; 
    text-transform: uppercase; 
    font-size: 0.9rem;
}
.nav-links a:hover { color: var(--primary-green); }

.menu-toggle { display: none; flex-direction: column; cursor: pointer; }
.menu-toggle span { height: 3px; width: 25px; background: var(--primary-green); margin-bottom: 4px; border-radius: 2px; }


.hero-content h1 { font-size: clamp(2.2rem, 8vw, 4rem); margin-bottom: 1rem; line-height: 1.2; }
.hero-content p { font-size: 1.3rem; margin-bottom: 30px; }
.cta-button { 
    display: inline-block; 
    background: var(--accent-gold); 
    color: var(--dark-gray); 
    padding: 18px 40px; 
    text-decoration: none; 
    font-weight: bold; 
    border-radius: 5px; 
    text-transform: uppercase; 
}

/* --- Content Sections: THE FIX IS ALSO HERE --- */

.section-title { text-align: center; margin-bottom: 20px; color: var(--primary-green); font-size: 2.5rem; }
.underline { width: 80px; height: 4px; background: var(--accent-gold); margin: 0 auto 40px; }

.about-text { max-width: 900px; margin: 0 auto; text-align: center; font-size: 1.1rem; }
.services-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px; }
.service-card { background: var(--light-gray); padding: 40px; text-align: center; border-radius: 15px; border-bottom: 5px solid var(--primary-green); }

/* this code makes images horizontal, but for now is being commented out */
/*---
.gallery-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 15px; }
.gallery-grid img { width: 100%; height: 300px; object-fit: cover; border-radius: 10px; }--*/

/* --- 4-Column Full Tree Gallery --- */
.gallery-grid { 
    display: grid; 
    /* Changed from 3 to 4 columns for a better balance of tall images */
    grid-template-columns: repeat(4, 1fr); 
    gap: 15px; 
    max-width: 1200px; /* Slightly wider to accommodate the 4th column */
    margin: 0 auto;
    align-items: start;
}

.gallery-grid img { 
    width: 100%; 
    height: auto; 
    object-fit: contain; 
    border-radius: 8px; /* Slightly smaller radius looks better in tighter grids */
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

.gallery-grid img:hover {
    transform: scale(1.04);
    z-index: 10; /* Ensures the zoomed image stays on top of neighbors */
}

/* --- Responsive Adjustments --- */
@media (max-width: 1024px) {
    .gallery-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 columns for tablets */
    }
}

@media (max-width: 600px) {
    .gallery-grid {
        grid-template-columns: 1fr; /* 1 column for phones */
        gap: 25px;
    }
}


/* --- Contact Grid --- */
.contact-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    max-width: 1100px;
    margin: 0 auto;
}

.contact-info h3 { color: var(--primary-green); margin-bottom: 20px; }
.phone-link { font-size: 1.5rem; color: var(--primary-green); font-weight: 700; text-decoration: none; display: block; margin-top: 10px; }

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

.contact-form { display: flex; flex-direction: column; }
.contact-form input, .contact-form textarea { margin-bottom: 20px; padding: 15px; border: 1px solid #ddd; border-radius: 8px; }
.submit-btn { background: var(--primary-green); color: white; border: none; padding: 18px; font-weight: bold; text-transform: uppercase; cursor: pointer; border-radius: 8px; }

/* --- Thank You Modal --- */
#thankYouModal { 
    display: none; 
    position: fixed; 
    z-index: 10000; /* Must be higher than nav (9999) */
    left: 0; 
    top: 0; 
    width: 100%; 
    height: 100%; 
    background-color: rgba(0,0,0,0.8); 
    align-items: center; 
    justify-content: center; 
}

.modal-content { 
    background: white; 
    padding: 40px; 
    border-radius: 15px; 
    text-align: center; 
    max-width: 400px; 
    margin: 20px; 
    border-bottom: 8px solid var(--accent-gold); 
}

/* --- Footer --- */
footer { 
    background: #111; 
    color: var(--white); 
    padding: 60px 10% 40px; 
    text-align: center; 
    position: relative; 
    z-index: 5; 
}

.footer-socials { margin-bottom: 30px; }
.footer-socials a { color: var(--white); font-size: 1.8rem; margin: 0 15px; transition: color 0.3s; }
.footer-socials a:hover { color: var(--accent-gold); }

.footer-creds { font-size: 0.9rem; text-transform: uppercase; letter-spacing: 1px; color: #888; margin-bottom: 10px; }
.footer-license { font-weight: 700; color: var(--accent-gold); margin-bottom: 20px; }

/* --- Responsive --- */
@media (max-width: 992px) {
    .menu-toggle { display: flex; }
    .nav-links { position: fixed; right: -100%; top: 100px; flex-direction: column; background: var(--white); width: 100%; height: 100vh; text-align: center; transition: 0.4s; }
    .nav-links.active { right: 0; }
    .site-logo { height: 80px; }
    nav { padding: 5px 5%; }
}

@media (max-width: 850px) {
    .contact-wrapper { grid-template-columns: 1fr; text-align: center; }
}

@media (max-width: 480px) {
    .site-logo { height: 60px; }
    .logo-line-one { font-size: 0.7rem; }
    .logo-line-two { font-size: 0.9rem; }
    .logo-line-three { font-size: 0.6rem; }
}

/* --- Services Section Styling --- */
#services {
    background-color: var(--white) !important; /* Forces background to white for the shadow fix */
    position: relative;
    z-index: 1;
}

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

.service-card { 
    background: var(--light-gray); /* This makes the boxes light gray so they pop against the white page */
    padding: 40px; 
    text-align: center; 
    border-radius: 15px; 
    border-bottom: 5px solid var(--primary-green); 
    box-shadow: 0 5px 15px rgba(0,0,0,0.05); /* Optional: adds a tiny shadow to the cards themselves */
}

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

/* =========================================
   MOBILE CALL BAR (Bottom of Screen)
   ========================================= */

/* Sticky Call Button for Mobile */
.sticky-call {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: #2d5a27; /* Your brand green */
    padding: 15px 0;
    text-align: center;
    z-index: 9999;
    box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
    display: none; /* Hidden by default on Desktop */
}

.call-btn {
    color: white;
    text-decoration: none;
    font-weight: bold;
    font-size: 18px;
    letter-spacing: 1px;
}

/* Only show this on mobile devices (phones) */
@media (max-width: 768px) {
    .sticky-call {
        display: block;
    }
    /* Adds space at the bottom of the page so the button doesn't cover your footer */
    body {
        padding-bottom: 60px;
    }
}

/* --- Gallery Title Precision Match --- */
#gallery .section-title {
    text-align: center;
    text-transform: uppercase;
    /* We removed color/font-size here so it matches your other H2s naturally */
    position: relative;
    display: block;
    width: 100%;
    margin-bottom: 40px;
}

/* This ensures the text itself matches the other section headers */
#gallery .section-title span {
    color: inherit; 
    font-family: inherit;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

/* The yellow line adjusted to be shorter and centered */
/* --- Gallery Title: Elegant Underline --- */
#gallery .section-title span::after {
    content: "";
    position: absolute;
    bottom: -5px; /* Moves it slightly lower so it doesn't touch the letters */
    left: 50%;
    transform: translateX(-50%); /* The "Secret Sauce" for perfect centering */
    width: 80px;  /* This makes it wider (not short) */
    height: 4px;  /* This makes it thinner (not fat) */
    background-color: #ffcc00; /* Your brand yellow */
    border-radius: 5px; /* Smooths the edges */
}