/* ═══════════════════════════════════════════════════════════════════
   Breed detail page (.bp-*)
   ═══════════════════════════════════════════════════════════════════ */

.bp {
    max-width: 52rem;
    margin: 0 auto;
    padding: 2rem 1.25rem 4rem;
}

/* ── Breadcrumb ──────────────────── */
.breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    font-size: 0.8rem;
    color: #9ca3af;
    margin-bottom: 1rem;
}
.breadcrumb a,
.breadcrumb span {
    unicode-bidi: isolate;
}
.breadcrumb a {
    color: var(--link);
    text-decoration: none;
}
.breadcrumb a:hover {
    text-decoration: underline;
}
.bc-sep {
    color: #9ca3af;
}

/* ── Hero ─────────────────────────── */
.bp-hero {
    background: var(--surface);
    border-radius: 1rem;
    padding: 1.75rem;
    margin-bottom: 0.75rem;
    position: relative;
    overflow: hidden;
    text-align: center;
}
.bp-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid var(--border);
    border-radius: 1rem;
    pointer-events: none;
}
.bp-site-logo {
    height: 5rem;
    width: auto;
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 1;
}
.bp-site-logo-link {
    display: contents;
}
.bp-avatar {
    width: 17rem;
    height: 17rem;
    border-radius: 50%;
    background: #fff;
    margin: 0 auto 1.25rem;
    border: 3px solid var(--border);
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: center;
}
.bp-avatar img {
    width: 80%;
    max-height: 90%;
    object-fit: contain;
}
.bp-hero-title {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-bright);
    margin: 0 0 0.25rem;
}
.bp-hero-subtitle {
    font-size: 1rem;
    color: #9ca3af;
    margin: 0 0 1.25rem;
}
.bp-hero-rating {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.3rem;
    font-size: 0.9rem;
    margin-bottom: 1rem;
    direction: ltr;
    position: relative;
}
.bp-rating-icon {
    width: 1.4em;
    height: 1.4em;
    flex-shrink: 0;
    border-radius: 2px;
}
.bp-info-btn {
    background: none;
    border: none;
    color: #9ca3af;
    font-size: 0.85rem;
    cursor: pointer;
    padding: 0;
    line-height: 1;
}
.bp-info-btn:hover {
    color: var(--accent);
}
.bp-hero-tooltip {
    display: none;
    position: absolute;
    top: calc(100% + 0.5rem);
    left: 50%;
    transform: translateX(-50%);
    width: max-content;
    max-width: 16rem;
    font-size: 0.75rem;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 0.5rem 0.75rem;
    line-height: 1.45;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    z-index: 10;
}
.bp-hero-tooltip::before {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 6px solid transparent;
    border-bottom-color: var(--border);
}
.bp-hero-tooltip::after {
    content: "";
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-bottom-color: var(--surface);
}
.bp-hero-tooltip.visible {
    display: block;
}

/* ── Quick stats ─────────────────── */
.bp-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr));
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}
.bp-stat {
    background: var(--bg);
    border-radius: 0.75rem;
    padding: 0.75rem;
    text-align: center;
    border: 1px solid var(--border);
}
.bp-stat-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-bright);
}
.bp-stat-label {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 0.15rem;
}

/* ── Ratings ─────────────────────── */
.bp-ratings {
    display: flex;
    gap: 1.4rem;
    justify-content: center;
    flex-wrap: wrap;
    align-items: flex-end;
    margin-bottom: 2rem;
}
.bp-rating-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.3rem;
    width: 2.5rem;
}
.bp-rating-label {
    font-size: 0.72rem;
    color: #9ca3af;
    text-align: center;
    width: 100%;
    overflow-wrap: break-word;
    line-height: 1.25;
    min-height: 2.4em;
    display: flex;
    align-items: flex-start;
    justify-content: center;
}
.bp-trait-bar {
    width: 2rem;
    height: 7rem;
    background: var(--border);
    border-radius: 999px;
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    flex-shrink: 0;
}
.bp-trait-fill {
    width: 100%;
    background: rgba(167, 139, 250, 0.85);
    border-radius: 999px;
    transition: height 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    height: 0;
}
.bp-rating-value {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-bright);
}

/* ── Badges ──────────────────────── */
.bp-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1.25rem;
    justify-content: center;
}
.bp-badge {
    font-size: 0.8rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    font-weight: 600;
}
.bp-badge--yes {
    background: rgba(34, 197, 94, 0.12);
    color: #22c55e;
    border: 1px solid rgba(34, 197, 94, 0.25);
}
.bp-badge--no {
    background: rgba(239, 68, 68, 0.08);
    color: #9ca3af;
    border: 1px solid var(--border);
}

