/* EzzyFinda — styles for views/listings/index.blade.php (moved from inline <style>) */

:root {
    --ef-surface-2: #E8EDF4;
    --ef-border: #DDE3ED;
}

/* ── Header ─────────────────────────────────────────── */
.listings-header {
    background: linear-gradient(135deg, var(--ef-blue-dark) 0%, var(--ef-blue) 100%);
    padding: 2rem 0 1.75rem;
}

.listings-heading {
    font-size: clamp(1.4rem, 3vw, 2rem);
    font-weight: 800;
    color: #fff;
    letter-spacing: -.02em;
    margin: 0 0 4px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.listings-sub {
    color: rgba(255,255,255,.65);
    font-size: .9rem;
    margin: 0;
}

/* ── Filter card ────────────────────────────────────── */
.filter-card {
    background: #fff;
    border: 1px solid var(--ef-border);
    border-radius: 12px;
    overflow: hidden;
}

.filter-card-header {
    padding: .85rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
    transition: background .15s;
}

.filter-card-header:hover { background: var(--ef-surface); }

.filter-card-title {
    font-weight: 700;
    font-size: .875rem;
    color: var(--ef-text);
    display: flex;
    align-items: center;
    gap: 7px;
}

.filter-card-title .bi { color: var(--ef-blue); font-size: .9rem; }

.filter-chevron {
    font-size: .75rem;
    color: var(--ef-muted);
    transition: transform .2s;
}

.filter-chevron.open { transform: rotate(180deg); }

.filter-card-body {
    padding: .5rem .75rem .75rem;
    border-top: 1px solid var(--ef-border);
}

.filter-scroll { max-height: 220px; overflow-y: auto; scrollbar-width: thin; }

/* Filter inputs */
.filter-radio, .filter-check {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    padding: .45rem .5rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: .875rem;
    transition: background .12s;
}

.filter-radio:hover, .filter-check:hover { background: var(--ef-surface); }

.filter-radio input, .filter-check input { flex-shrink: 0; cursor: pointer; }

.filter-radio span, .filter-check span { flex: 1; display: flex; align-items: center; gap: 6px; }

.filter-count {
    font-size: .72rem;
    color: var(--ef-muted);
    font-weight: 600;
    background: var(--ef-surface-2);
    padding: .1rem .45rem;
    border-radius: 99px;
    flex-shrink: 0;
}

/* Active filter pills */
.active-filter-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: .3rem .75rem;
    background: var(--ef-blue-pale);
    color: var(--ef-blue);
    border-radius: 99px;
    font-size: .78rem;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid rgba(13,59,140,.15);
    transition: background .15s;
}

