/* =========================================
   PYRITE REAL ESTATE - STYLES
   ========================================= */

:root {
    /* Color Palette */
    --primary-navy: #0F172A; /* Deep Authority Navy */
    --primary-navy-light: #1E293B;
    --secondary-gold: #D4AF37; /* Rich Gold */
    --secondary-gold-light: #F3E5AB;
    --secondary-gold-hover: #C5A028;
    
    --bg-white: #FFFFFF;
    --bg-pearl: #F8FAFC; /* Pearl Gray */
    
    --text-dark: #334155;
    --text-light: #334155;
    
    /* Typography */
    --font-heading: 'Cormorant Garamond', serif;
    --font-body: 'Montserrat', sans-serif;
    
    /* Transitions & Shadows */
    --transition-fast: 0.2s ease;
    --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-md: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --shadow-accent: 0 10px 25px -5px rgba(212, 175, 55, 0.3);
    
    /* Layout */
    --max-width: 1280px;
    --header-height: 80px;
}

/* =========================================
   RESET & BASICS
   ========================================= */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--text-dark);
    background-color: var(--bg-pearl);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-heading);
    color: var(--primary-navy);
    font-weight: 700;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color var(--transition-fast);
}

ul {
    list-style: none;
}

.container {
    max-width: var(--max-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* =========================================
   BUTTONS
   ========================================= */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 28px;
    border-radius: 4px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.5;
    box-sizing: border-box;
    cursor: pointer;
    transition: all var(--transition-smooth);
    border: none;
    gap: 8px;
}

.btn-primary {
    background-color: var(--secondary-gold);
    color: var(--primary-navy);
    box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
    background-color: var(--secondary-gold-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-accent);
}

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

.btn-secondary:hover {
    background-color: var(--primary-navy-light);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

/* =========================================
   HEADER
   ========================================= */
.main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background-color: rgba(255, 255, 255, 0.95);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    z-index: 1000;
    box-shadow: var(--shadow-sm);
    transition: transform 0.35s ease, height 0.35s ease, background 0.35s ease, padding 0.35s ease, box-shadow 0.35s ease, border-bottom 0.35s ease;
}

.main-header.header-scrolled {
    background: rgba(15, 23, 42, 0.85) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(212, 175, 55, 0.25);
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.3);
}

.main-header.header-hidden {
    transform: translateY(-100%);
}

.main-header.header-scrolled .nav-item {
    color: white;
}

.main-header.header-scrolled .btn-secondary.btn-contact {
    border-color: white;
    color: white;
}

.main-header.header-scrolled .btn-secondary.btn-contact:hover {
    background-color: white;
    color: var(--primary-navy);
}

.main-header.header-scrolled .mobile-menu-toggle {
    color: white;
}

.header-container {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0.75rem 1.5rem;
    transition: padding 0.35s ease;
}

.main-header.header-scrolled .header-container {
    padding: 0.5rem 1.5rem;
}

.logo-link {
    height: 60%;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.brand-logo {
    height: 100%;
    object-fit: contain;
}

.desktop-nav {
    display: none;
}

@media (min-width: 1024px) {
    .desktop-nav {
        display: block;
    }
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 1.25rem;
}

.nav-item {
    font-family: var(--font-body);
    font-weight: 500;
    color: var(--primary-navy);
    font-size: 0.875rem;
    position: relative;
    padding: 8px 0;
    white-space: nowrap;
}

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

.nav-item:hover::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
}

.header-actions .btn {
    width: auto;
    white-space: nowrap;
    padding: 0.5rem 1rem;
}

@media (max-width: 1023px) {
    .header-actions .currency-selector {
        display: none;
    }
    .header-actions .btn-estimate {
        display: none; /* Cache sur mobile pour faire de la place, optionnel selon l'espace mais recommandé */
    }
}

.mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--primary-navy);
    cursor: pointer;
}

@media (min-width: 1024px) {
    .mobile-menu-toggle {
        display: none;
    }
}

/* =========================================
   HERO SECTION
   ========================================= */
.hero {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: var(--header-height);
}

.hero-slider {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background-color: var(--color-navy);
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    z-index: 0;
    transition: opacity 1.5s ease-in-out;
}

.hero-slide.prev {
    opacity: 1;
    z-index: 1;
}

.hero-slide.active {
    opacity: 1;
    z-index: 2;
}

.hero-slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transform: scale(1);
    /* Optimisation matérielle pour la netteté pendant l'animation */
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
    transform-style: preserve-3d;
    image-rendering: -webkit-optimize-contrast;
}

/* Animation Ken Burns s'applique à la slide active ET précédente pour un fondu fluide sans saut */
.hero-slide.active img,
.hero-slide.prev img {
    animation: kenburns 6s linear forwards;
}

@keyframes kenburns {
    0% { transform: scale(1); }
    100% { transform: scale(1.08); }
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 3;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.35) 0%, rgba(15, 23, 42, 0.55) 100%);
}

/* Puces de navigation du Slider */
.hero-slider-nav {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 12px;
    z-index: 10;
}

.slider-dot {
    width: 30px;
    height: 4px;
    background: rgba(255, 255, 255, 0.4);
    border-radius: 2px;
    cursor: pointer;
    transition: background 0.3s ease, width 0.3s ease;
}

.slider-dot.active {
    background: var(--color-gold);
    width: 50px;
}

.hero-content {
    text-align: center;
    color: white;
    width: 100%;
    max-width: 1000px;
    padding: 40px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-subtitle {
    font-family: var(--font-body);
    font-size: 0.875rem;
    font-weight: 600;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    color: var(--secondary-gold);
    margin-bottom: 24px;
    display: block;
}

.hero-title {
    color: white;
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    line-height: 1.1;
    margin-bottom: 48px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

/* =========================================
   SEARCH WIDGET (Glassmorphism)
   ========================================= */
.search-widget {
    background: rgba(255, 255, 255, 0.1);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 12px;
    width: 100%;
    max-width: 900px;
    box-shadow: var(--shadow-lg);
    overflow: hidden;
}

.accent-glow {
    box-shadow: 0 0 40px rgba(212, 175, 55, 0.15), var(--shadow-lg);
}

.search-tabs {
    display: flex;
    background: rgba(15, 23, 42, 0.7);
}

.tab-btn {
    flex: 1;
    padding: 16px;
    background: transparent;
    border: none;
    color: white;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition-fast);
    position: relative;
    opacity: 0.7;
}

.tab-btn.active {
    opacity: 1;
    background: rgba(255, 255, 255, 0.1);
}

.tab-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background-color: var(--secondary-gold);
}

.search-form {
    display: none; /* Handled by JS */
    padding: 24px;
    background: rgba(255, 255, 255, 0.95);
    border-radius: 0 0 12px 12px;
    align-items: center;
    gap: 16px;
}


/* FIX Display Logic: Flex vs Block */
.search-form {
    display: none;
    flex-direction: column;
}
.search-form.active {
    display: flex;
}
@media (min-width: 768px) {
    .search-form.active {
        flex-direction: row;
    }
}

.form-group {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    position: relative;
}

.form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group label i {
    color: var(--secondary-gold);
    width: 16px;
    height: 16px;
}

.form-group select {
    width: 100%;
    padding: 8px 0;
    border: none;
    background: transparent;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 600;
    color: var(--primary-navy);
    cursor: pointer;
    outline: none;
    appearance: none;
}

