/* Premium property listing — presentation only. Mobile drawer & JS hooks unchanged. */
.properties-page {
    --pg-font: "Plus Jakarta Sans", "Inter", system-ui, -apple-system, sans-serif;
    --pg-bg: #f0f4fa;
    --pg-bg-soft: linear-gradient(165deg, #eef2f9 0%, #f7f9fc 42%, #ffffff 100%);
    --pg-ink: #0c1222;
    --pg-ink-muted: #5c6578;
    --pg-border: rgba(15, 23, 42, 0.08);
    --pg-primary: #3730a3;
    --pg-primary-bright: #4f46e5;
    --pg-accent: #2563eb;
    --pg-radius-lg: 18px;
    --pg-radius-xl: 20px;
    --pg-shadow: 0 4px 24px rgba(15, 23, 42, 0.06);
    --pg-shadow-hover: 0 20px 48px rgba(15, 23, 42, 0.12);
    --pg-sticky-top: 92px;

    font-family: var(--pg-font);
    background: var(--pg-bg-soft);
    color: var(--pg-ink);
    -webkit-font-smoothing: antialiased;
}

.properties-page .container {
    max-width: 1320px;
}

@media (min-width: 1400px) {
    .properties-page .container {
        max-width: 1420px;
    }
}

.properties-layout {
    display: grid;
    grid-template-columns: minmax(260px, 28%) minmax(0, 72%);
    gap: 1.25rem;
    align-items: start;
}

.filters-column {
    min-width: 0;
}

.results-column {
    min-width: 0;
}

/* ——— Filter sidebar (desktop: premium card) ——— */
.filter-shell {
    position: sticky;
    top: var(--pg-sticky-top);
    z-index: 35;
    background: #ffffff;
    border: 1px solid var(--pg-border);
    border-radius: var(--pg-radius-xl);
    box-shadow: var(--pg-shadow), 0 1px 0 rgba(255, 255, 255, 0.9) inset;
    padding: 1.25rem 1.35rem 1.35rem;
    transition: box-shadow 0.35s ease;
}

.filter-drawer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(15, 23, 42, 0.07);
}

.filter-title {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    font-size: 1.125rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    color: var(--pg-ink);
    line-height: 1.2;
}

.filter-title__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 12px;
    background: linear-gradient(145deg, #eef2ff 0%, #e0e7ff 100%);
    color: var(--pg-primary-bright);
    font-size: 0.9rem;
}

.filter-close-btn {
    display: none;
    flex: 0 0 auto;
    width: 36px;
    height: 36px;
    padding: 0;
    margin: 0;
    border: 1px solid #e2e8f0;
    border-radius: 50%;
    background: #fff;
    color: #475569;
    font-size: 0.95rem;
    line-height: 1;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.15s ease;
}

.filter-close-btn:hover {
    background: #f8fafc;
    color: #0f172a;
    border-color: #cbd5e1;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.08);
}

.filter-close-btn:active {
    transform: scale(0.96);
}

.filter-close-btn:focus-visible {
    outline: none;
    border-color: var(--pg-accent);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.35);
}

.filter-drawer-form {
    display: block;
}

.filter-drawer-body {
    min-width: 0;
}

.filter-drawer-footer {
    min-width: 0;
}

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

.filter-field {
    grid-column: span 1;
}

.filter-field.filter-field-full {
    grid-column: 1 / -1;
}

.filter-form .form-label {
    font-size: 0.8125rem;
    font-weight: 700;
    color: #334155;
    margin-bottom: 0.4rem;
    letter-spacing: 0.01em;
}

/* ——— Results toolbar ——— */
.results-toolbar {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.result-count {
    margin-right: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 1rem 0.5rem 0.5rem;
    background: #ffffff;
    border: 1px solid var(--pg-border);
    border-radius: 14px;
    box-shadow: 0 2px 16px rgba(15, 23, 42, 0.05);
}

.result-count__icon {
    flex-shrink: 0;
    width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: linear-gradient(135deg, var(--pg-primary-bright) 0%, var(--pg-primary) 100%);
    color: #fff;
    font-size: 1rem;
    box-shadow: 0 4px 14px rgba(79, 70, 229, 0.35);
}

.result-count__text {
    display: flex;
    flex-direction: column;
    gap: 0.05rem;
    line-height: 1.15;
    min-width: 0;
}

.result-count__num {
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--pg-ink);
    font-variant-numeric: tabular-nums;
}

.result-count__label {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pg-ink-muted);
}

