/* ============================================================
   Panorama.ar — Modern Premium Editorial Design System
   Fuses: light-dark(), color-scheme, oklch(), @starting-style,
   scroll-driven animations, Popover API, View Transitions API
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=JetBrains+Mono:wght@400;500;600&family=Playfair+Display:ital,wght@0,400..900;1,400..900&display=swap');

/* ---------- Design tokens with light-dark() and robust fallbacks ---------- */
:root {
  color-scheme: light dark;

  /* Fallback values for older engines */
  --bg:           oklch(0.98 0.004 80);
  --bg-card:      #ffffff;
  --bg-navbar:    oklch(0.98 0.004 80 / 0.90);
  --text-main:    oklch(0.12 0.005 80);
  --text-soft:    oklch(0.48 0.01 80);
  --text-muted:   oklch(0.65 0.01 80);
  --border-color: oklch(0.91 0.004 80);
  --primary:      oklch(0.48 0.20 25);
  --primary-glow: oklch(0.48 0.20 25 / 0.12);
  --economia:     oklch(0.48 0.16 145);
  --economia-bg:  oklch(0.95 0.03 145);
  --sociedad:     oklch(0.45 0.18 250);
  --sociedad-bg:  oklch(0.95 0.03 250);
  --politica:     oklch(0.55 0.16 75);
  --politica-bg:  oklch(0.96 0.03 75);
  --shadow-sm:    0 1px 3px oklch(0 0 0 / 0.04);
  --shadow-md:    0 4px 20px oklch(0 0 0 / 0.06);
  --shadow-lg:    0 12px 40px oklch(0 0 0 / 0.08);

  /* Modern engines rewrite with light-dark() */
  --bg:           light-dark(oklch(0.98 0.004 80), oklch(0.12 0.005 80));
  --bg-card:      light-dark(#ffffff, oklch(0.16 0.008 80));
  --bg-navbar:    light-dark(oklch(0.98 0.004 80 / 0.90), oklch(0.12 0.005 80 / 0.90));
  --text-main:    light-dark(oklch(0.12 0.005 80), oklch(0.98 0.004 80));
  --text-soft:    light-dark(oklch(0.48 0.01 80), oklch(0.72 0.01 80));
  --text-muted:   light-dark(oklch(0.65 0.01 80), oklch(0.55 0.01 80));
  --border-color: light-dark(oklch(0.91 0.004 80), oklch(0.24 0.008 80));
  
  --primary:      light-dark(oklch(0.48 0.20 25), oklch(0.60 0.22 25)); /* Accent Red */
  --primary-glow: light-dark(oklch(0.48 0.20 25 / 0.12), oklch(0.60 0.22 25 / 0.20));

  /* Categories */
  --economia:     light-dark(oklch(0.48 0.16 145), oklch(0.68 0.16 145)); /* Emerald */
  --economia-bg:  light-dark(oklch(0.95 0.03 145), oklch(0.22 0.05 145));
  --sociedad:     light-dark(oklch(0.45 0.18 250), oklch(0.65 0.18 250)); /* Blue */
  --sociedad-bg:  light-dark(oklch(0.95 0.03 250), oklch(0.20 0.05 250));
  --politica:     light-dark(oklch(0.55 0.16 75), oklch(0.72 0.15 75));   /* Amber */
  --politica-bg:  light-dark(oklch(0.96 0.03 75), oklch(0.22 0.05 75));

  --shadow-sm:    light-dark(0 1px 3px oklch(0 0 0 / 0.04),  0 1px 3px oklch(0 0 0 / 0.2));
  --shadow-md:    light-dark(0 4px 20px oklch(0 0 0 / 0.06), 0 4px 20px oklch(0 0 0 / 0.3));
  --shadow-lg:    light-dark(0 12px 40px oklch(0 0 0 / 0.08), 0 12px 40px oklch(0 0 0 / 0.4));

  --font-serif:   'Playfair Display', Georgia, serif;
  --font-sans:    'Inter', -apple-system, sans-serif;
  --font-mono:    'JetBrains Mono', monospace;

  --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring:   cubic-bezier(0.175, 0.885, 0.32, 1.275);

  interpolate-size: allow-keywords;
}

/* Explicit theme overrides */
[data-theme="light"] {
  color-scheme: light;
  --bg:           oklch(0.98 0.004 80);
  --bg-card:      #ffffff;
  --bg-navbar:    oklch(0.98 0.004 80 / 0.90);
  --text-main:    oklch(0.12 0.005 80);
  --text-soft:    oklch(0.48 0.01 80);
  --text-muted:   oklch(0.65 0.01 80);
  --border-color: oklch(0.91 0.004 80);
  --primary:      oklch(0.48 0.20 25);
  --primary-glow: oklch(0.48 0.20 25 / 0.12);
  --economia:     oklch(0.48 0.16 145);
  --economia-bg:  oklch(0.95 0.03 145);
  --sociedad:     oklch(0.45 0.18 250);
  --sociedad-bg:  oklch(0.95 0.03 250);
  --politica:     oklch(0.55 0.16 75);
  --politica-bg:  oklch(0.96 0.03 75);
  --shadow-sm:    0 1px 3px oklch(0 0 0 / 0.04);
  --shadow-md:    0 4px 20px oklch(0 0 0 / 0.06);
  --shadow-lg:    0 12px 40px oklch(0 0 0 / 0.08);
}

[data-theme="dark"]  {
  color-scheme: dark;
  --bg:           oklch(0.12 0.005 80);
  --bg-card:      oklch(0.16 0.008 80);
  --bg-navbar:    oklch(0.12 0.005 80 / 0.90);
  --text-main:    oklch(0.98 0.004 80);
  --text-soft:    oklch(0.72 0.01 80);
  --text-muted:   oklch(0.55 0.01 80);
  --border-color: oklch(0.24 0.008 80);
  --primary:      oklch(0.60 0.22 25);
  --primary-glow: oklch(0.60 0.22 25 / 0.20);
  --economia:     oklch(0.68 0.16 145);
  --economia-bg:  oklch(0.22 0.05 145);
  --sociedad:     oklch(0.65 0.18 250);
  --sociedad-bg:  oklch(0.20 0.05 250);
  --politica:     oklch(0.72 0.15 75);
  --politica-bg:  oklch(0.22 0.05 75);
  --shadow-sm:    0 1px 3px oklch(0 0 0 / 0.2);
  --shadow-md:    0 4px 20px oklch(0 0 0 / 0.3);
  --shadow-lg:    0 12px 40px oklch(0 0 0 / 0.4);
}

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

html {
  scroll-behavior: smooth;
  scrollbar-color: light-dark(oklch(0.78 0.01 80), oklch(0.35 0.01 80)) transparent;
  scrollbar-width: thin;
}

body {
  background: var(--bg);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background 0.35s ease, color 0.35s ease;
  overscroll-behavior-y: contain;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

button {
  font-family: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

.max-w-7xl {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

/* Focus styles */
a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 3px;
  border-radius: 4px;
}

/* ---------- View Transition Names ---------- */
.logo { view-transition-name: site-logo; }

/* ---------- Ticker (Breaking News) ---------- */
.ticker-container {
  background: var(--text-main);
  color: var(--bg);
  font-size: 13px;
  overflow: hidden;
  border-bottom: 1px solid var(--border-color);
}

.ticker-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 24px;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
}

.ticker-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--primary);
  flex-shrink: 0;
}

