/* ============================================================
   FONT FACES — self-hosted variable fonts
   ============================================================ */
@font-face {
  font-family: 'Playfair Display';
  src: url('/fonts/PlayfairDisplay-normal-400-900.woff2') format('woff2');
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Playfair Display';
  src: url('/fonts/PlayfairDisplay-italic-400-900.woff2') format('woff2');
  font-weight: 400 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: 'Lora';
  src: url('/fonts/Lora-normal-400-700.woff2') format('woff2');
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Lora';
  src: url('/fonts/Lora-italic-400-700.woff2') format('woff2');
  font-weight: 400 700;
  font-style: italic;
  font-display: swap;
}


/* ============================================================
   SECTION 1: DESIGN TOKENS
   Centralised variables for colors, fonts, and spacing.
   Change values here to restyle the entire site.
   ============================================================ */
:root {
  --color-bg:          #ffffff;
  --color-text:        #2c2c2c;
  --color-text-light:  #666666;
  --color-border:      #e0e0e0;
  --color-accent:      #7A5C00;   /* dark antique gold — links, headings */
  --color-accent-hover:#5A4200;   /* deeper gold — hover state */
  --color-header-bg:   #1C1400;   /* very dark warm brown */
  --color-header-text: #F0DFA0;   /* warm cream gold */
  --color-footer-bg:   #1C1400;
  --color-footer-text: #C8A857;
  --color-card-bg:     #f0ece3;   /* warm off-white card background */

  --font-body:      'Lora', Georgia, 'Times New Roman', serif;
  --font-heading:   'Playfair Display', Georgia, serif;
  --font-ui:        'Helvetica Neue', Arial, sans-serif;
  --font-size-base: 18px;
  --line-height:    1.75;

  --content-width:  900px;    /* max-width for single post body text */
  --site-width:     1200px;   /* max-width for header, grid, and footer */
  --gutter:         24px;
}


/* ============================================================
   SECTION 2: RESET & BASE
   ============================================================ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: var(--font-size-base);
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: var(--line-height);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--color-accent);
  text-decoration: none;
}

a:hover {
  color: var(--color-accent-hover);
  text-decoration: underline;
}


/* ============================================================
   SECTION 2b: DARK MODE
   Override design tokens when [data-theme="dark"] is set on <html>.
   ============================================================ */
[data-theme="dark"] {
  --color-bg:          #141414;
  --color-text:        #c4c4c4;
  --color-text-light:  #777777;
  --color-border:      #2a2a2a;
  --color-card-bg:     #1e1e1e;
  --color-accent:      #C9A227;
  --color-accent-hover:#E8C050;
  --color-heading:     #a5793c;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

[data-theme="dark"] h1,
[data-theme="dark"] h2,
[data-theme="dark"] h3,
[data-theme="dark"] h4,
[data-theme="dark"] h5,
[data-theme="dark"] h6 {
  color: #a5793c;
}

[data-theme="dark"] body {
  background: var(--color-bg);
  color: var(--color-text);
}

[data-theme="dark"] .site-header {
  background: #141414;
  border-bottom-color: rgba(255,255,255,0.12);
}

[data-theme="dark"] .cat-bar {
  background: #141414;
  border-top-color: rgba(255,255,255,0.12);
}

[data-theme="dark"] .featured-grid-wrap {
  background: #1a1400;
}

[data-theme="dark"] .post-content blockquote,
[data-theme="dark"] .post-content .wp-block-pullquote blockquote {
  background: #1e2a35;
  color: var(--color-text-light);
}

[data-theme="dark"] .search-overlay {
  background: rgba(0,0,0,0.92);
}

[data-theme="dark"] .search-box {
  background: #1e1e1e;
  border-color: #333;
}

[data-theme="dark"] .search-input {
  background: #1e1e1e;
  color: var(--color-text);
}

/* Sun icon hidden in light mode; moon hidden in dark mode */
.icon-sun { display: none; }
[data-theme="dark"] .icon-moon { display: none; }
[data-theme="dark"] .icon-sun  { display: block; }

/* ============================================================
   SECTION 3: SITE HEADER
   Sticky at top. Logo on the left, nav links on the far right.
   ============================================================ */
.site-header {
  background: #ffffff;
  border-bottom: 1px solid var(--color-border);
  padding: 12px var(--gutter);
  position: sticky;
  top: 0;
  z-index: 200;
}

.header-inner {
  max-width: var(--site-width);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-logo-link {
  display: block;
  flex-shrink: 0;
}

.site-logo {
  height: 60px;
  width: auto;
  display: block;
}
/* Light theme: show light logo, hide dark logo */
.logo-dark { display: none; }
.logo-light { display: block; }
/* Dark theme: show dark logo, hide light logo */
[data-theme="dark"] .logo-dark  { display: block; }
[data-theme="dark"] .logo-light { display: none; }
@media (max-width: 640px) {
  .site-logo { height: 36px; }
}

.site-nav > ul {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 28px;
  margin: 0;
}

.site-nav a {
  font-family: var(--font-ui);
  font-size: 0.9rem;
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.site-nav a:hover {
  color: var(--color-accent-hover);
  text-decoration: none;
}


/* ============================================================
   SECTION 4: LAYOUT WIDTHS
   --content-width (900px) controls the post body text column.
   --site-width (1200px) controls the outer card grid and header.
   Adjust these two variables to change the overall page width.
   ============================================================ */
.site-main {
  max-width: var(--site-width);
  margin: 0 auto;
  padding: 40px var(--gutter);
}


/* ============================================================
   SECTION 5: HOMEPAGE
   Hero: full-width background image with overlaid title text.
   Pulled edge-to-edge inside site-main by cancelling its padding.
   Below: 3×3 featured article grid (image + caption below).
   ============================================================ */

/* Hero — full-width, bleeds past site-main's side gutter */
.hero-banner {
  margin: -40px calc(-1 * var(--gutter)) 0;
  height: 360px;
  background-color: var(--color-accent);   /* fallback if no image */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

/* Subtle dark veil so white title is always readable */
.hero-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
}

.hero-banner-inner {
  position: relative;
  z-index: 1;
  text-align: center;
  padding: 0 var(--gutter);
}

.hero-title {
  font-family: var(--font-heading);
  font-size: 3rem;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: 0.01em;
  text-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* 3×3 featured grid — full-width within site-main */
.featured-grid-wrap {
  margin: 0 calc(-1 * var(--gutter));      /* edge-to-edge */
  padding: 24px var(--gutter) 0;
  background: #fff;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  max-width: var(--site-width);
  margin: 0 auto;
}

.featured-item {
  display: block;
  color: var(--color-text);
  text-decoration: none;
}

.featured-item-img-wrap {
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--color-border);
  border-radius: 8px;
}

.featured-item-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.3s ease;
}

.featured-item:hover .featured-item-img-wrap img {
  transform: scale(1.04);
}

.featured-item-no-img {
  background: #dde4ec;
}

.featured-item-title {
  font-family: var(--font-heading);
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--color-text);
  margin: 8px 0 0;
  text-align: center;
}

.featured-item:hover .featured-item-title {
  color: var(--color-accent-hover);
}

.more-articles-link {
  max-width: var(--site-width);
  margin: 20px auto 0;
  padding-bottom: 32px;
}

.more-articles-link a {
  font-family: var(--font-ui);
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--color-accent-hover);
  text-decoration: none;
}

