/* =============================================
   Lumen Theme — v1.0
   Geometric sans · Teal accent · Warm + Dark
   ============================================= */

/* ---------- Reset & Base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Brand accent — overridable via theme settings (maps to --red for compat) */
  --red:         #0891b2;
  --red-dark:    #0e7490;

  /* Dark surfaces */
  --black:       #1c1917;
  --charcoal:    #18181b;

  /* Neutral scale */
  --ink:         #1c1917;
  --mid:         #57534e;
  --muted:       #a8a29e;
  --subtle:      #d4cfc8;
  --border:      #e7e2dc;
  --border-mid:  #d6cfc6;

  /* Backgrounds */
  --bg:          #f8f5f0;
  --bg-card:     #ffffff;
  --bg-alt:      #f0ebe3;
  --white:       #ffffff;

  /* Layout */
  --max-w:       1200px;

  /* Typography */
  --font-head:   'Plus Jakarta Sans', sans-serif;
  --font-ui:     'Plus Jakarta Sans', sans-serif;

  /* Elevation */
  --shadow-sm:   0 1px 4px rgba(0,0,0,.06), 0 1px 2px rgba(0,0,0,.04);
  --shadow-md:   0 8px 32px rgba(0,0,0,.09), 0 2px 6px rgba(0,0,0,.05);
  --shadow-hover: 0 22px 52px rgba(0,0,0,.11), 0 6px 14px rgba(0,0,0,.06);

  /* Motion */
  --transition:  .22s cubic-bezier(.4,0,.2,1);
  --transition-bounce: .28s cubic-bezier(.34,1.56,.64,1);

  /* Derived accent helpers */
  --accent-glow:   rgba(8,145,178,.16);
  --accent-border: rgba(8,145,178,.28);

  /* Geometry */
  --radius:    12px;
  --radius-sm: 7px;
}

html { scroll-behavior: smooth; }

/* ---------- Reading Progress Bar ---------- */
#reading-progress {
  position: fixed; top: 0; left: 0;
  width: 0%; height: 3px;
  background: var(--red);
  z-index: 9999;
  transition: width .08s linear;
  pointer-events: none;
}

body {
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--ink);
  font-size: 15px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--red); }

/* Prevent hover color on structural anchors */
.post-row-image,
.post-row-image:hover,
.related-card a,
.related-card a:hover { color: inherit; }

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

/* ---------- Top Bar ---------- */
.top-bar {
  background: var(--charcoal);
  padding: 9px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11px;
  letter-spacing: .055em;
  color: rgba(255,255,255,.5);
  position: sticky;
  top: 0;
  z-index: 200;
}
.top-bar .top-bar-right {
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--red);
  font-size: 10.5px;
}
.top-bar a { color: rgba(255,255,255,.5); transition: color var(--transition); }
.top-bar a:hover { color: #fff; }

/* ---------- Site Header ---------- */
.site-header {
  position: sticky;
  top: 37px; /* sits directly below top-bar */
  z-index: 100;
  background: transparent;
  transition: background .28s cubic-bezier(.4,0,.2,1),
              box-shadow .28s cubic-bezier(.4,0,.2,1),
              backdrop-filter .28s;
}
.site-header.scrolled {
  background: rgba(248,245,240,.90);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  box-shadow: 0 1px 0 var(--border);
}
.site-header-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 32px;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
}

/* Logo */
.site-logo { display: flex; align-items: center; height: 48px; }
.site-logo img { height: 48px; width: auto; display: block; }
.site-logo .logo-text {
  font-family: var(--font-head);
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -.035em;
  color: #fff;
  line-height: 1;
  transition: color var(--transition);
}
.site-header.scrolled .site-logo .logo-text { color: var(--black); }
.logo-dot { color: var(--red); }

/* ---------- Primary Nav ---------- */
.primary-nav { display: flex; align-items: center; gap: 2px; }
.primary-nav a {
  font-family: var(--font-ui);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .025em;
  color: rgba(255,255,255,.82);
  padding: 7px 13px;
  border-radius: var(--radius-sm);
  transition: color var(--transition), background var(--transition);
}
.site-header.scrolled .primary-nav a { color: var(--mid); }
.primary-nav a:hover {
  color: var(--red) !important;
  background: var(--accent-glow);
}
.primary-nav a.active {
  background: var(--red);
  color: var(--white) !important;
}