/* =========================================
   BUDGET DUAL RANGE SLIDER — PYRITE
   ========================================= */
.budget-range-group { flex: 1.5; min-width: 200px; }
.budget-range-widget { width: 100%; padding: 4px 0 0; }
.budget-display { margin-bottom: 10px; }
.budget-range-label {
    font-size: 0.88rem; font-weight: 700; color: var(--primary-navy);
    letter-spacing: 0.01em; white-space: nowrap;
    overflow: hidden; text-overflow: ellipsis; display: block;
}
.dual-range-container {
    position: relative; height: 36px;
    display: flex; align-items: center; margin: 4px 0 8px;
}
.range-track {
    position: absolute; left: 0; right: 0; height: 4px;
    border-radius: 4px; background: #E2E8F0; z-index: 1; pointer-events: none;
}
.range-fill {
    position: absolute; height: 100%; border-radius: 4px;
    background: linear-gradient(90deg, #D4AF37, #B8962E);
    left: 0%; right: 0%; transition: left 0.04s, right 0.04s;
}
.range-thumb {
    position: absolute; width: 100%; height: 36px;
    background: transparent; appearance: none; -webkit-appearance: none;
    pointer-events: none; z-index: 3; outline: none; border: none; margin: 0; padding: 0;
}
.range-thumb::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    width: 22px; height: 22px; border-radius: 50%;
    background: #D4AF37; border: 2.5px solid #FFFFFF;
    box-shadow: 0 2px 8px rgba(212,175,55,0.45);
    cursor: grab; pointer-events: all;
    transition: transform 0.15s, box-shadow 0.15s;
}
.range-thumb::-moz-range-thumb {
    width: 22px; height: 22px; border-radius: 50%;
    background: #D4AF37; border: 2.5px solid #FFFFFF;
    box-shadow: 0 2px 8px rgba(212,175,55,0.45);
    cursor: grab; pointer-events: all;
    transition: transform 0.15s, box-shadow 0.15s;
}
.range-thumb::-webkit-slider-thumb:hover {
    transform: scale(1.2);
    box-shadow: 0 0 0 6px rgba(212,175,55,0.18), 0 2px 8px rgba(212,175,55,0.5);
}
.range-thumb:active::-webkit-slider-thumb { cursor: grabbing; transform: scale(1.15); }
.range-thumb::-moz-range-thumb:hover, .range-thumb:active::-moz-range-thumb {
    transform: scale(1.2);
    box-shadow: 0 0 0 6px rgba(212,175,55,0.18), 0 2px 8px rgba(212,175,55,0.5);
    cursor: grabbing;
}
.range-thumb::-webkit-slider-runnable-track, .range-thumb::-moz-range-track {
    background: transparent; border: none;
}
.budget-custom-toggle {
    background: none; border: none; padding: 0; margin-top: 2px;
    font-size: 0.75rem; color: #D4AF37; cursor: pointer;
    font-family: var(--font-body); font-weight: 500;
    text-decoration: underline; text-underline-offset: 2px;
    transition: color 0.2s; display: block; line-height: 1.4;
}
.budget-custom-toggle:hover { color: #B8962E; }
.budget-custom-inputs {
    display: flex; align-items: center; gap: 8px;
    margin-top: 10px; width: 100%;
}
.budget-custom-inputs.hidden { display: none; }
.budget-custom-input {
    flex: 1; min-width: 0; padding: 7px 10px;
    border: 1px solid rgba(212,175,55,0.4); border-radius: 6px;
    background: rgba(255,255,255,0.9); font-family: var(--font-body);
    font-size: 0.88rem; font-weight: 600; color: var(--primary-navy);
    outline: none; transition: border-color 0.2s, box-shadow 0.2s;
    -moz-appearance: textfield;
}
.budget-custom-input::-webkit-outer-spin-button,
.budget-custom-input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.budget-custom-input:focus {
    border-color: #D4AF37; box-shadow: 0 0 0 3px rgba(212,175,55,0.15);
}
.budget-custom-sep { font-size: 1rem; color: var(--text-light); flex-shrink: 0; user-select: none; }
@media (max-width: 768px) {
    .range-thumb::-webkit-slider-thumb { width: 28px; height: 28px; }
    .range-thumb::-moz-range-thumb { width: 28px; height: 28px; }
    .dual-range-container { height: 44px; }
    .budget-range-label { font-size: 0.82rem; }
    .budget-custom-input { padding: 9px 10px; font-size: 0.95rem; }
    .budget-range-group { min-width: 0; }
}

.form-divider {
    width: 100%;
    height: 1px;
    background-color: #E2E8F0;
    margin: 16px 0;
}

@media (min-width: 768px) {
    .form-divider {
        width: 1px;
        height: 40px;
        margin: 0;
    }
}

.search-submit {
    width: 100%;
    padding: 16px 24px;
    font-size: 1.125rem;
}

@media (min-width: 768px) {
    .search-submit {
        width: auto;
    }
}

/* =========================================
   SECTIONS GENERAL
   ========================================= */
.section {
    padding: 80px 0;
}

.bg-pearl {
    background-color: var(--bg-pearl);
}

.section-header {
    margin-bottom: 48px;
}

.section-header.center {
    text-align: center;
}

.section-title {
    font-size: 2.5rem;
    margin-bottom: 16px;
    color: var(--primary-navy);
}

.section-subtitle {
    font-size: 1.125rem;
    color: var(--text-light);
    max-width: 600px;
}

.section-header.center .section-subtitle {
    margin: 0 auto;
}

/* =========================================
   SERVICES SECTION
   ========================================= */
.services-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 24px;
}

@media (min-width: 768px) {
    .services-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .services-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.service-card {
    background: white;
    padding: 32px 24px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    border: 1px solid rgba(0,0,0,0.05);
}

.service-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(212, 175, 55, 0.3);
}

.service-icon {
    width: 64px;
    height: 64px;
    background: var(--bg-pearl);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    transition: var(--transition-fast);
}

.service-card:hover .service-icon {
    background: var(--primary-navy);
}

.service-icon i {
    width: 32px;
    height: 32px;
    color: var(--secondary-gold);
}

.service-card h3 {
    font-size: 1.5rem;
    margin-bottom: 16px;
}

.service-card p {
    color: var(--text-light);
    margin-bottom: 24px;
    font-size: 0.95rem;
}

.service-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: var(--primary-navy);
    font-size: 0.95rem;
}

.service-link i {
    width: 16px;
    height: 16px;
    transition: transform var(--transition-fast);
}

.service-link:hover i {
    transform: translateX(4px);
    color: var(--secondary-gold);
}

/* =========================================
   LISTINGS SECTION
   ========================================= */
.listings-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
}

@media (min-width: 768px) {
    .listings-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .listings-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.property-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
}

.property-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.property-image {
    position: relative;
    height: 240px;
    overflow: hidden;
}

.property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
    /* Performance : ratio explicite élimine le reflow (CLS) */
    aspect-ratio: 4 / 3;
    contain: strict;
}

.property-card:hover .property-image img {
    transform: scale(1.08);
}

.property-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: var(--secondary-gold);
    color: var(--primary-navy);
    padding: 6px 12px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 4px;
    z-index: 2;
    box-shadow: var(--shadow-sm);
}