.more-articles-link a:hover {
  text-decoration: underline;
}

/* ============================================================
   SPOTLIGHT: rotating featured article above the post grid
   ============================================================ */
.spotlight-wrap {
  margin-top: 20px;
  margin-bottom: 40px;
  position: relative;
}

.spotlight-slide {
  display: none;
}
.spotlight-slide.is-active {
  display: block;
  animation: spotlight-fade 0.5s ease;
}
@keyframes spotlight-fade {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0);   }
}

.spotlight-inner {
  display: flex;
  gap: 32px;
  align-items: center;
  background: var(--color-card-bg);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 16px rgba(0,0,0,0.08);
  text-decoration: none;
  color: var(--color-text);
  transition: box-shadow 0.2s;
}
.spotlight-inner:hover {
  box-shadow: 0 4px 24px rgba(0,0,0,0.14);
  text-decoration: none;
  color: var(--color-text);
}

.spotlight-text {
  flex: 1;
  padding: 32px 32px 32px 40px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.spotlight-cat {
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-accent);
}

.spotlight-title {
  font-family: var(--font-heading);
  font-size: 1.7rem;
  font-weight: 700;
  line-height: 1.25;
  color: var(--color-text);
}
.spotlight-inner:hover .spotlight-title {
  color: var(--color-accent);
}

.spotlight-excerpt {
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--color-text-light);
}

.spotlight-img-wrap {
  flex-shrink: 0;
  width: 580px;
  height: 330px;
  overflow: hidden;
}
.spotlight-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s ease;
}
.spotlight-inner:hover .spotlight-img-wrap img {
  transform: scale(1.03);
}

.spotlight-arrow {
  display: none;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: var(--color-text-light);
  font-size: 2rem;
  line-height: 1;
  padding: 8px 4px;
  cursor: pointer;
  opacity: 0.4;
  transition: opacity 0.2s;
  z-index: 10;
  user-select: none;
}
.spotlight-arrow:hover { opacity: 0.85; }
.spotlight-prev { left: -28px; }
.spotlight-next { right: -28px; }
@media (min-width: 761px) {
  .spotlight-arrow { display: block; }
}

.spotlight-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 14px;
}
.spotlight-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--color-border);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}
.spotlight-dot.is-active {
  background: var(--color-accent);
}

@media (max-width: 760px) {
  .spotlight-inner { flex-direction: column; }
  .spotlight-img-wrap { width: 100%; height: 220px; }
  .spotlight-text { padding: 24px 20px 20px; }
  .spotlight-title { font-size: 1.3rem; }
}
@media (max-width: 640px) {
  .spotlight-wrap { margin-top: 6px; margin-bottom: 24px; }
  .spotlight-img-wrap { height: 180px; }
  .spotlight-text { padding: 16px 16px 14px; gap: 8px; }
  .spotlight-excerpt {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
}

/* Infinite scroll */
.hidden-card { display: none; }
#scroll-sentinel { height: 1px; margin-top: 40px; }

/* Below-hero post grid section */
.post-grid-section {
  margin-top: 40px;
}

.pagination-nav {
  margin-top: 48px;
  text-align: center;
}

.btn-all-posts {
  display: inline-block;
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 600;
  padding: 10px 24px;
  background: var(--color-accent);
  color: #ffffff;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.btn-all-posts:hover {
  background: var(--color-accent-hover);
  color: #ffffff;
  text-decoration: none;
}


/* ============================================================
   SECTION 6: POST GRID
   3-column card grid on wide screens; 2 on tablet; 1 on mobile.
   Change grid-template-columns here to adjust the column count.
   ============================================================ */
.post-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  grid-auto-rows: 400px;
  gap: 32px;
}

@media (max-width: 900px) {
  .post-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .post-grid {
    grid-template-columns: 1fr;
  }
}