.ticker-dot {
  width: 7px;
  height: 7px;
  background: var(--primary);
  border-radius: 50%;
  animation: pulse-dot 1.5s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.3; transform: scale(0.9); }
}

.ticker-viewport {
  overflow: hidden;
  flex-grow: 1;
}

.ticker-track {
  display: flex;
  width: max-content;
  animation: ticker-slide 50s linear infinite;
}

.ticker-track:hover {
  animation-play-state: paused;
}

.ticker-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-right: 32px;
  white-space: nowrap;
  text-decoration: none;
  color: inherit;
  transition: color 0.2s ease;
}

.ticker-item:hover {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

.ticker-bullet {
  color: var(--primary);
  font-size: 8px;
}

@keyframes ticker-slide {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ---------- Top Date Strip ---------- */
.topbar-date {
  border-bottom: 1px solid var(--border-color);
  background: var(--bg);
  font-size: 11px;
  color: var(--text-soft);
  padding: 8px 0;
}

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

.topbar-date-links {
  display: flex;
  gap: 16px;
}

.topbar-date-links a:hover {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- Header ---------- */
header {
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-navbar);
  backdrop-filter: blur(16px) saturate(1.4);
  -webkit-backdrop-filter: blur(16px) saturate(1.4);
  position: sticky;
  top: 0;
  z-index: 100;
  transition: background 0.35s ease, border-color 0.35s ease;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
}

.logo {
  font-family: var(--font-serif);
  font-weight: 900;
  font-size: 32px;
  letter-spacing: -0.03em;
  display: flex;
  align-baseline: baseline;
  color: var(--text-main);
}

.logo span {
  color: var(--primary);
}

.nav-desktop {
  display: flex;
  gap: 28px;
  font-size: 14.5px;
  font-weight: 600;
}

.nav-link {
  color: var(--text-soft);
  position: relative;
  padding: 4px 0;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 1.5px;
  background: var(--text-main);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s var(--ease-out-expo);
}

.nav-link:hover {
  color: var(--text-main);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: scaleX(1);
  transform-origin: left;
}

.nav-link.active {
  color: var(--text-main);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn-icon {
  width: 38px;
  height: 38px;
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-soft);
  transition: background 0.25s ease, color 0.25s ease, transform 0.2s var(--ease-spring);
}

.btn-icon:hover {
  background: var(--border-color);
  color: var(--text-main);
  transform: scale(1.05);
}

.btn-icon svg {
  width: 18px;
  height: 18px;
}

/* ---------- Category Badges ---------- */
.tag-badge {
  display: inline-block;
  font-size: 10.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 4px 10px;
  border-radius: 4px;
}

.tag-badge.economia { background: var(--economia-bg); color: var(--economia); }
.tag-badge.sociedad { background: var(--sociedad-bg); color: var(--sociedad); }
.tag-badge.politica { background: var(--politica-bg); color: var(--politica); }

/* ---------- Hero Section (Grid) ---------- */
.hero-section {
  padding: 36px 0;
  border-bottom: 1px solid var(--border-color);
}

.hero-layout {
  display: grid;
  grid-template-columns: 1.3fr 1fr;
  gap: 32px;
}

/* Fullscreen Hero Main Card */
.hero-main-card {
  position: relative;
  height: 540px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: var(--border-color);
  view-transition-name: hero-image-container;
}

.hero-bg-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out-expo);
  view-transition-name: hero-image;
}

