﻿@charset "UTF-8";
/*
Theme Name: Imoveis POA
Theme URI: https://imoveispoa.com
Author: Imoveis POA
Author URI: https://imoveispoa.com
Description: Tema premium para imobiliaria de alto padrao em Porto Alegre. Inclui gerenciamento de imoveis, filtros avancados, mapa interativo e landing pages.
Version: 1.1.3
Requires at least: 6.0
Tested up to: 6.9
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: casanilo
Tags: real-estate, custom-colors, custom-logo, featured-images, full-width-template, theme-options, translation-ready

Imoveis POA - Imoveis de Alto Padrao
*/

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;500;600&family=Lato:wght@300;400;500;600&display=swap');

/* ==========================================================================
   CSS Variables
   ========================================================================== */
:root {
    --primary: #1a1a1a;
    --secondary: #2d2d2d;
    --accent: #c9a962;
    --accent-light: #d4b978;
    --accent-dark: #a68b4a;
    --accent-glow: rgba(201, 169, 98, 0.25);
    --accent-shimmer: rgba(212, 185, 120, 0.4);
    --text: #ffffff;
    --text-muted: #a0a0a0;
    --bg-dark: #0d0d0d;
    --bg-elevated: #141414;
    --card-bg: #1a1a1a;
    /* Altura da navbar para sticky (filtros, cabecalho de resultados, mapa) */
    --navbar-height: 80px;
    --border-color: rgba(255, 255, 255, 0.06);
    --border-gold: rgba(201, 169, 98, 0.15);
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.25);
    --shadow-gold: 0 8px 32px rgba(201, 169, 98, 0.15);
    --shadow-card-hover: 0 20px 50px rgba(0, 0, 0, 0.5), 0 0 40px rgba(201, 169, 98, 0.1);
    --mask-color: #0d0d0d;
    --transition-premium: cubic-bezier(0.4, 0, 0.2, 1);
    scroll-behavior: smooth;
}

/* ==========================================================================
   LIGHT THEME - PREMIUM ELEGANCE (Reference Implementation)
   ========================================================================== */
[data-theme="light"] {
    /* Dourados Sofisticados (Champagne/Old Gold) */
    --accent: #B08D55;
    /* Slightly darker for better contrast on light bg */
    --accent-light: #C5A059;
    --accent-dark: #8A6E3E;
    --price-gold-dark: #7A5A2A;
    --card-shadow-elegant: 0 16px 36px rgba(38, 28, 14, 0.22), 0 4px 12px rgba(0, 0, 0, 0.11), 0 0 0 1px rgba(176, 141, 85, 0.2);
    --card-shadow-elegant-hover: 0 26px 54px rgba(38, 28, 14, 0.3), 0 10px 24px rgba(0, 0, 0, 0.16), 0 0 0 1px rgba(176, 141, 85, 0.3);
    --accent-glow: rgba(176, 141, 85, 0.15);
    --accent-shimmer: rgba(197, 160, 89, 0.25);
    --gold-shimmer: rgba(176, 141, 85, 0.1);

    /* Fundos Premium - Suavizados */
    --primary: #FDFDFD;
    /* Cleaner white */
    --secondary: #F2F2F2;
    /* Soft grey */
    --bg-dark: #ffffff;
    --bg-elevated: #F7F7F7;
    --card-bg: #ffffff;

    /* Textos Elegantes - Contraste Aumentado */
    --text: #1a1a1a;
    /* Almost black for sharpness */
    --text-muted: #555555;
    /* Darker grey for readability */
    --text-light: #777777;

    /* Bordas Refinadas & Suaves */
    --border-color: #E2E2E2;
    --border-medium: #D1D1D1;
    --border-gold: rgba(176, 141, 85, 0.25);

    /* Sombras Elegantes & Difusas */
    --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.05);
    /* Softer, larger spread */
    --shadow-md: 0 10px 40px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 15px 60px rgba(0, 0, 0, 0.12);
    --shadow-gold: rgba(176, 141, 85, 0.15);
    --mask-color: #ffffff;
}

/* Light Theme Overrides - Softness & Clarity */
[data-theme="light"] .btn,
[data-theme="light"] .btn-primary,
[data-theme="light"] .search-button,
[data-theme="light"] .apply-filters-btn,
[data-theme="light"] .quick-search {
    border-radius: 12px !important;
}

[data-theme="light"] .property-card {
    border-radius: 24px !important;
    /* Extra soft */
}

[data-theme="light"] input,
[data-theme="light"] select,
[data-theme="light"] .custom-multiselect .select-trigger {
    border-radius: 12px !important;
}

[data-theme="light"] .filters-sidebar {
    border-radius: 16px !important;
}

[data-theme="light"] .transaction-tab {
    border-radius: 50px !important;
    /* Pill shape */
}

[data-theme="light"] .page-btn {
    border-radius: 12px !important;
}

[data-theme="light"] .filter-checkbox {
    border-radius: 5px !important;
    /* Softer square */
}

[data-theme="light"] .select-dropdown {
    border-radius: 12px !important;
}

/* Clarity & Legibility */
[data-theme="light"] body {
    font-weight: 500 !important;
    /* Slightly heavier base font */
}

[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] h5 {
    color: #000000 !important;
    font-weight: 600 !important;
}

[data-theme="light"] .text-muted,
[data-theme="light"] .property-location,
[data-theme="light"] .feature-item {
    color: #444444 !important;
    font-weight: 500 !important;
}

/* Light Theme overrides for Rounded Corners & Softness */
[data-theme="light"] .btn,
[data-theme="light"] .btn-primary,
[data-theme="light"] .search-button,
[data-theme="light"] .apply-filters-btn {
    border-radius: 8px !important;
}

[data-theme="light"] .property-card {
    border-radius: 20px !important;
    /* Mais arredondado */
}

[data-theme="light"] input,
[data-theme="light"] select,
[data-theme="light"] .custom-multiselect .select-trigger {
    border-radius: 8px !important;
}

[data-theme="light"] .filters-sidebar {
    border-radius: 12px !important;
}

/* ============================================
   LIGHT MODE - COMPLETE OVERRIDE
   ============================================ */

/* Global Background & Text */
[data-theme="light"],
[data-theme="light"] html,
[data-theme="light"] body {
    background-color: var(--bg-dark) !important;
    color: var(--text) !important;
}

/* ===== NAVBAR ELEGANTE ===== */
[data-theme="light"] .navbar {
    background: var(--bg-dark) !important;
    border-bottom: 1px solid var(--border-color) !important;
    box-shadow: var(--shadow-soft) !important;
}

[data-theme="light"] .navbar a,
[data-theme="light"] .nav-menu a,
[data-theme="light"] .nav-menu li a {
    color: #1C1C1C !important;
}

/* Nav Menu Links - Gradient Underline */
[data-theme="light"] .nav-menu a:hover,
[data-theme="light"] .nav-menu a:focus {
    color: var(--accent-dark) !important;
}

[data-theme="light"] .nav-menu a::after {
    background: linear-gradient(90deg, var(--accent), transparent) !important;
}

[data-theme="light"] .nav-menu a:hover,
[data-theme="light"] .nav-menu a:focus {
    color: var(--accent-dark) !important;
}

[data-theme="light"] .navbar .logo span {
    color: var(--text) !important;
    font-weight: 600;
}

[data-theme="light"] .logo {
    color: var(--accent-dark) !important;
}

/* ===== HERO - LIGHT/BEIGE BASE ===== */
[data-theme="light"] .hero {
    background: linear-gradient(135deg, rgba(245, 236, 220, 0.92), rgba(236, 224, 199, 0.88)),
        url('assets/images/hero-bg.jpg') center/cover no-repeat !important;
}

[data-theme="light"] .hero-title {
    color: #2b2217 !important;
}

[data-theme="light"] .hero-title span {
    color: var(--accent) !important;
}

[data-theme="light"] .hero-subtitle {
    color: #3f3122 !important;
    text-shadow: none;
}

[data-theme="light"] .hero-tagline {
    color: #4a3926 !important;
    text-shadow: none !important;
}

[data-theme="light"] .hero-badge {
    background: rgba(184, 150, 98, 0.16) !important;
    border-color: rgba(143, 106, 51, 0.42) !important;
    color: #8f6a33 !important;
}

/* Light panel (no glass-dark fallback). */
[data-theme="light"] .hero-content {
    background: linear-gradient(160deg, rgba(251, 244, 232, 0.95), rgba(241, 229, 203, 0.9)) !important;
    backdrop-filter: blur(6px) !important;
    -webkit-backdrop-filter: blur(6px) !important;
    border: 1px solid rgba(138, 102, 47, 0.34) !important;
    box-shadow: 0 14px 28px rgba(61, 43, 20, 0.16) !important;
    max-width: 850px !important;
    padding: 1.5rem 2rem !important;
    margin: 0 auto !important;
}

/* Navbar Logo Fix */
[data-theme="light"] .navbar .logo {
    color: var(--accent-dark) !important;
}

[data-theme="light"] .navbar .logo span {
    color: var(--text) !important;
}

/* Light Mode Search - Glassmorphism */
[data-theme="light"] .quick-search {
    background: linear-gradient(160deg, rgba(251, 244, 232, 0.95), rgba(241, 229, 203, 0.9)) !important;
    border: 1px solid rgba(138, 102, 47, 0.34) !important;
    backdrop-filter: blur(6px) !important;
    box-shadow: 0 14px 28px rgba(61, 43, 20, 0.16) !important;
}

[data-theme="light"] .quick-search input {
    color: #2a2116 !important;
}

[data-theme="light"] .quick-search input::placeholder {
    color: #765d3c !important;
}

/* ===== MAIN CONTENT ===== */
[data-theme="light"] .main-content,
[data-theme="light"] .results-area,
[data-theme="light"] .main-grid,
[data-theme="light"] .main-container {
    background: var(--bg-dark) !important;
}

/* ===== FILTERS SIDEBAR ELEGANTE ===== */
[data-theme="light"] .filters-sidebar,
[data-theme="light"] .filters-sticky-wrapper .filters-sidebar {
    background: var(--card-bg) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: var(--shadow-soft) !important;
}

[data-theme="light"] .filters-header {
    border-bottom: 1px solid var(--border-color) !important;
}

[data-theme="light"] .filters-title,
[data-theme="light"] .filter-group-title {
    color: var(--accent-dark) !important;
    font-weight: 600 !important;
}

[data-theme="light"] .filter-group {
    border-bottom: 1px solid var(--border-color) !important;
}

[data-theme="light"] .filter-label {
    color: var(--text) !important;
}

/* Filter Controls */
[data-theme="light"] .select-trigger,
[data-theme="light"] .custom-multiselect .select-trigger {
    background: var(--primary) !important;
    /* bg-secondary */
    border: 1px solid var(--border-color) !important;
    color: var(--text) !important;
}

[data-theme="light"] .select-trigger:hover,
[data-theme="light"] .select-trigger:focus {
    border-color: var(--accent) !important;
    box-shadow: 0 0 0 3px var(--gold-shimmer) !important;
}

[data-theme="light"] .select-options,
[data-theme="light"] .multiselect-options {
    background: var(--card-bg) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: var(--shadow-md) !important;
}

[data-theme="light"] .filter-checkbox+label,
[data-theme="light"] .checkbox-label {
    color: var(--secondary) !important;
}

[data-theme="light"] #clearFilters,
[data-theme="light"] .clear-filters {
    color: var(--text-light) !important;
    font-weight: 600 !important;
}

[data-theme="light"] #clearFilters:hover,
[data-theme="light"] .clear-filters:hover {
    color: var(--accent-dark) !important;
    letter-spacing: 1.5px !important;
}

/* ===== RESULTS HEADER ===== */
[data-theme="light"] .results-header {
    background: var(--primary) !important;
    border: 1px solid var(--border-color) !important;
    color: var(--text-muted) !important;
}

[data-theme="light"] .results-count {
    color: var(--accent-dark) !important;
    font-weight: 800 !important;
}

/* ===== PROPERTY CARDS ELEGANTES ===== */
[data-theme="light"] .property-card {
    background: var(--card-bg) !important;
    border: 1px solid var(--border-color) !important;
    box-shadow: var(--shadow-soft) !important;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1) !important;
}

[data-theme="light"] .property-card:hover {
    border-color: var(--border-gold) !important;
    box-shadow: var(--shadow-lg), 0 20px 40px var(--shadow-gold) !important;
    transform: translateY(-5px) !important;
}

[data-theme="light"] .property-title {
    color: var(--text) !important;
}

[data-theme="light"] .property-location {
    color: var(--text-muted) !important;
}

[data-theme="light"] .property-location::before {
    color: var(--accent) !important;
}

[data-theme="light"] .property-price {
    color: var(--price-gold-dark) !important;
    font-weight: 600 !important;
}

[data-theme="light"] .property-features,
[data-theme="light"] .feature-item {
    color: var(--text-light) !important;
}

[data-theme="light"] .property-badge {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark)) !important;
    color: #ffffff !important;
}

/* ===== BUTTONS DOURADOS ===== */
[data-theme="light"] .btn-gold,
[data-theme="light"] .btn-primary,
[data-theme="light"] .search-button {
    background: linear-gradient(135deg, var(--accent) 0%, var(--accent-dark) 100%) !important;
    color: #0a0a0a !important;
    border: none !important;
    font-weight: 700 !important;
    letter-spacing: 2px !important;
    text-transform: uppercase !important;
}

[data-theme="light"] .btn-gold:hover,
[data-theme="light"] .search-button:hover,
[data-theme="light"] .btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-light) 0%, var(--accent) 100%) !important;
    box-shadow: 0 8px 30px rgba(197, 160, 89, 0.5) !important;
    transform: translateY(-2px) !important;
}

/* ===== FOOTER ELEGANTE ===== */
[data-theme="light"] footer,
[data-theme="light"] .site-footer,
[data-theme="light"] .footer {
    background: var(--primary) !important;
    border-top: 1px solid var(--border-color) !important;
    color: var(--text) !important;
}

[data-theme="light"] footer a,
[data-theme="light"] .footer a,
[data-theme="light"] .footer-links a {
    color: var(--text-muted) !important;
}

[data-theme="light"] footer a:hover,
[data-theme="light"] .footer a:hover,
[data-theme="light"] .footer-links a:hover {
    color: var(--accent-dark) !important;
}

[data-theme="light"] .footer-title,
[data-theme="light"] footer h4,
[data-theme="light"] .footer h4 {
    color: var(--text) !important;
}

[data-theme="light"] .footer h4::after {
    background: var(--accent) !important;
}

[data-theme="light"] .footer-logo,
[data-theme="light"] .footer .logo {
    color: var(--accent-dark) !important;
}

[data-theme="light"] .footer-description,
[data-theme="light"] .footer p {
    color: var(--text-muted) !important;
}

[data-theme="light"] .footer-copyright {
    color: var(--text-light) !important;
    border-top: 1px solid var(--border-color) !important;
}

/* ===== TEXT COLORS ===== */
/* ===== HEADINGS & TEXT ===== */
[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] h5,
[data-theme="light"] h6 {
    color: var(--text) !important;
}

[data-theme="light"] p {
    color: #2D2D2D !important;
}

[data-theme="light"] .text-muted {
    color: #5C5C5C !important;
}

/* ===== SVG ICONS ===== */
[data-theme="light"] svg {
    stroke: #5C5C5C !important;
}

[data-theme="light"] .property-card svg,
[data-theme="light"] .feature-item svg {
    stroke: #C5A059 !important;
}

/* ===== FORM ELEMENTS ===== */
[data-theme="light"] input,
[data-theme="light"] select,
[data-theme="light"] textarea {
    background: #FAFAF9 !important;
    border: 1px solid #E8E4DE !important;
    color: #1C1C1C !important;
}

[data-theme="light"] input:focus,
[data-theme="light"] select:focus {
    border-color: #C5A059 !important;
    box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.15) !important;
}

[data-theme="light"] input::placeholder {
    color: #8A8A8A !important;
}

/* ===== RANGE SLIDERS ===== */
[data-theme="light"] .range-slider-container {
    background: transparent !important;
}

[data-theme="light"] .dual-range {
    background: #E6E2DC !important;
    /* Visible inactive track */
}

[data-theme="light"] .dual-range .track {
    background: #C5A059 !important;
    /* Gold active track */
}

[data-theme="light"] .dual-range input[type="range"]::-webkit-slider-thumb {
    border-color: #ffffff !important;
    box-shadow: 0 2px 6px rgba(197, 160, 89, 0.4) !important;
}

/* ===== THEME TOGGLE ===== */
[data-theme="light"] .theme-toggle {
    border: 1px solid #D4CFC7 !important;
    color: #8A8A8A !important;
}

[data-theme="light"] .theme-toggle:hover {
    border-color: #C5A059 !important;
    color: #9A7B4A !important;
    box-shadow: 0 0 0 3px rgba(197, 160, 89, 0.15) !important;
}

/* ===== MAP SECTION ===== */
[data-theme="light"] .map-sticky-wrapper,
[data-theme="light"] #mapView {
    border: 1px solid #E8E4DE !important;
    border-radius: 4px !important;
}

/* ===== SCROLLBAR ===== */
[data-theme="light"] ::-webkit-scrollbar {
    width: 8px;
}

[data-theme="light"] ::-webkit-scrollbar-track {
    background: #F5F5F0;
}

[data-theme="light"] ::-webkit-scrollbar-thumb {
    background: #D4CFC7;
    border-radius: 4px;
}

[data-theme="light"] ::-webkit-scrollbar-thumb:hover {
    background: #C5A059;
}

/* ==========================================================================
   Premium Animations
   ========================================================================== */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

@keyframes glowPulse {

    0%,
    100% {
        box-shadow: 0 0 20px rgba(201, 169, 98, 0.1);
    }

    50% {
        box-shadow: 0 0 35px rgba(201, 169, 98, 0.25);
    }
}

@keyframes subtleFloat {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-6px);
    }
}

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

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.95);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes slideInLeft {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes goldLineExpand {
    from {
        width: 0;
    }

    to {
        width: 60px;
    }
}

@keyframes heroParticle {

    0%,
    100% {
        opacity: 0;
        transform: translateY(0) scale(0);
    }

    50% {
        opacity: 0.6;
        transform: translateY(-80px) scale(1);
    }
}

/* ==========================================================================
   Reset & Base
   ========================================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    transition: background-color 0.3s ease, color 0.3s ease;
    overflow-x: clip;
    overflow-y: visible;
}

body {
    font-family: 'Montserrat', sans-serif;
    background-color: var(--bg-dark);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4 {
    font-family: 'Playfair Display', 'Cormorant Garamond', serif;
    font-weight: 500;
    letter-spacing: 0.02em;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem 1.5rem;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.4s var(--transition-premium);
    border: none;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    position: relative;
    overflow: hidden;
}

/* Shimmer sweep effect on buttons */
.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.15), transparent);
    transition: left 0.5s ease;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #1a1a1a;
    box-shadow: 0 4px 15px rgba(201, 169, 98, 0.2);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--accent-light), var(--accent));
    transform: translateY(-2px);
    box-shadow: 0 8px 30px rgba(201, 169, 98, 0.4);
}

.btn-outline {
    background: transparent;
    border: 1px solid var(--accent);
    color: var(--accent);
}

.btn-outline:hover {
    background: var(--accent);
    color: #1a1a1a;
    box-shadow: 0 5px 20px rgba(201, 169, 98, 0.25);
}

/* ==========================================================================
   Navbar
   ========================================================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    min-height: var(--navbar-height);
    padding: 1rem 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(13, 13, 13, 0.85);
    backdrop-filter: blur(24px) saturate(180%);
    -webkit-backdrop-filter: blur(24px) saturate(180%);
    box-shadow: 0 1px 30px rgba(0, 0, 0, 0.3);
    border-bottom: 1px solid var(--border-gold);
    transition: all 0.4s var(--transition-premium);
}

/* Gold accent line at bottom of navbar */
.navbar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 5%;
    right: 5%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 0.4;
}

/* SVG Logo styles */
.logo-svg {
    display: inline-flex;
    align-items: center;
    transition: all 0.4s var(--transition-premium);
}

.logo-svg svg {
    filter: drop-shadow(0 0 8px rgba(201, 169, 98, 0));
    transition: filter 0.4s ease;
}

.logo:hover .logo-svg svg {
    filter: drop-shadow(0 0 12px rgba(201, 169, 98, 0.3));
}

.logo {
    font-family: 'Playfair Display', 'Cormorant Garamond', serif;
    font-size: 1.8rem;
    font-weight: 600;
    color: var(--text);
    letter-spacing: 0.02em;
    transition: all 0.3s ease;
}

.logo span {
    color: var(--accent);
}

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

.nav-menu a {
    font-size: 0.78rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--text-muted);
    transition: all 0.3s var(--transition-premium);
    position: relative;
    padding: 0.25rem 0;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--accent);
}

.nav-menu a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    transition: all 0.4s var(--transition-premium);
    transform: translateX(-50%);
}

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

.nav-menu li {
    position: relative;
}

.nav-menu li.menu-item-has-children {
    padding-bottom: 14px;
    margin-bottom: -14px;
}

.nav-menu li.menu-item-has-children::after {
    content: '';
    position: absolute;
    top: 100%;
    left: -16px;
    right: -16px;
    height: 16px;
}

.nav-menu .sub-menu {
    position: absolute;
    top: calc(100% + 14px);
    left: 50%;
    transform: translateX(-50%) translateY(8px);
    min-width: 220px;
    padding: 0.5rem;
    margin: 0;
    list-style: none;
    background: linear-gradient(155deg, rgba(14, 14, 14, 0.98), rgba(22, 22, 22, 0.98));
    border: 1px solid rgba(201, 169, 98, 0.22);
    border-radius: 12px;
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.35);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.22s ease, transform 0.22s ease, visibility 0.22s ease;
    z-index: 200;
}