/* ── Sections ────────────────────── */
.bp-section {
    background: var(--surface);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1rem;
    border: 1px solid var(--border);
}

/* ── Gallery ─────────────────────── */
.bp-gallery {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.5rem;
    margin: 1rem 0;
}
.bp-gallery-col {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}
.bp-gallery-col:nth-child(1) img:first-child {
    flex: 3;
}
.bp-gallery-col:nth-child(1) img:last-child {
    flex: 2;
}
.bp-gallery-col:nth-child(2) img:first-child {
    flex: 2;
}
.bp-gallery-col:nth-child(2) img:last-child {
    flex: 3;
}
.bp-gallery-col:nth-child(3) img:first-child {
    flex: 3;
}
.bp-gallery-col:nth-child(3) img:last-child {
    flex: 2;
}
.bp-gallery img {
    width: 100%;
    object-fit: cover;
    border-radius: 0.5rem;
    display: block;
    min-height: 0;
    transition:
        transform 0.3s ease,
        filter 0.3s ease;
}
.bp-gallery img:hover {
    transform: scale(1.03);
    filter: brightness(1.05);
}
@media (max-width: 600px) {
    .bp-gallery {
        grid-template-columns: repeat(2, 1fr);
    }
    .bp-gallery-col:nth-child(3) {
        display: none;
    }
}
.bp-section h2 {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-bright);
    margin: 0 0 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.bp-section-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    font-size: 1rem;
    flex-shrink: 0;
}
.bp-section-icon--food {
    background: rgba(249, 166, 29, 0.12);
}
.bp-section-icon--health {
    background: rgba(239, 68, 68, 0.12);
}
.bp-section-icon--groom {
    background: rgba(99, 102, 241, 0.12);
}
.bp-section-icon--train {
    background: rgba(34, 197, 94, 0.12);
}
.bp-section-icon--faq {
    background: rgba(168, 85, 247, 0.12);
}
#faq {
    margin-top: 1.5rem;
}
.bp-section p {
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--text);
    margin: 0 0 0.5rem;
}
.bp-section ul {
    margin: 0.5rem 0;
    padding-right: 1.5rem;
}
.bp-section li {
    font-size: 0.92rem;
    line-height: 1.7;
    color: var(--text);
    margin-bottom: 0.25rem;
}

/* ── Expert tip ───────────────────── */
.bp-tip {
    background: rgba(249, 166, 29, 0.08);
    border: 1px solid rgba(249, 166, 29, 0.2);
    border-radius: 0.6rem;
    padding: 0.65rem 1rem;
    font-size: 0.85rem;
    color: var(--text);
    line-height: 1.6;
    margin-top: 0.75rem;
}

/* ── Provider take ───────────────── */
.bp-take {
    display: block;
    position: relative;
    background: rgba(167, 139, 250, 0.06);
    border: 1px solid rgba(167, 139, 250, 0.15);
    border-radius: 0.75rem;
    padding: 0.75rem 0.75rem 0.6rem 0.5rem;
    margin-top: 1rem;
    text-decoration: none;
    color: inherit;
    transition:
        border-color 0.2s,
        box-shadow 0.2s;
    cursor: pointer;
}
.bp-take:hover {
    border-color: rgba(167, 139, 250, 0.35);
    box-shadow: 0 2px 8px rgba(167, 139, 250, 0.1);
}
.bp-take::before {
    content: "❝";
    position: absolute;
    top: 0.6rem;
    left: 1rem;
    font-size: 3rem;
    line-height: 1;
    color: rgba(167, 139, 250, 0.12);
    font-family: Georgia, serif;
    pointer-events: none;
}
.bp-take-top {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.75rem;
}
.bp-take-avatar {
    width: 3.1rem;
    height: 3.1rem;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid rgba(167, 139, 250, 0.35);
    flex-shrink: 0;
}
.bp-take-who {
    display: flex;
    flex-direction: column;
    gap: 0.1rem;
    align-self: flex-start;
}
.bp-take-name {
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text);
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}
.bp-take-role {
    font-size: 1rem;
    font-weight: 700;
    color: rgba(167, 139, 250, 0.9);
}
.bp-take-body {
    margin: 0;
    font-size: 0.9rem;
    padding-right: 0.5rem;
    line-height: 1.75;
    color: var(--text);
    font-style: italic;
    white-space: pre-line;
}

