:root {
    --brand: #12c48b;
    --brand-strong: #0fa872;
    --brand-soft: #d9f7eb;
    --text-primary: #0f172a;
    --text-muted: #64748b;
    --bg: #f5f7fb;
    --surface: #ffffff;
    --border: #e2e8f0;
    --shadow-soft: 0 22px 60px rgba(15, 23, 42, 0.08);
    --map-filters-height: 0px;
}

.dark {
    --brand: #12c48b;
    --brand-strong: #15d494;
    --brand-soft: #0d3d2e;
    --text-primary: #f1f5f9;
    --text-muted: #94a3b8;
    --bg: #0a0a0a;
    --surface: #171717;
    --border: #404040;
    --shadow-soft: 0 22px 60px rgba(0, 0, 0, 0.3);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: 'Instrument Sans', 'Segoe UI', sans-serif;
    background: var(--bg);
    color: var(--text-primary);
    -webkit-font-smoothing: antialiased;
}

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

img {
    max-width: 100%;
    display: block;
}

.page-body {
    background: var(--bg);
}

.page-wrapper {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.page-content {
    flex: 1;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 2000;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
}

.dark .site-header {
    background: rgba(23, 23, 23, 0.92);
    border-bottom: 1px solid rgba(64, 64, 64, 0.8);
}

.header-inner {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1.1rem 0;
    justify-content: center;
    flex-wrap: wrap;
}

.brand,
.nav-brand {
    font-weight: 800;
    font-size: 1.15rem;
    color: var(--brand);
    letter-spacing: -0.02em;
}

.header-nav {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 1.6rem;
    align-items: center;
    justify-items: center;
    width: 100%;
}

.header-nav a {
    color: var(--text-muted);
    font-weight: 600;
    transition: color 0.2s ease, opacity 0.2s ease;
}

.header-nav a:hover {
    color: var(--text-primary);
}

.header-nav .nav-brand {
    color: var(--brand);
    font-weight: 800;
}

.lang-dropdown {
    position: relative;
}

.lang-summary {
    list-style: none;
    padding: 0.35rem 0.7rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-primary);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background: var(--surface);
}

.lang-summary::after {
    content: "v";
    font-size: 0.7rem;
    opacity: 0.6;
    transform: translateY(-1px);
}

.lang-dropdown[open] .lang-summary::after {
    transform: rotate(180deg);
}

.lang-menu {
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 50%;
    transform: translateX(-50%);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 10px;
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.12);
    padding: 0.4rem;
    display: none;
    min-width: 120px;
    z-index: 10;
}

.dark .lang-menu {
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.3);
}

.lang-dropdown[open] .lang-menu {
    display: grid;
    gap: 0.2rem;
}

.lang-item {
    padding: 0.45rem 0.65rem;
    border-radius: 8px;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--text-primary);
    text-align: center;
}

.lang-item:hover {
    background: #f1f5f9;
}

.dark .lang-item:hover {
    background: #262626;
}

.lang-dropdown summary::-webkit-details-marker {
    display: none;
}

.header-cta {
    font-size: 0.9rem;
    padding: 0.6rem 1.05rem;
}

@media (max-width: 1024px) {
    .header-nav {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 1rem;
    }

    .map-layout__filters {
        padding: 0.75rem 1.5rem;
    }

    .map-layout__body {
        grid-template-columns: 1fr;
    }

    .map-layout__map {
        position: relative;
        top: 0;
    }

    .map-canvas {
        height: 360px;
    }

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

    .map-layout__list {
        padding: 1rem 1.5rem 1.5rem;
    }

    .filter-actions {
        margin-left: 0;
        justify-content: flex-start;
    }

    .filter-dropdown__content {
        position: static;
        box-shadow: none;
        margin-top: 0.6rem;
        transform: none;
        width: 100%;
        min-width: 0;
    }

    .filter-grid--wide {
        grid-template-columns: 1fr;
    }
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.35rem;
    padding: 0.85rem 1.35rem;
    border-radius: 12px;
    border: 1px solid transparent;
    font-weight: 800;
    font-size: 0.98rem;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
    text-decoration: none;
}

.btn:focus-visible {
    outline: 3px solid rgba(18, 196, 139, 0.25);
    outline-offset: 2px;
}

.btn-primary {
    background: var(--brand);
    color: #ffffff;
    box-shadow: 0 12px 35px rgba(18, 196, 139, 0.28);
}