.hero-main-card:hover .hero-bg-img {
  transform: scale(1.03);
}

.hero-gradient-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, oklch(0.08 0.005 80 / 0.95) 0%, oklch(0.08 0.005 80 / 0.4) 50%, transparent 100%);
  z-index: 1;
}

.hero-main-content {
  position: relative;
  z-index: 2;
  padding: 36px;
  color: oklch(0.98 0.004 80);
}

.hero-main-content .tag-badge {
  margin-bottom: 16px;
}

.hero-main-content h2 {
  font-family: var(--font-serif);
  font-size: clamp(26px, 3.8vw, 38px);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 14px;
  text-wrap: balance;
  view-transition-name: hero-title;
}

.hero-main-content h2:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
}

.hero-main-content p {
  color: oklch(0.92 0.008 80);
  font-size: 15.5px;
  line-height: 1.6;
  margin-bottom: 20px;
  max-width: 90%;
  text-wrap: pretty;
}

.hero-meta {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 12px;
  color: oklch(0.80 0.01 80);
}

/* Side Heroes list */
.hero-side-list {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  height: 540px;
  gap: 16px;
}

.side-hero-item {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 16px;
  align-items: start;
}

.side-hero-img-wrap {
  aspect-ratio: 16 / 11;
  border-radius: 8px;
  overflow: hidden;
  background: var(--border-color);
}

.side-hero-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s var(--ease-out-expo);
}

.side-hero-item:hover .side-hero-img-wrap img {
  transform: scale(1.05);
}

.side-hero-item h3 {
  font-family: var(--font-serif);
  font-size: 17.5px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 8px;
  text-wrap: balance;
  color: var(--text-main);
}

.side-hero-item:hover h3 {
  color: var(--primary);
}

.side-hero-item p {
  font-size: 13px;
  color: var(--text-soft);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-wrap: pretty;
}

.side-hero-meta {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

/* ---------- Ornament Divider ---------- */
.ornament-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 36px 0;
  text-align: center;
  width: 100%;
}

.ornament-divider::before,
.ornament-divider::after {
  content: '';
  flex-grow: 1;
  height: 1px;
  background: var(--border-color);
}

.ornament-divider::before { margin-right: 20px; }
.ornament-divider::after { margin-left: 20px; }

.ornament-text {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 14px;
  color: var(--text-soft);
  font-weight: 500;
}

/* ---------- Feed Grid ---------- */
.feed-header {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-bottom: 32px;
}

.feed-header-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}

.feed-subtitle {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 700;
  margin-bottom: 4px;
}

.feed-title {
  font-family: var(--font-serif);
  font-size: 32px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

/* Category Filters (Pills) */
.filter-pills {
  display: flex;
  gap: 8px;
}

.pill-btn {
  font-size: 13.5px;
  font-weight: 600;
  padding: 8px 18px;
  border-radius: 20px;
  border: 1px solid var(--border-color);
  color: var(--text-soft);
  background: var(--bg-card);
  transition: all 0.25s var(--ease-out-expo);
}

.pill-btn:hover {
  border-color: var(--text-main);
  color: var(--text-main);
}

.pill-btn.active {
  background: var(--text-main);
  color: var(--bg);
  border-color: var(--text-main);
}

/* Grid layout */
.feed-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 36px 28px;
}

/* Premium Card */
.feed-card {
  display: flex;
  flex-direction: column;
  cursor: pointer;
}

/* Scroll-driven entry animation (only on browsers that support it, without content-visibility conflict) */
@supports (animation-timeline: view()) {
  .feed-card {
    animation: fade-slide-up linear both;
    animation-timeline: view();
    animation-range: entry 5% entry 30%;
  }
}

