/* ── Business Directory – Public Styles ── */
:root {
    --bd-primary:    #2563eb;
    --bd-primary-light: #eff6ff;
    --bd-accent:     #f59e0b;
    --bd-text:       #1e293b;
    --bd-muted:      #64748b;
    --bd-border:     #e2e8f0;
    --bd-bg:         #f8fafc;
    --bd-white:      #ffffff;
    --bd-radius-sm:  6px;
    --bd-radius:     12px;
    --bd-radius-lg:  16px;
    --bd-shadow:     0 4px 6px -1px rgba(0,0,0,.07), 0 2px 4px -1px rgba(0,0,0,.04);
    --bd-shadow-lg:  0 10px 25px -5px rgba(0,0,0,.1), 0 4px 6px -2px rgba(0,0,0,.05);
    --bd-transition: .2s ease;
}

/* ── Container ─────────────────────────────────────────────────── */
.bd-directory { font-family: inherit; color: var(--bd-text); }

/* ── Controls ───────────────────────────────────────────────────── */
.bd-controls {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 28px;
    align-items: center;
}

.bd-search-wrap {
    position: relative;
    flex: 1;
    min-width: 220px;
}
.bd-search-wrap input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border: 2px solid var(--bd-border);
    border-radius: var(--bd-radius);
    font-size: 15px;
    background: var(--bd-white);
    color: var(--bd-text);
    transition: border-color var(--bd-transition), box-shadow var(--bd-transition);
    box-sizing: border-box;
}
.bd-search-wrap input:focus {
    outline: none;
    border-color: var(--bd-primary);
    box-shadow: 0 0 0 3px rgba(37,99,235,.15);
}
.bd-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--bd-muted);
    pointer-events: none;
}

.bd-filters {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}
.bd-filters select,
.bd-filters input[type="text"] {
    padding: 10px 14px;
    border: 2px solid var(--bd-border);
    border-radius: var(--bd-radius);
    font-size: 14px;
    background: var(--bd-white);
    color: var(--bd-text);
    min-width: 160px;
    transition: border-color var(--bd-transition);
    cursor: pointer;
}
.bd-filters select:focus,
.bd-filters input:focus {
    outline: none;
    border-color: var(--bd-primary);
}

/* ── Loading ─────────────────────────────────────────────────────── */
.bd-loading {
    text-align: center;
    padding: 60px 20px;
    color: var(--bd-muted);
}
.bd-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--bd-border);
    border-top-color: var(--bd-primary);
    border-radius: 50%;
    animation: bd-spin .7s linear infinite;
    margin: 0 auto 16px;
}
@keyframes bd-spin { to { transform: rotate(360deg); } }

/* ── Grid ─────────────────────────────────────────────────────────── */
.bd-listings { display: grid; gap: 20px; }
.bd-cols-1 { grid-template-columns: 1fr; }
.bd-cols-2 { grid-template-columns: repeat(2, 1fr); }
.bd-cols-3 { grid-template-columns: repeat(3, 1fr); }
.bd-cols-4 { grid-template-columns: repeat(4, 1fr); }

@media (max-width: 1024px) {
    .bd-cols-4 { grid-template-columns: repeat(2, 1fr); }
    .bd-cols-3 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
    .bd-cols-2, .bd-cols-3, .bd-cols-4 { grid-template-columns: 1fr; }
}

/* ── Card ─────────────────────────────────────────────────────────── */
.bd-card {
    background: var(--bd-white);
    border-radius: var(--bd-radius-lg);
    box-shadow: var(--bd-shadow);
    overflow: hidden;
    transition: transform var(--bd-transition), box-shadow var(--bd-transition);
    display: flex;
    flex-direction: column;
    animation: bd-fade-in .35s ease both;
}
.bd-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--bd-shadow-lg);
}
@keyframes bd-fade-in {
    from { opacity: 0; transform: translateY(10px); }
    to   { opacity: 1; transform: translateY(0); }
}