.nav-menu li:hover>.sub-menu,
.nav-menu li:focus-within>.sub-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateX(-50%) translateY(0);
}

.nav-menu .sub-menu li {
    width: 100%;
}

.nav-menu .sub-menu a {
    display: block;
    padding: 0.55rem 0.75rem;
    border-radius: 8px;
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    color: #ece6d8;
}

.nav-menu .sub-menu a::after {
    display: none;
}

.nav-menu .sub-menu a:hover {
    color: #0f0f0f;
    background: linear-gradient(135deg, #d4b978 0%, #b89656 100%);
}

.mobile-nav-menu .sub-menu {
    list-style: none;
    margin: 0.9rem 0 0;
    padding: 0.9rem 0 0;
    border-top: 1px solid rgba(201, 169, 98, 0.2);
}

.mobile-nav-menu .sub-menu li {
    margin-bottom: 0.8rem;
}

.mobile-nav-menu .sub-menu a {
    font-size: 0.96rem;
    letter-spacing: 0.08em;
    color: var(--accent);
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--text);
    font-size: 1.5rem;
    cursor: pointer;
}

/* ==========================================================================
   Hero Section
   ========================================================================== */
.hero {
    min-height: 50vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, rgba(13, 13, 13, 0.85), rgba(20, 20, 20, 0.80)),
        url('assets/images/hero-bg.jpg') center/cover no-repeat;
    padding: 9rem 5% 4rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

[data-theme="light"] .hero {
    background: linear-gradient(135deg, rgba(245, 245, 245, 0.95), rgba(255, 255, 255, 0.90)),
        url('assets/images/hero-bg.jpg') center/cover no-repeat;
}

/* Decorative floating particles */
.hero::before {
    content: '';
    position: absolute;
    width: 4px;
    height: 4px;
    background: var(--accent);
    border-radius: 50%;
    top: 30%;
    left: 15%;
    animation: heroParticle 6s ease-in-out infinite;
    opacity: 0;
}

.hero::after {
    content: '';
    position: absolute;
    width: 3px;
    height: 3px;
    background: var(--accent-light);
    border-radius: 50%;
    top: 50%;
    right: 20%;
    animation: heroParticle 8s ease-in-out infinite 2s;
    opacity: 0;
}

.hero-content {
    max-width: 800px;
    animation: fadeInUp 1s var(--transition-premium);
}

/* ==========================================================================
   Home Filter Hub (MoveUp-inspired horizontal bar)
   ========================================================================== */
.region-context-wrap {
    width: 100%;
    padding: 0 1rem;
    position: relative;
    z-index: 24;
}

.region-context-wrap-archive {
    padding-top: calc(var(--navbar-height) + 0.48rem);
}

.region-context {
    width: min(96%, 1320px);
    margin: 0 auto 0.45rem;
    padding: 0.58rem 0.88rem;
    border-radius: 14px;
    border: 1px solid rgba(201, 169, 98, 0.34);
    background: linear-gradient(165deg, rgba(20, 22, 28, 0.92), rgba(11, 14, 18, 0.92));
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem 1rem;
}

.region-context-text {
    margin: 0;
    font-size: 0.88rem;
    color: #decda8;
}

.region-context-text strong {
    color: #f6ecd8;
    font-weight: 700;
}

.region-context-switch {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.region-context-switch label,
.region-context-switch-title {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #d5bf92;
    font-weight: 700;
}

.region-context-switch select {
    min-width: 196px;
    height: 40px;
    border-radius: 10px;
    border: 1px solid rgba(201, 169, 98, 0.34);
    background: #151920;
    color: #f4ead8;
    padding: 0.45rem 0.7rem;
}

.region-context-focus-btn {
    min-height: 40px;
    padding: 0.52rem 0.95rem;
    border-radius: 10px;
    border: 1px solid rgba(201, 169, 98, 0.42);
    background: linear-gradient(135deg, rgba(201, 169, 98, 0.22), rgba(155, 123, 69, 0.2));
    color: #f5e8cf;
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.region-context-focus-btn:hover,
.region-context-focus-btn:focus {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(141, 107, 54, 0.28);
    border-color: rgba(201, 169, 98, 0.72);
}

.home-filter-hub-wrap {
    width: 100%;
    margin-top: -2.4rem;
    position: relative;
    z-index: 25;
    padding: 0 1rem;
}

.home-filter-hub {
    width: min(96%, 1320px);
    margin: 0 auto;
    background: linear-gradient(165deg, rgba(248, 246, 242, 0.98), rgba(241, 237, 229, 0.98));
    border: 1px solid rgba(176, 141, 85, 0.24);
    border-radius: 18px;
    box-shadow: 0 18px 40px rgba(45, 33, 16, 0.14);
    padding: 1.15rem 1.2rem 1rem;
    overflow: hidden;
}

.home-filter-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 0.9rem 1rem;
    align-items: end;
}

.home-filter-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.home-filter-field label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-weight: 700;
    color: #3f3425;
}

.home-filter-field select {
    width: 100%;
    height: 44px;
    border-radius: 10px;
    border: 1px solid rgba(90, 74, 47, 0.34);
    background: #fff;
    color: #2a241b;
    font-size: 1rem;
    padding: 0.55rem 0.75rem;
}

.home-filter-slider .dual-range {
    margin-top: 0.65rem;
}

.home-filter-slider .range-values {
    margin-top: 0.45rem;
}

.home-filter-slider .range-values span {
    background: rgba(176, 141, 85, 0.12);
    color: #3f3425;
}

.home-filter-submit {
    justify-content: flex-end;
}

.home-filter-submit-btn {
    width: 100%;
    min-height: 46px;
    border-radius: 12px;
    border: 1px solid rgba(142, 106, 54, 0.38);
    background: linear-gradient(135deg, #b79253 0%, #8d6b36 100%);
    color: #17120a;
    font-size: 0.9rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.home-filter-submit-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 20px rgba(141, 107, 54, 0.28);
}

.hero-title {
    font-family: 'Playfair Display', 'Cormorant Garamond', serif;
    font-size: clamp(2.2rem, 5vw, 3.8rem);
    margin-bottom: 1rem;
    line-height: 1.15;
    font-weight: 400;
    letter-spacing: 0.01em;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

.hero-title span {
    color: var(--accent);
    font-style: italic;
}

.hero-tagline {
    font-family: 'Montserrat', sans-serif;
    font-size: clamp(1.1rem, 2.5vw, 1.6rem);
    font-weight: 300;
    color: var(--text);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 0.8rem;
    opacity: 0.85;
    animation: fadeInUp 1.2s var(--transition-premium) 0.2s backwards;
}

.hero-subtitle {
    font-size: 1.05rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    font-weight: 300;
    letter-spacing: 0.02em;
}

.quick-search {
    display: flex;
    gap: 0.5rem;
    max-width: 600px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.04);
    padding: 0.5rem;
    border-radius: 12px;
    border: 1px solid var(--border-gold);
    backdrop-filter: blur(12px);
    transition: all 0.4s var(--transition-premium);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
}

.quick-search:focus-within {
    border-color: var(--accent);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2), 0 0 0 3px var(--accent-glow);
}

.quick-search input {
    flex: 1;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    color: var(--text);
    font-size: 0.95rem;
    font-weight: 300;
}

.quick-search input:focus {
    outline: none;
}

.quick-search input::placeholder {
    color: var(--text-muted);
    font-weight: 300;
}

.quick-search {
    position: relative;
}

.quick-search-suggestions {
    position: absolute;
    top: calc(100% + 0.45rem);
    left: 0;
    right: 0;
    z-index: 35;
    border: 1px solid rgba(201, 169, 98, 0.35);
    border-radius: 12px;
    background: rgba(16, 18, 24, 0.98);
    box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
    overflow: hidden;
}

/* Keep autocomplete above the home filter block and prevent clipping. */
body.home .hero {
    overflow: visible;
    z-index: 40;
}

body.home .hero-content {
    position: relative;
    z-index: 41;
}

body.home .quick-search {
    z-index: 120;
}

body.home .quick-search-suggestions {
    z-index: 1300;
}

.quick-search-suggestion {
    width: 100%;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.18rem;
    text-align: left;
    border: 0;
    border-bottom: 1px solid rgba(201, 169, 98, 0.16);
    background: transparent;
    color: #f2eadb;
    padding: 0.72rem 0.95rem;
    cursor: pointer;
}

.quick-search-suggestion:last-child {
    border-bottom: 0;
}

.quick-search-suggestion .title {
    font-size: 0.92rem;
    font-weight: 600;
    line-height: 1.25;
}

.quick-search-suggestion .meta {
    font-size: 0.74rem;
    letter-spacing: 0.02em;
    color: rgba(238, 224, 192, 0.82);
}

.quick-search-suggestion:hover,
.quick-search-suggestion.is-active {
    background: rgba(201, 169, 98, 0.16);
}

/* ==========================================================================
   Main Layout
   ========================================================================== */
.main-container {
    width: 100%;
    margin: 0;
    padding: 1rem;
    display: grid;
    overflow: visible !important;
    /* Critical for sticky elements */
    grid-template-columns: 280px 1fr;
    gap: 1.5rem;
    align-items: start;
}

.post-type-archive-imovel .catalog-main {
    padding-top: 0.25rem;
}

.post-type-archive-imovel .region-context-wrap-archive .region-context {
    margin-bottom: 0.2rem;
}

/* ==========================================================================
   Filters Sidebar
   ========================================================================== */
/* Filters Sticky Wrapper (NEW) */
/* DO NOT MODIFY - START CRITICAL LAYOUT STRUCTURE */
.filters-sticky-wrapper {
    position: sticky;
    top: 80px;
    /* Standard Safe Offset */
    align-self: start;
    z-index: 90;
}

/* Ceiling Mask for Filters */
.filters-sticky-wrapper::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    height: 50px;
    background: var(--mask-color);
    /* Dynamic Mask */
    z-index: -1;
    pointer-events: none;
}

/* DO NOT MODIFY - END CRITICAL LAYOUT STRUCTURE */

/* Filters Sidebar (Inner Content) */
.filters-sidebar {
    background: var(--card-bg);
    padding: 0.8rem;
    border-radius: 8px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-soft);
    max-height: calc(100vh - 120px);
    overflow-y: auto;
    /* No sticky here, handled by wrapper */
}

/* Scrollbar Styling for Sidebar */
.filters-sidebar::-webkit-scrollbar {
    width: 6px;
}

.filters-sidebar::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
}

.filters-sidebar::-webkit-scrollbar-thumb {
    background: var(--accent-dark);
    border-radius: 3px;
}

.filters-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid rgba(201, 169, 98, 0.15);
}

.filters-header h3 {
    font-size: 1.3rem;
    color: var(--accent);
    margin: 0;
    font-family: 'Playfair Display', 'Cormorant Garamond', serif;
    letter-spacing: 0.05em;
    font-weight: 500;
}

.clear-filters {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    color: var(--text-muted);
    font-size: 0.72rem;
    padding: 5px 12px;
    border-radius: 50px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    transition: all 0.3s var(--transition-premium);
    font-weight: 500;
}

.clear-filters:hover {
    color: var(--accent);
    border-color: var(--accent);
    background: rgba(201, 169, 98, 0.1);
    transform: translateY(-1px);
}

.filter-section {
    margin-bottom: 0.6rem;
}

.filter-section-focus {
    border-radius: 8px;
    box-shadow: 0 0 0 1px rgba(201, 169, 98, 0.5), 0 0 0 4px rgba(201, 169, 98, 0.12);
}

.filter-section h4 {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
}

.filter-section select {
    width: 100%;
    padding: 0.4rem 0.5rem;
    background: #121212;
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text);
    font-size: 0.85rem;
    border-radius: 4px;
    height: 38px;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23c9a962' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}

.filter-section select:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(201, 169, 98, 0.2);
}

/* Custom Multi-Select */
.custom-multiselect {
    position: relative;
    width: 100%;
    font-family: 'Montserrat', sans-serif;
    margin-bottom: 0.5rem;
}

.select-trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0.6rem 0.8rem;
    background: #121212;
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    color: var(--text);
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s ease;
    user-select: none;
}

.select-trigger:hover {
    border-color: rgba(201, 169, 98, 0.5);
}

.custom-multiselect.open .select-trigger {
    border-color: var(--accent);
    box-shadow: 0 0 0 2px rgba(201, 169, 98, 0.2);
}

.arrow-icon {
    font-size: 0.7rem;
    color: var(--accent);
    transition: transform 0.3s ease;
}

.custom-multiselect.open .arrow-icon {
    transform: rotate(180deg);
}

.select-dropdown {
    position: absolute;
    top: 105%;
    left: 0;
    width: 100%;
    background: #1a1a1a;
    border: 1px solid var(--accent);
    border-radius: 8px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.5);
    display: none;
    flex-direction: column;
    max-height: 250px;
    overflow-y: auto;
    z-index: 1000;
    padding: 0.5rem 0;
}

.custom-multiselect.open .select-dropdown {
    display: flex;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.5rem 0.8rem;
    cursor: pointer;
    font-size: 0.85rem;
    color: var(--text);
    transition: background 0.2s ease;
}

.checkbox-item:hover {
    background: rgba(201, 169, 98, 0.1);
}

.filter-checkbox {
    appearance: none;
    width: 16px;
    height: 16px;
    border: 1.5px solid rgba(255, 255, 255, 0.3);
    border-radius: 3px;
    background: transparent;
    cursor: pointer;
    display: grid;
    place-content: center;
    transition: all 0.2s ease;
}

.filter-checkbox:checked {
    background: var(--accent);
    border-color: var(--accent);
}

.filter-checkbox::before {
    content: "";
    width: 10px;
    height: 10px;
    transform: scale(0);
    transition: 120ms transform ease-in-out;
    box-shadow: inset 1rem 1rem var(--primary);
    clip-path: polygon(14% 44%, 0 65%, 50% 100%, 100% 16%, 80% 0%, 43% 62%);
}

.filter-checkbox:checked::before {
    transform: scale(1);
}

/* Price/Area Sliders */
.range-slider-container {
    padding: 0.3rem 0;
}

.dual-range {
    position: relative;
    height: 4px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 2px;
    margin: 1.5rem 0 0.5rem;
}

.dual-range .track {
    position: absolute;
    height: 100%;
    background: var(--accent);
    border-radius: 2px;
}

.dual-range input[type="range"] {
    position: absolute;
    width: 100%;
    height: 4px;
    -webkit-appearance: none;
    background: transparent;
    pointer-events: none;
    top: 0;
    z-index: 2;
}

.dual-range .track {
    z-index: 1;
}

.dual-range input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: var(--accent);
    border: 2px solid var(--bg-dark);
    cursor: pointer;
    pointer-events: all;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
}

.range-values {
    display: flex;
    justify-content: space-between;
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 0.3rem;
}

.range-values span {
    background: rgba(255, 255, 255, 0.05);
    padding: 2px 6px;
    border-radius: 3px;
}

/* Apply Filters Button */
.apply-filters-btn {
    width: 100%;
    padding: 0.85rem;
    margin-top: 0.5rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    border: none;
    border-radius: 6px;
    color: #1a1a1a;
    font-weight: 700;
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    cursor: pointer;
    transition: all 0.4s var(--transition-premium);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(201, 169, 98, 0.2);
}

.apply-filters-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.apply-filters-btn:hover::before {
    left: 100%;
}

.apply-filters-btn:hover {
    background: linear-gradient(135deg, var(--accent-light), var(--accent));
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(201, 169, 98, 0.4);
}

/* ==========================================================================
   Results Area
   ========================================================================== */
.results-area {
    --results-header-top-offset: calc(var(--navbar-height) + 4px);
    --results-panel-top-offset: calc(var(--navbar-height) + 104px);
    --results-panel-height: clamp(430px, calc(100dvh - var(--results-panel-top-offset) - 8px), 860px);
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(430px, 1fr);
    grid-template-rows: auto auto minmax(0, var(--results-panel-height)) auto;
    gap: 0.78rem;
    align-content: start;
    align-items: start;
    overflow: visible !important;
}

.results-area.map-hidden {
    grid-template-columns: 1fr;
}

.desktop-map-toggle {
    display: flex;
    justify-content: flex-end;
    align-self: center;
    margin-bottom: 0;
}

.results-toolbar {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    gap: 0.55rem;
    margin-left: auto;
    min-width: 0;
}

.results-map-control {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    min-width: 0;
}

.results-quick-actions {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.results-filter-dock {
    display: flex;
    align-items: center;
    gap: 0.45rem;
    flex-wrap: wrap;
}

.results-filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-muted);
    min-height: 36px;
    border-radius: 10px;
    padding: 0.35rem 0.72rem;
    font-size: 0.74rem;
    letter-spacing: 0.03em;
    cursor: pointer;
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.results-filter-pill::after {
    content: '\25BE';
    font-size: 0.56rem;
    opacity: 0.76;
}

.results-filter-pill:hover,
.results-filter-pill:focus {
    border-color: rgba(201, 169, 98, 0.5);
    color: var(--accent);
    background: rgba(201, 169, 98, 0.14);
}

.results-filter-pill-alt::after {
    content: '+';
    font-size: 0.75rem;
    line-height: 1;
}

.results-quick-btn {
    border: 1px solid var(--border-color);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-muted);
    font-size: 0.72rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    border-radius: 999px;
    padding: 0.42rem 0.85rem;
    cursor: pointer;
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}

.results-quick-btn:hover,
.results-quick-btn:focus {
    border-color: rgba(201, 169, 98, 0.46);
    color: var(--accent);
    background: rgba(201, 169, 98, 0.12);
}

.results-quick-btn-mobile {
    display: none;
}

.results-map-status {
    margin: 0;
    font-size: 0.72rem;
    letter-spacing: 0.02em;
    color: var(--text-muted);
    text-align: right;
    white-space: nowrap;
    max-width: 186px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.desktop-map-toggle label {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.74rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 0.35rem 0.8rem;
    cursor: pointer;
}

.desktop-map-toggle input[type="checkbox"] {
    width: 14px;
    height: 14px;
    accent-color: var(--accent);
}

.results-active-filters {
    grid-column: 1 / -1;
    grid-row: 2;
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin-top: -0.12rem;
    padding: 0 0.8rem 0.52rem;
}

.results-active-filters:empty {
    display: none;
}

.result-filter-chip {
    border: 1px solid rgba(201, 169, 98, 0.28);
    background: rgba(201, 169, 98, 0.12);
    color: var(--text);
    font-size: 0.72rem;
    border-radius: 999px;
    padding: 0.33rem 0.7rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
}

.result-filter-chip:hover,
.result-filter-chip:focus {
    border-color: rgba(201, 169, 98, 0.55);
}

.result-filter-chip .chip-remove {
    display: inline-flex;
    font-size: 0.76rem;
    opacity: 0.86;
}

.result-filter-chip-clear {
    background: rgba(255, 255, 255, 0.03);
    border-color: var(--border-color);
    color: var(--text-muted);
}

.results-area .properties-grid {
    grid-column: 2;
    grid-row: 3;
}

.results-area .map-panel {
    grid-column: 1;
    grid-row: 3 / 5;
    display: grid;
    align-content: start;
    gap: 0.4rem;
    min-width: 0;
    height: var(--results-panel-height);
    position: sticky;
    top: var(--results-panel-top-offset);
    align-self: start;
    z-index: 60;
}

.results-area .pagination {
    grid-column: 2;
    grid-row: 4;
    justify-self: stretch;
}

.results-area.map-hidden .properties-grid {
    grid-column: 1 / -1;
    grid-row: 3;
}

.results-area.map-hidden .map-panel {
    display: none;
}

.results-area.map-hidden .pagination {
    grid-column: 1 / -1;
}

.results-header {
    grid-column: 1 / -1;
    grid-row: 1;
    display: grid;
    grid-template-columns: auto auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 0.42rem 0.66rem;
    padding: 0.62rem 0.76rem;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 0.35rem;
    position: sticky;
    top: var(--results-header-top-offset);
    /* Standard Safe Offset */
    background: var(--bg-dark);
    /* Ensure opacity */
    z-index: 80;
    backdrop-filter: blur(10px);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    /* Proper border for stickiness */
}

/* Ceiling Mask for Results Header */
/* DO NOT MODIFY - START CRITICAL LAYOUT STRUCTURE */
.results-header::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    height: 24px;
    background: var(--mask-color);
    /* Dynamic Mask */
    z-index: -1;
    pointer-events: none;
}

/* DO NOT MODIFY - END CRITICAL LAYOUT STRUCTURE */

