/* ================================================================
   Sprasa Media CMS — Default Theme (BBC/Guardian-inspired)
   Complete Stylesheet v1.0
   ================================================================ */

/* ── CSS Variables ─────────────────────────────────────────────── */
:root {
  --primary:         #2563eb;
  --primary-dark:    #1d4ed8;
  --primary-light:   #dbeafe;
  --secondary:       #64748b;
  --dark:            #0f172a;
  --dark-2:          #1e293b;
  --light:           #f8fafc;
  --border:          #e2e8f0;
  --border-light:    #f1f5f9;
  --text:            #1e293b;
  --text-muted:      #64748b;
  --text-light:      #94a3b8;
  --success:         #10b981;
  --danger:          #ef4444;
  --warning:         #f59e0b;
  --breaking:        #dc2626;
  --footer-bg:       #0f172a;
  --footer-text:     #94a3b8;
  --footer-text-muted: #64748b;
  --nav-bg:          #1e3a5f;
  --nav-height:      48px;
  --radius:          8px;
  --radius-lg:       12px;
  --shadow:          0 1px 3px rgba(0,0,0,.1);
  --shadow-md:       0 4px 12px rgba(0,0,0,.12);
  --shadow-lg:       0 8px 24px rgba(0,0,0,.14);
  --transition:      .2s ease;
}