@keyframes fade-slide-up {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

.card-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 10;
  border-radius: 8px;
  overflow: hidden;
  background: var(--border-color);
  margin-bottom: 16px;
  box-shadow: var(--shadow-sm);
}

.card-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s var(--ease-out-expo);
}

.feed-card:hover .card-img-wrap img {
  transform: scale(1.04);
}

.feed-card h3 {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  line-height: 1.3;
  margin-bottom: 8px;
  text-wrap: balance;
  color: var(--text-main);
  transition: color 0.2s ease;
}

.feed-card:hover h3 {
  color: var(--primary);
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

.feed-card p.card-dek {
  font-size: 13.5px;
  color: var(--text-soft);
  line-height: 1.55;
  margin-bottom: 16px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-wrap: pretty;
}

.card-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.card-meta-bottom {
  display: flex;
  gap: 8px;
  font-size: 11px;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);
  padding-top: 10px;
  margin-top: auto;
}

.no-results {
  grid-column: 1 / -1;
  text-align: center;
  padding: 64px 20px;
  color: var(--text-soft);
}

.no-results svg {
  width: 48px;
  height: 48px;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.no-results h3 {
  font-family: var(--font-serif);
  font-size: 22px;
  margin-bottom: 8px;
}

/* Load More */
.load-more-wrap {
  text-align: center;
  margin-top: 48px;
}

.btn-outline {
  font-size: 14px;
  font-weight: 600;
  padding: 12px 32px;
  border-radius: 24px;
  border: 1px solid var(--text-main);
  color: var(--text-main);
  background: transparent;
  transition: all 0.25s var(--ease-out-expo);
}

.btn-outline:hover {
  background: var(--text-main);
  color: var(--bg);
  transform: translateY(-2px);
}

.btn-outline:active {
  transform: translateY(0);
}

.hidden {
  display: none !important;
}

/* ---------- Newsletter Section ---------- */
.newsletter-section {
  padding: 64px 24px;
  border-top: 1px solid var(--border-color);
  background: linear-gradient(135deg, var(--bg-card), var(--bg));
  border-radius: 12px;
  margin-top: 40px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  text-align: center;
}

.newsletter-section::before {
  content: '';
  position: absolute;
  top: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 400px;
  height: 400px;
  border-radius: 50%;
  background: var(--primary-glow);
  filter: blur(80px);
  z-index: 0;
  pointer-events: none;
}

.newsletter-content {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
}

.newsletter-tag {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 12px;
  display: block;
}

.newsletter-content h2 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 4.5vw, 42px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 14px;
  text-wrap: balance;
}

.newsletter-content p {
  color: var(--text-soft);
  font-size: 15.5px;
  line-height: 1.6;
  margin-bottom: 32px;
  text-wrap: pretty;
}

.newsletter-form {
  display: flex;
  gap: 10px;
  max-width: 480px;
  margin: 0 auto;
}

.newsletter-input {
  flex-grow: 1;
  font-family: var(--font-sans);
  font-size: 14.5px;
  padding: 12px 20px;
  border-radius: 24px;
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-main);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.newsletter-input::placeholder { color: var(--text-muted); }

.newsletter-input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
  outline: none;
}

/* User-invalid style for post-interaction feedback */
.newsletter-input:user-invalid {
  border-color: oklch(0.50 0.20 25);
  box-shadow: 0 0 0 3px oklch(0.50 0.20 25 / 0.15);
}

.btn-accent {
  background: var(--text-main);
  color: var(--bg);
  font-weight: 700;
  font-size: 14px;
  padding: 0 28px;
  border-radius: 24px;
  transition: all 0.25s var(--ease-out-expo);
  white-space: nowrap;
}

.btn-accent:hover {
  background: var(--primary);
  color: #ffffff;
  transform: translateY(-1px);
}

.newsletter-msg {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--primary);
  margin-top: 16px;
}

.newsletter-footnote {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 20px;
}

.newsletter-footnote a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

/* ---------- Search Overlay (Popover) ---------- */
.search-overlay {
  position: fixed;
  inset: 0;
  background: light-dark(rgba(250, 250, 247, 0.90), rgba(15, 15, 14, 0.90));
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  z-index: 200;
  border: none;
  margin: 0;
  width: 100%;
  height: 100%;
  
  /* Slide-down and fade-in transitions via starting-style */
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.35s var(--ease-out-expo),
    transform 0.4s var(--ease-out-expo),
    display 0.35s allow-discrete,
    overlay 0.35s allow-discrete;
}

.search-overlay:not(:popover-open) {
  opacity: 0;
  transform: translateY(-20px);
}

@starting-style {
  .search-overlay:popover-open {
    opacity: 0;
    transform: translateY(-20px);
  }
}

.search-box-container {
  max-width: 768px;
  margin: 96px auto 0;
  padding: 0 24px;
}

.search-box-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

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

.search-input-row svg {
  width: 20px;
  height: 20px;
  color: var(--text-muted);
  flex-shrink: 0;
}