.results-count {
    grid-column: 1;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.results-count strong {
    color: var(--accent);
}

.results-sort {
    grid-column: 2;
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.results-toolbar {
    grid-column: 4;
}

.results-filter-dock {
    grid-column: 1 / -1;
}

.results-sort label {
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    font-weight: 700;
}

.results-sort select {
    min-height: 36px;
    border-radius: 10px;
    border: 1px solid rgba(201, 169, 98, 0.34);
    background: rgba(10, 14, 24, 0.94);
    color: var(--text);
    padding: 0.42rem 0.7rem;
    font-size: 0.84rem;
}

.results-sort select:focus {
    outline: none;
    border-color: rgba(201, 169, 98, 0.72);
    box-shadow: 0 0 0 2px rgba(201, 169, 98, 0.16);
}

@media (min-width: 1025px) {
    .main-container.catalog-main {
        grid-template-columns: 1fr;
    }

    .filters-sticky-wrapper {
        position: fixed;
        top: calc(var(--navbar-height) + 0.85rem);
        left: 0.95rem;
        width: min(340px, 90vw);
        z-index: 2700;
        pointer-events: none;
    }

    .filters-sticky-wrapper::before {
        display: none;
    }

    .filters-sidebar {
        transform: translateX(-112%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        max-height: calc(100vh - var(--navbar-height) - 1.8rem);
        border-radius: 14px;
        transition: transform 0.28s ease, opacity 0.2s ease, visibility 0.2s ease;
    }

    body.desktop-filters-open .filters-sticky-wrapper {
        pointer-events: auto;
    }

    body.desktop-filters-open .filters-sidebar {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    body.desktop-filters-open .filters-close-mobile {
        display: inline-flex;
    }

    body.desktop-filters-open .filters-overlay {
        display: block !important;
        position: fixed;
        inset: 0;
        border: 0;
        margin: 0;
        padding: 0;
        background: rgba(2, 3, 5, 0.16);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
        cursor: pointer;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        z-index: 2600;
    }

    .results-area {
        --results-header-top-offset: calc(var(--navbar-height) + 4px);
        --results-panel-top-offset: calc(var(--navbar-height) + 104px);
        --results-panel-height: clamp(440px, calc(100dvh - var(--results-panel-top-offset) - 6px), 860px);
        grid-template-columns: minmax(0, 1.5fr) minmax(430px, 1fr);
    }

    .results-header {
        display: grid;
        grid-template-columns: auto auto minmax(0, 1fr) auto;
        gap: 0.45rem 0.72rem;
        align-items: center;
    }

    .results-count {
        margin: 0;
    }

    .results-filter-dock {
        grid-column: 1 / -1;
        margin-top: 0;
        flex-wrap: nowrap;
        overflow-x: auto;
        scrollbar-width: none;
        white-space: nowrap;
        padding-bottom: 0.08rem;
    }

    .results-filter-dock::-webkit-scrollbar {
        display: none;
    }

    .results-filter-pill {
        min-height: 34px;
        font-size: 0.71rem;
        padding: 0.32rem 0.66rem;
        border-radius: 999px;
    }

    .results-sort {
        justify-self: end;
    }

    .results-sort label {
        font-size: 0.68rem;
    }

    .results-sort select {
        min-height: 34px;
        padding: 0.35rem 0.62rem;
        font-size: 0.8rem;
    }

    .results-toolbar {
        justify-self: end;
        gap: 0.42rem;
    }

    .results-map-control {
        gap: 0.45rem;
    }

    .results-map-status {
        font-size: 0.73rem;
        max-width: 172px;
    }

    .results-quick-btn {
        font-size: 0.68rem;
        padding: 0.36rem 0.76rem;
    }

    .results-area.map-active .properties-grid {
        grid-template-columns: repeat(auto-fit, minmax(236px, 1fr));
        max-height: var(--results-panel-height);
        overflow-y: auto;
        overscroll-behavior: contain;
        padding: 0.45rem 0.52rem 0.3rem 0;
        align-content: start;
        gap: 0.78rem;
        scrollbar-gutter: stable;
        border-radius: 12px;
    }

    .results-area.map-active .properties-grid::-webkit-scrollbar {
        width: 8px;
    }

    .results-area.map-active .properties-grid::-webkit-scrollbar-thumb {
        background: rgba(201, 169, 98, 0.34);
        border-radius: 999px;
    }

    .results-area.map-active .properties-grid .property-card {
        display: flex;
        flex-direction: column;
        min-height: 0;
        border-radius: 12px;
    }

    .results-area.map-active .properties-grid .property-image {
        height: 142px;
        min-height: 142px;
    }

    .results-area.map-active .properties-grid .property-content {
        padding: 0.78rem 0.82rem;
    }

    .results-area.map-active .properties-grid .property-title {
        font-size: 0.94rem;
        margin-bottom: 0.3rem;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .results-area.map-active .properties-grid .property-location {
        margin-bottom: 0.45rem;
        font-size: 0.78rem;
    }

    .results-area.map-active .properties-grid .property-price {
        font-size: 1.04rem;
        margin-bottom: 0.56rem;
    }

    .results-area.map-active .properties-grid .property-features {
        margin-top: auto;
        padding-top: 0.55rem;
        gap: 0.48rem 0.6rem;
        flex-wrap: wrap;
    }

    .results-area.map-active .properties-grid .feature-item {
        font-size: 0.72rem;
    }

    .results-area.map-active .properties-grid .property-badge {
        top: 0.6rem;
        left: 0.6rem;
        font-size: 0.62rem;
        padding: 0.26rem 0.62rem;
    }

    .map-sticky-wrapper {
        top: 0;
        height: 100%;
    }

    #mapView {
        height: 100%;
        min-height: 360px;
    }
}

/* ==========================================================================
   Property Cards
   ========================================================================== */
.properties-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    width: 100%;
}

.properties-grid > .loading-placeholder,
.properties-grid > .no-results {
    grid-column: 1 / -1;
    min-height: 180px;
    border: 1px solid rgba(201, 169, 98, 0.2);
    border-radius: 12px;
    background: rgba(16, 19, 27, 0.62);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 1rem 1.1rem;
}

.properties-grid > .loading-placeholder p,
.properties-grid > .no-results p {
    margin: 0;
    font-size: 0.9rem;
    letter-spacing: 0.02em;
}

.property-card {
    background: var(--card-bg);
    border-radius: 14px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.06);
    transition: all 0.5s var(--transition-premium);
    position: relative;
    animation: fadeInUp 0.6s var(--transition-premium) backwards;
}

/* Staggered entrance for cards */
.property-card:nth-child(1) {
    animation-delay: 0.05s;
}

.property-card:nth-child(2) {
    animation-delay: 0.1s;
}

.property-card:nth-child(3) {
    animation-delay: 0.15s;
}

.property-card:nth-child(4) {
    animation-delay: 0.2s;
}

.property-card:nth-child(5) {
    animation-delay: 0.25s;
}

.property-card:nth-child(6) {
    animation-delay: 0.3s;
}

.property-card:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-card-hover);
    border-color: rgba(201, 169, 98, 0.25);
}

/* Gold glow on card hover */
.property-card::after {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 14px;
    padding: 1px;
    background: linear-gradient(135deg, transparent, rgba(201, 169, 98, 0.15), transparent);
    -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.property-card:hover::after {
    opacity: 1;
}

.property-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #1a1a1a;
    padding: 0.35rem 0.9rem;
    font-size: 0.68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    border-radius: 4px;
    z-index: 1;
    box-shadow: 0 4px 12px rgba(201, 169, 98, 0.3);
}

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

/* Image overlay gradient for elegance */
.property-image::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.4), transparent);
    pointer-events: none;
    z-index: 1;
}

.property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s var(--transition-premium);
}

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

.property-actions {
    position: absolute;
    top: 1rem;
    right: 1rem;
    display: flex;
    gap: 0.5rem;
    z-index: 2;
}

.action-btn {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s var(--transition-premium);
}

.action-btn:hover {
    background: var(--accent);
    color: #1a1a1a;
    border-color: var(--accent);
    transform: scale(1.1);
}

.property-content {
    padding: 1.3rem;
}

.property-title {
    font-family: 'Playfair Display', 'Cormorant Garamond', serif;
    font-size: 1.1rem;
    font-weight: 500;
    margin-bottom: 0.5rem;
    line-height: 1.3;
    transition: color 0.3s ease;
}

.property-card:hover .property-title {
    color: var(--accent);
}

.property-location {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    color: var(--text-muted);
    font-size: 0.82rem;
    margin-bottom: 1rem;
    font-weight: 300;
}

.property-price {
    font-size: 1.35rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 1rem;
    font-family: 'Montserrat', sans-serif;
    letter-spacing: -0.01em;
}

.property-price.property-price-consult {
    font-size: 1.02rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--text-muted);
}

.property-features {
    display: flex;
    gap: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.78rem;
    color: var(--text-muted);
    font-weight: 400;
}

.feature-item svg {
    color: var(--accent);
    opacity: 0.8;
}

/* ==========================================================================
   Map View
   ========================================================================== */
/* Map Sticky Wrapper - para de rolar junto com filtros e "X imoveis encontrados" */
.map-sticky-wrapper {
    position: relative;
    top: 0;
    width: 100%;
    height: 100%;
    align-self: start;
    z-index: 50;
    pointer-events: none;
}

/* Ceiling Mask for Map */
/* DO NOT MODIFY - START CRITICAL LAYOUT STRUCTURE */
.map-sticky-wrapper::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 0;
    right: 0;
    height: 24px;
    background: var(--mask-color);
    /* Dynamic Mask */
    z-index: -1;
    pointer-events: none;
}

/* DO NOT MODIFY - END CRITICAL LAYOUT STRUCTURE */

/* Re-enable pointer events for map */
.map-sticky-wrapper>* {
    pointer-events: auto;
}

#mapView {
    width: 100%;
    height: 100%;
    min-height: 340px;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    /* Removed sticky from here to avoid Leaflet conflict */
}

.mobile-map-view {
    display: none;
}

/* Custom Map Markers */
.price-marker-icon {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #1a1a1a;
    padding: 5px 10px 6px;
    border-radius: 14px;
    font-family: 'Montserrat', sans-serif;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 1px;
    text-align: center;
    line-height: 1.05;
    width: 146px;
    min-width: 146px;
    max-width: 146px;
    box-sizing: border-box;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    border: 2px solid rgba(255, 255, 255, 0.3);
    position: relative;
    z-index: 1;
    overflow: visible;
    transform: none;
}

.price-marker-icon::after {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -8px;
    width: 14px;
    height: 14px;
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    border-right: 2px solid rgba(255, 255, 255, 0.28);
    border-bottom: 2px solid rgba(255, 255, 255, 0.28);
    border-radius: 2px;
    transform: translateX(-50%) rotate(45deg);
    box-shadow: 2px 2px 7px rgba(0, 0, 0, 0.26);
    z-index: 0;
    pointer-events: none;
}

.price-marker-icon::before {
    content: '';
    position: absolute;
    left: 50%;
    bottom: -17px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    transform: translateX(-50%);
    background: var(--accent-dark);
    border: 1px solid rgba(255, 255, 255, 0.44);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.34);
    z-index: 0;
    pointer-events: none;
}

.price-marker-icon .price-marker-title {
    position: relative;
    z-index: 2;
    font-size: 0.58rem;
    letter-spacing: 0.03em;
    text-transform: uppercase;
    font-weight: 700;
    max-width: 132px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.price-marker-icon .price-marker-symbol {
    position: relative;
    z-index: 2;
    width: 18px;
    height: 18px;
    margin-bottom: 1px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: rgba(26, 26, 26, 0.92);
    background: rgba(255, 255, 255, 0.22);
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.2);
}

.price-marker-icon .price-marker-symbol svg {
    width: 11px;
    height: 11px;
    stroke: currentColor;
    opacity: 0.9;
}

.price-marker-icon .price-marker-value {
    position: relative;
    z-index: 2;
    font-size: 0.78rem;
    font-weight: 800;
    max-width: 132px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.price-marker-icon.price-marker-compact {
    min-width: 40px;
    max-width: 40px;
    width: 40px;
    height: 40px;
    padding: 0;
    border-radius: 999px;
    border-width: 2px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.28);
}

.price-marker-icon.price-marker-compact::after {
    width: 9px;
    height: 9px;
    bottom: -6px;
    border-width: 1px;
    border-radius: 1px;
}

.price-marker-icon.price-marker-compact::before {
    width: 4px;
    height: 4px;
    bottom: -13px;
    border-width: 1px;
}

.price-marker-icon.price-marker-compact .price-marker-title,
.price-marker-icon.price-marker-compact .price-marker-value {
    display: none;
}

.price-marker-icon.price-marker-compact .price-marker-symbol {
    width: 18px;
    height: 18px;
    margin: 0;
    background: rgba(255, 255, 255, 0.28);
}

.price-marker-icon.price-marker-compact .price-marker-symbol svg {
    width: 11px;
    height: 11px;
}

.custom-cluster-icon {
    background: linear-gradient(135deg, var(--accent), var(--accent-dark));
    color: #1a1a1a;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: 1rem;
    font-family: 'Montserrat', sans-serif;
    box-shadow: 0 4px 15px rgba(201, 169, 98, 0.5);
    border: 3px solid rgba(255, 255, 255, 0.4);
}

/* Leaflet Popup Styling */
.leaflet-popup-content-wrapper {
    background: var(--card-bg);
    color: var(--text);
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(201, 169, 98, 0.2);
}

.leaflet-popup-tip {
    background: var(--card-bg);
}

.map-popup-card {
    min-width: 220px;
    max-width: 240px;
}

.map-popup-image {
    width: 100%;
    height: 124px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 0.5rem;
}

.map-popup-title {
    margin: 0 0 0.2rem;
    font-size: 1rem;
    line-height: 1.2;
    color: var(--text);
}

.map-popup-icon {
    margin-right: 0.28rem;
    font-size: 0.76em;
    opacity: 0.72;
}

.map-popup-price {
    margin: 0 0 0.4rem;
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--accent);
}

.map-popup-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    margin: 0 0 0.55rem;
}

.map-popup-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.46rem;
    border-radius: 999px;
    font-size: 0.69rem;
    letter-spacing: 0.03em;
    color: var(--text);
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(201, 169, 98, 0.28);
}

.map-popup-link {
    display: block;
    padding: 0.5rem 0.7rem;
    border-radius: 8px;
    text-align: center;
    font-size: 0.79rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    text-decoration: none;
    color: #1a1a1a !important;
    background: linear-gradient(135deg, #d4b978 0%, #b89656 100%);
}

/* ==========================================================================
   Homepage Badge Listings
   ========================================================================== */
.home-badge-listings {
    width: 100%;
    padding: 1.6rem 0 4.6rem;
}

.home-badge-listings-inner {
    width: min(94%, 1700px);
    margin: 0 auto;
    display: grid;
    gap: 2.5rem;
}

.badge-listing-section {
    background: linear-gradient(155deg, rgba(18, 18, 18, 0.92), rgba(24, 24, 24, 0.92));
    border: 1px solid rgba(201, 169, 98, 0.2);
    border-radius: 14px;
    padding: 1.35rem 1rem 1.7rem;
    overflow: hidden;
    scroll-margin-top: calc(var(--navbar-height) + 1rem);
}

.badge-listing-header {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 1.3rem;
    text-align: center;
}

.badge-listing-header h2 {
    margin: 0;
    font-size: clamp(1.05rem, 1.1vw, 1.35rem);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--accent);
    font-family: 'Playfair Display', 'Cormorant Garamond', serif;
    font-weight: 600;
    width: 100%;
    position: relative;
}

.badge-listing-header h2::after {
    content: '';
    display: block;
    width: 86px;
    height: 1px;
    margin: 0.5rem auto 0;
    background: linear-gradient(90deg, transparent, rgba(201, 169, 98, 0.8), transparent);
}

.badge-listing-sort {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
}

.badge-listing-sort label {
    font-size: 0.66rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: var(--text-muted);
    font-weight: 700;
}

.badge-sort-select {
    min-height: 34px;
    border-radius: 9px;
    border: 1px solid rgba(201, 169, 98, 0.32);
    background: rgba(12, 15, 22, 0.94);
    color: var(--text);
    font-size: 0.8rem;
    padding: 0.35rem 0.62rem;
}

.badge-sort-select:focus {
    outline: none;
    border-color: rgba(201, 169, 98, 0.72);
    box-shadow: 0 0 0 2px rgba(201, 169, 98, 0.16);
}

.badge-carousel {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) 36px;
    align-items: center;
    gap: 0.45rem;
}

.badge-carousel-nav {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(201, 169, 98, 0.35);
    background: rgba(255, 255, 255, 0.03);
    color: var(--accent);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    line-height: 1;
    transition: all 0.25s ease;
}

.badge-carousel-nav:hover {
    color: #111;
    background: linear-gradient(135deg, #d4b978 0%, #b89656 100%);
}

.badge-carousel-viewport {
    overflow-x: auto;
    overflow-y: hidden;
    cursor: grab;
    scroll-behavior: smooth;
    scrollbar-width: thin;
    scrollbar-color: rgba(201, 169, 98, 0.45) transparent;
}

.badge-carousel-viewport.is-dragging {
    cursor: grabbing;
}

.badge-carousel-viewport::-webkit-scrollbar {
    height: 7px;
}

.badge-carousel-viewport::-webkit-scrollbar-thumb {
    background: rgba(201, 169, 98, 0.45);
    border-radius: 999px;
}

.badge-carousel-track {
    display: flex;
    align-items: flex-start;
    gap: 0.8rem;
    width: max-content;
    padding-bottom: 0.3rem;
}

.badge-property-card {
    width: clamp(220px, 19vw, 280px);
    flex: 0 0 clamp(220px, 19vw, 280px);
    margin-right: 0.05rem;
}

.badge-property-card>a {
    display: block;
    overflow: hidden;
    border-radius: 12px;
    border: 1px solid rgba(201, 169, 98, 0.18);
    background: linear-gradient(160deg, rgba(33, 33, 33, 0.94), rgba(26, 26, 26, 0.94));
    text-decoration: none;
    transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.badge-property-card>a:hover {
    transform: translateY(-2px);
    border-color: rgba(201, 169, 98, 0.45);
    box-shadow: 0 14px 25px rgba(0, 0, 0, 0.32);
}

.badge-property-image {
    width: 100%;
    aspect-ratio: 16 / 10;
    background: #111;
}

.badge-property-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.badge-property-content {
    padding: 0.7rem 0.78rem 0.8rem;
}

.badge-property-content h3 {
    margin: 0 0 0.4rem;
    font-size: 0.95rem;
    line-height: 1.25;
    color: var(--text);
}

.badge-property-price {
    margin: 0 0 0.35rem;
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--accent);
}

.badge-property-meta {
    margin: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    font-size: 0.73rem;
    color: var(--text-muted);
}

.badge-property-meta span {
    display: inline-flex;
    align-items: center;
    padding: 0.15rem 0.42rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(201, 169, 98, 0.2);
}

/* ==========================================================================
   Single Property Page
   ========================================================================== */
.single-property {
    padding-top: 80px;
}

.property-gallery {
    position: relative;
    height: 500px;
    overflow: hidden;
}

.property-gallery img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.gallery-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 1rem;
}

.gallery-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.6);
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-btn:hover {
    background: var(--accent);
    color: #1a1a1a;
}

.property-details {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 5%;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 2rem;
}

.property-info h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.property-info .price {
    font-size: 2rem;
    color: var(--accent);
    font-weight: 700;
    margin-bottom: 2rem;
}

.property-features-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 12px;
}

.feature-box {
    text-align: center;
    padding: 1rem;
}

