:root {
  --bg-primary: #0f172a;
  --bg-secondary: #1e293b;
  --bg-card: #ffffff;
  --bg-page: #f8fafc;
  --text-main: #1e293b;
  --text-muted: #64748b;
  --accent: #0284c7;
  --accent-hover: #0369a1;
  --accent-light: #e0f2fe;
  --border: #e2e8f0;
  --success: #16a34a;
  --warning: #d97706;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
  background-color: var(--bg-page);
  color: var(--text-main);
  line-height: 1.8;
  font-size: 16.5px;
  -webkit-font-smoothing: antialiased;
}

/* Header */
.site-header {
  background: linear-gradient(180deg, #0b1120 0%, #0f172a 100%);
  color: #ffffff;
  padding: 14px 20px;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px rgba(0,0,0,0.25);
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo-area {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: #ffffff;
}

.logo-area img {
  width: 36px;
  height: 36px;
  object-fit: contain;
}

.logo-title {
  font-size: 1.25rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(90deg, #38bdf8, #818cf8);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.logo-subtitle {
  font-size: 0.72rem;
  color: #94a3b8;
  display: block;
}

.header-nav {
  display: flex;
  gap: 14px;
  align-items: center;
}

.nav-link {
  color: #cbd5e1;
  text-decoration: none;
  font-size: 0.88rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav-link:hover {
  color: #38bdf8;
}

.btn-mapa {
  background: linear-gradient(135deg, #0284c7 0%, #38bdf8 100%);
  color: #0f172a;
  padding: 8px 18px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(56, 189, 248, 0.3);
  transition: transform 0.15s, box-shadow 0.15s;
}

.btn-mapa:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(56, 189, 248, 0.45);
}

/* Breadcrumbs */
.breadcrumbs {
  max-width: 1200px;
  margin: 18px auto 0;
  padding: 0 20px;
  font-size: 0.88rem;
  color: var(--text-muted);
}

.breadcrumbs a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

/* 2-Column Grid Layout (Main Content + Sidebar Ads) */
.page-grid {
  max-width: 1200px;
  margin: 20px auto 60px;
  padding: 0 20px;
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 32px;
  align-items: start;
}

.article-card {
  background: var(--bg-card);
  border-radius: 16px;
  padding: 36px 40px;
  box-shadow: 0 4px 25px -4px rgba(0,0,0,0.06), 0 1px 3px rgba(0,0,0,0.04);
  border: 1px solid var(--border);
}

/* Hero Image inside Article */
.article-hero-image-wrapper {
  margin: -10px -10px 24px -10px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0,0,0,0.08);
}

.article-hero-image {
  width: 100%;
  height: auto;
  max-height: 400px;
  object-fit: cover;
  display: block;
}

.article-header {
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 20px;
}

.badge {
  display: inline-block;
  background: var(--accent-light);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 12px;
}

h1 {
  font-size: 2.1rem;
  color: #0f172a;
  line-height: 1.25;
  margin-bottom: 14px;
  font-weight: 800;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* Content Typography */
.article-content h2 {
  font-size: 1.45rem;
  color: #0f172a;
  margin-top: 36px;
  margin-bottom: 14px;
  font-weight: 700;
  border-bottom: 2px solid #f1f5f9;
  padding-bottom: 8px;
}

.article-content h3 {
  font-size: 1.15rem;
  color: #1e293b;
  margin-top: 24px;
  margin-bottom: 10px;
  font-weight: 600;
}

.article-content p {
  margin-bottom: 18px;
  color: #334155;
}

.article-content ul, .article-content ol {
  margin: 16px 0 24px 24px;
  color: #334155;
}

.article-content li {
  margin-bottom: 10px;
}

/* Callouts */
.callout {
  background: #f0fdf4;
  border-left: 4px solid var(--success);
  padding: 16px 20px;
  border-radius: 8px;
  margin: 24px 0;
  color: #166534;
}

.callout-warning {
  background: #fffbeb;
  border-left: 4px solid var(--warning);
  color: #92400e;
}

.callout-info {
  background: #eff6ff;
  border-left: 4px solid var(--accent);
  color: #1e40af;
}

.callout-title {
  font-weight: 700;
  font-size: 0.98rem;
  margin-bottom: 6px;
}

/* Table Styling */
.data-table-wrapper {
  overflow-x: auto;
  margin: 24px 0;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.92rem;
}

.data-table th {
  background: #f8fafc;
  color: #0f172a;
  padding: 12px 14px;
  font-weight: 600;
  border-bottom: 1px solid var(--border);
}

.data-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  color: #334155;
}

.data-table tr:nth-child(even) {
  background: #f8fafc;
}

/* Publicidades (AdSense Slots) */
.ad-slot-container {
  margin: 28px 0;
  text-align: center;
  background: #f8fafc;
  padding: 16px;
  border-radius: 10px;
  border: 1px dashed #cbd5e1;
  min-height: 100px;
}

.ad-label {
  font-size: 0.7rem;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 8px;
  display: block;
}

/* Sidebar Styling (Costados) */
.sidebar {
  position: sticky;
  top: 80px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.sidebar-widget {
  background: var(--bg-card);
  border-radius: 14px;
  padding: 20px;
  border: 1px solid var(--border);
  box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.sidebar-widget h3 {
  font-size: 1.05rem;
  color: #0f172a;
  margin-bottom: 12px;
  font-weight: 700;
  border-bottom: 2px solid #e0f2fe;
  padding-bottom: 6px;
}

.sidebar-map-card {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: #ffffff;
  border-radius: 14px;
  padding: 22px;
  text-align: center;
}

.sidebar-map-card h3 {
  color: #ffffff;
  font-size: 1.15rem;
  margin-bottom: 8px;
}

.sidebar-map-card p {
  font-size: 0.85rem;
  color: #cbd5e1;
  margin-bottom: 16px;
}

.sidebar-map-card .btn-sidebar-cta {
  background: #38bdf8;
  color: #0f172a;
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 0.88rem;
  text-decoration: none;
  display: block;
  transition: background 0.2s;
}

.sidebar-map-card .btn-sidebar-cta:hover {
  background: #7dd3fc;
}

.sidebar-links {
  list-style: none;
  margin: 0;
  padding: 0;
}

.sidebar-links li {
  margin-bottom: 10px;
  font-size: 0.88rem;
}

.sidebar-links a {
  color: #334155;
  text-decoration: none;
  transition: color 0.15s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.sidebar-links a:hover {
  color: var(--accent);
  font-weight: 600;
}

/* FAQ Accordion / Box */
.faq-section {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.faq-card {
  background: #f8fafc;
  border-radius: 10px;
  padding: 18px 20px;
  margin-bottom: 14px;
  border: 1px solid var(--border);
}

.faq-q {
  font-weight: 700;
  color: #0f172a;
  margin-bottom: 8px;
  font-size: 1rem;
}

.faq-a {
  color: #334155;
  margin-bottom: 0 !important;
  font-size: 0.94rem;
}

/* CTA Box */
.cta-box {
  background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
  color: #ffffff;
  padding: 28px;
  border-radius: 12px;
  text-align: center;
  margin: 32px 0;
}

.cta-box h3 {
  color: #ffffff;
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.cta-box p {
  color: #cbd5e1;
  margin-bottom: 18px;
  font-size: 0.95rem;
}

.cta-box .btn-cta {
  background: #38bdf8;
  color: #0f172a;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  display: inline-block;
  transition: transform 0.2s, background 0.2s;
}

.cta-box .btn-cta:hover {
  background: #7dd3fc;
  transform: translateY(-2px);
}

/* Related Section */
.related-section {
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 14px;
  margin-top: 14px;
}

.related-card {
  background: #f8fafc;
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s, border-color 0.15s;
}

.related-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
}

.related-card h4 {
  font-size: 0.92rem;
  color: #0f172a;
  margin-bottom: 4px;
  line-height: 1.35;
}

.related-card p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0;
}

/* Hub Hero & Cards */
.hub-hero {
  background: linear-gradient(135deg, #0b1120 0%, #1e293b 100%);
  color: #ffffff;
  padding: 50px 24px;
  text-align: center;
  border-radius: 16px;
  margin-bottom: 36px;
  box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.hub-hero h1 {
  color: #ffffff;
  font-size: 2.4rem;
  margin-bottom: 12px;
}

.hub-hero p {
  color: #cbd5e1;
  font-size: 1.1rem;
  max-width: 760px;
  margin: 0 auto;
}

.cluster-card-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin: 40px 0 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e2e8f0;
}

.cluster-card-header img {
  width: 70px;
  height: 50px;
  object-fit: cover;
  border-radius: 8px;
}

.cluster-title {
  font-size: 1.4rem;
  color: #0f172a;
  font-weight: 800;
}

.guides-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.guide-item {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 22px;
  border: 1px solid var(--border);
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 2px 8px rgba(0,0,0,0.03);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}

.guide-item:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
  border-color: #38bdf8;
}

.guide-item h3 {
  font-size: 1.05rem;
  color: #0f172a;
  margin: 8px 0;
  font-weight: 700;
  line-height: 1.35;
}

.guide-item p {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin-bottom: 14px;
}

.guide-footer-meta {
  font-size: 0.8rem;
  color: var(--accent);
  font-weight: 600;
}

/* Footer */
.site-footer {
  background: #0b1120;
  color: #94a3b8;
  padding: 40px 20px 24px;
  margin-top: 60px;
  font-size: 0.88rem;
  border-top: 1px solid rgba(255,255,255,0.08);
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 18px;
  align-items: center;
  text-align: center;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.footer-links a {
  color: #cbd5e1;
  text-decoration: none;
  transition: color 0.15s;
}

.footer-links a:hover {
  color: #38bdf8;
}

/* Cookie Consent Banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #0f172a;
  color: #ffffff;
  padding: 16px 24px;
  z-index: 99999;
  box-shadow: 0 -4px 20px rgba(0,0,0,0.35);
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 0.88rem;
  line-height: 1.5;
}

.cookie-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.cookie-content p {
  margin: 0;
  flex: 1 1 500px;
  color: #cbd5e1;
}

.cookie-content a {
  color: #38bdf8;
  text-decoration: underline;
}

.cookie-buttons {
  display: flex;
  gap: 10px;
}

.btn-cookie-accept {
  background: #38bdf8;
  color: #0f172a;
  border: none;
  padding: 8px 18px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
}

.btn-cookie-reject {
  background: transparent;
  color: #94a3b8;
  border: 1px solid #475569;
  padding: 8px 14px;
  border-radius: 6px;
  font-size: 0.85rem;
  cursor: pointer;
}

@media (max-width: 900px) {
  .page-grid {
    grid-template-columns: 1fr;
  }
  .sidebar {
    position: static;
  }
  .article-card {
    padding: 24px 20px;
  }
  h1 {
    font-size: 1.65rem;
  }
  .header-nav .nav-link {
    display: none;
  }
}