/* ── Health cards ─────────────────── */
.bp-health-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(min(140px, 45%), 1fr));
    gap: 0.65rem;
    margin: 0.5rem 0;
}
.bp-health-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    gap: 0.4rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 0.85rem 0.65rem;
    min-height: 80px;
}
.bp-health-icon {
    font-size: 1.4rem;
    flex-shrink: 0;
}
.bp-health-title {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--text-bright);
}
.bp-health-detail {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-top: 0.1rem;
}

/* ── Fun fact ────────────────────── */
.bp-funfact {
    border-top: 1px solid var(--border);
    padding: 1.25rem 0 0.25rem;
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.65;
    margin-top: 1.25rem;
    margin-bottom: 0;
}

/* ── Tables ──────────────────────── */
.bp-feed-table,
.bp-cost-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0.75rem;
    font-size: 0.85rem;
}
.bp-feed-table th,
.bp-cost-table th {
    background: var(--bg);
    color: #9ca3af;
    font-weight: 600;
    text-align: right;
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid var(--border);
}
.bp-feed-table td,
.bp-cost-table td {
    padding: 0.5rem 0.75rem;
    border-bottom: 1px solid var(--border);
    color: var(--text);
}
.bp-cost-low {
    background: rgba(34, 197, 94, 0.06);
}
.bp-cost-mid {
    background: rgba(249, 166, 29, 0.06);
}
.bp-cost-high {
    background: rgba(239, 68, 68, 0.06);
}
.bp-sub-heading {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-bright);
    margin: 1rem 0 0.25rem;
}

/* ── Video ────────────────────────── */
.bp-video-wrap {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    border-radius: 0.75rem;
    overflow: hidden;
}
.bp-video-wrap iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
}
.bp-section-video {
    margin-top: 0.75rem;
}

/* ── Section CTA ──────────────────── */
.bp-section-cta {
    display: block;
    margin: 1rem auto 0;
    padding: 0.6rem 1.4rem;
    border-radius: 0.6rem;
    background: var(--accent, #f9a61d);
    color: #000;
    font-weight: 700;
    font-size: 0.9rem;
    text-decoration: none;
    text-align: center;
    max-width: fit-content;
    transition:
        transform 0.15s,
        box-shadow 0.15s;
    box-shadow: 0 4px 14px rgba(249, 166, 29, 0.3);
}
.bp-section-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(249, 166, 29, 0.4);
}
.bp-hero .bp-section-cta {
    margin-bottom: 1.5rem;
}

/* ── Bottom CTA ──────────────────── */
.bp-bottom-cta {
    display: block;
    background: var(--accent, #f9a61d);
    color: #000;
    font-weight: 700;
    font-size: 1rem;
    padding: 0.75rem 2rem;
    border-radius: 0.6rem;
    text-decoration: none;
    font-family: var(--font);
    text-align: center;
    margin: 1.5rem auto 0;
    max-width: 22rem;
    transition:
        transform 0.15s,
        box-shadow 0.15s;
    box-shadow: 0 4px 14px rgba(249, 166, 29, 0.3);
}
.bp-bottom-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(249, 166, 29, 0.4);
}

/* ── Back to top ─────────────────── */
.bp-back-top {
    display: block;
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.82rem;
    color: #6b7280;
    text-decoration: none;
}
.bp-back-top:hover {
    color: var(--link);
}