/* ============================================================
   SECTION 7: POST CARD
   Card component used in grids. Controls thumbnail aspect ratio,
   title size, and excerpt truncation.
   ============================================================ */
.post-card {
  background: var(--color-card-bg);
  border: none;
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 12px rgba(0,0,0,0.07);
  transition: box-shadow 0.2s, transform 0.2s;
}
.post-card:hover {
  box-shadow: 0 6px 24px rgba(0,0,0,0.13);
  transform: translateY(-2px);
}

.post-card-image-link {
  display: block;
  overflow: hidden;
}

.post-card-image-link {
  flex: 1;
}

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

.post-card-image-link:hover img {
  transform: scale(1.03);
}

.post-card-body {
  padding: 16px 20px 20px;
  height: 200px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.post-card-title {
  font-family: var(--font-heading);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-card-title a {
  color: var(--color-text);
}

.post-card-title a:hover {
  color: var(--color-accent-hover);
  text-decoration: none;
}

.post-card-excerpt {
  font-size: 0.9rem;
  color: var(--color-text-light);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.read-more {
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-accent);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  align-self: flex-start;
}

.read-more:hover {
  color: var(--color-accent-hover);
  text-decoration: none;
}


/* ============================================================
   SECTION 8: POST META
   The date + category line appearing below post titles.
   ============================================================ */
.post-meta {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  color: var(--color-text-light);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.post-categories a {
  background: var(--color-accent);
  color: #ffffff;
  padding: 2px 8px;
  border-radius: 2px;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.post-categories a:hover {
  background: var(--color-accent-hover);
  text-decoration: none;
}


/* ============================================================
   SECTION 9: SINGLE POST LAYOUT
   Layout order: title → full-width image → body text.
   The hero image bleeds edge-to-edge inside site-main.
   Body text is constrained to --content-width (900px).
   Canonical image size for these posts: 1000×672px.
   ============================================================ */
.post-single-inner {
  max-width: var(--content-width);
  margin: 0 auto;
}

.post-header {
  margin-bottom: 28px;
}

.post-title {
  font-family: var(--font-heading);
  font-size: 2.2rem;
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-accent);
  margin-bottom: 12px;
}

/* Full-width hero image — bleeds past the 900px inner column */
.post-hero {
  margin: 0 calc(((var(--content-width) - var(--site-width)) / 2))  28px;
  max-width: var(--site-width);
  overflow: hidden;
}

.post-hero-img {
  width: 100%;
  height: auto;
  max-height: 500px;
  object-fit: cover;
  object-position: center top;
  display: block;
}


/* ============================================================
   SECTION 10: POST CONTENT TYPOGRAPHY
   Controls all HTML elements that appear within the post body.
   Font sizes are relative to the 18px base set in :root.
   ============================================================ */
.post-content p {
  margin-bottom: 1.4em;
}

.post-content h1 {
  /* Some posts use h1 inside content (Gutenberg level:1 headings) */
  font-family: var(--font-heading);
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-accent);
  margin: 2em 0 0.6em;
  line-height: 1.25;
}

.post-content h2 {
  font-family: var(--font-heading);
  font-size: 1.55rem;
  font-weight: 700;
  color: var(--color-accent);
  margin: 2em 0 0.6em;
  line-height: 1.25;
  clear: both;       /* always end floated images before a new section */
}

.post-content h3 {
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--color-accent);
  margin: 1.6em 0 0.5em;
  clear: both;
}

.post-content h4,
.post-content h5,
.post-content h6 {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-accent);
  margin: 1.4em 0 0.4em;
}

/* Images inside post content — all figures centred regardless of align class */
.post-content figure {
  margin: 2em auto;
  display: block;
  text-align: center;
}

