/* =============================================================
   CONSOLIDATED CSS for RealEstateHUD.com
   Replaces: hero1.css (S3) + both inline <style> blocks
   
   Load order: Bootstrap → ag1.css → THIS FILE → footer.css
   Then ONE inline <style> for PHP dynamic hero background image
   ============================================================= */

/* --- Base / Global (from head inline block) --- */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

/* Only add body padding when navbar is fixed-top (takes nav out of flow).
   Uses :has() selector — supported in Chrome 105+, Firefox 121+, Safari 15.4+.
   Without fixed-top nav, content flows naturally below the navbar. */
body:has(.fixed-top) {
    padding-top: 70px;
}

/* Hero pages: zero padding regardless — hero fills viewport, nav overlays */
body.has-hero {
    padding-top: 0 !important;
}

p, ul {
    font-size: 1rem;
}

@media (max-width: 767px) {
    p, ul {
        font-size: 1.25rem;
    }
}

.modal-backdrop {
    z-index: -1;
}

/* --- Hero Banner (background image set via PHP inline style) --- */

.hero-banner {
    height: 100vh;
    min-height: 100vh;
    max-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    width: 100%;
    overflow: hidden;
    background-color: #000;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}


.hero-banner .overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.1), rgba(0,0,0,0.3));
    z-index: 1;
}

.hero-banner .content {
    position: relative;
    z-index: 2;
    padding: 60px 20px;
    width: 100%;
}

.hero-banner h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.7);
    letter-spacing: -1px;
}

.hero-banner h3 {
    font-size: 1.5rem;
    font-weight: 300;
    margin-bottom: 3rem;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.7);
    opacity: 0.95;
}

.hero-banner h2 {
    font-size: 1.3rem;
    font-weight: 400;
    margin-top: 2rem;
    text-shadow: 1px 1px 4px rgba(0,0,0,0.7);
}

/* --- Search Wrapper (white box in hero) --- */
.search-wrapper {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.4);
    max-width: 800px;  /* <-- CHANGE THIS VALUE to resize the search box */
    margin: 0 auto;
}

/* --- Search Input --- */
#search {
    height: 60px;
    font-size: 1.1rem;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 0 25px;
    transition: all 0.3s ease;
    background: white;
    width: 100%;
}

#search:focus {
    border-color: #dc3545;
    box-shadow: 0 0 0 0.2rem rgba(220, 53, 69, 0.15);
    outline: none;
}

#search::placeholder {
    font-weight: 600;
    color: #999;
}

/* --- Search Icon --- */
.search-icon {
    position: absolute;
    right: 25px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.3rem;
    color: #dc3545;
    pointer-events: none;
}

/* --- Autocomplete Dropdown --- */
.custom-dropdown {
    position: relative;
}

.dropdown-options {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border-radius: 10px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    max-height: 400px;
    overflow-y: auto;
    z-index: 1000;
    margin-top: 10px;
}

.dropdown-options div {
    padding: 15px 25px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-options div:last-child {
    border-bottom: none;
}

.dropdown-options div:hover {
    background: #f8f9fa;
    padding-left: 30px;
    color: #dc3545;
}

/* Dropdown scrollbar */
.dropdown-options::-webkit-scrollbar {
    width: 8px;
}

.dropdown-options::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.dropdown-options::-webkit-scrollbar-thumb {
    background: #dc3545;
    border-radius: 10px;
}

.dropdown-options::-webkit-scrollbar-thumb:hover {
    background: #c82333;
}

/* --- Navbar --- */
.navbar.fixed-top {
    z-index: 1000;
}

/* --- Scroll Indicator (bounce arrow) --- */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    color: white;
    animation: bounce 2s infinite;
    cursor: pointer;
}

.scroll-indicator i {
    font-size: 2rem;
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { transform: translateX(-50%) translateY(0); }
    40% { transform: translateX(-50%) translateY(-10px); }
    60% { transform: translateX(-50%) translateY(-5px); }
}

/* --- Responsive --- */
@media (max-width: 768px) {
    .hero-banner h1 {
        font-size: 2.5rem;
    }
    
    .hero-banner h3 {
        font-size: 1.2rem;
        margin-bottom: 2rem;
    }
    
    .search-wrapper {
        padding: 25px 20px;
        border-radius: 10px;
    }
    
    #search {
        height: 50px;
        font-size: 1rem;
    }
}