/* ── TOC nav ─────────────────────── */
.bp-toc {
    display: flex;
    gap: 0.4rem;
    flex-wrap: wrap;
    justify-content: center;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: 0.75rem 1.25rem 0.4rem;
    margin-bottom: 1.25rem;
}
.bp-toc a {
    font-size: 0.78rem;
    font-weight: 600;
    color: #9ca3af;
    text-decoration: none;
    padding: 0.3rem 0.65rem;
    border-radius: 999px;
    transition:
        background 0.15s,
        color 0.15s;
    white-space: nowrap;
}
.bp-toc a:hover,
.bp-toc a.is-active {
    background: var(--accent, #f9a61d);
    color: #000;
}

/* ── Similar breeds ──────────────── */
.bp-similar {
    margin-top: 1.5rem;
}
.bp-similar h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-bright);
    margin: 0 0 0.75rem;
    text-align: center;
}
.bp-similar-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
    gap: 0.75rem;
}
.bp-similar-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1rem 0.75rem 0;
    transition:
        border-color 0.2s,
        transform 0.15s;
    overflow: hidden;
    text-align: center;
    position: relative;
    min-height: 15.5rem;
}
.bp-similar-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}
.bp-similar-flag {
    position: absolute;
    bottom: 0.5rem;
    left: 0.5rem;
    font-size: 1.4rem;
    line-height: 1;
    z-index: 2;
}
.bp-similar-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 0.1rem;
    min-height: 1.4em;
}
.bp-similar-en {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-bottom: 0.5rem;
    min-height: 1em;
}
.bp-similar-avatar {
    width: 8.4rem;
    height: 8.4rem;
    border-radius: 50%;
    overflow: hidden;
    background: #fff;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    margin: auto auto 0;
    border: 2px solid var(--border);
    position: relative;
    z-index: 1;
    flex-shrink: 0;
}
.bp-similar-avatar img {
    width: 80%;
    max-height: 90%;
    object-fit: contain;
}
.bp-similar-gradient {
    width: calc(100% + 1.5rem);
    height: 2.5rem;
    margin-top: -1.5rem;
    margin-left: -0.75rem;
    margin-right: -0.75rem;
    background: linear-gradient(to bottom, transparent, rgba(249, 166, 29, 0.08));
    border-radius: 0 0 0.75rem 0.75rem;
    flex-shrink: 0;
}

/* ── Pros / Cons ────────────────── */
.bp-proscons {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1rem;
}
.bp-proscons-col {
    background: var(--surface);
    border-radius: 1rem;
    padding: 1.25rem;
    border: 1px solid var(--border);
}
.bp-proscons-col h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-bright);
    margin: 0 0 0.6rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.bp-proscons-col ul {
    margin: 0;
    padding: 0;
    list-style: none;
}
.bp-proscons-col li {
    font-size: 0.88rem;
    line-height: 1.65;
    color: var(--text);
    padding: 0.2rem 0;
    padding-right: 1.1rem;
    position: relative;
}
.bp-proscons-col li::before {
    position: absolute;
    right: 0;
}
.bp-pros li::before {
    content: "✓";
    color: #22c55e;
    font-weight: 700;
}
.bp-cons li::before {
    content: "✗";
    color: #ef4444;
    font-weight: 700;
}
@media (max-width: 600px) {
    .bp-proscons {
        grid-template-columns: 1fr;
    }
}

/* ── Expert attribution ─────────── */
.bp-attribution {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.8rem;
    color: #6b7280;
    margin-top: 1.25rem;
    padding: 0.75rem 1rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
}
.bp-attribution-avatar {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    flex-shrink: 0;
}
.bp-attribution strong {
    color: var(--text-bright);
}

/* ── Sticky mobile CTA ────────────── */
.bp-sticky-cta {
    display: none;
}
@media (max-width: 600px) {
    .bp-sticky-cta {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        z-index: 100;
        background: var(--surface);
        border-top: 1px solid var(--border);
        padding: 0.6rem 1rem;
        justify-content: center;
        gap: 0.5rem;
        backdrop-filter: blur(8px);
        -webkit-backdrop-filter: blur(8px);
    }
    .bp-sticky-cta a {
        flex: 1;
        text-align: center;
        font-size: 0.85rem;
        font-weight: 700;
        padding: 0.55rem 0.5rem;
        border-radius: 0.5rem;
        text-decoration: none;
        font-family: var(--font);
    }
    .bp-sticky-primary {
        background: var(--accent, #f9a61d);
        color: #000;
    }
    .bp-sticky-secondary {
        background: transparent;
        border: 1px solid var(--border);
        color: var(--text-bright);
    }
    .bp {
        padding-bottom: 5rem;
    }
}

/* ── Print styles ────────────────── */
@media print {
    .bp-toc,
    .bp-sticky-cta,
    .bp-bottom-cta,
    .bp-section-cta,
    .share-panel,
    .bp-back-top,
    .bp-site-logo-link {
        display: none !important;
    }
    .bp-section {
        break-inside: avoid;
        border: none;
        box-shadow: none;
    }
    .bp {
        padding: 0;
        max-width: 100%;
    }
    .bp-hero {
        border: none;
    }
}

/* ── Footer ──────────────────────── */
.bp-footer {
    text-align: center;
    margin-top: 2rem;
    font-size: 0.82rem;
    color: #6b7280;
}
.bp-footer a {
    color: var(--link);
    text-decoration: none;
}

/* ── Mobile ───────────────────────── */
@media (max-width: 600px) {
    .bp-site-logo-link {
        display: block;
    }
    .bp-site-logo {
        position: static;
        height: 6rem;
        margin-bottom: 0.5rem;
    }
    .bp-avatar {
        width: 12rem;
        height: 12rem;
    }
    .bp-hero {
        padding: 1.25rem 1rem;
    }
    .bp-stats {
        grid-template-columns: 1fr 1fr;
    }
}

/* ═══════════════════════════════════════════════════════════════════
   Breed directory page (.bd-*)
   ═══════════════════════════════════════════════════════════════════ */

.bd {
    max-width: 60rem;
    margin: 0 auto;
    padding: 2rem 1.25rem 4rem;
}

/* ── Hero ─────────────────────────── */
.bd-hero {
    background: var(--surface);
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.bd-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    border: 1px solid var(--border);
    border-radius: 1rem;
    pointer-events: none;
}
.bd-site-logo {
    height: 5rem;
    width: auto;
    position: absolute;
    top: 1rem;
    left: 1rem;
    z-index: 1;
}
.bd-site-logo-link {
    display: contents;
}
.bd-hero h1 {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-bright);
    margin: 0 0 0.5rem;
}
.bd-hero p {
    font-size: 0.92rem;
    color: #9ca3af;
    margin: 0 0 1rem;
    max-width: 36rem;
    margin-left: auto;
    margin-right: auto;
}
.bd-hero-cta {
    display: inline-block;
    background: var(--accent, #f9a61d);
    color: #000;
    font-weight: 700;
    font-size: 0.95rem;
    padding: 0.6rem 1.8rem;
    border-radius: 0.6rem;
    text-decoration: none;
    font-family: var(--font);
    transition:
        transform 0.15s,
        box-shadow 0.15s;
    box-shadow: 0 4px 14px rgba(249, 166, 29, 0.3);
}
.bd-hero-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(249, 166, 29, 0.4);
}