.post-content figure img {
  max-width: 100%;
  height: auto;
  border-radius: 3px;
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* Also centre bare <img> tags not inside a figure */
.post-content > p > img,
.post-content > img {
  display: block;
  margin-left: auto;
  margin-right: auto;
  max-width: 100%;
  height: auto;
}

/* All wp-block-image figures: always centre the img regardless of align class */
.post-content .wp-block-image {
  display: flex !important;
  flex-direction: column;
  align-items: center;
  width: 100%;
  float: none !important;
}
.post-content .wp-block-image img {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

/* aligncenter: standard centered image */
.post-content .aligncenter,
.post-content .wp-block-image.aligncenter {
  display: block;
  margin-left: auto;
  margin-right: auto;
}

.post-content .aligncenter img,
.post-content .wp-block-image.aligncenter img {
  margin-left: auto;
  margin-right: auto;
}

/* alignfull / alignwide: fill the content column width */
.post-content .wp-block-image.alignfull,
.post-content .wp-block-image.alignwide,
.post-content .wp-block-columns.alignfull,
.post-content .wp-block-columns.alignwide,
.post-content .alignfull,
.post-content .alignwide,
.post-content .alignnone {
  width: 100%;
  max-width: 100%;
  margin-left: 0;
  margin-right: 0;
}

/* alignleft / alignright: override to centre all images */
.post-content .alignleft,
.post-content .wp-block-image.alignleft {
  float: none;
  display: block;
  margin: 0 auto 16px;
  max-width: 100%;
}

.post-content .alignright,
.post-content .wp-block-image.alignright {
  float: none;
  display: block;
  margin: 0 auto 16px;
  max-width: 100%;
}

/* Captions */
.post-content figcaption,
.post-content .wp-element-caption {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  color: var(--color-text-light);
  font-style: italic;
  margin-top: 8px;
  line-height: 1.4;
  text-align: center;
}

/* ── Blockquotes & pullquotes — unified style ── */
.post-content blockquote,
.post-content .wp-block-pullquote blockquote {
  position: relative;
  background: #f2f6fb;
  border: none;
  border-radius: 4px;
  padding: 1.6em 2em 1.4em 2.2em;
  margin: 2em auto;
  font-style: italic;
  font-size: 1.05rem;
  color: var(--color-text-light);
  text-align: center;
  clear: both;   /* always start below floated images */
}

/* Large decorative opening quote mark */
.post-content blockquote::before,
.post-content .wp-block-pullquote blockquote::before {
  content: '\201C';
  position: absolute;
  top: 0.05em;
  left: 0.18em;
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 3.6em;
  line-height: 1;
  color: #b5cde0;
  font-style: normal;
  pointer-events: none;
}

/* Pullquote wrapper — no extra decoration */
.post-content .wp-block-pullquote {
  border: none;
  margin: 2em 0;
  padding: 0;
}

/* Attribution / cite */
.post-content blockquote cite,
.post-content blockquote footer {
  display: block;
  margin-top: 12px;
  font-style: normal;
  font-size: 0.85rem;
  font-family: var(--font-ui);
  color: var(--color-text-light);
}

/* Lists */
.post-content ul,
.post-content ol {
  margin: 1em 0 1.4em 2em;
}

.post-content li {
  margin-bottom: 0.5em;
  line-height: 1.6;
}

/* Inline links */
.post-content a {
  color: var(--color-accent);
  text-decoration: underline;
}

.post-content a:hover {
  color: var(--color-accent-hover);
}

/* YouTube / iframes */
.post-content .video-embed {
  margin: 2em 0;
  position: relative;
}

.post-content .video-embed iframe {
  width: 100%;
  max-width: 100%;
}

.post-content .wp-block-embed {
  margin: 2em 0;
}

.post-content iframe {
  max-width: 100%;
}

/* Clearfix for floated images */
.post-content::after {
  content: "";
  display: table;
  clear: both;
}

.post-table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.6em 0;
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.post-table thead th {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: var(--color-accent);
  text-align: left;
  padding: 0 16px 10px 0;
  border-bottom: 2px solid var(--color-border);
}
.post-table tbody td {
  padding: 10px 16px 10px 0;
  color: var(--color-text);
  border-bottom: 1px solid var(--color-border);
  vertical-align: top;
}
.post-table tbody tr:last-child td {
  border-bottom: none;
}
.post-table tbody tr:hover td {
  color: var(--color-accent);
}


/* ============================================================
   SECTION 10B: SHARE BAR
   Social share buttons shown between the hero image and article body.
   ============================================================ */
.share-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  max-width: var(--content-width);
  margin: 0 auto 2rem;
  padding: 16px 0;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.share-count-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 56px;
  padding-right: 12px;
  border-right: 1px solid var(--color-border);
  line-height: 1.1;
}

.share-count-number {
  font-family: var(--font-ui);
  font-size: 1.6rem;
  font-weight: 700;
  color: #aaa;
  letter-spacing: -0.02em;
}

.share-count-label {
  font-family: var(--font-ui);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #aaa;
}

.share-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 16px;
  border: none;
  border-radius: 3px;
  font-family: var(--font-ui);
  font-size: 0.85rem;
  font-weight: 600;
  color: #fff;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.15s;
}

.share-btn:hover { opacity: 0.88; color: #fff; }
.share-btn:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}

.share-btn--facebook  { background: #1877f2; }
.share-btn--twitter   { background: #000; }
.share-btn--linkedin  { background: #0077b5; }
.share-btn--copy      { background: #555; }
.share-btn--copied    { background: #2e7d32; }

/* Mobile: stack count above buttons */
@media (max-width: 480px) {
  .share-bar         { flex-direction: column; align-items: flex-start; }
  .share-count-wrap  { flex-direction: row; gap: 6px; align-items: baseline;
                       border-right: none; padding-right: 0; }
  .share-count-label { font-size: 0.75rem; }
}


/* ============================================================
   SECTION 11: POST TAGS
   Tag links shown at the bottom of single posts.
   ============================================================ */
.post-tags {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
  font-family: var(--font-ui);
  font-size: 0.88rem;
}

.tag {
  display: inline-block;
  border: 1px solid var(--color-border);
  padding: 3px 10px;
  border-radius: 2px;
  margin: 4px 4px 4px 0;
  color: var(--color-text-light);
  font-size: 0.82rem;
}

.tag:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
  text-decoration: none;
}


/* ============================================================
   SECTION 12: ARCHIVE / LIST PAGE HEADER
   ============================================================ */
.archive-header {
  margin-bottom: 40px;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--color-accent);
}

.archive-title {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--color-accent);
  text-transform: capitalize;
}

.archive-description {
  margin-top: 12px;
  color: var(--color-text-light);
  font-size: 0.95rem;
}


/* ============================================================
   SECTION 13: PAGINATION
   ============================================================ */
.bnb-pagination {
  margin-top: 56px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 24px;
  font-family: var(--font-ui);
  font-size: 0.875rem;
}

/* Prev / Next text links */
.bnb-page-btn {
  color: var(--color-accent);
  text-decoration: none;
  letter-spacing: 0.04em;
  font-weight: 600;
  transition: color 0.15s;
}

.bnb-page-btn:hover {
  color: var(--color-accent-hover);
  text-decoration: none;
}

.bnb-page-btn.disabled {
  color: var(--color-border);
  cursor: default;
  pointer-events: none;
}

/* Numbered page bubbles */
.bnb-page-numbers {
  display: flex;
  align-items: center;
  gap: 4px;
}

.bnb-page-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  color: var(--color-accent);
  font-weight: 500;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}

.bnb-page-num:hover {
  background: #eef2f7;
  text-decoration: none;
}

.bnb-page-num.active {
  background: var(--color-accent);
  color: #fff;
  font-weight: 700;
  cursor: default;
  pointer-events: none;
}


/* ============================================================
   SECTION 14: LEGAL BAR (sticky footer, desktop only)
   ============================================================ */
.legal-bar {
  display: none;
}
@media (min-width: 641px) {
  .legal-bar {
    display: block;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 300;
    background: #1e1e1e;
    border-top: 1px solid rgba(255,255,255,0.07);
  }
}

.legal-bar-inner {
  max-width: var(--site-width);
  margin: 0 auto;
  padding: 0 var(--gutter);
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-ui);
  font-size: 0.72rem;
}