.active-filter-pill:hover { background: #d0e3f8; color: var(--ef-blue); }

/* View toggle */
.view-toggle-btn {
    background: #fff;
    border: none;
    padding: .4rem .7rem;
    color: var(--ef-muted);
    cursor: pointer;
    font-size: .9rem;
    transition: background .12s, color .12s;
}

.view-toggle-btn:hover { background: var(--ef-surface); color: var(--ef-blue); }

.view-toggle-btn.active { background: var(--ef-blue); color: #fff; }

/* ── List card (Bootstrap media object) ─────────────────── */
.llc {
    background: #fff;
    border: 1px solid var(--ef-border);
    border-radius: var(--ef-radius-lg);
    overflow: hidden;
    transition: transform .22s, box-shadow .22s;
}

.llc:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 36px rgba(13,59,140,.1);
}

/* Left image column — fixed 240px on md+, full width on mobile */
.llc-img-col {
    width: 240px;
    flex-shrink: 0;
}

.llc-cover {
    width: 100%;
    height: 100%;
    min-height: 180px;
    object-fit: cover;
    display: block;
}

/* Overlay badges on the image */
.llc-badge {
    font-size: .6rem;
    font-weight: 700;
    padding: .18rem .55rem;
    border-radius: 99px;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    backdrop-filter: blur(4px);
}

.llc-badge-open   { background: rgba(5,150,105,.92);   color: #fff; }

.llc-badge-closed { background: rgba(100,116,139,.85); color: #fff; }

.llc-badge-dark   { background: rgba(0,0,0,.55);       color: #fff; font-size: .68rem; }

/* Right content body */
.llc-body {
    min-width: 0;           /* prevent flex blowout */
    overflow: hidden;
}

.llc-category {
    font-size: .65rem;
    font-weight: 700;
    color: var(--ef-orange);
    text-transform: uppercase;
    letter-spacing: .09em;
}

.llc-name {
    font-family: 'Jost', sans-serif;
    font-size: 1rem;
    font-weight: 800;
    color: var(--ef-text);
    letter-spacing: -.015em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin: 0;
}

.llc-tagline {
    font-size: .82rem;
    color: var(--ef-muted);
    line-height: 1.5;
    margin: 0;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.llc-star { font-size: .72rem; color: #F59E0B; }

.llc-rating-val   { font-size: .82rem; font-weight: 700; color: var(--ef-text); }

.llc-rating-count { font-size: .75rem; color: var(--ef-muted); }

.llc-no-review    { font-size: .78rem; color: var(--ef-muted); font-style: italic; }

.llc-chip {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: .2rem .6rem;
    border-radius: 99px;
    font-size: .68rem;
    font-weight: 600;
    border: 1px solid var(--ef-border);
}

.llc-chip-neutral  { background: var(--ef-surface); color: var(--ef-muted); }

.llc-chip-featured { background: #FFFBEB; color: #D97706; border-color: #FCD34D; }

.llc-chip-book     { background: var(--ef-blue-pale); color: var(--ef-blue); border-color: rgba(13,59,140,.18); }

.llc-footer-row {
    border-top: 1px solid var(--ef-border);
}

.llc-location {
    font-size: .8rem;
    color: var(--ef-muted);
}

.llc-location .bi { color: var(--ef-orange); font-size: .82rem; }

.llc-price  { font-size: .85rem; font-weight: 700; color: var(--ef-blue); }

.llc-est    { font-size: .75rem; color: var(--ef-muted); }

.llc-views  { font-size: .75rem; color: var(--ef-muted); display: flex; align-items: center; gap: 3px; }

.llc-cta    { font-size: .8rem; font-weight: 700; color: var(--ef-blue); display: flex; align-items: center; gap: 4px; transition: gap .15s; }

.llc:hover .llc-cta { gap: 8px; }

/* ── Mobile: stack image above content ───────────────────── */
@media (max-width: 575px) {
    .llc { flex-direction: column !important; }
    .llc-img-col { width: 100%; }
    .llc-cover { min-height: 160px; height: 160px; }
}

/* ── Listing grid items ───────────────────────────────────── */
.grid-item {
    width: calc(33.333% - 1rem);
    flex: 0 0 calc(33.333% - 1rem);
}

@media (max-width: 1200px) {
    .grid-item { width: calc(50% - .75rem); flex: 0 0 calc(50% - .75rem); }
}

@media (max-width: 640px) {
    .grid-item { width: 100%; flex: 0 0 100%; }
}

/* In list mode, items go full width */
.listings-page.list-view .grid-item {
    width: 100% !important;
    flex: 0 0 100% !important;
    max-width: 100% !important;
}

.listings-page.list-view .grid-card-wrap { display: none; }

.listings-page.list-view .list-card-wrap { display: block !important; }

/* ── Lazy image fade-in ───────────────────────────────────── */
.lazy-img {
    opacity: 0;
    transition: opacity .4s ease;
}

.lazy-img.loaded { opacity: 1; }

.llc-cta { display: none; }

/* Mobile filter drawer */
.mobile-filter-overlay {
    display: none;
    position: fixed; inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 1040;
}

.mobile-filter-overlay.open { display: block; }

.mobile-filter-drawer {
    position: fixed;
    bottom: 0; left: 0; right: 0;
    background: #fff;
    border-radius: 20px 20px 0 0;
    z-index: 1041;
    transform: translateY(100%);
    transition: transform .3s cubic-bezier(.4,0,.2,1);
    max-height: 80vh;
    display: flex;
    flex-direction: column;
}

.mobile-filter-drawer.open { transform: translateY(0); }
