/**
 * FlutterFever - Professional WordPress Theme
 * 2026 Modern Publisher-Grade Magazine Layout & Typography
 * Ultra-Fast, Mobile-Responsive, Ads-Optimized & Secure
 */

:root {
  /* Brand Tokens */
  --brand-primary: #02569b;
  --brand-secondary: #0175c2;
  --brand-accent: #13b9fd;
  --brand-teal: #00b4ab;
  --gradient-brand: linear-gradient(135deg, #02569b 0%, #0175c2 55%, #13b9fd 100%);
  --gradient-badge: linear-gradient(135deg, #0175c2 0%, #02569b 100%);
  --gradient-num1: linear-gradient(135deg, #02569b 0%, #0175c2 100%);
  --gradient-num2: linear-gradient(135deg, #0175c2 0%, #13b9fd 100%);
  --gradient-num3: linear-gradient(135deg, #00b4ab 0%, #13b9fd 100%);

  /* Light Theme */
  --bg-body: #f4f7fb;
  --bg-surface: #ffffff;
  --bg-surface-elevated: #ffffff;
  --bg-muted: #eef2f8;
  --bg-input: #f8fafc;
  --bg-code: #0b1120;
  --bg-topbar: #080d1a;
  --bg-footer: #080d1a;

  --text-main: #0f172a;
  --text-muted: #475569;
  --text-light: #64748b;
  --text-code: #f1f5f9;
  --text-topbar: #94a3b8;
  --text-footer: #cbd5e1;
  --text-footer-muted: #94a3b8;

  --border-color: #e2e8f0;
  --border-subtle: #edf2f7;
  --border-footer: #172138;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.04), 0 1px 2px rgba(0, 0, 0, 0.02);
  --shadow-md: 0 4px 8px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -2px rgba(0, 0, 0, 0.03);
  --shadow-lg: 0 12px 20px -3px rgba(0, 0, 0, 0.08), 0 4px 6px -4px rgba(0, 0, 0, 0.03);
  --shadow-dropdown: 0 14px 30px rgba(0, 0, 0, 0.12), 0 4px 10px rgba(0, 0, 0, 0.05);
  --shadow-hover: 0 14px 22px -4px rgba(1, 117, 194, 0.14);

  --font-sans: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', Consolas, monospace;

  --radius-xs: 4px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-full: 9999px;

  --max-width: 1240px;
  --header-height: 70px;
  --transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] {
  --bg-body: #050811;
  --bg-surface: #0c1222;
  --bg-surface-elevated: #111a30;
  --bg-muted: #141e36;
  --bg-input: #0f172b;
  --bg-code: #03060d;
  --bg-topbar: #03050a;
  --bg-footer: #03050a;

  --text-main: #f8fafc;
  --text-muted: #94a3b8;
  --text-light: #64748b;
  --text-code: #f8fafc;
  --text-topbar: #94a3b8;
  --text-footer: #cbd5e1;
  --text-footer-muted: #64748b;

  --border-color: #1a2642;
  --border-subtle: #121b30;
  --border-footer: #111a2e;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.6);
  --shadow-dropdown: 0 16px 36px rgba(0, 0, 0, 0.7);
  --shadow-hover: 0 14px 22px -4px rgba(19, 185, 253, 0.16);
}

/* Global Resets */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-body);
  color: var(--text-main);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.25s ease, color 0.25s ease;
}

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

a:hover {
  color: var(--brand-accent);
}

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

ul, ol {
  list-style: none;
  margin: 0;
  padding: 0;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* Reading Progress Bar */
#reading-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: var(--gradient-brand);
  z-index: 10000;
  transition: width 0.1s ease-out;
}

/* ==========================================================================
   Global SVG Icons & Metadata Precision Alignment System
   ========================================================================== */

/* Universal SVG Icon alignment & rendering */
svg.icon,
.icon,
svg {
  vertical-align: middle;
  flex-shrink: 0;
}

/* Metadata Containers & Items - Pixel-Perfect Center Alignment */
.meta-item,
.meta-author-row,
.meta-author-group,
.section-badge-icon,
.cat-pill-left,
.cat-pill-icon,
.tags-label,
.perk-item,
.popular-post-meta,
.post-card-meta,
.hero-card-meta,
.hero-sub-meta,
.single-meta-bar {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  line-height: 1.2;
  vertical-align: middle;
}

/* Standardized metadata icon sizing */
.meta-item svg,
.popular-post-meta svg,
.post-card-meta svg,
.hero-card-meta svg,
.hero-sub-meta svg,
.single-meta-bar .meta-item svg {
  width: 14px;
  height: 14px;
  min-width: 14px;
  min-height: 14px;
  display: inline-block;
  vertical-align: middle;
  position: relative;
  top: -0.5px;
  stroke-width: 2px;
  color: var(--brand-secondary);
  opacity: 0.9;
}

/* Author Mini Badge Circle (Precision Centered Letter) */
.author-circle-mini {
  width: 22px;
  height: 22px;
  min-width: 22px;
  min-height: 22px;
  border-radius: 50%;
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1;
  text-transform: uppercase;
  flex-shrink: 0;
  box-shadow: 0 1px 4px rgba(1, 117, 194, 0.25);
}

.author-avatar-badge {
  width: 28px;
  height: 28px;
  min-width: 28px;
  min-height: 28px;
  border-radius: 50%;
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.75rem;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  line-height: 1;
  text-transform: uppercase;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(1, 117, 194, 0.25);
}

/* Clean Separator Dot */
.meta-sep {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  opacity: 0.45;
  font-size: 0.75rem;
  line-height: 1;
  margin: 0 2px;
  user-select: none;
}

/* 1. Topbar (Publisher Magazine Style) */
.site-topbar {
  background: var(--bg-topbar);
  color: var(--text-topbar);
  font-size: 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding: 7px 0;
  line-height: 1.2;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.topbar-left {
  display: flex;
  align-items: center;
  gap: 12px;
  overflow: hidden;
  flex: 1;
  min-width: 0;
}

.topbar-tag {
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  letter-spacing: 0.6px;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  text-transform: uppercase;
}

.trending-ticker-wrap {
  position: relative;
  height: 22px;
  overflow: hidden;
  flex: 1;
  min-width: 0;
}

.trending-ticker-items {
  position: relative;
  width: 100%;
  height: 100%;
}

.trending-ticker-item {
  display: none !important;
  font-size: 0.82rem;
  color: #cbd5e1;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 22px;
  font-weight: 500;
  transition: color 0.2s ease;
}

.trending-ticker-item.active {
  display: block !important;
  animation: tickerSlideIn 0.45s ease forwards;
}

.trending-ticker-item.leaving {
  display: block !important;
  animation: tickerSlideOut 0.45s ease forwards;
}

@keyframes tickerSlideIn {
  0% {
    opacity: 0;
    transform: translateY(14px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes tickerSlideOut {
  0% {
    opacity: 1;
    transform: translateY(0);
  }
  100% {
    opacity: 0;
    transform: translateY(-14px);
  }
}

.trending-ticker-item:hover {
  color: #38bdf8 !important;
  text-decoration: underline;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.topbar-date {
  font-size: 0.78rem;
  color: #94a3b8;
  white-space: nowrap;
}

.topbar-social {
  display: flex;
  align-items: center;
  gap: 10px;
}

.topbar-social a {
  color: #94a3b8;
  display: flex;
  align-items: center;
  transition: color 0.2s ease, transform 0.2s ease;
}

.topbar-social a:hover {
  color: #fff;
  transform: translateY(-1px);
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}

.topbar-date {
  color: #64748b;
  font-size: 0.75rem;
  font-weight: 500;
}

.topbar-social {
  display: flex;
  align-items: center;
  gap: 8px;
}

.topbar-social a {
  color: #94a3b8;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-xs);
  background: rgba(255, 255, 255, 0.05);
  transition: var(--transition);
}

.topbar-social a:hover {
  color: #fff;
  background: var(--brand-secondary);
}

/* 2. Main Navigation Header */
.site-header {
  position: sticky;
  top: 0;
  height: var(--header-height);
  background: var(--bg-surface);
  border-bottom: 1px solid var(--border-color);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  z-index: 999;
  display: flex;
  align-items: center;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  min-width: 0;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 0 1 auto;
  min-width: 0;
  max-width: calc(100% - 130px);
  text-decoration: none;
}

.logo-icon-wrap {
  width: 36px;
  height: 36px;
  min-width: 36px;
  border-radius: var(--radius-sm);
  background: rgba(1, 117, 194, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.logo-text-group {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.15;
  color: var(--brand-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
  max-width: 100%;
}

.brand-name .fever {
  background: var(--gradient-brand);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.brand-sub {
  font-size: 0.6rem;
  font-weight: 800;
  letter-spacing: 0.8px;
  color: var(--text-light);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Navigation & Sub-menus */
.main-nav-container {
  display: flex;
  align-items: center;
  flex: 1;
  margin-left: 8px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
}

.main-nav > li {
  position: relative;
  list-style: none;
}

.main-nav > li > a {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 8px 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

.main-nav > li > a:hover,
.main-nav > li.current-menu-item > a,
.main-nav > li.current-post-parent > a,
.main-nav > li.current-menu-ancestor > a {
  color: var(--brand-secondary);
  background: var(--bg-muted);
}

.main-nav li.menu-item-has-children > a::after {
  content: '';
  display: inline-block;
  width: 4px;
  height: 4px;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: rotate(45deg);
  margin-top: -2px;
  transition: transform 0.2s ease;
}

.main-nav li.menu-item-has-children:hover > a::after {
  transform: rotate(-135deg);
  margin-top: 2px;
}

/* Dropdown Sub-menus */
.main-nav ul.sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 220px;
  background: var(--bg-surface-elevated);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-dropdown);
  padding: 6px;
  list-style: none;
  margin: 4px 0 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(6px);
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 1000;
}

.main-nav li:hover > ul.sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.main-nav ul.sub-menu li {
  position: relative;
  list-style: none;
  margin: 0;
}

.main-nav ul.sub-menu a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-main);
  border-radius: var(--radius-xs);
  white-space: nowrap;
}

.main-nav ul.sub-menu a:hover {
  background: var(--bg-muted);
  color: var(--brand-secondary);
}

.nav-item-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-secondary);
  opacity: 0.85;
  transition: transform 0.2s ease;
}

.main-nav ul.sub-menu a:hover .nav-item-icon {
  transform: scale(1.15);
  color: var(--brand-accent);
}

.nav-item-label {
  flex: 1;
}

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

.theme-toggle-btn,
.mobile-nav-toggle {
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.theme-toggle-btn:hover,
.mobile-nav-toggle:hover {
  background: var(--border-color);
  color: var(--brand-secondary);
  transform: translateY(-1px);
}

.mobile-nav-toggle {
  display: none;
}

/* 3. 2026 Publisher-Grade Hero Showcase (Clean Thumbnail Layout) */
/* 3. 2026 Publisher-Grade Hero Showcase (1 Large Featured + 2 Fitted Right Cards) */
.hero-showcase-section {
  margin: 24px 0 36px;
}

.hero-showcase-grid {
  display: grid;
  grid-template-columns: 1.45fr 1fr;
  gap: 22px;
  align-items: stretch;
}

/* 1. Primary Left Featured Card */
.hero-primary-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.hero-primary-card:hover {
  box-shadow: var(--shadow-hover);
  border-color: rgba(1, 117, 194, 0.4);
  transform: translateY(-2px);
}

.hero-thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  overflow: hidden;
  background: var(--bg-muted);
  display: block;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}

.hero-primary-card:hover .hero-img {
  transform: scale(1.04);
}

.fallback-hero-icon {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-secondary);
  background: var(--bg-muted);
}

.hero-floating-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  letter-spacing: 0.6px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  z-index: 2;
}

.hero-card-body {
  padding: 22px 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
  justify-content: space-between;
}

.category-badge {
  display: inline-flex;
  align-items: center;
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: var(--radius-xs);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  align-self: flex-start;
  margin-bottom: 8px;
}

.cat-badge-sm {
  font-size: 0.65rem;
  padding: 2px 7px;
  margin-bottom: 6px;
}

.cat-badge-xs {
  font-size: 0.65rem;
  padding: 2px 7px;
}

.hero-primary-title {
  font-size: 1.32rem;
  font-weight: 800;
  line-height: 1.35;
  margin: 8px 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-primary-title a {
  color: var(--text-main);
  transition: color 0.2s ease;
}

.hero-primary-title a:hover {
  color: var(--brand-secondary);
}

.hero-primary-excerpt {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin: 10px 0 16px;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.78rem;
  color: var(--text-light);
  border-top: 1px solid var(--border-subtle);
  padding-top: 12px;
}

/* 2. Secondary Right Stacked Cards (Full Width Top Thumbnail - Equal Height Aligned) */
.hero-secondary-column {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 16px;
  height: 100%;
}

.hero-secondary-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  height: 100%;
}

.hero-secondary-card:hover {
  box-shadow: var(--shadow-hover);
  border-color: rgba(1, 117, 194, 0.4);
  transform: translateY(-2px);
}

.hero-sub-thumb-wrap {
  position: relative;
  width: 100%;
  height: 140px;
  max-height: 140px;
  overflow: hidden;
  background: var(--bg-muted);
  display: block;
  flex-shrink: 0;
}

.hero-sub-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
  display: block;
}

.hero-secondary-card:hover .hero-sub-img {
  transform: scale(1.04);
}

.fallback-hero-sub-icon {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-secondary);
  background: var(--bg-muted);
}

.hero-sub-body {
  padding: 12px 16px 12px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
  min-height: 0;
}

.hero-sub-top {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.hero-sub-title {
  font-size: 0.98rem;
  font-weight: 700;
  line-height: 1.35;
  margin: 4px 0 6px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-sub-title a {
  color: var(--text-main);
  transition: color 0.2s ease;
}

.hero-sub-title a:hover {
  color: var(--brand-secondary);
}

.hero-sub-excerpt {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin: 0 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-sub-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.76rem;
  color: var(--text-light);
  border-top: 1px solid var(--border-subtle);
  padding-top: 8px;
  margin-top: auto;
}

/* 4. Full 2-Column Site Layout (Publisher Standard) */
.site-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 32px;
  margin-bottom: 50px;
  align-items: start;
}

.primary-content {
  min-width: 0;
  width: 100%;
}

.section-header-modern {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border-color);
  position: relative;
}

.section-header-modern::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 48px;
  height: 2px;
  background: var(--brand-secondary);
}

.section-header-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.section-badge-icon {
  color: var(--brand-secondary);
  display: inline-flex;
}

.section-title-modern {
  font-size: 1.25rem;
  font-weight: 800;
}

.articles-count-pill {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-light);
  background: var(--bg-muted);
  padding: 3px 9px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border-color);
}

/* Post Cards Grid */
/* Post Cards Grid (Latest Guides & Tutorials) */
.posts-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  width: 100%;
  min-width: 0;
}

