/* ═══════════════════════════════════════════════════════════════
   CHRONICLE NEWS PORTAL — Complete Stylesheet v2
   Editorial aesthetic: cream paper · ink black · crimson red
   ═══════════════════════════════════════════════════════════════ */

/* ── CSS VARIABLES ──────────────────────────────────────────── */
:root {
  --ink:        #0a0a0a;
  --paper:      #f5f0e8;
  --cream:      #ede8dc;
  --offwhite:   #faf9f7;
  --primary:    #c8102e;        /* overridden by settings */
  --accent-gold:#b8972b;        /* overridden by settings */
  --muted:      #6b6560;
  --border:     rgba(10,10,10,0.10);
  --border-md:  rgba(10,10,10,0.18);
  --border-dk:  rgba(10,10,10,0.28);
  --serif:      'Playfair Display', Georgia, serif;
  --sans:       'DM Sans', system-ui, sans-serif;
  --mono:       'DM Mono', 'Courier New', monospace;
  --shadow:     0 2px 16px rgba(10,10,10,.07);
  --shadow-lg:  0 8px 40px rgba(10,10,10,.13);
  --shadow-xl:  0 20px 60px rgba(10,10,10,.18);
  --radius:     0px;
  --max-w:      1400px;
  --transition: .2s cubic-bezier(.4,0,.2,1);
  /* Content & Typography — overridden by theme settings */
  --body-bg:       #f5f0e8;
  --content-bg:    #ffffff;
  --heading-color: #0a0a0a;
  --body-text:     #1a1a1a;
  --subtle:        #6b6560;
  --excerpt-color: #4a4540;
  --link-color:    var(--primary);
  --image-radius:  0px;
  /* Typography scale defaults */
  --heading-size:  1rem;
  --body-size:     0.875rem;
  --head-lh:       1.28;
  --body-lh:       1.65;
  --head-ls:       -0.025em;
}

/* ── RESET ──────────────────────────────────────────────────── */
*,*::before,*::after { box-sizing:border-box; margin:0; padding:0; }
html { scroll-behavior:smooth; font-size:16px; }
body { font-family:var(--sans); background:var(--paper); color:var(--ink); line-height:1.6; overflow-x:hidden; -webkit-font-smoothing:antialiased; }
img  { max-width:100%; height:auto; display:block; }
a    { color:inherit; text-decoration:none; }
a:hover { text-decoration:underline; text-decoration-color:var(--primary); }
button { font-family:inherit; cursor:pointer; }
ul, ol { list-style:none; }
input, textarea, select { font-family:inherit; }

/* ════════════════════════════════════════════════════════════════
   SITE HEADER — mobile-first
   ════════════════════════════════════════════════════════════════ */

/* ── TOPBAR ─────────────────────────────────────────────────── */
.topbar {
  background: var(--ink);
  color: rgba(245,240,232,.5);
  font-size: .8rem;
  font-family: var(--mono);
  letter-spacing: .04em;
  position: relative;
  z-index: 110;
}
.topbar-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: .38rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
}
.topbar-left  { display: flex; align-items: center; gap: .4rem; white-space: nowrap; }
.topbar-cal   { font-size: .8rem; opacity: .4; }
.topbar-date  { white-space: nowrap; }
.topbar-social { display: flex; align-items: center; gap: .65rem; }
.tsoc-link    { color: rgba(245,240,232,.35); display: flex; align-items: center; transition: color var(--transition); }
.tsoc-link:hover { color: #fff; text-decoration: none; }
.topbar-auth  { display: flex; align-items: center; gap: .85rem; white-space: nowrap; }
.topbar-link  { color: rgba(245,240,232,.5); transition: color var(--transition); }
.topbar-link:hover { color: #fff; text-decoration: none; }
.topbar-admin { color: var(--primary) !important; font-weight: 700; margin-right: .15rem; }
.topbar-register { color: var(--primary) !important; font-weight: 600; }

/* ── SITE HEADER WRAPPER ────────────────────────────────────── */
.site-header {
  background: var(--paper);
  position: sticky;
  top: 0;
  z-index: 100;
  transition: box-shadow var(--transition), background var(--transition);
}
.site-header.scrolled {
  box-shadow: 0 4px 24px rgba(0,0,0,.1);
  background: rgba(245,240,232,.97);
  backdrop-filter: blur(8px);
}
/* Header background image — set via inline style="--hbg:url(...)" */
.site-header[style*="--hbg"] {
  position: relative;
}
.site-header[style*="--hbg"]::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: var(--hbg);
  background-size: cover;
  background-position: center;
  opacity: .12;
  pointer-events: none;
  z-index: 0;
}

/* ── MASTHEAD: brand LEFT · search+hamburger RIGHT ──────────── */
.masthead {
  position: relative;
  z-index: 1;
  border-bottom: 1px solid var(--border);
}
.masthead-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: .75rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

/* ── BRAND / LOGO ───────────────────────────────────────────── */
.brand-link {
  display: inline-flex;
  flex-direction: column;
  text-decoration: none;
  gap: 0;
  flex-shrink: 0;
  align-items: flex-start;
}
.brand-link:hover { text-decoration: none; opacity: .9; }

/* When logo image + text are side-by-side */
.brand-with-logo {
  display: flex;
  align-items: center;
  gap: .9rem;
}
.brand-logo-img {
  display: block;
  width: auto;
  height: auto;
  max-height: 36px;
  max-width: 110px;
  object-fit: contain;
  object-position: left center;
  flex-shrink: 0;
}
/* Vertical divider between logo image and text */
.brand-with-logo .brand-text-col {
  display: flex;
  flex-direction: column;
  gap: .1rem;
  border-left: 2px solid var(--border-md);
  padding-left: .9rem;
}
/* Text-only brand (no logo image) */
.brand-link > .brand-name,
.brand-text-col .brand-name {
  font-family: var(--serif);
  font-size: clamp(1.35rem, 3vw, 1.85rem);
  font-weight: 900;
  letter-spacing: -.04em;
  color: var(--ink);
  line-height: 1;
  display: block;
}
.brand-dot { color: var(--primary); }
.brand-link > .brand-tagline,
.brand-text-col .brand-tagline {
  font-size: .8rem;
  font-family: var(--mono);
  letter-spacing: .13em;
  text-transform: uppercase;
  color: var(--muted);
  line-height: 1;
  display: block;
}

/* Masthead right: search form + icon buttons */
.masthead-right {
  display: flex;
  align-items: center;
  gap: .6rem;
  flex-shrink: 0;
}
/* Desktop search form */
.masthead-search {
  display: flex;
  align-items: stretch;
  border: 1.5px solid var(--border-md);
  background: var(--offwhite);
  transition: border-color var(--transition), box-shadow var(--transition);
  height: 38px;
}
.masthead-search:focus-within {
  border-color: var(--ink);
  box-shadow: 0 0 0 3px rgba(10,10,10,.06);
}
.masthead-search input {
  flex: 1;
  width: 220px;
  padding: 0 .85rem;
  border: none;
  background: transparent;
  color: var(--ink);
  font-size: .875rem;
  font-family: var(--sans);
  outline: none;
  min-width: 0;
}
.masthead-search input::placeholder { color: var(--muted); }
.masthead-search button {
  background: var(--ink);
  color: var(--paper);
  border: none;
  padding: 0 .85rem;
  display: flex;
  align-items: center;
  transition: background var(--transition);
  cursor: pointer;
}
.masthead-search button:hover { background: var(--primary); }

/* Icon buttons (search icon + hamburger) */
.icon-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: none;
  border: 1.5px solid var(--border-md);
  color: var(--muted);
  cursor: pointer;
  transition: all var(--transition);
  flex-shrink: 0;
}
.icon-btn:hover { border-color: var(--ink); color: var(--ink); background: var(--cream); }

/* Mobile: icon search shown, desktop form shown */
.search-icon-btn { display: none; }
.hamburger-btn   { display: none; }


/* ═══════════════════════════════════════════════════
   SITE NAVIGATION  (snav-* prefix)
═══════════════════════════════════════════════════ */