.property-content {
    padding: 24px;
    flex-grow: 1;
}

.property-location {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.875rem;
    color: var(--text-light);
    margin-bottom: 8px;
}

.property-location i {
    width: 14px;
    height: 14px;
    color: var(--secondary-gold);
}

.property-title {
    font-size: 1.25rem;
    margin-bottom: 12px;
    line-height: 1.3;
}

.property-price {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary-navy);
    margin-bottom: 20px;
}

.property-features {
    display: flex;
    justify-content: space-between;
    border-top: 1px solid #E2E8F0;
    padding-top: 16px;
}

.property-features span {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.875rem;
    color: var(--text-dark);
    font-weight: 500;
}

.property-features i {
    width: 16px;
    height: 16px;
    color: var(--secondary-gold);
}

.property-footer {
    padding: 0 24px 24px;
}

.btn-full {
    width: 100%;
}

/* =========================================
   ESTIMATION MODULE (Lead Magnet)
   ========================================= */
.estimation-section {
    background-color: var(--bg-pearl);
    margin: 0 !important;
    padding-top: 50px !important;
    padding-bottom: 20px !important;
}

.estimation-wrapper {
    display: flex;
    flex-direction: column;
    gap: 48px;
    align-items: center;
}

@media (min-width: 992px) {
    .estimation-wrapper {
        flex-direction: row;
        justify-content: space-between;
        align-items: flex-start;
    }
}

.estimation-header {
    flex: 1;
    max-width: 500px;
}

.estimation-header h2 {
    color: var(--primary-navy);
    font-size: 2.5rem;
    margin-bottom: 24px;
}

.estimation-header p {
    color: var(--text-dark);
    font-size: 1.125rem;
    margin-bottom: 32px;
}

.estimation-progress {
    margin-top: 32px;
}

.progress-track {
    width: 100%;
    height: 8px;
    background-color: #E2E8F0;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
}

.progress-bar {
    height: 100%;
    background-color: var(--secondary-gold);
    transition: width 0.4s ease;
}

.progress-text {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 500;
}

.estimation-form-container {
    flex: 1;
    width: 100%;
    max-width: 550px;
    background: white;
    border-radius: 16px;
    padding: 32px;
    color: var(--text-dark);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
    position: relative;
    overflow: hidden;
    min-height: 400px;
    border-top: 4px solid var(--secondary-gold);
}

.est-step {
    display: none;
    animation: estFadeIn 0.4s ease forwards;
}

.est-step.active {
    display: block;
}

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

.est-step h3 {
    font-size: 1.5rem;
    margin-bottom: 24px;
    color: var(--primary-navy);
    font-family: var(--font-heading);
}

.options-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 576px) {
    .options-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.est-option-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 24px 16px;
    background: var(--bg-white);
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    font-family: var(--font-body);
    font-size: 1rem;
    font-weight: 500;
    color: var(--primary-navy);
    cursor: pointer;
    transition: all 0.3s ease;
}

.est-option-btn i {
    width: 32px;
    height: 32px;
    color: var(--primary-navy);
    transition: color 0.3s ease;
}

.est-option-btn:hover {
    background: #F8FAFC;
    border-color: var(--secondary-gold);
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

.est-option-btn:hover i {
    color: var(--secondary-gold);
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
}

@media (min-width: 576px) {
    .form-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.mb-4 { margin-bottom: 16px; }
.mb-6 { margin-bottom: 24px; }
.mt-4 { margin-top: 16px; }
.mt-6 { margin-top: 24px; }
.text-sm { font-size: 0.875rem; }
.text-gray-600 { color: #475569; }

.btn-gold-hover:hover {
    background-color: var(--primary-navy) !important;
    border-color: var(--primary-navy) !important;
}

.mt-4 { margin-top: 24px; }
.mt-2 { margin-top: 12px; }

.btn-text {
    background: none;
    border: none;
    color: var(--text-light);
    font-weight: 500;
    cursor: pointer;
    padding: 8px 0;
    width: 100%;
    text-align: center;
}

.btn-text:hover {
    color: var(--primary-navy);
}

.success-icon {
    color: #10B981;
    vertical-align: middle;
}

/* =========================================
   TRUST SECTION
   ========================================= */
.trust-section {
    background-color: var(--bg-white);
}

.trust-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px;
    text-align: center;
}

@media (min-width: 768px) {
    .trust-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.trust-metric {
    padding: 24px;
}

.metric-number {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    font-weight: 700;
    color: var(--secondary-gold);
    margin-bottom: 8px;
    line-height: 1;
}

.metric-label {
    font-size: 1.125rem;
    font-weight: 500;
    color: var(--primary-navy);
}

/* =========================================
   FOOTER
   ========================================= */
.main-footer {
    background-color: var(--primary-navy);
    color: white;
    padding: 80px 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 48px;
    margin-bottom: 64px;
}

@media (min-width: 768px) {
    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .footer-grid {
        grid-template-columns: 2fr 1.5fr 1.5fr 1.5fr;
    }
}

.footer-logo {
    height: 48px;
    margin-bottom: 24px;
    object-fit: contain;
}

.brand-col p {
    color: #334155;
    max-width: 300px;
}

.footer-socials {
    display: flex;
    gap: 16px;
    margin-top: 24px;
}

.footer-socials 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-fast);
}

.footer-socials a:hover {
    background-color: var(--secondary-gold);
    color: var(--primary-navy);
    transform: translateY(-3px);
}

.footer-socials i {
    width: 20px;
    height: 20px;
}

.footer-col h3 {
    color: white;
    font-size: 1.25rem;
    margin-bottom: 24px;
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-col a {
    color: #334155;
    transition: var(--transition-fast);
}

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

.contact-info li {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    color: #334155;
}

.contact-info i {
    width: 20px;
    height: 20px;
    color: var(--secondary-gold);
    flex-shrink: 0;
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 24px;
    color: #334155;
    font-size: 0.875rem;
}

@media (min-width: 768px) {
    .footer-bottom {
        flex-direction: row;
        justify-content: space-between;
    }
}

.legal-links {
    display: flex;
    gap: 24px;
}

.legal-links a {
    color: #334155;
}

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

/* =========================================
   FLOATING WHATSAPP BUTTON
   ========================================= */
.floating-wa {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 64px;
    height: 64px;
    background-color: #25D366;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 25px rgba(37, 211, 102, 0.4);
    z-index: 999;
    transition: transform var(--transition-smooth);
}

.floating-wa:hover {
    transform: scale(1.1) translateY(-4px);
}

@media (max-width: 768px) {
    .floating-wa {
        bottom: 24px;
        right: 24px;
        width: 56px;
        height: 56px;
    }
}

/* =========================================
   NO RESULTS MODAL
   ========================================= */
.no-results-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.7);
    -webkit-backdrop-filter: blur(6px);
    backdrop-filter: blur(6px);
}

.modal-content {
    position: relative;
    background: white;
    border-radius: 16px;
    padding: 48px 40px;
    max-width: 480px;
    width: 90%;
    text-align: center;
    box-shadow: 0 25px 60px -12px rgba(0, 0, 0, 0.35);
    animation: modalSlideIn 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    z-index: 1;
}

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

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 1.75rem;
    color: var(--text-light);
    cursor: pointer;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: var(--transition-fast);
}