.hamburger {
  display: none;
  background: none; border: none; cursor: pointer;
  flex-direction: column; gap: 5px; padding: 4px;
  color: rgba(255,255,255,.85);
}
.hamburger span {
  display: block; width: 20px; height: 2px;
  background: currentColor; border-radius: 2px;
  transition: transform .3s;
}
.site-header.scrolled .hamburger { color: var(--ink); }

/* ---------- Header Actions ---------- */
.header-actions { display: flex; align-items: center; gap: 10px; }

/* ---------- Search Toggle ---------- */
.search-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  height: 34px; padding: 0 13px;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: var(--radius-sm);
  background: transparent; color: rgba(255,255,255,.8);
  font-family: var(--font-ui); font-size: 12px; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
  cursor: pointer; flex-shrink: 0;
  transition: background var(--transition), color var(--transition),
              border-color var(--transition);
}
.site-header.scrolled .search-toggle {
  border-color: var(--border); color: var(--mid);
}
.search-toggle:hover,
.search-toggle.active {
  background: var(--red); border-color: var(--red); color: #fff;
}
.search-toggle-icon { flex-shrink: 0; }
.search-toggle-text { display: inline-block; }

/* ---------- Search Dropdown ---------- */
.search-dropdown {
  position: sticky;
  top: 109px; /* topbar 37 + header 72 */
  z-index: 98;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 16px 40px rgba(0,0,0,.10);
  opacity: 0; transform: translateY(-10px);
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
}
.search-dropdown.open {
  opacity: 1; transform: translateY(0); pointer-events: auto;
}
.search-dropdown-form {
  display: flex; align-items: center; gap: 10px; padding: 16px 0;
}
.search-dropdown-input {
  flex: 1; height: 46px; padding: 0 18px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-family: var(--font-ui); font-size: 15px;
  color: var(--ink); background: var(--bg);
  outline: none; -webkit-appearance: none;
  transition: border-color var(--transition);
}
.search-dropdown-input:focus { border-color: var(--red); background: var(--white); }
.search-dropdown-input::placeholder { color: var(--subtle); }
.search-dropdown-btn {
  height: 46px; padding: 0 24px;
  background: var(--red); color: #fff;
  font-family: var(--font-ui); font-size: 12px; font-weight: 700;
  letter-spacing: .07em; text-transform: uppercase;
  border: none; border-radius: var(--radius-sm);
  cursor: pointer; flex-shrink: 0;
  transition: background var(--transition);
}
.search-dropdown-btn:hover { background: var(--red-dark); }

/* ---------- Search Page ---------- */
.search-page-form { display: flex; gap: 10px; padding: 24px 0 8px; }
.search-page-input {
  flex: 1; height: 48px; padding: 0 18px;
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  font-family: var(--font-ui); font-size: 15px; color: var(--ink);
  background: var(--white); outline: none; -webkit-appearance: none;
  transition: border-color var(--transition);
}
.search-page-input:focus { border-color: var(--red); }
.search-page-input::placeholder { color: var(--subtle); }
.search-page-btn {
  height: 48px; padding: 0 28px;
  background: var(--red); color: #fff;
  font-family: var(--font-ui); font-size: 12px; font-weight: 700;
  letter-spacing: .07em; text-transform: uppercase;
  border: none; border-radius: var(--radius-sm); cursor: pointer; flex-shrink: 0;
  transition: background var(--transition);
}
.search-page-btn:hover { background: var(--red-dark); }

/* ---------- Wrapper ---------- */
.wrapper { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }

/* ---------- Homepage Hero ---------- */
.site-hero {
  position: relative;
  display: block;
  width: 100%;
  height: 700px;
  background: var(--charcoal);
  overflow: hidden;
  isolation: isolate;
  /* Slide under the sticky header via negative margin */
  margin-top: -72px;
  z-index: 1;
}