/* ── The sticky bar itself ── */
.site-nav {
  background: var(--nav-bg, #ffffff);
  border-top: 3px solid var(--nav-border, #0a0a0a);
  border-bottom: 1px solid rgba(10,10,10,.09);
  position: sticky;
  top: 0;
  z-index: 500;
  box-shadow: 0 2px 8px rgba(10,10,10,.06);
}

/* ── Inner row ── */
.snav-inner {
  max-width: var(--max-w, 1400px);
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  align-items: stretch;   /* links fill full height */
  justify-content: space-between;
  min-height: 44px;
}

/* ── Link list ── */
.snav-list {
  display: flex;
  align-items: stretch;
  list-style: none;
  margin: 0;
  padding: 0;
  overflow-x: auto;
  scrollbar-width: none;
  flex: 1;
}
.snav-list::-webkit-scrollbar { display: none; }

/* ── Nav item — relative so dropdown can anchor to it ── */
.snav-item {
  display: flex;
  align-items: stretch;
  position: relative;
}

/* ── Link/button base ── */
.snav-link {
  display: inline-flex;
  align-items: center;
  gap: .28rem;
  padding: 0 .9rem;
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .09em;
  text-transform: uppercase;
  font-family: var(--sans);
  color: var(--nav-text, #555);
  text-decoration: none;
  white-space: nowrap;
  border-bottom: 2.5px solid transparent;
  border-top: 2.5px solid transparent;
  /* reset button defaults */
  background: none;
  border-left: none;
  border-right: none;
  cursor: pointer;
  transition: color .14s, border-color .14s, background .14s;
  line-height: 1;
  height: 100%;
}
.snav-link:hover {
  color: var(--nav-accent, var(--ink));
  background: rgba(10,10,10,.03);
  text-decoration: none;
}
.snav-link.is-active,
.snav-item.is-active > .snav-link {
  color: var(--nav-accent, var(--ink));
  border-bottom-color: var(--nav-accent, var(--primary));
}
.snav-item.is-open > .snav-trigger {
  color: var(--nav-accent, var(--ink));
  border-bottom-color: var(--nav-accent, var(--primary));
  background: rgba(10,10,10,.035);
}

/* ePaper special link */
.snav-epaper { color: var(--primary); }
.snav-epaper:hover,
.snav-epaper.is-active { color: var(--primary); border-bottom-color: var(--primary); }

/* Caret on dropdown triggers */
.snav-caret {
  display: inline-block;
  width: 0; height: 0;
  border-left: 3.5px solid transparent;
  border-right: 3.5px solid transparent;
  border-top: 4px solid currentColor;
  opacity: .5;
  flex-shrink: 0;
  transition: transform .18s, opacity .18s;
  margin-left: .12rem;
}
.snav-item.is-open > .snav-trigger .snav-caret {
  transform: rotate(180deg);
  opacity: .85;
}

/* ── DROPDOWN PANEL ── */
.snav-drop {
  display: none;
  position: absolute;
  top: calc(100% + 1px);  /* flush below the nav border */
  left: 0;
  min-width: 210px;
  background: #ffffff;
  border: 1px solid rgba(10,10,10,.12);
  border-top: 3px solid var(--nav-accent, var(--primary));
  box-shadow: 0 4px 6px rgba(10,10,10,.05), 0 12px 36px rgba(10,10,10,.12);
  z-index: 600;
  padding: .3rem 0 .5rem;
}
.snav-item.is-open > .snav-drop {
  display: block;
  animation: snavIn .13s ease;
}
@keyframes snavIn {
  from { opacity: 0; transform: translateY(-5px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* "All [Category] →" header inside dropdown */
.snav-drop-all {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .55rem 1rem .6rem;
  font-size: .8rem;
  font-weight: 800;
  font-family: var(--mono);
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--ink);
  text-decoration: none;
  background: #fafaf8;
  border-bottom: 1px solid rgba(10,10,10,.06);
  transition: background .1s;
}
.snav-drop-all:hover { background: #f3f0eb; text-decoration: none; }
.snav-drop-all .arrow { opacity: .5; font-size: .9em; }

/* Thin rule between sections */
.snav-drop-sep { height: 1px; background: #ede9e2; margin: .25rem 0; }

/* Subcategory rows */
.snav-drop-item {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .45rem 1rem;
  font-size: .9rem;
  font-weight: 500;
  color: #3a3530;
  text-decoration: none;
  white-space: nowrap;
  transition: background .1s, color .1s;
}
.snav-drop-item:hover {
  background: #f8f4ef;
  color: var(--nav-accent, var(--primary));
  text-decoration: none;
  padding-left: 1.15rem; /* subtle indent on hover */
}
.snav-drop-item.is-active {
  font-weight: 700;
  color: var(--nav-accent, var(--primary));
  background: #faf6f0;
}
/* Colour dot beside sub-item name */
.snav-drop-item i {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  font-style: normal;
}

/* ── Right slot: sign in / sign out ── */
.snav-right {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  padding-left: .85rem;
  border-left: 1px solid rgba(10,10,10,.09);
  margin-left: .5rem;
}
.snav-auth {
  font-size: .8rem;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: .09em;
  color: var(--muted);
  border: 1.5px solid rgba(10,10,10,.18);
  padding: .3rem .8rem;
  text-decoration: none;
  white-space: nowrap;
  transition: all .14s;
  border-radius: 2px;
}
.snav-auth:hover {
  background: var(--ink);
  color: #fff;
  border-color: var(--ink);
  text-decoration: none;
}


/* ── FLASH MESSAGES ─────────────────────────────────────────── */
.flash-container { max-width: var(--max-w); margin: .75rem auto 0; padding: 0 1.25rem; }
.flash {
  display: flex; justify-content: space-between; align-items: center;
  padding: .75rem 1rem; margin-bottom: .35rem;
  border-left: 4px solid; font-size: .875rem;
  transition: opacity .4s, transform .4s;
}
.flash-success { background: #d4edda; color: #155724; border-color: #28a745; }
.flash-error   { background: #f8d7da; color: #721c24; border-color: #dc3545; }
.flash-warning { background: #fff3cd; color: #856404; border-color: #ffc107; }
.flash-info    { background: #d1ecf1; color: #0c5460; border-color: #17a2b8; }
.flash button  { background: none; border: none; font-size: 1rem; opacity: .5; padding: 0 .25rem; cursor: pointer; }
.flash button:hover { opacity: 1; }

/* ── BREAKING NEWS TICKER ───────────────────────────────────────── */
.breaking-bar {
  display: flex;
  align-items: center;
  background: var(--breaking-color, var(--primary));
  color: #fff;
  font-size: .8rem;
  font-family: var(--mono);
  font-weight: 700;
  letter-spacing: .04em;
  height: 34px;
  overflow: hidden;
  position: relative;
  z-index: 490;
}
.breaking-label-wrap {
  display: flex;
  align-items: center;
  gap: .4rem;
  padding: 0 .85rem;
  background: rgba(0,0,0,.20);
  height: 100%;
  flex-shrink: 0;
  white-space: nowrap;
  border-right: 1px solid rgba(255,255,255,.15);
}
.breaking-pulse {
  display: inline-block;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: #fff;
  animation: bkPulse 1.2s ease-in-out infinite;
  flex-shrink: 0;
}
@keyframes bkPulse {
  0%,100% { opacity:1; transform:scale(1); }
  50%      { opacity:.4; transform:scale(.7); }
}
.breaking-label { text-transform: uppercase; letter-spacing: .12em; font-size: .8rem; }
.breaking-track-outer {
  flex: 1;
  overflow: hidden;
  height: 100%;
  display: flex;
  align-items: center;
  position: relative;
}
.breaking-track {
  display: flex;
  align-items: center;
  gap: 0;
  white-space: nowrap;
  animation: breakingScroll 40s linear infinite;
}
.breaking-track:hover { animation-play-state: paused; }
@keyframes breakingScroll {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-33.333%); }
}
.breaking-item {
  color: rgba(255,255,255,.92);
  text-decoration: none;
  padding: 0 1.5rem;
  transition: color .15s;
  font-size: .8rem;
}
.breaking-item:hover { color: #fff; text-decoration: none; }
.ticker-dot {
  color: rgba(255,255,255,.35);
  font-size: .8rem;
  padding: 0 .25rem;
}
.breaking-pause {
  flex-shrink: 0;
  background: rgba(0,0,0,.15);
  border: none;
  color: rgba(255,255,255,.6);
  padding: 0 .75rem;
  height: 100%;
  cursor: pointer;
  font-size: .8rem;
  border-left: 1px solid rgba(255,255,255,.12);
  transition: background .15s, color .15s;
}
.breaking-pause:hover { background: rgba(0,0,0,.28); color: #fff; }

/* ── HOMEPAGE WRAPPER ───────────────────────────────────────── */
.homepage-wrap { max-width: var(--max-w); margin: 0 auto; padding: 2rem 1.25rem 4rem; }

/* ── HERO ROW: Carousel LEFT + Featured sidebar RIGHT ───────── */
.hero-row {
  display: grid;
  grid-template-columns: 1fr 300px;
  background: #0a0a0a;
  min-height: 560px;
}
/* Main carousel area */
.hero-row-main {
  position: relative;
  overflow: hidden;
  min-height: 0;
}
.hero-row-main .hero-carousel-section {
  height: 100%;
  min-height: 480px;
}
.hero-row-main .hc-track {
  height: 100%;
  min-height: 480px;
}

/* Featured sidebar */
.hero-row-side {
  background: #111;
  border-left: 1px solid rgba(255,255,255,.07);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.fs-side-head {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .75rem 1rem;
  border-bottom: 1px solid rgba(255,255,255,.07);
  font-family: var(--mono);
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: rgba(255,255,255,.4);
  background: rgba(255,255,255,.03);
  flex-shrink: 0;
}
.fs-side-list {
  flex: 1;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,.1) transparent;
}
.fs-side-list::-webkit-scrollbar { width: 3px; }
.fs-side-list::-webkit-scrollbar-thumb { background: rgba(255,255,255,.12); }

/* Each featured item in sidebar */
.fs-side-item {
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.fs-side-link {
  display: flex;
  gap: .65rem;
  padding: .7rem .9rem;
  text-decoration: none;
  transition: background var(--transition);
  align-items: flex-start;
}
.fs-side-link:hover { background: rgba(255,255,255,.05); text-decoration: none; }

/* Lead item (first): bigger image on top */
.fs-side-item--lead .fs-side-link {
  flex-direction: column;
  gap: .5rem;
  padding: .8rem .9rem;
}
.fs-side-item--lead .fs-side-img {
  width: 100%;
  height: 130px;
  flex-shrink: 0;
}
.fs-side-img {
  width: 72px;
  height: 52px;
  flex-shrink: 0;
  overflow: hidden;
  background: rgba(255,255,255,.06);
  position: relative;
}
.fs-side-img img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  display: block;
  transition: transform .4s ease;
}
.fs-side-link:hover .fs-side-img img { transform: scale(1.05); }
.fs-side-ph {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.2rem; opacity: .4;
}
.fs-side-badge {
  position: absolute; top: .3rem; left: .3rem;
  background: var(--primary);
  color: #fff;
  font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em;
  padding: .14rem .4rem;
}
.fs-side-body { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .2rem; }
.fs-side-cat {
  font-family: var(--mono);
  font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .07em;
  display: block;
}
.fs-side-title {
  font-family: var(--serif);
  font-size: .9rem; font-weight: 700;
  line-height: 1.3;
  color: rgba(255,255,255,.82);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.fs-side-item--lead .fs-side-title {
  font-size: .95rem;
  -webkit-line-clamp: 2;
}
.fs-side-link:hover .fs-side-title { color: #fff; }
.fs-side-meta {
  display: flex; gap: .3rem; align-items: center;
  font-size: .8rem; color: rgba(255,255,255,.3);
  font-family: var(--mono);
  margin-top: auto;
}
.fs-side-more {
  display: block;
  padding: .6rem 1rem;
  font-family: var(--mono);
  font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  color: rgba(255,255,255,.3);
  border-top: 1px solid rgba(255,255,255,.07);
  text-decoration: none;
  text-align: center;
  background: rgba(255,255,255,.02);
  flex-shrink: 0;
  transition: all var(--transition);
}
.fs-side-more:hover { color: #fff; background: rgba(255,255,255,.06); text-decoration: none; }

/* ── (old .featured-strip-* kept minimal for compat) ─────── */
.featured-strip { display: none; }

/* ── HERO: replaced by carousel — see hc-* classes below ── */

/* ── CONTENT GRID ───────────────────────────────────────────── */
.content-grid {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 3rem;
  padding-bottom: 3rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 3rem;
  margin-top: 2.5rem;    /* space below hero carousel */
}
.sidebar-col { display: flex; flex-direction: column; gap: 1.5rem; }

/* Section heading */
.section-hd { display: flex; align-items: center; gap: .85rem; margin-bottom: 1.5rem; }
.section-label {
  font-family: var(--mono);
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  white-space: nowrap;
}
.section-label span {
  border-left: 3px solid var(--primary);
  padding-left: .65rem;
}
.section-rule { flex: 1; height: 1px; background: var(--border); }

/* Article grid */
.article-grid-hp {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.article-card-hp {
  background: var(--paper);
  transition: box-shadow var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
}
.article-card-hp:hover { box-shadow: var(--shadow-lg); z-index: 1; }
.article-card-hp > a { display: flex; flex-direction: column; text-decoration: none; height: 100%; }
.card-breaking-border { border-top: 2px solid var(--primary); }

.card-img-hp {
  aspect-ratio: var(--card-ratio, 16/9);
  overflow: hidden;
  position: relative;
  background: var(--cream);
  flex-shrink: 0;
  display: block;
  width: 100%;
}
.card-img-hp img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transition: transform .4s ease;
}
.card-img-ph { width: 100%; aspect-ratio: 16/9; display: flex; align-items: center; justify-content: center; }
.card-ribbon {
  position: absolute; top: .6rem; left: 0;
  background: var(--primary); color: #fff;
  font-size: .8rem; font-family: var(--mono);
  padding: .2rem .55rem;
  text-transform: uppercase; letter-spacing: .08em;
}
.card-ribbon-feat { background: var(--ink); }

.card-body-hp { padding: .9rem; flex: 1; display: flex; flex-direction: column; gap: .4rem; }
.card-meta-top { display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.card-title-hp {
  font-family: var(--serif);
  font-size: var(--heading-size, 1.05rem);
  font-weight: 700;
  line-height: var(--head-lh, 1.25);
  letter-spacing: var(--head-ls, -0.025em);
  color: var(--heading-color, var(--ink));
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  flex: 1;
}
.card-excerpt-hp {
  font-size: var(--body-size, .8375rem); color: var(--excerpt-color, var(--muted)); line-height: var(--body-lh, 1.55);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-footer-hp {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: auto; padding-top: .5rem;
  border-top: 1px solid var(--border);
  font-size: .8rem; color: var(--muted); font-family: var(--mono);
  flex-wrap: wrap; gap: .25rem;
}
.card-footer-right { display: flex; gap: .5rem; align-items: center; }
.card-read-time { background: var(--cream); padding: .1rem .4rem; font-size: .8rem; }
.card-author { font-size: .8rem; }

/* Empty state */
.empty-state-hp {
  grid-column: 1/-1;
  text-align: center; padding: 5rem 2rem; color: var(--muted);
}
.empty-state-hp h3 { font-family: var(--serif); font-size: 1.25rem; margin: .75rem 0 .4rem; }

/* Load more */
.btn-load-more {
  display: inline-block;
  padding: .65rem 2rem;
  border: 2px solid var(--ink);
  font-weight: 700;
  font-size: .875rem;
  letter-spacing: .04em;
  transition: all var(--transition);
}
.btn-load-more:hover { background: var(--ink); color: var(--paper); text-decoration: none; }

/* ── SIDEBAR WIDGETS ────────────────────────────────────────── */
.rail-widget {
  border: 1px solid var(--border);
  overflow: hidden;
  background: var(--paper);
}
.rail-header {
  font-family: var(--mono);
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .11em;
  padding: .6rem 1rem;
  background: var(--ink);
  color: var(--paper);
}

/* Most Read */
.most-read-list { padding: .25rem 0; }
.most-read-list li {
  display: flex; gap: .65rem;
  padding: .65rem 1rem;
  border-bottom: 1px solid var(--border);
  align-items: flex-start;
  transition: background var(--transition);
}
.most-read-list li:last-child { border-bottom: none; }
.most-read-list li:hover { background: var(--cream); }
.mr-num {
  font-family: var(--serif);
  font-size: 1.5rem; font-weight: 900;
  color: rgba(10,10,10,.1);
  line-height: 1; flex-shrink: 0; width: 1.75rem;
}
.mr-content { flex: 1; display: flex; flex-direction: column; gap: .3rem; }
.mr-thumb-link { display: block; flex-shrink: 0; }
.mr-thumb { width: 64px; height: 48px; object-fit: cover; object-position: center; display: block; flex-shrink: 0; background: var(--cream); }
.mr-title { font-family: var(--serif); font-size: .95rem; font-weight: 700; line-height: 1.3; color: var(--heading-color, var(--ink)); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.mr-meta { font-size: .8rem; color: var(--muted); font-family: var(--mono); }

/* Newsletter widget */
.rail-newsletter {}
.rail-nl-body { padding: .85rem 1rem 1rem; }
.rail-nl-body p { font-size: .9rem; color: var(--muted); line-height: 1.55; margin-bottom: .75rem; }
.rail-nl-form { display: flex; flex-direction: column; gap: .4rem; }
.rail-nl-form input {
  padding: .5rem .75rem; border: 1.5px solid var(--border-md);
  background: var(--offwhite); font-size: .875rem;
  outline: none; transition: border-color var(--transition);
}
.rail-nl-form input:focus { border-color: var(--ink); }
.rail-nl-form button {
  background: var(--primary); color: #fff; border: none;
  padding: .55rem .75rem; font-weight: 700; font-size: .875rem;
  transition: background var(--transition);
}
.rail-nl-form button:hover { background: var(--primary); filter: brightness(.82); }

/* Social follow grid */
.rail-social-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--border); }
.rail-soc-btn {
  display: flex; align-items: center; gap: .5rem;
  padding: .65rem .85rem;
  background: var(--paper);
  font-size: .9rem; font-weight: 600;
  transition: background var(--transition), color var(--transition);
  color: var(--ink);
}
.rail-soc-btn:hover { background: var(--sbg, var(--ink)); color: #fff; text-decoration: none; }

/* Tag cloud */
.tag-cloud { padding: .85rem 1rem; display: flex; flex-wrap: wrap; gap: .35rem; }
.tag-pill {
  display: inline-block;
  font-size: .8rem; font-family: var(--mono);
  padding: .22rem .6rem;
  border: 1px solid var(--border-md);
  color: var(--muted);
  transition: all var(--transition);
}
.tag-pill:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); text-decoration: none; }

/* ── CATEGORY SPOTLIGHT SECTIONS ────────────────────────────── */
.cat-section { padding: 2.5rem 0; border-top: 1px solid var(--border); margin-top: 0; }
.cat-section-inner { max-width: var(--max-w); margin: 0 auto; padding: 0 2rem; }
.cat-section-hd {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 1rem; margin-bottom: 1.25rem;
}
.cat-section-hd-left { display: flex; align-items: flex-start; gap: .75rem; }
.cat-section-stripe { width: 4px; height: 40px; border-radius: 2px; flex-shrink: 0; margin-top: 4px; }
.cat-section-name {
  font-family: var(--serif); font-size: 1.4rem; font-weight: 900;
  letter-spacing: -.02em; display: block; margin-bottom: .15rem;
}
.cat-sub-pills {
  display: flex;
  flex-wrap: wrap;
  gap: .35rem;
  margin-top: .55rem;
}
.cat-sub-pill {
  display: inline-block;
  padding: .2rem .65rem;
  font-size: .8rem;
  font-weight: 700;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: .06em;
  border: 1.5px solid var(--sub-color, #888);
  color: var(--sub-color, #555);
  text-decoration: none;
  transition: background .12s, color .12s;
  white-space: nowrap;
}
.cat-sub-pill:hover {
  background: var(--sub-color, #888);
  color: #fff;
  text-decoration: none;
}

.cat-section-desc { font-size: .9rem; color: var(--muted); max-width: 48ch; }
.cat-section-more { font-size: .8rem; font-family: var(--mono); text-transform: uppercase; letter-spacing: .07em; color: var(--muted); white-space: nowrap; border-bottom: 1px solid var(--border-md); transition: color var(--transition), border-color var(--transition); }
.cat-section-more:hover { color: var(--ink); border-color: var(--ink); text-decoration: none; }

.cat-art-body { padding: .85rem; }
.cat-art-meta { font-size: .8rem; color: var(--muted); font-family: var(--mono); display: flex; gap: .35rem; align-items: center; }

/* ── BADGES ─────────────────────────────────────────────────── */
.cat-badge {
  display: inline-block;
  font-size: .8rem; font-family: var(--mono); font-weight: 600;
  text-transform: uppercase; letter-spacing: .08em;
  background: var(--badge-bg, var(--primary));
  color: var(--badge-color, #fff);
  border: var(--badge-border, none);
  border-radius: var(--badge-radius, 2px);
  padding: .18rem .55rem;
  text-decoration: none; flex-shrink: 0;
}
.cat-badge-sm {
  display: inline-block;
  font-size: .8rem; font-family: var(--mono); font-weight: 700;
  text-transform: uppercase; letter-spacing: .06em;
  background: var(--badge-bg, transparent);
  color: var(--badge-color, inherit);
  border: var(--badge-border, none);
  border-radius: var(--badge-radius, 2px);
  padding: .05rem .35rem;
  text-decoration: none;
}
.badge-breaking {
  display: inline-block;
  font-size: .8rem; font-family: var(--mono);
  text-transform: uppercase; letter-spacing: .08em;
  background: var(--primary); color: #fff;
  padding: .18rem .55rem; font-weight: 700;
}
.badge-premium {
  display: inline-block;
  font-size: .8rem; font-family: var(--mono);
  padding: .18rem .55rem; font-weight: 700;
  background: #7c3aed; color: #fff;
}
.badge-premium-sm { font-size: .8rem; color: #7c3aed; font-family: var(--mono); font-weight: 600; }

/* ── NEWSLETTER FOOTER BANNER ───────────────────────────────── */
.footer-newsletter-bar {
  background: var(--ink);
  border-top: 3px solid var(--primary);
}
.fnl-inner {
  max-width: var(--max-w); margin: 0 auto;
  padding: 2rem 2rem;
  display: flex; align-items: center; gap: 3rem;
  flex-wrap: wrap;
}
.fnl-copy {}
.fnl-copy h3 { font-family: var(--serif); font-size: 1.25rem; font-weight: 700; color: #fff; margin-bottom: .3rem; }
.fnl-copy p  { font-size: .875rem; color: rgba(255,255,255,.5); }
.fnl-form {
  display: flex; gap: 0; flex: 1; max-width: 460px;
  min-width: 280px;
}
.fnl-form input {
  flex: 1; padding: .7rem 1.1rem;
  background: rgba(255,255,255,.08); border: 1.5px solid rgba(255,255,255,.15);
  border-right: none; color: #fff; font-size: .9rem;
  outline: none; transition: border-color var(--transition);
}
.fnl-form input::placeholder { color: rgba(255,255,255,.3); }
.fnl-form input:focus { border-color: rgba(255,255,255,.4); }
.fnl-form button {
  background: var(--primary); color: #fff; border: none;
  padding: .7rem 1.35rem; font-weight: 700; font-size: .875rem;
  white-space: nowrap; transition: background var(--transition);
}
.fnl-form button:hover { background: var(--primary); filter: brightness(.82); }

/* ── FOOTER ─────────────────────────────────────────────────── */
.site-footer { background: #0d0d0d; color: rgba(245,240,232,.55); }
.footer-body { background: #0d0d0d; }
.footer-inner {
  max-width: var(--max-w); margin: 0 auto;
  padding: 3.5rem 2rem 2.5rem;
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1.2fr;
  gap: 3rem;
}
.footer-brand-col {}
.footer-logo-link { display: inline-flex; flex-direction: column; gap: .35rem; margin-bottom: .5rem; text-decoration: none; }
.footer-logo-img { max-height: 44px; width: auto; object-fit: contain; opacity: .9; display: block; }
.footer-logo-text { font-family: var(--serif); font-size: 1.75rem; font-weight: 900; color: var(--paper); letter-spacing: -.03em; }
.footer-logo-text span { color: var(--primary); }
.footer-tagline { font-size: .9rem; color: rgba(245,240,232,.4); line-height: 1.65; margin: .5rem 0 1.25rem; max-width: 28ch; }

/* Social icons in footer */
.footer-social-icons { display: flex; gap: .6rem; flex-wrap: wrap; margin-top: .5rem; }
.footer-soc-icon {
  width: 34px; height: 34px;
  display: flex; align-items: center; justify-content: center;
  border: 1px solid rgba(255,255,255,.1);
  color: rgba(255,255,255,.45);
  transition: all var(--transition);
}
.footer-soc-icon:hover { border-color: transparent; text-decoration: none; color: #fff; }
.footer-soc-facebook:hover  { background: #1877f2; }
.footer-soc-twitter:hover   { background: #000; border-color: #333 !important; }
.footer-soc-instagram:hover { background: linear-gradient(45deg,#f09433,#e6683c,#dc2743,#cc2366,#bc1888); }
.footer-soc-youtube:hover   { background: #ff0000; }
.footer-soc-linkedin:hover  { background: #0a66c2; }
.footer-soc-tiktok:hover    { background: #010101; }
.footer-soc-rss:hover       { background: #f26522; }

.footer-col {}
.footer-col-heading { font-size: .8rem; font-family: var(--mono); letter-spacing: .13em; text-transform: uppercase; color: rgba(255,255,255,.25); margin-bottom: .9rem; }
.footer-col ul { display: flex; flex-direction: column; gap: .45rem; }
.footer-col a { font-size: .875rem; color: rgba(245,240,232,.45); transition: color var(--transition); }
.footer-col a:hover { color: var(--paper); text-decoration: none; }

.footer-share-row { display: flex; gap: .4rem; margin-top: .5rem; }
.footer-share-btn {
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.4);
  border: 1px solid rgba(255,255,255,.08);
  transition: all var(--transition);
}
.footer-share-btn:hover { color: #fff; text-decoration: none; }
.footer-share-btn.footer-soc-facebook:hover { background: #1877f2; border-color: #1877f2; }
.footer-share-btn.footer-soc-twitter:hover  { background: #000; border-color: #333; }
.footer-share-btn.footer-soc-whatsapp:hover { background: #25d366; border-color: #25d366; }
.footer-share-btn.footer-soc-telegram:hover { background: #2ca5e0; border-color: #2ca5e0; }

.footer-bottom-bar {
  border-top: 1px solid rgba(255,255,255,.06);
  padding: 1.1rem 0;
}
.footer-bottom-inner {
  max-width: var(--max-w); margin: 0 auto;
  padding: 0 2rem;
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: .75rem;
}
.footer-copyright { font-size: .9rem; font-family: var(--mono); color: rgba(255,255,255,.2); }
.footer-bottom-links { display: flex; align-items: center; gap: 1.25rem; }
.footer-bottom-links a { font-size: .9rem; color: rgba(255,255,255,.2); transition: color var(--transition); }
.footer-bottom-links a:hover { color: rgba(255,255,255,.6); text-decoration: none; }

/* ── ARTICLE DETAIL PAGE ────────────────────────────────────── */
.article-container {
  max-width: 1200px; margin: 0 auto;
  padding: 2rem 2rem 4rem;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 3rem;
}
.article-header {
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border);
  margin-bottom: 2rem;
}
.article-kicker { display: flex; gap: .5rem; margin-bottom: .85rem; align-items: center; flex-wrap: wrap; }
.article-headline {
  font-family: var(--serif);
  font-size: clamp(1.75rem, 3.5vw, 3rem);
  font-weight: 900; line-height: var(--head-lh, 1.05);
  letter-spacing: var(--head-ls, -.03em);
  color: var(--heading-color, var(--ink));
  margin-bottom: .85rem;
}
.article-deck {
  font-size: 1.1875rem;
  color: var(--excerpt-color, var(--muted));
  line-height: var(--body-lh, 1.65);
  margin-bottom: 1.5rem;
}
.article-byline-full {
  display: flex; justify-content: space-between;
  align-items: center; flex-wrap: wrap;
  gap: .75rem; padding-top: 1rem;
  border-top: 1px solid var(--border);
}
.byline-author { display: flex; align-items: center; gap: .75rem; }
.author-avatar-sm {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--ink); color: var(--paper);
  font-family: var(--serif); font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-size: .9rem;
}
.byline-info { font-size: .8rem; color: var(--muted); display: flex; gap: .45rem; flex-wrap: wrap; align-items: center; }
.article-figure { margin: 2rem 0; }
.article-featured-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; object-position: center top; display: block; max-height: 560px; }
.article-figure figcaption { font-size: .8125rem; color: var(--muted); padding: .5rem 0; font-style: italic; border-bottom: 1px solid var(--border); }
/* ── EMBED WRAPPERS (YouTube / Social) ──────────────────── */
.embed-wrap { display: block; margin: 1.75rem 0; clear: both; }
.embed-video {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 */
  height: 0;
  overflow: hidden;
  background: #000;
  border-radius: 2px;
}
.embed-video iframe,
.embed-video video {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  border: 0;
}
/* Bare iframe not inside embed-video — still make it responsive */
.article-body > iframe {
  display: block;
  width: 100%;
  min-height: 360px;
  border: 0;
  margin: 1.75rem 0;
}
.embed-social { max-width: 560px; margin: 1.5rem auto; }
.embed-twitter, .embed-instagram, .embed-facebook { width: 100%; }
/* Twitter tweet blockquote before widget.js loads */
.article-body blockquote.twitter-tweet {
  background: #f7f9fc;
  border-left: 4px solid #1da1f2;
  padding: 1rem 1.25rem;
  font-style: normal;
  max-width: 560px;
  margin: 1.5rem auto;
}
/* Instagram blockquote before embed.js loads */
.article-body blockquote.instagram-media {
  background: #fff;
  border: 1px solid #dbdbdb;
  padding: 1rem;
  max-width: 540px;
  margin: 1.5rem auto;
}
.article-body img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1rem auto;
}

/* ── ARTICLE BODY ────────────────────────────────────────── */
.article-body { font-size: var(--body-size, 1.0625rem); line-height: var(--body-lh, 1.85); color: var(--body-text, #1a1a1a); font-family: var(--sans); }
.article-body > p:first-of-type { line-height: var(--body-lh, 1.75); color: var(--body-text, #1a1a1a); }
.article-body p { margin-bottom: 1.6em; color: var(--body-text, #1a1a1a); }
.article-body h2 {
  font-family: var(--serif); font-size: 1.6rem; font-weight: 700;
  margin: 2.5em 0 .75em; padding-top: 1rem;
  border-top: 3px solid var(--heading-color, var(--ink)); letter-spacing: var(--head-ls, -.02em); line-height: var(--head-lh, 1.1);
  color: var(--heading-color, var(--ink));
}
.article-body h3 {
  font-family: var(--serif); font-size: 1.25rem; font-weight: 700;
  margin: 2em 0 .65em; color: var(--heading-color, var(--ink)); line-height: var(--head-lh, 1.15);
}
.article-body h4 { font-family: var(--serif); font-size: 1.05rem; font-weight: 700; margin: 1.75em 0 .5em; color: var(--heading-color, var(--ink)); }
.article-body blockquote {
  border-left: 4px solid var(--primary); padding: 1.25rem 1.75rem;
  margin: 2.5rem 0; font-family: var(--serif); font-style: italic;
  font-size: 1.175rem; line-height: var(--body-lh, 1.65); background: var(--body-bg, var(--cream));
  color: var(--excerpt-color, #1a1a1a);
}
.article-body blockquote p { margin-bottom: 0; }
.article-body code { font-family: var(--mono); background: #f0ebe3; padding: .18em .45em; font-size: .88em; border-radius: 2px; color: var(--primary); }
.article-body pre { background: #0d0d0d; color: #f0ebe3; padding: 1.5rem; overflow-x: auto; margin: 2rem 0; font-family: var(--mono); font-size: .875rem; line-height: 1.65; border-left: 4px solid var(--primary); }
.article-body pre code { background: none; color: inherit; padding: 0; font-size: inherit; }
.article-body a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; font-weight: 500; }
.article-body a:hover { color: var(--ink); }
.article-body ul { padding-left: 1.5rem; margin-bottom: 1.6em; list-style: none; }
.article-body ul li { margin-bottom: .5em; padding-left: .75rem; position: relative; }
.article-body ul li::before { content: '–'; position: absolute; left: -.25rem; color: var(--primary); font-weight: 700; }
.article-body ol { padding-left: 1.75rem; margin-bottom: 1.6em; counter-reset: ol-counter; list-style: none; }
.article-body ol li { margin-bottom: .5em; counter-increment: ol-counter; padding-left: .5rem; position: relative; }
.article-body ol li::before { content: counter(ol-counter) '.'; position: absolute; left: -1.5rem; color: var(--primary); font-weight: 700; font-family: var(--mono); font-size: .85em; top: .15em; }
.article-body img { max-width: 100%; height: auto; margin: 2.5rem auto; display: block; border: 1px solid var(--border); }
.article-body figure { margin: 2.5rem 0; }
.article-body figcaption { font-size: .8125rem; color: var(--muted); padding: .5rem 0; font-style: italic; border-bottom: 1px solid var(--border); text-align: center; }
.article-body hr { border: none; border-top: 1px solid var(--border); margin: 3rem 0; }
.article-body table { width: 100%; border-collapse: collapse; margin: 2rem 0; font-size: .9375rem; overflow-x: auto; display: block; }
.article-body th { background: var(--ink); color: var(--paper); padding: .65rem .9rem; text-align: left; font-family: var(--mono); font-size: .8rem; text-transform: uppercase; letter-spacing: .06em; font-weight: 600; white-space: nowrap; }
.article-body td { padding: .6rem .9rem; border-bottom: 1px solid var(--border); vertical-align: top; }
.article-body tr:nth-child(even) td { background: var(--cream); }
.article-body mark { background: rgba(200,16,46,.12); color: var(--ink); padding: .05em .2em; }
.article-tags { margin-top: 2.5rem; padding-top: 1.5rem; border-top: 1px solid var(--border); display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.article-tags strong { font-size: .8rem; text-transform: uppercase; letter-spacing: .08em; font-family: var(--mono); color: var(--muted); }
.author-bio-box { margin-top: 2.5rem; padding: 1.5rem; background: var(--cream); border-left: 4px solid var(--ink); display: flex; gap: 1.25rem; align-items: flex-start; }
.author-avatar-lg { width: 56px; height: 56px; border-radius: 50%; background: var(--ink); color: var(--paper); font-family: var(--serif); font-size: 1.5rem; font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.author-bio-box h3 { font-family: var(--serif); font-size: 1.1rem; font-weight: 700; margin-bottom: .35rem; }
.author-bio-box p { font-size: .9rem; color: var(--muted); line-height: 1.65; }
.article-sidebar {}
.sidebar-mini { border-bottom: 1px solid var(--border); padding: .75rem 1rem; }
.sidebar-mini:last-child { border-bottom: none; }
.sidebar-mini > a { display: block; text-decoration: none; transition: background var(--transition); }
.sidebar-mini:hover { background: var(--cream); }
.sidebar-mini img { width: 100%; aspect-ratio: 16/9; object-fit: cover; object-position: center; display: block; margin-bottom: .5rem; max-height: 160px; }
.sidebar-mini h4 { font-family: var(--serif); font-size: .9rem; font-weight: 700; line-height: 1.3; margin-bottom: .3rem; color: var(--ink); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.sidebar-mini time { font-size: .8rem; color: var(--muted); }

/* Comments */
.comments-section { margin-top: 3rem; padding-top: 2rem; border-top: 3px solid var(--ink); }
.comments-title { font-family: var(--serif); font-size: 1.5rem; font-weight: 700; margin-bottom: 1.5rem; }
.comment-form { margin-bottom: 2rem; }
.comment-form textarea { width: 100%; padding: .75rem 1rem; border: 1.5px solid var(--border-md); background: #fff; font-family: var(--sans); font-size: .9375rem; resize: vertical; outline: none; min-height: 100px; }
.comment-form textarea:focus { border-color: var(--ink); }
.comment-login { font-size: .9rem; color: var(--muted); padding: 1rem; background: var(--cream); }
.comment-login a { color: var(--primary); text-decoration: underline; }
.comment-list { display: flex; flex-direction: column; gap: 1.25rem; margin-top: 1.5rem; }
.comment { display: flex; gap: 1rem; padding-bottom: 1.25rem; border-bottom: 1px solid var(--border); }
.comment:last-child { border-bottom: none; }
.comment-author-avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--ink); color: var(--paper); font-family: var(--serif); font-weight: 700; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: .875rem; }
.comment-header { display: flex; gap: .75rem; align-items: baseline; margin-bottom: .4rem; }
.comment-header strong { font-size: .9rem; }
.comment-header time { font-size: .8rem; color: var(--muted); }
.comment-content p { font-size: .9375rem; line-height: 1.65; }

/* ── INNER PAGES ────────────────────────────────────────────── */
.inner-container { max-width: 1200px; margin: 0 auto; padding: 2rem; }
.page-header { padding: 2rem 0 1.5rem; border-bottom: 3px solid var(--ink); margin-bottom: 2rem; }
.page-title { font-family: var(--serif); font-size: clamp(2rem,4vw,3rem); font-weight: 900; letter-spacing: -.03em; }
.page-desc { font-size: 1.0625rem; color: var(--muted); margin-top: .5rem; }
.page-count { font-family: var(--mono); font-size: .8rem; color: var(--muted); margin-top: .35rem; letter-spacing: .06em; }
.empty-state { text-align: center; padding: 5rem 2rem; color: var(--muted); }
.empty-state h3 { font-family: var(--serif); font-size: 1.25rem; margin: .75rem 0 .4rem; }

/* ── ARTICLE GRID (category/search pages) ───────────────────── */
.article-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 1.5rem;
}
.article-card {
  border: var(--card-border, 1px solid var(--border));
  background: var(--paper);
  border-radius: var(--card-radius, 0px);
  overflow: hidden;
  transition: box-shadow var(--transition), transform var(--transition);
}
.article-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-3px); }
.article-card > a { display: block; text-decoration: none; height: 100%; }
.card-img { aspect-ratio: var(--card-ratio, 16/9); overflow: hidden; position: relative; background: var(--cream); border-radius: var(--card-radius,0px) var(--card-radius,0px) 0 0; }
/* fallback always present, real img stacked on top */
.card-img-fb   { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 1; }
.card-img-real { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; z-index: 2; transition: transform .4s; }
.article-card:hover .card-img-real { transform: scale(1.04); }
/* legacy fallback for pages that don't use card-img-fb */
.card-img img  { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; transition: transform .4s; }
.article-card:hover .card-img img { transform: scale(1.04); }
.card-body { padding: 1rem; }
.card-title { font-family: var(--serif); font-size: 1.0625rem; font-weight: 700; line-height: 1.25; margin: .4rem 0 .5rem; color: var(--heading-color, var(--ink)); }
.card-excerpt { font-size: var(--body-size, .875rem); color: var(--excerpt-color, var(--muted)); line-height: var(--body-lh, 1.6); margin-bottom: .75rem; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.card-meta { font-size: .8rem; color: var(--muted); display: flex; gap: .35rem; flex-wrap: wrap; }

/* ── AUTH PAGES ─────────────────────────────────────────────── */
.auth-page .site-header { position: static; }
.auth-container { min-height: calc(100vh - 200px); display: flex; align-items: center; justify-content: center; padding: 2rem; background: var(--cream); }
.auth-card { background: var(--paper); padding: 3rem; width: 100%; max-width: 480px; border: 1px solid var(--border); box-shadow: var(--shadow-xl); border-top: 4px solid var(--primary); }
.auth-logo { text-align: center; margin-bottom: 2rem; display: block; font-family: var(--serif); font-size: 2rem; font-weight: 900; color: var(--ink); text-decoration: none; letter-spacing: -.03em; }
.auth-logo span { color: var(--primary); }
.auth-card h1 { font-family: var(--serif); font-size: 1.75rem; font-weight: 900; margin-bottom: .4rem; text-align: center; }
.auth-sub { color: var(--muted); margin-bottom: 1.75rem; }
.auth-form { display: flex; flex-direction: column; gap: 1.25rem; }
.btn-auth { background: var(--ink); color: var(--paper); border: none; padding: .875rem; font-family: var(--sans); font-size: 1rem; font-weight: 700; cursor: pointer; transition: background .2s; letter-spacing: .02em; }
.btn-auth:hover { background: var(--primary); }
.auth-footer { text-align: center; margin-top: 1.5rem; font-size: .9rem; color: var(--muted); }
.auth-footer a { color: var(--primary); text-decoration: underline; }
.form-group { display: flex; flex-direction: column; gap: .35rem; }
.form-group label { font-size: .8125rem; font-weight: 600; font-family: var(--mono); text-transform: uppercase; letter-spacing: .06em; display: flex; justify-content: space-between; }
.form-link { font-weight: 400; color: var(--primary); text-decoration: underline; text-transform: none; letter-spacing: 0; font-family: var(--sans); }
.form-group input, .form-group textarea, .form-group select { padding: .65rem .875rem; border: 1.5px solid var(--border-md); background: #fff; font-family: var(--sans); font-size: .9375rem; color: var(--ink); outline: none; transition: border-color .2s; }
.form-group input:focus, .form-group textarea:focus, .form-group select:focus { border-color: var(--ink); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-error { background: #f8d7da; color: #721c24; border-left: 4px solid #dc3545; padding: .65rem 1rem; font-size: .9rem; margin-bottom: .75rem; }

/* ── PAGINATION ─────────────────────────────────────────────── */
.pagination { display: flex; justify-content: center; gap: .4rem; margin: 2.5rem 0; flex-wrap: wrap; }
.pag-btn { display: inline-flex; align-items: center; justify-content: center; padding: .4rem .85rem; border: 1.5px solid var(--border-md); font-size: .875rem; font-weight: 500; color: var(--ink); background: var(--paper); transition: all .2s; text-decoration: none; }
.pag-btn:hover, .pag-btn.active { background: var(--ink); color: var(--paper); border-color: var(--ink); text-decoration: none; }
.pag-ellipsis { display: inline-flex; align-items: center; padding: .4rem .5rem; color: var(--muted); }

/* ── BUTTONS ────────────────────────────────────────────────── */
.btn-outline-dark { display: inline-block; padding: .75rem 2rem; border: 2px solid var(--ink); color: var(--ink); font-weight: 700; font-size: .9375rem; transition: all .2s; }
.btn-outline-dark:hover { background: var(--ink); color: var(--paper); text-decoration: none; }
.btn-primary-sm { background: var(--primary); color: #fff; border: none; padding: .55rem 1.25rem; font-family: var(--sans); font-weight: 600; font-size: .9rem; cursor: pointer; transition: background .2s; }
.btn-primary-sm:hover { background: var(--primary); filter: brightness(.82); }

/* Search page form */
.search-page-form { display: flex; gap: .75rem; margin-bottom: 2rem; }
.search-page-input { flex: 1; padding: .75rem 1rem; border: 2px solid var(--ink); background: #fff; font-family: var(--sans); font-size: 1rem; outline: none; }
.search-page-input:focus { border-color: var(--primary); }

/* ── RESPONSIVE ─────────────────────────────────────────────── */

/* ≥ 1280px — wide desktop */
@media (min-width: 1280px) {
  .masthead-search input { width: 280px; }
  .hero-row { grid-template-columns: 1fr 320px; }
}

/* 1025 – 1279px — desktop */
@media (max-width: 1279px) {
  .hero-row { grid-template-columns: 1fr 280px; }
  .cat-section-grid { grid-template-columns: 1.5fr 1fr 1fr; }
  .footer-inner { grid-template-columns: 1fr 1fr 1fr; }
  .footer-brand-col { grid-column: 1/-1; }
}

/* 901 – 1024px — small desktop / large tablet */
@media (max-width: 1024px) {
  .hero-row { grid-template-columns: 1fr 250px; }
  .content-grid { grid-template-columns: 1fr 280px; gap: 2rem; }
  .article-grid-hp { grid-template-columns: 1fr 1fr; }
  .masthead-search input { width: 180px; }
}

/* ≤ 900px — tablet portrait / large phone  */
@media (max-width: 900px) {
  /* Header */
  .masthead-search  { display: none; }
  .search-icon-btn  { display: flex; }
  .hamburger-btn    { display: flex; }
  .snav-right       { display: none; }
  /* Hide desktop nav bar on mobile — use drawer instead */
  .site-nav         { display: none; }

  /* Hero row: stack carousel on top, featured below */
  .hero-row { grid-template-columns: 1fr; }
  .hero-row-side {
    border-left: none;
    border-top: 1px solid rgba(255,255,255,.08);
    flex-direction: row;
    max-height: 160px;
  }
  .fs-side-head { display: none; }
  .fs-side-list {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    overflow-y: hidden;
  }
  .fs-side-item { border-bottom: none; border-right: 1px solid rgba(255,255,255,.06); min-width: 200px; }
  .fs-side-item--lead .fs-side-link { flex-direction: row; }
  .fs-side-item--lead .fs-side-img  { width: 72px; height: 52px; }
  .fs-side-more { writing-mode: vertical-rl; padding: .75rem .5rem; min-width: 36px; }

  /* Ticker */
  .hc-controls { display: flex; }
  .hc-dots     { padding: .4rem .5rem .3rem; }

  /* Layout */
  .content-grid      { grid-template-columns: 1fr; }
  .sidebar-col       { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
  .article-container { grid-template-columns: 1fr; }
  .cat-section-grid  { grid-template-columns: 1fr 1fr; }
  .cat-art-lead      { grid-column: 1 / -1; }
  .article-grid      { grid-template-columns: 1fr 1fr; }

  /* Footer */
  .footer-inner     { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .footer-brand-col { grid-column: 1 / -1; }
  .fnl-inner        { flex-direction: column; gap: 1.25rem; }
  .fnl-form         { max-width: 100%; width: 100%; }
  .topbar-social    { display: none; }
}

/* ≤ 640px — phone */
@media (max-width: 640px) {
  .topbar-left { display: none; }
  .masthead-inner { padding: .6rem 1rem; }

  /* Hero row: hide featured sidebar on small phone */
  .hero-row-side { display: none; }

  /* Content */
  .homepage-wrap    { padding: 1rem 1rem 3rem; }
  .article-grid-hp  { grid-template-columns: 1fr; }
  .article-grid     { grid-template-columns: 1fr; }
  .form-row         { grid-template-columns: 1fr; }
  .sidebar-col      { display: flex; flex-direction: column; }
  .cat-section-grid { grid-template-columns: 1fr; }

  /* Auth pages */
  .auth-card        { padding: 1.75rem 1.25rem; }
  .article-container{ padding: 1rem; }
  .inner-container  { padding: 1rem; }

  /* Footer */
  .footer-inner     { grid-template-columns: 1fr 1fr; padding: 1.75rem 1rem; }
  .cat-section-grid { grid-template-columns: 1fr; }
}

/* ≤ 420px — small phones */
@media (max-width: 420px) {
  .brand-name { font-size: 1.4rem; }
  .featured-strip-grid { grid-template-columns: 1fr; }
  .hc-track   { height: 300px; }
}

/* ═══════════════════════════════════════════════════════════════

/* ── RESPONSIVE IMAGE IMPROVEMENTS ─────────────────────────── */
/* Lazy-load fade-in — only hides/fades when JS is active */
.js-ready img[loading="lazy"]        { opacity: 0; transition: opacity .45s ease; }
.js-ready img[loading="lazy"].loaded { opacity: 1; }

/* Card entrance animation — only for below-fold cards */
.anim-ready { opacity: 0; transform: translateY(20px); transition: opacity .5s ease, transform .5s ease; }
.anim-ready.anim-in { opacity: 1; transform: translateY(0); }
img { opacity: 1; } /* always visible by default */

/* object-position helpers */

/* Mobile image caps — prevent oversized images on small screens */
@media (max-width: 768px) {
  .card-img-hp         { max-height: none; }
  .article-featured-img{ max-height: 300px; }
  .cat-art-lead .cat-art-img { max-height: 260px; }
  .cat-art .cat-art-img      { max-height: 180px; }
}
@media (max-width: 480px) {
  .article-featured-img{ aspect-ratio: 4/3; max-height: none; }
  .card-img-hp         { max-height: none; }
}

/* site-main — full height */
.site-main { min-height: 50vh; }


/* rail-soc-btn hover uses CSS var */
.rail-soc-btn:hover { background: var(--sbg, var(--ink)); color: #fff; text-decoration: none; }


/* broken image placeholder */
img::after {
  content: '🖼';
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%; height: 100%;
  min-height: 80px;
  background: var(--cream);
  color: rgba(10,10,10,.2);
  font-size: 1.5rem;
  font-style: normal;
}

/* content-main-col */
.content-main-col { min-width: 0; }

/* ── ARTICLE BOTTOM — Related & Most Viewed ─────────────────── */
.article-bottom-section {
  max-width: 1200px; margin: 0 auto; padding: 0 2rem 4rem;
}
.article-bottom-heading {
  font-family: var(--serif); font-size: 1.5rem; font-weight: 900;
  letter-spacing: -.03em; margin-bottom: 1.25rem;
  padding-bottom: .75rem; border-bottom: 3px solid var(--ink);
  display: flex; align-items: center; justify-content: space-between;
}
.article-bottom-heading a { font-size: .8rem; font-family: var(--mono); font-weight: 400; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; text-decoration: none; }
.article-bottom-heading a:hover { color: var(--primary); }
.article-bottom-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}
.art-bot-card {
  background: var(--paper);
  display: flex; flex-direction: column;
  transition: background .15s;
}
.art-bot-card:hover { background: var(--cream); }
.art-bot-card > a { display: flex; flex-direction: column; text-decoration: none; height: 100%; }
.art-bot-img { aspect-ratio: 16/9; overflow: hidden; background: var(--cream); flex-shrink: 0; }
.art-bot-img img { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; transition: transform .4s ease; }
.art-bot-card:hover .art-bot-img img { transform: scale(1.04); }
.art-bot-img-ph { width: 100%; aspect-ratio: 16/9; display: flex; align-items: center; justify-content: center; font-size: 2rem; background: var(--cream); }
.art-bot-body { padding: .9rem; flex: 1; display: flex; flex-direction: column; }
.art-bot-cat { font-size: .8rem; font-family: var(--mono); text-transform: uppercase; letter-spacing: .08em; font-weight: 600; margin-bottom: .4rem; }
.art-bot-title { font-family: var(--serif); font-size: .9375rem; font-weight: 700; line-height: 1.3; margin-bottom: .5rem; color: var(--heading-color, var(--ink)); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.art-bot-meta { font-size: .8rem; color: var(--muted); margin-top: auto; padding-top: .4rem; display: flex; gap: .35rem; align-items: center; flex-wrap: wrap; }
.art-bot-views { font-size: .8rem; font-family: var(--mono); color: var(--muted); display: flex; align-items: center; gap: .2rem; }

/* Most-viewed numbered list */
.art-bot-mv-list { display: flex; flex-direction: column; gap: 0; }
.art-bot-mv-item {
  display: flex; gap: .85rem; align-items: flex-start;
  padding: .9rem 1rem; border-bottom: 1px solid var(--border);
  transition: background .15s; text-decoration: none;
}
.art-bot-mv-item:last-child { border-bottom: none; }
.art-bot-mv-item:hover { background: var(--cream); text-decoration: none; }
.art-bot-mv-num {
  font-family: var(--serif); font-size: 1.75rem; font-weight: 900;
  color: rgba(10,10,10,.12); line-height: 1; flex-shrink: 0;
  width: 2rem; text-align: right;
}
.art-bot-mv-img { width: 72px; height: 54px; flex-shrink: 0; overflow: hidden; background: var(--cream); }
.art-bot-mv-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.art-bot-mv-content { flex: 1; min-width: 0; }
.art-bot-mv-title { font-family: var(--serif); font-size: .95rem; font-weight: 700; line-height: 1.3; color: var(--heading-color, var(--ink)); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-bottom: .25rem; }
.art-bot-mv-meta { font-size: .8rem; color: var(--muted); font-family: var(--mono); }

.art-bot-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin-top: 3rem; }
.art-bot-panel { background: var(--paper); border: 1px solid var(--border); overflow: hidden; }

@media (max-width: 900px) {
  .article-bottom-grid { grid-template-columns: 1fr 1fr; }
  .art-bot-two-col { grid-template-columns: 1fr; gap: 1.5rem; }
}
@media (max-width: 600px) {
  .article-bottom-grid { grid-template-columns: 1fr; }
  .article-bottom-section { padding: 0 1rem 3rem; }
}

/* ── ARTICLE BOTTOM (related + most viewed) ─────────────── */
@media (max-width: 768px) {
  .article-bottom-two-col { grid-template-columns: 1fr !important; }
}

/* ═══════════════════════════════════════════════════════════════
   HERO CAROUSEL
   ═══════════════════════════════════════════════════════════════ */
.hero-carousel-section {
  position: relative;
  width: 100%;
  overflow: hidden;
  background: #0a0a0a;
  margin-bottom: 0;
  user-select: none;
}

/* Track holds all slides stacked */
.hc-track {
  position: relative;
  width: 100%;
  height: 560px;
}
@media (max-width: 900px)  { .hc-track { height: 440px; } }
@media (max-width: 640px)  { .hc-track { height: 320px; } }

/* Individual slide */
.hc-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity .75s ease, visibility .75s ease;
  will-change: opacity;
}
.hc-slide.active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

/* Background image */
.hc-bg {
  position: absolute;
  inset: 0;
  overflow: hidden;
}
.hc-bg-img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  transform: scale(1.04);
  transition: transform 8s ease;
}
.hc-slide.active .hc-bg-img {
  transform: scale(1);
}

/* Dark gradient overlay */
.hc-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to top,  rgba(5,5,5,.95)  0%, rgba(5,5,5,.55) 45%, transparent 75%),
    linear-gradient(to right, rgba(5,5,5,.5)  0%, transparent 55%);
}

/* Default placeholder (no image) */
.hc-placeholder {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.hc-ph-pattern {
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(45deg, rgba(255,255,255,.03) 0px, rgba(255,255,255,.03) 1px, transparent 1px, transparent 12px),
    repeating-linear-gradient(-45deg, rgba(255,255,255,.03) 0px, rgba(255,255,255,.03) 1px, transparent 1px, transparent 12px);
  background-size: 24px 24px;
}
.hc-ph-content {
  position: relative; z-index: 1;
  text-align: center;
  padding: 2rem;
}
.hc-ph-icon { font-size: 3.5rem; display: block; margin-bottom: .75rem; opacity: .5; }
.hc-ph-cat {
  display: block;
  font-family: var(--mono); font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .2em;
  color: rgba(255,255,255,.6); margin-bottom: .35rem;
}
.hc-ph-site {
  display: block;
  font-family: var(--serif); font-size: 2rem; font-weight: 900;
  color: rgba(255,255,255,.15); letter-spacing: -.03em;
}

/* Slide content — bottom-left */
.hc-content {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  z-index: 2;
  padding: 2.5rem 3.5rem 2rem 2.5rem;
  display: flex;
  flex-direction: column;
  gap: .7rem;
  max-width: 780px;
}
@media (max-width: 900px) { .hc-content { padding: 1.5rem 5rem 1.25rem 1.5rem; max-width: 100%; gap: .5rem; } }
@media (max-width: 640px) { .hc-content { padding: 1rem 1rem 4.5rem; gap: .35rem; } }

/* Badges row */
.hc-badges { display: flex; gap: .4rem; flex-wrap: wrap; align-items: center; }
.hc-cat-badge {
  display: inline-block;
  font-family: var(--mono); font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  color: #fff; padding: .25rem .65rem;
  text-decoration: none;
  transition: opacity .2s;
}
.hc-cat-badge:hover { opacity: .85; text-decoration: none; }
.hc-badge-pill {
  display: inline-block;
  font-family: var(--mono); font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  padding: .25rem .6rem;
}
.hc-breaking { background: var(--primary); color: #fff; }
.hc-premium  { background: #7c3aed;       color: #fff; }

/* Headline */
.hc-headline-link { text-decoration: none; display: block; }
.hc-headline {
  font-family: var(--serif);
  font-size: clamp(1.5rem, 3.2vw, 2.75rem);
  font-weight: 900;
  line-height: 1.06;
  letter-spacing: -.04em;
  color: #fff;
  margin: 0;
  text-shadow: 0 2px 12px rgba(0,0,0,.35);
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.hc-headline-link:hover .hc-headline { text-decoration: underline; text-underline-offset: 4px; }

/* Excerpt */
.hc-excerpt {
  font-size: .9375rem; line-height: 1.6;
  color: rgba(255,255,255,.72);
  margin: 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
@media (max-width: 640px) { .hc-excerpt { display: none; } }

/* Meta line */
.hc-meta {
  display: flex; align-items: center; gap: .45rem;
  font-family: var(--mono); font-size: .8rem;
  color: rgba(255,255,255,.5);
  flex-wrap: wrap;
}
.hc-dot { opacity: .4; }

/* Read button */
.hc-read-btn {
  display: inline-flex; align-items: center; gap: .5rem;
  background: #fff; color: var(--ink);
  font-family: var(--mono); font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .1em;
  padding: .5rem 1.1rem;
  text-decoration: none;
  align-self: flex-start;
  transition: background .2s, color .2s, gap .2s;
  border: 2px solid rgba(255,255,255,.9);
  margin-top: .1rem;
}
.hc-read-btn:hover { background: var(--primary); color: #fff; border-color: var(--primary); text-decoration: none; gap: .8rem; }
.hc-arrow { transition: transform .2s; }
.hc-read-btn:hover .hc-arrow { transform: translateX(3px); }
@media (max-width: 640px) { .hc-read-btn { font-size: .75rem; padding: .45rem .9rem; } }

/* Prev / Next arrow buttons */
.hc-nav {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  z-index: 10;
  width: 44px; height: 44px;
  background: rgba(255,255,255,.12);
  border: 1.5px solid rgba(255,255,255,.2);
  color: #fff;
  font-size: 1.25rem;
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, border-color .2s;
  backdrop-filter: blur(4px);
}
.hc-nav:hover { background: rgba(255,255,255,.28); border-color: rgba(255,255,255,.5); }
.hc-prev { left: 1.1rem; }
.hc-next { right: 1.1rem; }
@media (max-width: 640px) {
  .hc-prev { left: .5rem; }
  .hc-next { right: .5rem; }
  .hc-nav  { width: 36px; height: 36px; font-size: 1rem; }
}

/* Controls bar — thumbnail dots + progress */
.hc-controls {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  z-index: 10;
  background: rgba(5,5,5,.75);
  backdrop-filter: blur(6px);
  border-top: 1px solid rgba(255,255,255,.08);
  display: flex;
  flex-direction: column;
}

/* Thumbnail dot strip */
.hc-dots {
  display: flex;
  overflow-x: auto;
  scrollbar-width: none;
  padding: .55rem .75rem .4rem;
  gap: .45rem;
}
.hc-dots::-webkit-scrollbar { display: none; }

.hc-dot-btn {
  display: flex; align-items: center; gap: .55rem;
  background: transparent;
  border: 1.5px solid rgba(255,255,255,.15);
  color: rgba(255,255,255,.5);
  padding: .3rem .5rem .3rem .35rem;
  cursor: pointer;
  font-size: .75rem; font-family: var(--sans);
  white-space: nowrap;
  flex-shrink: 0;
  transition: border-color .2s, color .2s, background .2s;
  max-width: 220px;
}
.hc-dot-btn:hover {
  border-color: rgba(255,255,255,.45);
  color: rgba(255,255,255,.85);
  background: rgba(255,255,255,.06);
}
.hc-dot-btn.active {
  border-color: #fff;
  color: #fff;
  background: rgba(255,255,255,.1);
}
.hc-dot-thumb {
  width: 44px; height: 32px; flex-shrink: 0;
  overflow: hidden; background: rgba(255,255,255,.08);
  display: block;
}
.hc-dot-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hc-dot-label {
  overflow: hidden; text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 150px;
  display: block;
}
@media (max-width: 640px) {
  .hc-dot-label { display: none; }
  .hc-dot-btn   { padding: .25rem; border: 1.5px solid rgba(255,255,255,.2); }
  .hc-dot-btn.active { border-color: #fff; }
  .hc-dot-thumb { width: 36px; height: 26px; }
}

/* Progress bar */
.hc-progress-wrap {
  display: flex; align-items: center; gap: 0;
  height: 3px; background: rgba(255,255,255,.1);
}
.hc-progress-bar {
  height: 100%;
  background: var(--primary);
  width: 0%;
  transition: width .1s linear;
}
.hc-pause-btn {
  flex-shrink: 0;
  width: 26px; height: 26px;
  background: rgba(255,255,255,.1);
  border: none; color: rgba(255,255,255,.6);
  font-size: .8rem; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s, color .2s;
  position: relative; top: -1.5px; /* optical */
}
.hc-pause-btn:hover { background: rgba(255,255,255,.2); color: #fff; }

/* ═══════════════════════════════════════════════════════════════
   ARTICLE CARDS — DEFAULT PLACEHOLDER IMAGE
   ═══════════════════════════════════════════════════════════════ */
.card-img-default {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
  min-height: 140px;
}
.card-img-default::before {
  content: ''; position: absolute; inset: 0;
  background: repeating-linear-gradient(
    -45deg,
    rgba(255,255,255,.03) 0px, rgba(255,255,255,.03) 1px,
    transparent 1px, transparent 14px
  );
  pointer-events: none; z-index: 0;
}
.card-img-default-inner {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: .35rem; padding: 1rem;
  text-align: center;
  pointer-events: none;
  position: relative; z-index: 1;
}
.card-ph-initial {
  font-family: var(--serif); font-size: 2.2rem; font-weight: 900;
  line-height: 1; display: block; opacity: .55; letter-spacing: -.04em;
}
.card-ph-icon  { font-size: 1.8rem; display: block; opacity: .4; }
.card-ph-cat   {
  font-family: var(--mono); font-size: .75rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .14em;
  display: block; opacity: .75;
}
.card-ph-site  {
  font-family: var(--serif); font-size: .8rem; font-weight: 900;
  color: var(--muted); opacity: .4; display: block;
}

/* ── Article page image placeholder ── */
.article-img-ph {
  width: 100%; min-height: 280px; max-height: 420px;
  display: flex; align-items: center; justify-content: center;
  margin: 0 0 2rem; border-radius: 2px;
  position: relative; overflow: hidden;
}
.article-img-ph::before {
  content: ''; position: absolute; inset: 0;
  background: repeating-linear-gradient(
    -45deg,
    rgba(0,0,0,.025) 0, rgba(0,0,0,.025) 1px,
    transparent 1px, transparent 16px
  );
}

/* ── Most-read sidebar thumbnail placeholder ── */
.mr-thumb-ph {
  display: flex; align-items: center; justify-content: center;
  font-size: .9rem;
}

/* ═══════════════════════════════════════════════════════════════
   ARTICLE CARD UNIFORM HEIGHT FIX
   ═══════════════════════════════════════════════════════════════ */
/* Force all grid cards to equal column heights via grid rows */
.article-grid-hp {
  grid-auto-rows: 1fr;  /* equal row heights */
  align-items: stretch;
}
/* Card body/footer */
.card-body-hp  { flex: 1; display: flex; flex-direction: column; }
.card-footer-hp{ margin-top: auto; }
.article-card-hp:hover .card-img-hp img { transform: scale(1.04); }
/* Title — consistent 3-line clamp */
.card-title-hp {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

/* ═══════════════════════════════════════════════════════════════
   CATEGORY SECTION — DEFAULT PLACEHOLDER IMAGE
   ═══════════════════════════════════════════════════════════════ */
.cat-art-img-default {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  min-height: 120px;
}
.cat-art-img-default-lg { min-height: 200px; }
.cat-ph-inner {
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: .4rem; padding: 1rem;
  text-align: center;
}
.cat-ph-ico {
  font-size: 2.25rem; opacity: .4; display: block;
}
.cat-ph-nm {
  font-family: var(--mono); font-size: .8rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: .12em;
  display: block; opacity: .7;
}

/* Category grid alignment — lead fills height */
.cat-art {
  background: var(--paper);
  display: flex; flex-direction: column;
}
.cat-art > a {
  display: flex; flex-direction: column;
  height: 100%; text-decoration: none;
}
.cat-art-body {
  flex: 1; display: flex; flex-direction: column;
}
.cat-art-title {
  flex: 1;
}
.cat-art-title-lg {
  font-size: 1.15rem !important;
  -webkit-line-clamp: 4 !important;
}
.cat-art-excerpt {
  font-size: .9rem; color: var(--muted); line-height: 1.55;
  margin: .35rem 0;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.cat-art-meta {
  margin-top: auto;
}

/* Section header spacing tweak */
.section-hd { margin-top: .15rem; }

/* ═══════════════════════════════════════════════════════════════
   CATEGORY SECTION GRID RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */
/* Override: use 1fr lead + 1fr 1fr for 3 articles, or 1fr each for 2 */
.cat-section-grid {
  display: grid;
  grid-template-columns: 1.75fr 1fr 1fr;
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
  align-items: stretch; /* uniform height columns */
}
.cat-section-grid .cat-art:not(.cat-art-lead) .cat-art-img {
  aspect-ratio: 16/9;
}
.cat-section-grid .cat-art-lead .cat-art-img {
  aspect-ratio: 4/3;
}
.cat-art-img {
  overflow: hidden;
  background: var(--cream);
}
.cat-art-img img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  display: block;
  transition: transform .4s ease;
}
.cat-art:hover .cat-art-img img { transform: scale(1.04); }

@media (max-width: 900px) {
  .cat-section-grid { grid-template-columns: 1fr 1fr; }
  .cat-art-lead { grid-column: 1 / -1; }
  .cat-section-grid .cat-art-lead .cat-art-img { aspect-ratio: 16/9; max-height: 300px; }
}
@media (max-width: 640px) {
  .cat-section-grid { grid-template-columns: 1fr; }
  .cat-art-lead { grid-column: auto; }
  .cat-section-grid .cat-art-lead .cat-art-img { aspect-ratio: 16/9; max-height: 220px; }
}


/* ── LINK PREVIEW CARDS ─────────────────────────────────────── */
.lp-card {
  display: flex; gap: 0; border: 1px solid var(--border);
  background: var(--paper); margin: 1.25rem 0; overflow: hidden;
  transition: box-shadow .18s; cursor: pointer; text-decoration: none;
}
.lp-card:hover { box-shadow: 0 4px 16px rgba(0,0,0,.10); }
.lp-img { width: 140px; min-height: 96px; flex-shrink: 0; overflow: hidden; background: var(--cream); }
.lp-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.lp-body { flex: 1; padding: .85rem 1rem; min-width: 0; border-left: 1px solid var(--border); }
.lp-domain { font-size: .8rem; font-family: var(--mono); color: var(--muted); text-transform: uppercase; letter-spacing: .06em; margin-bottom: .3rem; }
.lp-title { font-family: var(--serif); font-size: .9rem; font-weight: 700; line-height: 1.3; color: var(--heading-color, var(--ink)); margin-bottom: .3rem; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.lp-desc { font-size: .8rem; color: var(--muted); line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
@media(max-width:600px) { .lp-img { width: 96px; min-height: 72px; } }

/* ════════════════════════════════════════════════════════════
   EPAPER — shared card + homepage strip
   ════════════════════════════════════════════════════════════ */

/* ── Newspaper portrait card ─────────────────────────────── */
.ep-card {
  background: #fff;
  border: 1px solid #e8e4de;
  border-radius: 6px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  box-shadow: 0 2px 8px rgba(0,0,0,.06);
  transition: transform .2s ease, box-shadow .2s ease;
  cursor: pointer;
}
.ep-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 14px 36px rgba(0,0,0,.14);
  text-decoration: none;
  color: inherit;
}
.ep-card-img {
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: linear-gradient(160deg,#1a1a2e 0%,#16213e 100%);
  position: relative;
  flex-shrink: 0;
}
.ep-card-img img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  transition: transform .35s ease;
}
.ep-card:hover .ep-card-img img { transform: scale(1.03); }
.ep-card-img-ph {
  width: 100%; height: 100%;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  gap: .5rem;
  position: absolute; inset: 0;
}
.ep-card-img-ph svg { opacity: .18; }
.ep-card-img-ph span {
  font-size: .8rem; color: rgba(255,255,255,.3);
  text-align: center; padding: 0 .75rem;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.ep-card-overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,0);
  transition: background .2s;
  display: flex; align-items: center; justify-content: center;
}
.ep-card:hover .ep-card-overlay { background: rgba(0,0,0,.38); }
.ep-card-overlay-icon {
  width: 46px; height: 46px;
  background: rgba(255,255,255,.92);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.15rem;
  opacity: 0; transform: scale(.75);
  transition: all .2s ease;
}
.ep-card:hover .ep-card-overlay-icon { opacity: 1; transform: scale(1); }
.ep-card-body {
  padding: .75rem .9rem .85rem;
  background: #fff;
  border-top: 2px solid var(--primary);
}
.ep-card-pub {
  font-size: .8rem;
  font-weight: 700;
  font-family: var(--mono);
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--primary);
  margin-bottom: .2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.ep-card-date {
  font-size: .8rem;
  color: #888;
  font-family: var(--sans);
}

/* ── Homepage epaper strip ──────────────────────────────── */
.ep-home-section {
  background: #faf9f7;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 3rem 0 3.5rem;
  margin: 2rem 0;
}
.ep-home-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem;
}
.ep-home-hdr {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.75rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid var(--ink);
  position: relative;
}
.ep-home-hdr::after {
  content: '';
  position: absolute;
  bottom: -2px; left: 0;
  width: 52px; height: 2px;
  background: var(--primary);
}
.ep-home-title {
  font-family: var(--serif);
  font-size: clamp(1.3rem,2.5vw,1.75rem);
  font-weight: 900;
  letter-spacing: -.04em;
  color: var(--ink);
  display: flex;
  align-items: baseline;
  gap: .5rem;
}
.ep-home-title em {
  font-style: normal;
  font-size: .7em;
  color: var(--primary);
  font-family: var(--sans);
  font-weight: 700;
  letter-spacing: 0;
}
.ep-home-more {
  font-size: .9rem;
  font-family: var(--mono);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--primary);
  text-decoration: none;
  white-space: nowrap;
  flex-shrink: 0;
}
.ep-home-more:hover { text-decoration: underline; }
.ep-home-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1.25rem;
}
@media(max-width:1100px){ .ep-home-grid{ grid-template-columns: repeat(4,1fr); } }
@media(max-width:800px) { .ep-home-grid{ grid-template-columns: repeat(3,1fr); gap:1rem; } }
@media(max-width:560px) { .ep-home-grid{ grid-template-columns: repeat(2,1fr); gap:.75rem; } }

/* ── ePaper page grids ─────────────────────────────────── */
.ep-page { max-width: 1260px; margin: 0 auto; padding: 2.5rem 2rem 5rem; }
.ep-grid {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  gap: 1.5rem;
}
@media(max-width:1024px){ .ep-grid{ grid-template-columns: repeat(3,1fr); } }
@media(max-width:700px) { .ep-grid{ grid-template-columns: repeat(2,1fr); gap:1rem; } }
@media(max-width:420px) { .ep-grid{ grid-template-columns: 1fr 1fr; gap:.75rem; } }

/* page header */
.ep-title-block { text-align:center; padding-bottom:2rem; margin-bottom:2.5rem; border-bottom:2px solid var(--border); position:relative; }
.ep-title-block::before { content:''; position:absolute; bottom:-2px; left:50%; transform:translateX(-50%); width:48px; height:2px; background:var(--primary); }
.ep-title-block h1 { font-family:var(--serif); font-size:clamp(1.8rem,3.5vw,2.6rem); font-weight:900; letter-spacing:-.04em; color:var(--ink); margin-bottom:.4rem; }
.ep-title-block p { font-size:.9rem; color:var(--muted); }

/* filter tabs */
.ep-filters { display:flex; align-items:center; gap:.4rem; flex-wrap:wrap; margin-bottom:2.25rem; }
.ep-filter-label { font-family:var(--mono); font-size:.62rem; text-transform:uppercase; letter-spacing:.12em; color:var(--muted); margin-right:.4rem; }
.ep-filter-btn { padding:.38rem .9rem; font-size:.78rem; font-weight:600; font-family:var(--sans); border:1.5px solid var(--border); background:var(--paper); color:var(--muted); cursor:pointer; transition:all .16s; text-decoration:none; }
.ep-filter-btn:hover { border-color:var(--ink); color:var(--ink); text-decoration:none; }
.ep-filter-btn.active { background:var(--ink); border-color:var(--ink); color:var(--paper); }

/* source block */
.ep-source-block { margin-bottom:3.5rem; }
.ep-source-hdr { display:flex; align-items:center; justify-content:space-between; gap:1rem; margin-bottom:1.5rem; padding-bottom:.85rem; border-bottom:2px solid var(--ink); }
.ep-source-name { font-family:var(--serif); font-size:1.35rem; font-weight:900; letter-spacing:-.03em; color:var(--ink); display:flex; align-items:center; gap:.6rem; }
.ep-source-name::before { content:''; display:inline-block; width:4px; height:1.1em; background:var(--primary); flex-shrink:0; }
.ep-source-actions { display:flex; align-items:center; gap:.5rem; flex-shrink:0; }
.ep-visit-btn { display:inline-flex; align-items:center; gap:.35rem; padding:.38rem .9rem; background:var(--ink); color:var(--paper); font-size:.75rem; font-weight:700; font-family:var(--sans); text-decoration:none; transition:opacity .16s; }
.ep-visit-btn:hover { opacity:.8; color:var(--paper); text-decoration:none; }
.ep-rss-btn { display:inline-flex; align-items:center; gap:.3rem; padding:.38rem .85rem; border:1.5px solid #f26522; color:#f26522; font-size:.72rem; font-weight:600; font-family:var(--mono); text-decoration:none; transition:all .16s; }
.ep-rss-btn:hover { background:#f26522; color:#fff; text-decoration:none; }
.ep-rss-btn svg { width:12px; height:12px; }
.ep-error { padding:1.5rem 1.75rem; background:#fffbf0; border:1px solid #f0d87a; color:#7a5c00; font-size:.875rem; display:flex; align-items:center; gap:.75rem; }

/* ═══════════════════════════════════════════════════
   MOBILE DRAWER  (mob-* classes)
   Hidden offscreen by default, slides in on mobile
═══════════════════════════════════════════════════ */

/* Overlay backdrop */
.mobile-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,.55);
  z-index: 799;
  backdrop-filter: blur(2px);
}
/* JS adds class 'show' via openNav(); keep .open as alias */
.mobile-overlay.show,
.mobile-overlay.open { display: block; }

/* The drawer itself — hidden by default at ALL sizes, revealed only inside ≤900px media query */
.mobile-nav {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: min(320px, 88vw);
  background: #fff;
  z-index: 800;
  transform: translateX(-100%);
  transition: transform .26s cubic-bezier(.4,0,.2,1);
  overflow-y: auto;
  overflow-x: hidden;
  display: none;           /* ← hidden everywhere by default */
  flex-direction: column;
  box-shadow: 4px 0 32px rgba(0,0,0,.18);
}
.mobile-nav.open {
  transform: translateX(0);
}

/* Header row inside drawer */
.mob-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .85rem 1.1rem;
  border-bottom: 1px solid rgba(10,10,10,.09);
  flex-shrink: 0;
}
.mob-brand {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 900;
  letter-spacing: -.03em;
  color: var(--ink);
}

/* Search row */
.mob-search {
  padding: .65rem 1.1rem;
  border-bottom: 1px solid rgba(10,10,10,.07);
  flex-shrink: 0;
}
.mob-search form {
  display: flex;
  border: 1.5px solid rgba(10,10,10,.15);
  background: #f8f5f0;
  height: 36px;
}
.mob-search input {
  flex: 1;
  padding: 0 .8rem;
  border: none;
  background: transparent;
  font-size: .875rem;
  outline: none;
  color: var(--ink);
  font-family: var(--sans);
}
.mob-search button {
  background: var(--ink);
  color: #fff;
  border: none;
  padding: 0 .8rem;
  cursor: pointer;
  display: flex;
  align-items: center;
}
.mob-search button:hover { background: var(--primary); }

/* Nav list */
.mob-list {
  list-style: none;
  margin: 0;
  padding: .4rem 0;
  flex: 1;
}

/* Plain links */
.mob-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .7rem 1.25rem;
  font-size: .875rem;
  font-weight: 600;
  font-family: var(--sans);
  color: var(--ink);
  text-decoration: none;
  border: none;
  background: none;
  width: 100%;
  cursor: pointer;
  transition: background .12s;
  text-align: left;
}
.mob-link:hover { background: var(--cream); text-decoration: none; }

/* Separator */
.mob-sep {
  height: 1px;
  background: rgba(10,10,10,.08);
  margin: .4rem 1.1rem;
}

/* Accordion group */
.mob-group {}

.mob-toggle {
  font-weight: 700;
}
.mob-toggle .mob-caret {
  flex-shrink: 0;
  transition: transform .22s;
  color: var(--muted);
}
.mob-group.open > .mob-toggle .mob-caret { transform: rotate(180deg); }

/* Sub-list */
.mob-sub {
  list-style: none;
  margin: 0;
  padding: 0;
  background: #faf8f5;
  border-top: 1px solid rgba(10,10,10,.06);
  border-bottom: 1px solid rgba(10,10,10,.06);
  overflow: hidden;
  /* Animated expand via max-height toggle in JS */
}
.mob-sub[hidden] { display: none; }
.mob-sub-link {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .58rem 1.25rem .58rem 1.75rem;
  font-size: .84rem;
  font-weight: 500;
  color: #3a3530;
  text-decoration: none;
  transition: background .12s;
}
.mob-sub-link:hover { background: rgba(10,10,10,.04); text-decoration: none; }
.mob-sub-all {
  font-weight: 700;
  padding-left: 1.25rem;
  border-bottom: 1px solid rgba(10,10,10,.05);
  margin-bottom: .2rem;
}
.mob-sub-dot {
  width: 7px; height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
  display: inline-block;
}

/* Social icons row at bottom of drawer */
.mobile-nav-social {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .9rem 1.1rem;
  border-top: 1px solid rgba(10,10,10,.08);
  flex-shrink: 0;
}
.mobile-nav-social a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  color: var(--muted);
  text-decoration: none;
  border: 1.5px solid rgba(10,10,10,.1);
  transition: all .15s;
}
.mobile-nav-social a:hover { color: var(--ink); border-color: var(--ink); }
.mobile-nav-social svg { width: 16px; height: 16px; }


/* ── SEARCH OVERLAY ────────────────────────────────────────── */
/* Hidden by default; JS adds .open class to show it          */
.search-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 900;
  background: rgba(8,8,8,.82);
  backdrop-filter: blur(6px);
  align-items: flex-start;
  justify-content: center;
  padding-top: clamp(4rem, 12vw, 8rem);
}
.search-overlay.open { display: flex; }
.search-overlay-box {
  width: min(680px, 92vw);
  position: relative;
}
.search-overlay-form {
  display: flex;
  align-items: stretch;
  border: 2px solid rgba(255,255,255,.2);
  background: rgba(255,255,255,.06);
  backdrop-filter: blur(4px);
  transition: border-color .2s;
}
.search-overlay-form:focus-within {
  border-color: rgba(255,255,255,.55);
}
.search-overlay-form svg {
  flex-shrink: 0;
  align-self: center;
  margin: 0 .85rem;
  opacity: .45;
  color: #fff;
}
.search-overlay-form input {
  flex: 1;
  padding: 1rem .5rem;
  background: transparent;
  border: none;
  outline: none;
  font-family: var(--sans);
  font-size: 1.15rem;
  color: #fff;
}
.search-overlay-form input::placeholder { color: rgba(255,255,255,.3); }
.search-overlay-form button {
  padding: 0 1.25rem;
  background: var(--primary);
  color: #fff;
  border: none;
  cursor: pointer;
  font-family: var(--sans);
  font-size: .9rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  transition: background .18s;
  white-space: nowrap;
}
.search-overlay-form button:hover { background: var(--primary); filter: brightness(.82); }
.search-overlay-close {
  position: absolute;
  top: -2.8rem;
  right: 0;
  background: none;
  border: none;
  color: rgba(255,255,255,.45);
  cursor: pointer;
  padding: .25rem;
  transition: color .18s;
}
.search-overlay-close:hover { color: #fff; }

/* ─── Show drawer only on mobile (≤900px) ─── */
/* Base: both hidden on desktop */
.mobile-nav     { display: none; }
.mobile-overlay { display: none; }

@media (max-width: 900px) {
  /* Enable drawer as off-screen flex column; .open slides it in via transform */
  .mobile-nav { display: flex; }
  /* Overlay shown only when JS adds .show or .open */
  .mobile-overlay.show,
  .mobile-overlay.open { display: block; }
}