.post-card {
  background: var(--bg-surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: var(--transition);
  width: 100%;
  min-width: 0;
  max-width: 100%;
}

.post-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(1, 117, 194, 0.35);
}

.post-card-thumb {
  position: relative;
  aspect-ratio: 16 / 9;
  width: 100%;
  max-width: 100%;
  background: var(--bg-muted);
  overflow: hidden;
  display: block;
  flex-shrink: 0;
}

.card-thumb-img,
.post-card-thumb img {
  width: 100% !important;
  height: 100% !important;
  max-width: 100% !important;
  object-fit: cover !important;
  display: block !important;
  transition: transform 0.4s ease;
}

.post-card:hover .card-thumb-img,
.post-card:hover .post-card-thumb img {
  transform: scale(1.04);
}

.card-thumb-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
  color: var(--brand-secondary);
}

.post-card-body {
  padding: 18px 20px;
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.post-card-title {
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.4;
  margin: 6px 0 10px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  overflow-wrap: break-word;
  word-break: break-word;
}

.post-card-title a {
  color: var(--text-main);
  text-decoration: none;
  transition: color 0.2s ease;
}

.post-card-title a:hover {
  color: var(--brand-secondary);
}

.post-card-excerpt {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
  overflow-wrap: break-word;
  word-break: break-word;
}

.post-card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-light);
  border-top: 1px solid var(--border-subtle);
  padding-top: 12px;
  margin-top: auto;
}