.legal-bar-copy {
  color: rgba(255,255,255,0.35);
}

.legal-bar-nav {
  display: flex;
  gap: 20px;
}
.legal-bar-nav a {
  color: rgba(255,255,255,0.35);
  text-decoration: none;
  transition: color 0.15s;
}
.legal-bar-nav a:hover {
  color: rgba(255,255,255,0.75);
  text-decoration: none;
}

/* Lift page content above the sticky legal bar */
.site-main {
  padding-bottom: calc(36px + 40px);
}


/* ============================================================
   SECTION 15A: MOBILE HAMBURGER MENU
   The toggle button is hidden on desktop and shown on mobile.
   The nav is always visible on desktop; hidden/shown on mobile.
   ============================================================ */

/* Hamburger button — hidden on desktop */
.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  padding: 4px;
  background: none;
  border: none;
  cursor: pointer;
  flex-shrink: 0;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--color-text);
  border-radius: 2px;
  transition: opacity 0.2s, transform 0.2s;
}

@media (max-width: 640px) {
  /* Show hamburger */
  .nav-toggle {
    display: flex;
  }

  /* Hide nav by default; drop down when .is-open */
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-bg);
    border-top: 1px solid var(--color-border);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    z-index: 100;
  }

  .site-nav.is-open {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    gap: 0;
    padding: 8px 0;
  }

  .site-nav li a {
    display: block;
    padding: 12px var(--gutter);
    font-size: 1rem;
    border-bottom: 1px solid var(--color-border);
  }

  .site-nav li:last-child a {
    border-bottom: none;
  }
}

/* ============================================================
   SECTION 14b: MOBILE BOTTOM SHEET
   ============================================================ */
.bottom-sheet {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 500;
}
@media (max-width: 640px) {
  .bottom-sheet { display: block; pointer-events: none; }
  .bottom-sheet.is-open { pointer-events: auto; }
}

.bottom-sheet-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0);
  transition: background 0.3s ease;
}
.bottom-sheet.is-open .bottom-sheet-overlay {
  background: rgba(0, 0, 0, 0.45);
}

.bottom-sheet-panel {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--color-card-bg);
  border-radius: 16px 16px 0 0;
  padding: 12px 0 32px;
  transform: translateY(100%);
  transition: transform 0.32s cubic-bezier(0.32, 0.72, 0, 1);
  box-shadow: 0 -4px 32px rgba(0, 0, 0, 0.18);
}
.bottom-sheet.is-open .bottom-sheet-panel {
  transform: translateY(0);
}

.bottom-sheet-handle {
  width: 36px;
  height: 4px;
  border-radius: 2px;
  background: var(--color-border);
  margin: 0 auto 20px;
}

.bottom-sheet-nav {
  display: flex;
  flex-direction: column;
}
.bottom-sheet-nav a {
  padding: 14px 28px;
  font-family: var(--font-ui);
  font-size: 1rem;
  color: var(--color-text);
  text-decoration: none;
  border-bottom: 1px solid var(--color-border);
}
.bottom-sheet-nav a:last-child {
  border-bottom: none;
}
.bottom-sheet-nav a:hover {
  color: var(--color-accent);
  text-decoration: none;
}

/* ============================================================
   SECTION 15: RESPONSIVE ADJUSTMENTS & UTILITIES
   ============================================================ */
@media (max-width: 768px) {
  .post-title {
    font-size: 2.2rem;
  }

  .site-title {
    font-size: 1.4rem;
  }

  .hero-banner {
    height: 260px;
  }

  .hero-title {
    font-size: 2rem;
  }

  .featured-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  /* Single post hero: cancel the bleed on narrow screens */
  .post-hero {
    margin-left: 0;
    margin-right: 0;
  }

  /* alignleft/right already centred globally — ensure full width on mobile */
  .post-content .alignleft,
  .post-content .alignright,
  .post-content .wp-block-image.alignleft,
  .post-content .wp-block-image.alignright {
    max-width: 100%;
    margin: 2em auto;
  }

  /* alignfull/wide already constrained in main rule */
}