/* ── Grid ─────────────────────────── */
.bd-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
    gap: 0.75rem;
}
.bd-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    background: var(--surface);
    border-radius: 0.75rem;
    padding: 1rem 0.75rem 0;
    border: 1px solid var(--border);
    text-decoration: none;
    transition:
        border-color 0.2s,
        transform 0.15s;
    overflow: hidden;
    text-align: center;
    position: relative;
    min-height: 17rem;
}
.bd-card:hover {
    border-color: var(--accent);
    transform: translateY(-2px);
}
.bd-card-name {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text-bright);
    margin-bottom: 0.1rem;
    min-height: 1.4em;
}
.bd-card-en {
    font-size: 0.75rem;
    color: #9ca3af;
    margin-bottom: 0.5rem;
    min-height: 1em;
}
.bd-card-rating {
    display: flex;
    align-items: center;
    gap: 0.2rem;
    font-size: 0.75rem;
    margin-bottom: 0.35rem;
    direction: ltr;
}
.bd-card-rating-icon {
    width: 1.3em;
    height: 1.3em;
    flex-shrink: 0;
    border-radius: 2px;
}
.bd-card-rating-value {
    font-weight: 600;
    color: var(--text-bright);
}
.bd-avatar {
    width: 10rem;
    height: 10rem;
    border-radius: 50%;
    background: #fff;
    margin: auto auto 0;
    border: 2px solid var(--border);
    overflow: hidden;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    position: relative;
    z-index: 1;
    flex-shrink: 0;
}
.bd-avatar img {
    width: 80%;
    max-height: 90%;
    object-fit: contain;
}
.bd-card-gradient {
    width: calc(100% + 1.5rem);
    height: 2.5rem;
    margin-top: -1.5rem;
    margin-left: -0.75rem;
    margin-right: -0.75rem;
    background: linear-gradient(to bottom, transparent, rgba(249, 166, 29, 0.08));
    border-radius: 0 0 0.75rem 0.75rem;
    flex-shrink: 0;
}

/* ── Card flag ───────────────────── */
.bd-card-flag {
    position: absolute;
    bottom: 0.5rem;
    left: 0.5rem;
    font-size: 1.4rem;
    line-height: 1;
    z-index: 2;
}