.site-hero--color {
  background: linear-gradient(160deg, #061428 0%, #0c2340 50%, #071830 100%);
}
.site-hero--video { background: var(--charcoal); }

.site-hero-video {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: cover; display: block; pointer-events: none;
  transition: transform 6s cubic-bezier(0,0,.2,1);
}
a.site-hero--linked:hover .site-hero-video { transform: scale(1.04); }

.site-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(6,9,16,.92) 0%, rgba(6,9,16,.32) 55%, rgba(6,9,16,.1) 100%);
  transition: background .25s;
}
a.site-hero--linked:hover .site-hero-overlay {
  background: linear-gradient(to top, rgba(6,9,16,.96) 0%, rgba(6,9,16,.42) 55%, rgba(6,9,16,.14) 100%);
}

.site-hero-inner {
  position: absolute; inset: 0; z-index: 2;
  display: flex; align-items: flex-end; padding-bottom: 60px;
}
.site-hero-text-box {
  max-width: var(--max-w); width: 100%; margin: 0 auto; padding: 0 32px;
}

/* Hero category pill */
.site-hero-category-pill {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 10.5px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: var(--red);
  background: rgba(8,145,178,.16); border: 1px solid rgba(8,145,178,.28);
  padding: 5px 11px; border-radius: 4px; margin-bottom: 16px;
}

.site-hero-title {
  font-size: clamp(28px, 4.2vw, 52px);
  font-weight: 800; line-height: 1.08;
  color: #fff; letter-spacing: -.025em;
  margin: 0 0 14px; text-wrap: pretty;
}
.site-hero-subtitle {
  font-size: 16px; font-weight: 400;
  color: rgba(255,255,255,.68);
  margin: 0 0 28px; line-height: 1.65;
  max-width: 580px;
}
.site-hero-custom-text {
  font-size: 28px; font-weight: 700; color: var(--white);
  line-height: 1.3; word-break: break-word;
}
.site-hero-rule {
  width: 36px; height: 3px;
  background: var(--red); border-radius: 2px; margin: 10px 0 0;
}
.site-hero-cta {
  display: inline-flex; align-items: center; gap: 9px;
  height: 48px; padding: 0 24px;
  background: var(--red); color: #fff;
  font-size: 13px; font-weight: 700; letter-spacing: .05em;
  border-radius: var(--radius-sm);
  transition: background var(--transition), transform .2s var(--transition);
}
.site-hero-cta:hover { background: var(--red-dark); color: #fff; transform: translateY(-2px); }

/* ---------- Index / Category Bar ---------- */
.index-hero {
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  padding: 14px 0;
}
.index-hero .wrapper { display: flex; align-items: center; gap: 14px; }
.index-hero-accent {
  width: 4px; height: 28px;
  background: var(--red); border-radius: 2px; flex-shrink: 0;
}
.index-hero-text { flex: 1; }
.index-hero-title {
  font-size: clamp(18px, 2.5vw, 26px);
  font-weight: 800; letter-spacing: -.02em; color: var(--black); line-height: 1;
}
.index-hero-sub { font-size: 11px; color: var(--subtle); margin-top: 3px; font-weight: 500; }
.index-hero-line { flex: 1; height: 1px; background: var(--border); }
.index-hero-back {
  font-size: 12px; font-weight: 600; color: var(--muted); letter-spacing: .04em;
  transition: color var(--transition); white-space: nowrap;
}
.index-hero-back:hover { color: var(--red); }

/* ---------- Post Listing ---------- */
.post-listing {
  padding: 32px 0 16px;
  display: flex; flex-direction: column; gap: 16px;
}

.post-row {
  display: grid;
  grid-template-columns: 310px 1fr;
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  transition: box-shadow var(--transition), transform var(--transition),
              border-color var(--transition);
  will-change: transform;
}
.post-row:hover {
  box-shadow: var(--shadow-hover);
  transform: translateY(-5px);
  border-color: var(--border-mid);
}

/* Thumbnail */
.post-row-image {
  display: block; position: relative;
  overflow: hidden; height: 192px;
  background: var(--bg-alt); flex-shrink: 0;
}
.post-row-image img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .5s cubic-bezier(.4,0,.2,1);
}
.post-row:hover .post-row-image img { transform: scale(1.07); }

.post-row-cat-strip {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: var(--red); padding: 7px 14px;
}
.post-row-cat-strip span {
  font-size: 9.5px; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase; color: #fff;
}

.post-row-image-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-alt); color: var(--subtle);
  font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
}