@media (max-width: 480px) {
  .site-nav ul {
    flex-wrap: wrap;
    gap: 12px;
  }

  .post-title {
    font-size: 2.2rem;
  }

  .hero-banner {
    height: 200px;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .featured-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Visually hidden (accessibility) */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ============================================================
   EXPAND SHORTCODE
   Collapsible block for embedded content (Google Maps, etc.)
   ============================================================ */
.expand-block {
  margin: 1.5rem 0;
  max-width: var(--content-width);
}

.expand-block summary {
  list-style: none;
  cursor: pointer;
  color: #1a6bbf;
  font-family: var(--font-ui);
  font-size: 0.95rem;
  font-weight: bold;
  display: block;
  text-align: center;
  text-decoration: underline;
}

.expand-block summary::-webkit-details-marker { display: none; }
.expand-block summary::marker { display: none; }

.expand-block summary:hover {
  color: #c0392b;
}

.expand-block .expand-text-less { display: none; }
.expand-block[open] .expand-text-more { display: none; }
.expand-block[open] .expand-text-less { display: inline; }

.expand-content {
  margin-top: 1rem;
}

.expand-content iframe {
  width: 100%;
  max-width: var(--content-width);
  height: 450px;
  border: 0;
  display: block;
}


/* 404 page */
.error-page {
  text-align: center;
  padding: 80px 24px;
}

.error-page h1 {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  color: var(--color-accent);
  margin-bottom: 16px;
}

.error-page p {
  color: var(--color-text-light);
  margin-bottom: 24px;
}

.error-page a {
  font-family: var(--font-ui);
  font-weight: 600;
}


/* ============================================================
   SECTION 16: HEADER RIGHT GROUP + SEARCH
   ============================================================ */

/* Groups nav + search icon + hamburger in a row */
/* Desktop category dropdown */
.has-dropdown {
  position: relative;
}

.nav-dropdown-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--font-ui);
  font-size: 0.9rem;
  color: var(--color-text);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 0;
}
.nav-dropdown-toggle:hover { color: var(--color-accent-hover); }

.dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--color-card-bg);
  border: 1px solid var(--color-border);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  list-style: none;
  min-width: 190px;
  padding: 8px 0;
  z-index: 300;
}
.dropdown-menu li a {
  display: block;
  padding: 9px 20px;
  font-family: var(--font-ui);
  font-size: 0.88rem;
  color: var(--color-text);
  text-decoration: none;
  white-space: nowrap;
}
.dropdown-menu li a:hover {
  background: var(--color-accent);
  color: #fff;
  text-decoration: none;
}
.has-dropdown.is-open .dropdown-menu { display: block; }

/* Mobile category pill bar — persistent below header, hidden on desktop */
.cat-bar {
  display: none;
  border-top: 1px solid var(--color-border);
  background: #ffffff;
  overflow: hidden;
  margin-top: 10px;
  margin-bottom: -10px;
}

@media (max-width: 640px) {
  .cat-bar { display: block; }
}

.cat-bar-inner {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  overflow-x: scroll;
  overflow-y: hidden;
  scrollbar-width: none;
  -ms-overflow-style: none;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  box-sizing: border-box;
}
.cat-bar-inner::-webkit-scrollbar { display: none; }
.cat-pill {
  flex: 0 0 auto;
  padding: 3px 10px;
  border-radius: 12px;
  background: var(--color-card-bg);
  border: 1px solid var(--color-border);
  font-family: var(--font-ui);
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--color-text);
  text-decoration: none;
  white-space: nowrap;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.cat-pill:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #fff;
  text-decoration: none;
}
.cat-pill:hover {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #fff;
  text-decoration: none;
}

@media (max-width: 640px) {
  .has-dropdown .dropdown-menu,
  .nav-dropdown-toggle svg { display: none; }
}

.theme-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text);
  padding: 4px;
  display: flex;
  align-items: center;
  opacity: 0.7;
}
.theme-toggle:hover { opacity: 1; }

.header-right {
  display: flex;
  align-items: center;
  gap: 20px;
}

/* Search toggle icon button */
.search-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  cursor: pointer;
  color: var(--color-text);
  padding: 4px;
  flex-shrink: 0;
}

.search-toggle:hover {
  color: var(--color-accent-hover);
}

/* Full-screen search overlay */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 200;
  padding: 60px var(--gutter) 40px;
  overflow-y: auto;
}

.search-overlay.is-open {
  display: block;
}

/* Input row */
.search-box {
  max-width: 640px;
  margin: 0 auto 24px;
  display: flex;
  align-items: center;
  gap: 12px;
  background: #ffffff;
  border-radius: 6px;
  padding: 10px 16px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.25);
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-family: var(--font-ui);
  font-size: 1.1rem;
  color: var(--color-text);
  background: transparent;
}

.search-input::placeholder {
  color: #aaa;
}

.search-close {
  background: none;
  border: none;
  font-size: 1.2rem;
  color: var(--color-text-light);
  cursor: pointer;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
}

.search-close:hover {
  color: var(--color-accent-hover);
}

/* Results list */
.search-results {
  max-width: 640px;
  margin: 0 auto;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-result-link {
  display: block;
  background: #ffffff;
  border-radius: 5px;
  padding: 14px 18px;
  text-decoration: none;
  color: var(--color-text);
  transition: box-shadow 0.15s;
}

.search-result-link:hover {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.15);
  text-decoration: none;
  color: var(--color-text);
}

.search-result-title {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 700;
  color: var(--color-accent);
  display: block;
  margin-bottom: 4px;
}

.search-result-cats {
  margin-bottom: 4px;
}

.search-cat {
  font-family: var(--font-ui);
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  background: var(--color-accent);
  color: #fff;
  padding: 1px 6px;
  border-radius: 2px;
  margin-right: 4px;
}

.search-result-summary {
  font-size: 0.88rem;
  color: var(--color-text-light);
  margin: 0;
  line-height: 1.5;
}

.search-no-results {
  background: #ffffff;
  border-radius: 5px;
  padding: 16px 18px;
  font-family: var(--font-ui);
  font-size: 0.95rem;
  color: var(--color-text-light);
  text-align: center;
}

