/* ============================================================
   BlogCraft Designer — Frontend Stylesheet  v1.0.0
   All styles are scoped under .blogcraft-wrapper to prevent
   conflicts with themes and page builders.
   CSS custom properties (--bc-*) are output dynamically by
   BlogCraft_Plugin::output_css_variables() from saved settings.
   ============================================================ */

/* ── 1. Reset & Base ─────────────────────────────────────── */
.blogcraft-wrapper { box-sizing: border-box; font-family: var(--bc-font-body); font-size: var(--bc-font-size); line-height: var(--bc-lh); color: var(--bc-text); background: var(--bc-page-bg); }
.blogcraft-wrapper *, .blogcraft-wrapper *::before, .blogcraft-wrapper *::after { box-sizing: inherit; }
.blogcraft-wrapper a { color: var(--bc-link); text-decoration: underline; text-underline-offset: 2px; }
.blogcraft-wrapper a:hover { color: var(--bc-link-hover); }
.blogcraft-wrapper img { max-width: 100%; height: auto; display: block; }
.blogcraft-wrapper ul, .blogcraft-wrapper ol { padding-left: 1.5em; }
.blogcraft-wrapper p { margin: 0 0 1.1em; }
.blogcraft-wrapper h1, .blogcraft-wrapper h2, .blogcraft-wrapper h3,
.blogcraft-wrapper h4, .blogcraft-wrapper h5, .blogcraft-wrapper h6 {
  font-family: var(--bc-font-heading); font-weight: var(--bc-fw-heading);
  color: var(--bc-heading); line-height: 1.25; margin: 0 0 .55em; }

/* ── 2. Archive Container ────────────────────────────────── */
.bc-archive-wrap { max-width: var(--bc-max-w); margin: 0 auto; padding: 0 20px 60px; }

/* ── 3. Blog Archive Header ──────────────────────────────── */
.bc-archive-header { background: var(--bc-header-bg); color: var(--bc-header-text); min-height: var(--bc-header-h); display: flex; align-items: center; padding: 40px 20px; margin-bottom: 40px; }
.bc-archive-header__inner { max-width: var(--bc-max-w); margin: 0 auto; width: 100%; }
.bc-archive-header--center { text-align: center; }
.bc-archive-header--left { text-align: left; }
.bc-archive-header--right { text-align: right; }
.bc-archive-header__title { font-family: var(--bc-font-heading); font-size: clamp(28px, 4vw, 44px); font-weight: var(--bc-fw-heading); color: var(--bc-header-text); margin: 0 0 10px; line-height: 1.15; }
.bc-archive-header__subtitle { font-size: 16px; color: var(--bc-header-text); opacity: .8; margin: 0; max-width: 560px; }
.bc-archive-header--center .bc-archive-header__subtitle { margin: 0 auto; }
.bc-archive-context { font-size: 13px; color: var(--bc-header-text); opacity: .65; margin-top: 10px; }

/* ── 4. Badges ────────────────────────────────────────────── */
.bc-badge { display: inline-flex; align-items: center; padding: 3px 10px; border-radius: 99px; font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; text-decoration: none; transition: opacity .15s; white-space: nowrap; }
.bc-badge--category { background: var(--bc-badge-bg); color: var(--bc-badge-text); }
.bc-badge--category:hover { opacity: .8; }
.bc-badges { display: flex; flex-wrap: wrap; gap: 6px; }

/* ── 5. Meta Row (author, date, reading time) ─────────────── */
.bc-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; font-size: 12.5px; color: var(--bc-meta); }
.bc-meta__sep { display: inline-block; width: 3px; height: 3px; border-radius: 50%; background: var(--bc-meta); opacity: .5; }
.bc-author-link { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; color: var(--bc-meta); }
.bc-author-link:hover { color: var(--bc-primary); }
.bc-avatar { border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.bc-avatar--sm { width: 24px; height: 24px; }
.bc-avatar--lg { width: 64px; height: 64px; }
.bc-author-name { font-weight: 500; }
.bc-date { color: var(--bc-meta); }
.bc-reading-time { display: inline-flex; align-items: center; gap: 4px; color: var(--bc-meta); }
.bc-reading-time svg { opacity: .6; }
.bc-comment-count { display: inline-flex; align-items: center; gap: 4px; color: var(--bc-meta); text-decoration: none; }

/* ── 6. Tags ──────────────────────────────────────────────── */
.bc-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px; }
.bc-tag { display: inline-flex; align-items: center; padding: 4px 12px; border: 1px solid var(--bc-border); border-radius: 99px; font-size: 12px; color: var(--bc-meta); text-decoration: none; transition: border-color .15s, color .15s; }
.bc-tag:hover { border-color: var(--bc-primary); color: var(--bc-primary); }