/* Content */
.post-row-content {
  padding: 24px 28px;
  display: flex; flex-direction: column;
  justify-content: center; gap: 9px;
}
.post-row-meta {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: var(--subtle);
}
.post-row-meta strong { color: var(--mid); font-weight: 600; }
.meta-sep { width: 1px; height: 10px; background: var(--border-mid); flex-shrink: 0; }

.post-row-title {
  font-size: clamp(17px, 2vw, 21px);
  font-weight: 700; letter-spacing: -.015em;
  color: var(--black); line-height: 1.28; text-wrap: pretty;
}
.post-row-title a { transition: color var(--transition); }
.post-row-title a:hover,
.post-row:hover .post-row-title a { color: var(--red); }

.post-row-excerpt {
  font-size: 14px; color: var(--mid); line-height: 1.68;
  display: -webkit-box; -webkit-line-clamp: 2;
  -webkit-box-orient: vertical; overflow: hidden;
}

.post-row-readmore {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 11.5px; font-weight: 700; letter-spacing: .08em;
  text-transform: uppercase; color: var(--red);
  align-self: flex-start; transition: gap var(--transition);
}
.post-row-readmore svg { transition: transform var(--transition); }
.post-row:hover .post-row-readmore { gap: 9px; }
.post-row:hover .post-row-readmore svg { transform: translateX(3px); }

.no-posts {
  font-size: 14px; color: var(--muted); padding: 80px 0; text-align: center;
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-sm);
}

/* ---------- Post Listing — 3-col grid ---------- */
.post-listing--grid_3col {
  display: grid; grid-template-columns: repeat(3,1fr);
  gap: 20px; padding: 32px 0 16px;
}
.post-listing--grid_3col .post-row {
  grid-template-columns: 1fr; grid-template-rows: auto 1fr;
}
.post-listing--grid_3col .post-row-image { height: 200px; }
.post-listing--grid_3col .post-row-content { justify-content: flex-start; padding: 18px 20px 22px; }
.post-listing--grid_3col .post-row-readmore { margin-top: auto; }
.post-listing--grid_3col .post-row-title { font-size: clamp(15px, 1.5vw, 18px); }
.post-listing--grid_3col .post-row-excerpt { -webkit-line-clamp: 3; }

/* ---------- Pagination ---------- */
.pagination {
  display: flex; justify-content: center; align-items: center;
  gap: 6px; padding: 40px 0 60px; flex-wrap: wrap;
}
.page-btn {
  font-family: var(--font-ui); font-size: 13px; font-weight: 600;
  color: var(--mid); background: var(--bg-card);
  border: 1px solid var(--border); padding: 9px 16px;
  border-radius: var(--radius-sm); min-width: 40px; text-align: center;
  transition: all var(--transition), transform var(--transition-bounce);
  will-change: transform;
}
.page-btn:hover { border-color: var(--red); color: var(--red); transform: translateY(-2px); }
.page-btn.active {
  background: var(--red); color: #fff; border-color: var(--red); pointer-events: none;
}
.page-dots { color: var(--subtle); padding: 0 4px; font-size: 14px; }

/* ---------- Article Hero ---------- */
.hero-wrap { background: var(--charcoal); position: relative; overflow: hidden; }
.hero-wrap img { width: 100%; max-height: 580px; object-fit: cover; opacity: .94; }
.hero-caption {
  position: absolute; bottom: 12px; right: 16px;
  font-size: 11px; color: rgba(255,255,255,.4);
  font-style: italic; letter-spacing: .04em;
}

/* ---------- Article Page Layout ---------- */
.page-layout { padding: 40px 0 72px; }
body.single-post-page .page-layout { max-width: 920px; }

/* ---------- Article ---------- */
.article-title {
  font-size: clamp(26px, 4vw, 44px);
  font-weight: 800; line-height: 1.1; color: var(--black);
  margin-bottom: 18px; letter-spacing: -.02em; text-wrap: pretty;
}
.byline {
  font-size: 12px; color: var(--muted);
  border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  padding: 10px 0; margin-bottom: 32px;
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
}
.byline-meta { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; font-size: 12px; color: var(--muted); }
.byline a { color: var(--red); font-weight: 600; transition: color var(--transition); }
.byline a:hover { color: var(--red-dark); }
.byline .meta-sep { width: 1px; height: 10px; background: var(--border-mid); flex-shrink: 0; }

