/* =========================================================
   /properties advanced search (App\Support\PropertySearch)
   Theme: primary #26ae61, heading #001935 (matches style.css)
   ========================================================= */

:root {
    --ps-primary: #26ae61;
    --ps-primary-dark: #1e8449;
    --ps-primary-soft: #eaf7f0;
    --ps-heading: #001935;
    --ps-text: #4b5563;
    --ps-muted: #6b7280;
    --ps-border: #e3e8ee;
    --ps-soft: #f6f8fa;
}

/* ---------- page layout: a real-width filter column + results ---------- */
.ps-container {
    max-width: 1440px;
}

.ps-layout {
    display: grid;
    grid-template-columns: 340px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}

/* cards keep their image area even when a thumbnail is missing,
   otherwise the owner avatar floats up over the results bar */
.ps-page .property-item .property-image {
    min-height: 220px;
    background: #eef1f4;
}

.ps-page .property-item .property-image > img {
    height: 220px !important;
}

/* ---------- filter panel ---------- */
.ps-sidebar {
    position: sticky;
    top: 110px;
}

.ps-panel {
    display: flex;
    flex-direction: column;
    border: 1px solid var(--ps-border);
    border-radius: 16px;
    background: #fff;
    box-shadow: 0 6px 22px rgba(15, 42, 71, .05);
}

.ps-panel-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    border-bottom: 1px solid var(--ps-border);
}

.ps-panel-title {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0;
    color: var(--ps-heading);
    font-size: 1.35rem;
    font-weight: 700;
}

.ps-panel-title i {
    color: var(--ps-primary);
}

.ps-close {
    display: none;
    width: 34px;
    height: 34px;
    border: 0;
    border-radius: 50%;
    background: var(--ps-soft);
    color: var(--ps-heading);
    font-size: 22px;
    line-height: 1;
}

.ps-panel-body {
    padding: 6px 22px 8px;
}

.ps-group {
    padding: 16px 0;
    border-bottom: 1px dashed var(--ps-border);
}

.ps-type-group .ps-group:last-child,
.ps-panel-body > .ps-group:last-child {
    border-bottom: 0;
}

.ps-label {
    display: block;
    margin-bottom: 10px;
    color: var(--ps-heading);
    font-size: 15px;
    font-weight: 700;
}

.ps-label small {
    color: var(--ps-muted);
    font-weight: 400;
}

.ps-panel .form-control,
.ps-panel .form-select {
    height: 46px;
    padding: 9px 14px;
    border: 1px solid #d5dce4;
    border-radius: 10px;
    color: var(--ps-heading);
    font-size: 15px;
    box-shadow: none;
}

.ps-panel .form-select {
    padding-right: 32px;
}

.ps-panel .form-control:focus,
.ps-panel .form-select:focus {
    border-color: var(--ps-primary);
    box-shadow: 0 0 0 3px rgba(38, 174, 97, .15);
}

/* custom-mrt-dev.css turns every placeholder white */
.ps-panel .form-control::placeholder {
    color: #9ca3af !important;
}

.ps-panel .form-select:disabled {
    background-color: var(--ps-soft);
    color: #9ca3af;
}

.ps-search {
    position: relative;
}

.ps-search i {
    position: absolute;
    top: 50%;
    left: 13px;
    transform: translateY(-50%);
    color: var(--ps-muted);
    font-size: 13px;
}

.ps-search .form-control {
    padding-left: 36px;
}

.ps-row {
    display: flex;
    align-items: center;
    gap: 8px;
}

.ps-row > .form-control,
.ps-row > .form-select {
    flex: 1 1 0;
    min-width: 0;
}

.ps-row-sep {
    color: var(--ps-muted);
    font-size: 12px;
}

.ps-hint {
    margin-top: 6px;
    color: var(--ps-muted);
    font-size: 12px;
}

/* pill radios */
.ps-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.ps-pill {
    margin: 0;
    cursor: pointer;
}

.ps-pill input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.ps-pill span {
    display: inline-block;
    padding: 9px 16px;
    border: 1px solid #d5dce4;
    border-radius: 999px;
    background: #fff;
    color: var(--ps-text);
    font-size: 14px;
    font-weight: 600;
    line-height: 1.2;
    transition: all .15s ease;
}