.view-toggle-group {
    display: inline-flex;
    gap: 0.35rem;
    padding: 0.2rem;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid var(--pg-border);
    border-radius: 14px;
    box-shadow: 0 2px 12px rgba(15, 23, 42, 0.04);
}

.view-toggle-group .btn {
    text-transform: none;
    letter-spacing: 0;
    width: 42px;
    height: 42px;
    padding: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    border-radius: 11px;
    border-color: transparent;
    background: transparent;
    color: #64748b;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.25s ease;
}

.view-toggle-group .btn:hover {
    background: #f1f5f9;
    color: #334155;
}

.view-toggle-group .btn.active {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 4px 16px rgba(79, 70, 229, 0.35);
}

.filters-mobile-btn {
    display: none;
    text-transform: none;
    letter-spacing: 0;
    border-radius: 12px;
    font-weight: 600;
}

/* Active filter chips (in toolbar on desktop) */
.active-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    align-items: center;
    align-content: center;
    min-height: 0;
}

.filter-chip {
    display: inline-flex;
    align-items: center;
    padding: 0.35rem 0.75rem;
    border-radius: 999px;
    background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
    border: 1px solid rgba(15, 23, 42, 0.1);
    color: #334155;
    font-size: 0.75rem;
    font-weight: 600;
}

/* ——— Filter fields & actions ——— */
.filter-actions {
    margin-top: 0;
    display: flex;
    flex-direction: column;
    gap: 0.65rem;
    width: 100%;
}

.filter-btn-reset,
.filter-btn-apply {
    text-transform: none;
    letter-spacing: 0;
    font-weight: 700;
    border-radius: 14px;
    min-height: 48px;
    width: 100%;
    font-size: 0.9375rem;
    transition: transform 0.2s ease, box-shadow 0.25s ease, background 0.2s ease, border-color 0.2s ease;
}

.filter-btn-reset {
    border: 1.5px solid #e2e8f0;
    color: #475569;
    background: #fff;
}

.filter-btn-reset:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
}

.filter-btn-apply {
    background: linear-gradient(135deg, #4f46e5 0%, #3730a3 100%);
    border: none;
    box-shadow: 0 6px 20px rgba(79, 70, 229, 0.35);
}

.filter-btn-apply:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 28px rgba(79, 70, 229, 0.42);
    filter: brightness(1.03);
}

.filter-btn-apply:active {
    transform: translateY(0);
}

.filter-form .form-control,
.filter-form .form-select {
    border-radius: 12px;
    border: 1px solid #dbe4f0;
    min-height: 46px;
    font-size: 0.9375rem;
    box-shadow: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.filter-form .form-control:focus,
.filter-form .form-select:focus {
    border-color: #818cf8;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}

/* Inline checkbox lists (location, room type, amenities) */
.filter-checkbox-list {
    border: 1px solid #dbe4f0;
    border-radius: 12px;
    background: #fff;
    max-height: 200px;
    overflow-y: auto;
    padding: 0.35rem 0.45rem;
    -webkit-overflow-scrolling: touch;
}

.filter-checkbox-list--tall {
    max-height: 260px;
}

.filter-checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    padding: 0.42rem 0.5rem;
    border-radius: 10px;
    cursor: pointer;
    margin-bottom: 0.05rem;
    font-size: 0.9375rem;
    font-weight: 500;
    color: #334155;
    transition: background 0.15s ease;
}

.filter-checkbox-item:hover {
    background: #f5f7ff;
}

.filter-checkbox-item input[type="checkbox"] {
    width: 1.05rem;
    height: 1.05rem;
    flex-shrink: 0;
    margin: 0;
    accent-color: #4f46e5;
    cursor: pointer;
}

.filter-checkbox-item span {
    line-height: 1.35;
}

/* ——— Property grid & cards ——— */
.properties-grid-wrap {
    position: relative;
}

.properties-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.35rem;
    transition: gap 0.25s ease;
}

.properties-grid.view-list {
    grid-template-columns: 1fr;
}

.property-item {
    min-width: 0;
    display: flex;
}

.property-card-modern {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
    border-radius: var(--pg-radius-lg);
    overflow: hidden;
    border: 1px solid var(--pg-border);
    background: #ffffff;
    box-shadow: var(--pg-shadow);
    transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1), box-shadow 0.35s ease, border-color 0.25s ease;
}

.property-card-modern:hover {
    transform: translateY(-8px);
    box-shadow: var(--pg-shadow-hover);
    border-color: rgba(99, 102, 241, 0.22);
}