/* 5. Sticky Sidebar & Publisher-Grade Widgets */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 24px;
  position: sticky;
  top: 86px;
}

.sidebar > *,
.sidebar .widget,
.sidebar section,
.sidebar .wp-block-group,
.widget,
.widget_block,
.wp-block-group {
  background: var(--bg-surface) !important;
  border-radius: var(--radius-lg) !important;
  border: 1px solid var(--border-color) !important;
  padding: 22px !important;
  box-shadow: var(--shadow-sm) !important;
  transition: var(--transition) !important;
  overflow: hidden;
}

.sidebar > *:hover,
.sidebar .widget:hover,
.widget:hover,
.widget_block:hover,
.wp-block-group:hover {
  box-shadow: var(--shadow-md) !important;
}

.sidebar h1,
.sidebar h2,
.sidebar h3,
.sidebar .widget-title,
.sidebar .widgettitle,
.widget-title,
.widgettitle,
.widget h2,
.widget h3,
.widget_block h2,
.widget_block h3,
.wp-block-heading,
.wp-block-group h2,
.wp-block-group h3 {
  font-size: 1.08rem !important;
  font-weight: 800 !important;
  margin: 0 0 16px 0 !important;
  padding-bottom: 10px !important;
  border-bottom: 2px solid var(--border-color) !important;
  position: relative !important;
  color: var(--text-main) !important;
  display: flex !important;
  align-items: center !important;
  gap: 8px !important;
  line-height: 1.3 !important;
}

.sidebar h1::after,
.sidebar h2::after,
.sidebar h3::after,
.sidebar .widget-title::after,
.sidebar .widgettitle::after,
.widget-title::after,
.widgettitle::after,
.widget h2::after,
.widget h3::after,
.widget_block h2::after,
.widget_block h3::after,
.wp-block-heading::after,
.wp-block-group h2::after,
.wp-block-group h3::after {
  content: '' !important;
  position: absolute !important;
  bottom: -2px !important;
  left: 0 !important;
  width: 32px !important;
  height: 2px !important;
  background: var(--brand-secondary) !important;
}

.widget-title span,
.widgettitle span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

/* Standard & Block WordPress Sidebar Widgets (Recent Posts, Jobs, Pages, Categories) */
.sidebar ul:not(.popular-posts-list):not(.category-pills-list),
.sidebar ol:not(.popular-posts-list):not(.category-pills-list),
.widget ul:not(.popular-posts-list):not(.category-pills-list),
.widget ol:not(.popular-posts-list):not(.category-pills-list),
.wp-block-latest-posts,
.wp-block-latest-posts__list,
.wp-block-categories-list,
.wp-block-archives-list,
.widget_recent_entries ul,
.widget_categories ul,
.widget_archive ul,
.widget_nav_menu ul,
.widget_pages ul,
.wp-block-page-list,
.wp-block-latest-comments {
  list-style: none !important;
  display: flex !important;
  flex-direction: column !important;
  gap: 10px !important;
  margin: 0 !important;
  padding: 0 !important;
}

.sidebar ul:not(.popular-posts-list):not(.category-pills-list) li,
.sidebar ol:not(.popular-posts-list):not(.category-pills-list) li,
.widget ul:not(.popular-posts-list):not(.category-pills-list) li,
.widget ol:not(.popular-posts-list):not(.category-pills-list) li,
.wp-block-latest-posts li,
.wp-block-latest-posts__list li,
.wp-block-categories-list li,
.wp-block-archives-list li,
.widget_recent_entries ul li,
.widget_categories ul li,
.widget_archive ul li,
.widget_nav_menu ul li,
.widget_pages ul li,
.wp-block-page-list li,
.wp-block-latest-comments li {
  display: flex !important;
  align-items: flex-start !important;
  gap: 10px !important;
  padding: 12px 14px !important;
  border-radius: var(--radius-sm) !important;
  background: var(--bg-muted) !important;
  border: 1px solid var(--border-subtle) !important;
  font-size: 0.9rem !important;
  line-height: 1.45 !important;
  transition: all 0.22s cubic-bezier(0.4, 0, 0.2, 1) !important;
  margin-bottom: 0 !important;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02) !important;
}

.sidebar ul:not(.popular-posts-list):not(.category-pills-list) li::before,
.sidebar ol:not(.popular-posts-list):not(.category-pills-list) li::before,
.widget ul:not(.popular-posts-list):not(.category-pills-list) li::before,
.wp-block-latest-posts li::before,
.wp-block-latest-posts__list li::before,
.widget_recent_entries ul li::before {
  content: '›' !important;
  font-weight: 800 !important;
  color: var(--brand-secondary) !important;
  font-size: 1.3rem !important;
  line-height: 1 !important;
  flex-shrink: 0 !important;
  margin-top: -1px !important;
}

.sidebar ul:not(.popular-posts-list):not(.category-pills-list) li:hover,
.sidebar ol:not(.popular-posts-list):not(.category-pills-list) li:hover,
.widget ul:not(.popular-posts-list):not(.category-pills-list) li:hover,
.wp-block-latest-posts li:hover,
.wp-block-latest-posts__list li:hover,
.widget_recent_entries ul li:hover,
.wp-block-categories-list li:hover {
  background: var(--bg-surface-elevated) !important;
  border-color: rgba(1, 117, 194, 0.45) !important;
  transform: translateX(5px) !important;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.07) !important;
}