/* On mobile, hamburger sits after search icon */
@media (max-width: 640px) {
  .search-overlay {
    padding-top: 80px;
  }
}

/* ============================================================
   SECTION 16: CAROUSEL
   ============================================================ */
.bnb-carousel {
  position: relative;
  margin: 2em 0;
}

.bnb-carousel-viewport {
  overflow: hidden;
  border-radius: 4px;
}

.bnb-carousel-track {
  display: flex;
  gap: 16px;
  transition: transform 0.4s ease;
  will-change: transform;
  align-items: stretch;
}

/* Each slide is a <figure> */
.bnb-carousel-track > figure {
  flex-shrink: 0;
  margin: 0;
  position: relative;
  overflow: hidden;
  border-radius: 4px;
}

/* Square aspect ratio via padding trick */
.bnb-carousel-track > figure::before {
  content: '';
  display: block;
  padding-top: 100%;
}

.bnb-carousel-track > figure img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  margin: 0;
}

/* Caption overlaid at bottom */
.bnb-carousel-track > figure figcaption {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  font-family: var(--font-ui);
  font-size: 0.75rem;
  font-style: normal;
  padding: 8px 12px;
  margin: 0;
  line-height: 1.4;
  text-align: left;
}

/* Prev / next buttons */
.bnb-carousel-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  border: none;
  width: 40px;
  height: 40px;
  font-size: 1.8rem;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
  transition: background 0.2s;
}

.bnb-carousel-btn:hover {
  background: rgba(0, 0, 0, 0.7);
}

.bnb-carousel-btn:disabled {
  opacity: 0.3;
  cursor: default;
}

.bnb-carousel-prev { left: 8px; }
.bnb-carousel-next { right: 8px; }

/* Dot indicators */
.bnb-carousel-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 12px;
}

.bnb-carousel-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: none;
  background: var(--color-border);
  cursor: pointer;
  padding: 0;
  transition: background 0.2s;
}

.bnb-carousel-dot.active {
  background: var(--color-accent);
}

/* ============================================================
   SECTION 17: INSTAGRAM GRID
   ============================================================ */
.instagram-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 2em 0;
}

.instagram-row .instagram-media {
  width: 100% !important;
  min-width: unset !important;
  max-width: 100% !important;
}

@media (max-width: 640px) {
  .instagram-row {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   SECTION 18: AFFILIATE GRID
   ============================================================ */
.affiliate-section {
  background: #d3d3d3;
  padding: 24px;
  margin: 2em 0;
}

.affiliate-disclosure {
  font-family: var(--font-ui);
  font-size: 0.82rem;
  color: var(--color-text-light);
  margin: 0 0 20px;
  text-align: center;
}

.affiliate-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.affiliate-item {
  text-align: center;
}

.affiliate-item a {
  text-decoration: none;
  color: var(--color-text);
}

.affiliate-item a:hover {
  color: var(--color-accent-hover);
}

.affiliate-item img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  display: block;
  margin: 0 auto;
}

.affiliate-item-title {
  font-family: var(--font-ui);
  font-weight: 700;
  text-transform: capitalize;
  font-size: 0.9rem;
  margin: 10px 0 8px;
  line-height: 1.3;
}

@media (max-width: 640px) {
  .affiliate-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   SECTION 19: TAXONOMY TERM GRID (categories, tags)
   ============================================================ */
.term-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 1.5em;
}

.term-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 22px;
  background: #fff;
  border: 1px solid var(--color-border);
  border-left: 3px solid transparent;
  border-radius: 4px;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s, border-left-color 0.15s;
}

.term-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.09);
  border-left-color: var(--color-accent);
  text-decoration: none;
}

.term-card-name {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--color-accent);
}

.term-card-count {
  font-family: var(--font-ui);
  font-size: 0.78rem;
  color: var(--color-text-light);
  background: #f0f4f8;
  padding: 3px 10px;
  border-radius: 12px;
  white-space: nowrap;
  flex-shrink: 0;
}

@media (max-width: 768px) {
  .term-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .term-grid {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   SECTION 20: SCROLL TO TOP
   ============================================================ */
.scroll-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 40px;
  height: 40px;
  background: #4a4a4a;
  color: #fff;
  border: none;
  border-radius: 3px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 999;
  transition: background 0.2s, opacity 0.2s;
  opacity: 0.85;
}

.scroll-top:hover {
  background: #2c2c2c;
  opacity: 1;
}

.scroll-top svg {
  width: 18px;
  height: 18px;
}

.scroll-top[hidden] {
  display: none;
}

/* ============================================================
   SECTION 20: POLL WIDGET
   ============================================================ */
.bnb-poll {
  border: 2px solid #2e86c1;
  border-radius: 4px;
  background: #f4f9ff;
  max-width: 580px;
  margin: 1.8em auto;
  font-family: var(--font-ui);
  overflow: hidden;
}

.bnb-poll-question {
  color: #1a5276;
  font-weight: 700;
  font-size: 1rem;
  text-align: center;
  margin: 0;
  padding: 16px 20px 12px;
  border-bottom: 1px solid #cde0f0;
}

.bnb-poll-options {
  padding: 12px 20px;
}

.bnb-poll-option {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid #a8cde8;
  border-radius: 3px;
  padding: 10px 14px;
  margin-bottom: 8px;
  cursor: pointer;
  background: #fff;
  transition: background 0.15s, border-color 0.15s;
}

.bnb-poll-option:last-child {
  margin-bottom: 0;
}

.bnb-poll-option:hover {
  background: #e8f4fc;
  border-color: #2e86c1;
}

.bnb-poll-option input[type="radio"] {
  accent-color: #1a5276;
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  cursor: pointer;
}

.bnb-poll-opt-text {
  font-size: 0.95rem;
  color: var(--color-text);
}

/* Bottom footer: Vote button + count */
.bnb-poll-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 12px 20px;
  border-top: 1px solid #cde0f0;
  position: relative;
}