.search-main-input {
  flex-grow: 1;
  background: transparent;
  border: none;
  font-size: 18px;
  font-family: var(--font-sans);
  color: var(--text-main);
  outline: none;
}

.search-main-input::placeholder { color: var(--text-muted); }

.search-close-btn {
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease;
}

.search-close-btn:hover { color: var(--text-main); }
.search-close-btn svg { width: 22px; height: 22px; }

.search-results-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.search-result-item {
  display: flex;
  gap: 16px;
  padding: 12px;
  border-radius: 8px;
  transition: background 0.2s ease;
}

.search-result-item:hover {
  background: var(--border-color);
}

.search-result-thumb {
  width: 80px;
  height: 80px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--border-color);
  flex-shrink: 0;
}

.search-result-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.search-result-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-width: 0;
}

.search-result-info .tag-badge {
  align-self: flex-start;
  font-size: 9px;
  padding: 2px 6px;
  margin-bottom: 6px;
}

.search-result-info h4 {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35;
  margin-bottom: 4px;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.search-result-info span {
  font-size: 11px;
  color: var(--text-muted);
}

/* ---------- Mobile Navigation Drawer (Popover) ---------- */
.mobile-nav-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 280px;
  background: var(--bg-card);
  border-left: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  z-index: 180;
  padding: 32px 24px;
  margin: 0;
  height: 100%;
  border-top: none;
  border-bottom: none;
  border-right: none;

  /* Slide from right transition starting style */
  opacity: 1;
  transform: translateX(0);
  transition:
    opacity 0.3s var(--ease-out-expo),
    transform 0.35s var(--ease-out-expo),
    display 0.35s allow-discrete,
    overlay 0.35s allow-discrete;
}

.mobile-nav-drawer:not(:popover-open) {
  opacity: 0;
  transform: translateX(100%);
}

@starting-style {
  .mobile-nav-drawer:popover-open {
    opacity: 0;
    transform: translateX(100%);
  }
}

.drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 36px;
}

.drawer-close {
  color: var(--text-soft);
  display: flex;
  align-items: center;
  justify-content: center;
}

.drawer-close svg { width: 22px; height: 22px; }

.drawer-links {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.drawer-links a {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-soft);
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 8px;
}

.drawer-links a:hover,
.drawer-links a.active {
  color: var(--text-main);
  border-bottom-color: var(--text-main);
}

/* ---------- Legal & Static Pages ---------- */
.legal-container {
  max-width: 720px;
  margin: 48px auto 96px;
  padding: 0 24px;
}

.legal-eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 12px;
  display: block;
}

.legal-container h1 {
  font-family: var(--font-serif);
  font-size: clamp(30px, 5vw, 44px);
  font-weight: 800;
  line-height: 1.15;
  margin-bottom: 10px;
  letter-spacing: -0.02em;
}

.legal-updated {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 36px;
  display: block;
}

.legal-container h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  margin: 36px 0 16px;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 8px;
}

.legal-container p {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-soft);
  margin-bottom: 20px;
}

.legal-container ul {
  margin: 0 0 20px 24px;
}

.legal-container li {
  font-size: 16px;
  line-height: 1.75;
  color: var(--text-soft);
  margin-bottom: 8px;
}

.legal-container a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2.5px;
}

/* ---------- Footer ---------- */
footer {
  background: oklch(0.12 0.005 80); /* Fallback */
  background: light-dark(oklch(0.12 0.005 80), oklch(0.08 0.005 80));
  color: oklch(0.88 0.005 80 / 0.8);
  border-top: 1px solid var(--border-color);
  margin-top: 64px;
}

.footer-top {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 64px;
  padding: 64px 24px;
  max-width: 1280px;
  margin: 0 auto;
}

.footer-brand h4 {
  font-family: var(--font-serif);
  font-size: 26px;
  font-weight: 900;
  margin-bottom: 12px;
  color: oklch(0.98 0.004 80);
}

.footer-brand h4 span { color: var(--primary); }

.footer-brand p {
  font-size: 14px;
  line-height: 1.6;
  max-width: 320px;
  margin-bottom: 24px;
}

.social-links {
  display: flex;
  gap: 12px;
}

.social-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid oklch(0.98 0.004 80 / 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: inherit;
  transition: all 0.2s ease;
}

.social-btn:hover {
  background: oklch(0.98 0.004 80);
  color: oklch(0.12 0.005 80);
}

.social-btn svg { width: 16px; height: 16px; }

.footer-col h5 {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: oklch(0.98 0.004 80);
  margin-bottom: 16px;
}

.footer-col ul {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-col a {
  font-size: 13.5px;
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: oklch(0.98 0.004 80);
}

.footer-bottom {
  border-top: 1px solid oklch(0.98 0.004 80 / 0.1);
  padding: 24px;
}

.footer-bottom-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 11.5px;
  color: oklch(0.88 0.005 80 / 0.5);
}