.btn-primary:hover {
    background: var(--brand-strong);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--surface);
    color: var(--text-primary);
    border-color: var(--border);
}

.btn-secondary:hover {
    border-color: #cbd5e1;
    color: #0b1224;
}

.dark .btn-secondary:hover {
    border-color: #525252;
    color: #f1f5f9;
}

.btn.full-width {
    width: 100%;
}

.shadow-glow {
    box-shadow: 0 15px 35px rgba(18, 196, 139, 0.32);
}

.hero {
    padding: 4.5rem 0 3.25rem;
}

.hero-wide {
    position: relative;
    padding: 0;
    background: #0b1224;
    color: #fff;
    min-height: 520px;
    isolation: isolate;
}

.hero-wide::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--hero-image, none) center/cover no-repeat;
    opacity: 0.9;
    z-index: -3;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(9, 14, 25, 0.5) 0%, rgba(9, 14, 25, 0.75) 60%, rgba(9, 14, 25, 0.8) 100%);
    z-index: -2;
}

.hero-rail {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding: 1.5rem 0 3rem;
}

.hero-top {
    display: grid;
    grid-template-columns: auto 1fr auto auto;
    gap: 1rem;
    align-items: center;
}

.hero-brand {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    font-weight: 800;
    font-size: 1.2rem;
    color: #fff;
}

.hero-brand__logo {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #12c48b;
    color: #fff;
    border-radius: 10px;
}

.hero-meta {
    display: inline-flex;
    gap: 0.5rem;
}

.hero-actions {
    display: inline-flex;
    justify-content: flex-end;
    gap: 0.6rem;
}

.hero-content {
    margin-top: 1rem;
}

.hero-heading h1 {
    margin: 0 0 1.25rem;
    font-size: clamp(2rem, 3vw, 2.8rem);
    font-weight: 800;
    color: #fff;
}

.pill {
    border: 1px solid rgba(255, 255, 255, 0.4);
    background: transparent;
    color: #fff;
    border-radius: 999px;
    padding: 0.55rem 1rem;
    font-weight: 700;
    cursor: pointer;
}

.pill-ghost {
    border: none;
    background: rgba(255, 255, 255, 0.15);
}

.hero-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
    align-items: center;
}

.hero-copy {
    max-width: 560px;
}

.eyebrow {
    text-transform: uppercase;
    letter-spacing: 0.08em;
    font-size: 0.92rem;
    font-weight: 800;
    color: var(--brand);
}

.hero-title {
    font-size: clamp(2.3rem, 5vw, 3.3rem);
    line-height: 1.15;
    margin: 0.65rem 0;
    font-weight: 800;
    color: var(--text-primary);
}

.hero-subtitle {
    font-size: 1.05rem;
    color: var(--text-muted);
    line-height: 1.65;
    margin-bottom: 1.4rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    align-items: center;
}

.highlight-card {
    background: radial-gradient(circle at 18% 20%, rgba(18, 196, 139, 0.14), transparent 45%),
        var(--surface);
}

.search-card {
    padding: 1.75rem;
}

.search-card--wide {
    background: rgba(255, 255, 255, 0.98);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

.dark .search-card--wide {
    background: rgba(23, 23, 23, 0.98);
}

.tabs,
.search-tabs {
    display: flex;
    gap: 0.6rem;
    padding: 0.35rem;
    background: #f0f4fa;
    border-radius: 999px;
    width: fit-content;
}

.dark .tabs,
.dark .search-tabs {
    background: #262626;
}

.tab {
    border: none;
    background: transparent;
    padding: 0.55rem 1rem;
    border-radius: 999px;
    font-weight: 700;
    color: var(--text-muted);
    cursor: pointer;
    transition: all 0.2s ease;
}

.tab.is-active {
    background: var(--surface);
    color: var(--text-primary);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.1);
}

.dark .tab.is-active {
    box-shadow: 0 12px 28px rgba(0, 0, 0, 0.25);
}

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

.form-field {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.form-label {
    font-weight: 700;
    color: var(--text-primary);
    font-size: 0.96rem;
}

.form-control {
    width: 100%;
    padding: 0.9rem 1rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--surface);
    font-size: 1rem;
    color: var(--text-primary);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.form-control:focus {
    outline: none;
    border-color: rgba(18, 196, 139, 0.6);
    box-shadow: 0 0 0 4px rgba(18, 196, 139, 0.15);
}

.search-form {
    display: grid;
    gap: 1rem;
    margin-top: 1.25rem;
}

.search-form--wide .form-grid.wide {
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 0.8rem;
}

.filters-row {
    margin-top: 1rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
    justify-content: space-between;
}

.filters-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.filters-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 0.85rem;
}