.ps-pills-tight .ps-pill span {
    min-width: 46px;
    padding: 9px 12px;
    text-align: center;
}

.ps-pill:hover span {
    border-color: var(--ps-primary);
}

.ps-pill input:checked + span {
    border-color: var(--ps-primary);
    background: var(--ps-primary);
    color: #fff;
}

.ps-pill input:focus-visible + span {
    box-shadow: 0 0 0 3px rgba(38, 174, 97, .25);
}

/* amenity checkboxes */
.ps-checks {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 6px 10px;
}

.ps-check {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    color: var(--ps-text);
    font-size: 14px;
    cursor: pointer;
}

/* mrt-custom.css scales checkboxes on some pages; keep these normal */
.ps-check input {
    flex: 0 0 auto;
    width: 15px;
    height: 15px;
    margin: 0;
    transform: none;
    accent-color: var(--ps-primary);
}

.ps-checks:not(.is-open) .ps-check.is-extra {
    display: none;
}

.ps-more {
    margin-top: 8px;
    padding: 0;
    border: 0;
    background: none;
    color: var(--ps-primary-dark);
    font-size: 13px;
    font-weight: 600;
}

.ps-type-group[hidden],
.ps-type-hint[hidden] {
    display: none;
}

.ps-type-hint {
    margin: 12px 0 2px;
    padding: 10px 12px;
    border-radius: 10px;
    background: var(--ps-soft);
    color: var(--ps-muted);
    font-size: 12.5px;
}

.ps-panel-foot {
    display: flex;
    gap: 10px;
    padding: 16px 22px;
    border-top: 1px solid var(--ps-border);
    background: #fbfcfd;
    border-radius: 0 0 16px 16px;
}

.ps-panel-foot .ps-btn {
    flex: 1 1 auto;
}

.ps-panel-foot .ps-btn-light {
    flex: 0 0 auto;
}

/* ---------- buttons ---------- */
.ps-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    padding: 12px 18px;
    border: 1px solid transparent;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
}

.ps-btn-primary {
    background: var(--ps-primary);
    color: #fff;
}

.ps-btn-primary:hover,
.ps-btn-primary:focus {
    background: var(--ps-primary-dark);
    color: #fff;
}

.ps-btn-light {
    border-color: #d5dce4;
    background: #fff;
    color: var(--ps-heading);
}

.ps-btn-light:hover {
    border-color: var(--ps-heading);
    color: var(--ps-heading);
}

/* ---------- results bar ---------- */
.ps-results-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 18px;
    border: 1px solid var(--ps-border);
    border-radius: 14px;
    background: #fff;
}

.ps-results-count {
    color: var(--ps-text);
    font-size: 15px;
}

.ps-results-count strong {
    color: var(--ps-primary);
    font-family: "Barlow Semi Condensed", sans-serif;
    font-size: 1.6rem;
    line-height: 1;
}

.ps-results-tools {
    display: flex;
    align-items: center;
    gap: 10px;
}

.ps-open {
    display: none;
}

.ps-count-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--ps-primary);
    color: #fff;
    font-size: 12px;
}

.ps-sort {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    color: var(--ps-muted);
    font-size: 13px;
}

.ps-sort .form-select {
    width: auto;
    height: 40px;
    padding: 6px 32px 6px 12px;
    border: 1px solid #d5dce4;
    border-radius: 10px;
    color: var(--ps-heading);
    font-size: 14px;
    box-shadow: none;
}

/* ---------- active filter chips ---------- */
.ps-chips {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 14px;
}

.ps-chip {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 6px 12px;
    border: 1px solid rgba(38, 174, 97, .3);
    border-radius: 999px;
    background: var(--ps-primary-soft);
    color: var(--ps-primary-dark);
    font-size: 13px;
    font-weight: 600;
}

.ps-chip i {
    font-size: 11px;
    opacity: .7;
}

.ps-chip:hover {
    border-color: var(--ps-primary);
    color: var(--ps-primary-dark);
}

.ps-chip:hover i {
    opacity: 1;
}

.ps-chip-clear {
    color: var(--ps-muted);
    font-size: 13px;
    text-decoration: underline;
}