.feature-box .icon {
    font-size: 2rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.feature-box .value {
    font-size: 1.5rem;
    font-weight: 700;
}

.feature-box .label {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.property-description {
    line-height: 1.8;
    color: var(--text-muted);
}

.property-description h2 {
    color: var(--text);
    margin-bottom: 1rem;
}

/* Contact Sidebar */
.contact-sidebar {
    background: var(--card-bg);
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 100px;
}

.contact-sidebar h3 {
    font-size: 1.3rem;
    margin-bottom: 1.5rem;
    color: var(--accent);
}

.contact-form input,
.contact-form textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    margin-bottom: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    color: var(--text);
    font-size: 0.9rem;
}

.contact-form input:focus,
.contact-form textarea:focus {
    outline: none;
    border-color: var(--accent);
}

.contact-form textarea {
    min-height: 120px;
    resize: vertical;
}

.whatsapp-btn {
    width: 100%;
    min-height: 50px;
    padding: 0.9rem 1rem;
    background: linear-gradient(135deg, #26cb68 0%, #1da851 100%);
    color: #f8fff8;
    border: 1px solid rgba(220, 195, 136, 0.34);
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.96rem;
    letter-spacing: 0.04em;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.55rem;
    margin-top: 1rem;
    box-shadow: 0 12px 24px rgba(16, 98, 52, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.16);
    transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease;
}

.whatsapp-btn:hover {
    transform: translateY(-2px);
    filter: saturate(1.05);
    box-shadow: 0 16px 30px rgba(16, 98, 52, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

[data-theme="light"] .whatsapp-btn {
    color: #173b24;
    border-color: rgba(155, 122, 62, 0.38);
    box-shadow: 0 12px 24px rgba(20, 122, 67, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.65);
}

/* ==========================================================================
   Footer
   ========================================================================== */
footer {
    background: var(--primary);
    padding: 4rem 5% 2rem;
    margin-top: 4rem;
    border-top: none;
    position: relative;
}

/* Gold gradient divider at top of footer */
footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 10%;
    right: 10%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.footer-content {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    max-width: 1400px;
    margin: 0 auto;
}

.footer-brand .logo {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 0.88rem;
    line-height: 1.8;
    margin-bottom: 1.5rem;
    font-weight: 300;
}

.footer-social {
    display: flex;
    gap: 0.8rem;
}

.footer-social a {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    transition: all 0.4s var(--transition-premium);
}

.footer-social a:hover {
    background: var(--accent);
    color: #1a1a1a;
    border-color: var(--accent);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(201, 169, 98, 0.3);
}

.footer-column h4 {
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text);
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    position: relative;
    padding-bottom: 0.8rem;
}

/* Gold underline on footer headings */
.footer-column h4::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 30px;
    height: 2px;
    background: linear-gradient(90deg, var(--accent), transparent);
}

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

.footer-links li {
    margin-bottom: 0.8rem;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.88rem;
    font-weight: 300;
    transition: all 0.3s var(--transition-premium);
    position: relative;
}

.footer-links a:hover {
    color: var(--accent);
    padding-left: 0.5rem;
}

.footer-bottom {
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.06);
    text-align: center;
    color: var(--text-muted);
    font-size: 0.82rem;
    font-weight: 300;
    letter-spacing: 0.02em;
}

/* ==========================================================================
   WhatsApp Float Button
   ========================================================================== */
.whatsapp-float {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    z-index: 999;
}

.whatsapp-float a {
    display: flex;
    align-items: center;
    gap: 0.72rem;
    min-height: 56px;
    background: linear-gradient(140deg, #24c965 0%, #1ea958 100%);
    color: #f6fff6;
    padding: 0.84rem 1.34rem;
    border-radius: 999px;
    font-weight: 700;
    letter-spacing: 0.02em;
    border: 1px solid rgba(220, 194, 130, 0.32);
    box-shadow: 0 14px 34px rgba(13, 92, 49, 0.3), inset 0 1px 0 rgba(255, 255, 255, 0.16);
    transition: transform 0.26s ease, box-shadow 0.26s ease, filter 0.26s ease;
}

.whatsapp-float a:hover {
    transform: translateY(-3px) scale(1.01);
    filter: saturate(1.05);
    box-shadow: 0 18px 38px rgba(13, 92, 49, 0.36), inset 0 1px 0 rgba(255, 255, 255, 0.2);
}

.whatsapp-float a svg {
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    padding: 5px;
    border-radius: 50%;
    color: #24c965;
    background: rgba(6, 36, 21, 0.9);
    border: 1px solid rgba(220, 194, 130, 0.38);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

.whatsapp-float .whatsapp-text {
    display: block;
    font-size: 1.02rem;
    line-height: 1;
}

html:not([data-theme="light"]) .whatsapp-float a {
    background: linear-gradient(140deg, #24c965 0%, #1eaa58 100%);
    color: #f7fff8;
    border-color: rgba(219, 192, 128, 0.34);
}

[data-theme="light"] .whatsapp-float a {
    background: linear-gradient(140deg, #2cd06d 0%, #25b961 100%);
    color: #173b24;
    border-color: rgba(155, 122, 62, 0.38);
    box-shadow: 0 14px 30px rgba(28, 129, 74, 0.24), inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

[data-theme="light"] .whatsapp-float a svg {
    color: #179a4c;
    background: rgba(255, 255, 255, 0.88);
    border-color: rgba(173, 136, 70, 0.46);
}

/* ==========================================================================
   Pagination
   ========================================================================== */
.pagination {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 2rem 0;
    grid-column: 1 / -1;
}

.pagination a,
.pagination span {
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: var(--text-muted);
    transition: all 0.3s ease;
}

.pagination a:hover,
.pagination .current {
    background: var(--accent);
    color: #1a1a1a;
    border-color: var(--accent);
}

/* ==========================================================================
   Contact Page
   ========================================================================== */
.contact-page {
    padding: calc(var(--navbar-height) + 3rem) 5% 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.contact-page h1 {
    font-size: 3rem;
    margin-bottom: 2rem;
    text-align: center;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.contact-info-box {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.contact-info-box h3 {
    color: var(--accent);
    margin-bottom: 1.5rem;
}

.contact-info-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.contact-info-item .icon {
    width: 40px;
    height: 40px;
    background: rgba(201, 169, 98, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

/* ==========================================================================
   About Page
   ========================================================================== */
.about-page {
    padding: calc(var(--navbar-height) + 3rem) 5% 4rem;
}

.about-hero {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

.about-hero h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

/* ==========================================================================
   Landing Page Template
   ========================================================================== */
.landing-hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    position: relative;
}

.landing-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.4));
}

.landing-content {
    position: relative;
    z-index: 1;
    max-width: 600px;
    padding: 5%;
}

.urgency-bar {
    background: linear-gradient(135deg, #ff4444, #cc0000);
    color: white;
    text-align: center;
    padding: 0.8rem;
    font-weight: 600;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1001;
}

/* Fix: Hide Mobile Filter Toggle by Default */
.mobile-filter-toggle {
    display: none;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

/* Large Desktop */
@media (min-width: 1400px) {
    .properties-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Tablet */
@media (max-width: 1024px) {
    .navbar {
        padding: 0.8rem 4%;
    }

    .nav-menu {
        gap: 1.5rem;
    }

    .main-container {
        grid-template-columns: 220px 1fr;
        gap: 1rem;
    }

    .mobile-map-view {
        display: block !important;
        width: 100%;
        height: 250px;
        border-radius: 8px;
        margin-bottom: 1rem;
        overflow: hidden;
        border: 1px solid rgba(255, 255, 255, 0.1);
    }

    .property-details {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }
}

/* Mobile */
@media (max-width: 768px) {
    .navbar {
        padding: 0.8rem 4%;
    }

    .nav-menu {
        display: none;
    }

    .mobile-menu-toggle {
        display: block;
    }

    .hero {
        min-height: 50vh;
        padding: 6rem 4% 2rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .quick-search {
        flex-direction: column;
    }

    .home-filter-hub-wrap {
        margin-top: -1.2rem;
        padding: 0 0.7rem;
    }

    .home-filter-hub {
        width: 100%;
        border-radius: 14px;
        padding: 0.9rem 0.8rem;
    }

    .home-filter-grid {
        grid-template-columns: 1fr;
        gap: 0.65rem;
    }

    .home-filter-field select {
        height: 42px;
        font-size: 0.95rem;
    }

    .home-filter-submit-btn {
        min-height: 44px;
    }

    .main-container {
        grid-template-columns: 1fr;
        padding: 1rem 4%;
    }

    .filters-sidebar {
        position: fixed;
        top: 0;
        left: -100%;
        width: 85%;
        max-width: 320px;
        height: 100vh;
        max-height: 100vh;
        z-index: 2000;
        transition: left 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        border-radius: 0;
        background: var(--bg-dark);
        border-right: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: 10px 0 30px rgba(0, 0, 0, 0.5);
    }

    .filters-sidebar.active {
        left: 0;
    }

    .filters-sidebar {
        padding-bottom: 4.6rem;
    }

    .filters-sidebar .apply-filters-btn {
        position: sticky;
        bottom: 0.7rem;
        z-index: 6;
        margin-top: 1rem;
    }

    /* Overlay for sidebar */
    .filters-overlay {
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.34);
        z-index: 1500;
        opacity: 0;
        visibility: hidden;
        transition: all 0.3s ease;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .filters-sidebar.active+.filters-overlay,
    .filters-overlay.active {
        opacity: 1;
        visibility: visible;
    }

    .mobile-filter-toggle {
        display: flex !important;
        position: fixed;
        bottom: 1rem;
        left: 50%;
        transform: translateX(-50%);
        z-index: 100;
        background: var(--accent);
        color: #1a1a1a;
        padding: 0.8rem 1.5rem;
        border-radius: 50px;
        font-weight: 600;
        box-shadow: 0 5px 20px rgba(201, 169, 98, 0.4);
    }

    body.filters-open .mobile-filter-toggle {
        opacity: 0;
        pointer-events: none;
        transform: translateX(-50%) translateY(24px);
    }

    .desktop-map-toggle,
    .results-map-control,
    .results-map-status,
    .map-sticky-wrapper,
    #mapView {
        display: none !important;
    }

    .results-quick-actions {
        width: 100%;
        justify-content: flex-start;
    }

    .results-toolbar {
        width: 100%;
        justify-content: flex-start;
    }

    .results-filter-dock {
        width: 100%;
        flex-wrap: nowrap;
        overflow-x: auto;
        padding-bottom: 0.18rem;
        scrollbar-width: none;
    }

    .results-filter-dock::-webkit-scrollbar {
        display: none;
    }

    .results-filter-pill {
        flex: 0 0 auto;
        min-height: 34px;
        border-radius: 999px;
        font-size: 0.7rem;
        padding: 0.32rem 0.66rem;
    }

    .results-quick-btn-mobile {
        display: inline-flex;
    }

    .results-area.map-hidden {
        grid-template-columns: 1fr;
    }

    .results-area {
        grid-template-columns: 1fr;
    }

    .results-area .pagination {
        grid-column: 1 / -1;
    }

    .results-active-filters {
        padding: 0 0.1rem 0.55rem;
        margin-top: 0;
    }

    .results-header {
        display: flex;
        flex-wrap: wrap;
        gap: 0.55rem;
    }

    .results-sort {
        width: 100%;
        justify-content: flex-end;
    }

    .results-sort select {
        width: 100%;
        max-width: 220px;
    }

    .results-area .properties-grid,
    body.post-type-archive-imovel .results-area .properties-grid {
        grid-template-columns: minmax(0, 1fr) !important;
        gap: 0.82rem !important;
        width: 100% !important;
        max-width: 100% !important;
        overflow-x: hidden !important;
    }

    .results-area .property-card,
    body.post-type-archive-imovel .results-area .property-card {
        width: 100% !important;
        min-width: 0 !important;
    }

    html,
    body,
    body.post-type-archive-imovel,
    body.post-type-archive-imovel .catalog-main-modern,
    body.post-type-archive-imovel .results-area {
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
    }

    .property-gallery {
        height: 300px;
    }

    .property-features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-social {
        justify-content: center;
    }

    .whatsapp-float a {
        min-height: 48px;
        padding: 0.72rem 0.96rem;
        border-radius: 16px;
        gap: 0.5rem;
    }

    .whatsapp-float .whatsapp-text {
        display: block;
        font-size: 0.9rem;
    }

    .badge-carousel {
        grid-template-columns: 1fr;
    }

    .badge-carousel-nav {
        display: none;
    }

    .badge-property-card {
        width: min(76vw, 310px);
        flex: 0 0 min(76vw, 310px);
    }

    .badge-listing-sort {
        width: 100%;
        justify-content: center;
    }

    .badge-sort-select {
        width: min(100%, 260px);
    }
}

@media (max-width: 420px) {
    .whatsapp-float .whatsapp-text {
        display: none;
    }

    .whatsapp-float a {
        min-width: 46px;
        min-height: 46px;
        padding: 0.72rem;
        border-radius: 999px;
    }
}

/* Small Mobile */
@media (max-width: 480px) {
    .properties-grid {
        grid-template-columns: 1fr;
    }

    .contact-grid {
        grid-template-columns: 1fr;
    }

    .about-content {
        grid-template-columns: 1fr;
    }
}

/* ==========================================================================
   WordPress Specific
   ========================================================================== */
.alignwide {
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

.alignfull {
    width: 100vw;
    max-width: 100vw;
    margin-left: calc(-50vw + 50%);
}

.wp-block-image img {
    max-width: 100%;
    height: auto;
}

/* Admin Bar Offset & Sticky Fixes */
body.admin-bar .navbar {
    top: 32px;
}

body.admin-bar .contact-page,
body.admin-bar .about-page {
    padding-top: calc(var(--navbar-height) + 3rem + 32px);
}

@media (min-width: 769px) {
    body.admin-bar .filters-sticky-wrapper {
        top: calc(var(--navbar-height) + 32px);
    }

    body.admin-bar .filters-sidebar {
        max-height: calc(100vh - 132px);
    }

    body.admin-bar .results-header {
        top: calc(var(--results-header-top-offset) + 32px);
    }

    body.admin-bar .map-sticky-wrapper {
        top: calc(var(--results-panel-top-offset) + 32px);
    }
}

@media (max-width: 782px) {
    body.admin-bar .navbar {
        top: 46px;
    }

    body.admin-bar .contact-page,
    body.admin-bar .about-page {
        padding-top: calc(var(--navbar-height) + 3rem + 46px);
    }
}

@media (max-width: 768px) {
    .contact-page,
    .about-page {
        padding: calc(var(--navbar-height) + 2.3rem) 5% 3rem;
    }
}

/* Screen Reader Text */
.screen-reader-text {
    clip: rect(1px, 1px, 1px, 1px);
    position: absolute !important;
    height: 1px;
    width: 1px;
    overflow: hidden;
}

/* Fix: Hide Mobile Filter Toggle on Desktop */
@media (min-width: 769px) {
    .mobile-filter-toggle {
        display: none !important;
    }
}

/* ==========================================================================
   Theme Toggle
   ========================================================================== */
.theme-toggle {
    background: transparent;
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-right: 1rem;
}

.theme-toggle:hover {
    background: rgba(201, 169, 98, 0.1);
    border-color: var(--accent);
    color: var(--accent);
}

.theme-toggle svg {
    display: none;
}

/* ==========================================================================
   Landing Page Components (Added Fix)
   ========================================================================== */

/* Landing Page Wrapper Background */
.landing-page-wrapper {
    background-color: var(--bg-dark);
    color: var(--text);
    transition: background-color 0.4s ease, color 0.4s ease;
}

[data-theme="light"] .landing-page-wrapper {
    background-color: var(--bg-dark);
    /* Should be lighter in light mode via var */
}

/* Stats Bar */
.stats-bar {
    display: flex;
    justify-content: center;
    gap: 2rem;
    padding: 3rem 5%;
    background: var(--bg-elevated);
    border-bottom: 1px solid var(--border-color);
    flex-wrap: wrap;
}

.stat-item {
    text-align: center;
    padding: 1.5rem 2.5rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    min-width: 180px;
    transition: all 0.3s ease;
}

.stat-number {
    font-family: 'Playfair Display', serif;
    font-size: 2.5rem;
    color: var(--accent);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Light Mode Overrides for Landing Page */
[data-theme="light"] .stats-bar {
    background: #ffffff;
    border-bottom: 1px solid var(--border-color);
}

[data-theme="light"] .stat-item {
    background: #ffffff;
    border: 1px solid #d1d1d1;
    /* Stronger border for visibility */
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .stat-number {
    color: var(--accent-dark);
}

[data-theme="light"] .stat-label {
    color: #555;
    font-weight: 600;
}

/* Feature Boxes / Generic Boxes Enhancement */
[data-theme="light"] .wp-block-group,
[data-theme="light"] .wp-block-columns,
[data-theme="light"] .feature-item,
[data-theme="light"] .contact-form-wrapper {
    border: 1px solid #e0e0e0;
    border-radius: 12px;
}

[data-theme="light"] .landing-contact {
    background: #f9f9f9 !important;
}

[data-theme="light"] .section-title {
    color: #1a1a1a;
}

/* AGGRESSIVE LANDING PAGE LIGHT MODE FIXES - FINAL */
[data-theme="light"] body.page-template-template-landing {
    background-color: #ffffff !important;
    color: #1a1a1a !important;
}

/* Force backgrounds on all grouping elements */
[data-theme="light"] .landing-page-wrapper,
[data-theme="light"] .landing-content-wrapper,
[data-theme="light"] .landing-main-content,
[data-theme="light"] .landing-contact,
[data-theme="light"] article,
[data-theme="light"] section,
[data-theme="light"] .entry-content,
[data-theme="light"] .wp-site-blocks,
[data-theme="light"] .gutenberg-block,
[data-theme="light"] .block-editor-block-list__block {
    background-color: #ffffff !important;
    color: #1a1a1a !important;
}

/* Force Text Colors */
[data-theme="light"] h1,
[data-theme="light"] h2,
[data-theme="light"] h3,
[data-theme="light"] h4,
[data-theme="light"] h5,
[data-theme="light"] h6,
[data-theme="light"] p,
[data-theme="light"] li,
[data-theme="light"] span,
[data-theme="light"] div {
    color: #1a1a1a;
}

/* Exceptions for specific UI elements */
[data-theme="light"] .btn-primary,
[data-theme="light"] .badge,
[data-theme="light"] .label,
[data-theme="light"] .landing-contact h2 {
    color: #000 !important;
    /* Ensure headers in contact section are dark */
}

/* Fix specific dark utility classes */
[data-theme="light"] .bg-dark,
[data-theme="light"] .has-background-dark,
[data-theme="light"] .has-black-background-color {
    background-color: #f2f2f2 !important;
    color: #1a1a1a !important;
}

/* Property Cards & Contour Improvements */
[data-theme="light"] .property-card,
[data-theme="light"] .card,
[data-theme="light"] .box,
[data-theme="light"] .feature-box,
[data-theme="light"] .wp-block-group,
[data-theme="light"] .wp-block-column,
[data-theme="light"] .stat-item,
[data-theme="light"] .contact-form-wrapper {
    background-color: #ffffff !important;
    border: 1px solid #d1d1d1 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08) !important;
}

/* Accent Colors Visibility */
[data-theme="light"] .stat-number,
[data-theme="light"] .price-value,
[data-theme="light"] .accent-text,
[data-theme="light"] a {
    color: #B08D55 !important;
    /* Darker Gold for visibility on white */
}

[data-theme="light"] a:hover {
    color: #8A6E3E !important;
}

[data-theme="light"] .btn-primary {
    background-color: #B08D55 !important;
    color: #ffffff !important;
    border: none !important;
}

/* Inputs */
[data-theme="light"] input,
[data-theme="light"] textarea,
[data-theme="light"] select {
    background-color: #ffffff !important;
    border: 1px solid #ccc !important;
    color: #1a1a1a !important;
}

[data-theme="light"] ::placeholder {
    color: #666 !important;
}

/* ==========================================================================
   Forminator Contact Form Styling (Luxury & High Conversion)
   ========================================================================== */

/* 
 * WRAPPER & CONTAINER 
 * Uses a glassmorphism approach for dark mode and clean minimalism for light mode.
 */
.landing-contact-container .forminator-ui,
.custom-form-shortcode .forminator-ui,
.casanilo-contact-form-wrapper .forminator-ui {
    background: rgba(20, 20, 20, 0.6) !important;
    /* Semi-transparent dark styling */
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    padding: 3.5rem 2.5rem !important;
    border-radius: 4px !important;
    /* Sharp, elegant corners */
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.3) !important;
    width: 100% !important;
    max-width: 580px !important;
    margin: 0 auto !important;
    position: relative !important;
}

/* Elegant Gold Top Border (Accent) */
.landing-contact-container .forminator-ui::before,
.custom-form-shortcode .forminator-ui::before,
.casanilo-contact-form-wrapper .forminator-ui::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--accent), transparent);
    opacity: 1;
}

/* 
 * TYPOGRAPHY & LABELS 
 * Refined, uppercase, tracked-out labels for a premium feel.
 */
.landing-contact-container .forminator-ui .forminator-label,
.custom-form-shortcode .forminator-ui .forminator-label,
.casanilo-contact-form-wrapper .forminator-ui .forminator-label {
    font-family: 'Outfit', 'Inter', sans-serif !important;
    font-size: 0.75rem !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 1.5px !important;
    color: rgba(255, 255, 255, 0.7) !important;
    margin-bottom: 0.75rem !important;
    display: block !important;
}

/* Required Asterisk */
.landing-contact-container .forminator-ui .forminator-required,
.custom-form-shortcode .forminator-ui .forminator-required,
.casanilo-contact-form-wrapper .forminator-ui .forminator-required {
    color: var(--accent) !important;
    font-weight: normal !important;
}

/* 
 * INPUTS & TEXTAREAS 
 * Minimalist, underlined style or clean box depending on preference. 
 * Using clean box for better conversion usability.
 */
.landing-contact-container .forminator-ui .forminator-input,
.landing-contact-container .forminator-ui .forminator-textarea,
.custom-form-shortcode .forminator-ui .forminator-input,
.custom-form-shortcode .forminator-ui .forminator-textarea,
.casanilo-contact-form-wrapper .forminator-ui .forminator-input,
.casanilo-contact-form-wrapper .forminator-ui .forminator-textarea {
    background-color: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.12) !important;
    border-radius: 0 !important;
    /* Square sharp edges for luxury feel */
    color: #fff !important;
    padding: 16px 18px !important;
    font-size: 0.95rem !important;
    font-family: 'Outfit', 'Inter', sans-serif !important;
    font-weight: 400 !important;
    transition: all 0.3s ease !important;
    box-shadow: none !important;
}

/* Placeholders */
.landing-contact-container .forminator-ui .forminator-input::placeholder,
.landing-contact-container .forminator-ui .forminator-textarea::placeholder,
.custom-form-shortcode .forminator-ui .forminator-input::placeholder,
.custom-form-shortcode .forminator-ui .forminator-textarea::placeholder,
.casanilo-contact-form-wrapper .forminator-ui .forminator-input::placeholder,
.casanilo-contact-form-wrapper .forminator-ui .forminator-textarea::placeholder {
    color: rgba(255, 255, 255, 0.3) !important;
    font-weight: 300 !important;
}

/* Focus State */
.landing-contact-container .forminator-ui .forminator-input:focus,
.landing-contact-container .forminator-ui .forminator-textarea:focus,
.custom-form-shortcode .forminator-ui .forminator-input:focus,
.custom-form-shortcode .forminator-ui .forminator-textarea:focus,
.casanilo-contact-form-wrapper .forminator-ui .forminator-input:focus,
.casanilo-contact-form-wrapper .forminator-ui .forminator-textarea:focus {
    border-color: var(--accent) !important;
    background-color: rgba(255, 255, 255, 0.05) !important;
    box-shadow: 0 0 0 1px rgba(176, 141, 85, 0.2) !important;
    outline: none !important;
}

/* 
 * SUBMIT BUTTON 
 * The centerpiece of conversion. Bold, Gold, High Contrast.
 */
.landing-contact-container .forminator-ui .forminator-button-submit,
.custom-form-shortcode .forminator-ui .forminator-button-submit,
.casanilo-contact-form-wrapper .forminator-ui .forminator-button-submit {
    background: #B08D55 !important;
    /* Solid gold base */
    background: linear-gradient(135deg, #C5A065 0%, #9E7D47 100%) !important;
    /* Refined luxury gradient */
    color: #FFFFFF !important;
    border: none !important;
    border-radius: 0 !important;
    /* Sharp corners */
    padding: 20px 40px !important;
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 2px !important;
    cursor: pointer !important;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3) !important;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1) !important;
    width: 100% !important;
    margin-top: 1.5rem !important;
    position: relative !important;
    overflow: hidden !important;
}

/* Button Hover - Shine Effect */
.landing-contact-container .forminator-ui .forminator-button-submit:hover,
.custom-form-shortcode .forminator-ui .forminator-button-submit:hover,
.casanilo-contact-form-wrapper .forminator-ui .forminator-button-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 35px rgba(176, 141, 85, 0.25) !important;
    background: linear-gradient(135deg, #D4AF74 0%, #B08D55 100%) !important;
}

/* Row Spacing */
.landing-contact-container .forminator-ui .forminator-row,
.custom-form-shortcode .forminator-ui .forminator-row,
.casanilo-contact-form-wrapper .forminator-ui .forminator-row {
    margin-bottom: 2rem !important;
}

/* Error Messages */
.landing-contact-container .forminator-ui .forminator-error-message,
.custom-form-shortcode .forminator-ui .forminator-error-message,
.casanilo-contact-form-wrapper .forminator-ui .forminator-error-message {
    font-size: 0.75rem !important;
    margin-top: 0.5rem !important;
    color: #ff8e8e !important;
    font-weight: 500 !important;
    letter-spacing: 0.5px !important;
}

/* 
 * =========================================
 * LIGHT MODE OVERRIDES - Clean & Stark
 * =========================================
 */
[data-theme="light"] .landing-contact-container .forminator-ui,
[data-theme="light"] .custom-form-shortcode .forminator-ui,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui {
    background: #ffffff !important;
    border: 1px solid #e5e5e5 !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.06) !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-label,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-label,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-label {
    color: #1a1a1a !important;
    font-weight: 700 !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-input,
[data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea {
    background-color: #ffffff !important;
    border: 1px solid #e0e0e0 !important;
    color: #1a1a1a !important;
    box-shadow: none !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-input:focus,
[data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea:focus,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input:focus,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea:focus,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input:focus,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea:focus {
    border-color: var(--accent) !important;
    background-color: #ffffff !important;
    box-shadow: 0 0 0 1px rgba(176, 141, 85, 0.2) !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-input::placeholder,
[data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea::placeholder,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input::placeholder,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea::placeholder,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input::placeholder,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea::placeholder {
    color: #999 !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-button-submit,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-button-submit,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-button-submit {
    /* Strong Gold, retaining white text for contrast */
    background: linear-gradient(135deg, #B08D55 0%, #8A6E3E 100%) !important;
    color: #ffffff !important;
    box-shadow: 0 10px 25px rgba(176, 141, 85, 0.2) !important;
}

/* Description/Counter Text */
.landing-contact-container .forminator-ui .forminator-description,
.custom-form-shortcode .forminator-ui .forminator-description,
.casanilo-contact-form-wrapper .forminator-ui .forminator-description {
    color: rgba(255, 255, 255, 0.5) !important;
    font-size: 0.75rem !important;
    text-align: right !important;
    display: block !important;
    margin-top: 5px !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-description,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-description,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-description {
    color: #888 !important;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {

    .landing-contact-container .forminator-ui,
    .custom-form-shortcode .forminator-ui,
    .casanilo-contact-form-wrapper .forminator-ui {
        padding: 2rem 1.5rem !important;
    }
}

/* Description/Counter Text */
.landing-contact-container .forminator-ui .forminator-description,
.custom-form-shortcode .forminator-ui .forminator-description,
.casanilo-contact-form-wrapper .forminator-ui .forminator-description {
    color: var(--text-muted);
    font-size: 0.8rem;
    text-align: right;
    display: block;
    margin-top: 5px;
}

/* Mobile Responsiveness */
@media (max-width: 768px) {

    .landing-contact-container .forminator-ui,
    .custom-form-shortcode .forminator-ui,
    .casanilo-contact-form-wrapper .forminator-ui {
        padding: 2rem 1.5rem;
    }
}

[data-theme="light"] footer {
    background-color: #f9f9f9 !important;
    color: #333 !important;
    border-top: 1px solid #e0e0e0;
}

[data-theme="light"] footer h4 {
    color: #000 !important;
}

[data-theme="light"] footer a {
    color: #555 !important;
}

[data-theme="light"] footer a:hover {
    color: #B08D55 !important;
}

/* ==========================================================================
   Index Template Styles (Moved from index.php)
   ========================================================================== */
.content-page {
    padding: 2rem 5%;
}

.content-wrapper {
    max-width: 800px;
    margin: 0 auto;
}

.post-thumbnail {
    margin-bottom: 2rem;
}

.post-thumbnail img {
    width: 100%;
    border-radius: 12px;
}

.post-content {
    line-height: 1.8;
    color: var(--text);
}

.post-content h2,
.post-content h3 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.post-content p {
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

.post-content a {
    color: var(--accent);
}

/* ==========================================================================
   Contact Page Styles (Moved from page-contato.php)
   ========================================================================== */
.contact-hero {
    text-align: center;
    margin-bottom: 3rem;
}

.contact-hero h1 {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.page-subtitle {
    color: var(--text-muted);
    font-size: 1.1rem;
}

.contact-form-box,
.contact-info-box {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.contact-form-box h3,
.contact-info-box h3 {
    color: var(--accent);
    margin-bottom: 1.5rem;
    font-size: 1.3rem;
}

.contact-info-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.contact-info-item .icon {
    width: 44px;
    height: 44px;
    background: rgba(201, 169, 98, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    flex-shrink: 0;
}

.contact-info-item .info {
    display: flex;
    flex-direction: column;
}

.contact-info-item .info strong {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.3rem;
}

.contact-info-item .info a,
.contact-info-item .info span {
    color: var(--text);
    font-size: 1rem;
}

.contact-info-item .info a:hover {
    color: var(--accent);
}

.contact-social {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.contact-social h4 {
    font-size: 0.9rem;
    margin-bottom: 1rem;
    color: var(--text-muted);
}

.social-links {
    display: flex;
    gap: 0.8rem;
}

.social-link {
    padding: 0.5rem 1rem;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: var(--accent);
    color: #1a1a1a;
}

.page-content {
    max-width: 800px;
    margin: 3rem auto 0;
    line-height: 1.8;
}

/* ==========================================================================
   About Page Styles (Moved from page-sobre.php)
   ========================================================================== */
.about-hero {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

.about-hero h1 {
    font-size: 3rem;
    margin-bottom: 1.5rem;
}

.about-subtitle {
    color: var(--text-muted);
    font-size: 1.2rem;
    line-height: 1.7;
}

.about-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
    align-items: center;
}

.about-content.no-about-image {
    grid-template-columns: 1fr;
    max-width: 860px;
}

.about-content.no-about-image .about-text {
    max-width: 100%;
    margin: 0 auto;
}

.about-text {
    line-height: 1.8;
    color: var(--text);
}

.about-text h2 {
    color: var(--accent);
    margin-bottom: 1.5rem;
}

.about-text p {
    margin-bottom: 1.5rem;
    color: var(--text-muted);
}

.about-image img {
    width: 100%;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.about-values {
    margin-top: 4rem;
    padding-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

@media (max-width: 768px) {
    .about-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .about-hero h1 {
        font-size: 2rem;
    }
}

/* ==========================================================================
   Landing Page Styles (Moved from template-landing.php)
   ========================================================================== */
.landing-page {
    background: var(--bg-dark);
}

.urgency-bar {
    background: linear-gradient(135deg, #ff4444, #cc0000);
    color: white;
    text-align: center;
    padding: 0.8rem;
    font-weight: 600;
    font-size: 0.9rem;
    position: fixed;
    top: 60px;
    left: 0;
    right: 0;
    z-index: 999;
    animation: pulse 2s infinite;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.8;
    }
}

body.admin-bar .urgency-bar {
    top: 92px;
}

.landing-hero {
    min-height: 80vh;
    display: flex;
    align-items: center;
    background-size: cover;
    background-position: center;
    position: relative;
}

.landing-hero::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.4));
}

.landing-content {
    position: relative;
    z-index: 1;
    max-width: 600px;
    padding: 5%;
}

.landing-content h1 {
    font-size: clamp(2.5rem, 5vw, 4rem);
    margin-bottom: 1rem;
    line-height: 1.1;
}

.landing-subtitle {
    font-size: 1.2rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.6;
}

.landing-price {
    margin-bottom: 2rem;
}

.price-label {
    display: block;
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
}

.price-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--accent);
}

.landing-cta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.landing-main-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 4rem 5%;
}

.landing-main-content>* {
    margin-bottom: 2rem;
}

.landing-contact {
    background: var(--secondary);
    padding: 4rem 5%;
}

.landing-contact-container {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.landing-contact h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.landing-contact p {
    color: var(--text-muted);
    margin-bottom: 2rem;
    line-height: 1.7;
}

.contact-form-wrapper {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

@media (max-width: 768px) {
    .landing-hero {
        min-height: 60vh;
    }

    .landing-content h1 {
        font-size: 2rem;
    }

    .landing-contact-container {
        grid-template-columns: 1fr;
        gap: 2rem;
    }
}

/* ==========================================================================
   Compact Contact Form Styles (Forminator - STACKED, COMPACT & CENTERED - User Requested)
   ========================================================================== */

/* Main Section - Remove vertical bloat */
.form-section {
    padding-top: 0.5rem !important;
    padding-bottom: 0.5rem !important;
}

/* Header - Tighten */
.form-section .section-header {
    margin-bottom: 0.5rem !important;
}

.form-section .section-label {
    margin-bottom: 0.2rem !important;
    font-size: 0.7rem !important;
}

.form-section .section-title {
    margin-bottom: 0.2rem !important;
    font-size: 1.4rem !important;
}

.form-section .section-description {
    margin-bottom: 0.5rem !important;
    font-size: 0.85rem !important;
}

/* Container & Form Wrapper */
.landing-contact-container,
.custom-form-shortcode {
    padding: 0 !important;
    width: 100% !important;
    max-width: 1000px !important;
    /* Keep outer restraint */
    margin: 0 auto !important;
    /* Center the block */
    display: flex !important;
    justify-content: center !important;
    /* Flex center */
}

/* Forminator UI Container */
.landing-contact-container .forminator-ui {
    display: block !important;
    width: 100% !important;
    max-width: 100% !important;
    /* Fill the container */
    margin: 0 auto !important;
}

/* Rows - Stacked & Tight */
.landing-contact-container .forminator-ui .forminator-row {
    margin-bottom: 4px !important;
    padding-bottom: 0 !important;
    width: 100% !important;
    display: block !important;
    margin-left: auto !important;
    margin-right: auto !important;
}

/* Fields - Full Width */
.landing-contact-container .forminator-ui .forminator-col {
    padding: 0 !important;
    margin: 0 !important;
    width: 100% !important;
}

/* Ensure Side-by-side rules are killed */
.landing-contact-container .forminator-ui .forminator-row:has(.forminator-field-name),
.landing-contact-container .forminator-ui .forminator-row:has(.forminator-field-email),
.landing-contact-container .forminator-ui .forminator-row:has(.forminator-field-phone) {
    width: 100% !important;
    flex: none !important;
}

/* Input Height - Ultra Compact */
.landing-contact-container .forminator-ui .forminator-input {
    height: 32px !important;
    /* Minimum viable height */
    min-height: 32px !important;
    padding: 0 0.5rem !important;
    font-size: 0.85rem !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    margin-top: 0 !important;
    width: 100% !important;
}

/* Textarea Height */
.landing-contact-container .forminator-ui .forminator-textarea {
    min-height: 60px !important;
    height: 60px !important;
    padding: 0.5rem 0.5rem !important;
    font-size: 0.85rem !important;
    margin-bottom: 0 !important;
    background: rgba(255, 255, 255, 0.05) !important;
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    width: 100% !important;
}

/* Label - Integrated feeling */
.landing-contact-container .forminator-ui .forminator-label {
    font-size: 0.7rem !important;
    margin-bottom: 1px !important;
    color: var(--text-muted) !important;
    font-weight: 500 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
}

/* Error Messages - Control height if they appear */
.landing-contact-container .forminator-ui .forminator-error-message {
    margin-top: 2px !important;
    font-size: 0.7rem !important;
    text-align: left !important;
}

/* Button */
.landing-contact-container .forminator-ui .forminator-button-submit {
    margin-top: 5px !important;
    padding: 0 2rem !important;
    height: 36px !important;
    width: 100% !important;
    line-height: 36px !important;
    background: var(--accent) !important;
    color: #000 !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
}

/* ==========================================================================
   Light Mode Refinement - Home (No Layout Changes)
   ========================================================================== */
[data-theme="light"] body.home {
    background: #f7f4ed !important;
    color: #201a12 !important;
}

body.home .navbar {
    background: linear-gradient(180deg, rgba(9, 9, 9, 0.72) 0%, rgba(9, 9, 9, 0.42) 52%, rgba(9, 9, 9, 0) 100%) !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

[data-theme="light"] body.home .navbar {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.78) 0%, rgba(255, 255, 255, 0.42) 52%, rgba(255, 255, 255, 0) 100%) !important;
    border-bottom: none !important;
    box-shadow: none !important;
}

[data-theme="light"] body.home .navbar::after {
    opacity: 0.55;
}

[data-theme="light"] body.home .nav-menu a {
    color: #3a3125 !important;
}

[data-theme="light"] body.home .nav-menu a:hover,
[data-theme="light"] body.home .nav-menu a:focus,
[data-theme="light"] body.home .nav-menu a.active {
    color: #8e6b35 !important;
}

[data-theme="light"] body.home .hero {
    background: linear-gradient(140deg, rgba(10, 10, 10, 0.64), rgba(34, 30, 22, 0.54)),
        url('assets/images/hero-bg.jpg') center/cover no-repeat !important;
}

[data-theme="light"] body.home .hero-title,
[data-theme="light"] body.home .hero-tagline {
    color: #f8f6f2 !important;
}

[data-theme="light"] body.home .hero-subtitle {
    color: rgba(246, 240, 229, 0.92) !important;
}

[data-theme="light"] body.home .hero-title span {
    color: #d7ba7f !important;
}

[data-theme="light"] body.home .quick-search {
    background: linear-gradient(145deg, rgba(24, 24, 24, 0.52), rgba(12, 12, 12, 0.45)) !important;
    border: 1px solid rgba(212, 185, 120, 0.46) !important;
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.26), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

[data-theme="light"] body.home .quick-search input {
    color: #2a2217 !important;
    background: #fffdf8 !important;
    caret-color: #2a2217 !important;
}

[data-theme="light"] body.home .quick-search input::placeholder {
    color: #7a6546 !important;
    opacity: 1 !important;
}

[data-theme="light"] body.home .quick-search input:focus {
    color: #241d14 !important;
    background: #ffffff !important;
}

[data-theme="light"] body.home .main-container {
    background: linear-gradient(180deg, #f7f4ed 0%, #f1ece2 100%) !important;
}

[data-theme="light"] body.home .filters-sidebar,
[data-theme="light"] body.home .filters-sticky-wrapper .filters-sidebar {
    background: linear-gradient(160deg, #fffdf8 0%, #f8f2e7 100%) !important;
    border: 1px solid rgba(176, 141, 85, 0.24) !important;
    box-shadow: 0 14px 32px rgba(53, 41, 20, 0.09) !important;
}

[data-theme="light"] body.home .results-header {
    background: linear-gradient(160deg, #fffdf9, #f7f2e8) !important;
    border: 1px solid rgba(176, 141, 85, 0.24) !important;
    box-shadow: 0 10px 26px rgba(53, 41, 20, 0.08) !important;
}

[data-theme="light"] body.home .results-count {
    color: #5e513f !important;
}

[data-theme="light"] body.home .results-count strong {
    color: #8f6a32 !important;
}

[data-theme="light"] .results-sort label,
[data-theme="light"] .badge-listing-sort label {
    color: #6d5a42 !important;
}

[data-theme="light"] .results-sort select,
[data-theme="light"] .badge-sort-select {
    background: #fffdf8 !important;
    border: 1px solid rgba(176, 141, 85, 0.34) !important;
    color: #2d2215 !important;
}

[data-theme="light"] body.home .property-card {
    background: linear-gradient(160deg, #fffefb 0%, #f9f3e8 100%) !important;
    border: 1px solid rgba(176, 141, 85, 0.22) !important;
    box-shadow: 0 12px 30px rgba(53, 41, 20, 0.08) !important;
}

[data-theme="light"] body.home .property-card:hover {
    border-color: rgba(176, 141, 85, 0.5) !important;
    box-shadow: 0 22px 44px rgba(53, 41, 20, 0.16) !important;
}

[data-theme="light"] body.home .property-title {
    color: #1f1911 !important;
}

[data-theme="light"] body.home .property-location {
    color: #665743 !important;
}

[data-theme="light"] body.home .property-price {
    color: var(--price-gold-dark) !important;
}

[data-theme="light"] body.home .property-features {
    border-top: 1px solid rgba(176, 141, 85, 0.2) !important;
}

[data-theme="light"] body.home .feature-item {
    color: #5f523f !important;
}

[data-theme="light"] body.home #mapView {
    border: 1px solid rgba(176, 141, 85, 0.24) !important;
    box-shadow: 0 14px 28px rgba(53, 41, 20, 0.09) !important;
}

[data-theme="light"] body.home .btn-primary,
[data-theme="light"] body.home .search-button,
[data-theme="light"] body.home .apply-filters-btn {
    background: linear-gradient(135deg, #b79253 0%, #8d6b36 100%) !important;
    color: #17120a !important;
    border: 1px solid rgba(142, 106, 54, 0.36) !important;
}

[data-theme="light"] body.home .btn-primary:hover,
[data-theme="light"] body.home .search-button:hover,
[data-theme="light"] body.home .apply-filters-btn:hover {
    background: linear-gradient(135deg, #c3a064 0%, #a37d42 100%) !important;
    box-shadow: 0 12px 30px rgba(176, 141, 85, 0.28) !important;
}

/* Light mode filter dropdown readability fix */
[data-theme="light"] .custom-multiselect.open .select-dropdown,
[data-theme="light"] .select-dropdown {
    background: linear-gradient(170deg, #fffefb 0%, #f4ecdf 100%) !important;
    border: 1px solid rgba(176, 141, 85, 0.44) !important;
    box-shadow: 0 18px 36px rgba(59, 44, 20, 0.18) !important;
}

[data-theme="light"] .select-dropdown .checkbox-item {
    color: #2f2518 !important;
    font-weight: 500 !important;
}

[data-theme="light"] .select-dropdown .checkbox-item:hover {
    background: rgba(176, 141, 85, 0.14) !important;
}

[data-theme="light"] .select-dropdown .filter-checkbox {
    border-color: rgba(121, 99, 61, 0.5) !important;
    background: #fff !important;
}

[data-theme="light"] .select-dropdown .filter-checkbox:checked {
    background: #b08d55 !important;
    border-color: #8e6b35 !important;
}

[data-theme="light"] .select-dropdown::-webkit-scrollbar {
    width: 8px;
}

[data-theme="light"] .select-dropdown::-webkit-scrollbar-track {
    background: rgba(176, 141, 85, 0.09);
    border-radius: 8px;
}

[data-theme="light"] .select-dropdown::-webkit-scrollbar-thumb {
    background: rgba(176, 141, 85, 0.45);
    border-radius: 8px;
}

/* Light mode palette distribution polish (home + generic components) */
[data-theme="light"] .filters-header h3,
[data-theme="light"] .filter-section h4 {
    color: #4f3f29 !important;
}

[data-theme="light"] .clear-filters {
    color: #6b5a42 !important;
    border-color: rgba(176, 141, 85, 0.3) !important;
    background: rgba(255, 255, 255, 0.75) !important;
}

[data-theme="light"] .clear-filters:hover {
    color: #8e6b35 !important;
    background: rgba(176, 141, 85, 0.11) !important;
}

[data-theme="light"] footer,
[data-theme="light"] .site-footer,
[data-theme="light"] .footer {
    background: linear-gradient(180deg, #f7f2e7 0%, #f3ecde 100%) !important;
    border-top: 1px solid rgba(176, 141, 85, 0.25) !important;
    color: #2a2218 !important;
}

/* Light mode range sliders: clearer track and thumb above the bar */
[data-theme="light"] .dual-range {
    height: 6px !important;
    background: rgba(126, 105, 68, 0.22) !important;
    border-radius: 999px !important;
}

[data-theme="light"] .dual-range .track {
    height: 6px !important;
    background: linear-gradient(90deg, #c8a364 0%, #a78042 100%) !important;
    border-radius: 999px !important;
    z-index: 2 !important;
}

[data-theme="light"] .dual-range input[type="range"] {
    top: -9px !important;
    height: 24px !important;
    z-index: 4 !important;
    background: transparent !important;
}

[data-theme="light"] .dual-range input[type="range"]::-webkit-slider-runnable-track {
    height: 6px !important;
    background: transparent !important;
    border: none !important;
}

[data-theme="light"] .dual-range input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none !important;
    width: 20px !important;
    height: 20px !important;
    border-radius: 50% !important;
    background: #b08d55 !important;
    border: 3px solid #fdfbf6 !important;
    box-shadow: 0 4px 12px rgba(49, 36, 16, 0.28) !important;
    margin-top: -7px !important;
    position: relative !important;
    z-index: 6 !important;
}

[data-theme="light"] .dual-range input[type="range"]::-moz-range-track {
    height: 6px !important;
    background: transparent !important;
    border: none !important;
}

[data-theme="light"] .dual-range input[type="range"]::-moz-range-thumb {
    width: 20px !important;
    height: 20px !important;
    border-radius: 50% !important;
    background: #b08d55 !important;
    border: 3px solid #fdfbf6 !important;
    box-shadow: 0 4px 12px rgba(49, 36, 16, 0.28) !important;
}

[data-theme="light"] .nav-menu .sub-menu {
    background: linear-gradient(160deg, #fffefb 0%, #f4ecdd 100%);
    border-color: rgba(176, 141, 85, 0.35);
    box-shadow: 0 18px 30px rgba(62, 45, 20, 0.15);
}

[data-theme="light"] .nav-menu .sub-menu a {
    color: #3f301c;
}

[data-theme="light"] .nav-menu .sub-menu a:hover {
    color: #16120a;
}

[data-theme="light"] .badge-listing-section {
    background: linear-gradient(165deg, #fffefb 0%, #f6efe1 100%);
    border-color: rgba(176, 141, 85, 0.28);
}

[data-theme="light"] .badge-listing-header h2::after {
    background: linear-gradient(90deg, transparent, rgba(176, 141, 85, 0.95), transparent);
}

[data-theme="light"] .badge-property-card>a {
    background: linear-gradient(165deg, #ffffff 0%, #f7f1e6 100%);
    border-color: rgba(176, 141, 85, 0.24);
}

/* Light Theme - Elegant card elevation across the interface */
[data-theme="light"] .property-card,
[data-theme="light"] .badge-property-card>a,
[data-theme="light"] .related-property-card,
[data-theme="light"] .feature-box,
[data-theme="light"] .stat-item,
[data-theme="light"] .contact-form-wrapper,
[data-theme="light"] .wp-block-group,
[data-theme="light"] .wp-block-column,
[data-theme="light"] .card,
[data-theme="light"] .box {
    box-shadow: var(--card-shadow-elegant) !important;
}

[data-theme="light"] .badge-property-card {
    background: transparent !important;
    border: 0 !important;
    box-shadow: none !important;
    filter: none !important;
}

[data-theme="light"] .badge-carousel-viewport {
    padding: 0.45rem 0.35rem 0.95rem;
    margin: -0.45rem -0.35rem -0.95rem;
}

[data-theme="light"] .results-area.map-active .properties-grid {
    padding: 0.65rem 0.62rem 0.6rem 0.2rem;
}

[data-theme="light"] .badge-property-card>a,
[data-theme="light"] .related-property-card,
[data-theme="light"] .feature-box,
[data-theme="light"] .stat-item,
[data-theme="light"] .contact-form-wrapper,
[data-theme="light"] .wp-block-group,
[data-theme="light"] .wp-block-column,
[data-theme="light"] .card,
[data-theme="light"] .box {
    transition: box-shadow 0.28s ease;
}

[data-theme="light"] .property-card:hover,
[data-theme="light"] .badge-property-card>a:hover,
[data-theme="light"] .related-property-card:hover,
[data-theme="light"] .card:hover,
[data-theme="light"] .box:hover {
    box-shadow: var(--card-shadow-elegant-hover) !important;
}

[data-theme="light"] .badge-property-content h3 {
    color: #2f2416;
}

[data-theme="light"] .badge-property-price,
[data-theme="light"] .map-popup-price,
[data-theme="light"] .price-value,
[data-theme="light"] .property-info .price {
    color: var(--price-gold-dark) !important;
}

[data-theme="light"] .badge-property-meta {
    color: #6b5a42;
}

[data-theme="light"] .badge-property-meta span {
    background: rgba(176, 141, 85, 0.08);
    border-color: rgba(176, 141, 85, 0.2);
}

[data-theme="light"] .map-popup-chip {
    background: rgba(176, 141, 85, 0.12);
    border-color: rgba(176, 141, 85, 0.34);
    color: #3b2c1a;
}

/* ==========================================================================
   UX Fixes: Home light palette + contact form labels visibility
   ========================================================================== */
[data-theme="light"] body.home .home-filter-hub {
    background: linear-gradient(165deg, rgba(255, 253, 248, 0.98), rgba(245, 238, 226, 0.98)) !important;
    border: 1px solid rgba(176, 141, 85, 0.34) !important;
    box-shadow: 0 14px 30px rgba(58, 43, 20, 0.12) !important;
}

[data-theme="light"] body.home .home-filter-field label {
    color: #4a3a25 !important;
}

[data-theme="light"] body.home .home-filter-field select {
    background: #fffdf9 !important;
    border: 1px solid rgba(120, 96, 58, 0.36) !important;
    color: #2c2318 !important;
}

[data-theme="light"] body.home .home-filter-submit-btn {
    background: linear-gradient(135deg, #bb9758 0%, #916f3a 100%) !important;
    color: #17120a !important;
}

.landing-contact-container .forminator-ui .forminator-label,
.custom-form-shortcode .forminator-ui .forminator-label,
.casanilo-contact-form-wrapper .forminator-ui .forminator-label,
.landing-contact-container .forminator-ui .casanilo-generated-label,
.custom-form-shortcode .forminator-ui .casanilo-generated-label,
.casanilo-contact-form-wrapper .forminator-ui .casanilo-generated-label {
    display: block !important;
    visibility: visible !important;
    opacity: 1 !important;
    min-height: 14px !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-label,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-label,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-label,
[data-theme="light"] .landing-contact-container .forminator-ui .casanilo-generated-label,
[data-theme="light"] .custom-form-shortcode .forminator-ui .casanilo-generated-label,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .casanilo-generated-label {
    color: #342819 !important;
    font-weight: 700 !important;
    letter-spacing: 0.09em !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-input,
[data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea {
    background: #fcfaf5 !important;
    border: 1px solid rgba(176, 141, 85, 0.34) !important;
    color: #241d14 !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-input::placeholder,
[data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea::placeholder,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input::placeholder,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea::placeholder,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input::placeholder,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea::placeholder {
    color: #8f7b5a !important;
}

[data-theme="light"] .landing-contact-container .forminator-ui .forminator-error-message,
[data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-error-message,
[data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-error-message {
    color: #ba4e4e !important;
}

/* ==========================================================================
   Final Theme Consolidation: colors, filters and mobile UX
   ========================================================================== */

/* Base navbar gradient on home (dark and light tuned separately). */
body.home .navbar {
    background: linear-gradient(180deg, rgba(8, 8, 8, 0.78) 0%, rgba(8, 8, 8, 0.48) 52%, rgba(8, 8, 8, 0.02) 100%) !important;
}

[data-theme="light"] body.home .navbar {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.94) 0%, rgba(255, 255, 255, 0.78) 52%, rgba(255, 255, 255, 0.04) 100%) !important;
    border-bottom: 1px solid rgba(176, 141, 85, 0.18) !important;
}

[data-theme="light"] body.home .navbar::after {
    opacity: 0.35 !important;
}

/* Stronger default contrast for archive filters (dark mode baseline). */
.filters-sidebar {
    background: linear-gradient(165deg, #1b1c20 0%, #141519 100%);
    border: 1px solid rgba(201, 169, 98, 0.18);
}

.filters-header h3 {
    color: #d7bc82;
}

.filter-section h4 {
    color: #b8ab97;
}

.filter-section select,
.select-trigger {
    background: linear-gradient(165deg, #14161b 0%, #101217 100%);
    border: 1px solid rgba(201, 169, 98, 0.32);
    color: #f4eee2;
}

.select-trigger .trigger-text {
    color: inherit;
}

.filter-section select:focus,
.select-trigger:focus,
.custom-multiselect.open .select-trigger {
    border-color: #d4b978;
    box-shadow: 0 0 0 2px rgba(201, 169, 98, 0.2);
}

.select-dropdown {
    background: linear-gradient(170deg, #1c1e22 0%, #131519 100%);
    border: 1px solid rgba(201, 169, 98, 0.45);
    box-shadow: 0 14px 32px rgba(0, 0, 0, 0.42);
}

.checkbox-item {
    color: #efe8da;
}

.checkbox-item:hover {
    background: rgba(201, 169, 98, 0.18);
}

.filter-checkbox {
    border-color: rgba(245, 236, 219, 0.5);
    background: rgba(4, 6, 10, 0.3);
}

.filter-checkbox:checked {
    background: #c9a962;
    border-color: #d8bd83;
}

.filter-checkbox:checked::before {
    box-shadow: inset 1rem 1rem #141519;
}

/* Range sliders: clear track hierarchy and thumb over bar. */
.dual-range {
    height: 8px;
    border-radius: 999px;
    background: rgba(201, 169, 98, 0.2);
}

.dual-range .track {
    height: 8px;
    border-radius: 999px;
    background: linear-gradient(90deg, #c9a962 0%, #9e7c42 100%);
    z-index: 1;
}

.dual-range input[type="range"] {
    top: -8px;
    height: 24px;
    z-index: 3;
}

.dual-range input[type="range"]::-webkit-slider-runnable-track {
    height: 8px;
    background: transparent;
}

.dual-range input[type="range"]::-webkit-slider-thumb {
    width: 18px;
    height: 18px;
    margin-top: -5px;
    border-radius: 50%;
    border: 2px solid #0f1114;
    background: #c9a962;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.38);
    z-index: 4;
}

.dual-range input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid #0f1114;
    background: #c9a962;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.38);
}

/* Light mode final contrast pass for all filter controls. */
[data-theme="light"] .filters-sidebar {
    background: linear-gradient(168deg, #fffefb 0%, #f6efdf 100%) !important;
    border: 1px solid rgba(176, 141, 85, 0.3) !important;
    box-shadow: 0 16px 36px rgba(53, 41, 20, 0.12) !important;
}

[data-theme="light"] .filters-header h3,
[data-theme="light"] .filter-section h4 {
    color: #4d3d27 !important;
}

[data-theme="light"] .clear-filters {
    background: #fffefb !important;
    color: #67553f !important;
    border-color: rgba(176, 141, 85, 0.34) !important;
}

[data-theme="light"] .clear-filters:hover {
    background: rgba(176, 141, 85, 0.12) !important;
    color: #8d6b36 !important;
}

[data-theme="light"] .filter-section select,
[data-theme="light"] .select-trigger {
    background: #fffcf5 !important;
    border: 1px solid rgba(130, 102, 58, 0.4) !important;
    color: #2b2216 !important;
}

[data-theme="light"] .filter-section select option {
    color: #2b2216;
    background: #fffcf5;
}

[data-theme="light"] .select-dropdown {
    background: linear-gradient(170deg, #fffefb 0%, #f4ecdf 100%) !important;
    border: 1px solid rgba(176, 141, 85, 0.44) !important;
    box-shadow: 0 18px 34px rgba(55, 42, 20, 0.18) !important;
}

[data-theme="light"] .select-dropdown .checkbox-item {
    color: #2d2316 !important;
}

[data-theme="light"] .select-dropdown .checkbox-item:hover {
    background: rgba(176, 141, 85, 0.14) !important;
}

[data-theme="light"] .select-dropdown .filter-checkbox {
    background: #fffefb !important;
    border-color: rgba(133, 103, 58, 0.5) !important;
}

[data-theme="light"] .select-dropdown .filter-checkbox:checked {
    background: #b08d55 !important;
    border-color: #8e6b35 !important;
}

[data-theme="light"] .filter-checkbox:checked::before {
    box-shadow: inset 1rem 1rem #fffdf7;
}

[data-theme="light"] .dual-range {
    background: rgba(126, 105, 68, 0.24) !important;
}

[data-theme="light"] .dual-range .track {
    background: linear-gradient(90deg, #c8a364 0%, #a78042 100%) !important;
}

[data-theme="light"] .dual-range input[type="range"]::-webkit-slider-thumb,
[data-theme="light"] .dual-range input[type="range"]::-moz-range-thumb {
    border: 2px solid #fffdf7 !important;
    background: #b08d55 !important;
    box-shadow: 0 4px 12px rgba(49, 36, 16, 0.28) !important;
}

[data-theme="light"] .results-header,
[data-theme="light"] .desktop-map-toggle label {
    background: linear-gradient(165deg, #fffefb 0%, #f5eee0 100%) !important;
    border-color: rgba(176, 141, 85, 0.3) !important;
    color: #5b4a34 !important;
}

[data-theme="light"] .mobile-filter-toggle {
    background: linear-gradient(135deg, #b79253 0%, #8d6b36 100%) !important;
    color: #17120a !important;
}

[data-theme="light"] .results-quick-btn {
    background: rgba(255, 255, 255, 0.9) !important;
    border-color: rgba(176, 141, 85, 0.32) !important;
    color: #5b4a34 !important;
}

[data-theme="light"] .results-filter-pill {
    background: rgba(255, 255, 255, 0.9) !important;
    border-color: rgba(176, 141, 85, 0.34) !important;
    color: #4f3f2b !important;
}

[data-theme="light"] .results-filter-pill:hover,
[data-theme="light"] .results-filter-pill:focus {
    background: rgba(176, 141, 85, 0.16) !important;
    color: #7d5f31 !important;
}

[data-theme="light"] .result-filter-chip {
    background: rgba(176, 141, 85, 0.14) !important;
    border-color: rgba(176, 141, 85, 0.34) !important;
    color: #382b1b !important;
}

[data-theme="light"] .result-filter-chip-clear {
    background: rgba(255, 255, 255, 0.8) !important;
    color: #6f5c42 !important;
}

/* Home filter hub: dark and light mode distribution. */
body.home .home-filter-hub {
    width: min(96%, 1320px) !important;
    border-radius: 18px !important;
    padding: 0.9rem 1rem 0.8rem !important;
}


body.home .home-filter-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
    gap: 0.9rem 1rem !important;
    align-items: end !important;
}

@media (min-width: 769px) {
    body.home .hero {
        min-height: 44vh;
        padding-top: calc(var(--navbar-height) + 2rem);
        padding-bottom: 1.8rem;
    }

    body.home .hero-subtitle {
        margin-bottom: 1.65rem;
    }

    body.home .region-context {
        margin-bottom: 2.2rem;
    }

    body.home .home-filter-hub-wrap {
        margin-top: -2.1rem !important;
    }

    body.home .home-filter-grid {
        gap: 0.62rem 0.8rem !important;
    }

    body.home .home-filter-field label {
        font-size: 0.68rem !important;
    }

    body.home .home-filter-field select {
        height: 48px !important;
        font-size: 0.96rem !important;
        padding: 0.56rem 0.82rem !important;
    }

    body.home .home-filter-submit-btn {
        min-height: 48px !important;
    }

    body.home .home-filter-slider .range-values {
        margin-top: 0.4rem !important;
    }
}

@media (max-width: 980px) {
    body.home .home-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    }
}

body.home .home-filter-field {
    min-width: 0;
}

body.home .home-filter-field select {
    height: 54px !important;
    border-radius: 12px !important;
    padding: 0.68rem 0.9rem !important;
    font-size: 1rem !important;
}

body.home .home-filter-submit-btn {
    min-height: 54px !important;
    border-radius: 12px !important;
}

body.home .home-filter-slider .range-values {
    margin-top: 0.55rem !important;
}

html:not([data-theme="light"]) body.home .home-filter-slider .range-values {
    color: #decaa0 !important;
}

html:not([data-theme="light"]) body.home .home-filter-slider .range-values span {
    color: #f1e5cd !important;
    background: rgba(12, 14, 18, 0.88) !important;
    border: 1px solid rgba(201, 169, 98, 0.3) !important;
}

[data-theme="light"] body.home .home-filter-slider .range-values {
    color: #6c573a !important;
}

[data-theme="light"] body.home .home-filter-slider .range-values span {
    color: #4b3a23 !important;
    background: rgba(176, 141, 85, 0.12) !important;
    border: 1px solid rgba(176, 141, 85, 0.22) !important;
}

html:not([data-theme="light"]) body.home .home-filter-hub {
    background: linear-gradient(165deg, rgba(22, 24, 29, 0.94), rgba(14, 16, 20, 0.94)) !important;
    border: 1px solid rgba(201, 169, 98, 0.3) !important;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.34) !important;
}

html:not([data-theme="light"]) body.home .home-filter-field label {
    color: #e2d7c4 !important;
}

html:not([data-theme="light"]) body.home .home-filter-field select {
    background: #14161b !important;
    border: 1px solid rgba(201, 169, 98, 0.34) !important;
    color: #f4ede1 !important;
}

[data-theme="light"] .region-context {
    background: linear-gradient(165deg, rgba(255, 253, 248, 0.98), rgba(246, 238, 224, 0.98)) !important;
    border: 1px solid rgba(176, 141, 85, 0.34) !important;
    box-shadow: 0 10px 26px rgba(58, 43, 20, 0.1) !important;
}

[data-theme="light"] .region-context-text {
    color: #624f36 !important;
}

[data-theme="light"] .region-context-text strong {
    color: #2c2318 !important;
}

[data-theme="light"] .region-context-switch label,
[data-theme="light"] .region-context-switch-title {
    color: #6e593b !important;
}

[data-theme="light"] .region-context-switch select {
    background: #fffdf8 !important;
    border: 1px solid rgba(120, 96, 58, 0.38) !important;
    color: #2c2318 !important;
}

[data-theme="light"] .region-context-focus-btn {
    background: linear-gradient(135deg, #c4a05f 0%, #ab8344 100%) !important;
    border: 1px solid rgba(120, 96, 58, 0.45) !important;
    color: #1f170e !important;
    box-shadow: 0 8px 20px rgba(77, 56, 25, 0.18) !important;
}

[data-theme="light"] body.home .home-filter-hub {
    background: linear-gradient(165deg, rgba(255, 254, 250, 0.98), rgba(246, 238, 224, 0.98)) !important;
    border: 1px solid rgba(176, 141, 85, 0.34) !important;
    box-shadow: 0 16px 34px rgba(58, 43, 20, 0.12) !important;
}

[data-theme="light"] body.home .home-filter-field label {
    color: #4b3a24 !important;
}

[data-theme="light"] body.home .home-filter-field select {
    background: #fffdf8 !important;
    border: 1px solid rgba(120, 96, 58, 0.38) !important;
    color: #2c2318 !important;
}

[data-theme="light"] body.home .quick-search-suggestions {
    background: rgba(255, 253, 248, 0.98) !important;
    border-color: rgba(176, 141, 85, 0.34) !important;
    box-shadow: 0 16px 34px rgba(53, 41, 20, 0.16) !important;
}

[data-theme="light"] body.home .quick-search-suggestion {
    color: #2a2217 !important;
    border-bottom-color: rgba(176, 141, 85, 0.2) !important;
}

[data-theme="light"] body.home .quick-search-suggestion .meta {
    color: #6f5c42 !important;
}

[data-theme="light"] body.home .quick-search-suggestion:hover,
[data-theme="light"] body.home .quick-search-suggestion.is-active {
    background: rgba(176, 141, 85, 0.14) !important;
}

/* Mobile filters UX: better panel behavior and touch flow. */
.filters-overlay {
    display: none !important;
}

.filters-close-mobile {
    display: none;
}

@media (max-width: 768px) {
    .region-context-wrap {
        padding: 0 0.75rem;
    }

    .region-context-wrap-archive {
        padding-top: calc(var(--navbar-height) + 0.66rem);
    }

    .region-context {
        margin-bottom: 0.65rem;
        padding: 0.62rem 0.72rem;
        border-radius: 12px;
        flex-direction: column;
        align-items: stretch;
        gap: 0.45rem;
    }

    .post-type-archive-imovel .region-context {
        margin-bottom: 0.42rem;
    }

    .region-context-text {
        font-size: 0.82rem;
    }

    .region-context-switch {
        width: 100%;
        justify-content: space-between;
    }

    .region-context-switch select {
        min-width: 0;
        width: 62%;
        height: 38px;
        font-size: 0.9rem;
    }

    .region-context-focus-btn {
        min-height: 38px;
        font-size: 0.72rem;
        padding: 0.44rem 0.75rem;
    }

    .home-filter-hub-wrap {
        margin-top: -0.8rem;
        padding: 0 0.75rem 0.5rem;
    }

    .home-filter-hub {
        border-radius: 16px;
        padding: 0.95rem 0.85rem;
    }

    .home-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
        gap: 0.55rem 0.65rem !important;
    }

    .home-filter-field {
        min-width: 0;
    }

    .home-filter-field label {
        font-size: 0.66rem;
    }

    .home-filter-field select {
        height: 40px;
        font-size: 0.92rem;
        padding: 0.45rem 0.62rem;
    }

    .home-filter-field.home-filter-slider,
    .home-filter-field.home-filter-submit {
        grid-column: 1 / -1;
    }

    .quick-search-suggestions {
        left: 0.2rem;
        right: 0.2rem;
    }

    .quick-search-suggestion {
        padding: 0.66rem 0.8rem;
    }

    .filters-sidebar {
        left: 0;
        transform: translateX(-112%);
        opacity: 0;
        visibility: hidden;
        pointer-events: none;
        width: min(88vw, 360px);
        max-width: 360px;
        padding: calc(0.95rem + env(safe-area-inset-top, 0px)) 0.9rem calc(5.8rem + env(safe-area-inset-bottom, 0px));
        border-right: 1px solid rgba(201, 169, 98, 0.26);
        z-index: 2600;
        transition: transform 0.28s ease, opacity 0.2s ease, visibility 0.2s ease;
    }

    .filters-sidebar.active {
        left: 0;
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    body.filters-open .filters-sidebar {
        transform: translateX(0);
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    body.filters-open .filters-sticky-wrapper {
        z-index: 2601;
        pointer-events: auto;
    }

    .filters-sidebar .filters-header {
        position: sticky;
        top: 0;
        z-index: 20;
        background: inherit;
        margin-bottom: 0.85rem;
        padding-top: 0.15rem;
        padding-bottom: 0.65rem;
    }

    .filters-close-mobile {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(201, 169, 98, 0.35);
        border-radius: 999px;
        background: rgba(201, 169, 98, 0.12);
        color: inherit;
        font-size: 0.68rem;
        letter-spacing: 0.08em;
        text-transform: uppercase;
        padding: 0.35rem 0.75rem;
        cursor: pointer;
    }

    .filters-sidebar .apply-filters-btn {
        position: sticky;
        bottom: calc(0.7rem + env(safe-area-inset-bottom, 0px));
        z-index: 30;
        margin-top: 1.2rem;
        min-height: 44px;
    }

    .filters-overlay {
        display: block !important;
        position: fixed;
        inset: 0;
        background: rgba(2, 3, 5, 0.34);
        opacity: 0;
        visibility: hidden;
        transition: opacity 0.25s ease, visibility 0.25s ease;
        z-index: 2500;
        border: 0;
        padding: 0;
        margin: 0;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
        cursor: pointer;
        pointer-events: none;
    }

    .filters-overlay.active {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    body.filters-open .filters-overlay {
        opacity: 1;
        visibility: visible;
        pointer-events: auto;
    }

    .mobile-filter-toggle {
        bottom: calc(0.9rem + env(safe-area-inset-bottom, 0px));
        min-height: 44px;
        padding: 0.78rem 1.4rem;
        gap: 0.45rem;
        z-index: 1700;
    }

    body.filters-open .mobile-filter-toggle {
        opacity: 0;
        pointer-events: none;
        transform: translateX(-50%) translateY(22px);
    }

    .mobile-map-view {
        height: 210px !important;
        border: 1px solid rgba(201, 169, 98, 0.3);
        border-radius: 10px;
        margin-bottom: 0.8rem;
        overflow: hidden;
    }
}

@media (max-width: 520px) {
    .home-filter-grid {
        grid-template-columns: 1fr !important;
    }
}

/* Desktop tuning: keep hero + filter fully visible before fold with extra breathing room. */
@media (min-width: 1200px) {
    body.home .hero {
        min-height: 40vh !important;
        padding-top: calc(var(--navbar-height) + 1.35rem) !important;
        padding-bottom: 1.2rem !important;
    }

    body.home .hero-title {
        margin-bottom: 0.65rem !important;
        line-height: 1.08 !important;
    }

    body.home .hero-tagline {
        margin-bottom: 0.45rem !important;
    }

    body.home .hero-subtitle {
        margin-bottom: 1.2rem !important;
    }

    body.home .quick-search {
        max-width: 560px !important;
        padding: 0.42rem !important;
    }

    body.home .quick-search input {
        padding: 0.86rem 1.2rem !important;
    }

    body.home .region-context {
        margin-bottom: 2.75rem !important;
        padding: 0.56rem 0.85rem !important;
    }

    body.home .home-filter-hub-wrap {
        margin-top: -2.65rem !important;
    }

    body.home .home-filter-hub {
        padding: 0.72rem 0.9rem 0.64rem !important;
    }

    body.home .home-filter-grid {
        gap: 0.55rem 0.72rem !important;
    }

    body.home .home-filter-field select {
        height: 44px !important;
        padding: 0.48rem 0.75rem !important;
        font-size: 0.93rem !important;
    }

    body.home .home-filter-submit-btn {
        min-height: 44px !important;
    }

    body.home .home-filter-slider .range-values {
        margin-top: 0.3rem !important;
    }
}

/* Hotfix mobile: prevent horizontal overflow in the home filter hub. */
@media (max-width: 768px) {

    body.home .home-filter-hub-wrap,
    body.home .home-filter-hub,
    body.home .home-filter-form,
    body.home .home-filter-grid,
    body.home .home-filter-field,
    body.home .home-filter-field select,
    body.home .home-filter-submit-btn,
    body.home .home-filter-slider .range-slider-container,
    body.home .home-filter-slider .dual-range,
    body.home .home-filter-slider .range-values {
        width: 100%;
        max-width: 100%;
        min-width: 0;
        box-sizing: border-box;
    }

    body.home .home-filter-slider .range-values {
        display: flex;
        justify-content: space-between;
        gap: 0.45rem;
    }

    body.home .home-filter-slider .range-values span {
        max-width: calc(50% - 0.25rem);
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }
}

/* Mobile compact mode on home: bring search + filter hub closer to first fold. */
@media (max-width: 768px) {
    body.home .hero {
        min-height: auto !important;
        align-items: flex-start !important;
        padding-top: calc(var(--navbar-height) + 0.5rem) !important;
        padding-bottom: 0.45rem !important;
    }

    body.home .hero-content {
        max-width: 100% !important;
    }

    body.home .hero-title {
        font-size: clamp(1.65rem, 9.2vw, 2.5rem) !important;
        margin-bottom: 0.42rem !important;
        line-height: 1.06 !important;
    }

    body.home .hero-tagline {
        font-size: clamp(0.8rem, 4.2vw, 1.05rem) !important;
        margin-bottom: 0.28rem !important;
        letter-spacing: 0.1em !important;
    }

    body.home .hero-subtitle {
        font-size: clamp(0.78rem, 3.9vw, 0.98rem) !important;
        margin-bottom: 0.72rem !important;
    }

    body.home .quick-search {
        padding: 0.34rem !important;
        gap: 0.34rem !important;
        border-radius: 10px !important;
    }

    body.home .quick-search input {
        padding: 0.72rem 0.88rem !important;
        font-size: 0.9rem !important;
    }

    body.home .quick-search .btn {
        min-height: 42px !important;
        padding: 0.64rem 0.86rem !important;
        font-size: 0.76rem !important;
    }

    body.home .region-context-wrap {
        padding: 0 0.55rem !important;
    }

    body.home .region-context {
        margin-bottom: 0.42rem !important;
        padding: 0.5rem 0.58rem !important;
        gap: 0.34rem !important;
    }

    body.home .region-context-text {
        font-size: 0.76rem !important;
    }

    body.home .region-context-switch label {
        font-size: 0.64rem !important;
    }

    body.home .region-context-switch-title {
        font-size: 0.64rem !important;
    }

    body.home .region-context-switch select {
        height: 36px !important;
        font-size: 0.84rem !important;
        width: 60% !important;
    }

    body.home .region-context-focus-btn {
        min-height: 36px !important;
        padding: 0.4rem 0.68rem !important;
        font-size: 0.68rem !important;
        white-space: nowrap;
    }

    body.home .home-filter-hub-wrap {
        margin-top: -1.12rem !important;
        padding: 0 0.55rem 0.42rem !important;
    }

    body.home .home-filter-hub {
        border-radius: 13px !important;
        padding: 0.68rem 0.62rem !important;
    }

    body.home .home-filter-grid {
        gap: 0.46rem 0.5rem !important;
    }

    body.home .home-filter-field label {
        font-size: 0.62rem !important;
        letter-spacing: 0.07em !important;
    }

    body.home .home-filter-field select {
        height: 38px !important;
        font-size: 0.86rem !important;
        padding: 0.38rem 0.52rem !important;
        border-radius: 10px !important;
    }

    body.home .home-filter-submit-btn {
        min-height: 40px !important;
        font-size: 0.8rem !important;
    }

    body.home .home-filter-slider .range-values {
        margin-top: 0.24rem !important;
    }

    body.home .home-filter-slider .range-values span {
        font-size: 0.78rem !important;
        padding: 0.16rem 0.34rem !important;
    }
}

/* ==========================================================================
   LIGHT MODE LAYOUT PARITY LOCK (desktop + mobile)
   Mantem o layout do tema claro estritamente igual ao do tema escuro.
   Apenas geometria/espacamento/tamanho. Nao altera layout do modo escuro.
   ========================================================================== */
[data-theme="light"] body {
    font-weight: 400 !important;
}

[data-theme="light"] .btn,
[data-theme="light"] .btn-primary,
[data-theme="light"] .search-button,
[data-theme="light"] .apply-filters-btn {
    border-radius: 4px !important;
}

[data-theme="light"] .quick-search,
[data-theme="light"] .quick-search-suggestions {
    border-radius: 12px !important;
}

[data-theme="light"] .quick-search input {
    padding: 1rem 1.5rem !important;
    font-size: 0.95rem !important;
    font-weight: 300 !important;
}

[data-theme="light"] .hero-content {
    max-width: 800px !important;
    padding: 0 !important;
    margin: 0 auto !important;
}

[data-theme="light"] .filters-sidebar,
[data-theme="light"] .results-header {
    border-radius: 8px !important;
}

[data-theme="light"] .select-trigger,
[data-theme="light"] .custom-multiselect .select-trigger {
    padding: 0.6rem 0.8rem !important;
    border-radius: 6px !important;
    font-size: 0.85rem !important;
}

[data-theme="light"] .select-dropdown {
    border-radius: 8px !important;
}

[data-theme="light"] .filter-checkbox {
    width: 16px !important;
    height: 16px !important;
    border-radius: 3px !important;
}

[data-theme="light"] .property-card,
[data-theme="light"] .property-card::after {
    border-radius: 14px !important;
}

[data-theme="light"] .property-card:hover {
    transform: translateY(-6px) !important;
}

[data-theme="light"] .home-filter-hub {
    border-radius: 18px !important;
    padding: 1.15rem 1.2rem 1rem !important;
}

[data-theme="light"] .home-filter-field select {
    height: 44px !important;
    border-radius: 10px !important;
    font-size: 1rem !important;
    padding: 0.55rem 0.75rem !important;
}

[data-theme="light"] .home-filter-submit-btn {
    min-height: 46px !important;
    border-radius: 12px !important;
    font-size: 0.9rem !important;
}

@media (max-width: 768px) {
    [data-theme="light"] body.home .quick-search {
        border-radius: 10px !important;
        padding: 0.34rem !important;
        gap: 0.34rem !important;
    }

    [data-theme="light"] body.home .home-filter-hub {
        border-radius: 13px !important;
        padding: 0.68rem 0.62rem !important;
    }

    [data-theme="light"] body.home .home-filter-field select {
        height: 38px !important;
        border-radius: 10px !important;
        font-size: 0.86rem !important;
        padding: 0.38rem 0.52rem !important;
    }

    [data-theme="light"] body.home .home-filter-submit-btn {
        min-height: 40px !important;
        font-size: 0.8rem !important;
    }
}

/* Light home: keep a clear/beige panel in hero. */
[data-theme="light"] body.home .hero-content {
    background: linear-gradient(160deg, rgba(251, 244, 232, 0.95), rgba(241, 229, 203, 0.9)) !important;
    border: 1px solid rgba(138, 102, 47, 0.34) !important;
    box-shadow: 0 14px 28px rgba(61, 43, 20, 0.16) !important;
    backdrop-filter: blur(6px) !important;
    -webkit-backdrop-filter: blur(6px) !important;
}

/* Mobile light-mode contrast guard for fillable fields. */
@media (max-width: 768px) {

    [data-theme="light"] .filters-sidebar .select-trigger,
    [data-theme="light"] .filters-sidebar .filter-section select,
    [data-theme="light"] .home-filter-hub .home-filter-field select,
    [data-theme="light"] .contact-page input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]):not([type="range"]),
    [data-theme="light"] .contact-page select,
    [data-theme="light"] .contact-page textarea,
    [data-theme="light"] .landing-contact-container .forminator-ui .forminator-input,
    [data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea,
    [data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input,
    [data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea,
    [data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input,
    [data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea {
        background: #f8f1e4 !important;
        border: 1px solid rgba(120, 96, 58, 0.52) !important;
        color: #2d2316 !important;
        -webkit-text-fill-color: #2d2316 !important;
    }

    [data-theme="light"] .filters-sidebar .select-trigger .trigger-text,
    [data-theme="light"] .filters-sidebar .arrow-icon {
        color: #5f4b32 !important;
    }

    [data-theme="light"] .contact-page input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]):not([type="range"])::placeholder,
    [data-theme="light"] .contact-page textarea::placeholder,
    [data-theme="light"] .landing-contact-container .forminator-ui .forminator-input::placeholder,
    [data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea::placeholder,
    [data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input::placeholder,
    [data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea::placeholder,
    [data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input::placeholder,
    [data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea::placeholder {
        color: #6f5d45 !important;
        opacity: 1 !important;
    }

    [data-theme="light"] .filters-sidebar .select-trigger:focus,
    [data-theme="light"] .filters-sidebar .filter-section select:focus,
    [data-theme="light"] .home-filter-hub .home-filter-field select:focus,
    [data-theme="light"] .contact-page input:not([type="submit"]):not([type="button"]):not([type="checkbox"]):not([type="radio"]):not([type="range"]):focus,
    [data-theme="light"] .contact-page textarea:focus,
    [data-theme="light"] .landing-contact-container .forminator-ui .forminator-input:focus,
    [data-theme="light"] .landing-contact-container .forminator-ui .forminator-textarea:focus,
    [data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-input:focus,
    [data-theme="light"] .custom-form-shortcode .forminator-ui .forminator-textarea:focus,
    [data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-input:focus,
    [data-theme="light"] .casanilo-contact-form-wrapper .forminator-ui .forminator-textarea:focus {
        background: #fffaf0 !important;
        border-color: #8d6b36 !important;
        box-shadow: 0 0 0 2px rgba(176, 141, 85, 0.2) !important;
    }
}

/* ==========================================================================
   RESULTS PAGE REFACTOR (REAL ESTATE MODE)
   Distinct layout for archive-imovel only.
   ========================================================================== */
body.post-type-archive-imovel .region-context-wrap-archive {
    padding: 0 0.8rem 0.3rem;
}

body.post-type-archive-imovel .region-context-wrap-archive .region-context {
    margin-bottom: 0.3rem;
    padding: 0.45rem 0.75rem;
    border-radius: 10px;
}

body.post-type-archive-imovel .catalog-main-modern {
    max-width: min(98vw, 1760px);
    margin: 0 auto;
    padding: 0 0.6rem 1.15rem;
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.7rem;
}

body.post-type-archive-imovel .results-area {
    --results-header-top-offset: calc(var(--navbar-height) + 4px);
    --results-panel-top-offset: calc(var(--navbar-height) + 116px);
    --results-panel-height: clamp(460px, calc(100dvh - var(--results-panel-top-offset) - 12px), 920px);
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: auto auto minmax(0, var(--results-panel-height)) auto;
    gap: 0.72rem;
}

body.post-type-archive-imovel .results-header {
    grid-template-columns: auto minmax(0, 1fr) auto auto;
    gap: 0.52rem 0.72rem;
    padding: 0.6rem 0.72rem;
}

body.post-type-archive-imovel .results-meta-path {
    grid-column: 1 / -1;
    font-size: 0.7rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--text-muted);
    opacity: 0.9;
}

body.post-type-archive-imovel .results-count {
    margin: 0;
}

body.post-type-archive-imovel .results-filter-dock {
    grid-column: 1 / -1;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: thin;
    padding-bottom: 0.06rem;
}

body.post-type-archive-imovel .results-filter-pill {
    flex: 0 0 auto;
}

body.post-type-archive-imovel .results-toolbar {
    gap: 0.5rem;
    align-items: center;
}

body.post-type-archive-imovel .results-view-toggle {
    display: inline-flex;
    align-items: center;
    gap: 0.18rem;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 0.18rem;
    background: rgba(255, 255, 255, 0.03);
}

body.post-type-archive-imovel .results-view-btn {
    border: 0;
    border-radius: 999px;
    padding: 0.3rem 0.62rem;
    min-height: 30px;
    font-size: 0.7rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    color: var(--text-muted);
    background: transparent;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

body.post-type-archive-imovel .results-view-btn.is-active {
    background: rgba(201, 169, 98, 0.2);
    color: var(--accent);
}

body.post-type-archive-imovel .results-area .properties-grid {
    grid-column: 1;
    grid-row: 3;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    align-content: start;
    min-height: var(--results-panel-height);
    max-height: var(--results-panel-height);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding-right: 0.2rem;
    gap: 0.76rem;
    scrollbar-gutter: stable;
}

body.post-type-archive-imovel .results-area .pagination {
    grid-column: 1;
    grid-row: 4;
}

body.post-type-archive-imovel .results-area .map-panel {
    grid-column: 2;
    grid-row: 3 / 5;
    height: var(--results-panel-height);
    position: sticky;
    top: var(--results-panel-top-offset);
    z-index: 40;
}

body.post-type-archive-imovel .map-sticky-wrapper {
    position: sticky;
    top: 0;
    height: 100%;
}

body.post-type-archive-imovel #mapView {
    height: 100%;
    min-height: 420px;
}

body.post-type-archive-imovel .results-area.map-hidden {
    grid-template-columns: 1fr;
}

body.post-type-archive-imovel .results-area.map-hidden .properties-grid,
body.post-type-archive-imovel .results-area.map-hidden .pagination {
    grid-column: 1 / -1;
}

body.post-type-archive-imovel .results-area.map-hidden .properties-grid {
    max-height: none;
    min-height: 0;
    overflow: visible;
    padding-right: 0;
}

body.post-type-archive-imovel .results-area.map-hidden .map-panel {
    display: none;
}

body.post-type-archive-imovel .results-area.results-view-list .properties-grid {
    grid-template-columns: 1fr;
    gap: 0.72rem;
}

body.post-type-archive-imovel .results-area.results-view-list .property-card {
    display: grid;
    grid-template-columns: minmax(220px, 34%) minmax(0, 1fr);
    align-items: stretch;
    min-height: 214px;
    height: auto;
}

body.post-type-archive-imovel .results-area.results-view-list .property-image {
    height: 100%;
    min-height: 214px;
}

body.post-type-archive-imovel .results-area.results-view-list .property-content {
    display: flex;
    flex-direction: column;
    padding: 0.84rem 0.92rem;
    min-height: 214px;
    min-width: 0;
}

body.post-type-archive-imovel .results-area.results-view-list .property-title {
    font-size: 1.05rem;
    margin-bottom: 0.38rem;
}

body.post-type-archive-imovel .results-area.results-view-list .property-location {
    margin-bottom: 0.45rem;
}

body.post-type-archive-imovel .results-area.results-view-list .property-price {
    margin-bottom: 0.5rem;
}

body.post-type-archive-imovel .results-area.results-view-list .property-features {
    margin-top: auto;
}

body.post-type-archive-imovel .results-area.results-view-grid .properties-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.post-type-archive-imovel .results-area.map-active.results-view-grid .properties-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.post-type-archive-imovel .results-area.map-active.results-view-list .property-card {
    min-height: 214px;
}

body.post-type-archive-imovel .results-area.map-active.results-view-list .property-content {
    padding: 0.8rem 0.86rem;
}

body.post-type-archive-imovel .results-area.map-active.results-view-list .property-card {
    grid-template-columns: minmax(200px, 36%) minmax(0, 1fr);
}

@media (max-width: 1380px) {
    body.post-type-archive-imovel .results-area.results-view-list .property-card {
        grid-template-columns: minmax(180px, 38%) minmax(0, 1fr);
    }

    body.post-type-archive-imovel .results-area.results-view-list .property-image {
        min-height: 188px;
    }
}

[data-theme="light"] body.post-type-archive-imovel .results-meta-path {
    color: #6b5a42;
}

[data-theme="light"] body.post-type-archive-imovel .results-view-toggle {
    background: rgba(255, 255, 255, 0.88);
    border-color: rgba(176, 141, 85, 0.3);
}

[data-theme="light"] body.post-type-archive-imovel .results-view-btn {
    color: #675338;
}

[data-theme="light"] body.post-type-archive-imovel .results-view-btn.is-active {
    background: rgba(176, 141, 85, 0.2);
    color: #7e602f;
}

@media (max-width: 1024px) {
    body.post-type-archive-imovel .results-area {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 768px) {
    body.post-type-archive-imovel .region-context-wrap-archive {
        padding: 0 0.45rem 0.22rem;
    }

    body.post-type-archive-imovel .catalog-main-modern {
        padding: 0 0.38rem 0.8rem;
        gap: 0.5rem;
    }

    body.post-type-archive-imovel .results-area {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto auto auto;
        --results-header-top-offset: calc(var(--navbar-height) + 2px);
        --results-panel-top-offset: 0px;
        --results-panel-height: auto;
    }

    body.post-type-archive-imovel .results-header {
        grid-template-columns: 1fr auto;
        gap: 0.45rem 0.52rem;
        padding: 0.54rem 0.58rem;
    }

    body.post-type-archive-imovel .results-meta-path {
        display: none;
    }

    body.post-type-archive-imovel .results-filter-dock {
        grid-column: 1 / -1;
        padding-bottom: 0;
    }

    body.post-type-archive-imovel .results-toolbar {
        grid-column: 1 / -1;
        justify-content: space-between;
        flex-wrap: wrap;
    }

    body.post-type-archive-imovel .results-view-toggle {
        display: none;
    }

    body.post-type-archive-imovel .results-area .properties-grid {
        grid-column: 1;
        grid-row: 3;
        max-height: none;
        min-height: 0;
        overflow: visible;
        padding-right: 0;
        grid-template-columns: 1fr;
    }

    body.post-type-archive-imovel .results-area .map-panel {
        grid-column: 1;
        grid-row: 4;
        height: auto;
        position: relative;
        top: auto;
        z-index: 1;
    }

    body.post-type-archive-imovel #mapView {
        min-height: 42vh;
        height: 42vh;
    }

    body.post-type-archive-imovel .results-area .pagination {
        grid-column: 1;
        grid-row: 5;
    }
}

/* ==========================================================================
   ARCHIVE MAP PRECISION STABILIZATION
   Final override layer to remove legacy conflicts in list/map layout.
   ========================================================================== */
body.post-type-archive-imovel .results-area {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) !important;
    grid-template-rows: auto auto minmax(0, var(--results-panel-height)) auto !important;
    gap: 0.72rem !important;
    align-items: start !important;
}

body.post-type-archive-imovel .results-header,
body.post-type-archive-imovel .results-active-filters {
    grid-column: 1 / -1 !important;
}

body.post-type-archive-imovel .results-area .properties-grid {
    grid-column: 1 !important;
    grid-row: 3 !important;
    min-height: var(--results-panel-height) !important;
    max-height: var(--results-panel-height) !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    overscroll-behavior: contain !important;
}

body.post-type-archive-imovel .results-area .pagination {
    grid-column: 1 !important;
    grid-row: 4 !important;
}

body.post-type-archive-imovel .results-area .map-panel {
    grid-column: 2 !important;
    grid-row: 3 / 5 !important;
    height: var(--results-panel-height) !important;
    position: sticky !important;
    top: var(--results-panel-top-offset) !important;
    z-index: 40 !important;
}

body.post-type-archive-imovel .map-sticky-wrapper {
    position: relative !important;
    top: 0 !important;
    height: 100% !important;
    pointer-events: auto !important;
}

body.post-type-archive-imovel .map-sticky-wrapper::before {
    display: none !important;
}

body.post-type-archive-imovel #mapView {
    height: 100% !important;
    min-height: 420px !important;
}

body.post-type-archive-imovel .results-area.map-hidden {
    grid-template-columns: 1fr !important;
}

body.post-type-archive-imovel .results-area.map-hidden .properties-grid,
body.post-type-archive-imovel .results-area.map-hidden .pagination {
    grid-column: 1 / -1 !important;
}

@media (max-width: 768px) {
    body.post-type-archive-imovel .results-area {
        grid-template-columns: 1fr !important;
        grid-template-rows: auto auto auto auto auto !important;
    }

    body.post-type-archive-imovel .results-area .properties-grid {
        grid-column: 1 !important;
        grid-row: 3 !important;
        min-height: 0 !important;
        max-height: none !important;
        overflow: visible !important;
    }

    body.post-type-archive-imovel .results-area .map-panel {
        grid-column: 1 !important;
        grid-row: 4 !important;
        position: relative !important;
        top: auto !important;
        height: auto !important;
    }

    body.post-type-archive-imovel #mapView {
        min-height: 42vh !important;
        height: 42vh !important;
    }

    body.post-type-archive-imovel .results-area .pagination {
        grid-column: 1 !important;
        grid-row: 5 !important;
    }
}

body.post-type-archive-imovel .custom-map-marker {
    background: none;
    border: none;
}

body.post-type-archive-imovel .marker-container {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: visible;
}

body.post-type-archive-imovel .marker-label {
    position: absolute;
    bottom: 46px;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(160deg, rgba(22, 22, 24, 0.98), rgba(17, 17, 19, 0.95));
    color: #d6bc83;
    padding: 7px 12px 6px;
    border-radius: 10px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.82rem;
    font-weight: 700;
    white-space: nowrap;
    box-shadow: 0 7px 20px rgba(0, 0, 0, 0.45);
    border: 1px solid rgba(201, 169, 98, 0.64);
    z-index: 1000;
    max-width: 280px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

body.post-type-archive-imovel .marker-label-title {
    max-width: 230px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

body.post-type-archive-imovel .marker-label-price {
    font-size: 0.95rem;
    font-weight: 800;
    color: #e6c98b;
}

body.post-type-archive-imovel .marker-label::after {
    content: '';
    position: absolute;
    bottom: -6px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 10px;
    height: 10px;
    background-color: #1a1a1a;
    border-right: 1px solid #c9a962;
    border-bottom: 1px solid #c9a962;
}

body.post-type-archive-imovel .marker-pin-shape {
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.42));
}

body.post-type-archive-imovel .marker-pin-shape svg {
    display: block;
}

body.post-type-archive-imovel .results-map-count-marker {
    width: 42px;
    height: 42px;
    border-radius: 999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(145deg, #d8be84, #af8d4d);
    border: 2px solid rgba(255, 255, 255, 0.7);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.3);
    color: #1c1710;
    font-family: 'Montserrat', sans-serif;
    font-size: 1rem;
    font-weight: 800;
}

body.post-type-archive-imovel .results-map-count-marker span {
    line-height: 1;
}

body.post-type-archive-imovel .results-map-count-cluster {
    width: 46px;
    height: 46px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.34);
}

[data-theme="light"] body.post-type-archive-imovel .marker-label {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 242, 233, 0.98));
    color: #6f5328;
    border-color: #b08d55;
    box-shadow: 0 4px 15px rgba(122, 96, 49, 0.22);
}

[data-theme="light"] body.post-type-archive-imovel .marker-label-title {
    color: #6f5328;
}

[data-theme="light"] body.post-type-archive-imovel .marker-label::after {
    background-color: #ffffff;
    border-right-color: #b08d55;
    border-bottom-color: #b08d55;
}

[data-theme="light"] body.post-type-archive-imovel .marker-label-price {
    color: var(--price-gold-dark);
}

/* ==========================================================================
   ARCHIVE RESULTS DENSITY COMPACT MODE (desktop)
   Reduce dead space in top controls and keep more room for map/cards.
   ========================================================================== */
@media (min-width: 1025px) {
    body.post-type-archive-imovel {
        --navbar-height: 70px;
    }

    body.post-type-archive-imovel .navbar {
        min-height: var(--navbar-height);
        padding: 0.56rem 4%;
    }

    body.post-type-archive-imovel .nav-menu {
        gap: 1.45rem;
    }

    body.post-type-archive-imovel .region-context-wrap-archive {
        padding: 0 0.55rem 0.12rem;
    }

    body.post-type-archive-imovel .region-context-wrap-archive .region-context {
        margin-bottom: 0.2rem;
        padding: 0.34rem 0.56rem;
        border-radius: 10px;
        gap: 0.4rem 0.58rem;
    }

    body.post-type-archive-imovel .region-context-text {
        font-size: 0.78rem;
    }

    body.post-type-archive-imovel .region-context-switch-title {
        font-size: 0.64rem;
    }

    body.post-type-archive-imovel .region-context-focus-btn {
        min-height: 34px;
        padding: 0.36rem 0.72rem;
        font-size: 0.68rem;
    }

    body.post-type-archive-imovel .catalog-main-modern {
        gap: 0.48rem;
        padding: 0 0.54rem 0.76rem;
    }

    body.post-type-archive-imovel .results-area {
        --results-header-top-offset: calc(var(--navbar-height) + 2px) !important;
        --results-panel-top-offset: calc(var(--navbar-height) + 76px) !important;
        --results-panel-height: clamp(530px, calc(100dvh - var(--results-panel-top-offset) - 4px), 980px) !important;
        gap: 0.56rem !important;
    }

    body.post-type-archive-imovel .results-header {
        display: flex !important;
        flex-wrap: wrap !important;
        align-items: center !important;
        gap: 0.36rem 0.52rem !important;
        padding: 0.42rem 0.56rem !important;
        margin-bottom: 0 !important;
        border-radius: 10px !important;
    }

    body.post-type-archive-imovel .results-header::before {
        height: 8px !important;
    }

    body.post-type-archive-imovel .results-meta-path {
        display: none !important;
    }

    body.post-type-archive-imovel .results-count {
        order: 1;
        flex: 0 0 auto;
        margin: 0;
        font-size: 0.78rem;
    }

    body.post-type-archive-imovel .results-filter-dock {
        order: 2;
        flex: 1 1 540px;
        min-width: 280px;
        max-width: 100%;
        overflow-x: auto;
        gap: 0.34rem;
        padding-bottom: 0;
    }

    body.post-type-archive-imovel .results-filter-pill {
        min-height: 32px;
        padding: 0.26rem 0.62rem;
        font-size: 0.69rem;
    }

    body.post-type-archive-imovel .results-sort {
        order: 3;
        flex: 0 0 auto;
        margin-left: auto;
        gap: 0.34rem;
    }

    body.post-type-archive-imovel .results-sort label {
        font-size: 0.66rem;
    }

    body.post-type-archive-imovel .results-sort select {
        min-height: 32px;
        padding: 0.3rem 0.56rem;
        font-size: 0.78rem;
    }

    body.post-type-archive-imovel .results-toolbar {
        order: 4;
        flex: 0 0 auto;
        margin-left: 0;
        gap: 0.34rem;
    }

    body.post-type-archive-imovel .results-view-toggle {
        padding: 0.14rem;
    }

    body.post-type-archive-imovel .results-view-btn {
        min-height: 28px;
        padding: 0.24rem 0.5rem;
        font-size: 0.66rem;
    }

    body.post-type-archive-imovel .results-quick-btn {
        padding: 0.3rem 0.64rem;
        font-size: 0.66rem;
    }

    body.post-type-archive-imovel .results-map-control {
        gap: 0.3rem;
    }

    body.post-type-archive-imovel .results-map-status {
        display: none !important;
    }

    body.post-type-archive-imovel .desktop-map-toggle label {
        min-height: 32px;
        padding: 0.28rem 0.64rem;
        font-size: 0.68rem;
    }

    body.post-type-archive-imovel .results-active-filters {
        margin-top: 0;
        padding: 0.12rem 0.4rem 0.22rem;
        gap: 0.3rem;
    }

    body.post-type-archive-imovel .result-filter-chip {
        padding: 0.26rem 0.54rem;
        font-size: 0.67rem;
    }

    body.post-type-archive-imovel .results-area .properties-grid {
        gap: 0.6rem;
        padding-right: 0.08rem;
    }

    body.post-type-archive-imovel #mapView {
        min-height: 500px !important;
    }

    body.post-type-archive-imovel footer {
        margin-top: 1.1rem;
        padding: 2.1rem 4% 1rem;
    }

    body.post-type-archive-imovel .footer-content {
        gap: 1.4rem;
    }

    body.post-type-archive-imovel .footer-brand p {
        margin-bottom: 0.78rem;
        font-size: 0.82rem;
        line-height: 1.5;
    }

    body.post-type-archive-imovel .footer-column h4 {
        margin-bottom: 0.82rem;
        padding-bottom: 0.42rem;
    }

    body.post-type-archive-imovel .footer-links li {
        margin-bottom: 0.38rem;
    }

    body.post-type-archive-imovel .footer-bottom {
        margin-top: 1rem;
        padding-top: 0.9rem;
    }
}

@media (min-width: 1025px) and (max-width: 1420px) {
    body.post-type-archive-imovel .results-count {
        order: 1;
        flex-basis: 100%;
    }

    body.post-type-archive-imovel .results-filter-dock {
        order: 2;
        flex-basis: 100%;
    }

    body.post-type-archive-imovel .results-sort {
        order: 3;
        margin-left: 0;
    }

    body.post-type-archive-imovel .results-toolbar {
        order: 4;
        margin-left: auto;
    }
}

/* ==========================================================================
   ACTIVE FILTER RAIL (archive-imovel)
   Keep chip actions visible and easier to click.
   ========================================================================== */
body.post-type-archive-imovel .results-active-filters {
    grid-row: 2 !important;
    position: sticky;
    top: calc(var(--results-header-top-offset, var(--navbar-height)) + 48px);
    z-index: 79;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.34rem;
    overflow-x: auto;
    scrollbar-width: thin;
    margin-top: 0 !important;
    padding: 0.3rem 0.42rem 0.32rem;
    background: linear-gradient(165deg, rgba(12, 14, 18, 0.95), rgba(9, 11, 15, 0.95));
    border: 1px solid rgba(201, 169, 98, 0.3);
    border-radius: 10px;
    box-shadow: 0 9px 22px rgba(0, 0, 0, 0.28);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

body.post-type-archive-imovel .results-active-filters:empty {
    display: none !important;
}

body.post-type-archive-imovel .result-filter-chip {
    flex: 0 0 auto;
    min-height: 31px;
    padding: 0.32rem 0.56rem;
    border-color: rgba(201, 169, 98, 0.42);
    background: rgba(201, 169, 98, 0.16);
    color: #f1e2c0;
    font-size: 0.7rem;
    font-weight: 600;
}

body.post-type-archive-imovel .result-filter-chip .chip-label {
    white-space: nowrap;
}

body.post-type-archive-imovel .result-filter-chip .chip-remove {
    width: 18px;
    height: 18px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.95rem;
    line-height: 1;
    background: rgba(15, 18, 24, 0.9);
    color: #efd8a9;
    border: 1px solid rgba(201, 169, 98, 0.36);
    opacity: 1;
}

body.post-type-archive-imovel .result-filter-chip-clear {
    background: linear-gradient(145deg, rgba(201, 169, 98, 0.25), rgba(146, 111, 58, 0.22));
    border-color: rgba(201, 169, 98, 0.56);
    color: #f8ebce;
    font-weight: 700;
}

[data-theme="light"] body.post-type-archive-imovel .results-active-filters {
    background: linear-gradient(180deg, rgba(252, 250, 245, 0.96), rgba(247, 242, 233, 0.96));
    border-color: rgba(176, 141, 85, 0.34);
    box-shadow: 0 8px 18px rgba(132, 106, 63, 0.16);
}

[data-theme="light"] body.post-type-archive-imovel .result-filter-chip {
    background: rgba(176, 141, 85, 0.16);
    border-color: rgba(176, 141, 85, 0.44);
    color: #6f552e;
}

[data-theme="light"] body.post-type-archive-imovel .result-filter-chip .chip-remove {
    background: rgba(255, 255, 255, 0.98);
    color: #7c5f32;
    border-color: rgba(176, 141, 85, 0.45);
}

[data-theme="light"] body.post-type-archive-imovel .result-filter-chip-clear {
    background: rgba(176, 141, 85, 0.24);
    color: #6c512a;
}

@media (max-width: 768px) {
    body.post-type-archive-imovel .results-active-filters {
        top: calc(var(--navbar-height) + 96px);
        padding: 0.26rem 0.34rem 0.3rem;
        border-radius: 9px;
    }

    body.post-type-archive-imovel .result-filter-chip {
        min-height: 30px;
        font-size: 0.68rem;
        padding: 0.3rem 0.5rem;
    }
}

/* ==========================================================================
   RESIZABLE MAP/CARDS SPLITTER
   ========================================================================== */
@media (min-width: 1025px) {
    body.post-type-archive-imovel .results-area {
        --results-cards-fr: 1fr;
        --results-map-fr: 1fr;
        --results-splitter-width: 12px;
        --cards-grid-columns: 2;
        grid-template-columns:
            minmax(0, var(--results-cards-fr))
            var(--results-splitter-width)
            minmax(0, var(--results-map-fr)) !important;
    }

    body.post-type-archive-imovel .results-area .properties-grid {
        grid-column: 1 !important;
    }

    body.post-type-archive-imovel .results-area .map-panel {
        grid-column: 3 !important;
    }

    body.post-type-archive-imovel .results-area.results-view-grid .properties-grid {
        grid-template-columns: repeat(var(--cards-grid-columns, 2), minmax(0, 1fr)) !important;
        gap: 0.72rem !important;
    }

    body.post-type-archive-imovel .results-splitter {
        grid-column: 2;
        grid-row: 3 / 5;
        align-self: start;
        position: sticky;
        top: var(--results-panel-top-offset);
        height: var(--results-panel-height);
        width: var(--results-splitter-width);
        border: 0;
        background: transparent;
        cursor: col-resize;
        z-index: 82;
        touch-action: none;
    }

    body.post-type-archive-imovel .results-splitter::before {
        content: '';
        position: absolute;
        top: 0;
        bottom: 0;
        left: 50%;
        width: 1px;
        transform: translateX(-50%);
        background: linear-gradient(180deg, rgba(201, 169, 98, 0), rgba(201, 169, 98, 0.6), rgba(201, 169, 98, 0));
        opacity: 0.9;
    }

    body.post-type-archive-imovel .results-splitter::after {
        content: '';
        position: absolute;
        left: 50%;
        top: 50%;
        width: 9px;
        height: 54px;
        transform: translate(-50%, -50%);
        border-radius: 999px;
        border: 1px solid rgba(201, 169, 98, 0.45);
        background: rgba(12, 15, 21, 0.82);
        box-shadow: 0 8px 18px rgba(0, 0, 0, 0.35);
    }

    body.post-type-archive-imovel .results-splitter:hover::after,
    body.post-type-archive-imovel .results-splitter:focus-visible::after {
        border-color: rgba(201, 169, 98, 0.8);
        background: rgba(19, 24, 34, 0.96);
    }

    body.results-splitter-dragging,
    body.results-splitter-dragging * {
        user-select: none !important;
        cursor: col-resize !important;
    }

    /* When cards reached the edge, release sticky blocks so the page can flow as a whole. */
    body.post-type-archive-imovel .results-area.results-scroll-unlocked .results-header,
    body.post-type-archive-imovel .results-area.results-scroll-unlocked .results-active-filters,
    body.post-type-archive-imovel .results-area.results-scroll-unlocked .map-panel,
    body.post-type-archive-imovel .results-area.results-scroll-unlocked .results-splitter {
        position: relative !important;
        top: auto !important;
    }

    body.post-type-archive-imovel .results-area.results-scroll-unlocked .map-panel {
        height: var(--results-panel-height) !important;
    }

    body.post-type-archive-imovel .results-area.results-scroll-unlocked .results-splitter {
        height: var(--results-panel-height) !important;
        align-self: start !important;
    }

    body.post-type-archive-imovel .results-area.map-hidden {
        grid-template-columns: 1fr !important;
    }

    body.post-type-archive-imovel .results-area.map-hidden .results-splitter {
        display: none !important;
    }

    body.post-type-archive-imovel .results-area.map-hidden.results-view-grid .properties-grid {
        grid-template-columns: repeat(var(--cards-grid-columns, 4), minmax(0, 1fr)) !important;
    }

    body.post-type-archive-imovel .results-area.map-hidden.results-view-list .properties-grid {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 1024px) {
    body.post-type-archive-imovel .results-splitter {
        display: none !important;
    }
}

/* ==========================================================================
   ARCHIVE LIST MODE STABILIZATION (desktop/tablet)
   Keep list cards readable and avoid compressed rows.
   ========================================================================== */
@media (min-width: 769px) {
    .results-area.results-view-list #propertiesGrid.properties-grid,
    .results-area.results-view-list.map-active #propertiesGrid.properties-grid {
        grid-template-columns: repeat(var(--cards-list-columns, 1), minmax(0, 1fr)) !important;
        gap: 0.78rem !important;
    }

    .results-area.results-view-list #propertiesGrid .property-card,
    .results-area.results-view-list.map-active #propertiesGrid .property-card {
        display: grid !important;
        grid-template-columns: clamp(185px, 31%, 280px) minmax(0, 1fr) !important;
        min-height: 0 !important;
        height: auto !important;
        align-items: start !important;
        overflow: hidden !important;
    }

    .results-area.results-view-list #propertiesGrid .property-card::after,
    .results-area.results-view-list.map-active #propertiesGrid .property-card::after {
        display: none !important;
    }

    .results-area.results-view-list #propertiesGrid .property-image,
    .results-area.results-view-list.map-active #propertiesGrid .property-image {
        width: 100% !important;
        height: var(--cards-list-image-height, 188px) !important;
        min-height: var(--cards-list-image-height, 188px) !important;
        max-height: 228px !important;
    }

    .results-area.results-view-list #propertiesGrid .property-content,
    .results-area.results-view-list.map-active #propertiesGrid .property-content {
        display: flex !important;
        flex-direction: column !important;
        min-width: 0 !important;
        min-height: 0 !important;
        padding: 0.74rem 0.86rem !important;
        opacity: 1 !important;
        visibility: visible !important;
    }

    .results-area.results-view-list #propertiesGrid .property-title,
    .results-area.results-view-list.map-active #propertiesGrid .property-title {
        display: -webkit-box;
        -webkit-line-clamp: 2;
        line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
        margin-bottom: 0.38rem !important;
    }

    .results-area.results-view-list #propertiesGrid .property-location,
    .results-area.results-view-list.map-active #propertiesGrid .property-location {
        margin-bottom: 0.46rem !important;
    }

    .results-area.results-view-list #propertiesGrid .property-price,
    .results-area.results-view-list.map-active #propertiesGrid .property-price {
        margin-bottom: 0.4rem !important;
    }

    .results-area.results-view-list #propertiesGrid .property-features,
    .results-area.results-view-list.map-active #propertiesGrid .property-features {
        margin-top: 0.42rem !important;
        flex-wrap: wrap;
        gap: 0.5rem 0.72rem;
        padding-top: 0.4rem !important;
    }
}

@media (min-width: 769px) and (max-width: 1220px) {
    .results-area.results-view-list #propertiesGrid .property-card,
    .results-area.results-view-list.map-active #propertiesGrid .property-card {
        grid-template-columns: minmax(170px, 36%) minmax(0, 1fr) !important;
        min-height: 0 !important;
    }

    .results-area.results-view-list #propertiesGrid .property-image,
    .results-area.results-view-list.map-active #propertiesGrid .property-image {
        max-height: 198px !important;
    }

    .results-area.results-view-list #propertiesGrid .property-content,
    .results-area.results-view-list.map-active #propertiesGrid .property-content {
        min-height: 0 !important;
        padding: 0.66rem 0.76rem !important;
    }
}


