/* PambaKali - shops page: filter bar and shop cards */

/* ============================================ */
/* FILTER BAR */
/* ============================================ */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
}

.filter-tools {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.75rem;
}

.filter-search {
    position: relative;
}

.filter-search i {
    position: absolute;
    left: 0.95rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--muted);
    font-size: 0.85rem;
    pointer-events: none;
}

.filter-search input,
.filter-sort select {
    height: 42px;
    border: 1.5px solid var(--line);
    border-radius: 999px;
    background: var(--surface-alt);
    color: var(--ink);
    font-family: inherit;
    font-size: 0.88rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.filter-search input {
    width: 220px;
    padding: 0 1rem 0 2.4rem;
}

.filter-sort select {
    padding: 0 2.2rem 0 1rem;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238b8698' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.9rem center;
    cursor: pointer;
}

.filter-search input:focus,
.filter-sort select:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 4px rgba(107, 70, 193, 0.12);
}

.results-note {
    margin: 1.25rem 0 0;
    color: var(--ink-soft);
    font-size: 0.92rem;
}

.results-note strong {
    color: var(--ink);
}

.results-note a {
    margin-left: 0.5rem;
    color: var(--brand);
    font-weight: 600;
}

/* ============================================ */
/* SHOP CARDS */
/* ============================================ */
.shops-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.25rem;
}

.shop-card {
    position: relative;
    display: flex;
    flex-direction: column;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    color: inherit;
    text-decoration: none;
    overflow: hidden;
    transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), border-color 0.35s;
}

.shop-card:hover {
    transform: translateY(-4px);
    border-color: transparent;
    box-shadow: var(--shadow-md);
}

.shop-cover {
    position: relative;
    height: 150px;
    background: var(--surface-alt);
    overflow: hidden;
}

.shop-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s var(--ease);
}

.shop-card:hover .shop-cover img {
    transform: scale(1.06);
}

.shop-cover::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(0deg, rgba(20, 14, 34, 0.45), transparent 60%);
}

.shop-cover .shop-badge {
    position: absolute;
    top: 0.75rem;
    right: 0.75rem;
    z-index: 1;
    padding: 0.25rem 0.7rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.92);
    color: var(--dark);
    font-size: 0.72rem;
    font-weight: 700;
}

.shop-avatar {
    width: 64px;
    height: 64px;
    flex-shrink: 0;
    border: 4px solid var(--surface);
    border-radius: 18px;
    background: var(--brand-gradient);
    color: white;
    display: grid;
    place-items: center;
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 600;
    box-shadow: var(--shadow-sm);
}

.shop-card .shop-avatar {
    position: relative;
    z-index: 1;
    margin: -34px 0 0 1.25rem;
}

.shop-card-body {
    display: flex;
    flex-direction: column;
    flex: 1;
    padding: 0.75rem 1.25rem 1.25rem;
}

.shop-card h3 {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 600;
    letter-spacing: -0.015em;
}

.shop-meta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem 0.85rem;
    margin: 0.3rem 0 0.75rem;
    color: var(--muted);
    font-size: 0.82rem;
}

.shop-meta i {
    color: var(--brand);
}

.shop-meta .stars {
    font-size: 0.82rem;
}

.shop-card p {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 1rem;
    color: var(--ink-soft);
    font-size: 0.9rem;
    line-height: 1.55;
}

.tag-list {
    display: flex;
    margin-bottom: 1rem;
    flex-wrap: wrap;
    gap: 0.4rem;
}

.tag {
    padding: 0.2rem 0.65rem;
    border-radius: 999px;
    background: var(--brand-light);
    color: var(--brand);
    font-size: 0.75rem;
    font-weight: 700;
}

.shop-card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px solid var(--line);
    color: var(--ink-soft);
    font-size: 0.85rem;
}

.shop-card-footer .visit {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--brand);
    font-weight: 700;
    transition: gap 0.2s;
}

.shop-card:hover .visit {
    gap: 10px;
}

@media (max-width: 1100px) {
    .shops-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 767px) {
    .filter-bar { padding: 0.85rem; }
    /* Rows may shrink to the screen; the chips scroll sideways instead of widening the page */
    .filter-bar > * { min-width: 0; }
    .filter-bar .chips {
        flex-wrap: nowrap;
        overflow-x: auto;
        width: 100%;
        scrollbar-width: none;
    }
    .filter-bar .chips::-webkit-scrollbar { display: none; }
    .filter-tools { width: 100%; }
    .filter-search { flex: 1; }
    .filter-search input { width: 100%; }
    .shops-grid { grid-template-columns: 1fr; }
}