.modal-close:hover {
    background: var(--bg-pearl);
    color: var(--primary-navy);
}

.modal-icon {
    margin-bottom: 20px;
    color: var(--secondary-gold);
}

.modal-content h2 {
    font-family: var(--font-heading);
    font-size: 1.75rem;
    color: var(--primary-navy);
    margin-bottom: 12px;
}

.modal-content p {
    color: var(--text-light);
    font-size: 1rem;
    margin-bottom: 8px;
    line-height: 1.6;
}

.modal-highlight {
    background: var(--bg-pearl);
    border-left: 3px solid var(--secondary-gold);
    padding: 16px;
    border-radius: 0 8px 8px 0;
    margin: 20px 0 !important;
    color: var(--primary-navy) !important;
    font-weight: 500;
}

.modal-wa-btn {
    margin-top: 16px;
    padding: 16px 28px;
    font-size: 1.1rem;
    gap: 10px;
}

.modal-sub {
    margin-top: 12px !important;
    font-size: 0.8rem !important;
    color: var(--text-light) !important;
}

/* Search active indicator on biens page */
.search-active-bar {
    background: white;
    border-radius: 8px;
    padding: 16px 24px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    box-shadow: var(--shadow-sm);
    border-left: 3px solid var(--secondary-gold);
}

.search-active-bar .search-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.search-active-bar .search-tag {
    background: var(--bg-pearl);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--primary-navy);
}

.search-active-bar .clear-search {
    color: var(--text-light);
    font-size: 0.875rem;
    cursor: pointer;
    text-decoration: underline;
    transition: color var(--transition-fast);
}

.search-active-bar .clear-search:hover {
    color: var(--primary-navy);
}

/* =========================================
   ARTICLE MODAL POPUP
   ========================================= */
.article-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 23, 42, 0.75);
    -webkit-backdrop-filter: blur(10px);
    backdrop-filter: blur(10px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.article-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.article-modal {
    position: relative;
    background: white;
    border-radius: 20px;
    max-width: 820px;
    width: 92%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.45);
    transform: translateY(40px) scale(0.95);
    opacity: 0;
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.4s ease;
}

.article-modal-overlay.active .article-modal {
    transform: translateY(0) scale(1);
    opacity: 1;
}

/* Scrollbar styling */
.article-modal::-webkit-scrollbar {
    width: 6px;
}

.article-modal::-webkit-scrollbar-track {
    background: transparent;
}

.article-modal::-webkit-scrollbar-thumb {
    background: #CBD5E1;
    border-radius: 3px;
}

.article-modal::-webkit-scrollbar-thumb:hover {
    background: #334155;
}

/* Close button */
.article-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    -webkit-backdrop-filter: blur(4px);
    backdrop-filter: blur(4px);
    border: none;
    border-radius: 50%;
    font-size: 1.75rem;
    line-height: 1;
    color: var(--primary-navy);
    cursor: pointer;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.article-modal-close:hover {
    background: white;
    transform: rotate(90deg) scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.15);
}

/* Header */
.article-modal-header {
    position: relative;
    height: 320px;
    overflow: hidden;
    border-radius: 20px 20px 0 0;
}

.article-modal-header img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.article-modal-header-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(15, 23, 42, 0) 0%,
        rgba(15, 23, 42, 0.3) 50%,
        rgba(15, 23, 42, 0.85) 100%
    );
}

.article-modal-header-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px 40px;
    z-index: 2;
}

.article-modal-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: var(--secondary-gold);
    color: var(--primary-navy);
    padding: 6px 16px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    z-index: 10;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.1);
}

.article-modal-title {
    font-family: var(--font-heading);
    color: white;
    font-size: 2rem;
    font-weight: 700;
    line-height: 1.2;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
}

/* Body */
.article-modal-body {
    padding: 40px;
}

.article-modal-body h3 {
    font-family: var(--font-heading);
    color: var(--primary-navy);
    font-size: 1.4rem;
    margin: 32px 0 16px;
    padding-bottom: 8px;
    border-bottom: 2px solid var(--secondary-gold);
    display: inline-block;
}

.article-modal-body h3:first-child {
    margin-top: 0;
}

.article-modal-body p {
    color: #475569;
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 16px;
}

.article-modal-body ul {
    list-style: none;
    padding: 0;
    margin: 16px 0 24px;
}

.article-modal-body ul li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 12px;
    color: #475569;
    font-size: 1rem;
    line-height: 1.6;
}

.article-modal-body ul li::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    width: 8px;
    height: 8px;
    background: var(--secondary-gold);
    border-radius: 50%;
}

.article-modal-body .article-highlight {
    background: linear-gradient(135deg, #F8FAFC 0%, #F1F5F9 100%);
    border-left: 4px solid var(--secondary-gold);
    padding: 20px 24px;
    border-radius: 0 12px 12px 0;
    margin: 24px 0;
    font-style: italic;
    color: var(--primary-navy);
    font-weight: 500;
}

.article-modal-body .article-info-box {
    background: linear-gradient(135deg, var(--primary-navy) 0%, #1E293B 100%);
    border-radius: 12px;
    padding: 24px;
    margin: 24px 0;
    color: white;
}

.article-modal-body .article-info-box h3 {
    color: var(--secondary-gold);
    font-family: var(--font-heading);
    font-size: 1.1rem;
    margin-bottom: 10px;
}

.article-modal-body .article-info-box p {
    color: #CBD5E1;
    margin-bottom: 0;
}

/* Footer */
.article-modal-footer {
    padding: 0 40px 40px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    border-top: 1px solid #E2E8F0;
    padding-top: 30px;
    margin: 0 40px;
    padding-left: 0;
    padding-right: 0;
}

.article-modal-cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 14px 32px;
    font-size: 1rem;
    width: 100%;
    justify-content: center;
}

.article-modal-close-btn {
    background: none;
    border: none;
    color: var(--text-light);
    font-family: var(--font-body);
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    padding: 8px 16px;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.article-modal-close-btn:hover {
    color: var(--primary-navy);
    background: var(--bg-pearl);
}

/* Guide card hover enhancement */
.guide-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: default;
}

.guide-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.1) !important;
}

.article-link {
    transition: gap 0.3s ease, color 0.3s ease !important;
}

.article-link:hover {
    gap: 10px !important;
    color: var(--secondary-gold) !important;
}

/* Responsive */
@media (max-width: 768px) {
    .article-modal {
        width: 100%;
        max-height: 100vh;
        border-radius: 0;
        height: 100vh;
    }

    .article-modal-header {
        height: 220px;
        border-radius: 0;
    }

    .article-modal-header-content {
        padding: 20px 24px;
    }

    .article-modal-title {
        font-size: 1.5rem;
    }

    .article-modal-body {
        padding: 24px;
    }

    .article-modal-body h3 {
        font-size: 1.2rem;
    }

    .article-modal-footer {
        padding: 0 24px 24px;
        margin: 0 24px;
    }

    .article-modal-close {
        top: 12px;
        right: 12px;
    }
}

/* Body no scroll when modal open */
body.article-modal-open {
    overflow: hidden;
}