/* ── Filters ─────────────────────── */
.bd-filter {
    background: var(--surface);
    border-radius: 1rem;
    padding: 1.25rem;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
    border: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    text-align: right;
}
.bd-filter-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.35rem;
}
.bd-filter-title {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-bright);
    margin: 0;
}
.bd-filter-count {
    font-size: 0.82rem;
    color: #9ca3af;
}
.bd-filter-search {
    width: 100%;
    box-sizing: border-box;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-bright);
    font-size: 0.85rem;
    padding: 0.5rem 1rem;
    border-radius: 999px;
    font-family: var(--font);
    outline: none;
    transition: border-color 0.15s;
}
.bd-filter-search:focus {
    border-color: var(--accent);
}
.bd-filter-search::placeholder {
    color: #6b7280;
}
.bd-filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    width: 100%;
    margin-top: 0.65rem;
}
.bd-filter-label {
    display: block;
    font-size: 0.82rem;
    color: #9ca3af;
    font-weight: 600;
}
.bd-filter-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}
.bd-filter-pill {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-bright);
    font-size: 0.8rem;
    padding: 0.3rem 0.85rem;
    border-radius: 999px;
    cursor: pointer;
    font-family: var(--font);
    transition:
        background 0.15s,
        border-color 0.15s,
        color 0.15s;
}
.bd-filter-pill:hover {
    border-color: var(--accent);
}
.bd-filter-pill.is-active {
    background: var(--accent, #f9a61d);
    color: #000;
    font-weight: 700;
    border-color: var(--accent, #f9a61d);
}
.bd-filter-footer {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-top: 0.25rem;
}
.bd-filter-advanced {
    display: none;
    flex-direction: column;
    gap: 0.6rem;
    width: 100%;
}
.bd-filter-advanced.is-open {
    display: flex;
}
.bd-filter-toggle {
    background: transparent;
    border: 1px solid var(--border);
    color: var(--accent, #f9a61d);
    font-size: 0.82rem;
    font-weight: 600;
    padding: 0.35rem 1rem;
    border-radius: 999px;
    cursor: pointer;
    font-family: var(--font);
    transition:
        background 0.15s,
        border-color 0.15s;
}
.bd-filter-toggle:hover {
    border-color: var(--accent);
    background: rgba(249, 166, 29, 0.08);
}
.bd-empty {
    text-align: center;
    padding: 3rem 1rem;
    color: #9ca3af;
    font-size: 0.95rem;
    display: none;
}

/* ── Adoption CTA ────────────────── */
.bd-adoption-cta {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0.75rem;
    padding: 1rem 1.25rem;
    margin-top: 1.25rem;
}
.bd-adoption-emoji {
    font-size: 1.6rem;
    flex-shrink: 0;
}
.bd-adoption-text {
    font-size: 0.88rem;
    color: #9ca3af;
    flex: 1;
}
.bd-adoption-text strong {
    color: var(--text-bright);
}
.bd-adoption-link {
    white-space: nowrap;
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--accent, #f9a61d);
    text-decoration: none;
    transition: opacity 0.15s;
}
.bd-adoption-link:hover {
    opacity: 0.8;
}

/* ── Bottom CTA ──────────────────── */
.bd-bottom-cta {
    display: block;
    background: var(--accent, #f9a61d);
    color: #000;
    font-weight: 700;
    font-size: 1rem;
    padding: 0.75rem 2rem;
    border-radius: 0.6rem;
    text-decoration: none;
    font-family: var(--font);
    text-align: center;
    margin: 1.5rem auto 0;
    max-width: 22rem;
    transition:
        transform 0.15s,
        box-shadow 0.15s;
    box-shadow: 0 4px 14px rgba(249, 166, 29, 0.3);
}
.bd-bottom-cta:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(249, 166, 29, 0.4);
}

/* ── Footer ──────────────────────── */
.bd-footer {
    text-align: center;
    margin-top: 2rem;
    font-size: 0.82rem;
    color: #6b7280;
}
.bd-footer a {
    color: var(--link);
    text-decoration: none;
}

/* ── Mobile ───────────────────────── */
@media (max-width: 600px) {
    .bd-site-logo-link {
        display: block;
    }
    .bd-site-logo {
        position: static;
        height: 6rem;
        margin-bottom: 0.5rem;
    }
    .bd-hero {
        padding: 1.25rem 1rem;
    }
    .bd-grid {
        grid-template-columns: repeat(auto-fill, minmax(9rem, 1fr));
    }
    .bd-avatar {
        width: 8rem;
        height: 8rem;
    }
    .bd-filter {
        padding-top: 0.75rem;
        gap: 0.5rem;
    }
}

/* ═══════════════════════════════════════════════════════════════════
   Shared component styles (imported)
   ═══════════════════════════════════════════════════════════════════ */

/* ── Related articles ────────────── */
.bp-related-articles { margin-top: 1rem; }
.bp-related-header { display: flex; align-items: center; justify-content: space-between; margin: 0 0 0.5rem; }
.bp-related-header h3 { font-size: 1.1rem; font-weight: 600; color: var(--text-bright); margin: 0; }
.bp-related-see-all { color: var(--accent); font-size: 0.85rem; font-weight: 700; text-decoration: none; white-space: nowrap; transition: opacity 0.2s; }
.bp-related-see-all:hover { opacity: 0.8; }
.bp-related-row { display: grid; grid-template-columns: repeat(2, 1fr); grid-auto-rows: 9rem; gap: 0.65rem; }
.bp-related-card { position: relative; border-radius: 0.75rem; overflow: hidden; cursor: pointer; text-decoration: none; border: 1px solid #374151; }
.bp-related-card:first-child { grid-row: span 2; }
.bp-related-card > img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.7s ease; }
.bp-related-card:hover > img { transform: scale(1.09); }
.bp-related-overlay { position: absolute; bottom: 0; left: 0; right: 0; padding: 2.5rem 0.75rem 0.6rem; background: linear-gradient(to top, rgba(0,0,0,1) 0%, rgba(0,0,0,0.85) 40%, rgba(0,0,0,0.5) 65%, rgba(0,0,0,0.15) 80%, transparent 100%); }
.bp-related-title { font-size: 0.82rem; font-weight: 700; color: #f9fafb; line-height: 1.45; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.bp-related-card:first-child .bp-related-title { font-size: 1rem; font-weight: 800; -webkit-line-clamp: 3; }
@media (max-width: 600px) {
    .bp-related-row { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 8rem; }
    .bp-related-card:first-child { grid-column: span 2; grid-row: span 1; }
}
.bp-related-card .bc-reviewer { margin-bottom: 0; margin-top: 0.3rem; }
.bp-related-card .bc-reviewer-pic { width: 18px !important; height: 18px !important; max-width: 18px; max-height: 18px; min-width: 18px; min-height: 18px; border-radius: 50%; object-fit: cover; border: 1.5px solid var(--accent); margin-left: 0.3rem; flex-shrink: 0; }
.bc-reviewer { display: flex; align-items: center; flex-wrap: wrap; row-gap: 0.15rem; column-gap: 0; margin-bottom: 0.4rem; margin-top: 0.5rem; font-size: 0.78rem; color: #9ca3af; line-height: 1.4; }
.bc-reviewer-pic { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; border: 1.5px solid var(--accent); margin-left: 0.3rem; }
.bc-reviewer-label { color: var(--accent); font-weight: 700; margin-left: 0.25rem; }
.bc-reviewer-name { font-weight: 700; color: var(--text); }
.bc-reviewer-title { font-weight: bold; }

.show-more-btn { display: block; width: fit-content; margin: 1.25rem auto 0; background: var(--surface); border: 1.5px solid var(--border); color: var(--accent, #f9a61d); font-weight: 700; font-size: 0.9rem; padding: 0.6rem 2rem; border-radius: 0.6rem; cursor: pointer; font-family: var(--font); transition: background 0.2s, border-color 0.2s, transform 0.15s, box-shadow 0.15s; box-shadow: 0 2px 8px rgba(0,0,0,0.06); }
.show-more-btn:hover { border-color: var(--accent); background: rgba(249,166,29,0.06); transform: translateY(-1px); box-shadow: 0 4px 14px rgba(249,166,29,0.15); }
.show-more-btn:active { transform: translateY(0); }

/* ── Menu toggle button (matches .menu-icon-btn from React) ── */
.menu-toggle {
    background: transparent;
    border: none;
    border-radius: 50%;
    padding: 0;
    cursor: pointer;
    color: #f9fafb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: clamp(14px, 3.5vw, 16px);
    width: 2.34em;
    height: 2.34em;
    -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
    .menu-toggle:hover { background: #222325; }
}
.menu-toggle:active { background: #292c31; }
.menu-toggle-bars {
    display: flex;
    flex-direction: column;
    gap: 0.4em;
}
.menu-toggle .bar {
    width: 1.25em;
    height: 0.125em;
    background-color: #f9fafb;
    border-radius: 1px;
}

/* ── Side menu panel ───────────────── */
/* em units used inside panel so sizes are relative to this
   element's font-size (matching React's rem-based layout). */
.side-menu {
    position: fixed;
    top: 0;
    right: -21em;
    width: 21em;
    height: 100dvh;
    background-color: #1f2937;
    box-shadow: -2px 0 10px rgba(0, 0, 0, 0.3);
    transition: right 0.3s ease-in-out;
    z-index: 1100;
    display: flex;
    flex-direction: column;
    padding: 1em 1.25em 0;
    font-size: clamp(14px, 3.5vw, 16px);
    line-height: normal;
    direction: ltr;
}
.side-menu.open { right: 0; }

.side-menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #374151;
    padding-bottom: 0.375em;
}
.side-menu-title {
    margin: 0;
    text-align: right;
    font-weight: 800;
    color: #f9fafb;
    font-size: 1.25em;
}
.menu-close-btn {
    background: transparent;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    -webkit-tap-highlight-color: transparent;
}
@media (hover: hover) {
    .menu-close-btn:hover { background: #374151; }
}
.menu-close-btn:active { background: #292c31; }

.side-menu-body {
    display: flex;
    flex-direction: column;
    gap: 0;
    margin-top: 0.5em;
    flex: 1;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
.side-menu-body::-webkit-scrollbar { display: none; }

.side-menu-item {
    background: none;
    border: none;
    padding: 0.57em 0.715em;
    text-align: right;
    cursor: pointer;
    border-radius: 8px;
    font-size: 1.05em;
    font-weight: 700;
    transition: background-color 0.2s ease;
    color: #f9a61d;
    text-decoration: none;
    display: block;
    font-family: inherit;
}
.side-menu-item:hover { background-color: #374151; }

.side-menu-divider {
    border-top: 1px solid #374151;
    margin: 0.667em 0.715em 0;
    width: 50%;
    align-self: flex-end;
}
.side-menu-section-title {
    font-size: 1.05em;
    font-weight: 700;
    color: #d1d5db;
    padding: 0.475em 0.715em 0.285em;
    margin-top: 0.38em;
    text-align: right;
    letter-spacing: 0.03em;
}

.side-menu-footer {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.15em;
    padding: 0.5em 0.75em;
    border-top: 1px solid #374151;
}
.side-menu-footer-row {
    display: flex;
    align-items: center;
    gap: 0.4em;
}
.side-menu-footer-item {
    background: none;
    border: none;
    padding: 0.2em 0;
    cursor: pointer;
    font-size: 0.95em;
    font-weight: 400;
    transition: color 0.2s ease;
    color: #9ca3af;
    text-decoration: none;
    font-family: inherit;
}
.side-menu-footer-item:hover { color: #f9fafb; }
.side-menu-footer-sep { color: #4b5563; }

.side-menu-promo {
    display: block;
    margin: 0.5em 0.715em;
    padding: 0.6em 0.715em;
    background: rgba(167,139,250,0.08);
    border: 1px dashed rgba(167,139,250,0.5);
    border-radius: 8px;
    font-size: 0.9em;
    color: #d1d5db;
    text-align: center;
    text-decoration: none;
}
.side-menu-promo span { color: #f9a61d; font-weight: 700; }
.side-menu-promo:hover { background: rgba(167,139,250,0.14); }

/* ── Overlay ───────────────────────── */
.side-menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100dvh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    display: none;
}
.side-menu-overlay.open { display: block; }

/* ── Toolbar ──────────────────────── */
.toolbar {
    margin-top: -1.2rem;
    margin-bottom: 0;
    margin-right: -0.1em;
    display: flex;
    flex-direction: column;
    padding-bottom: 1rem;
}
.toolbar-row {
    display: flex;
    align-items: center;
    gap: 0.375rem;
}
.toolbar .breadcrumb {
    display: block;
    font-size: 0.8rem;
    color: #9ca3af;
    margin: 0;
    min-width: 0;
    flex: 1;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}
.toolbar .breadcrumb a, .toolbar .breadcrumb span { unicode-bidi: isolate; }
.toolbar .breadcrumb a { color: var(--link); text-decoration: none; }
.toolbar .breadcrumb a:hover { text-decoration: underline; }
.toolbar .breadcrumb .bc-sep { color: #9ca3af; margin: 0 0.2rem; }
.hero-updated {
    display: block;
    font-size: 0.75rem;
    color: #a1aabd;
    background: rgba(107,114,128,0.1);
    padding: 0.15rem 0.55rem;
    border-radius: 0.3rem;
    white-space: nowrap;
    text-align: end;
    margin-top: 0;
    width: fit-content;
    align-self: flex-end;
}

.star-rating { display: inline-flex; align-items: center; direction: ltr; }
.star-rating svg { width: 1em; height: 1em; }
.star-rating-lg svg { width: 1.1em; height: 1.1em; }
.star-rating-sm svg { width: 0.9em; height: 0.9em; }