.sidebar ul:not(.popular-posts-list):not(.category-pills-list) li a,
.sidebar ol:not(.popular-posts-list):not(.category-pills-list) li a,
.widget ul:not(.popular-posts-list):not(.category-pills-list) li a,
.wp-block-latest-posts li a,
.wp-block-latest-posts__list li a,
.wp-block-latest-posts__post-title,
.widget_recent_entries ul li a {
  color: var(--text-main) !important;
  font-weight: 600 !important;
  text-decoration: none !important;
  transition: color 0.2s ease !important;
  flex: 1 !important;
}

.sidebar ul:not(.popular-posts-list):not(.category-pills-list) li a:hover,
.sidebar ol:not(.popular-posts-list):not(.category-pills-list) li a:hover,
.widget ul:not(.popular-posts-list):not(.category-pills-list) li a:hover,
.wp-block-latest-posts li a:hover,
.wp-block-latest-posts__list li a:hover,
.wp-block-latest-posts__post-title:hover,
.widget_recent_entries ul li a:hover {
  color: var(--brand-secondary) !important;
}

.sidebar ul:not(.popular-posts-list):not(.category-pills-list) .post-date,
.widget ul:not(.popular-posts-list):not(.category-pills-list) .post-date,
.wp-block-latest-posts__post-date {
  font-size: 0.76rem !important;
  color: var(--text-light) !important;
  display: block !important;
  margin-top: 4px !important;
}

.widget select {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-surface);
  color: var(--text-main);
  font-size: 0.88rem;
  transition: var(--transition);
}

.widget select:focus {
  outline: none;
  border-color: var(--brand-secondary);
}

/* ==========================================================================
   Publisher Search Forms (Sidebar, In-Content, Block & Classic Widgets)
   ========================================================================== */
.search-form,
.modern-search-form,
.searchform,
.wp-block-search,
.widget_search form,
form[role="search"] {
  width: 100%;
  margin: 0;
  display: flex !important;
  flex-wrap: wrap !important;
  align-items: stretch !important;
  gap: 8px !important;
}

.search-form .screen-reader-text,
.wp-block-search__label,
.widget_search .screen-reader-text,
.searchform label .screen-reader-text {
  display: block;
  width: 100%;
  font-size: 0.84rem;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.search-form label,
.searchform label,
.widget_search label {
  flex: 1 1 180px !important;
  display: flex !important;
  align-items: center !important;
  margin: 0 !important;
  width: 100%;
}

/* 1. Custom Wrapper Form (searchform.php) */
.search-input-wrap,
.wp-block-search__inside-wrapper {
  display: flex !important;
  align-items: center !important;
  position: relative;
  width: 100% !important;
  border-radius: var(--radius-sm) !important;
  border: 1px solid var(--border-color) !important;
  background: var(--bg-surface) !important;
  transition: var(--transition) !important;
  padding: 4px !important;
  box-shadow: var(--shadow-sm) !important;
}

.search-input-wrap:focus-within,
.wp-block-search__inside-wrapper:focus-within {
  border-color: var(--brand-secondary) !important;
  box-shadow: 0 0 0 3px rgba(1, 117, 194, 0.15) !important;
}

.search-input-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding-left: 10px;
  color: var(--text-light);
  flex-shrink: 0;
}

/* 2. Search Inputs (Classic & Modern) */
.search-input-wrap .search-field,
.wp-block-search__inside-wrapper .wp-block-search__input,
.modern-search-input {
  flex: 1;
  border: none !important;
  background: transparent !important;
  padding: 9px 12px !important;
  font-size: 0.88rem !important;
  color: var(--text-main) !important;
  outline: none !important;
  min-width: 0;
}

/* Classic fallback inputs without wrapper */
.search-form:not(:has(.search-input-wrap)) .search-field,
.searchform:not(:has(.search-input-wrap)) input[type="text"],
.searchform:not(:has(.search-input-wrap)) input[type="search"],
.widget_search input[type="search"],
.widget_search input[type="text"] {
  width: 100% !important;
  flex: 1 !important;
  padding: 10px 14px !important;
  border-radius: var(--radius-sm) !important;
  border: 1px solid var(--border-color) !important;
  background: var(--bg-surface) !important;
  color: var(--text-main) !important;
  font-size: 0.88rem !important;
  outline: none !important;
  transition: var(--transition) !important;
  box-shadow: var(--shadow-sm) !important;
}

.search-form:not(:has(.search-input-wrap)) .search-field:focus,
.searchform:not(:has(.search-input-wrap)) input[type="text"]:focus,
.searchform:not(:has(.search-input-wrap)) input[type="search"]:focus,
.widget_search input[type="search"]:focus,
.widget_search input[type="text"]:focus {
  border-color: var(--brand-secondary) !important;
  box-shadow: 0 0 0 3px rgba(1, 117, 194, 0.15) !important;
}

.search-field::placeholder,
.modern-search-input::placeholder,
.wp-block-search__input::placeholder {
  color: var(--text-light);
  font-size: 0.85rem;
}

/* 3. Search Submit Buttons */
.search-submit,
.modern-search-submit,
.wp-block-search__button,
.search-form input[type="submit"],
.search-form button[type="submit"],
.searchform input[type="submit"],
.widget_search input[type="submit"] {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 6px !important;
  background: var(--gradient-brand) !important;
  color: #fff !important;
  font-size: 0.85rem !important;
  font-weight: 700 !important;
  padding: 9px 18px !important;
  border-radius: var(--radius-xs) !important;
  border: none !important;
  cursor: pointer !important;
  transition: var(--transition) !important;
  flex-shrink: 0 !important;
  box-shadow: 0 2px 6px rgba(1, 117, 194, 0.25) !important;
}

.search-submit:hover,
.modern-search-submit:hover,
.wp-block-search__button:hover,
.search-form input[type="submit"]:hover,
.searchform input[type="submit"]:hover,
.widget_search input[type="submit"]:hover {
  opacity: 0.92 !important;
  transform: translateY(-1px) !important;
  box-shadow: 0 4px 10px rgba(1, 117, 194, 0.35) !important;
}

/* Trending Guides List */
.popular-posts-list {
  display: flex;
  flex-direction: column;
  gap: 14px;
  list-style: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.popular-post-item {
  display: flex !important;
  gap: 14px !important;
  align-items: flex-start !important;
  padding-bottom: 14px !important;
  border-bottom: 1px solid var(--border-subtle) !important;
  transition: var(--transition) !important;
  background: transparent !important;
  border-radius: 0 !important;
  padding-top: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

.popular-post-item:last-child {
  padding-bottom: 0 !important;
  border-bottom: none !important;
}

.popular-post-thumb-wrap {
  position: relative;
  width: 90px;
  height: 64px;
  min-width: 90px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg-muted);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.popular-post-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
  display: block;
}

.popular-post-item:hover .popular-post-img {
  transform: scale(1.08);
}

.popular-post-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-secondary);
}

.popular-rank-badge {
  position: absolute;
  top: 4px;
  left: 4px;
  font-size: 0.65rem;
  font-weight: 800;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  background: var(--gradient-brand);
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.35);
  z-index: 2;
}