.bnb-poll-vote-btn {
  background: #1a5276;
  color: #fff;
  border: none;
  border-radius: 3px;
  padding: 8px 28px;
  font-family: var(--font-ui);
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.bnb-poll-vote-btn:hover {
  background: #154360;
}

.bnb-poll-count {
  position: absolute;
  right: 16px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: #1a3a5c;
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: 3px;
}

.bnb-poll-icon {
  width: 16px;
  height: 12px;
  flex-shrink: 0;
}

/* nudge animation when no option selected */
.bnb-poll-options--nudge .bnb-poll-option {
  border-color: #c0392b;
  animation: poll-nudge 0.15s ease 2;
}

@keyframes poll-nudge {
  0%, 100% { transform: translateX(0); }
  50%       { transform: translateX(4px); }
}

/* Results view */
.bnb-poll-results {
  padding: 8px 20px 16px;
}

.bnb-poll-result-row {
  margin-bottom: 14px;
}

.bnb-poll-result-row:last-child {
  margin-bottom: 0;
}

.bnb-poll-result-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 5px;
}

.bnb-poll-result-label {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 0.9rem;
  color: var(--color-text);
}

.bnb-poll-result-row.chosen .bnb-poll-result-label {
  font-weight: 600;
  color: #1a5276;
}

.bnb-poll-check-icon {
  width: 13px;
  height: 10px;
  color: #1a5276;
  flex-shrink: 0;
}

.bnb-poll-result-count {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  margin-left: 12px;
}

.bnb-poll-bar-track {
  height: 22px;
  background: #d5e8f5;
  border-radius: 2px;
  overflow: hidden;
}

.bnb-poll-reset {
  display: block;
  margin: 12px auto 0;
  background: none;
  border: none;
  font-family: var(--font-ui);
  font-size: 0.78rem;
  color: #2e86c1;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}

.bnb-poll-reset:hover {
  color: #154360;
}

.bnb-poll-bar-fill {
  height: 100%;
  background: #1a5276;
  border-radius: 2px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 7px;
  font-size: 0.72rem;
  font-weight: 700;
  color: #fff;
  min-width: 32px;
  transition: width 0.55s ease-out;
  white-space: nowrap;
}

/* ============================================================
   SECTION 21: MEDIA & TEXT SIDE-BY-SIDE BLOCK
   ============================================================ */
.media-text-block {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: center;
  margin: 1.5em 0 2em;
}

.media-text-image {
  margin: 0;
}

.media-text-image img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
}

/* blockquote inside media-text grid: clear: both doesn't apply in grid */
.media-text-content blockquote {
  clear: none;
  margin: 1em 0;
}

.media-text-content .modal-trigger {
  margin-left: 0;      /* left-align with text rather than centering */
}

@media (max-width: 640px) {
  .media-text-block {
    grid-template-columns: 1fr;
  }
}

/* ============================================================
   SECTION 22: MODAL DIALOG
   ============================================================ */
.modal-trigger {
  display: block;
  margin: 1em auto 0;
  background: none;
  border: none;
  font-family: var(--font-ui);
  font-size: 0.95rem;
  font-weight: 700;
  color: #1a6bbf;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}

.modal-trigger:hover {
  color: #154a8a;
}

/* ============================================================
   IMAGE PROTECTION
   Transparent overlay intercepts right-click / drag on images.
   The <img> itself gets pointer-events:none so all mouse events
   hit the shield instead, preventing "Open image in new tab".
   ============================================================ */
.img-protect-wrap {
  position: relative;
  display: inline-block; /* shrink-wrap the image */
}

/* figures are already block-level */
figure.img-protect-wrap {
  display: block;
}

.post-content img {
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
}

.img-protect-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  cursor: default;
  /* transparent — purely an event sink */
}

/* ============================================================
   Div-based modal overlay */
.bnb-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(2px);
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
  box-sizing: border-box;
}

.bnb-modal-overlay.is-open {
  display: flex;
}

.bnb-modal-box {
  position: relative;
  background: var(--color-bg);
  border-radius: 6px;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.35);
  max-width: 540px;
  width: 100%;
  max-height: 85vh;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 40px 44px 36px;
  box-sizing: border-box;
}
[data-theme="dark"] .bnb-modal-box {
  background: #1e1e1e;
  color: var(--color-text);
}

.bnb-modal-close {
  position: absolute;
  top: 14px;
  right: 18px;
  background: none;
  border: none;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  color: var(--color-text-light);
  padding: 4px 8px;
  transition: color 0.15s;
}

.bnb-modal-close:hover {
  color: var(--color-text);
}

.bnb-modal-title {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  color: var(--color-accent);
  margin: 0 0 4px;
  clear: none;
}

.bnb-modal-subtitle {
  font-family: var(--font-ui);
  font-style: italic;
  color: var(--color-text-light);
  font-size: 0.9rem;
  margin: 0 0 24px;
}

.bnb-modal-body {
  font-family: var(--font-body);
  font-style: italic;
  line-height: 1.9;
  color: var(--color-text);
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}

.bnb-modal-body p {
  margin: 0 0 1.2em;
  text-align: center;
}

.bnb-modal-body p:last-child {
  margin-bottom: 0;
}