.bd-card-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
    background: var(--bd-bg);
}
.bd-card-image-placeholder {
    height: 180px;
    background: linear-gradient(135deg, #e2e8f0, #cbd5e1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
}

.bd-card-body { padding: 18px; flex: 1; display: flex; flex-direction: column; gap: 8px; }

.bd-card-category {
    display: inline-block;
    padding: 3px 10px;
    background: var(--bd-primary-light);
    color: var(--bd-primary);
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
    align-self: flex-start;
}

.bd-card-name {
    font-size: 18px;
    font-weight: 700;
    color: var(--bd-text);
    margin: 0;
    line-height: 1.3;
}

.bd-card-meta {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 4px;
    flex: 1;
}

.bd-card-meta-row {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13.5px;
    color: var(--bd-muted);
    line-height: 1.4;
}
.bd-card-meta-row svg { flex-shrink: 0; margin-top: 1px; }
.bd-card-meta-row a { color: var(--bd-primary); text-decoration: none; }
.bd-card-meta-row a:hover { text-decoration: underline; }

.bd-card-footer {
    padding: 14px 18px;
    border-top: 1px solid var(--bd-border);
    display: flex;
    gap: 10px;
}

.bd-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border-radius: var(--bd-radius-sm);
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background var(--bd-transition), color var(--bd-transition);
    cursor: pointer;
    border: none;
}
.bd-btn-primary { background: var(--bd-primary); color: #fff; }
.bd-btn-primary:hover { background: #1d4ed8; color: #fff; }
.bd-btn-outline {
    background: transparent;
    color: var(--bd-primary);
    border: 1.5px solid var(--bd-primary);
}
.bd-btn-outline:hover { background: var(--bd-primary-light); }
.bd-btn-whatsapp { background: #25d366; color: #fff; }
.bd-btn-whatsapp:hover { background: #1da851; color: #fff; }

/* ── List style ───────────────────────────────────────────────────── */
.bd-style-list .bd-card {
    flex-direction: row;
    align-items: stretch;
}
.bd-style-list .bd-card-image { width: 140px; height: auto; min-height: 120px; flex-shrink: 0; }
.bd-style-list .bd-card-image-placeholder { width: 140px; height: auto; min-height: 120px; flex-shrink: 0; }
.bd-style-list .bd-card-body { padding: 16px 20px; }
.bd-style-list .bd-card-meta { flex-direction: row; flex-wrap: wrap; gap: 8px 20px; }
.bd-style-list .bd-card-footer { border-top: none; border-left: 1px solid var(--bd-border); align-items: center; flex-direction: column; justify-content: center; padding: 16px; }

/* ── No results ──────────────────────────────────────────────────── */
.bd-no-results {
    grid-column: 1 / -1;
    text-align: center;
    padding: 60px 20px;
    color: var(--bd-muted);
}
.bd-no-results-icon { font-size: 56px; margin-bottom: 16px; }
.bd-no-results h3 { font-size: 20px; color: var(--bd-text); margin-bottom: 8px; }

/* ── Pagination ───────────────────────────────────────────────────── */
.bd-pagination {
    display: flex;
    justify-content: center;
    gap: 6px;
    margin-top: 32px;
    flex-wrap: wrap;
}
.bd-page-btn {
    padding: 8px 14px;
    border: 2px solid var(--bd-border);
    border-radius: var(--bd-radius-sm);
    background: var(--bd-white);
    color: var(--bd-text);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all var(--bd-transition);
}
.bd-page-btn:hover { border-color: var(--bd-primary); color: var(--bd-primary); }
.bd-page-btn.active { background: var(--bd-primary); border-color: var(--bd-primary); color: #fff; }
.bd-page-btn:disabled { opacity: .4; cursor: not-allowed; }

/* ══════════════════════════════════════════════════
   BD Single Business Page
══════════════════════════════════════════════════ */

.bd-single-wrap { max-width: 1100px; margin: 0 auto; padding: 0 20px 60px; }

/* Hero */
.bd-single-hero {
    width: 100%;
    min-height: 320px;
    background: linear-gradient(135deg, #1e293b, #334155);
    background-size: cover;
    background-position: center;
    border-radius: var(--bd-radius-lg);
    overflow: hidden;
    margin-bottom: 32px;
    position: relative;
}
.bd-single-hero-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,.75) 0%, rgba(0,0,0,.2) 60%, transparent 100%);
    display: flex; align-items: flex-end;
}
.bd-single-hero-content { padding: 32px; width: 100%; }
.bd-single-cats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.bd-single-badge {
    display: inline-block;
    padding: 4px 14px;
    background: var(--bd-primary);
    color: #fff;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}
.bd-single-title {
    color: #fff;
    font-size: clamp(24px, 4vw, 42px);
    font-weight: 800;
    margin: 0;
    line-height: 1.2;
    text-shadow: 0 2px 8px rgba(0,0,0,.4);
}

/* Body layout */
.bd-single-body {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 32px;
    align-items: start;
}
@media (max-width: 900px) {
    .bd-single-body { grid-template-columns: 1fr; }
    .bd-single-sidebar { order: -1; }
}

/* Description */
.bd-single-description {
    font-size: 16px;
    line-height: 1.7;
    color: var(--bd-text);
    margin-bottom: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid var(--bd-border);
}

/* Info grid */
.bd-single-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}
@media (max-width: 600px) { .bd-single-info-grid { grid-template-columns: 1fr; } }

.bd-single-info-item {
    display: flex;
    align-items: flex-start;
    gap: 14px;
    padding: 16px;
    background: var(--bd-bg);
    border-radius: var(--bd-radius);
    border: 1px solid var(--bd-border);
}
.bd-single-info-full { grid-column: 1 / -1; }
.bd-single-info-icon {
    width: 40px; height: 40px;
    background: var(--bd-primary-light);
    border-radius: var(--bd-radius-sm);
    display: flex; align-items: center; justify-content: center;
    color: var(--bd-primary);
    flex-shrink: 0;
}
.bd-single-info-content { display: flex; flex-direction: column; gap: 3px; }
.bd-single-info-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--bd-muted);
}
.bd-single-info-value { font-size: 15px; font-weight: 500; color: var(--bd-text); }
.bd-single-link { color: var(--bd-primary); text-decoration: none; }
.bd-single-link:hover { text-decoration: underline; }

/* Sidebar CTA */
.bd-single-cta-card {
    background: var(--bd-white);
    border-radius: var(--bd-radius-lg);
    box-shadow: var(--bd-shadow-lg);
    overflow: hidden;
    position: sticky;
    top: 80px;
}
.bd-single-thumb { width: 100%; height: 200px; object-fit: cover; display: block; }
.bd-single-cta-body { padding: 24px; display: flex; flex-direction: column; gap: 12px; }
.bd-single-cta-title { font-size: 18px; font-weight: 700; margin: 0 0 4px; color: var(--bd-text); }

.bd-single-cta-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 13px 20px;
    border-radius: var(--bd-radius);
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: filter .15s, transform .15s;
}
.bd-single-cta-btn:hover { filter: brightness(1.08); transform: translateY(-1px); }
.bd-cta-phone     { background: var(--bd-primary); color: #fff; }
.bd-cta-whatsapp  { background: #25d366; color: #fff; }
.bd-cta-instagram { background: linear-gradient(45deg, #f09433,#e6683c,#dc2743,#cc2366,#bc1888); color: #fff; }

.bd-single-back {
    display: block;
    text-align: center;
    margin-top: 8px;
    font-size: 13px;
    color: var(--bd-muted);
    text-decoration: none;
    padding: 8px;
}
.bd-single-back:hover { color: var(--bd-primary); }

/* Shortcode contact */
.bd-sc-contact { display: flex; flex-wrap: wrap; gap: 10px; }
.bd-sc-field { font-size: 14px; }
.bd-sc-label { font-weight: 600; }

/* ── New filter styles ────────────────────────────────────────── */
.bd-controls { flex-direction: column; align-items: stretch; }
.bd-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-end;
}
.bd-filter-item { display: flex; flex-direction: column; gap: 5px; flex: 1; min-width: 150px; }
.bd-filter-item--btn { justify-content: flex-end; flex: 0 0 auto; }
.bd-filter-label { font-size: 12px; font-weight: 600; color: var(--bd-muted); text-transform: uppercase; letter-spacing: .04em; }
.bd-select {
    padding: 10px 14px;
    border: 2px solid var(--bd-border);
    border-radius: var(--bd-radius);
    font-size: 14px;
    background: var(--bd-white);
    color: var(--bd-text);
    width: 100%;
    transition: border-color var(--bd-transition);
    cursor: pointer;
    appearance: auto;
}
.bd-select:focus { outline: none; border-color: var(--bd-primary); }

.bd-btn-clear {
    padding: 10px 16px;
    border: 2px solid var(--bd-border);
    border-radius: var(--bd-radius);
    background: #fff;
    color: var(--bd-muted);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--bd-transition);
    white-space: nowrap;
}
.bd-btn-clear:hover { border-color: var(--bd-danger); color: var(--bd-danger); background: #fff5f5; }

/* Active filter tags */
.bd-active-filters {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 16px;
}
.bd-filter-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    background: var(--bd-primary-light);
    color: var(--bd-primary);
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}
.bd-filter-tag button {
    background: none;
    border: none;
    cursor: pointer;
    color: var(--bd-primary);
    font-size: 14px;
    padding: 0;
    line-height: 1;
}