/* --- Hero Animated Typography --- */
.hero-title-container {
    margin-bottom: 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.hero-fixed-title {
    font-family: 'Outfit', sans-serif;
    font-size: 3.5rem;
    font-weight: 700;
    color: white;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    line-height: 1.1;
    letter-spacing: -0.5px;
}

.hero-animated-text {
    position: relative;
    height: 8rem;
    width: 100%;
    overflow: hidden;
    display: flex;
    justify-content: center;
}

.animated-phrase {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    text-align: center;
    font-family: 'Playfair Display', serif;
    font-size: 1.8rem;
    font-weight: 400;
    color: var(--pearl);
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    opacity: 0;
    transform: translateY(30px);
    animation: slideFadeLoop 10.5s cubic-bezier(0.4, 0, 0.2, 1) infinite;
    filter: blur(4px);
    line-height: 1.4;
    padding: 0 20px;
}

.phrase-1 {
    animation-delay: 0s;
}

.phrase-2 {
    animation-delay: 3.5s;
}

.phrase-3 {
    animation-delay: 7s;
}

@keyframes slideFadeLoop {
    0%, 100% {
        opacity: 0;
        transform: translateY(30px);
        filter: blur(4px);
    }
    5%, 28% {
        opacity: 1;
        transform: translateY(0);
        filter: blur(0);
    }
    33%, 99% {
        opacity: 0;
        transform: translateY(-30px);
        filter: blur(4px);
    }
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .hero-fixed-title {
        font-size: 2.2rem;
    }
    .hero-animated-text {
        height: 7rem;
    }
    .animated-phrase {
        font-size: 1.4rem;
    }
}
@media (max-width: 480px) {
    .hero-fixed-title {
        font-size: 1.8rem;
    }
    .hero-animated-text {
        height: 6rem;
    }
    .animated-phrase {
        font-size: 1.2rem;
    }
}

/* =========================================
   MOBILE MENU OVERLAY
   ========================================= */
.mobile-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.92);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s ease, visibility 0.4s ease;
}

.mobile-menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-close {
    position: absolute;
    top: 20px;
    right: 24px;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    z-index: 10001;
    padding: 8px;
}

.mobile-menu-close i {
    width: 32px;
    height: 32px;
}

.mobile-nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.mobile-nav-list li a {
    font-family: var(--font-body);
    font-size: 1.5rem;
    font-weight: 600;
    color: white;
    text-decoration: none;
    transition: color 0.3s ease;
    letter-spacing: 0.02em;
}

.mobile-nav-list li a:hover {
    color: var(--secondary-gold);
}

.mobile-menu-cta {
    margin-top: 32px;
    display: flex;
    flex-direction: column;
    gap: 16px;
    align-items: center;
}

.mobile-menu-cta .btn {
    min-width: 220px;
    text-align: center;
    justify-content: center;
}

.mobile-menu-cta i {
    width: 16px;
    height: 16px;
}

/* =========================================
   RESPONSIVE: HEADER (Tablet & Mobile)
   ========================================= */
@media (max-width: 1024px) {
    .header-actions .btn-estimate {
        display: none;
    }
    .header-actions .btn-contact {
        display: none;
    }
    .nav-list {
        gap: 20px;
    }
}

@media (max-width: 768px) {
    :root {
        --header-height: 64px;
    }

    .main-header {
        height: var(--header-height);
    }

    .logo-link {
        height: 50%;
    }

    .header-actions .btn-estimate {
        display: none;
    }

    .header-actions .btn-contact {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex !important;
    }
}

/* =========================================
   RESPONSIVE: HERO SECTION
   ========================================= */
@media (max-width: 768px) {
    .hero {
        min-height: 100vh;
        padding-top: var(--header-height);
    }

    .hero-content {
        padding: 24px 16px;
    }

    .hero-subtitle {
        font-size: 0.75rem;
        letter-spacing: 0.15em;
        margin-bottom: 16px;
    }

    .search-widget {
        max-width: 100%;
        border-radius: 8px;
    }

    .search-form {
        padding: 16px;
        gap: 12px;
    }

    .search-submit {
        font-size: 1rem;
        padding: 14px 20px;
    }

    .tab-btn {
        font-size: 0.875rem;
        padding: 12px;
    }
}

/* =========================================
   RESPONSIVE: SECTIONS GENERAL
   ========================================= */
@media (max-width: 768px) {
    .section {
        padding: 48px 0;
    }

    .section-title {
        font-size: 1.75rem;
    }

    .section-subtitle {
        font-size: 1rem;
    }

    .section-header {
        margin-bottom: 32px;
    }
}

@media (max-width: 480px) {
    .section {
        padding: 36px 0;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .container {
        padding: 0 16px;
    }
}

/* =========================================
   RESPONSIVE: SERVICES SECTION
   ========================================= */
@media (max-width: 768px) {
    .services-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .service-card {
        padding: 24px 20px;
    }

    .service-card h3 {
        font-size: 1.25rem;
    }
}

/* =========================================
   RESPONSIVE: LISTINGS SECTION
   ========================================= */
@media (max-width: 768px) {
    .listings-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .property-image {
        height: 200px;
    }

    .property-content {
        padding: 20px;
    }

    .property-title {
        font-size: 1.125rem;
    }

    .property-price {
        font-size: 1.5rem;
    }

    .property-features {
        flex-wrap: wrap;
        gap: 8px;
    }

    .property-features span {
        font-size: 0.8rem;
    }

    .property-footer {
        padding: 0 20px 20px;
    }
}

/* =========================================
   RESPONSIVE: GUIDES SECTION
   ========================================= */
@media (max-width: 768px) {
    .guides-grid {
        grid-template-columns: 1fr !important;
        gap: 20px !important;
    }
}

/* =========================================
   RESPONSIVE: ASSISTANT SECTION
   ========================================= */
@media (max-width: 768px) {
    .assistant-wrapper {
        gap: 32px;
    }

    .assistant-content h2 {
        font-size: 1.75rem;
    }

    .assistant-content p {
        font-size: 1rem;
    }

    .assistant-form-container {
        padding: 24px;
        min-height: 260px;
    }

    .form-step h3 {
        font-size: 1.125rem;
        margin-bottom: 16px;
    }

    .option-btn {
        padding: 14px;
        font-size: 0.9rem;
    }
}

/* =========================================
   RESPONSIVE: TRUST SECTION
   ========================================= */
@media (max-width: 768px) {
    .trust-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
    }

    .trust-metric {
        padding: 16px;
    }

    .metric-number {
        font-size: 2.5rem;
    }

    .metric-label {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .trust-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .metric-number {
        font-size: 2.25rem;
    }
}

/* =========================================
   RESPONSIVE: FOOTER
   ========================================= */
@media (max-width: 768px) {
    .main-footer {
        padding: 48px 0 24px;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 32px;
        margin-bottom: 32px;
    }

    .brand-col p {
        max-width: 100%;
    }

    .footer-col h3 {
        font-size: 1.125rem;
        margin-bottom: 16px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
        gap: 12px;
    }

    .legal-links {
        justify-content: center;
    }
}

/* =========================================
   RESPONSIVE: PAGE HEADERS (Sub-pages)
   ========================================= */
@media (max-width: 768px) {
    .page-header {
        padding: 90px 0 30px !important;
    }

    .page-header h1 {
        font-size: 1.75rem !important;
        line-height: 1.2;
    }

    .page-header p {
        font-size: 1rem !important;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.5rem !important;
    }
}

/* =========================================
   RESPONSIVE: FILTER BUTTONS (Sub-pages)
   ========================================= */
@media (max-width: 768px) {
    .filter-container {
        gap: 8px !important;
    }

    .filter-btn {
        padding: 8px 16px !important;
        font-size: 0.85rem !important;
    }
}

/* =========================================
   RESPONSIVE: CONTACT MODAL
   ========================================= */
@media (max-width: 480px) {
    .contact-info-block {
        padding: 16px;
    }

    .contact-info-item {
        font-size: 0.85rem;
    }

    .contact-form-group input,
    .contact-form-group textarea {
        padding: 12px 14px;
        font-size: 0.9rem;
    }
}

.center-action {
    display: flex;
    justify-content: center;
    margin-top: 48px;
    width: 100%;
}

@media (max-width: 768px) {
    .center-action {
        margin-top: 24px !important;
    }

    .center-action .btn {
        width: 100%;
        max-width: 320px;
    }
}

.autre-loc-input {
    display: none;
    position: absolute;
    margin-top: 60px;
    z-index: 10;
    padding: 8px;
    border: 1px solid #E2E8F0;
    border-radius: 4px;
    font-family: var(--font-body);
    font-size: 0.875rem;
    width: 100%;
    box-sizing: border-box;
    background: white;
    box-shadow: var(--shadow-sm);
}

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

.guide-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    border: 1px solid var(--bg-pearl);
    transition: var(--transition-smooth);
    display: flex;
    flex-direction: column;
}

