/* /real-estate/assets/css/property-grid.css
   Listings page — filter sidebar, sort bar, grid/list toggle */

/* ---- SORT BAR ---- */
.re-sort-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid var(--re-rule);
    margin-bottom: 24px;
    flex-wrap: wrap;
}
.re-sort-bar__count {
    font-family: var(--re-font-ui);
    font-size: 0.86rem;
    color: var(--re-muted);
}
.re-sort-bar__count strong { color: var(--re-ink-soft); }
.re-sort-bar__right {
    display: flex;
    align-items: center;
    gap: 10px;
}
.re-sort-select {
    padding: 7px 28px 7px 11px;
    border: 1px solid var(--re-rule);
    border-radius: var(--re-radius);
    font-family: var(--re-font-ui);
    font-size: 0.82rem;
    color: var(--re-ink-soft);
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='7' viewBox='0 0 10 7'%3E%3Cpath d='M1 1l4 4 4-4' stroke='%236b6b6b' stroke-width='1.4' fill='none' stroke-linecap='round'/%3E%3C/svg%3E") no-repeat right 10px center;
    appearance: none;
    cursor: pointer;
}
.re-sort-select:focus { outline: none; border-color: var(--re-sea-lt); }

/* ---- GRID/LIST TOGGLE ---- */
.re-view-toggle {
    display: flex;
    border: 1px solid var(--re-rule);
    border-radius: var(--re-radius);
    overflow: hidden;
}
.re-view-toggle__btn {
    width: 34px; height: 34px;
    display: flex; align-items: center; justify-content: center;
    background: #fff;
    border: none;
    cursor: pointer;
    transition: background .18s;
}
.re-view-toggle__btn:hover { background: var(--re-sand); }
.re-view-toggle__btn.active { background: var(--re-sea); }
.re-view-toggle__btn svg { width: 15px; height: 15px; stroke: var(--re-muted); fill: none; }
.re-view-toggle__btn.active svg { stroke: #fff; }

/* ---- FILTER SIDEBAR (refined) ---- */
.re-filter-sidebar {
    font-family: var(--re-font-ui);
}
.re-filter-sidebar .re-filter-title {
    font-size: 0.86rem;
    font-weight: 600;
    color: var(--re-dusk);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.re-filter-sidebar .re-filter-reset {
    font-size: 0.74rem;
    color: var(--re-muted);
    cursor: pointer;
    font-weight: 400;
    text-decoration: underline;
    background: none;
    border: none;
    padding: 0;
}
.re-filter-sidebar .re-filter-reset:hover { color: var(--re-sea); }
.re-active-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 20px;
}
.re-active-tag {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 4px 10px;
    background: var(--re-sea);
    color: #fff;
    border-radius: 20px;
    font-family: var(--re-font-ui);
    font-size: 0.74rem;
    font-weight: 500;
}
.re-active-tag button {
    background: none;
    border: none;
    color: rgba(255,255,255,.8);
    cursor: pointer;
    font-size: 0.82rem;
    padding: 0;
    line-height: 1;
}
.re-active-tag button:hover { color: #fff; }

/* ---- BHK BUTTONS ---- */
.re-bhk-buttons {
    display: flex;
    gap: 6px;
    flex-wrap: wrap;
}
.re-bhk-btn {
    padding: 6px 12px;
    border: 1px solid var(--re-rule);
    border-radius: 4px;
    background: #fff;
    font-family: var(--re-font-ui);
    font-size: 0.8rem;
    color: var(--re-ink-soft);
    cursor: pointer;
    transition: all .18s;
}
.re-bhk-btn:hover, .re-bhk-btn.active {
    background: var(--re-sea);
    border-color: var(--re-sea);
    color: #fff;
}

/* ---- PRICE RANGE SLIDER ---- */
.re-range-display {
    display: flex;
    justify-content: space-between;
    font-family: var(--re-font-ui);
    font-size: 0.76rem;
    color: var(--re-muted);
    margin-top: 8px;
}
input[type="range"].re-slider {
    width: 100%;
    accent-color: var(--re-sea);
    margin: 6px 0;
}

/* ---- LIST VIEW CARD ---- */
.re-listing-grid.list-view {
    grid-template-columns: 1fr;
}
.re-listing-grid.list-view .re-card {
    flex-direction: row;
}
.re-listing-grid.list-view .re-card__img {
    width: 280px;
    flex-shrink: 0;
    aspect-ratio: auto;
    height: 200px;
}
.re-listing-grid.list-view .re-card__body {
    padding: 18px 22px;
}
@media (max-width: 640px) {
    .re-listing-grid.list-view .re-card { flex-direction: column; }
    .re-listing-grid.list-view .re-card__img { width: 100%; height: auto; aspect-ratio: 16/9; }
}

/* ---- NO RESULTS ---- */
.re-no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 64px 24px;
}
.re-no-results h3 {
    font-family: var(--re-font-head);
    font-size: 1.2rem;
    color: var(--re-dusk);
    margin-bottom: 10px;
}
.re-no-results p { font-size: 0.9rem; color: var(--re-muted); margin-bottom: 20px; }

/* ---- MOBILE FILTER DRAWER ---- */
.re-filter-toggle-btn {
    display: none;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    border: 1px solid var(--re-rule);
    border-radius: var(--re-radius);
    background: #fff;
    font-family: var(--re-font-ui);
    font-size: 0.86rem;
    cursor: pointer;
}
.re-filter-toggle-btn svg { width: 16px; height: 16px; stroke: var(--re-muted); fill: none; }
.re-filter-drawer-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.4);
    z-index: 100;
}
.re-filter-drawer {
    position: fixed;
    left: 0; top: 0; bottom: 0;
    width: 300px;
    background: #fff;
    z-index: 101;
    transform: translateX(-100%);
    transition: transform .28s ease;
    overflow-y: auto;
    padding: 20px;
    box-shadow: var(--re-shadow-lg);
}
.re-filter-drawer.open { transform: translateX(0); }
.re-filter-drawer-overlay.open { display: block; }
.re-filter-drawer__head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--re-rule);
}
.re-filter-drawer__head h3 {
    font-family: var(--re-font-ui);
    font-weight: 600;
    font-size: 0.94rem;
    color: var(--re-dusk);
}
.re-filter-drawer__close {
    background: none;
    border: none;
    font-size: 1.4rem;
    color: var(--re-muted);
    cursor: pointer;
}

@media (max-width: 900px) {
    .re-listing-layout { grid-template-columns: 1fr; }
    .re-filter-sidebar { display: none; }
    .re-filter-toggle-btn { display: flex; }
    .re-sort-bar { flex-direction: column; align-items: flex-start; }
}