.property-media {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: var(--pg-radius-lg) var(--pg-radius-lg) 0 0;
}

.property-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 35%, rgba(12, 18, 34, 0.55) 100%);
    opacity: 0.85;
    pointer-events: none;
    transition: opacity 0.35s ease;
}

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

/* List: horizontal layout */
.properties-grid.view-list .property-card-modern {
    flex-direction: row;
    align-items: stretch;
    min-height: 260px;
}

.properties-grid.view-list .property-media {
    flex: 0 0 40%;
    max-width: 420px;
    border-radius: var(--pg-radius-lg) 0 0 var(--pg-radius-lg);
}

.properties-grid.view-list .property-media::after {
    background: linear-gradient(90deg, transparent 20%, rgba(12, 18, 34, 0.45) 100%);
}

.properties-grid.view-list .property-media img {
    height: 100%;
    min-height: 260px;
}

.properties-grid.view-list .property-content {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    padding: 1.35rem 1.5rem 1.4rem;
}

.properties-grid.view-list .property-desc {
    min-height: 0;
    -webkit-line-clamp: 2;
    line-clamp: 2;
}

.properties-grid.view-list .property-meta {
    margin-top: auto;
    padding-top: 1rem;
}

.property-media img {
    width: 100%;
    height: 240px;
    object-fit: cover;
    transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.property-card-modern:hover .property-media img {
    transform: scale(1.06);
}

.price-chip {
    position: absolute;
    left: 1rem;
    bottom: 1rem;
    z-index: 2;
    background: rgba(255, 255, 255, 0.96);
    color: var(--pg-primary);
    padding: 0.45rem 0.9rem;
    border-radius: 12px;
    font-weight: 800;
    font-size: 0.875rem;
    letter-spacing: -0.02em;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.18), 0 0 0 1px rgba(255, 255, 255, 0.5) inset;
    backdrop-filter: blur(8px);
}

.property-content {
    padding: 1.15rem 1.2rem 1.25rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.property-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.75rem;
}

.property-name {
    margin: 0;
    font-size: 1.0625rem;
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.28;
    color: var(--pg-ink);
}