.guide-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
}

.guide-content {
    padding: 30px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.guide-content p {
    flex: 1;
    margin-bottom: 24px;
}

.guide-content span {
    color: var(--secondary-gold);
    font-family: var(--font-body);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
}

.guide-content h3 {
    font-family: var(--font-heading);
    color: var(--primary-navy);
    font-size: 1.5rem;
    margin: 10px 0;
}

.guide-content p {
    color: #334155;
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.success-checkmark i {
    width: 32px;
    height: 32px;
}

.contact-modal-header {
    height: 200px;
    background: linear-gradient(135deg, var(--primary-navy) 0%, #1E293B 100%);
    position: relative;
    overflow: hidden;
}

.contact-modal-header-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 30px 40px;
    z-index: 2;
}

.contact-modal-title {
    color: white;
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-top: 10px;
}

.contact-info-item i {
    width: 20px;
    height: 20px;
    color: var(--secondary-gold);
    flex-shrink: 0;
}

.contact-form-group label i {
    width: 16px;
    height: 16px;
}

.contact-submit-btn i {
    width: 18px;
    height: 18px;
}

.expertise-modal-overlay {
    background: linear-gradient(135deg, var(--primary-navy) 0%, #1E293B 100%);
    opacity: 0.9;
}

#noResultsModal {
    display: none;
}

/* =========================================
   CURRENCY SELECTOR
   ========================================= */
.currency-selector {
    background-color: transparent;
    color: var(--primary-navy);
    border: 1px solid rgba(15, 23, 42, 0.2);
    border-radius: 4px;
    padding: 8px 12px;
    font-family: var(--font-body);
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    outline: none;
    transition: all var(--transition-fast);
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url('data:image/svg+xml;utf8,<svg fill="%230F172A" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/><path d="M0 0h24v24H0z" fill="none"/></svg>');
    background-repeat: no-repeat;
    background-position-x: 100%;
    background-position-y: 5px;
    padding-right: 28px;
}

.currency-selector:hover, .currency-selector:focus {
    border-color: var(--secondary-gold);
    box-shadow: 0 0 0 2px rgba(212, 175, 55, 0.2);
}

.currency-selector option {
    background-color: white;
    color: var(--primary-navy);
}

/* =========================================
   MAP SECTION (Leaflet)
   ========================================= */
.map-section {
    padding: 80px 0;
}

.map-container {
    height: 600px;
    width: 100%;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.1);
    border: 1px solid var(--secondary-gold);
}

#map {
    height: 100%;
    width: 100%;
    z-index: 1;
}

/* POI Filters */
.poi-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 24px;
    justify-content: center;
}

.poi-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    background: white;
    border: 1px solid #CBD5E1;
    border-radius: 30px;
    color: var(--primary-navy);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.poi-btn i {
    width: 18px;
    height: 18px;
    color: #334155;
    transition: color 0.3s ease;
}

.poi-btn:hover {
    border-color: var(--secondary-gold);
    box-shadow: 0 4px 6px rgba(212, 175, 55, 0.15);
}

.poi-btn.active {
    background: var(--primary-navy);
    color: white;
    border-color: var(--primary-navy);
}

.poi-btn.active i {
    color: var(--secondary-gold);
}

/* Leaflet Custom Popups for Pyrite */
.leaflet-popup-content-wrapper {
    background: var(--primary-navy) !important;
    color: white !important;
    border-radius: 12px !important;
    padding: 0 !important;
    overflow: hidden;
    box-shadow: 0 15px 30px rgba(0,0,0,0.3) !important;
    border: 1px solid var(--secondary-gold);
}

.leaflet-popup-tip {
    background: var(--secondary-gold) !important;
}

.leaflet-popup-content {
    margin: 0 !important;
    width: 260px !important;
}

.popup-custom-card {
    display: flex;
    flex-direction: column;
}

.popup-img-container {
    height: 140px;
    width: 100%;
    overflow: hidden;
    position: relative;
}

.popup-img-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.popup-img-container:hover img {
    transform: scale(1.1);
}

.popup-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--secondary-gold);
    color: var(--primary-navy);
    font-size: 0.7rem;
    font-weight: bold;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.popup-details {
    padding: 16px;
}

.popup-title {
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 700;
    color: white;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.popup-price {
    color: var(--secondary-gold);
    font-weight: 700;
    font-size: 1rem;
    margin-bottom: 12px;
}

.popup-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: rgba(255,255,255,0.1);
    color: white;
    padding: 8px 0;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.2);
}

.popup-btn:hover {
    background: var(--secondary-gold);
    color: var(--primary-navy);
    border-color: var(--secondary-gold);
}

/* =========================================
   Testimonials & Case Studies Section
   ========================================= */

.testimonials-section {
    padding: 100px 0;
    background-color: var(--bg-pearl);
    position: relative;
}

.testimonials-header {
    text-align: center;
    margin-bottom: 60px;
}

.trust-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    padding: 8px 16px;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-navy);
    margin-bottom: 24px;
    border: 1px solid rgba(212, 175, 55, 0.2);
}

.trust-badge i {
    color: var(--secondary-gold);
}

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

.testimonial-card {
    background: white;
    padding: 40px 30px;
    border-radius: 16px;
    box-shadow: 0 10px 30px -10px rgba(15, 23, 42, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-top: 4px solid var(--secondary-gold);
    display: flex;
    flex-direction: column;
}

.testimonial-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(15, 23, 42, 0.12);
}

.rating-stars {
    display: flex;
    gap: 4px;
    color: var(--secondary-gold);
    margin-bottom: 20px;
}