.ui-card {
    background: var(--surface);
    border-radius: 18px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
    padding: 1.5rem;
}

.section-heading {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    margin-bottom: 1.25rem;
}

.featured {
    padding: 1.5rem 0 3.5rem;
}

.section-title {
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-primary);
    margin: 0;
}

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

.map-layout {
    padding: 0;
}

.map-layout .container {
    max-width: none;
    padding: 0;
}

.map-layout__filters {
    position: sticky;
    top: var(--site-header-height, 72px);
    z-index: 1500;
    margin-bottom: 0;
    padding: 0.85rem 2rem;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.06);
}

.dark .map-layout__filters {
    background: rgba(23, 23, 23, 0.96);
    border-bottom: 1px solid rgba(64, 64, 64, 0.9);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.2);
}

.map-filters {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 1rem;
    justify-content: space-between;
    padding: 0;
    border-radius: 0;
    background: transparent;
    border: none;
    box-shadow: none;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    min-width: 140px;
    flex: 1 1 180px;
}

.filter-label {
    font-size: 0.78rem;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.filter-actions {
    display: flex;
    gap: 0.6rem;
    align-items: center;
    margin-left: auto;
    flex: 1 1 220px;
    justify-content: flex-end;
}

.filter-summary {
    list-style: none;
    padding: 0.75rem 1.2rem;
    border-radius: 10px;
    border: 1px solid var(--border);
    font-weight: 700;
    font-size: 1rem;
    color: var(--text-primary);
    cursor: pointer;
    background: var(--surface);
}

.filter-summary::after {
    content: "v";
    font-size: 0.7rem;
    opacity: 0.6;
    margin-left: 0.4rem;
}

.filter-dropdown[open] .filter-summary::after {
    transform: rotate(180deg);
}

.filter-dropdown {
    position: relative;
    flex: 1 1 180px;
    display: flex;
    justify-content: center;
}

.filter-dropdown summary::-webkit-details-marker {
    display: none;
}

.filter-dropdown__content {
    position: absolute;
    top: calc(100% + 0.6rem);
    left: 50%;
    transform: translateX(-50%);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.12);
    padding: 0.9rem;
    min-width: 320px;
    width: min(420px, 90vw);
    z-index: 10;
}

.dark .filter-dropdown__content {
    box-shadow: 0 18px 40px rgba(0, 0, 0, 0.3);
}

.filter-dropdown--wide .filter-dropdown__content {
    min-width: 360px;
    width: min(640px, 92vw);
}

.filter-grid {
    display: grid;
    gap: 0.75rem;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.filter-grid--wide {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.filter-features {
    margin-top: 0.8rem;
}

.filter-chip-grid {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 0.4rem;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
    color: var(--text-primary);
    background: #f8fafc;
}

.dark .filter-chip {
    background: #262626;
}

.filter-chip input {
    accent-color: var(--brand);
}

.map-layout__body {
    display: grid;
    grid-template-columns: 3fr 2fr;
    gap: 0;
    align-items: start;
}

.map-layout__map {
    position: sticky;
    top: calc(var(--site-header-height, 72px) + var(--map-filters-height, 0px) + 1rem);
    align-self: start;
}

.map-canvas {
    height: calc(100vh - var(--site-header-height, 72px) - var(--map-filters-height, 0px));
    border-radius: 0;
    border: none;
    overflow: hidden;
}

.map-layout__list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem 2rem 2rem;
}

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

.results-title {
    margin: 0;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--text-primary);
}

.results-count {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-muted);
}

.property-results-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.property-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 1.1rem;
}

.property-card {
    display: grid;
    gap: 0.4rem;
}

.property-thumb {
    position: relative;
    overflow: hidden;
    border-radius: 12px;
    border: 1px solid var(--border);
    margin-bottom: 0.5rem;
}

.property-thumb img {
    width: 100%;
    height: 160px;
    object-fit: cover;
    display: block;
    transition: transform 0.2s ease;
}

.property-card:hover .property-thumb img {
    transform: scale(1.02);
}