/* ============================================================
   Article Detail Page (noticia.html)
   ============================================================ */

/* CSS-only reading progress bar */
.progress-bar-container {
  position: fixed;
  top: 71px;
  left: 0;
  width: 100%;
  height: 3px;
  background: transparent;
  z-index: 101;
}

.progress-bar {
  height: 100%;
  width: 100%;
  background: var(--primary);
  transform-origin: left;
  animation: progress-grow linear;
  animation-timeline: scroll(root);
}

@keyframes progress-grow {
  from { transform: scaleX(0); }
  to   { transform: scaleX(1); }
}

.article-layout {
  display: grid;
  grid-template-columns: 1fr min(680px, 100%) 1fr;
  gap: 32px;
  padding: 48px 0;
}

.article-sidebar {
  grid-column: 1;
  position: sticky;
  top: 110px;
  height: fit-content;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  padding-right: 24px;
}

.share-title {
  font-family: var(--font-mono);
  font-size: 9.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.share-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-soft);
  box-shadow: var(--shadow-sm);
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s var(--ease-spring);
}

.share-btn:hover {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
  transform: translateY(-2px) scale(1.05);
}

.share-btn svg { width: 16px; height: 16px; fill: currentColor; }

.article-main {
  grid-column: 2;
}

.article-header {
  padding-bottom: 28px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 32px;
}

.article-header .tag-badge { margin-bottom: 16px; }

.article-header h1 {
  font-family: var(--font-serif);
  font-size: clamp(28px, 4.5vw, 42px);
  line-height: 1.15;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  text-wrap: balance;
  view-transition-name: hero-title;
}

.article-header p.dek {
  font-size: 17.5px;
  color: var(--text-soft);
  line-height: 1.6;
  margin-bottom: 20px;
  font-weight: 500;
  text-wrap: pretty;
}

.article-byline {
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 12px;
  color: var(--text-muted);
}

.article-byline strong { color: var(--text-main); }

.article-img-wrap {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  margin-bottom: 36px;
  background: var(--border-color);
  view-transition-name: hero-image-container;
}

.article-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  view-transition-name: hero-image;
}

.article-body {
  font-size: 17.5px;
  line-height: 1.8;
  color: var(--text-main);
}

.article-body p {
  margin-bottom: 28px;
  text-wrap: pretty;
}

.article-body p:first-of-type::first-letter {
  font-size: 3.4em;
  float: left;
  line-height: 0.85;
  padding-top: 4px;
  padding-right: 8px;
  font-family: var(--font-serif);
  font-weight: 900;
  color: var(--primary);
}

/* Related section */
.related-section {
  border-top: 1px solid var(--border-color);
  padding: 48px 0;
  grid-column: 1 / -1;
}

.related-section h2 {
  font-family: var(--font-serif);
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 24px;
}

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

.related-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 16px;
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 14px;
  transition: transform 0.25s var(--ease-out-expo), border-color 0.2s ease, box-shadow 0.2s ease;
}

.related-card:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.related-card-img {
  width: 72px;
  height: 72px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--border-color);
}

.related-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.related-card-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.related-card-info .tag-badge {
  align-self: flex-start;
  font-size: 8.5px;
  padding: 2px 6px;
  margin-bottom: 6px;
}

.related-card-info h3 {
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  text-wrap: balance;
  color: var(--text-main);
}

/* ---------- Toast Notification ---------- */
.toast-notification {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--text-main);
  color: var(--bg);
  padding: 12px 20px;
  border-radius: 24px;
  font-size: 13px;
  font-weight: 700;
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  display: flex;
  align-items: center;
  gap: 8px;
  border: none;
  margin: 0;
  inset: auto;
  opacity: 1;
  transform: translateY(0);
  transition:
    opacity 0.3s var(--ease-out-expo),
    transform 0.35s var(--ease-spring),
    display 0.3s allow-discrete,
    overlay 0.3s allow-discrete;
}

.toast-notification:not(:popover-open) {
  opacity: 0;
  transform: translateY(20px);
}

@starting-style {
  .toast-notification:popover-open {
    opacity: 0;
    transform: translateY(20px);
  }
}

.toast-notification svg { width: 16px; height: 16px; fill: currentColor; }

/* ============================================================
   View Transitions Group Animations
   ============================================================ */
::view-transition-old(hero-image),
::view-transition-new(hero-image) {
  animation-duration: 0.4s;
  animation-timing-function: var(--ease-out-expo);
}

::view-transition-old(hero-title),
::view-transition-new(hero-title) {
  animation-duration: 0.35s;
  animation-timing-function: var(--ease-out-expo);
}

::view-transition-old(site-logo),
::view-transition-new(site-logo) {
  animation-duration: 0.25s;
}

/* ============================================================
   Accessibility: Prefers Contrast
   ============================================================ */