/* ---------- empty state ---------- */
.ps-empty {
    margin-top: 20px;
    padding: 50px 20px;
    border-radius: 16px;
    background: var(--ps-soft);
    color: var(--ps-text);
    text-align: center;
}

.ps-empty i {
    margin-bottom: 14px;
    color: #9ca3af;
    font-size: 2.4rem;
}

.ps-empty h3 {
    margin: 0 0 6px;
    color: var(--ps-heading);
    font-size: 1.4rem;
    font-weight: 700;
}

/* ---------- home page quick search (hero, dark glass card) ---------- */
.hs-head {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    margin-bottom: 14px;
    padding-bottom: 12px;
    border-bottom: 1px solid rgba(255, 255, 255, .18);
}

.hs-title {
    color: #fff;
    font-family: "Barlow Semi Condensed", sans-serif;
    font-size: 1.25rem;
    font-weight: 600;
    letter-spacing: .3px;
}

.hs-advanced {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border: 1px solid rgba(255, 255, 255, .35);
    border-radius: 999px;
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    transition: background .15s ease, border-color .15s ease;
}

.hs-advanced:hover {
    border-color: var(--ps-primary);
    background: var(--ps-primary);
    color: #fff;
}

.search-box-wrapper .hs-form select.form-control {
    height: 46px;
    border-color: rgba(255, 255, 255, .35);
    color: #fff;
    font-size: 14px;
}

.search-box-wrapper .hs-form select.form-control:disabled {
    background-color: rgba(255, 255, 255, .04);
    opacity: .55;
}

/* style.css ".search a" / ".search i" absolutely position every link and icon in the hero
   (made for an old one-line search bar); undo that for the quick search pieces */
.search .hs-advanced {
    position: static;
    margin: 0;
    padding: 6px 14px;
    border-radius: 999px;
    background: transparent;
}

.search .hs-advanced:hover {
    background: var(--ps-primary);
}

/* same rule again: the phone-only "Free listing" link floated over "Advanced search".
   Give it its own row at the top of the card. */
.search-box-wrapper > .card-header {
    padding: 12px 16px 0;
    border-bottom: 0;
    background: transparent;
    text-align: right;
}

.search .search-box-wrapper > .card-header a {
    position: static;
    display: inline-block;
    margin: 0;
    padding: 7px 16px;
    border-radius: 6px;
}

.search .hs-advanced i,
.search .hs-submit i {
    position: static;
    margin: 0;
    padding: 0;
    color: inherit;
}

.search-box-wrapper .hs-form select option {
    color: var(--ps-heading);
}

.hs-submit {
    height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 7px;
    font-weight: 600;
}

/* ---------- phones / tablets: the panel becomes a drawer ---------- */
.ps-overlay {
    display: none;
}

@media (max-width: 1199px) {
    .ps-layout {
        grid-template-columns: 300px minmax(0, 1fr);
        gap: 22px;
    }
}

@media (max-width: 991px) {
    .ps-layout {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
    }

    .ps-open {
        display: inline-flex;
    }

    .ps-sidebar {
        position: fixed;
        top: 0;
        bottom: 0;
        left: 0;
        z-index: 10600;
        width: min(380px, 92vw);
        transform: translateX(-105%);
        transition: transform .25s ease;
    }

    .ps-sidebar.is-open {
        transform: translateX(0);
    }

    .ps-panel {
        height: 100%;
        border: 0;
        border-radius: 0;
    }

    .ps-panel-body {
        flex: 1 1 auto;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .ps-panel-foot {
        border-radius: 0;
    }

    .ps-close {
        display: inline-flex;
        align-items: center;
        justify-content: center;
    }

    .ps-overlay.is-open {
        display: block;
        position: fixed;
        inset: 0;
        z-index: 10599;
        background: rgba(0, 25, 53, .45);
    }

    body.ps-locked {
        overflow: hidden;
    }
}

@media (max-width: 575px) {
    .ps-results-bar {
        padding: 12px 14px;
    }

    .ps-results-tools {
        width: 100%;
        justify-content: space-between;
    }

    .ps-sort span {
        display: none;
    }
}