.frequent {
    background: var(--surface);
}

.frequent-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.frequent-card {
    text-align: center;
    display: grid;
    gap: 0.5rem;
}

.frequent-thumb {
    display: flex;
    justify-content: center;
}

.frequent-title {
    font-weight: 700;
    color: var(--text-primary);
}

.meta-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
}

.property-card h3 {
    margin: 0.35rem 0 0.2rem;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.property-meta {
    color: var(--text-muted);
    font-weight: 600;
    font-size: 0.95rem;
}

.price {
    font-weight: 800;
    font-size: 1.25rem;
    margin-top: 0.4rem;
    color: var(--text-primary);
}

.meta-secondary {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.38rem 0.8rem;
    border-radius: 999px;
    font-weight: 800;
    font-size: 0.88rem;
}

.badge-success {
    background: #e9fbf3;
    color: #0f9f6a;
}

.dark .badge-success {
    background: rgba(18, 196, 139, 0.15);
    color: #34d399;
}

.badge-warning {
    background: #fff6e5;
    color: #c87a00;
}

.dark .badge-warning {
    background: rgba(251, 191, 36, 0.15);
    color: #fbbf24;
}

.badge-info {
    background: #eef4ff;
    color: #4154f1;
}

.dark .badge-info {
    background: rgba(96, 165, 250, 0.15);
    color: #60a5fa;
}

.badge-neutral {
    background: #f1f5f9;
    color: var(--text-muted);
}

.dark .badge-neutral {
    background: #262626;
}

/* ==========================================
   Enhanced Footer
   ========================================== */
.site-footer {
    border-top: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-muted);
    padding: 3rem 0 1.5rem;
}

.dark .site-footer {
    border-top: 1px solid rgba(64, 64, 64, 0.8);
}

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

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

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

.footer-brand-section {
    max-width: 280px;
}

.footer-brand {
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--brand);
    margin-bottom: 0.75rem;
}

.footer-tagline {
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 1.25rem;
}

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

.footer-social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--bg);
    color: var(--text-muted);
    transition: all 0.2s ease;
}

.footer-social-link:hover {
    background: var(--brand);
    color: white;
    transform: translateY(-2px);
}

.footer-social-link .icon {
    width: 18px;
    height: 18px;
}

.footer-heading {
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.footer-nav {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.footer-nav a {
    font-size: 0.9rem;
    color: var(--text-muted);
    transition: color 0.2s ease;
}

.footer-nav a:hover {
    color: var(--brand);
}

.footer-newsletter-text {
    font-size: 0.85rem;
    line-height: 1.5;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

.footer-newsletter-form {
    display: flex;
    gap: 0;
}

.footer-newsletter-input {
    flex: 1;
    padding: 0.65rem 0.9rem;
    border: 1px solid var(--border);
    border-right: none;
    border-radius: 8px 0 0 8px;
    font-size: 0.85rem;
    background: var(--bg);
    color: var(--text-primary);
    outline: none;
    transition: border-color 0.2s ease;
}

.footer-newsletter-input:focus {
    border-color: var(--brand);
}

.footer-newsletter-input::placeholder {
    color: var(--text-muted);
}

.footer-newsletter-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 1rem;
    background: var(--brand);
    color: white;
    border: none;
    border-radius: 0 8px 8px 0;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.footer-newsletter-btn:hover {
    background: var(--brand-strong);
}

.footer-newsletter-btn .icon {
    width: 18px;
    height: 18px;
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding-top: 2rem;
    margin-top: 2rem;
    border-top: 1px solid var(--border);
}

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

.footer-copy {
    font-size: 0.85rem;
    color: var(--text-muted);
}

.footer-locale {
    display: flex;
    gap: 0.5rem;
}

.footer-locale a {
    padding: 0.3rem 0.6rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-muted);
    border: 1px solid var(--border);
    transition: all 0.2s ease;
}

.footer-locale a:hover,
.footer-locale a.is-active {
    background: var(--brand-soft);
    border-color: var(--brand);
    color: var(--brand);
}

.property-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    padding: calc(var(--site-header-height, 72px) + 1rem) 1.5rem 1.5rem;
    z-index: 1200;
}

.property-modal.is-open {
    display: flex;
}

.property-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(6px);
}