@media (prefers-contrast: more) {
  :root {
    --border-color: light-dark(oklch(0.5 0 0), oklch(0.6 0 0));
    --text-soft:    light-dark(oklch(0.2 0 0), oklch(0.9 0 0));
    --shadow-sm: none;
    --shadow-md: none;
    --shadow-lg: none;
  }

  .hero-main-card,
  .side-hero-img-wrap,
  .card-img-wrap,
  .btn-outline,
  .newsletter-input,
  .search-box-card {
    border-width: 2px;
  }
}

/* ============================================================
   Accessibility: Reduced Motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  ::view-transition-group(*),
  ::view-transition-old(*),
  ::view-transition-new(*) {
    animation: none !important;
  }
}

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .hero-main-card {
    height: 480px;
  }
  .hero-side-list {
    flex-direction: row;
    gap: 20px;
  }
  .side-hero-item {
    flex: 1;
    grid-template-columns: 1fr;
  }
  .side-hero-img-wrap {
    aspect-ratio: 16 / 9;
    margin-bottom: 12px;
  }
  .feed-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .article-layout {
    grid-template-columns: 1fr min(680px, 100%);
    padding: 32px 24px;
  }
  .article-sidebar {
    grid-column: 1 / -1;
    position: relative;
    top: 0;
    flex-direction: row;
    align-items: center;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 24px;
    justify-content: flex-start;
  }
  .article-main {
    grid-column: 1 / -1;
  }
}

@media (max-width: 880px) {
  .footer-top {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .footer-brand p {
    max-width: 100%;
  }
  .newsletter-form {
    flex-direction: column;
    align-items: stretch;
  }
  .btn-accent {
    padding: 12px 0;
    text-align: center;
  }
  .related-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .max-w-7xl { padding: 0 16px; }
  .logo { font-size: 26px; }
  .topbar-date { display: none; }
  .nav-desktop { display: none; }
  
  .hero-main-card { height: 380px; }
  .hero-main-content { padding: 20px; }
  .hero-main-content p { display: none; }
  
  .hero-side-list { flex-direction: column; gap: 24px; }
  .feed-grid { grid-template-columns: 1fr; }
  .feed-header-top { flex-direction: column; align-items: flex-start; gap: 16px; }
  
  .search-box-container { margin-top: 48px; }
  
  .article-layout { padding: 16px; }
  .progress-bar-container { top: 71px; }
}

/* ============================================================
   Premium UI/UX Style Enhancements
   ============================================================ */

/* 1. Category-Synced Hover Colors for Cards */
.feed-card.cat-economia:hover h3,
.side-hero-item.cat-economia:hover h3,
.hero-main-card.cat-economia:hover h2 {
  color: var(--economia);
  text-decoration-color: var(--economia);
}
.feed-card.cat-sociedad:hover h3,
.side-hero-item.cat-sociedad:hover h3,
.hero-main-card.cat-sociedad:hover h2 {
  color: var(--sociedad);
  text-decoration-color: var(--sociedad);
}
.feed-card.cat-politica:hover h3,
.side-hero-item.cat-politica:hover h3,
.hero-main-card.cat-politica:hover h2 {
  color: var(--politica);
  text-decoration-color: var(--politica);
}

/* 2. Category-Specific Hover and Active states for Filter Pills */
.pill-btn[data-cat="economia"]:hover,
.pill-btn[data-cat="economia"].active {
  background: var(--economia-bg);
  color: var(--economia);
  border-color: var(--economia);
}
.pill-btn[data-cat="sociedad"]:hover,
.pill-btn[data-cat="sociedad"].active {
  background: var(--sociedad-bg);
  color: var(--sociedad);
  border-color: var(--sociedad);
}
.pill-btn[data-cat="politica"]:hover,
.pill-btn[data-cat="politica"].active {
  background: var(--politica-bg);
  color: var(--politica);
  border-color: var(--politica);
}
.pill-btn[data-cat="todas"]:hover,
.pill-btn[data-cat="todas"].active {
  background: var(--primary-glow);
  color: var(--primary);
  border-color: var(--primary);
}

/* 3. Category-Specific Underlines for Navbar Desktop and Mobile Drawer links */
.nav-link[data-cat="economia"]::after,
.drawer-links a[data-cat="economia"]::after {
  background: var(--economia);
}
.nav-link[data-cat="economia"]:hover,
.nav-link[data-cat="economia"].active,
.drawer-links a[data-cat="economia"]:hover,
.drawer-links a[data-cat="economia"].active {
  color: var(--economia);
}

.nav-link[data-cat="sociedad"]::after,
.drawer-links a[data-cat="sociedad"]::after {
  background: var(--sociedad);
}
.nav-link[data-cat="sociedad"]:hover,
.nav-link[data-cat="sociedad"].active,
.drawer-links a[data-cat="sociedad"]:hover,
.drawer-links a[data-cat="sociedad"].active {
  color: var(--sociedad);
}

