/* ─────────────────────────────────────────────────────────────────────────
 * The public blog — listings, cards, the article page and its chrome.
 * Built on the site design system (partials/site/styles: tokens, .container,
 * .btn, .kicker, .eyebrow, .crumbs, .cta-band, .reveal). Article typography
 * itself lives in article.css.
 * ───────────────────────────────────────────────────────────────────────── */

.blog { --radius: 22px; --radius-sm: 14px; }
/* `hidden` must win over the display values below (the dock, share buttons). */
.blog [hidden] { display: none !important; }
/* Icons inside flex rows keep their size (the site's svg max-width would let them collapse). */
.blog :is(.b-pill, .b-badge, .b-text-link, .b-pager-step, .b-views, .b-side-title, .b-tag, .b-dock-btn, .b-read-link, .b-rss, .b-prevnext-label, .b-toc-mobile summary, .b-preview-banner, .b-faq-item summary, .b-code-copy) svg { flex: none; }

/* ── Hero ──────────────────────────────────────────────────────────────── */
.b-hero {
    position: relative; isolation: isolate; overflow: hidden;
    padding: 148px 0 64px;
    background:
        radial-gradient(70% 60% at 85% 0%, color-mix(in srgb, var(--gold-2) 16%, transparent), transparent 70%),
        linear-gradient(180deg, var(--bg-soft) 0%, var(--bg) 100%);
}
.b-hero-glow {
    position: absolute; z-index: -1; left: -200px; top: -220px; width: 680px; height: 680px; border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 214, 120, 0.42), transparent 62%);
    pointer-events: none;
}
[data-theme="dark"] .b-hero-glow { background: radial-gradient(circle, rgba(251, 192, 45, 0.16), transparent 62%); }
.b-hero-grid {
    position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: 0.55;
    background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(70% 70% at 60% 20%, #000 0%, transparent 75%);
    -webkit-mask-image: radial-gradient(70% 70% at 60% 20%, #000 0%, transparent 75%);
}
.b-hero-inner { position: relative; max-width: 880px; }
.b-hero-inner--center { margin: 0 auto; text-align: center; display: flex; flex-direction: column; align-items: center; }
.b-hero-title {
    margin: 22px 0 16px;
    font-size: clamp(38px, 5.2vw, 68px); font-weight: 800; line-height: 1.04; letter-spacing: -0.035em;
}
.b-hero-page { color: var(--muted); font-weight: 700; }
.b-hero-lead { max-width: 660px; font-size: clamp(17px, 1.3vw, 19.5px); line-height: 1.6; color: var(--muted); }
[data-theme="light"] .b-hero-lead { color: #3E475C; }
.b-hero-count { margin-top: 18px; font-weight: 600; color: var(--muted); }
.b-hero .crumbs { margin-bottom: 18px; }
.b-hero--archive, .b-hero--search, .b-hero--missing { padding-bottom: 54px; }
.b-missing-code {
    font: 800 clamp(80px, 14vw, 150px)/1 'Plus Jakarta Sans', sans-serif; letter-spacing: -0.06em;
    background: linear-gradient(92deg, #F39A0E, #FBB829 55%, #F5A623); -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* Author archive head */
.b-profile { display: flex; align-items: center; gap: 22px; margin: 6px 0 14px; }
.b-profile .kicker { margin-bottom: 4px; }
.b-profile .b-hero-title { margin: 0; }
.b-profile-role { margin-top: 8px; font-weight: 600; color: var(--muted); }

/* ── Search ────────────────────────────────────────────────────────────── */
.b-search {
    position: relative; display: flex; align-items: center;
    max-width: 640px; height: 62px; margin-top: 30px;
    border-radius: 999px; background: var(--surface);
    border: 1px solid var(--line-2); box-shadow: var(--shadow-md);
    transition: border-color 0.2s ease, box-shadow 0.25s ease;
}
.b-search:focus-within { border-color: var(--gold-2); box-shadow: var(--shadow-md), 0 0 0 4px color-mix(in srgb, var(--gold-2) 22%, transparent); }
.b-hero-inner--center .b-search { width: 100%; }
.b-search-icon { position: absolute; left: 22px; width: 20px; height: 20px; color: var(--dim); pointer-events: none; }
.b-search-input {
    flex: 1; min-width: 0; height: 100%; padding: 0 12px 0 54px; border: 0; outline: 0;
    background: transparent; color: var(--ink); font: 500 16.5px 'Inter', sans-serif;
}
.b-search-input::placeholder { color: var(--dim); }
.b-search-input::-webkit-search-cancel-button { -webkit-appearance: none; }
.b-search-kbd {
    margin-right: 8px; padding: 3px 9px; border-radius: 7px;
    border: 1px solid var(--line-2); color: var(--dim); font: 600 12.5px 'JetBrains Mono', monospace;
}
.b-search:focus-within .b-search-kbd { display: none; }
.b-search-go {
    flex: none; width: 48px; height: 48px; margin-right: 7px; border: 0; border-radius: 50%;
    display: grid; place-items: center; background: var(--btn); color: var(--on-btn); box-shadow: var(--shadow-gold);
    transition: transform 0.2s ease;
}
.b-search-go:hover { transform: scale(1.05); }
.b-search-go svg { width: 18px; height: 18px; }

.b-suggest {
    position: absolute; z-index: 30; top: calc(100% + 10px); left: 0; right: 0;
    padding: 8px; border-radius: 20px; background: var(--surface);
    border: 1px solid var(--line-2); box-shadow: var(--shadow-lg);
    text-align: left; max-height: min(70vh, 460px); overflow-y: auto;
}
.b-suggest-item {
    display: flex; align-items: center; gap: 12px; padding: 9px 10px; border-radius: 14px;
    color: var(--text); cursor: pointer;
}
.b-suggest-item[aria-selected="true"], .b-suggest-item:hover { background: var(--surface-2); }
.b-suggest-thumb { flex: none; width: 54px; height: 40px; border-radius: 10px; object-fit: cover; background: var(--surface-2); }
.b-suggest-title { display: block; font-weight: 700; color: var(--ink); font-size: 15px; line-height: 1.35; }
.b-suggest-meta { display: block; font-size: 13px; color: var(--muted); }
.b-suggest-all { justify-content: center; font-weight: 700; color: var(--gold-ink); border-top: 1px solid var(--line); border-radius: 0 0 14px 14px; margin-top: 4px; }
.b-suggest-empty { padding: 14px; color: var(--muted); font-size: 14.5px; }

/* ── Chips ─────────────────────────────────────────────────────────────── */
.b-chips {
    display: flex; gap: 8px; margin-top: 24px; padding: 4px 2px 8px;
    overflow-x: auto; scroll-snap-type: x proximity; scrollbar-width: none;
}
.b-chips::-webkit-scrollbar { display: none; }
.b-chip {
    position: relative; z-index: 2;
    display: inline-flex; align-items: center; gap: 8px; flex: none;
    height: 30px; padding: 0 12px; border-radius: 999px;
    background: var(--gold-soft); color: var(--label);
    font-size: 13px; font-weight: 700; letter-spacing: 0.01em; white-space: nowrap;
    transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.b-chip:hover { transform: translateY(-1px); background: color-mix(in srgb, var(--gold-2) 30%, var(--gold-soft)); }
.b-chip--filter {
    height: 40px; padding: 0 16px; scroll-snap-align: start;
    background: var(--surface); color: var(--text); border: 1px solid var(--line-2); box-shadow: var(--shadow-xs);
    font-size: 14.5px;
}
.b-chip--filter[aria-current="page"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.b-chip-count { font-size: 12px; font-weight: 700; color: var(--dim); }
.b-chip--filter[aria-current="page"] .b-chip-count { color: color-mix(in srgb, var(--bg) 70%, transparent); }
.b-chip--float {
    position: absolute; left: 14px; top: 14px;
    background: color-mix(in srgb, var(--surface) 88%, transparent); color: var(--ink);
    -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
    box-shadow: var(--shadow-sm);
}
.b-pill {
    display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 999px;
    background: var(--surface); border: 1px solid var(--line-2); color: var(--muted); font-size: 13px; font-weight: 600;
}
.b-pill svg { width: 15px; height: 15px; }
.b-badge {
    display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 999px;
    background: linear-gradient(90deg, #FFE7A8, #FFD27A); color: #7A430B; font-size: 13px; font-weight: 800;
}
[data-theme="dark"] .b-badge { background: rgba(251, 192, 45, 0.16); color: #FFD889; }
.b-badge svg { width: 15px; height: 15px; }

/* ── Sections ──────────────────────────────────────────────────────────── */
.b-section { padding: 56px 0 96px; }
.b-section--tight { padding: 20px 0 24px; }
.b-section-head { margin-bottom: 28px; }
.b-section-head .kicker { margin-bottom: 8px; }
.b-section-head--row { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; }
.b-section-title { font-size: clamp(26px, 2.6vw, 36px); font-weight: 800; letter-spacing: -0.025em; }
.b-count { font-weight: 700; color: var(--muted); white-space: nowrap; }
.b-muted { color: var(--muted); }
.b-text-link { display: inline-flex; align-items: center; gap: 8px; margin-top: 20px; font-weight: 700; color: var(--gold-ink); }
.b-text-link svg { width: 16px; height: 16px; transition: transform 0.2s ease; }
.b-text-link:hover svg { transform: translateX(3px); }

.b-with-side { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.b-main { min-width: 0; }

.b-grid { display: grid; gap: 28px; }
.b-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.b-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }

/* ── Picture with placeholder ──────────────────────────────────────────── */
.b-pic {
    position: relative; display: block; overflow: hidden;
    background: var(--ph, var(--surface-2));
    background-image: var(--lqip, none); background-size: cover; background-position: center;
}
.b-pic img { position: relative; width: 100%; height: 100%; object-fit: cover; transition: transform 0.8s cubic-bezier(.2,.7,.2,1), opacity 0.4s ease; }
.b-pic--blank {
    display: grid; place-items: center;
    background: radial-gradient(80% 80% at 30% 20%, #FFE9B8, transparent 60%), linear-gradient(135deg, var(--gold-soft), var(--surface-2));
}
.b-pic--blank svg { width: 42px; height: 42px; color: var(--gold); opacity: 0.8; }

/* ── Cards ─────────────────────────────────────────────────────────────── */
.b-card {
    position: relative; display: flex; flex-direction: column;
    border-radius: var(--radius); background: var(--surface);
    border: 1px solid var(--line); box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: transform 0.35s cubic-bezier(.2,.7,.2,1), box-shadow 0.35s ease, border-color 0.35s ease;
}
.b-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: color-mix(in srgb, var(--gold-2) 50%, var(--line)); }
.b-card:hover .b-pic img { transform: scale(1.05); }
.b-card:focus-within { border-color: var(--gold-2); }
.b-card-media { position: relative; aspect-ratio: 16 / 10; }
.b-card-media .b-pic { position: absolute; inset: 0; }
.b-card-body { display: flex; flex: 1; flex-direction: column; gap: 12px; padding: 22px 22px 20px; }
.b-card-title { font-size: 20px; font-weight: 800; line-height: 1.3; letter-spacing: -0.015em; }
.b-card-title a { color: var(--ink); }
.b-card:hover .b-card-title a { color: var(--gold-ink); }
.b-card-excerpt {
    color: var(--muted); font-size: 15.5px; line-height: 1.6;
    display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.b-card .b-byline { margin-top: auto; padding-top: 6px; }
.b-card--compact .b-card-title { font-size: 17px; }
.b-card--compact .b-card-body { padding: 16px 18px; }

/* The title link covers the whole card; inner links sit above it. */
.b-stretched::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.b-stretched:focus-visible { outline: none; }
.b-stretched:focus-visible::after { outline: 3px solid var(--gold-2); outline-offset: -3px; border-radius: var(--radius); }

/* ── Byline ────────────────────────────────────────────────────────────── */
.b-byline { display: flex; align-items: center; gap: 10px; min-width: 0; }
.b-byline-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.35; }
.b-byline-name { font-weight: 700; font-size: 14.5px; color: var(--ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.b-byline-meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: 13.5px; color: var(--muted); }
.b-avatar {
    flex: none; width: 38px; height: 38px; border-radius: 50%; overflow: hidden;
    display: grid; place-items: center;
    background: linear-gradient(135deg, #FFD966, #F5A623); color: #0E1A33;
    font: 800 14px/1 'Inter', sans-serif;
    box-shadow: 0 0 0 3px var(--surface);
}
.b-avatar img { width: 100%; height: 100%; object-fit: cover; }
.b-avatar--lg { width: 88px; height: 88px; font-size: 28px; }
.b-avatar--xl { width: 120px; height: 120px; font-size: 38px; box-shadow: 0 0 0 5px var(--surface), var(--shadow-md); }

/* ── Lead story ────────────────────────────────────────────────────────── */
.b-lead {
    position: relative; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    border-radius: 30px; overflow: hidden; background: var(--surface);
    border: 1px solid var(--line); box-shadow: var(--shadow-md);
    transition: box-shadow 0.4s ease, transform 0.4s cubic-bezier(.2,.7,.2,1);
}
.b-lead:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); }
.b-lead:hover .b-pic img { transform: scale(1.04); }
.b-lead-media { position: relative; min-height: 420px; }
.b-lead-media .b-pic { position: absolute; inset: 0; }
.b-lead-body { display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 48px 46px; }
.b-lead-kicker { display: flex; flex-wrap: wrap; gap: 8px; }
.b-lead-title { font-size: clamp(28px, 2.7vw, 40px); font-weight: 800; line-height: 1.12; letter-spacing: -0.03em; }
.b-lead-title a { color: var(--ink); }
.b-lead-excerpt { color: var(--muted); font-size: 17px; line-height: 1.65; }
.b-lead-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 6px; }
.b-read-link { display: inline-flex; align-items: center; gap: 8px; font-weight: 800; color: var(--gold-ink); white-space: nowrap; }
.b-read-link svg { width: 18px; height: 18px; transition: transform 0.25s ease; }
.b-lead:hover .b-read-link svg { transform: translateX(4px); }
.b-picks { margin-top: 64px; }

/* ── Sidebar ───────────────────────────────────────────────────────────── */
.b-side { position: sticky; top: 104px; display: grid; gap: 20px; }
.b-side-card { padding: 24px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.b-side-title { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; font-size: 17px; font-weight: 800; }
.b-side-title svg { width: 19px; height: 19px; color: var(--gold); }
.b-popular { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; counter-reset: pop; }
.b-popular-item { display: flex; gap: 14px; padding: 10px 0; border-top: 1px solid var(--line); }
.b-popular-item:first-child { border-top: 0; padding-top: 0; }
.b-popular-rank { flex: none; width: 30px; font: 800 22px/1.1 'Plus Jakarta Sans', sans-serif; color: color-mix(in srgb, var(--gold) 70%, transparent); }
.b-popular-link { display: block; font-weight: 700; font-size: 15px; line-height: 1.4; color: var(--ink); }
.b-popular-link:hover { color: var(--gold-ink); }
.b-popular-meta { font-size: 13px; color: var(--muted); }
.b-topics { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; }
.b-topics a { display: flex; justify-content: space-between; gap: 12px; padding: 9px 12px; border-radius: 12px; font-weight: 600; color: var(--text); }
.b-topics a:hover { background: var(--surface-2); color: var(--ink); }
.b-topics-count { min-width: 28px; height: 24px; padding: 0 8px; border-radius: 999px; display: grid; place-items: center; background: var(--surface-2); font-size: 12.5px; font-weight: 700; color: var(--muted); }
.b-side-cta { position: relative; overflow: hidden; background: radial-gradient(80% 80% at 100% 0%, rgba(255, 255, 255, 0.7), transparent 60%), linear-gradient(135deg, #FFF3DC, #FDE6C4); border-color: transparent; }
[data-theme="dark"] .b-side-cta { background: radial-gradient(80% 80% at 100% 0%, rgba(251, 192, 45, 0.14), transparent 60%), linear-gradient(135deg, #131C33, #1A2541); }
.b-side-cta-icon { display: grid; place-items: center; width: 46px; height: 46px; border-radius: 14px; background: var(--surface); box-shadow: var(--shadow-sm); color: var(--gold); margin-bottom: 14px; }
.b-side-cta-icon svg { width: 22px; height: 22px; }
.b-side-cta-title { font-size: 20px; font-weight: 800; margin-bottom: 8px; }
.b-side-cta p { color: var(--muted); font-size: 15px; margin-bottom: 18px; }
.b-rss { display: inline-flex; align-items: center; gap: 8px; padding: 0 6px; font-weight: 700; font-size: 14px; color: var(--muted); }
.b-rss:hover { color: var(--gold-ink); }
.b-rss svg { width: 16px; height: 16px; }

/* ── Pagination ────────────────────────────────────────────────────────── */
.b-pager { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 48px; }
.b-pager-pages { list-style: none; display: flex; gap: 6px; margin: 0; padding: 0; }
.b-pager-num, .b-pager-gap {
    display: grid; place-items: center; min-width: 44px; height: 44px; padding: 0 10px; border-radius: 14px;
    font-weight: 700; color: var(--text);
}
a.b-pager-num { border: 1px solid var(--line-2); background: var(--surface); transition: border-color 0.2s, transform 0.2s; }
a.b-pager-num:hover { border-color: var(--gold-2); transform: translateY(-1px); }
.b-pager-num.is-current { background: var(--ink); color: var(--bg); }
.b-pager-gap { color: var(--dim); }
.b-pager-step { display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 16px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--surface); font-weight: 700; color: var(--ink); }
.b-pager-step svg { width: 16px; height: 16px; }
.b-pager-step.is-disabled { opacity: 0.4; }

/* ── Empty states ──────────────────────────────────────────────────────── */
.b-empty { max-width: 560px; margin: 0 auto; padding: 56px 32px; text-align: center; border-radius: 28px; border: 1px dashed var(--line-2); background: var(--surface); }
.b-empty-icon { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 20px; background: var(--gold-soft); color: var(--gold-ink); margin-bottom: 18px; }
.b-empty-icon svg { width: 28px; height: 28px; }
.b-empty h2 { font-size: 24px; font-weight: 800; margin-bottom: 10px; }
.b-empty p { color: var(--muted); margin-bottom: 22px; }

/* ── Search results ────────────────────────────────────────────────────── */
.b-results { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.b-result { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 22px; padding: 18px; border-radius: var(--radius); background: var(--surface); border: 1px solid var(--line); }
.b-result:not(:has(.b-result-media)) { grid-template-columns: minmax(0, 1fr); }
.b-result-media { position: relative; display: block; border-radius: 16px; overflow: hidden; aspect-ratio: 4 / 3; }
.b-result-media .b-pic { position: absolute; inset: 0; }
.b-result-body { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.b-result-title { font-size: 21px; font-weight: 800; line-height: 1.3; }
.b-result-title a:hover { color: var(--gold-ink); }
.b-result-excerpt { color: var(--muted); }
.b-result mark { background: color-mix(in srgb, var(--gold-2) 40%, transparent); color: inherit; border-radius: 4px; padding: 0 2px; }

/* ── Article page ──────────────────────────────────────────────────────── */
.b-article-page .site-header:not(.is-scrolled) { background: transparent; }
.b-preview-banner {
    position: sticky; top: 0; z-index: 65;
    display: flex; align-items: center; justify-content: center; gap: 10px;
    padding: 10px 16px; background: #0E1A33; color: #FFD966; font-weight: 700; font-size: 14px;
}
.b-preview-banner svg { width: 18px; height: 18px; }

.b-article-head {
    position: relative; isolation: isolate; overflow: hidden;
    padding: 140px 0 40px;
    background: linear-gradient(180deg, var(--bg-soft) 0%, var(--bg) 100%);
}
.b-article-glow {
    position: absolute; z-index: -1; right: -240px; top: -260px; width: 720px; height: 720px; border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 214, 120, 0.38), transparent 62%); pointer-events: none;
}
[data-theme="dark"] .b-article-glow { background: radial-gradient(circle, rgba(251, 192, 45, 0.14), transparent 62%); }
.b-article-head-inner { max-width: 880px; }
.b-article-kicker { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 4px; }
.b-article-title {
    margin: 20px 0 18px;
    font-size: clamp(34px, 4.6vw, 60px); font-weight: 800; line-height: 1.06; letter-spacing: -0.035em;
}
.b-article-lead { max-width: 760px; font-size: clamp(18px, 1.4vw, 21px); line-height: 1.6; color: var(--muted); }
[data-theme="light"] .b-article-lead { color: #3E475C; }
.b-article-meta { display: flex; align-items: center; gap: 14px; margin-top: 30px; }
.b-article-meta .b-avatar { width: 46px; height: 46px; }
.b-article-meta-text { display: flex; flex-direction: column; gap: 2px; }
.b-article-author { font-weight: 800; color: var(--ink); }
.b-article-author a:hover { color: var(--gold-ink); }
.b-article-role { font-weight: 500; color: var(--muted); }
.b-article-dates { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; font-size: 14.5px; color: var(--muted); }
.b-views { display: inline-flex; align-items: center; gap: 5px; }
.b-views svg { width: 15px; height: 15px; }

.b-article-hero { max-width: 1152px; margin: 8px auto 0; padding: 0 24px; }
.b-article-hero .b-pic--hero { aspect-ratio: 16 / 9; border-radius: 30px; box-shadow: var(--shadow-lg); }
.b-article-hero figcaption { margin-top: 12px; text-align: center; font-size: 14px; color: var(--muted); }
.b-credit { margin-left: 8px; font-style: italic; color: var(--dim); }
.b-credit::before { content: '· '; font-style: normal; }

.b-article-layout {
    display: grid; grid-template-columns: 64px minmax(0, 720px) 260px; justify-content: center;
    gap: 56px; padding-top: 56px; padding-bottom: 32px;
}
.b-article-main { min-width: 0; }
.b-article-rail { position: relative; }
.b-article-rail .b-share { position: sticky; top: 120px; }
.b-article-aside { position: relative; }
.b-article-after { padding-bottom: 96px; }
.b-article-after .cta-band { margin: 24px 0 88px; }

/* TOC */
.b-toc { font-size: 14.5px; }
.b-toc--sticky { position: sticky; top: 112px; max-height: calc(100vh - 140px); overflow-y: auto; padding: 4px 4px 16px 0; }
.b-toc-head { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 12.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }
.b-toc-ring { width: 26px; height: 26px; transform: rotate(-90deg); }
.b-toc-ring circle { fill: none; stroke-width: 3.5; stroke: var(--line-2); }
.b-toc-ring .b-toc-ring-fill { stroke: var(--gold); stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: calc(100 - var(--read, 0) * 100); transition: stroke-dashoffset 0.15s linear; }
.b-toc-list { list-style: none; margin: 0; padding: 0 0 0 2px; border-left: 2px solid var(--line); }
.b-toc-item a {
    display: block; margin-left: -2px; padding: 7px 0 7px 16px; border-left: 2px solid transparent;
    color: var(--muted); line-height: 1.4; transition: color 0.2s ease, border-color 0.2s ease;
}
.b-toc-l3 a { padding-left: 30px; font-size: 13.5px; }
.b-toc-item a:hover { color: var(--ink); }
.b-toc-item a[aria-current] { color: var(--ink); font-weight: 700; border-left-color: var(--gold); }
.b-toc-mobile { display: none; margin-bottom: 32px; border-radius: 18px; border: 1px solid var(--line-2); background: var(--surface); }
.b-toc-mobile summary { display: flex; align-items: center; gap: 10px; padding: 14px 18px; cursor: pointer; font-weight: 800; color: var(--ink); list-style: none; }
.b-toc-mobile summary::-webkit-details-marker { display: none; }
.b-toc-mobile summary svg { width: 18px; height: 18px; }
.b-toc-chev { margin-left: auto; transition: transform 0.2s ease; }
.b-toc-mobile[open] .b-toc-chev { transform: rotate(180deg); }
.b-toc--inline { padding: 0 18px 16px; }
.b-toc--inline .b-toc-head { display: none; }

/* Share */
.b-share { display: flex; align-items: center; gap: 10px; }
.b-share--rail { flex-direction: column; }
.b-share--bar { flex-wrap: wrap; margin: 40px 0; padding: 20px 22px; border-radius: 20px; background: var(--surface-2); }
.b-share-label { margin-right: auto; font-weight: 800; color: var(--ink); }
.b-share-btn {
    width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
    background: var(--surface); color: var(--text); border: 1px solid var(--line-2);
    transition: transform 0.2s ease, color 0.2s ease, border-color 0.2s ease, background-color 0.2s ease;
}
.b-share-btn:hover { transform: translateY(-2px); color: var(--gold-ink); border-color: var(--gold-2); }
.b-share-btn svg { width: 18px; height: 18px; }
.b-share-done-icon { display: none; }
.b-share-btn.is-done { color: #16A34A; border-color: #16A34A; }
.b-share-btn.is-done .b-share-copy-icon { display: none; }
.b-share-btn.is-done .b-share-done-icon { display: block; }

/* Tags, FAQ */
.b-tags { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 40px 0 0; padding: 0; }
.b-tag { display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); font-size: 14px; font-weight: 600; color: var(--text); }
.b-tag:hover { border-color: var(--gold-2); color: var(--gold-ink); }
.b-tag svg { width: 14px; height: 14px; color: var(--dim); }
.b-faq { margin-top: 48px; }
.b-faq h2 { font-size: 26px; font-weight: 800; margin-bottom: 16px; }
.b-faq-item { border-bottom: 1px solid var(--line); }
.b-faq-item summary { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 0; cursor: pointer; list-style: none; font-weight: 700; font-size: 17px; color: var(--ink); }
.b-faq-item summary::-webkit-details-marker { display: none; }
.b-faq-item summary svg { flex: none; width: 18px; height: 18px; transition: transform 0.2s ease; color: var(--muted); }
.b-faq-item[open] summary svg { transform: rotate(180deg); }
.b-faq-item p { padding: 0 0 18px; color: var(--muted); line-height: 1.7; }

/* Author card */
.b-author {
    display: flex; gap: 24px; padding: 30px; border-radius: 26px;
    background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm);
}
.b-author-kicker { font-size: 12.5px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; color: var(--kicker); }
.b-author-name { margin: 4px 0 2px; font-size: 24px; font-weight: 800; }
.b-author-name a:hover { color: var(--gold-ink); }
.b-author-role { font-weight: 600; color: var(--muted); }
.b-author-bio { margin-top: 12px; color: var(--text); line-height: 1.7; }
.b-author-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; }
.b-author-foot .b-text-link { margin-top: 0; }
.b-author-social { list-style: none; display: flex; gap: 8px; margin: 16px 0 0; padding: 0; }
.b-author-foot .b-author-social { margin: 0; }
.b-author-social a { width: 38px; height: 38px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--line-2); background: var(--surface); color: var(--text); transition: color 0.2s, border-color 0.2s; }
.b-author-social a:hover { color: var(--gold-ink); border-color: var(--gold-2); }
.b-author-social svg { width: 17px; height: 17px; }

/* Reactions */
.b-reactions { margin: 40px 0 0; text-align: center; }
.b-reactions-title { font-size: 18px; font-weight: 800; margin-bottom: 14px; }
.b-reactions-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.b-reaction {
    display: inline-flex; align-items: center; gap: 8px; height: 46px; padding: 0 16px 0 12px; border-radius: 999px;
    border: 1px solid var(--line-2); background: var(--surface); color: var(--text); font-weight: 700; font-size: 14px;
    transition: transform 0.2s cubic-bezier(.2,.7,.2,1), border-color 0.2s, background-color 0.2s, box-shadow 0.2s;
}
.b-reaction:hover { transform: translateY(-2px); border-color: var(--gold-2); box-shadow: var(--shadow-sm); }
.b-reaction[aria-pressed="true"] { background: var(--gold-soft); border-color: var(--gold); color: var(--ink); }
.b-reaction-glyph { font-size: 20px; line-height: 1; transition: transform 0.25s cubic-bezier(.2,1.4,.4,1); }
.b-reaction[aria-pressed="true"] .b-reaction-glyph { transform: scale(1.18); }
.b-reaction-count { min-width: 22px; height: 22px; padding: 0 7px; border-radius: 999px; display: inline-grid; place-items: center; background: var(--surface-2); color: var(--muted); font-size: 12.5px; }
.b-reaction[aria-pressed="true"] .b-reaction-count { background: var(--surface); color: var(--gold-ink); }
@keyframes b-pop { 0% { transform: scale(1); } 40% { transform: scale(1.45) rotate(-8deg); } 100% { transform: scale(1.18); } }
.b-reaction.is-popping .b-reaction-glyph { animation: b-pop 0.45s ease; }
@media (max-width: 520px) {
    .b-reaction-label { display: none; }
    .b-reactions-row { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
    .b-reaction { justify-content: center; gap: 6px; padding-inline: 8px; }
}

/* Newsletter */
.b-hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.b-news {
    position: relative; overflow: hidden; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 14px 18px; align-items: start;
    margin: 40px 0 0; padding: 28px; border-radius: 26px;
    background: radial-gradient(80% 120% at 100% 0%, rgba(255, 255, 255, 0.75), transparent 60%), linear-gradient(135deg, #FFF3DC, #FDE6C4);
    box-shadow: var(--shadow-sm);
}
[data-theme="dark"] .b-news { background: radial-gradient(80% 120% at 100% 0%, rgba(251, 192, 45, 0.14), transparent 60%), linear-gradient(135deg, #131C33, #1A2541); }
.b-news-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 15px; background: var(--surface); color: var(--gold); box-shadow: var(--shadow-sm); }
.b-news-icon svg { width: 22px; height: 22px; }
.b-news-title { font-size: 21px; font-weight: 800; margin-bottom: 6px; }
.b-news-copy p { color: var(--muted); font-size: 15px; }
.b-news-form { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 10px; }
.b-news-input { flex: 1; min-width: 200px; height: 46px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--surface); color: var(--ink); font: 500 15px 'Inter', sans-serif; }
.b-news-input:focus { outline: none; border-color: var(--gold-2); box-shadow: 0 0 0 4px color-mix(in srgb, var(--gold-2) 22%, transparent); }
.b-news-status { flex-basis: 100%; min-height: 1.2em; font-size: 14px; font-weight: 600; color: var(--gold-ink); }
.b-news-status.is-error { color: #D23A2E; }
.b-news-fine { flex-basis: 100%; margin: -4px 0 0; font-size: 12.5px; color: var(--muted); }
.b-news-fine a, .b-comment-note a { color: inherit; text-decoration: underline; text-underline-offset: 2px; }
.b-news-fine a:hover, .b-comment-note a:hover { color: var(--ink); }
.b-news--side { grid-template-columns: minmax(0, 1fr); margin: 0; padding: 24px; border-radius: var(--radius); }
.b-news--side .b-news-title { font-size: 18px; }
.b-news--side .b-news-form { flex-direction: column; }
.b-news--side .b-news-input { min-width: 0; }

/* Comments */
.b-comments { margin-top: 56px; padding-top: 40px; border-top: 1px solid var(--line); content-visibility: auto; contain-intrinsic-size: auto 600px; }
.b-comments-title { font-size: 26px; font-weight: 800; margin-bottom: 22px; }
.b-comment-list, .b-comment-replies { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.b-comment-replies { margin: 16px 0 0 52px; padding-left: 18px; border-left: 2px solid var(--line); }
.b-comment-card { display: flex; gap: 14px; }
.b-avatar--sm { width: 38px; height: 38px; font-size: 13px; }
.b-comment-card.is-team .b-avatar { background: linear-gradient(135deg, #0E1A33, #26324B); color: #FFD966; }
.b-comment-main { flex: 1; min-width: 0; }
.b-comment-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-bottom: 4px; font-size: 14px; }
.b-comment-name { font-weight: 800; color: var(--ink); }
.b-comment-head time { color: var(--muted); }
.b-team-badge { padding: 2px 8px; border-radius: 999px; background: var(--gold-soft); color: var(--label); font-size: 11.5px; font-weight: 800; }
.b-comment-body { color: var(--text); line-height: 1.7; overflow-wrap: anywhere; }
.b-comment-body a { color: var(--gold-ink); text-decoration: underline; }
.b-link-btn { border: 0; background: none; padding: 0; color: var(--gold-ink); font: 700 13.5px 'Inter', sans-serif; cursor: pointer; }
.b-comment-main .b-link-btn { margin-top: 6px; }
.b-comment-form { margin-top: 32px; padding: 26px; border-radius: 24px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-sm); }
.b-comment-form-title { font-size: 20px; font-weight: 800; margin-bottom: 14px; }
.b-comment-replying { margin: -6px 0 14px; color: var(--muted); font-size: 14px; }
.b-comment-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.b-field { display: grid; gap: 6px; margin-bottom: 12px; font-size: 13.5px; font-weight: 700; color: var(--ink); position: relative; }
.b-field small { font-weight: 500; color: var(--muted); }
.b-field input, .b-field textarea { width: 100%; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--line-2); background: var(--bg); color: var(--ink); font: 500 15px/1.5 'Inter', sans-serif; }
.b-field textarea { resize: vertical; min-height: 120px; }
.b-field input:focus, .b-field textarea:focus { outline: none; border-color: var(--gold-2); box-shadow: 0 0 0 4px color-mix(in srgb, var(--gold-2) 22%, transparent); }
.b-field-count { justify-self: end; font-size: 12px; }
.b-captcha { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-bottom: 12px; padding: 12px; border-radius: 14px; background: var(--surface-2); }
.b-captcha-img svg { display: block; height: 44px; width: auto; border-radius: 8px; background: #fff; }
.b-field--inline { margin: 0; flex: 1; min-width: 140px; }
.b-comment-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; }
.b-comment-note { color: var(--muted); font-size: 13.5px; }
.b-comment-status { min-height: 1.2em; margin-top: 12px; font-weight: 700; font-size: 14px; color: var(--gold-ink); }
.b-comment-status.is-error { color: #D23A2E; }
.b-comments-closed { margin-top: 12px; }
@media (max-width: 640px) {
    .b-comment-fields { grid-template-columns: 1fr; }
    .b-comment-replies { margin-left: 18px; }
    .b-news { padding: 22px; grid-template-columns: minmax(0, 1fr); }
}

/* Related + prev/next */
.b-related { margin-top: 8px; }
.b-prevnext { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 56px; }
.b-prevnext-link { display: flex; flex-direction: column; gap: 8px; padding: 24px 26px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface); transition: border-color 0.2s, transform 0.25s; }
.b-prevnext-link:hover { border-color: var(--gold-2); transform: translateY(-3px); }
.b-prevnext-link--next { text-align: right; align-items: flex-end; }
.b-prevnext-label { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 800; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.b-prevnext-label svg { width: 15px; height: 15px; }
.b-prevnext-title { font-size: 18px; font-weight: 800; color: var(--ink); line-height: 1.35; }

/* Mobile dock */
.b-dock {
    position: fixed; left: 50%; bottom: 16px; z-index: 45; transform: translate(-50%, 140%);
    display: flex; gap: 4px; padding: 6px; border-radius: 999px;
    background: color-mix(in srgb, var(--surface) 92%, transparent);
    -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px);
    border: 1px solid var(--line-2); box-shadow: var(--shadow-lg);
    transition: transform 0.35s cubic-bezier(.2,.7,.2,1);
}
.b-dock.is-visible { transform: translate(-50%, 0); }
.b-dock-btn { display: inline-flex; align-items: center; gap: 7px; height: 44px; padding: 0 16px; border: 0; border-radius: 999px; background: transparent; font-weight: 700; font-size: 14px; color: var(--ink); }
.b-dock-btn:hover { background: var(--surface-2); }
.b-dock-btn svg { width: 17px; height: 17px; }

/* Lightbox */
.b-lightbox { max-width: min(96vw, 1400px); max-height: 94vh; padding: 0; border: 0; border-radius: 18px; background: transparent; overflow: visible; }
.b-lightbox::backdrop { background: rgba(6, 10, 21, 0.86); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.b-lightbox img { max-width: min(96vw, 1400px); max-height: 86vh; width: auto; height: auto; border-radius: 16px; margin: 0 auto; }
.b-lightbox-caption { margin-top: 12px; text-align: center; color: #D6DCE8; font-size: 14.5px; }
.b-lightbox-close { position: absolute; top: -14px; right: -14px; width: 42px; height: 42px; border-radius: 50%; border: 0; display: grid; place-items: center; background: #fff; color: #0E1A33; box-shadow: var(--shadow-md); }
.b-lightbox-close svg { width: 18px; height: 18px; }

/* Toast */
.b-toast {
    position: fixed; left: 50%; bottom: 84px; z-index: 80; transform: translate(-50%, 20px); opacity: 0;
    padding: 12px 18px; border-radius: 14px; background: var(--ink); color: var(--bg); font-weight: 700; font-size: 14.5px;
    box-shadow: var(--shadow-lg); pointer-events: none; transition: opacity 0.25s ease, transform 0.25s ease;
}
.b-toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ── Responsive ────────────────────────────────────────────────────────── */
@media (max-width: 1180px) {
    .b-article-layout { grid-template-columns: minmax(0, 720px); gap: 0; }
    .b-article-rail, .b-article-aside { display: none; }
    .b-toc-mobile { display: block; }
}
@media (max-width: 1100px) {
    .b-with-side { grid-template-columns: minmax(0, 1fr); }
    .b-side { position: static; grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .b-rss { grid-column: 1 / -1; }
}
@media (max-width: 980px) {
    .b-lead { grid-template-columns: minmax(0, 1fr); }
    .b-lead-media { min-height: 0; aspect-ratio: 16 / 9; }
    .b-lead-body { padding: 30px 28px 32px; }
    .b-grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
    .b-hero { padding: 120px 0 44px; }
    .b-article-head { padding: 116px 0 28px; }
    .b-grid--2, .b-grid--3 { grid-template-columns: minmax(0, 1fr); }
    .b-grid--snap { grid-auto-flow: column; grid-auto-columns: 84%; grid-template-columns: none; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: none; }
    .b-grid--snap > * { scroll-snap-align: start; }
    .b-side { grid-template-columns: minmax(0, 1fr); }
    .b-section { padding: 40px 0 72px; }
    .b-section-head--row { flex-direction: column; align-items: flex-start; }
    .b-search { height: 56px; }
    .b-search-kbd { display: none; }
    .b-result { grid-template-columns: 110px minmax(0, 1fr); gap: 14px; padding: 14px; }
    .b-result-title { font-size: 17.5px; }
    .b-result-excerpt { display: none; }
    .b-prevnext { grid-template-columns: minmax(0, 1fr); }
    .b-author { flex-direction: column; padding: 24px; }
    .b-article-hero { padding: 0; }
    .b-article-hero .b-pic--hero { border-radius: 0; }
    .b-article-layout { padding-top: 36px; }
    .b-profile { flex-direction: column; align-items: flex-start; }
    .b-pager-step span { display: none; }
    .article-body { font-size: 17px; }
}
@media (min-width: 1181px) {
    .b-dock { display: none; }
}
@media (max-width: 1180px) {
    /* Keep the WhatsApp button clear of the article dock. */
    .b-article-page .whatsapp-fab { bottom: 88px; }
}

@media print {
    .site-header, .site-footer, .whatsapp-fab, .b-article-rail, .b-article-aside, .b-share, .b-dock, .b-related, .b-prevnext, .cta-band, .scroll-progress { display: none !important; }
    .b-article-layout { display: block; }
}