.rating-stars i {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.testimonial-quote {
    font-family: var(--font-heading);
    font-size: 1.25rem;
    color: var(--primary-navy);
    line-height: 1.4;
    margin-bottom: 16px;
    font-style: italic;
}

.testimonial-text {
    color: #475569;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 30px;
    flex-grow: 1;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 16px;
    border-top: 1px solid #E2E8F0;
    padding-top: 20px;
}

.author-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--primary-navy);
    color: var(--secondary-gold);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-weight: 700;
    font-size: 1.2rem;
}

.author-info h3 {
    margin: 0;
    font-size: 1rem;
    color: var(--primary-navy);
}

.author-info span {
    font-size: 0.85rem;
    color: #334155;
}

/* Case Studies Block */
.case-studies-block {
    background: var(--primary-navy);
    border-radius: 20px;
    padding: 40px;
    margin-bottom: 60px;
    color: white;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    position: relative;
    overflow: hidden;
}

.case-studies-block::before {
    content: '';
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(135deg, rgba(212, 175, 55, 0.1) 0%, transparent 100%);
    pointer-events: none;
}

.case-study {
    position: relative;
    z-index: 1;
}

.case-study-label {
    display: inline-block;
    background: rgba(212, 175, 55, 0.15);
    color: var(--secondary-gold);
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.case-study h3 {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: white;
}

.case-study p {
    color: #CBD5E1;
    margin-bottom: 20px;
    font-size: 1rem;
}

.case-study-metric {
    display: flex;
    align-items: baseline;
    gap: 12px;
}

.metric-value {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    color: var(--secondary-gold);
    font-weight: 700;
}

.metric-desc {
    color: #334155;
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    .case-studies-block {
        grid-template-columns: 1fr;
        gap: 30px;
        padding: 30px 20px;
    }
}

/* =========================================
   MARQUEE STRIP
   ========================================= */
.marquee-strip {
    width: 100%;
    overflow: hidden;
    background: #0F172A;
    border-top: 1px solid rgba(212, 175, 55, 0.3);
    border-bottom: 1px solid rgba(212, 175, 55, 0.3);
    padding: 12px 0;
    display: flex;
    align-items: center;
}

.marquee-content {
    display: flex;
    white-space: nowrap;
    animation: marquee-scroll 25s linear infinite;
    will-change: transform;
}

.marquee-content:hover {
    animation-play-state: paused;
}

.marquee-content span {
    font-family: var(--font-serif, serif);
    font-size: 0.85rem;
    letter-spacing: 0.15em;
    color: #D4AF37;
    text-transform: uppercase;
    font-weight: 500;
    display: inline-block;
    padding-right: 0.5em; /* Small space before the next span */
}

@keyframes marquee-scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* =========================================
   GOLD CREST DIVIDER
   ========================================= */
.gold-crest-divider {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 1280px;
    margin: 1.5rem auto 0 auto !important;
    padding: 0 !important;
    gap: 1rem;
}

.crest-line {
    flex: 1;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(212, 175, 55, 0.35), transparent);
}

.crest-symbol {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid rgba(212, 175, 55, 0.5);
    background: #FFFFFF;
    flex-shrink: 0;
}

/* =========================================
   SERVICES WATERMARK
   ========================================= */
.services-section {
    position: relative;
    overflow: hidden;
}

.services-corner-watermark {
    position: absolute;
    top: -20px;
    right: -20px;
    width: 280px;
    height: 280px;
    opacity: 0.04;
    pointer-events: none;
    z-index: 0;
    color: #D4AF37;
}

.services-section .container {
    position: relative;
    z-index: 1; /* Keep content above watermark */
}

@media (max-width: 768px) {
    .services-corner-watermark {
        width: 180px;
        height: 180px;
        top: -10px;
        right: -10px;
        opacity: 0.03;
    }
}

#services {
    display: block !important;
    min-height: auto !important;
    position: relative !important;
    background-color: #F8FAFC !important;
    background-image: url("data:image/svg+xml,%3Csvg width='80' height='80' viewBox='0 0 80 80' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='%23D4AF37' fill-opacity='0.05' fill-rule='evenodd'%3E%3Cpath d='M0 0h80v80H0V0zm40 10l8.5 11.5L60 20l-3 14 11.5 8.5L60 51l3 14-11.5-1.5L40 75l-11.5-11.5L17 65l3-14-11.5-8.5L20 34l-3-14 11.5 1.5L40 10z'/%3E%3C/g%3E%3C/svg%3E") !important;
    background-repeat: repeat !important;
    background-size: 80px 80px !important;
    margin-top: 0 !important;
    padding-top: 30px !important;
    padding-bottom: 60px !important;
}

#services > * {
    position: relative;
    z-index: 1;
}

#services .container {
    max-width: 1280px !important;
    margin: 0 auto !important;
    padding: 0 20px !important;
    width: 100% !important;
    position: relative;
    z-index: 1;
}

#services .section-header {
    text-align: center !important;
    margin-top: 0 !important;
    margin-bottom: 30px !important;
    padding-top: 0 !important;
    position: relative;
    z-index: 2;
}

#services .section-header h2 {
    margin-top: 0 !important;
    margin-bottom: 8px !important;
}

#services .section-header p {
    margin-bottom: 0 !important;
}

#services .services-grid {
    display: grid !important;
    grid-template-columns: repeat(5, 1fr) !important;
    gap: 18px !important;
    width: 100% !important;
    margin-top: 0 !important;
    margin-bottom: 0 !important;
    position: relative;
    z-index: 2;
}

@media (max-width: 1200px) {
    #services .services-grid {
        grid-template-columns: repeat(3, 1fr) !important;
    }
}

@media (max-width: 768px) {
    #services .services-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

@media (max-width: 640px) {
    #services .services-grid {
        grid-template-columns: repeat(1, 1fr) !important;
    }
}


/* =========================================
   ESTIMATION FORM FIELDS (ETAPE 3)
   ========================================= */
#est-quartier {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23D4AF37' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px !important;
}

.form-input, #est-quartier, #est-surface, #est-chambres, #est-quartier-custom {
    width: 100% !important;
    padding: 12px 16px !important;
    border-radius: 12px !important;
    border: 1px solid #CBD5E1 !important;
    background-color: #FFFFFF !important;
    font-size: 0.95rem !important;
    color: #0F172A !important;
    transition: all 0.2s ease !important;
    box-sizing: border-box !important;
}

.form-input:focus, #est-quartier:focus, #est-surface:focus, #est-chambres:focus, #est-quartier-custom:focus {
    border-color: #D4AF37 !important;
    box-shadow: 0 0 0 3px rgba(212, 175, 55, 0.2) !important;
    outline: none !important;
}



/* =========================================
   ESTIMATION FORM SUBMIT BUTTON
   ========================================= */
#est-step4 button.btn-primary, #est-step4 .btn-primary {
    background-color: #D4AF37 !important;
    color: #0F172A !important;
    border: 1px solid #D4AF37 !important;
    border-radius: 12px !important;
    padding: 12px 24px !important;
    font-weight: 600 !important;
    font-size: 0.95rem !important;
    white-space: nowrap !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    cursor: pointer !important;
    transition: all 0.2s ease !important;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.25) !important;
}

#est-step4 button.btn-primary:hover, #est-step4 .btn-primary:hover {
    background-color: #C5A028 !important;
    border-color: #C5A028 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px rgba(212, 175, 55, 0.35) !important;
}

/* =========================================
   CATEGORY TABS AND FILTER BUTTONS
   ========================================= */