.nav-link[data-cat="politica"]::after,
.drawer-links a[data-cat="politica"]::after {
  background: var(--politica);
}
.nav-link[data-cat="politica"]:hover,
.nav-link[data-cat="politica"].active,
.drawer-links a[data-cat="politica"]:hover,
.drawer-links a[data-cat="politica"].active {
  color: var(--politica);
}

.nav-link[data-cat="todas"]::after,
.drawer-links a[data-cat="todas"]::after {
  background: var(--primary);
}
.nav-link[data-cat="todas"]:hover,
.nav-link[data-cat="todas"].active,
.drawer-links a[data-cat="todas"]:hover,
.drawer-links a[data-cat="todas"].active {
  color: var(--primary);
}

/* 4. Editorial Drop Cap (Letra Capitular) for Article View */
.article-body > p:first-of-type::first-letter {
  font-family: var(--font-serif);
  font-size: 3.6rem;
  font-weight: 900;
  float: left;
  line-height: 0.82;
  margin-top: 5px;
  margin-right: 12px;
  color: var(--primary);
  background: linear-gradient(135deg, var(--primary), var(--text-main));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.article-main.cat-economia .article-body > p:first-of-type::first-letter {
  background: linear-gradient(135deg, var(--economia), var(--text-main));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.article-main.cat-sociedad .article-body > p:first-of-type::first-letter {
  background: linear-gradient(135deg, var(--sociedad), var(--text-main));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
.article-main.cat-politica .article-body > p:first-of-type::first-letter {
  background: linear-gradient(135deg, var(--politica), var(--text-main));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* 5. Custom Branded Hover Colors for Social Sharing Buttons */
#share-twitter:hover {
  background: #000000;
  color: #ffffff;
  border-color: #000000;
}
[data-theme="dark"] #share-twitter:hover {
  background: #ffffff;
  color: #000000;
  border-color: #ffffff;
}

#share-whatsapp:hover {
  background: #25D366;
  color: #ffffff;
  border-color: #25D366;
}

#share-copy:hover {
  background: var(--primary);
  color: #ffffff;
  border-color: var(--primary);
}

/* ============================================================
   X Trends Bar Styling
   ============================================================ */
.x-trends-bar {
  display: flex;
  align-items: center;
  gap: 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 12px 18px;
  margin-top: 16px;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  max-width: 100%;
}

.x-trends-label {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text-main);
  white-space: nowrap;
}

.x-logo-inline {
  width: 14px;
  height: 14px;
  color: var(--text-main);
}

.x-trends-container {
  display: flex;
  align-items: center;
  gap: 10px;
  overflow-x: auto;
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none;  /* IE/Edge */
  flex: 1;
}

.x-trends-container::-webkit-scrollbar {
  display: none; /* Chrome/Safari */
}

.x-trend-badge {
  display: inline-flex;
  align-items: center;
  background: var(--primary-glow);
  color: var(--primary);
  border: 1px solid var(--primary);
  border-radius: var(--radius-full);
  padding: 4px 12px;
  font-size: 0.82rem;
  font-weight: 600;
  white-space: nowrap;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
  cursor: pointer;
}

.x-trend-badge:hover {
  background: var(--primary);
  color: #ffffff;
  transform: translateY(-1px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.05);
}

[data-theme="dark"] .x-trend-badge:hover {
  color: #000000;
}

.x-trend-skeleton {
  font-size: 0.85rem;
  color: var(--text-soft);
  font-style: italic;
}

@media (max-width: 768px) {
  .x-trends-bar {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
  }
  .x-trends-container {
    width: 100%;
  }
}

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

/* ---------- Ad Containers (Monetización) ---------- */
.ad-slot-wrapper {
  margin: 24px 0;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.ad-label {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.ad-slot-card {
  width: 728px;
  height: 90px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: none;
  background: transparent;
}

/* Adaptabilidad Móvil para Anuncios de 728px y Layout Hero */
@media (max-width: 768px) {
  .hero-layout {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .hero-main-card {
    height: 380px;
  }
  .hero-side-list {
    height: auto;
    gap: 16px;
  }
  .side-hero-item {
    grid-template-columns: 110px 1fr;
    gap: 12px;
  }
  .side-hero-item h3 {
    font-size: 15px;
    line-height: 1.35;
  }
  .ad-slot-wrapper {
    margin: 14px 0;
  }
  .ad-slot-card {
    transform: scale(calc((100vw - 32px) / 728));
    transform-origin: center center;
    max-width: none;
    margin: -18px 0;
  }
}

@media (max-width: 480px) {
  .hero-main-card {
    height: 320px;
  }
  .hero-main-content {
    padding: 20px;
  }
  .hero-main-content h2 {
    font-size: 22px;
  }
  .ad-slot-card {
    transform: scale(calc((100vw - 24px) / 728));
    margin: -22px 0;
  }
}