/* ── 7. Read More Button ──────────────────────────────────── */
.bc-read-more { display: inline-flex; align-items: center; gap: 6px; padding: 9px 20px; background: var(--bc-btn); color: var(--bc-btn-text) !important; border-radius: var(--bc-radius); font-size: 13px; font-weight: 600; text-decoration: none !important; transition: opacity .15s, transform .15s; white-space: nowrap; }
.bc-read-more:hover { opacity: .9; transform: translateY(-1px); }

/* ── 8. Post Card ─────────────────────────────────────────── */
.bc-card { display: flex; flex-direction: column; background: var(--bc-card-bg); border-radius: var(--bc-radius); border: var(--bc-border-w) solid var(--bc-border); overflow: hidden; transition: transform .2s, box-shadow .2s; }
.bc-card--shadow { box-shadow: 0 2px 12px rgba(0,0,0,.06), 0 1px 3px rgba(0,0,0,.04); }
.bc-card--hover-lift:hover { transform: translateY(-4px); box-shadow: 0 12px 32px rgba(0,0,0,.1); }
.bc-card__image-wrap { position: relative; overflow: hidden; }
.bc-card__image-wrap a { display: block; }
.bc-card__image-inner { position: relative; padding-bottom: var(--bc-img-ratio); overflow: hidden; background: var(--bc-border); }
.bc-card__image-inner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.bc-card:hover .bc-card__image-inner img { transform: scale(1.04); }
.bc-card__no-image { position: absolute; inset: 0; background: linear-gradient(135deg, #e2e8f0 0%, #f1f5f9 100%); display: flex; align-items: center; justify-content: center; }
.bc-card__no-image svg { opacity: .25; }
.bc-card__body { flex: 1; padding: 22px; display: flex; flex-direction: column; gap: 10px; }
.bc-card__cats { display: flex; flex-wrap: wrap; gap: 6px; }
.bc-card__title { font-size: 17px; font-weight: 700; color: var(--bc-heading); line-height: 1.3; margin: 0; }
.bc-card__title a { color: inherit; text-decoration: none; }
.bc-card__title a:hover { color: var(--bc-primary); }
.bc-card__excerpt { font-size: 14px; color: var(--bc-text); line-height: 1.65; margin: 0; flex: 1; }
.bc-card__footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; margin-top: auto; padding-top: 14px; border-top: 1px solid var(--bc-border); }

/* ── 9. Archive Grids ─────────────────────────────────────── */
.bc-grid { display: grid; grid-template-columns: repeat(var(--bc-columns), 1fr); gap: var(--bc-gap); }
.bc-grid--equal .bc-card { height: 100%; }

/* No posts */
.bc-no-posts { text-align: center; padding: 80px 20px; color: var(--bc-meta); font-size: 16px; }
.bc-no-posts p { max-width: 360px; margin: 0 auto; }

/* ── 10. Layout: Editorial Grid ───────────────────────────── */
.bc-layout--editorial-grid {}

/* Featured post – spans full width */
.bc-featured-wrap { margin-bottom: calc(var(--bc-gap) * 1.5); }
.bc-card--featured { flex-direction: row; min-height: 340px; }
.bc-card--featured .bc-card__image-wrap { flex: 0 0 55%; }
.bc-card--featured .bc-card__image-inner { padding-bottom: 0; height: 100%; }
.bc-card--featured .bc-card__image-inner img { position: absolute; }
.bc-card--featured .bc-card__body { flex: 1; padding: 32px; justify-content: center; gap: 14px; }
.bc-card--featured .bc-card__title { font-size: clamp(20px, 2.5vw, 28px); }
.bc-card--featured .bc-card__excerpt { font-size: 15px; }

.bc-section-label { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.bc-section-label__text { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; font-weight: 700; color: var(--bc-meta); white-space: nowrap; }
.bc-section-label__line { flex: 1; height: 1px; background: var(--bc-border); }

/* ── 11. Layout: Modern Magazine ─────────────────────────── */
.bc-layout--modern-magazine {}

.bc-mag-hero { display: grid; grid-template-columns: 1fr 360px; gap: var(--bc-gap); margin-bottom: calc(var(--bc-gap) * 1.5); }
.bc-mag-hero__main .bc-card--featured { flex-direction: column; min-height: 400px; }
.bc-mag-hero__main .bc-card--featured .bc-card__image-wrap { flex: none; }
.bc-mag-hero__main .bc-card--featured .bc-card__image-inner { padding-bottom: 55%; }
.bc-mag-sidebar { display: flex; flex-direction: column; gap: var(--bc-gap); }
.bc-mag-sidebar .bc-card { flex-direction: row; min-height: auto; }
.bc-mag-sidebar .bc-card__image-wrap { flex: 0 0 110px; }
.bc-mag-sidebar .bc-card__image-inner { padding-bottom: 100%; }
.bc-mag-sidebar .bc-card__body { padding: 14px; }
.bc-mag-sidebar .bc-card__title { font-size: 14px; }
.bc-mag-sidebar .bc-card__excerpt { display: none; }

.bc-mag-section-title { font-size: 22px; font-weight: 800; color: var(--bc-heading); border-bottom: 3px solid var(--bc-primary); padding-bottom: 10px; margin: 0 0 20px; }

/* ── 12. Layout: Professional List ───────────────────────── */
.bc-layout--professional-list {}

.bc-list { display: flex; flex-direction: column; gap: var(--bc-gap); }
.bc-list-card { display: flex; align-items: stretch; background: var(--bc-card-bg); border-radius: var(--bc-radius); border: var(--bc-border-w) solid var(--bc-border); overflow: hidden; transition: box-shadow .2s, transform .2s; }
.bc-list-card--shadow { box-shadow: 0 1px 8px rgba(0,0,0,.05); }
.bc-list-card--hover:hover { box-shadow: 0 6px 20px rgba(0,0,0,.08); transform: translateX(2px); }
.bc-list-card__image { flex: 0 0 280px; position: relative; overflow: hidden; }
.bc-list-card__image a { display: block; height: 100%; }
.bc-list-card__image img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.bc-list-card:hover .bc-list-card__image img { transform: scale(1.04); }
.bc-list-card__body { flex: 1; padding: 28px 32px; display: flex; flex-direction: column; justify-content: center; gap: 10px; }
.bc-list-card__title { font-size: 20px; font-weight: 700; color: var(--bc-heading); margin: 0; line-height: 1.3; }
.bc-list-card__title a { color: inherit; text-decoration: none; }
.bc-list-card__title a:hover { color: var(--bc-primary); }
.bc-list-card__excerpt { font-size: 14.5px; color: var(--bc-text); line-height: 1.65; }
.bc-list-card__footer { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-top: 12px; border-top: 1px solid var(--bc-border); margin-top: auto; }

/* ── 13. Layout: Image Cards ──────────────────────────────── */
.bc-layout--image-cards {}

.bc-img-grid { display: grid; grid-template-columns: repeat(var(--bc-columns), 1fr); gap: var(--bc-gap); }
.bc-img-card { position: relative; border-radius: var(--bc-radius); overflow: hidden; aspect-ratio: 3/4; display: flex; align-items: flex-end; }
.bc-img-card::after { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.75) 0%, rgba(0,0,0,.2) 50%, transparent 100%); z-index: 1; transition: opacity .3s; }
.bc-img-card:hover::after { opacity: .9; }
.bc-img-card__image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.bc-img-card:hover .bc-img-card__image { transform: scale(1.06); }
.bc-img-card__body { position: relative; z-index: 2; padding: 22px; width: 100%; }
.bc-img-card__badge { display: inline-flex; padding: 2px 10px; background: rgba(255,255,255,.2); backdrop-filter: blur(4px); border-radius: 99px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: #fff; text-decoration: none; margin-bottom: 8px; }
.bc-img-card__title { font-size: clamp(14px, 2vw, 18px); font-weight: 700; color: #fff; line-height: 1.3; margin: 0 0 8px; }
.bc-img-card__title a { color: #fff; text-decoration: none; }
.bc-img-card__meta { font-size: 12px; color: rgba(255,255,255,.7); display: flex; align-items: center; gap: 10px; }
.bc-img-card__no-image { background: linear-gradient(135deg, #1e293b, #334155); }

/* ── 14. Pagination ───────────────────────────────────────── */
.bc-pagination { margin: 48px 0 0; display: flex; justify-content: center; }
.bc-pagination__list { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.bc-pagination__item a,
.bc-pagination__item span { display: inline-flex; align-items: center; justify-content: center; min-width: 40px; height: 40px; padding: 0 12px; border: 1px solid var(--bc-border); border-radius: 6px; font-size: 14px; color: var(--bc-text); text-decoration: none; transition: background .15s, border-color .15s, color .15s; }
.bc-pagination__item a:hover { background: var(--bc-primary); border-color: var(--bc-primary); color: #fff; }
.bc-pagination__item--active span { background: var(--bc-primary); border-color: var(--bc-primary); color: #fff; font-weight: 700; }
.bc-pagination__item .dots { background: transparent; border-color: transparent; }

/* ── 15. Breadcrumbs ──────────────────────────────────────── */
.bc-breadcrumbs { font-size: 13px; color: var(--bc-meta); margin-bottom: 20px; }
.bc-breadcrumbs__list { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; }
.bc-breadcrumbs__item { display: flex; align-items: center; gap: 4px; }
.bc-breadcrumbs__link { color: var(--bc-meta); text-decoration: none; }
.bc-breadcrumbs__link:hover { color: var(--bc-primary); }
.bc-breadcrumbs__current { color: var(--bc-text); font-weight: 500; }
.bc-breadcrumbs__sep { color: var(--bc-meta); opacity: .6; }

/* ── 16. Single Post Wrapper ──────────────────────────────── */
.bc-single-wrap { max-width: var(--bc-max-w); margin: 0 auto; padding: 40px 20px 80px; }

/* ── 17. Single: Professional Article ────────────────────── */
.bc-single--professional {}
.bc-single-article { max-width: var(--bc-reading-w); margin: 0 auto; }
.bc-article-header { margin-bottom: 32px; }
.bc-article-header .bc-badges { margin-bottom: 14px; }
.bc-article-title { font-size: clamp(26px, 4.5vw, 42px); font-weight: 800; color: var(--bc-heading); line-height: 1.18; margin: 0 0 20px; }
.bc-article-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; margin-bottom: 24px; }
.bc-article-excerpt { font-size: 18px; line-height: 1.65; color: var(--bc-secondary); font-style: italic; border-left: 3px solid var(--bc-primary); padding-left: 20px; margin: 0 0 28px; }
.bc-featured-image-wrap { border-radius: var(--bc-radius); overflow: hidden; margin-bottom: 36px; }
.bc-featured-image-wrap img { width: 100%; height: auto; display: block; }

/* ── 18. Article Content Styling ──────────────────────────── */
.bc-content { font-size: var(--bc-font-size); line-height: var(--bc-lh); color: var(--bc-text); }
.bc-content p { margin: 0 0 1.25em; }
.bc-content h2 { font-size: 1.6em; margin: 1.8em 0 .6em; padding-top: .2em; }
.bc-content h3 { font-size: 1.3em; margin: 1.5em 0 .5em; }
.bc-content h4 { font-size: 1.1em; margin: 1.3em 0 .4em; }
.bc-content h5, .bc-content h6 { font-size: 1em; margin: 1.2em 0 .4em; }
.bc-content ul, .bc-content ol { margin: 0 0 1.2em; padding-left: 1.6em; }
.bc-content li { margin-bottom: .35em; }
.bc-content blockquote { border-left: 4px solid var(--bc-primary); margin: 1.8em 0; padding: 1em 1.5em; background: var(--bc-badge-bg); border-radius: 0 var(--bc-radius) var(--bc-radius) 0; font-size: 1.05em; color: var(--bc-heading); font-style: italic; }
.bc-content blockquote cite { display: block; font-size: .85em; font-style: normal; color: var(--bc-meta); margin-top: .6em; }
.bc-content img { border-radius: calc(var(--bc-radius) * .75); max-width: 100%; height: auto; }
.bc-content figure { margin: 1.6em 0; }
.bc-content figcaption { font-size: 13px; color: var(--bc-meta); text-align: center; margin-top: 8px; }
.bc-content table { width: 100%; border-collapse: collapse; margin: 1.4em 0; font-size: .95em; }
.bc-content th { background: var(--bc-badge-bg); font-weight: 700; }
.bc-content th, .bc-content td { padding: 10px 14px; border: 1px solid var(--bc-border); text-align: left; }
.bc-content tr:nth-child(even) td { background: #f8fafc; }
.bc-content pre { background: #1e293b; color: #e2e8f0; padding: 18px 20px; border-radius: var(--bc-radius); overflow-x: auto; font-size: .9em; line-height: 1.6; margin: 1.4em 0; }
.bc-content code { background: var(--bc-badge-bg); color: var(--bc-badge-text); padding: 2px 6px; border-radius: 4px; font-size: .88em; font-family: "Courier New", Courier, monospace; }
.bc-content pre code { background: transparent; color: inherit; padding: 0; font-size: inherit; }
.bc-content a { color: var(--bc-link); }
.bc-content a:hover { color: var(--bc-link-hover); }
.bc-content hr { border: none; border-top: 2px solid var(--bc-border); margin: 2.5em 0; }

/* ── 19. Author Box ───────────────────────────────────────── */
.bc-author-box { display: flex; gap: 20px; padding: 28px; background: var(--bc-card-bg); border: 1px solid var(--bc-border); border-radius: var(--bc-radius); margin: 48px 0 0; }
.bc-author-box__avatar img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.bc-author-box__body { flex: 1; }
.bc-author-box__label { font-size: 11px; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; color: var(--bc-meta); margin-bottom: 4px; }
.bc-author-box__name { font-size: 17px; font-weight: 700; color: var(--bc-heading); margin: 0 0 8px; }
.bc-author-box__name a { color: inherit; text-decoration: none; }
.bc-author-box__name a:hover { color: var(--bc-primary); }
.bc-author-box__bio { font-size: 14px; color: var(--bc-text); line-height: 1.6; margin: 0 0 12px; }
.bc-author-box__links { display: flex; gap: 10px; flex-wrap: wrap; }
.bc-author-box__link { font-size: 13px; color: var(--bc-primary); text-decoration: none; font-weight: 500; }
.bc-author-box__link:hover { text-decoration: underline; }

/* ── 20. Social Sharing ───────────────────────────────────── */
.bc-share { margin: 32px 0; }
.bc-share__label { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; font-weight: 700; color: var(--bc-meta); margin-bottom: 12px; }
.bc-share__buttons { display: flex; flex-wrap: wrap; gap: 8px; }
.bc-share-btn { display: inline-flex; align-items: center; gap: 7px; padding: 8px 16px; border-radius: 6px; font-size: 13px; font-weight: 600; text-decoration: none; color: #fff; transition: opacity .15s, transform .12s; border: none; cursor: pointer; }
.bc-share-btn:hover { opacity: .88; transform: translateY(-1px); color: #fff; }
.bc-share-btn--facebook { background: #1877f2; }
.bc-share-btn--twitter  { background: #000; }
.bc-share-btn--linkedin { background: #0a66c2; }
.bc-share-btn--whatsapp { background: #25d366; }
.bc-share-btn--telegram { background: #229ed9; }
.bc-share-btn--email    { background: #64748b; }
.bc-share-btn--copy     { background: var(--bc-border); color: var(--bc-text); }
.bc-share-btn--copy:hover { color: var(--bc-text); }

/* ── 21. Related Posts ────────────────────────────────────── */
.bc-related { margin: 56px 0 0; }
.bc-related__title { font-size: 22px; font-weight: 800; color: var(--bc-heading); border-bottom: 2px solid var(--bc-border); padding-bottom: 12px; margin: 0 0 24px; }
.bc-related__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }

/* ── 22. Prev/Next Navigation ─────────────────────────────── */
.bc-prev-next { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 48px 0 0; }
.bc-prev-next__item { display: flex; flex-direction: column; gap: 4px; padding: 18px 20px; background: var(--bc-card-bg); border: 1px solid var(--bc-border); border-radius: var(--bc-radius); text-decoration: none; transition: border-color .15s, box-shadow .15s; }
.bc-prev-next__item:hover { border-color: var(--bc-primary); box-shadow: 0 4px 16px rgba(0,0,0,.07); }
.bc-prev-next__item--next { text-align: right; }
.bc-prev-next__label { font-size: 11px; text-transform: uppercase; letter-spacing: .07em; font-weight: 700; color: var(--bc-meta); display: flex; align-items: center; gap: 4px; }
.bc-prev-next__item--next .bc-prev-next__label { justify-content: flex-end; }
.bc-prev-next__title { font-size: 15px; font-weight: 600; color: var(--bc-heading); line-height: 1.4; margin: 0; }
.bc-prev-next__item:hover .bc-prev-next__title { color: var(--bc-primary); }

/* ── 23. Editorial Wide Single ────────────────────────────── */
.bc-single--editorial-wide .bc-single-wrap { max-width: 100%; padding-left: 0; padding-right: 0; }
.bc-single--editorial-wide .bc-wide-hero { position: relative; min-height: 500px; display: flex; align-items: center; overflow: hidden; background: #1e293b; }
.bc-single--editorial-wide .bc-wide-hero__image { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .5; }
.bc-single--editorial-wide .bc-wide-hero__body { position: relative; z-index: 2; max-width: 900px; margin: 0 auto; padding: 60px 40px; color: #fff; }
.bc-single--editorial-wide .bc-wide-hero__title { font-size: clamp(28px,5vw,52px); font-weight: 900; color: #fff; line-height: 1.12; margin: 0 0 16px; }
.bc-single--editorial-wide .bc-wide-hero__meta { color: rgba(255,255,255,.8); }
.bc-single--editorial-wide .bc-content-wrap { max-width: 800px; margin: 0 auto; padding: 48px 24px; }
.bc-single--editorial-wide .bc-content { font-size: 18px; }
.bc-single--editorial-wide .bc-content h2 { font-size: 2em; }

/* ── 24. Sidebar Article Single ───────────────────────────── */
.bc-single--sidebar .bc-single-layout { display: grid; grid-template-columns: 1fr var(--bc-sidebar-w); gap: 48px; align-items: start; max-width: var(--bc-max-w); margin: 0 auto; padding: 40px 20px 80px; }
.bc-single--sidebar.bc-sidebar-left .bc-single-layout { grid-template-columns: var(--bc-sidebar-w) 1fr; }
.bc-single--sidebar.bc-sidebar-left .bc-single-layout .bc-article-main { order: 2; }
.bc-single--sidebar.bc-sidebar-left .bc-single-layout .bc-article-sidebar { order: 1; }
.bc-article-sidebar { position: sticky; top: 100px; }
.bc-sidebar-widget { background: var(--bc-card-bg); border: 1px solid var(--bc-border); border-radius: var(--bc-radius); padding: 20px; margin-bottom: 20px; }
.bc-sidebar-widget__title { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; font-weight: 800; color: var(--bc-meta); margin: 0 0 14px; padding-bottom: 10px; border-bottom: 2px solid var(--bc-border); }
.bc-sidebar-cat-list { list-style: none; margin: 0; padding: 0; }
.bc-sidebar-cat-list li { padding: 6px 0; border-bottom: 1px solid var(--bc-border); }
.bc-sidebar-cat-list li:last-child { border-bottom: 0; }
.bc-sidebar-cat-list a { display: flex; justify-content: space-between; font-size: 13px; color: var(--bc-text); text-decoration: none; }
.bc-sidebar-cat-list a:hover { color: var(--bc-primary); }
.bc-sidebar-cat-list .bc-cat-count { color: var(--bc-meta); font-size: 12px; }

/* ── 25. Minimal Reading Single ───────────────────────────── */
.bc-single--minimal .bc-single-wrap { max-width: 720px; margin: 0 auto; }
.bc-single--minimal .bc-article-title { font-size: clamp(24px, 4vw, 36px); }
.bc-single--minimal .bc-content { font-size: 18px; line-height: 1.85; }
.bc-single--minimal .bc-content h2 { font-size: 1.5em; }

/* Reading progress bar */
.bc-progress-bar { position: fixed; top: 0; left: 0; width: 0%; height: 3px; background: var(--bc-primary); z-index: 9999; transition: width .1s linear; pointer-events: none; }

/* ── 26. Sidebar Category Archive ─────────────────────────── */
.bc-archive-with-sidebar { display: grid; grid-template-columns: 1fr var(--bc-sidebar-w); gap: 48px; align-items: start; }

/* ── 27. Focus & Accessibility ────────────────────────────── */
.blogcraft-wrapper a:focus-visible,
.blogcraft-wrapper button:focus-visible { outline: 2px solid var(--bc-primary); outline-offset: 3px; border-radius: 3px; }
.screen-reader-text { clip: rect(1px,1px,1px,1px); position: absolute; height: 1px; overflow: hidden; width: 1px; }

/* ── 28. Utility ──────────────────────────────────────────── */
.bc-divider { border: none; border-top: 1px solid var(--bc-border); margin: 40px 0; }
.bc-spacer { height: var(--bc-gap); }

/* ── 29. Responsive: Tablet (≤1024px) ────────────────────── */
@media (max-width: 1024px) {
  .bc-grid { grid-template-columns: repeat(2, 1fr); }
  .bc-img-grid { grid-template-columns: repeat(2, 1fr); }
  .bc-mag-hero { grid-template-columns: 1fr; }
  .bc-mag-sidebar { flex-direction: row; }
  .bc-mag-sidebar .bc-card { flex-direction: column; }
  .bc-mag-sidebar .bc-card__image-wrap { flex: none; }
  .bc-mag-sidebar .bc-card__image-inner { padding-bottom: 56%; }
  .bc-related__grid { grid-template-columns: repeat(2, 1fr); }
  .bc-single--sidebar .bc-single-layout { grid-template-columns: 1fr; gap: 32px; }
  .bc-article-sidebar { position: static; }
  .bc-archive-with-sidebar { grid-template-columns: 1fr; }
  .bc-single--editorial-wide .bc-wide-hero__body { padding: 48px 24px; }
}

/* ── 30. Responsive: Mobile (≤768px) ─────────────────────── */
@media (max-width: 768px) {
  .bc-grid { grid-template-columns: 1fr; }
  .bc-img-grid { grid-template-columns: 1fr 1fr; }
  .bc-card--featured { flex-direction: column; }
  .bc-card--featured .bc-card__image-wrap { flex: none; }
  .bc-card--featured .bc-card__image-inner { padding-bottom: 56%; }
  .bc-list-card { flex-direction: column; }
  .bc-list-card__image { flex: none; height: 200px; }
  .bc-list-card__body { padding: 18px; }
  .bc-list-card__title { font-size: 17px; }
  .bc-prev-next { grid-template-columns: 1fr; }
  .bc-related__grid { grid-template-columns: 1fr; }
  .bc-author-box { flex-direction: column; }
  .bc-share__buttons { }
  .bc-archive-header { padding: 28px 20px; }
  .bc-archive-header__title { font-size: 28px; }
}

/* ── 31. Responsive: Small Mobile (≤480px) ───────────────── */
@media (max-width: 480px) {
  .bc-img-grid { grid-template-columns: 1fr; }
  .bc-mag-sidebar { flex-direction: column; }
  .bc-archive-wrap { padding: 0 14px 40px; }
  .bc-single-wrap { padding: 24px 14px 60px; }
  .bc-article-title { font-size: 24px; }
  .bc-share__buttons { flex-direction: column; }
  .bc-share-btn { width: 100%; justify-content: center; }
  .bc-pagination__list { gap: 2px; }
  .bc-pagination__item a,
  .bc-pagination__item span { min-width: 34px; height: 34px; font-size: 13px; }
}

/* ── 32. Print ────────────────────────────────────────────── */
@media print {
  .bc-share, .bc-related, .bc-prev-next, .bc-progress-bar, .bc-article-sidebar { display: none !important; }
  .bc-content { font-size: 12pt; line-height: 1.6; color: #000; }
  .bc-article-title { font-size: 22pt; }
  .bc-single--sidebar .bc-single-layout { display: block; }
}

/* ── 33. Reduced Motion ───────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .bc-card, .bc-card__image-inner img, .bc-img-card__image,
  .bc-list-card, .bc-read-more, .bc-share-btn { transition: none !important; }
}