.property-modal__panel {
    position: relative;
    width: 50vw;
    height: calc(100vh - var(--site-header-height, 72px) - 2.5rem);
    max-width: 50vw;
    max-height: calc(100vh - var(--site-header-height, 72px) - 2.5rem);
    background: var(--surface);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 24px 80px rgba(15, 23, 42, 0.2);
    display: flex;
    flex-direction: column;
    z-index: 1;
}

.dark .property-modal__panel {
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.4);
}

.property-modal__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.85rem 1.25rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.9);
    background: var(--surface);
}

.dark .property-modal__header {
    border-bottom: 1px solid rgba(64, 64, 64, 0.9);
}

.property-modal__title {
    font-weight: 800;
    color: var(--text-primary);
}

.property-modal__close {
    border: none;
    background: #f1f5f9;
    color: #0f172a;
    font-size: 1rem;
    border-radius: 999px;
    width: 2rem;
    height: 2rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.property-modal__close:hover {
    background: #e2e8f0;
}

.dark .property-modal__close {
    background: #262626;
    color: #f1f5f9;
}

.dark .property-modal__close:hover {
    background: #404040;
}

.property-modal__body {
    flex: 1;
    min-height: 0;
    background: var(--surface);
}

.property-modal__frame {
    width: 100%;
    height: 100%;
    border: 0;
}

.modal-open {
    overflow: hidden;
}

@media (max-width: 960px) {
    .hero-top {
        grid-template-columns: 1fr;
        justify-items: start;
        gap: 0.5rem;
    }
}

@media (max-width: 640px) {
    .tabs {
        width: 100%;
    }

    .tab {
        flex: 1;
        text-align: center;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }

    .header-inner {
        padding: 0.75rem 0;
    }

    .header-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 0.75rem 1rem;
    }

    .header-nav a {
        font-size: 0.95rem;
    }

    .header-nav .nav-brand {
        grid-column: 1 / -1;
        order: -1;
        font-size: 1.1rem;
    }

    .lang-summary {
        width: 100%;
        justify-content: center;
    }

    .header-cta {
        width: 100%;
        justify-content: center;
    }

    .hero {
        padding: 3.5rem 0 2.5rem;
    }

    .hero-wide {
        min-height: 420px;
    }

    .hero-heading h1,
    .hero-title {
        font-size: clamp(1.8rem, 6vw, 2.4rem);
    }

    .hero-subtitle {
        font-size: 0.95rem;
    }

    .search-card {
        padding: 1.25rem;
    }

    .search-form {
        margin-top: 1rem;
    }

    .search-form--wide .form-grid.wide,
    .form-grid {
        grid-template-columns: 1fr;
    }

    .filters-row {
        flex-direction: column;
        align-items: stretch;
    }

    .filters-actions {
        width: 100%;
        flex-direction: column;
    }

    .filters-actions .btn {
        width: 100%;
    }

    .map-layout__filters {
        padding: 0.65rem 1rem;
    }

    .map-filters {
        flex-direction: column;
        align-items: stretch;
        gap: 0.75rem;
    }

    .filter-dropdown {
        flex: 1 1 100%;
    }

    .filter-summary {
        width: 100%;
        text-align: left;
    }

    .filter-actions {
        width: 100%;
        margin-left: 0;
        flex-direction: column;
        align-items: stretch;
        justify-content: stretch;
    }

    .filter-actions .btn {
        width: 100%;
    }

    .filter-group {
        min-width: 0;
    }

    .map-layout__body {
        grid-template-columns: 1fr;
    }

    .map-layout__map {
        position: relative;
        top: 0;
    }

    .map-canvas {
        height: 45vh;
    }

    .map-layout__list {
        padding: 1rem 1rem 1.5rem;
    }

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

    .ui-card {
        padding: 1.1rem;
    }

    .footer-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

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

    .property-gallery {
        gap: 0.75rem;
    }

    .property-gallery__main {
        height: 260px;
    }

    .property-gallery__stack {
        height: auto;
        grid-template-rows: none;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        grid-auto-flow: column;
    }

    .property-gallery__tile {
        height: 96px;
    }

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

@media (max-width: 480px) {
    .container {
        padding: 0 0.85rem;
    }

    .header-nav {
        grid-template-columns: 1fr;
        gap: 0.6rem;
    }

    .header-nav a {
        font-size: 0.92rem;
    }

    .filter-summary {
        padding: 0.65rem 0.9rem;
        font-size: 0.95rem;
    }

    .map-canvas {
        height: 40vh;
    }

    .results-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.25rem;
    }

    .hero {
        padding: 3rem 0 2rem;
    }

    .search-card {
        padding: 1rem;
    }

    .form-control {
        padding: 0.75rem 0.85rem;
        font-size: 0.95rem;
    }

    .footer-links {
        flex-direction: column;
        gap: 0.5rem;
    }

    .property-gallery__main {
        height: 220px;
    }

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

    .property-gallery__tile {
        height: 88px;
    }
}