.popular-rank-badge.rank-1 {
  background: linear-gradient(135deg, #f59e0b, #d97706);
}

.popular-rank-badge.rank-2 {
  background: linear-gradient(135deg, #0175c2, #13b9fd);
}

.popular-rank-badge.rank-3 {
  background: linear-gradient(135deg, #8b5cf6, #6366f1);
}

.popular-rank-badge.rank-4,
.popular-rank-badge.rank-5 {
  background: rgba(15, 23, 42, 0.75);
}

.popular-post-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  flex: 1;
}

.popular-post-cat {
  font-size: 0.66rem;
  font-weight: 700;
  color: var(--brand-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 2px;
  display: inline-block;
}

.sidebar .popular-post-title,
.popular-post-title {
  font-size: 0.88rem !important;
  font-weight: 700 !important;
  line-height: 1.35 !important;
  color: var(--text-main) !important;
  margin: 0 0 4px 0 !important;
  padding: 0 !important;
  border: none !important;
  border-bottom: none !important;
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
}

.sidebar .popular-post-title::after,
.popular-post-title::after {
  display: none !important;
}

.popular-post-title a {
  color: var(--text-main) !important;
  text-decoration: none !important;
  transition: color 0.2s ease !important;
}

.popular-post-title a:hover {
  color: var(--brand-secondary) !important;
}

.popular-post-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: var(--text-light);
  margin-top: 2px;
}

/* 2. Community & Follow Us Widget */
.social-connect-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.social-connect-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-surface);
  transition: var(--transition);
  color: var(--text-main);
}

.social-connect-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.sc-github:hover {
  background: #24292e;
  color: #fff;
  border-color: #24292e;
}

.sc-youtube:hover {
  background: #ff0000;
  color: #fff;
  border-color: #ff0000;
}

.sc-twitter:hover {
  background: #000;
  color: #fff;
  border-color: #000;
}

.sc-linkedin:hover {
  background: #0077b5;
  color: #fff;
  border-color: #0077b5;
}

.sc-text {
  display: flex;
  flex-direction: column;
}

.sc-name {
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.2;
}

.sc-action {
  font-size: 0.68rem;
  opacity: 0.75;
}

/* 3. Publisher Pro Newsletter Widget */
.newsletter-widget {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  position: relative;
  overflow: hidden;
  padding: 24px 20px;
}

.newsletter-widget::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-brand);
}

.newsletter-badge-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.newsletter-badge-icon {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: rgba(1, 117, 194, 0.12);
  color: var(--brand-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.newsletter-badge-tag {
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.8px;
  color: var(--brand-secondary);
}

.newsletter-title {
  font-size: 1.15rem;
  font-weight: 800;
  margin-bottom: 8px;
  letter-spacing: -0.3px;
}

.newsletter-desc {
  font-size: 0.84rem;
  color: var(--text-muted);
  margin-bottom: 14px;
  line-height: 1.5;
}

.newsletter-perks {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 16px;
  padding: 10px 12px;
  background: var(--bg-muted);
  border-radius: var(--radius-sm);
}

.perk-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-main);
}

.perk-item svg {
  color: #10b981;
  flex-shrink: 0;
}

.newsletter-input-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.newsletter-input {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-input);
  color: var(--text-main);
  font-size: 0.88rem;
  font-family: inherit;
  transition: border-color 0.2s;
}

.newsletter-input:focus {
  outline: none;
  border-color: var(--brand-secondary);
}

.newsletter-submit-btn {
  width: 100%;
  padding: 11px 18px;
  border: none;
  border-radius: var(--radius-sm);
  background: var(--gradient-brand);
  color: #fff;
  font-weight: 700;
  font-size: 0.88rem;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  transition: var(--transition);
}

.newsletter-submit-btn:hover {
  opacity: 0.92;
  transform: translateY(-1px);
}

.newsletter-sub-note {
  display: block;
  font-size: 0.7rem;
  color: var(--text-light);
  margin-top: 10px;
  text-align: center;
}

/* 4. Category Topics List with Micro-Icons */
.category-pills-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  list-style: none;
}

.category-pill-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text-main);
  transition: var(--transition);
}

.cat-pill-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.cat-pill-icon {
  color: var(--brand-secondary);
  display: inline-flex;
  align-items: center;
}

.category-pill-link:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
  transform: translateX(3px);
}

.category-pill-link:hover .cat-pill-icon {
  color: #fff;
}

.cat-pill-count {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-full);
  background: var(--bg-surface);
  color: var(--text-muted);
}

.category-pill-link:hover .cat-pill-count {
  background: rgba(255, 255, 255, 0.25);
  color: #fff;
}

/* 5. Popular Tags Cloud (Hashtag Style) */
.sidebar-tags-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.sidebar-tag-pill {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-full);
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  transition: var(--transition);
}

.sidebar-tag-pill:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
  transform: translateY(-1px);
}

/* 6. Sticky Sidebar Ad Box */
.sticky-ad-box {
  position: sticky;
  top: calc(var(--header-height) + 20px);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px;
  text-align: center;
}

.ad-disclosure-label {
  display: block;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: var(--text-light);
  margin-bottom: 6px;
}

/* 6. Single Article Card View */
.single-article-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 22px 32px 34px;
  box-shadow: var(--shadow-sm);
}

.breadcrumbs {
  font-size: 0.82rem;
  color: var(--text-light);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
}

.breadcrumbs a {
  color: var(--text-muted);
}

.breadcrumbs a:hover {
  color: var(--brand-secondary);
}

.breadcrumb-sep {
  color: var(--text-light);
}

.breadcrumb-current {
  color: var(--text-main);
  font-weight: 600;
}

.single-header {
  margin-bottom: 18px;
}

.single-category-wrap {
  margin-bottom: 8px;
}

.single-category-wrap .category-badge {
  margin-bottom: 0;
}

.single-title {
  font-size: 2.1rem;
  font-weight: 800;
  line-height: 1.25;
  margin: 6px 0 14px;
  letter-spacing: -0.5px;
  color: var(--text-main);
}

.single-meta-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 0.84rem;
  color: var(--text-muted);
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border-color);
  flex-wrap: wrap;
}

.meta-author-group {
  display: flex;
  align-items: center;
  gap: 7px;
}

.author-avatar-badge {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--gradient-brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
}

.meta-author-name strong {
  color: var(--text-main);
}

/* Social Share Bar (Publisher Style) */
.social-share-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
}

.share-label {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 5px 12px;
  border-radius: var(--radius-xs);
  font-size: 0.78rem;
  font-weight: 700;
  color: #fff;
  border: none;
  cursor: pointer;
  transition: var(--transition);
}

.share-twitter {
  background: #000;
}
.share-twitter:hover {
  background: #1a1a1a;
}
.share-facebook {
  background: #1877f2;
}
.share-facebook:hover {
  background: #1465cc;
}
.share-reddit {
  background: #ff4500;
}
.share-reddit:hover {
  background: #d83a00;
}
.share-linkedin {
  background: #0077b5;
}
.share-linkedin:hover {
  background: #005f93;
}
.share-whatsapp {
  background: #25d366;
}
.share-whatsapp:hover {
  background: #1ea952;
}
.share-copy-link {
  background: var(--bg-muted);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}
.share-copy-link.copied {
  background: #10b981;
  color: #fff;
  border-color: #10b981;
}