.filter-btn, .category-tab, .filter-tabs button, .listings-filter-btn {
    font-size: 0.95rem !important;
    font-weight: 500 !important;
    color: #475569 !important; /* Gris foncé lisible pour les onglets inactifs */
    background: transparent !important;
    border: none !important;
    border-bottom: 3px solid transparent !important;
    padding: 10px 18px !important;
    cursor: pointer !important;
    transition: all 0.25s ease !important;
    white-space: nowrap !important;
}

.filter-btn.active, .category-tab.active, .filter-tabs button.active, .listings-filter-btn.active {
    color: #0F172A !important; /* Bleu nuit foncé parfaitement lisible sur fond blanc */
    font-weight: 700 !important; /* Texte en gras */
    border-bottom: 3px solid #D4AF37 !important; /* Ligne d'accentuation dorée */
}

.filter-btn:hover, .category-tab:hover, .filter-tabs button:hover, .listings-filter-btn:hover {
    color: #0F172A !important;
}

.filter-container, .filter-tabs {
    display: flex !important;
    overflow-x: auto !important;
    padding-bottom: 8px !important;
    -webkit-overflow-scrolling: touch !important;
    scrollbar-width: none !important; /* Firefox */
    -ms-overflow-style: none !important; /* IE and Edge */
}

.filter-container::-webkit-scrollbar, .filter-tabs::-webkit-scrollbar {
    display: none !important; /* Chrome, Safari and Opera */
}

/* =========================================
   SERVICE CARDS ALIGNMENT (Flexbox)
   ========================================= */
.service-card {
    display: flex !important;
    flex-direction: column !important;
    justify-content: space-between !important;
    height: 100% !important;
    min-height: 260px !important;
    padding: 1.5rem !important;
}

.service-card p {
    flex-grow: 1 !important;
    margin-bottom: 1.25rem !important;
}

.service-card .service-link {
    margin-top: auto !important;
    white-space: nowrap !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    color: #0F172A !important;
    padding-top: 0.75rem !important;
    border-top: 1px solid #F1F5F9 !important;
}

.service-card .service-link i, .service-card .service-link svg {
    margin-left: 8px !important;
    transition: transform 0.2s ease !important;
}

.service-card .service-link:hover i, .service-card .service-link:hover svg {
    transform: translateX(4px) !important;
}

/* =========================================
   MODALS FIXES (Header & Global)
   ========================================= */
.article-modal-header-content, .contact-modal-header-content {
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 0.5rem !important;
    padding-top: 1rem !important;
}
.article-modal-badge {
    position: static !important; /* Supprime le chevauchement absolu */
    display: inline-block !important;
    margin-bottom: 0.5rem !important;
    align-self: flex-start !important;
}
.article-modal-title, .contact-modal-title {
    margin-top: 0 !important;
    line-height: 1.25 !important;
    position: relative !important;
    z-index: 1 !important;
}

.article-modal {
    max-height: 88vh !important;
    overflow-y: auto !important;
}

.article-modal-close {
    position: absolute !important;
    top: 1rem !important;
    right: 1rem !important;
    z-index: 20 !important;
    background: rgba(15,23,42,0.1) !important;
    border-radius: 50% !important;
    padding: 6px !important;
    cursor: pointer !important;
}

.article-modal-overlay {
    backdrop-filter: blur(8px) !important;
    background: rgba(15, 23, 42, 0.75) !important;
}

/* =========================================
   SECTION HEADERS ALIGNMENT (Global Centering)
   ========================================= */
.section-header {
    text-align: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    margin-bottom: 2.5rem !important;
}

.section-title, .section-subtitle {
    text-align: center !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* =========================================
   BUTTONS LUXURY HOVER EFFECTS
   ========================================= */
.btn-primary, .btn-secondary {
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

.btn-primary:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 20px -4px rgba(212, 175, 55, 0.4) !important;
}

.btn-secondary:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 20px -4px rgba(15, 23, 42, 0.4) !important;
}


/* =========================================
   SEARCH WIDGET — MASQUAGE FORMULAIRES
   ========================================= */
.search-form {
    display: none !important;
}

.search-form.active {
    display: flex !important;
}

/* === DESKTOP (≥ 992px) === */
@media (min-width: 992px) {
    .search-widget {
        max-width: 1150px !important;
        width: 100% !important;
        margin: 2rem auto 0 auto !important;
        background: #FFFFFF !important;
        border-radius: 16px !important;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15) !important;
        overflow: hidden !important;
    }

    .search-form.active {
        display: flex !important;
        flex-direction: row !important;
        align-items: center !important;
        justify-content: space-between !important;
        padding: 1.25rem 1.5rem !important;
        gap: 1.25rem !important;
        width: 100% !important;
        box-sizing: border-box !important;
    }

    .search-form .form-group {
        flex: 1 !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        min-width: 0 !important;
    }

    .search-form label {
        display: inline-flex !important;
        align-items: center !important;
        gap: 0.5rem !important;
        white-space: nowrap !important;
        font-size: 0.85rem !important;
        color: #334155 !important;
        font-weight: 500 !important;
        margin-bottom: 0.25rem !important;
    }

    .search-form select {
        width: 100% !important;
        font-size: 0.95rem !important;
        font-weight: 700 !important;
        color: #0F172A !important;
        white-space: nowrap !important;
        text-overflow: ellipsis !important;
        overflow: hidden !important;
        border: none !important;
        background: transparent !important;
        cursor: pointer !important;
        padding: 0 !important;
    }

    .form-divider {
        width: 1px !important;
        height: 38px !important;
        background-color: #E2E8F0 !important;
        flex-shrink: 0 !important;
        align-self: center !important;
    }

    .search-submit {
        flex-shrink: 0 !important;
        white-space: nowrap !important;
        padding: 14px 24px !important;
        font-size: 0.95rem !important;
        font-weight: 600 !important;
        border-radius: 12px !important;
    }
}

/* === MOBILE (≤ 991px) === */
@media (max-width: 991px) {
    .search-form.active {
        display: flex !important;
        flex-direction: column !important;
        gap: 1rem !important;
        padding: 1.25rem !important;
    }

    .form-divider {
        display: none !important;
    }

    .search-submit {
        width: 100% !important;
    }
}

/* =============================================================================
   OPTIMISATIONS RENDU MOBILE — CORE WEB VITALS / PAGESPEED
   Appliqué en dessous de la ligne de flottaison pour accélérer FCP & LCP.
   content-visibility: auto → le navigateur ignore le calcul de layout/paint
   des sections hors-écran au premier rendu, libérant le thread principal.
   contain-intrinsic-size → réserve un espace de place-holder stable (pas de CLS).
   Source : web.dev/articles/content-visibility
============================================================================= */

/* font-display: swap — garantit que le texte reste visible pendant le chargement
   des polices (FOUT acceptable, pas de FOIT bloquant).
   Note : déjà actif via &display=swap dans l'URL Google Fonts.
   Déclaration explicite pour tout @font-face local éventuel. */
@font-face {
    font-display: swap;
}

/* Sections sous la ligne de flottaison — rendu différé sur mobile */
.listings-section,
.map-section,
.estimation-section,
.services-section,
.guides-section,
.trust-section,
.testimonials-section,
.main-footer {
    content-visibility: auto;
    contain-intrinsic-size: 1px 800px;
}