/* ==========================================
   Mobile Navigation (Zillow-style)
   ========================================== */

/* Show mobile header on small screens, desktop header on large */
.site-header--mobile {
    display: block;
}

.site-header--desktop {
    display: none;
}

@media (min-width: 769px) {
    .site-header--mobile {
        display: none;
    }

    .site-header--desktop {
        display: block;
    }
}

/* Mobile header styling */
.site-header--mobile .header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
}

.mobile-menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    border-radius: 8px;
    cursor: pointer;
    color: var(--text-primary);
    transition: background-color 0.2s ease;
}

.mobile-menu-toggle:hover {
    background: rgba(0, 0, 0, 0.05);
}

.dark .mobile-menu-toggle:hover {
    background: rgba(255, 255, 255, 0.1);
}

.mobile-menu-toggle .icon {
    width: 24px;
    height: 24px;
}

.mobile-user-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 0.8rem;
    font-weight: 700;
}

.mobile-signin {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--brand);
}

/* Mobile slide-out menu */
.mobile-menu {
    position: fixed;
    inset: 0;
    z-index: 3000;
    display: none;
}

.mobile-menu.is-open {
    display: block;
}

.mobile-menu__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
}

.mobile-menu__panel {
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    width: 280px;
    max-width: 85vw;
    background: var(--surface);
    display: flex;
    flex-direction: column;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.15);
}

.dark .mobile-menu__panel {
    box-shadow: 4px 0 24px rgba(0, 0, 0, 0.4);
}

.mobile-menu.is-open .mobile-menu__panel {
    transform: translateX(0);
}

.mobile-menu__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid var(--border);
}

.mobile-menu__close {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    border-radius: 8px;
    cursor: pointer;
    color: var(--text-muted);
    transition: background-color 0.2s ease, color 0.2s ease;
}

.mobile-menu__close:hover {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text-primary);
}

.dark .mobile-menu__close:hover {
    background: rgba(255, 255, 255, 0.1);
}

.mobile-menu__close .icon {
    width: 20px;
    height: 20px;
}

/* Mobile user section */
.mobile-menu__user {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border-bottom: 1px solid var(--border);
}

.mobile-menu__avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--brand-soft);
    color: var(--brand);
    font-size: 0.9rem;
    font-weight: 700;
    flex-shrink: 0;
}

.mobile-menu__user-info {
    min-width: 0;
    flex: 1;
}

.mobile-menu__user-name {
    display: block;
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.mobile-menu__user-email {
    display: block;
    font-size: 0.8rem;
    color: var(--text-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Mobile navigation links */
.mobile-menu__nav {
    flex: 1;
    overflow-y: auto;
    padding: 0.5rem 0;
}

.mobile-menu__link {
    display: block;
    padding: 0.9rem 1rem;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    transition: background-color 0.2s ease;
}

.mobile-menu__link:hover {
    background: rgba(0, 0, 0, 0.03);
}

.dark .mobile-menu__link:hover {
    background: rgba(255, 255, 255, 0.05);
}

/* Mobile menu footer */
.mobile-menu__footer {
    padding: 1rem;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.mobile-menu__lang {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.mobile-menu__lang-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
}

.mobile-menu__lang-options {
    display: flex;
    gap: 0.35rem;
}

.mobile-menu__lang-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.4rem 0.7rem;
    border-radius: 6px;
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    border: 1px solid var(--border);
    background: transparent;
    transition: all 0.2s ease;
}

.mobile-menu__lang-btn:hover,
.mobile-menu__lang-btn.is-active {
    background: var(--brand-soft);
    border-color: var(--brand);
    color: var(--brand);
}

.mobile-menu__cta {
    width: 100%;
}

.mobile-menu__logout {
    margin: 0;
}

/* Prevent body scroll when menu is open */
body.mobile-menu-open {
    overflow: hidden;
}