.social-share-bottom {
  margin-top: 24px;
  padding: 16px 20px;
  background: var(--bg-muted);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.share-btn:hover {
  opacity: 0.95;
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.single-featured-image {
  border-radius: var(--radius-md);
  overflow: hidden;
  margin: 22px 0 28px;
  box-shadow: var(--shadow-md);
}

.single-featured-image img {
  width: 100%;
  height: auto;
  border-radius: var(--radius-md);
}

/* Ad Slots */
.header-ad-wrapper {
  margin: 16px 0 24px;
  text-align: center;
}

.ad-slot {
  margin: 18px 0;
  text-align: center;
  overflow: hidden;
}

.article-ad-top {
  margin: 16px 0 24px;
}

.article-ad-bottom {
  margin: 28px 0 20px;
}

.ad-label {
  display: block;
  font-size: 0.65rem;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-bottom: 4px;
}

/* Article Typography */
.article-content {
  font-size: 1.05rem;
  line-height: 1.85;
  color: var(--text-main);
  overflow-wrap: break-word !important;
  word-wrap: break-word !important;
  word-break: break-word !important;
  min-width: 0;
  max-width: 100%;
}

.article-content p,
.article-content li,
.article-content span,
.article-content blockquote,
.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4,
.article-content h5,
.article-content h6 {
  overflow-wrap: break-word !important;
  word-wrap: break-word !important;
  word-break: break-word !important;
  max-width: 100%;
}

.article-content h2 {
  font-size: 1.55rem;
  font-weight: 800;
  margin: 36px 0 14px;
  letter-spacing: -0.3px;
  padding-left: 12px;
  border-left: 4px solid var(--brand-secondary);
}

.article-content h3 {
  font-size: 1.25rem;
  font-weight: 700;
  margin: 28px 0 12px;
}

.article-content p {
  margin-bottom: 20px;
}

.article-content ul,
.article-content ol {
  margin: 0 0 20px 24px;
}

.article-content ul {
  list-style: disc;
}

.article-content ol {
  list-style: decimal;
}

.article-content li {
  margin-bottom: 6px;
}

.article-content blockquote {
  border-left: 4px solid var(--brand-secondary);
  padding: 14px 20px;
  background: var(--bg-muted);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  margin: 24px 0;
}

/* Article Hyperlinks & Long URLs (100% Mobile Responsive Break) */
.article-content a {
  color: var(--brand-secondary);
  font-weight: 600;
  text-decoration: underline;
  text-decoration-color: rgba(1, 117, 194, 0.45);
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  border-radius: var(--radius-xs);
  padding: 1px 3px;
  overflow-wrap: anywhere !important;
  word-break: break-all !important;
  word-wrap: break-word !important;
  max-width: 100%;
}

.article-content img,
.article-content figure,
.article-content video,
.article-content iframe,
.article-content embed {
  max-width: 100% !important;
  height: auto !important;
  border-radius: var(--radius-sm);
}

.article-content table {
  width: 100%;
  display: block;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-collapse: collapse;
  margin: 24px 0;
}

[data-theme="dark"] .article-content a {
  color: var(--brand-accent);
  text-decoration-color: rgba(19, 185, 253, 0.45);
}

.article-content a:hover {
  color: var(--brand-primary);
  text-decoration-color: var(--brand-secondary);
  text-decoration-thickness: 2px;
  background: rgba(1, 117, 194, 0.1);
}

[data-theme="dark"] .article-content a:hover {
  color: #fff;
  text-decoration-color: var(--brand-accent);
  background: rgba(19, 185, 253, 0.18);
}

/* Code Snippets with Copy Button */
.article-content pre {
  position: relative;
  background: var(--bg-code);
  color: var(--text-code);
  padding: 20px;
  border-radius: var(--radius-md);
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  line-height: 1.6;
  margin: 24px 0;
  border: 1px solid var(--border-color);
}

.article-content code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--bg-muted);
  color: var(--brand-secondary);
  padding: 2px 6px;
  border-radius: var(--radius-xs);
}

.article-content pre code {
  background: transparent;
  color: inherit;
  padding: 0;
}

.copy-code-btn {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 4px 10px;
  border-radius: var(--radius-xs);
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  gap: 5px;
}

.copy-code-btn:hover {
  background: var(--brand-secondary);
  border-color: var(--brand-secondary);
}

.copy-code-btn.copied {
  background: #10b981;
  border-color: #10b981;
}

/* ==========================================================================
   Table of Contents (Collapsible / Expandable Publisher Card)
   ========================================================================== */
.article-content .toc-box,
.toc-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin: 30px 0 34px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: var(--transition);
}

.toc-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  cursor: pointer;
  user-select: none;
  background: var(--bg-muted);
  border-bottom: 1px solid var(--border-color);
  transition: background 0.2s ease;
}

.toc-header:hover {
  background: var(--bg-surface-elevated);
}

.toc-title-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

.toc-badge {
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 3px 8px;
  border-radius: var(--radius-xs);
  display: inline-flex;
  align-items: center;
  gap: 5px;
  letter-spacing: 0.5px;
}

.toc-text {
  font-size: 0.96rem;
  font-weight: 800;
  color: var(--text-main);
}

.toc-toggle-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xs);
  padding: 4px 10px;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
  transition: var(--transition);
}

.toc-toggle-btn:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
}

.toc-toggle-arrow {
  transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.toc-box.collapsed .toc-header {
  border-bottom-color: transparent;
}

.toc-box.collapsed .toc-toggle-arrow {
  transform: rotate(180deg);
}

.toc-content-wrap {
  max-height: 1500px;
  opacity: 1;
  padding: 16px 20px;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.25s ease, padding 0.35s ease;
  overflow: hidden;
}

.toc-box.collapsed .toc-content-wrap {
  max-height: 0;
  opacity: 0;
  padding-top: 0;
  padding-bottom: 0;
}

.article-content .toc-box ul,
.article-content ul.toc-list,
.toc-list,
.toc-list li {
  list-style: none !important;
  list-style-type: none !important;
  margin: 0 !important;
  padding: 0 !important;
}

.toc-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toc-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--text-muted);
  text-decoration: none !important;
  padding: 4px 8px;
  border-radius: var(--radius-xs);
  transition: var(--transition);
}

.toc-num {
  font-size: 0.72rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: var(--brand-secondary);
  background: rgba(1, 117, 194, 0.1);
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  min-width: 24px;
  text-align: center;
  line-height: 1.2;
}

.toc-link:hover {
  color: var(--brand-secondary);
  background: var(--bg-muted);
  transform: translateX(4px);
}

.toc-link:hover .toc-num {
  background: var(--brand-secondary);
  color: #fff;
}

/* Tags Wrap */
.article-tags-wrap {
  margin: 30px 0 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.tags-label {
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--text-light);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.tag-pill {
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  padding: 3px 9px;
  border-radius: var(--radius-xs);
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
}

.tag-pill:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
}

/* Author Bio Card (Publisher Style) */
.author-bio-box {
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 22px 24px;
  margin: 36px 0;
  display: flex;
  gap: 20px;
  align-items: center;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
}

.author-bio-box:hover {
  border-color: rgba(1, 117, 194, 0.35);
  box-shadow: var(--shadow-md);
}

.author-bio-avatar {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--gradient-brand);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1.35rem;
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(1, 117, 194, 0.25);
}

.author-bio-avatar img,
.author-bio-avatar .author-bio-img,
.author-bio-avatar .avatar {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
  display: block;
}

.author-bio-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.author-bio-header {
  display: flex;
  align-items: center;
  gap: 8px;
}

.author-bio-name {
  font-size: 1.1rem;
  font-weight: 800;
  margin: 0;
  color: var(--text-main);
}

.author-bio-name a {
  color: var(--text-main);
  text-decoration: none;
  transition: color 0.2s ease;
}