/* ── Reset & Base ──────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--text);
  background: #fff;
  line-height: 1.6;
  margin: 0;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--primary); text-decoration: none; }
a:hover { color: var(--primary-dark); }

.theme-default { background: #f8fafc; }

/* ── Top Bar ───────────────────────────────────────────────────── */
.topbar-strip {
  background: var(--dark);
  color: var(--text-light);
  font-size: 12px;
  padding: 6px 0;
  border-bottom: 1px solid #1e293b;
}
.topbar-date i { margin-right: 4px; }
.social-links { display: flex; gap: 12px; }
.social-links a { color: var(--text-light); font-size: 14px; transition: color var(--transition); }
.social-links a:hover { color: #fff; }
.auth-links { display: flex; gap: 12px; font-size: 12px; }
.auth-links a { color: var(--text-light); }
.auth-links a:hover { color: #fff; }

/* ── Site Header ───────────────────────────────────────────────────
   Looks only. Layout, height and ad sizing come from the shared
   themes/_shared/assets/css/header.css, which loads before this file. */
.site-header {
  background: #fff;
  border-bottom: 1px solid var(--border);
  box-shadow: var(--shadow);
}
.logo-text {
  font-weight: 800;
  color: var(--dark);
  font-family: 'Playfair Display', serif;
  letter-spacing: -0.5px;
}

/* ── Main Navigation ───────────────────────────────────────────── */
.main-nav {
  background: var(--nav-bg);
  position: relative;
  z-index: 999;
}
.nav-inner {
  display: flex;
  align-items: center;
  gap: 0;
  height: var(--nav-height);
  flex-wrap: wrap;
}
.nav-list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  height: 100%;
  align-items: stretch;
}
.nav-list li {
  position: relative;
  display: flex;
  align-items: stretch;
}
.nav-list li a {
  display: flex;
  align-items: center;
  padding: 0 16px;
  color: rgba(255,255,255,.85);
  font-size: 13.5px;
  font-weight: 500;
  white-space: nowrap;
  transition: background var(--transition), color var(--transition);
  text-decoration: none;
  height: 100%;
}
.nav-list li a:hover,
.nav-list li a.active { background: rgba(255,255,255,.12); color: #fff; }
.nav-has-home a { padding: 0 14px; font-size: 16px; }

/* Dropdown */
.has-dropdown > a i { font-size: 10px; margin-left: 4px; }
.dropdown-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: #fff;
  min-width: 200px;
  border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: var(--shadow-lg);
  list-style: none;
  padding: 8px 0;
  margin: 0;
  z-index: 1001;
}
.has-dropdown:hover .dropdown-nav { display: block; }
.dropdown-nav li a {
  color: var(--text) !important;
  padding: 8px 16px !important;
  font-size: 13px !important;
  background: transparent !important;
  height: auto !important;
}
.dropdown-nav li a:hover { background: var(--border-light) !important; color: var(--primary) !important; }

/* Nav search icon + expandable box */
.nav-search { position: relative; margin-left: auto; flex-shrink: 0; }
.nav-search-toggle {
  background: transparent; border: none; color: rgba(255,255,255,.85);
  font-size: 16px; padding: 0 16px; height: var(--nav-height); cursor: pointer;
  transition: color var(--transition);
}
.nav-search-toggle:hover { color: #fff; }
.nav-search-box {
  display: none; position: absolute; top: 100%; right: 0; margin-top: 1px;
  background: #fff; padding: 10px; border-radius: 0 0 var(--radius) var(--radius);
  box-shadow: var(--shadow-lg); z-index: 1002; gap: 0;
}
.nav-search-box.open { display: flex; }
.nav-search-box input {
  border: 2px solid var(--border); border-right: none; border-radius: 50px 0 0 50px;
  padding: 8px 16px; font-size: 14px; outline: none; width: 200px;
  transition: border-color var(--transition);
}
.nav-search-box input:focus { border-color: var(--primary); }
.nav-search-box button {
  background: var(--primary); border: none; color: #fff; padding: 8px 16px;
  border-radius: 0 50px 50px 0; cursor: pointer; transition: background var(--transition);
}
.nav-search-box button:hover { background: var(--primary-dark); }

/* ── Breaking News Ticker ──────────────────────────────────────── */
.breaking-ticker {
  background: #fff;
  border-bottom: 1px solid var(--border);
  padding: 8px 0;
  overflow: hidden;
}
.ticker-inner { display: flex; align-items: center; gap: 12px; overflow: hidden; }
.ticker-label {
  background: var(--breaking);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  white-space: nowrap;
  text-transform: uppercase;
  letter-spacing: .5px;
  flex-shrink: 0;
}
.ticker-track { flex: 1; overflow: hidden; }
.ticker-items { display: flex; gap: 32px; animation: ticker 30s linear infinite; }
.ticker-item {
  white-space: nowrap;
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  flex-shrink: 0;
}
.ticker-item::before { content: '•'; margin-right: 8px; color: var(--breaking); }
.ticker-item:hover { color: var(--primary); }
@keyframes ticker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* ── Hero Section ──────────────────────────────────────────────── */
.hero-main {
  display: block;
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  height: 420px;
  background: var(--dark);
}
.hero-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.hero-main:hover img { transform: scale(1.02); }
.hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 24px;
  background: linear-gradient(0deg, rgba(0,0,0,.85) 0%, rgba(0,0,0,.4) 60%, transparent 100%);
}
.hero-cat {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 4px;
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 8px;
}
.hero-title {
  color: #fff;
  font-size: 26px;
  font-weight: 800;
  line-height: 1.25;
  margin: 6px 0 10px;
  font-family: 'Playfair Display', serif;
  text-shadow: 0 1px 3px rgba(0,0,0,.3);
}
.hero-meta { display: flex; gap: 16px; color: rgba(255,255,255,.75); font-size: 12px; }
.hero-meta span { display: flex; align-items: center; gap: 4px; }

/* ── Lead Story (big feature block: headline → image → caption) ──── */
.lead-story-head { text-align: center; max-width: 780px; margin: 0 auto 16px; }
.lead-title { font-size: 28px; font-weight: 800; line-height: 1.25; margin: 10px 0; font-family: 'Playfair Display', serif; color: var(--dark); }
.lead-title a { color: inherit; text-decoration: none; }
.lead-title a:hover { color: var(--primary); }
.lead-subtitle { font-size: 16px; color: var(--text-muted); margin-bottom: 10px; line-height: 1.5; }
.lead-byline { font-size: 13px; font-weight: 600; color: var(--primary); margin-bottom: 4px; }
.lead-image-link { border-radius: var(--radius-lg); overflow: hidden; display: block; }
.lead-image { width: 100%; max-height: 480px; object-fit: cover; }
.lead-caption { font-size: 14px; color: var(--text-muted); text-align: center; margin: 14px auto 0; max-width: 780px; }
.lead-caption-link { font-weight: 600; color: var(--primary); margin-left: 6px; white-space: nowrap; }
.lead-story-text { padding-bottom: 16px; border-bottom: 1px solid var(--border-light); }
.lead-story-text .lead-story-head { margin-bottom: 0; }

/* ── Article Cards ─────────────────────────────────────────────── */
.article-card {
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform var(--transition), box-shadow var(--transition);
  display: flex;
  flex-direction: column;
}
.article-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}
.card-img-wrapper {
  position: relative;
  overflow: hidden;
  aspect-ratio: 16/9;
  background: var(--border-light);
}
.card-img-wrapper img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s ease;
}
.article-card:hover .card-img-wrapper img { transform: scale(1.04); }
.card-badges {
  position: absolute;
  top: 8px;
  left: 8px;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.badge-cat {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 3px;
  text-transform: uppercase;
  letter-spacing: .4px;
}
.badge-breaking { background: var(--breaking); }
.badge-featured  { background: var(--warning);  color: var(--dark); }
.badge-status    { font-size: 10px; font-weight: 700; padding: 2px 8px; border-radius: 3px; text-transform: uppercase; letter-spacing: .4px; }

.card-body { padding: 14px; flex: 1; display: flex; flex-direction: column; }
.card-meta {
  font-size: 11px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}
.dot {
  width: 3px;
  height: 3px;
  background: var(--text-light);
  border-radius: 50%;
  flex-shrink: 0;
}
.card-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--dark);
  line-height: 1.35;
  margin: 0 0 8px;
}
.card-title.large { font-size: 18px; }
.card-title.small { font-size: 13px; font-weight: 600; }
.card-title a { color: inherit; text-decoration: none; }
.card-title a:hover { color: var(--primary); }
.card-summary { font-size: 13px; color: var(--text-muted); line-height: 1.55; margin: 0 0 8px; flex: 1; }
.card-footer-meta {
  display: flex;
  gap: 12px;
  font-size: 11px;
  color: var(--text-light);
  align-items: center;
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--border-light);
}
.card-footer-meta span { display: flex; align-items: center; gap: 3px; }

