/*
 * Landing-page budget panels and shared panel footer.
 * This file belongs only to housinglistings.html. The price histogram itself is the
 * shared component (components/price-range-chart.css); everything here is the landing
 * page's own chrome around it, scoped so it can never leak onto the listings pages.
 */

/* The three offering categories now hold a histogram; housing-wanted keeps the
   narrower single-input panel from housinglistings.css. */
#lease-categories .budget-dropdown-content,
#sublease-categories .budget-dropdown-content,
#housemates-wanted-categories .budget-dropdown-content {
    width: 300px;
}

/* The chart renders its own inputs wrapper, so re-apply the landing field styling
   that housinglistings.css scopes to .budget-inputs. */
#lease-categories .price-range-chart__inputs input[type='text'],
#sublease-categories .price-range-chart__inputs input[type='text'],
#housemates-wanted-categories .price-range-chart__inputs input[type='text'] {
    padding: 10px 12px;
    border: 1.5px solid #d4d4d4;
    border-radius: 8px;
    font-size: 14px;
    outline: none;
}

#lease-categories .price-range-chart__inputs input[type='text']:focus,
#sublease-categories .price-range-chart__inputs input[type='text']:focus,
#housemates-wanted-categories .price-range-chart__inputs input[type='text']:focus {
    border-color: #4fb59d;
    box-shadow: 0 0 0 1.5px rgba(79, 181, 157, 0.15);
}

/* Shared Reset / Done footer on every landing dropdown panel. */
.hl-panel-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 6px;
    margin-top: 12px;
}

.hl-panel-reset,
.hl-panel-done {
    padding: 5px 10px;
    background-color: #fff;
    color: #000;
    border: 1px solid #000;
    border-radius: 8px;
    font-size: 14px;
    line-height: 1.2;
    cursor: pointer;
}

.hl-panel-reset {
    padding: 5px 9px;
    font-size: 15px;
}

.hl-panel-reset:hover,
.hl-panel-done:hover {
    background-color: rgba(119, 119, 119, 0.15);
}

.hl-panel-reset:focus-visible,
.hl-panel-done:focus-visible {
    outline: 2px solid #4fb59d;
    outline-offset: 1px;
}

/* The availability panel already owns its footer spacing rhythm. */
[data-housing-availability] .hl-panel-actions {
    margin-top: 10px;
}

@media (max-width: 1200px) {
    /* Panels become in-flow accordions here; housinglistings.css already forces
       width:100%, so only the fixed widths above need releasing. */
    #lease-categories .budget-dropdown-content,
    #sublease-categories .budget-dropdown-content,
    #housemates-wanted-categories .budget-dropdown-content {
        width: 100%;
        min-width: 0;
    }
}