.author-bio-name a:hover {
  color: var(--brand-secondary);
}

.author-bio-text {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin: 0;
}

/* Post Navigation */
.post-navigation {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 36px 0;
}

.nav-post-card {
  display: block;
  padding: 14px 16px;
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

.nav-post-card:hover {
  border-color: var(--brand-secondary);
  transform: translateY(-2px);
}

.nav-next-card {
  text-align: right;
}

.nav-direction {
  font-size: 0.72rem;
  color: var(--text-light);
  text-transform: uppercase;
  font-weight: 700;
}

.nav-title {
  font-weight: 700;
  font-size: 0.9rem;
  margin-top: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Related Posts Section */
.related-posts-section {
  margin: 40px 0 24px;
}

/* 7. Comments & Discussion Section (High-End Publisher Style) */
.comments-area {
  margin-top: 44px;
  padding-top: 24px;
  border-top: 2px solid var(--border-color);
}

.comments-header-wrap {
  margin-bottom: 20px;
}

.comments-title,
.comment-reply-title {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: 20px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--border-color);
  position: relative;
}

.comments-title::after,
.comment-reply-title::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 36px;
  height: 2px;
  background: var(--brand-secondary);
}

.comments-title span,
.comment-reply-title span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.comment-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 36px;
}

.comment-item-wrap {
  list-style: none;
}

.comment-card {
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 18px 20px;
}

.comment-by-author {
  border-left: 3.5px solid var(--brand-secondary);
}

.comment-header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.comment-author-meta {
  display: flex;
  align-items: center;
  gap: 10px;
}

.comment-avatar-wrap img {
  border-radius: 50%;
  width: 40px;
  height: 40px;
}

.comment-author-details {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.comment-author-name {
  font-size: 0.92rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  gap: 6px;
}

.author-badge-chip {
  font-size: 0.65rem;
  font-weight: 800;
  background: var(--brand-secondary);
  color: #fff;
  padding: 1px 6px;
  border-radius: var(--radius-xs);
  text-transform: uppercase;
}

.comment-date {
  font-size: 0.75rem;
  color: var(--text-light);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.comment-reply-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--brand-secondary);
  padding: 4px 10px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xs);
  transition: var(--transition);
}

.comment-reply-link:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
}

.comment-body-text {
  font-size: 0.92rem;
  line-height: 1.65;
  color: var(--text-main);
}

.comment-body-text p {
  margin-bottom: 0;
}

/* Pingbacks Section */
.pingbacks-section {
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin-bottom: 30px;
}

.pingbacks-title {
  font-size: 0.95rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.pingback-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.pingback-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  font-size: 0.85rem;
}

.pingback-link-icon {
  color: var(--brand-secondary);
  margin-top: 2px;
}

.pingback-content {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pingback-author a {
  font-weight: 600;
  color: var(--text-main);
}

.pingback-date {
  font-size: 0.75rem;
  color: var(--text-light);
}

/* Comment Form */
.comment-respond {
  margin-top: 30px;
}

.comment-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.comment-notes {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.comment-form-fields-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-group label {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-input);
  color: var(--text-main);
  font-family: inherit;
  font-size: 0.9rem;
  transition: var(--transition);
}

.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--brand-secondary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px rgba(1, 117, 194, 0.15);
}

.comment-submit-btn {
  width: auto;
  align-self: flex-start;
  padding: 10px 24px;
}

/* 8. Professional Footer (Publisher Style) */
.site-footer {
  background: var(--bg-footer);
  color: var(--text-footer);
  border-top: 1px solid var(--border-footer);
  padding: 50px 0 24px;
  margin-top: 60px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.8fr 1fr 1fr 1.4fr;
  gap: 36px;
  margin-bottom: 40px;
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.footer-desc {
  font-size: 0.88rem;
  color: var(--text-footer-muted);
  line-height: 1.65;
  margin-bottom: 18px;
}

.footer-social-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

.social-circle {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #cbd5e1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.social-circle:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
  transform: translateY(-2px);
}

.footer-col-title {
  font-size: 1rem;
  font-weight: 800;
  margin-bottom: 16px;
  color: #fff;
}

.footer-col-title span {
  padding-bottom: 4px;
  border-bottom: 2px solid var(--brand-secondary);
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.86rem;
  color: var(--text-footer-muted);
}

.footer-links li a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: var(--transition);
}

.footer-link-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--brand-secondary);
  opacity: 0.85;
}

.footer-links a:hover {
  color: var(--brand-accent);
  padding-left: 4px;
}

.footer-links a:hover .footer-link-icon {
  color: var(--brand-accent);
}

/* In-Feed & In-Content Ad Slots */
.in-feed-ad-grid-item {
  grid-column: 1 / -1;
  background: var(--bg-surface);
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-lg);
  padding: 18px;
  text-align: center;
  margin: 8px 0;
  box-shadow: var(--shadow-sm);
}

.ad-in-content {
  margin: 28px 0;
  text-align: center;
  background: var(--bg-muted);
  border: 1px dashed var(--border-color);
  border-radius: var(--radius-md);
  padding: 18px;
}

.footer-newsletter-text {
  font-size: 0.84rem;
  color: var(--text-footer-muted);
  margin-bottom: 12px;
  line-height: 1.5;
}

.footer-newsletter-form input {
  width: 100%;
  padding: 11px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
  margin-bottom: 10px;
  font-size: 0.86rem;
  transition: var(--transition);
}

.footer-newsletter-form input:focus {
  outline: none;
  border-color: var(--brand-secondary);
  background: rgba(255, 255, 255, 0.08);
}

.footer-newsletter-form button,
.footer-newsletter-form .btn-primary {
  width: 100%;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 700;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 8px rgba(1, 117, 194, 0.3);
  transition: var(--transition);
  display: block;
}

.footer-newsletter-form button:hover,
.footer-newsletter-form .btn-primary:hover {
  opacity: 0.95;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(1, 117, 194, 0.4);
}

/* Footer Legal Navigation Bar */
.footer-legal-bar {
  border-top: 1px solid var(--border-footer);
  padding: 16px 0;
  margin-top: 10px;
}

.footer-legal-links {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px 24px;
  list-style: none;
}

.footer-legal-links a {
  color: var(--text-footer-muted);
  font-size: 0.82rem;
  font-weight: 500;
  transition: var(--transition);
}

.footer-legal-links a:hover {
  color: var(--brand-accent);
}

.footer-bottom {
  border-top: 1px solid var(--border-footer);
  padding-top: 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.82rem;
  color: var(--text-footer-muted);
}

.footer-bottom-right {
  display: flex;
  align-items: center;
}

.back-to-top-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #cbd5e1;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  padding: 0;
}

.back-to-top-btn svg {
  display: block;
  stroke: currentColor;
}

.back-to-top-btn:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
  transform: translateY(-2px);
}

/* OneSignal Bell & Prompt Z-Index Fix */
#onesignal-bell-container,
.OneSignal-prompt,
#onesignal-slidedown-dialog {
  z-index: 99999 !important;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin: 36px 0;
}

.pagination .page-numbers {
  padding: 7px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  font-weight: 600;
  font-size: 0.88rem;
}

/* ==========================================================================
   Header Search Button & Interactive Modal Overlay
   ========================================================================== */