/* Horizontal card */
.article-card-h {
  display: flex;
  gap: 10px;
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: box-shadow var(--transition);
  padding: 8px;
}
.article-card-h:hover { box-shadow: var(--shadow-md); }
.article-card-h .card-img-wrapper {
  border-radius: 6px;
  aspect-ratio: 1;
  flex-shrink: 0;
  height: 80px;
  width: 80px;
}
.article-card-h .card-body { padding: 0; }

/* ── Section Headers ───────────────────────────────────────────── */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--border);
}
.section-title {
  font-size: 18px;
  font-weight: 800;
  color: var(--dark);
  margin: 0;
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 3px solid var(--primary);
  padding-bottom: 10px;
  margin-bottom: -12px;
}
.section-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  white-space: nowrap;
}
.section-link:hover { color: var(--primary-dark); }

/* ── Sidebar ───────────────────────────────────────────────────── */
.sidebar { display: flex; flex-direction: column; gap: 20px; }
.sidebar-widget {
  background: #fff;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.widget-title {
  font-size: 14px;
  font-weight: 700;
  color: var(--dark);
  margin: 0;
  padding: 12px 16px;
  background: var(--border-light);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.widget-body { padding: 12px 16px; }

/* Most Viewed List */
.most-viewed-list {
  list-style: none;
  margin: 0;
  padding: 8px 0;
}
.most-viewed-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-light);
}
.most-viewed-list li:last-child { border-bottom: none; }
.mv-rank {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--border-light);
  color: var(--text-muted);
  font-size: 12px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.mv-rank.top { background: var(--primary); color: #fff; }
.mv-info { flex: 1; min-width: 0; }
.mv-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--dark);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.mv-title:hover { color: var(--primary); }
.mv-meta { font-size: 11px; color: var(--text-light); margin-top: 3px; display: flex; align-items: center; gap: 4px; }

