/* === WAYANAD BUSINESS DIRECTORY v3.1 === */

/* --- FILTERS --- */
.wbd-directory { max-width: 1200px; margin: 0 auto; padding: 20px; }

.wbd-filters-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 12px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.wbd-filter-group { display: flex; align-items: center; gap: 8px; }
.wbd-filter-group label { font-weight: 600; font-size: 13px; color: #495057; text-transform: uppercase; letter-spacing: 0.5px; }
.wbd-filter-group select {
    padding: 10px 14px;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    font-size: 14px;
    background: white;
    cursor: pointer;
    min-width: 140px;
}

.wbd-layout-toggle { margin-left: auto; display: flex; gap: 8px; }
.wbd-layout-btn {
    padding: 10px 14px;
    border: 2px solid #dee2e6;
    background: white;
    cursor: pointer;
    border-radius: 8px;
    font-size: 18px;
    transition: all 0.2s;
}
.wbd-layout-btn.active { background: #2c6e49; color: white; border-color: #2c6e49; }

.wbd-results-count { color: #6c757d; font-size: 14px; margin-bottom: 20px; }

/* --- LISTINGS --- */
.wbd-listings {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 25px;
}

.wbd-listings.wbd-layout-row { display: block; }

/* --- CARD --- */
.wbd-card {
    position: relative;
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.wbd-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0,0,0,0.12);
}

.wbd-tier-sponsored { border: 2px solid #ffd700; }
.wbd-tier-premium { border: 2px solid #c0c0c0; }

.wbd-badge-sponsored,
.wbd-badge-premium {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    z-index: 2;
}

.wbd-badge-sponsored { background: linear-gradient(135deg, #ffd700, #ffb700); color: #333; }
.wbd-badge-premium { background: linear-gradient(135deg, #e8e8e8, #c0c0c0); color: #333; }

.wbd-card-image {
    position: relative;
    height: 220px;
    overflow: hidden;
}

.wbd-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.wbd-card:hover .wbd-card-image img { transform: scale(1.08); }

.wbd-food-tag {
    position: absolute;
    bottom: 12px;
    right: 12px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.wbd-food-veg { background: #2c6e49; color: white; }
.wbd-food-non-veg { background: #c62828; color: white; }

.wbd-card-body { padding: 20px; }
.wbd-card-body h3 { margin: 0 0 12px; font-size: 20px; }
.wbd-card-body h3 a { color: #212529; text-decoration: none; }
.wbd-card-body h3 a:hover { color: #2c6e49; }

.wbd-location { margin: 10px 0; color: #6c757d; font-size: 14px; }
.wbd-place { display: block; font-weight: 600; color: #2c6e49; margin-bottom: 4px; }
.wbd-landmark { display: block; font-size: 13px; }

.wbd-cost { color: #495057; font-size: 14px; font-weight: 500; margin: 10px 0; }

.wbd-card-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 15px 0;
}

.wbd-card-actions a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 8px 14px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: opacity 0.2s;
}

.wbd-btn-map { background: #e3f2fd; color: #1565c0; }
.wbd-btn-call { background: #e8f5e9; color: #2e7d32; }
.wbd-btn-whatsapp { background: #f3e5f5; color: #7b1fa2; }

.wbd-thumb-gallery {
    display: flex;
    gap: 8px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e9ecef;
}

.wbd-thumb-gallery img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: opacity 0.2s;
}

.wbd-thumb-gallery img:hover { opacity: 0.8; }

/* --- ROW LAYOUT --- */
.wbd-layout-row .wbd-card {
    display: flex;
    margin-bottom: 20px;
}

.wbd-layout-row .wbd-card-image {
    width: 300px;
    height: 220px;
    flex-shrink: 0;
}

.wbd-layout-row .wbd-card-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

/* --- SINGLE --- */
.wbd-single { max-width: 900px; margin: 0 auto; padding: 20px; }

.wbd-single-hero {
    position: relative;
    height: 450px;
    overflow: hidden;
    border-radius: 16px;
    margin-bottom: 25px;
}

.wbd-single-hero img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.wbd-single-food {
    position: absolute;
    bottom: 20px;
    right: 20px;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
}

.wbd-single-tier {
    position: absolute;
    top: 20px;
    left: 20px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #ffd700, #ffb700);
    color: #333;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
}

.wbd-single h1 { font-size: 36px; margin: 0 0 10px; }

.wbd-single-breadcrumb {
    color: #6c757d;
    font-size: 14px;
    margin-bottom: 20px;
}

.wbd-single-breadcrumb a { color: #2c6e49; }

.wbd-single-quick {
    display: flex;
    gap: 20px;
    margin: 20px 0;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 10px;
}

.wbd-quick-item { font-size: 15px; color: #495057; }

.wbd-single-actions-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin: 25px 0;
}

.wbd-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    color: white;
    transition: transform 0.2s, box-shadow 0.2s;
}

.wbd-action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.15);
}

.wbd-action-call { background: linear-gradient(135deg, #2e7d32, #1b5e20); }
.wbd-action-whatsapp { background: linear-gradient(135deg, #25d366, #128c7e); }
.wbd-action-map { background: linear-gradient(135deg, #1565c0, #0d47a1); }
.wbd-action-zomato { background: linear-gradient(135deg, #cb202d, #9e1b26); }
.wbd-action-swiggy { background: linear-gradient(135deg, #fc8019, #e67300); }

.wbd-single-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin: 30px 0;
}

.wbd-detail-section {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
}

.wbd-detail-section h3 {
    margin: 0 0 15px;
    font-size: 18px;
    color: #212529;
}

.wbd-detail-section p { margin: 10px 0; color: #495057; }

.wbd-hours-table { width: 100%; }
.wbd-hours-table td { padding: 10px 0; border-bottom: 1px solid #e9ecef; }
.wbd-hours-table tr.wbd-closed { color: #c62828; }
.wbd-hours-table tr.wbd-closed td:last-child { font-weight: 600; }

.wbd-single-gallery-section { margin: 30px 0; }
.wbd-single-gallery-section h3 { font-size: 22px; margin-bottom: 20px; }

.wbd-single-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 15px;
}

.wbd-gallery-item {
    margin: 0;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
}

.wbd-gallery-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s;
}

.wbd-gallery-item:hover img { transform: scale(1.05); }

.wbd-single-about {
    margin: 30px 0;
    line-height: 1.8;
    color: #495057;
}

.wbd-single-about h3 { font-size: 22px; margin-bottom: 15px; }

.wbd-nearby { margin: 40px 0; padding-top: 30px; border-top: 2px solid #e9ecef; }
.wbd-nearby h3 { font-size: 22px; margin-bottom: 20px; }

.wbd-nearby-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 20px;
}

.wbd-nearby-item {
    text-align: center;
    text-decoration: none;
    color: #212529;
}

.wbd-nearby-item img {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 10px;
}

.wbd-nearby-item span { font-size: 14px; font-weight: 500; }

.wbd-single-cta {
    margin: 40px 0;
    padding: 30px;
    background: linear-gradient(135deg, #2c6e49, #1b4332);
    border-radius: 16px;
    text-align: center;
    color: white;
}

.wbd-single-cta a { color: #ffd700; font-weight: 600; }

/* --- PLACE ARCHIVE --- */
.wbd-place-archive { max-width: 1200px; margin: 0 auto; padding: 20px; }

.wbd-place-header {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #f8f9fa, #e9ecef);
    border-radius: 16px;
    margin-bottom: 30px;
}

.wbd-place-header h1 { font-size: 36px; margin: 0 0 15px; }
.wbd-place-header p { color: #6c757d; font-size: 16px; max-width: 600px; margin: 0 auto; }

.wbd-place-seo {
    margin-top: 50px;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 12px;
}

.wbd-place-seo h2 { font-size: 24px; margin-bottom: 15px; }
.wbd-place-seo p { color: #495057; line-height: 1.7; margin: 10px 0; }

/* --- NO RESULTS --- */
.wbd-no-results {
    text-align: center;
    padding: 60px 20px;
    color: #6c757d;
}

.wbd-no-results a { color: #2c6e49; font-weight: 600; }

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .wbd-filters-bar { flex-direction: column; align-items: stretch; }
    .wbd-layout-toggle { margin-left: 0; justify-content: center; }
    .wbd-listings { grid-template-columns: 1fr; }
    .wbd-layout-row .wbd-card { flex-direction: column; }
    .wbd-layout-row .wbd-card-image { width: 100%; }
    .wbd-single-hero { height: 250px; }
    .wbd-single h1 { font-size: 26px; }
    .wbd-single-actions-bar { flex-direction: column; }
    .wbd-action-btn { justify-content: center; }
    .wbd-single-gallery { grid-template-columns: repeat(2, 1fr); }
}
/* --- LIGHTBOX --- */
.wbd-lightbox-trigger { cursor: pointer; }
.wbd-lightbox {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.9);
    z-index: 99999;
    align-items: center;
    justify-content: center;
}
.wbd-lightbox.wbd-lightbox-open { display: flex; }
body.wbd-lightbox-locked { overflow: hidden; }
.wbd-lightbox-img {
    max-width: 90vw;
    max-height: 85vh;
    object-fit: contain;
    border-radius: 4px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.5);
}
.wbd-lightbox-close,
.wbd-lightbox-prev,
.wbd-lightbox-next {
    position: absolute;
    background: rgba(255,255,255,0.12);
    border: none;
    color: #fff;
    cursor: pointer;
    border-radius: 50%;
    width: 44px;
    height: 44px;
    font-size: 24px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s ease;
}
.wbd-lightbox-close:hover,
.wbd-lightbox-prev:hover,
.wbd-lightbox-next:hover { background: rgba(255,255,255,0.25); }
.wbd-lightbox-close { top: 16px; right: 16px; font-size: 28px; }
.wbd-lightbox-prev { left: 16px; top: 50%; transform: translateY(-50%); }
.wbd-lightbox-next { right: 16px; top: 50%; transform: translateY(-50%); }
.wbd-lightbox-counter {
    position: absolute;
    bottom: 18px;
    left: 50%;
    transform: translateX(-50%);
    color: #fff;
    font-size: 13px;
    opacity: 0.85;
}
@media (max-width: 600px) {
    .wbd-lightbox-prev, .wbd-lightbox-next { width: 38px; height: 38px; font-size: 20px; }
}

/* --- BREADCRUMBS --- */
.wbd-breadcrumbs {
    font-size: 0.88em;
    color: #666;
    margin-bottom: 16px;
}
.wbd-breadcrumbs a { color: #2c6e49; text-decoration: none; }
.wbd-breadcrumbs a:hover { text-decoration: underline; }
.wbd-breadcrumb-sep { color: #bbb; margin: 0 4px; }

/* --- INTERNAL LINK BLOCKS --- */
.wbd-browse-places,
.wbd-other-places {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px 8px;
    margin: 14px 0 20px;
    font-size: 0.88em;
}
.wbd-browse-places-label,
.wbd-other-places-label { color: #777; font-weight: 600; margin-right: 4px; }
.wbd-place-pill,
.wbd-other-places a {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 14px;
    background: #f2f2f2;
    color: #333;
    text-decoration: none;
    transition: background 0.15s ease;
}
.wbd-place-pill:hover,
.wbd-other-places a:hover { background: #e5e5e5; }

.wbd-related-restaurants {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}
.wbd-related-restaurants h2 { font-size: 1.2em; margin-bottom: 10px; }
.wbd-related-list { list-style: none; margin: 0 0 10px; padding: 0; }
.wbd-related-list li { margin-bottom: 6px; }
.wbd-related-list a { color: #2c6e49; text-decoration: none; font-weight: 500; }
.wbd-related-list a:hover { text-decoration: underline; }
.wbd-related-viewall { font-weight: 600; color: #2c6e49; text-decoration: none; }
.wbd-related-viewall:hover { text-decoration: underline; }