/* ---------- Share Buttons ---------- */
.share-buttons { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.share-label {
  font-size: 10.5px; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: var(--subtle); margin-right: 2px;
}
.share-btn {
  display: inline-flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: var(--radius-sm);
  border: 1px solid var(--border); background: var(--white);
  color: var(--mid); cursor: pointer; text-decoration: none; overflow: hidden;
  transition: background var(--transition), color var(--transition),
              border-color var(--transition), transform var(--transition-bounce);
  flex-shrink: 0; will-change: transform;
}
.share-btn:hover { transform: translateY(-2px); }
.share-facebook:hover  { background: #1877f2; border-color: #1877f2; color: #fff; }
.share-twitter:hover   { background: #000;    border-color: #000;    color: #fff; }
.share-linkedin:hover  { background: #0a66c2; border-color: #0a66c2; color: #fff; }
.share-copy:hover      { background: var(--red); border-color: var(--red); color: #fff; }
.share-copy.copied     { background: #16a34a; border-color: #16a34a; color: #fff; }

@media (max-width: 540px) {
  .byline { flex-direction: column; align-items: flex-start; gap: 10px; }
  .share-buttons { align-self: flex-start; }
}

/* ---------- Article Body ---------- */
.article-body p {
  font-family: Georgia, 'Times New Roman', serif;
  margin-bottom: 1.5em; font-size: 17px; color: var(--ink); line-height: 1.85;
}
.article-body h2 {
  font-family: var(--font-head); font-size: 26px; font-weight: 800;
  letter-spacing: -.01em; margin: 1.8em 0 .7em; color: var(--black);
}
.article-body h3 {
  font-family: var(--font-head); font-size: 21px; font-weight: 700;
  letter-spacing: -.01em; margin: 1.5em 0 .5em; color: var(--black);
}
.article-body strong { color: var(--black); font-weight: 700; }
.article-body a {
  color: var(--red); text-decoration: underline;
  text-decoration-color: rgba(8,145,178,.3); text-underline-offset: 3px;
  transition: text-decoration-color var(--transition);
}
.article-body a:hover { text-decoration-color: var(--red); }
.article-body ul, .article-body ol {
  font-family: Georgia, 'Times New Roman', serif;
  margin: 0 0 1.5em 1.6em; font-size: 17px; color: var(--ink);
}
.article-body li { margin-bottom: .5em; }
.article-body blockquote {
  border-left: 4px solid var(--red); margin: 1.8em 0;
  padding: 16px 24px; background: rgba(8,145,178,.05);
  font-style: italic; color: var(--mid);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-family: Georgia, 'Times New Roman', serif; font-size: 17px;
}
.article-body > :first-child { margin-top: 0; }
.article-body img { width: 100%; border-radius: var(--radius); margin: 26px 0; }
.article-body figure { margin: 26px 0; }
.article-body figcaption {
  font-size: 12px; color: var(--muted); margin-top: 8px; text-align: center;
}
.article-body hr { border: 0; border-top: 1px solid var(--border); margin: 2em 0; }

/* ---------- Prev/Next Nav ---------- */
.post-nav {
  margin-top: 40px; background: var(--charcoal);
  padding: 18px 24px; border-radius: var(--radius-sm);
  display: flex; gap: 14px; align-items: flex-start;
}
.post-nav .arrow {
  color: var(--red); font-size: 20px; line-height: 1.2;
  flex-shrink: 0; margin-top: 2px;
  display: inline-block; transition: transform var(--transition);
}
.post-nav:hover .arrow { transform: translateX(-4px); }
.post-nav-next:hover .arrow { transform: translateX(4px); }
.post-nav .label {
  font-size: 10px; font-weight: 700; letter-spacing: .14em;
  text-transform: uppercase; color: #444; margin-bottom: 5px;
}
.post-nav strong {
  display: block; font-family: var(--font-head); font-size: 17px;
  font-weight: 700; color: #fff; line-height: 1.25; letter-spacing: -.01em;
}
.post-nav a { color: #666; transition: color var(--transition); }
.post-nav a:hover { color: #fff; }
.post-nav-next { justify-content: flex-end; }
.post-nav-next .arrow { order: 2; margin-left: auto; }

/* ---------- Author Card ---------- */
.author-card {
  margin: 44px 0 0; padding: 24px 28px;
  background: var(--bg-alt);
  border-left: 4px solid var(--red);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.author-card-name {
  font-family: var(--font-head); font-size: 17px; font-weight: 700;
  color: var(--ink); margin-bottom: 8px;
}
.author-card-bio { font-size: 14px; line-height: 1.65; color: var(--mid); margin: 0 0 14px; }
.author-card-social { display: flex; flex-wrap: wrap; gap: 10px; }
.author-social-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 600; padding: 5px 12px;
  border-radius: 20px; text-decoration: none; transition: opacity .15s;
}
.author-social-link:hover { opacity: .75; }
.author-social-li  { background: #0a66c2; color: #fff; }
.author-social-x   { background: #000;    color: #fff; }
.author-social-ig  { background: linear-gradient(45deg,#f09433,#e6683c,#dc2743,#cc2366,#bc1888); color: #fff; }

/* ---------- Related Posts ---------- */
.related-posts { margin-top: 56px; }
.section-title {
  font-family: var(--font-head); font-size: 20px; font-weight: 800;
  letter-spacing: -.01em; color: var(--black); margin-bottom: 20px;
  display: flex; align-items: center; gap: 12px;
}
.section-title::before {
  content: ''; display: block; width: 4px; height: 22px;
  background: var(--red); border-radius: 2px; flex-shrink: 0;
}

.related-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 16px; }
.related-card {
  background: var(--bg-card); border-radius: var(--radius);
  overflow: hidden; border: 1px solid var(--border); box-shadow: var(--shadow-sm);
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
  will-change: transform;
}
.related-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-hover); border-color: var(--border-mid); }
.related-card-img-wrap { position: relative; overflow: hidden; height: 200px; background: var(--bg-alt); }
.related-card-img-wrap img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--transition); }
.related-card:hover .related-card-img-wrap img { transform: scale(1.06); }
.related-card-cat { position: absolute; bottom: 0; left: 0; right: 0; background: var(--red); padding: 5px 12px; }
.related-card-cat span { font-size: 9px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #fff; }
.related-card-body { padding: 14px 16px; }
.related-card h4 {
  font-size: 16px; font-weight: 700; line-height: 1.25;
  margin-bottom: 6px; color: var(--black); letter-spacing: -.01em;
  transition: color var(--transition);
}
.related-card:hover h4 { color: var(--red); }
.related-card .date { font-size: 11px; color: var(--subtle); font-weight: 500; }

/* ---------- Sidebar ---------- */
body.single-post-page .page-layout-sidebar { max-width: var(--max-w); }
.single-post-with-sidebar { display: grid; grid-template-columns: 1fr 320px; gap: 36px; align-items: start; }
.single-post-main { min-width: 0; }
.single-post-sidebar { display: flex; flex-direction: column; gap: 20px; }
.sidebar-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 20px; overflow: hidden;
}
.sidebar-ad-card { text-align: center; display: flex; flex-direction: column; align-items: center; }
@media (min-width: 1024px) { .sidebar-ad-sticky { position: sticky; top: 124px; } }
.sidebar-card-title {
  font-size: 16px; font-weight: 800; letter-spacing: -.01em;
  color: var(--black); margin: 0 0 14px; padding-bottom: 10px;
  border-bottom: 2px solid var(--red);
}
.sidebar-latest-list { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.sidebar-latest-item {
  display: flex; flex-direction: column; gap: 2px;
  padding-bottom: 10px; border-bottom: 1px solid var(--border);
}
.sidebar-latest-item:last-child { padding-bottom: 0; border-bottom: none; }
.sidebar-latest-item a {
  font-size: 14px; font-weight: 600; color: var(--black);
  line-height: 1.4; transition: color var(--transition);
}
.sidebar-latest-item a:hover { color: var(--red); }
.sidebar-latest-date { font-size: 11px; color: var(--subtle); }

@media (max-width: 960px) {
  .single-post-with-sidebar { grid-template-columns: 1fr; }
  .sidebar-ad-sticky { position: static; }
}

/* ---------- Footer ---------- */
.site-footer { background: var(--charcoal); padding: 56px 32px 32px; margin-top: 16px; }
.footer-inner {
  max-width: var(--max-w); margin: 0 auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 52px;
  padding-bottom: 40px; border-bottom: 1px solid rgba(255,255,255,.06);
}
.footer-logo { margin-bottom: 14px; }
.footer-logo img { height: 38px; width: auto; display: block; }
.footer-logo .logo-text {
  font-size: 20px; font-weight: 800; letter-spacing: -.035em;
  color: #fff; line-height: 1;
}
.footer-about p { font-size: 13px; line-height: 1.8; color: rgba(255,255,255,.45); }
.footer-col h4 {
  font-size: 9.5px; font-weight: 700; letter-spacing: .22em;
  text-transform: uppercase; color: rgba(255,255,255,.3); margin-bottom: 18px;
}
.footer-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a {
  font-size: 13.5px; color: rgba(255,255,255,.52);
  transition: color var(--transition), padding-left var(--transition); display: inline-block;
}
.footer-col ul li a:hover { color: #fff; padding-left: 4px; }
.footer-social { display: flex; gap: 8px; flex-wrap: wrap; }
.social-chip {
  padding: 6px 14px; border: 1px solid rgba(255,255,255,.14);
  border-radius: 20px; font-size: 12px; font-weight: 500;
  color: rgba(255,255,255,.52); transition: all var(--transition); cursor: pointer;
}
.social-chip:hover { border-color: var(--red); color: var(--red); }
.footer-network {
  max-width: var(--max-w); margin: 0 auto; padding: 16px 0;
  border-top: 1px solid rgba(255,255,255,.06);
  display: flex; align-items: center; flex-wrap: wrap; gap: 12px; font-size: 12px;
}
.footer-network-label {
  color: rgba(255,255,255,.28); font-weight: 700;
  letter-spacing: .1em; text-transform: uppercase; font-size: 10px;
}
.footer-network a { color: rgba(255,255,255,.42); font-weight: 500; transition: color var(--transition); }
.footer-network a:hover { color: rgba(255,255,255,.85); }
.footer-bottom {
  max-width: var(--max-w); margin: 22px auto 0;
  display: flex; justify-content: space-between;
  font-size: 11.5px; color: rgba(255,255,255,.26); flex-wrap: wrap; gap: 8px;
}
.footer-bottom a { color: rgba(255,255,255,.26); transition: color var(--transition); }
.footer-bottom a:hover { color: rgba(255,255,255,.7); }

/* ---------- Error Card ---------- */
.error-card {
  background: var(--bg-card); border: 1px solid var(--border);
  box-shadow: var(--shadow-md); border-radius: var(--radius); padding: 36px;
}
.error-eyebrow {
  font-size: 11px; letter-spacing: .18em; text-transform: uppercase;
  color: var(--red); font-weight: 700; margin-bottom: 10px;
}
.error-copy { font-size: 15px; color: var(--muted); max-width: 640px; }
.error-actions { margin-top: 22px; display: flex; gap: 10px; flex-wrap: wrap; }

/* ---------- Homepage layout blocks ---------- */
.block-shell { width: 100%; margin: 2rem auto; box-sizing: border-box; }
.block-shell .section-heading { text-align: center; margin: 0 auto 1.25rem; font-size: 1.4rem; font-weight: 700; }
.block-shell .block-inner { margin-left: auto; margin-right: auto; }
.category-strip-items {
  display: flex; flex-wrap: wrap; gap: .5rem; justify-content: center; padding: .5rem 0 1rem;
}
.category-strip-items a {
  display: inline-block; padding: .35rem .9rem;
  background: var(--bg-alt); border-radius: var(--radius-sm);
  text-decoration: none; color: var(--mid); font-size: .875rem;
  border: 1px solid var(--border); transition: all var(--transition);
}
.category-strip-items a:hover { background: var(--red); color: #fff; border-color: var(--red); }
.newsletter-block {
  text-align: center; background: var(--bg-alt);
  border: 1px solid var(--border); padding: 2.5rem 1.5rem;
  border-radius: var(--radius); max-width: 720px; margin: 0 auto;
}
.newsletter-block h2 { margin: 0 0 1rem; font-size: 1.35rem; font-weight: 800; letter-spacing: -.01em; }
.newsletter-block .btn-cta {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--red); color: #fff; text-decoration: none;
  padding: .65rem 1.75rem; border-radius: var(--radius-sm); font-weight: 700; margin-top: .25rem;
  transition: background var(--transition);
}
.newsletter-block .btn-cta:hover { background: var(--red-dark); }
.custom-html-block { text-align: left; }

/* ---------- Custom layout blocks ---------- */
.custom-block-section { width: 100%; box-sizing: border-box; padding: 3rem 0; }
.custom-block-section .custom-block-inner { margin-left: auto; margin-right: auto; }
.custom-block-section .custom-block-grid { display: grid; gap: 2rem; align-items: start; }
.custom-block-section .custom-block-grid--1 { grid-template-columns: minmax(0,1fr); }
.custom-block-section .custom-block-grid--2 { grid-template-columns: repeat(2,minmax(0,1fr)); }
.custom-block-section .custom-block-grid--3 { grid-template-columns: repeat(3,minmax(0,1fr)); }
.custom-block-section .custom-block-col { min-width: 0; word-wrap: break-word; }
.custom-block-section .custom-block-col > *:first-child { margin-top: 0; }
.custom-block-section .custom-block-col > *:last-child { margin-bottom: 0; }

/* ---------- Ads ---------- */
.homepage-ads-block { width: 100%; }
.ads-block-hide-mobile { display: none; }
@media (min-width: 600px) { .ads-block-hide-mobile { display: block; } }
.ads-block-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.5rem;
  overflow: hidden; text-align: center; display: flex; flex-direction: column; align-items: center;
}
.ads-block-title { margin-bottom: 1rem; }
.ads-block-card.ads-rotating-out { opacity: 0; transition: opacity .25s ease; }
.ads-block-card.ads-rotating-in  { opacity: 1; transition: opacity .25s ease; }
.ad-slot-wrap { width: 100%; }
@media (min-width: 1024px) { .ad-slot-sticky { position: sticky; top: 124px; } }
@media (max-width: 960px)  { .ad-slot-sticky { position: static; } }

/* ---------- Focus ---------- */
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .post-row { grid-template-columns: 260px 1fr; }
  .post-listing--grid_3col { grid-template-columns: repeat(2,1fr); }
  .post-listing--grid_3col .post-row { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-about { grid-column: 1 / -1; }
  .custom-block-section .custom-block-grid--3 { grid-template-columns: repeat(2,minmax(0,1fr)); }
  .header-actions { gap: 8px; }
  .search-toggle-text { display: none; }
  .search-toggle { width: 36px; padding: 0; gap: 0; justify-content: center; }
}

@media (max-width: 640px) {
  .site-header-inner { padding: 0 18px; height: 60px; }
  .site-header { top: 37px; }
  .site-hero { height: 480px; margin-top: -60px; }
  .primary-nav {
    display: none; flex-direction: column;
    position: fixed; top: 97px; left: 0; right: 0;
    background: var(--bg-card); border-top: 1px solid var(--border);
    padding: 12px 18px 18px; box-shadow: var(--shadow-md); z-index: 99;
  }
  .primary-nav a { color: var(--mid) !important; }
  .primary-nav.open { display: flex; }
  .hamburger { display: flex; }
  .top-bar { padding: 9px 18px; }
  .wrapper { padding: 0 18px; }
  .post-row { grid-template-columns: 1fr; }
  .post-row-image { height: 200px; }
  .post-row-content { padding: 18px 20px; }
  .post-listing--grid_3col { grid-template-columns: 1fr; }
  .related-grid { grid-template-columns: 1fr; }
  .footer-inner { grid-template-columns: 1fr; gap: 28px; }
  .site-footer { padding: 44px 18px 24px; }
  .article-title { font-size: 28px; }
  .custom-block-section { padding: 2rem 0; }
  .custom-block-section .custom-block-grid--2,
  .custom-block-section .custom-block-grid--3 { grid-template-columns: minmax(0,1fr); gap: 1.5rem; }
  .error-card { padding: 24px 20px; }
  .post-nav { padding: 16px 18px; }
}