/* Newsletter Widget */
.newsletter-widget {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  border-radius: var(--radius-lg);
  padding: 20px;
  color: #fff;
}
.newsletter-widget h5 { color: #fff; font-weight: 700; margin-bottom: 6px; }
.newsletter-widget p { color: rgba(255,255,255,.8); font-size: 13px; margin-bottom: 14px; }
.newsletter-form .form-control {
  border-radius: var(--radius) 0 0 var(--radius);
  border: none;
  font-size: 13px;
  padding: 8px 12px;
}
.newsletter-form .input-group { flex-wrap: nowrap; }

/* Tag Cloud */
.tag-cloud { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-pill {
  display: inline-block;
  background: var(--border-light);
  color: var(--text-muted);
  font-size: 12px;
  padding: 4px 10px;
  border-radius: 20px;
  transition: background var(--transition), color var(--transition);
  text-decoration: none;
}
.tag-pill:hover { background: var(--primary); color: #fff; }

/* Poll Widget */
.poll-option { cursor: pointer; }
.poll-option:hover .progress-bar { filter: brightness(1.1); }

/* ── Fade In Animation ─────────────────────────────────────────── */
.fade-in-up {
  animation: fadeInUp .4s ease both;
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ── Article Page ──────────────────────────────────────────────── */
/* ── Article card ──────────────────────────────────────────────────
   The article had a background but no padding, so every line of text
   started hard against the left edge of the column — nothing to rest the
   eye on, and uncomfortable to read at length. It's now a proper card
   with breathing room on both sides. */
.article-single {
  background: var(--bg-card, #fff);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 34px 38px;
  margin-bottom: 24px;
  /* Keeps the full-bleed photo inside the rounded corners. */
  overflow: hidden;
}

/* The featured photo spans the whole card while the text keeps its
   margins — the usual news-site treatment, and it stops the picture
   looking like it has been shrunk to fit. */
.article-featured-img { margin: 0 -38px 26px; border-radius: 0; }
.article-featured-img img { width: 100%; display: block; }
.article-featured-img .img-caption { padding: 8px 38px 0; }

@media (max-width: 767.98px) {
  .article-single { padding: 20px 18px; border-radius: var(--radius); }
  .article-featured-img { margin: 0 -18px 20px; }
  .article-featured-img .img-caption { padding: 8px 18px 0; }
}
.article-hero { border-radius: var(--radius-lg); overflow: hidden; margin-bottom: 28px; }
.article-hero img { width: 100%; max-height: 480px; object-fit: cover; }
.article-header { margin-bottom: 24px; }
.article-category {
  display: inline-flex;
  align-items: center;
  background: var(--primary);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .3px;
  text-transform: uppercase;
  padding: 4px 12px;
  border-radius: 4px;
  text-decoration: none;
}
.article-category:hover { opacity: .9; color: #fff; }
.article-title {
  font-size: 32px;
  font-weight: 800;
  line-height: 1.2;
  color: var(--dark);
  font-family: 'Playfair Display', serif;
  margin-bottom: 16px;
}
.article-subtitle {
  font-size: 18px;
  line-height: 1.5;
  color: var(--text-muted);
  font-family: 'Merriweather', serif;
  margin-bottom: 16px;
}
.article-meta { display: flex; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--text-muted); align-items: center; }
.article-meta i { margin-right: 3px; }
.article-author { display: flex; align-items: center; gap: 8px; }
.author-avatar { width: 36px; height: 36px; border-radius: 50%; object-fit: cover; }
.author-name { color: var(--text); font-weight: 600; }
.article-featured-img { margin: 24px 0; border-radius: var(--radius-lg); overflow: hidden; }
.article-featured-img img { display: block; }
.img-caption { font-size: 12px; color: var(--text-muted); padding: 8px 4px 0; font-style: italic; }
.article-body { padding-bottom: 24px; }
/* Article body typography, the designed blocks (pull quote, key points,
   fact box, data table) and the staff bar now live in
   themes/_shared/assets/css/article-typography.css, so the admin editor
   can load exactly the same rules and show what will publish. */

.gallery-link { display: block; }

/* ── Tags ──────────────────────────────────────────────────────── */
.article-tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 24px 0; align-items: center; }
.article-tag, .tag-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: var(--border-light);
  color: var(--text-muted);
  padding: 5px 12px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: background var(--transition), color var(--transition);
}
.article-tag:hover, .tag-link:hover { background: var(--primary); color: #fff; }

/* ── Author Box ────────────────────────────────────────────────── */
.author-box {
  background: var(--border-light);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin: 32px 0;
}
.author-box img { width: 64px; height: 64px; border-radius: 50%; object-fit: cover; flex-shrink: 0; }
.author-box h4 { font-size: 16px; font-weight: 700; margin: 0 0 4px; }
.author-box p { font-size: 13px; color: var(--text-muted); margin: 0; }

/* ── Share Bar ─────────────────────────────────────────────────── */
.share-bar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 20px 0; padding: 16px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.share-label { font-size: 13px; font-weight: 600; color: var(--text-muted); }
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 14px;
  border-radius: var(--radius);
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: none;
  background: var(--border-light);
  color: var(--text);
  transition: opacity var(--transition), transform var(--transition);
}
.share-btn:hover { opacity: .85; transform: translateY(-1px); }
.share-fb   { background: #1877f2; color: #fff; }
.share-tw   { background: #000;    color: #fff; }
.share-wa   { background: #25d366; color: #fff; }
.share-li   { background: #0a66c2; color: #fff; }
.share-copy { background: var(--border-light); color: var(--text); }

/* ── Comments ──────────────────────────────────────────────────── */
.comment-item { display: flex; gap: 12px; padding: 16px 0; border-bottom: 1px solid var(--border); }
.comment-item:last-child { border-bottom: none; }
.comment-avatar {
  width: 40px; height: 40px; border-radius: 50%; object-fit: cover; flex-shrink: 0;
  background: var(--primary-light); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 14px;
}
.comment-body { background: var(--border-light); border-radius: var(--radius); padding: 12px 16px; font-size: 14px; flex: 1; }
.comment-header { display: flex; align-items: baseline; gap: 8px; margin-bottom: 4px; flex-wrap: wrap; }
.comment-author { font-weight: 700; font-size: 14px; color: var(--text); }
.comment-time, .comment-date { font-size: 12px; color: var(--text-light); }
.comment-text { font-size: 14px; line-height: 1.6; color: var(--text); margin: 0; }
.comment-reply-btn {
  background: none; border: none; padding: 0; margin-top: 6px;
  font-size: 12px; font-weight: 600; color: var(--primary); cursor: pointer;
}
.comment-reply-btn:hover { text-decoration: underline; }

/* ── Search Page ───────────────────────────────────────────────── */
.search-result { padding: 20px 0; border-bottom: 1px solid var(--border); }
.search-result:last-child { border-bottom: none; }
.search-result h3 { font-size: 18px; font-weight: 700; margin: 0 0 6px; }
.search-result p  { font-size: 14px; color: var(--text-muted); margin: 0 0 8px; }

/* ── Breadcrumbs ───────────────────────────────────────────────── */
.breadcrumb { font-size: 13px; background: transparent; padding: 8px 0; margin-bottom: 20px; }
.breadcrumb-item + .breadcrumb-item::before { color: var(--text-light); }
.breadcrumb-item a { color: var(--primary); text-decoration: none; }

/* ── Pagination ────────────────────────────────────────────────── */
.pagination .page-link {
  color: var(--primary);
  border-radius: var(--radius) !important;
  margin: 0 2px;
  border: 1px solid var(--border);
  padding: 7px 13px;
}
.pagination .page-item.active .page-link { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination .page-link:hover { background: var(--border-light); color: var(--primary); }

/* ── Ad Zones ──────────────────────────────────────────────────── */
.ad-zone { text-align: center; margin: 20px 0; }
.ad-zone .ad-label {
  display: block; font-size: 10px; font-weight: 600; text-transform: uppercase;
  letter-spacing: .6px; color: var(--text-light); margin-bottom: 8px;
}
.ad-zone img {
  margin: 0 auto; max-width: 100%; height: auto; border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* ── Footer ────────────────────────────────────────────────────── */
.site-footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: 48px 0 0;
  margin-top: 48px;
}
.footer-top { padding-bottom: 32px; }
.footer-brand { margin-bottom: 14px; }
.footer-site-name { font-size: 22px; font-weight: 800; color: #fff; font-family: 'Playfair Display', serif; }
.footer-logo { height: 40px; width: auto; }
.footer-desc { font-size: 13px; color: var(--footer-text-muted); line-height: 1.6; margin-bottom: 14px; }
.footer-social { display: flex; gap: 12px; }
.footer-social a { color: var(--footer-text); font-size: 18px; transition: color var(--transition); }
.footer-social a:hover { color: #fff; }
.footer-heading { font-size: 13px; font-weight: 700; color: #fff; text-transform: uppercase; letter-spacing: .6px; margin-bottom: 14px; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: var(--footer-text-muted); font-size: 13px; transition: color var(--transition); }
.footer-links a:hover { color: #fff; }
.footer-contact a { color: var(--footer-text-muted); font-size: 13px; display: flex; align-items: center; gap: 6px; }
.footer-contact a:hover { color: #fff; }
.footer-bottom {
  border-top: 1px solid #1e293b;
  padding: 16px 0;
  font-size: 12px;
  color: var(--footer-text-muted);
}
.footer-bottom a { color: var(--footer-text-muted); }
.footer-bottom a:hover { color: #fff; }

/* ── Popup Ad ──────────────────────────────────────────────────── */
.popup-ad-overlay { position: fixed; inset: 0; background: rgba(0,0,0,.65); display: none; align-items: center; justify-content: center; z-index: 2000; padding: 20px; }
.popup-ad-overlay.visible { display: flex; }
.popup-ad-box { position: relative; max-width: 92vw; max-height: 90vh; }
.popup-ad-box .ad-zone { margin: 0; }
.popup-ad-box .ad-label { display: none; }
.popup-ad-box img { max-width: 100%; max-height: 80vh; display: block; border-radius: var(--radius); }
.popup-ad-close { position: absolute; top: -14px; right: -14px; width: 32px; height: 32px; border-radius: 50%; background: #fff; border: none; font-size: 20px; line-height: 1; cursor: pointer; box-shadow: 0 2px 10px rgba(0,0,0,.35); color: #111; }
.popup-ad-close:hover { background: #f1f5f9; }

/* ── Back to Top ───────────────────────────────────────────────── */
.back-to-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  border: none;
  display: none;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(37,99,235,.4);
  z-index: 999;
  font-size: 18px;
  transition: opacity var(--transition);
}
.back-to-top.visible { display: flex; }
.back-to-top:hover { opacity: .85; }

/* ── Cookie Banner ─────────────────────────────────────────────── */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #1e293b;
  color: #fff;
  padding: 16px 0;
  z-index: 9999;
  box-shadow: 0 -4px 20px rgba(0,0,0,.2);
}
.cookie-banner a { color: #93c5fd; }

/* ── Admin Notices ─────────────────────────────────────────────── */
.alert { border-radius: var(--radius); font-size: 14px; }

/* ── Responsive ────────────────────────────────────────────────── */
@media (max-width: 991px) {
  .hero-main { height: 320px; }
  .hero-title { font-size: 20px; }
  .article-title { font-size: 24px; }
  /* A sticky masthead eats too much of a phone screen — the nav bar below
     it stays reachable anyway. Overrides the hd-sticky setting on purpose. */
  .site-header.hd-sticky { position: static; }
  /* Main categories scroll horizontally instead of hiding behind a
     hamburger toggle — far more discoverable on mobile, and lets people
     swipe straight to a category without an extra tap to open a menu.
     nav-list shares the row with the search icon (flex:1) rather than
     taking the full width and pushing the icon onto its own line. */
  .nav-list {
    display: flex; flex-direction: row; flex-wrap: nowrap; flex: 1; min-width: 0; height: auto;
    overflow-x: auto; overflow-y: hidden; -webkit-overflow-scrolling: touch;
    scrollbar-width: none; -ms-overflow-style: none;
    scroll-snap-type: x proximity; scroll-padding-left: 8px;
    -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent 100%);
    mask-image: linear-gradient(to right, #000 calc(100% - 28px), transparent 100%);
  }
  .nav-list::-webkit-scrollbar { display: none; }
  .nav-list li { height: auto; flex-shrink: 0; scroll-snap-align: start; }
  .nav-list li a { padding: 10px 16px; }
  .dropdown-nav { position: absolute; }
  .nav-search-box { right: 0; left: auto; }
  .nav-search-box input { width: 140px; }
}
@media (max-width: 575px) {
  .hero-main { height: 240px; }
  .hero-title { font-size: 17px; }
  .article-title { font-size: 20px; }
  .share-bar { gap: 6px; }
  .share-btn { padding: 6px 10px; font-size: 12px; }
}

/* -- Ad Width / Column Options ------------------------------------
   Works in both contexts: a single ad injected into the article body,
   and several ads laid out side by side inside .ad-row. */
.ad-w-full    { --ad-w: 100%; }
.ad-w-half    { --ad-w: 50%; }
.ad-w-third   { --ad-w: 33.333%; }
.ad-w-quarter { --ad-w: 25%; }

.ad-zone[class*="ad-w-"] { max-width: var(--ad-w, 100%); margin-left: auto; margin-right: auto; }

.ad-row { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; align-items: flex-start; margin: 20px 0; }
.ad-row .ad-zone { margin: 0; flex: 1 1 var(--ad-w, 100%); max-width: var(--ad-w, 100%); }

@media (max-width: 767px) {
  .ad-zone[class*="ad-w-"],
  .ad-row .ad-zone { max-width: 100%; flex-basis: 100%; }
}

/* -- Byline avatar (per-block "author photo" toggle) ---------------- */
.byline-avatar {
  width: 20px; height: 20px; border-radius: 50%; object-fit: cover;
  flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center;
}
.byline-initials {
  background: var(--border-light); color: var(--text-muted);
  font-size: 10px; font-weight: 700; line-height: 1;
}
.lead-byline { display: inline-flex; align-items: center; gap: 6px; justify-content: center; }
.lead-byline-date { color: var(--text-light); font-weight: 400; }
.lead-story-head .lead-byline { display: flex; }

/* -- Category block styles (per-category layout choice) ------------- */
.cat-list { display: flex; flex-direction: column; }
.cat-list-item {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 0; border-bottom: 1px solid var(--border-light);
}
.cat-list-item:last-child { border-bottom: none; }
.cat-list-num {
  font-size: 18px; font-weight: 800; color: var(--border);
  min-width: 26px; text-align: center; flex-shrink: 0;
}
.cat-list-thumb { width: 88px; height: 62px; flex-shrink: 0; overflow: hidden; border-radius: var(--radius-sm, 6px); }
.cat-list-thumb img { width: 100%; height: 100%; object-fit: cover; }
.cat-list-body { min-width: 0; flex: 1; }

.cat-showcase-lead .card-img-wrapper img { width: 100%; height: 100%; object-fit: cover; }

.cat-block-compact .article-card-h { height: 100%; }

@media (max-width: 575px) {
  .cat-list-thumb { width: 64px; height: 48px; }
  .cat-list-num { min-width: 20px; font-size: 15px; }
}