.status-pill {
    display: inline-flex;
    align-items: center;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    background: linear-gradient(180deg, #ecfdf5 0%, #d1fae5 100%);
    color: #047857;
    font-size: 0.6875rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    flex-shrink: 0;
}

.property-location {
    margin: 0.5rem 0 0.5rem;
    color: var(--pg-ink-muted);
    font-size: 0.875rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.property-location i {
    color: var(--pg-accent);
    font-size: 0.85rem;
}

.property-desc {
    color: var(--pg-ink-muted);
    font-size: 0.875rem;
    line-height: 1.55;
    margin: 0;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    overflow: hidden;
    min-height: 0;
    flex-shrink: 0;
}

.property-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
    margin-top: auto;
    padding-top: 0.85rem;
    color: var(--pg-ink-muted);
    font-size: 0.8125rem;
}

/* Price also in meta — hide; badge on image is primary */
.property-meta > span:first-child {
    display: none;
}

.property-meta span {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.35rem 0.65rem;
    border-radius: 999px;
    background: #f8fafc;
    border: 1px solid rgba(15, 23, 42, 0.06);
    font-weight: 600;
    color: #475569;
    max-width: 100%;
}

.property-meta span i {
    color: var(--pg-primary-bright);
    font-size: 0.8rem;
    opacity: 0.9;
}

.property-content .btn-primary {
    margin-top: 1rem !important;
    width: 100%;
    border: none;
    border-radius: 14px;
    font-weight: 800;
    letter-spacing: 0.02em;
    padding: 0.65rem 1rem;
    background: linear-gradient(135deg, #4f46e5 0%, #6366f1 45%, #4338ca 100%);
    box-shadow: 0 8px 24px rgba(79, 70, 229, 0.35);
    transition: transform 0.2s ease, box-shadow 0.3s ease, filter 0.2s ease;
}

.property-content .btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(79, 70, 229, 0.45);
    filter: brightness(1.05);
}

.property-content .btn-primary:active {
    transform: translateY(0);
}

/* Empty & loading */
.empty-state {
    grid-column: 1 / -1;
    background: #fff;
    border: 1px dashed rgba(15, 23, 42, 0.12);
    border-radius: var(--pg-radius-lg);
    text-align: center;
    padding: 2.75rem 1.5rem;
}

.empty-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: linear-gradient(145deg, #eef2ff 0%, #e0e7ff 100%);
    color: var(--pg-primary-bright);
    margin: 0 auto 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.65rem;
}

.filter-loading {
    display: none;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1.25rem;
    margin-top: 0.5rem;
}

.filter-loading.show {
    display: grid;
}

.skeleton-card {
    border: 1px solid var(--pg-border);
    border-radius: var(--pg-radius-lg);
    background: #fff;
    padding: 0.9rem;
}

.skeleton-media,
.skeleton-line {
    background: linear-gradient(90deg, #edf2f7 25%, #e4ebf5 37%, #edf2f7 63%);
    background-size: 400% 100%;
    animation: pg-shimmer 1.2s ease-in-out infinite;
    border-radius: 12px;
}

.skeleton-media {
    height: 180px;
    margin-bottom: 0.75rem;
}

.skeleton-line {
    height: 12px;
    margin-bottom: 0.45rem;
}

.w-70 { width: 70%; }
.w-40 { width: 40%; }
.w-85 { width: 85%; }
.w-60 { width: 60%; }

@keyframes pg-shimmer {
    0% { background-position: 100% 0; }
    100% { background-position: -100% 0; }
}

/* Pagination */
.properties-page .pagination {
    gap: 0.35rem;
    flex-wrap: wrap;
}

.properties-page .pagination .page-item {
    margin: 0;
}

.properties-page .pagination .page-link {
    border-radius: 12px;
    min-width: 2.65rem;
    text-align: center;
    padding: 0.5rem 0.85rem;
    font-weight: 700;
    font-size: 0.9rem;
    color: #475569;
    border: 1px solid var(--pg-border);
    background: #fff;
    margin: 0;
    transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.properties-page .pagination .page-link:hover {
    background: #f8fafc;
    color: var(--pg-primary-bright);
    border-color: #c7d2fe;
}

.properties-page .pagination .page-item.active .page-link {
    background: linear-gradient(135deg, #4f46e5 0%, #4338ca 100%);
    color: #fff;
    border-color: transparent;
    box-shadow: 0 6px 18px rgba(79, 70, 229, 0.35);
}

.properties-page .pagination .page-item.disabled .page-link {
    opacity: 0.5;
    pointer-events: none;
}

/* Drawer backdrop */
.filter-drawer-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 1040;
    background: rgba(15, 23, 42, 0.45);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.filter-drawer-backdrop.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

body.no-scroll {
    overflow: hidden;
    overscroll-behavior: none;
}

/* ——— Desktop (≥992px): layout, toolbar grid, sidebar width ——— */
@media (min-width: 992px) {
    .properties-layout {
        grid-template-columns: 320px minmax(0, 1fr);
        gap: 2rem;
    }

    .filter-drawer-footer {
        margin-top: 1.15rem;
        padding-top: 1.15rem;
        border-top: 1px solid rgba(15, 23, 42, 0.07);
    }

    .results-toolbar {
        display: grid;
        grid-template-columns: auto minmax(0, 1fr) auto;
        align-items: center;
        gap: 1.25rem 1.5rem;
        padding: 1rem 1.25rem;
        background: rgba(255, 255, 255, 0.88);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        border: 1px solid var(--pg-border);
        border-radius: var(--pg-radius-lg);
        box-shadow: 0 4px 24px rgba(15, 23, 42, 0.05);
        margin-bottom: 1.25rem !important;
    }

    .results-toolbar.mb-3 {
        margin-bottom: 1.25rem !important;
    }

    .result-count {
        margin-right: 0;
    }

    .result-count__text {
        flex-direction: row;
        align-items: baseline;
        flex-wrap: wrap;
        gap: 0.35rem 0.5rem;
    }

    .result-count__num {
        font-size: 1.625rem;
    }

    .result-count__label {
        font-size: 0.8125rem;
        font-weight: 700;
        text-transform: none;
        letter-spacing: 0.02em;
        color: #64748b;
    }

    .active-filters {
        justify-content: flex-start;
        max-height: 4.5rem;
        overflow-y: auto;
        padding: 0 0.25rem;
    }

    .active-filters:empty {
        min-height: 0;
        padding: 0;
    }

    .property-name {
        font-size: 1.2rem;
    }

}

@media (min-width: 992px) {
    .filter-drawer-backdrop {
        display: none !important;
    }
}

/* Grid: 2 columns below xl; list stays single column */
@media (max-width: 1199px) {
    .properties-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

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

    .properties-grid.view-list {
        grid-template-columns: 1fr;
    }
}

/* Mobile drawer & stack */
@media (max-width: 991px) {
    .properties-layout {
        grid-template-columns: 1fr;
    }

    .filters-mobile-btn {
        display: inline-flex;
        align-items: center;
        gap: 0.45rem;
    }

    .filter-shell {
        position: fixed;
        top: 0;
        right: 0;
        left: auto;
        bottom: 0;
        display: flex;
        flex-direction: column;
        width: min(88vw, 400px);
        max-width: 100%;
        height: 100%;
        max-height: 100dvh;
        padding: 0;
        margin: 0;
        overflow: hidden;
        background: #fff;
        border: none;
        border-radius: 18px 0 0 18px;
        box-shadow: -12px 0 40px rgba(15, 23, 42, 0.18);
        transform: translate3d(105%, 0, 0);
        transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
        z-index: 1050;
    }

    .filter-shell.mobile-open {
        transform: translate3d(0, 0, 0);
    }

    .filter-drawer-header {
        position: sticky;
        top: 0;
        flex-shrink: 0;
        margin-bottom: 0;
        padding: 1.125rem 1.125rem;
        background: #fff;
        border-bottom: 1px solid #e8eef4;
        z-index: 5;
    }

    .filter-drawer-header .filter-title {
        font-size: 1.125rem;
    }

    .filter-close-btn {
        display: inline-flex;
    }

    .filter-drawer-form {
        flex: 1 1 auto;
        display: flex;
        flex-direction: column;
        min-height: 0;
        overflow: hidden;
        margin: 0;
    }

    .filter-drawer-body {
        flex: 1 1 auto;
        min-height: 0;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
        padding: 1.125rem 1.125rem 1rem;
    }

    .filter-drawer-body .filter-grid {
        gap: 1.125rem;
    }

    .filter-drawer-body .filter-field .form-label {
        font-size: 0.8125rem;
    }

    .filter-shell .filter-form .form-control,
    .filter-shell .filter-form .form-select {
        min-height: 48px;
        font-size: 1rem;
    }

    .filter-shell .filter-checkbox-item {
        min-height: 44px;
        padding-top: 0.5rem;
        padding-bottom: 0.5rem;
    }

    .filter-drawer-footer {
        flex-shrink: 0;
        margin-top: 0;
        padding: 1rem 1.125rem;
        padding-bottom: max(1rem, env(safe-area-inset-bottom, 0px));
        background: #fff;
        border-top: 1px solid #e8eef4;
        box-shadow: 0 -8px 28px rgba(15, 23, 42, 0.07);
    }

    .filter-drawer-footer .filter-actions {
        flex-direction: row;
        gap: 0.75rem;
    }

    .filter-drawer-footer .filter-btn-reset,
    .filter-drawer-footer .filter-btn-apply {
        flex: 1 1 0;
        min-height: 48px;
        width: auto;
    }

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

    .filter-field,
    .filter-field.filter-field-full {
        grid-column: span 1;
    }

    /* Toolbar: mobile flex */
    .results-toolbar {
        display: flex;
        flex-wrap: wrap;
        padding: 0;
        background: transparent;
        border: none;
        box-shadow: none;
        backdrop-filter: none;
    }

    .result-count {
        order: 2;
        flex: 1 1 100%;
        margin-right: 0;
    }

    .filters-mobile-btn {
        order: 1;
    }

    .view-toggle-group {
        order: 3;
        margin-left: auto;
    }

    .active-filters {
        order: 4;
        flex: 1 1 100%;
        justify-content: flex-start;
        max-height: none;
        margin-top: 0.25rem;
    }

    .properties-grid.view-list .property-card-modern {
        flex-direction: column;
    }

    .properties-grid.view-list .property-media {
        flex: 0 0 auto;
        max-width: none;
        border-radius: var(--pg-radius-lg) var(--pg-radius-lg) 0 0;
    }

    .properties-grid.view-list .property-media::after {
        background: linear-gradient(180deg, transparent 35%, rgba(12, 18, 34, 0.55) 100%);
    }

    .properties-grid.view-list .property-media img {
        min-height: 210px;
        height: 210px;
    }

    .properties-grid.view-list .property-content {
        padding: 1.15rem 1.2rem 1.25rem;
    }
}

@media (max-width: 380px) {
    .filter-shell {
        width: 100%;
        border-radius: 0;
    }
}

@media (max-width: 767px) {
    .properties-page.py-5 {
        padding-top: 0 !important;
    }

    .view-toggle-group .btn {
        width: 40px;
        height: 40px;
    }

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

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