.search-toggle-btn {
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  width: 38px;
  height: 38px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.search-toggle-btn:hover {
  background: var(--border-color);
  color: var(--brand-secondary);
  transform: translateY(-1px);
}

.search-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 100000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 100px;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, visibility 0.25s ease;
}

.search-modal.active {
  opacity: 1;
  visibility: visible;
}

.search-modal-backdrop {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(10, 15, 30, 0.7);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.search-modal-container {
  position: relative;
  width: 100%;
  max-width: 680px;
  padding: 0 20px;
  z-index: 1;
  transform: translateY(-20px);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

.search-modal.active .search-modal-container {
  transform: translateY(0);
}

.search-modal-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.search-modal-header {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-color);
  gap: 12px;
}

.search-modal-form {
  flex: 1;
}

.search-input-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-muted);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 6px 14px;
  transition: border-color 0.2s;
}

.search-input-wrap:focus-within {
  border-color: var(--brand-secondary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px rgba(1, 117, 194, 0.15);
}

.search-modal-icon {
  color: var(--brand-secondary);
  display: flex;
  align-items: center;
}

.modal-search-input {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--text-main);
  font-size: 1rem;
  font-family: inherit;
  outline: none;
}

.search-modal-submit-btn {
  background: var(--gradient-brand);
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-xs);
  font-weight: 700;
  font-size: 0.84rem;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
}

.search-modal-submit-btn:hover {
  opacity: 0.92;
}

.search-modal-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 6px;
  border-radius: var(--radius-xs);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s;
}

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

.search-modal-suggestions {
  padding: 16px 20px;
  background: var(--bg-surface-elevated);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.suggestions-label {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.suggestions-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.suggestions-tags a {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-main);
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  padding: 4px 10px;
  border-radius: var(--radius-full);
  transition: var(--transition);
}

.suggestions-tags a:hover {
  background: var(--brand-secondary);
  color: #fff;
  border-color: var(--brand-secondary);
}

/* ==========================================================================
   Publisher Archive & Category/Tag Page Aesthetics
   ========================================================================== */
.archive-hero-box {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
  margin: 16px 0 36px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.archive-hero-box::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-brand);
}

.archive-hero-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.archive-type-badge-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.archive-type-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.8px;
  padding: 3px 10px;
  border-radius: var(--radius-xs);
  text-transform: uppercase;
}

.tag-badge-accent {
  background: linear-gradient(135deg, #10b981, #059669);
}

.author-badge-accent {
  background: linear-gradient(135deg, #8b5cf6, #6366f1);
}

.archive-count-badge {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-muted);
  background: var(--bg-muted);
  border: 1px solid var(--border-color);
  padding: 2px 9px;
  border-radius: var(--radius-full);
}

.archive-main-title {
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.2;
  margin: 4px 0 0;
  color: var(--text-main);
}

.archive-description-text {
  font-size: 0.95rem;
  color: var(--text-muted);
  line-height: 1.65;
  max-width: 800px;
  margin-top: 4px;
}

.archive-description-text p {
  margin: 0;
}

/* ==========================================================================
   Publisher Search Results Page
   ========================================================================== */
.search-results-hero {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
  margin: 16px 0 36px;
  box-shadow: var(--shadow-sm);
  position: relative;
  overflow: hidden;
}

.search-results-hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--gradient-brand);
}

.search-results-hero-inner {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.search-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--gradient-brand);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.8px;
  padding: 3px 10px;
  border-radius: var(--radius-xs);
  align-self: flex-start;
}

.search-hero-title {
  font-size: 1.9rem;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.25;
  margin: 4px 0 0;
}

.search-keyword {
  color: var(--brand-secondary);
}

.search-results-count {
  font-size: 0.92rem;
  color: var(--text-muted);
  margin: 0;
}

.search-inline-form {
  max-width: 580px;
  margin-top: 10px;
}

.search-inline-input-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--bg-muted);
  border: 1.5px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 6px 14px;
  transition: var(--transition);
}

.search-inline-input-wrap:focus-within {
  border-color: var(--brand-secondary);
  background: var(--bg-surface);
  box-shadow: 0 0 0 3px rgba(1, 117, 194, 0.15);
}

.search-inline-icon {
  color: var(--brand-secondary);
  display: flex;
  align-items: center;
}

.search-inline-input {
  width: 100%;
  background: transparent;
  border: none;
  color: var(--text-main);
  font-size: 0.92rem;
  font-family: inherit;
  outline: none;
}

.search-inline-btn {
  background: var(--gradient-brand);
  color: #fff;
  border: none;
  padding: 8px 16px;
  border-radius: var(--radius-xs);
  font-weight: 700;
  font-size: 0.84rem;
  cursor: pointer;
  white-space: nowrap;
  transition: var(--transition);
}

.search-inline-btn:hover {
  opacity: 0.92;
}

/* Nothing Found / Empty State Card */
.nothing-found-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 44px 30px;
  text-align: center;
  box-shadow: var(--shadow-sm);
}

.nothing-found-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: rgba(1, 117, 194, 0.1);
  color: var(--brand-secondary);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.nothing-found-icon svg {
  width: 26px;
  height: 26px;
}

.nothing-found-card h2 {
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: 10px;
}

.nothing-found-card p {
  font-size: 0.9rem;
  color: var(--text-muted);
  max-width: 500px;
  margin: 0 auto 20px;
  line-height: 1.6;
}

.explore-tags-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}

/* Responsive Breakdown */
@media (max-width: 960px) {
  .hero-showcase-grid {
    grid-template-columns: 1fr;
  }
  .hero-secondary-column {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }
  .site-layout {
    grid-template-columns: 1fr;
  }
  .posts-grid {
    grid-template-columns: 1fr;
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .single-article-card {
    padding: 22px 18px;
  }
  .comment-form-fields-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .site-topbar {
    display: none;
  }
  .site-logo {
    max-width: calc(100% - 110px);
  }
  .brand-name {
    font-size: 1.05rem;
  }
  .hero-secondary-column {
    grid-template-columns: 1fr;
  }
  .main-nav-container {
    display: none;
    position: absolute;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: var(--bg-surface);
    border-bottom: 1px solid var(--border-color);
    padding: 14px 20px;
    margin: 0;
    box-shadow: var(--shadow-dropdown);
  }
  .main-nav-container.active {
    display: block;
  }
  .main-nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
  }
  .main-nav > li {
    width: 100%;
  }
  .main-nav ul.sub-menu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    padding-left: 14px;
    margin: 2px 0;
  }
  .mobile-nav-toggle {
    display: flex;
  }
  .single-article-card {
    padding: 18px 14px;
    border-radius: var(--radius-md);
  }
  .single-title {
    font-size: 1.45rem;
    overflow-wrap: break-word;
    word-break: break-word;
  }
  .article-content {
    font-size: 0.98rem;
    line-height: 1.75;
  }
  .footer-grid {
    grid-template-columns: 1fr;
  }
  .post-navigation {
    grid-template-columns: 1fr;
  }
  .nav-next-card {
    text-align: left;
  }
}

@media (max-width: 480px) {
  .site-logo {
    max-width: calc(100% - 95px);
  }
  .brand-name {
    font-size: 0.92rem;
  }
  .single-article-card {
    padding: 14px 10px;
  }
  .single-title {
    font-size: 1.3rem;
  }
  .social-share-bar {
    gap: 6px;
  }
  .share-btn {
    padding: 5px 8px;
    font-size: 0.72rem;
  }
}
