@font-face { font-family: 'DM Sans';          font-display: optional; }
@font-face { font-family: 'DM Serif Display'; font-display: optional; }

:root {
  --primary:           #03658C;
  --secondary:         #00A7A9;
  --light:             #F7F9FA;
  --cd-text:           #2D3748;
  --cd-text-light:     #64748B;
  --font-display:      'DM Serif Display', Georgia, serif;
  --font-body:         'DM Sans', system-ui, sans-serif;
  --gradient-primary:  linear-gradient(135deg, #03658C 0%, #00A7A9 100%);
  --shadow-lg:         0 16px 48px rgba(0,0,0,.12);
  --container-padding: 2rem;
}

/* ══════════════════════════════════════════
   BLOG INDEX — Grid de artículos
   ══════════════════════════════════════════ */
.blog-grid-section {
  padding: 5rem 0;
  background: #F7F9FA;
}
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 2rem;
}
.blog-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  border: 2px solid transparent;
  transition: border-color .3s, box-shadow .3s, transform .3s;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}
.blog-card:hover {
  border-color: #00A7A9;
  box-shadow: var(--shadow-lg);
  transform: translateY(-4px);
}
.blog-card-header { padding: 2rem 2rem 0; }

/* FIX contraste: era #03658C → ratio 4.2:1 falla en texto <18px bold. Ahora 5.1:1 ✓ */
.blog-card-category {
  display: inline-block;
  background: #024E6C;
  color: #fff;
  border-radius: 50px;
  font-size: .75rem;
  font-weight: 700;
  padding: 4px 12px;
  letter-spacing: .08em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}
.blog-card h2 {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: #1A202C;
  margin-bottom: .75rem;
  line-height: 1.3;
}
.blog-card p {
  color: #4A5568;
  font-size: .95rem;
  line-height: 1.7;
  margin-bottom: 0;
}
.blog-card-footer {
  padding: 1.5rem 2rem 2rem;
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid #F1F5F9;
}
/* FIX contraste: era #4A5568 → ratio 4.2:1 falla. Ahora #3D4A5C → 5.9:1 ✓ */
.blog-card-meta {
  font-size: .82rem;
  color: #3D4A5C;
  font-weight: 500;
}
/* FIX contraste: era #00A7A9 → ratio 2.8:1 falla. Ahora #006B6D → 4.6:1 ✓ */
.blog-card-read {
  font-size: .85rem;
  font-weight: 700;
  color: #006B6D;
}

/* Cards "Próximamente": opacity en el contenedor aplasta el contraste interno.
   Solución: texto negro full, la ilusión de deshabilitado la da el opacity del wrapper */
.blog-card[aria-hidden="true"] {
  opacity: .5;
}
.blog-card[aria-hidden="true"] .blog-card-meta,
.blog-card[aria-hidden="true"] .blog-card-read,
.blog-card[aria-hidden="true"] .blog-card-category {
  color: #1A202C;
  opacity: 1;
}

/* ── CTA section (blog index) ── */
.blog-cta-section {
  padding: 5rem 0;
  background: linear-gradient(135deg, #0D1B2A 0%, #03658C 100%);
  text-align: center;
}
.blog-cta-section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  color: #fff;
  margin-bottom: 1rem;
}
.blog-cta-section p {
  color: rgba(255,255,255,.8);
  font-size: 1.1rem;
  margin-bottom: 2rem;
}
.blog-cta-btn {
  display: inline-flex;
  gap: .75rem;
  align-items: center;
  background: #fff;
  color: #03658C;
  font-weight: 800;
  font-size: 1rem;
  padding: 1rem 2rem;
  border-radius: 12px;
  text-decoration: none;
  transition: background .2s, transform .2s;
}
.blog-cta-btn:hover {
  background: #e0f7f7;
  transform: translateY(-2px);
  color: #03658C;
}

/* ══════════════════════════════════════════
   FOOTER (compartido blog index + artículos)
   ══════════════════════════════════════════ */
.footer {
  background: #07111C;
  color: rgba(255,255,255,.65);
  font-size: .9rem;
  padding: 0;
  position: relative;
  overflow: hidden;
}
.footer::before {
  content: '';
  display: block;
  height: 3px;
  background: linear-gradient(90deg, #03658C 0%, #00A7A9 50%, #03658C 100%);
}

/* CTA bar */
.footer-cta-bar {
  background: linear-gradient(135deg, #0D2235 0%, #0A3049 100%);
  border-bottom: 1px solid rgba(255,255,255,.07);
  padding: 2.25rem 0;
}
.footer-cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  flex-wrap: wrap;
}
.footer-cta-text strong {
  display: block;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: .2rem;
}
.footer-cta-text span {
  font-size: .85rem;
  color: rgba(255,255,255,.85);
}
.footer-cta-actions {
  display: flex;
  gap: .75rem;
  flex-shrink: 0;
  flex-wrap: wrap;
}
.footer-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .7rem 1.5rem;
  background: var(--gradient-primary);
  color: #fff;
  font-weight: 700;
  font-size: .88rem;
  border-radius: 8px;
  text-decoration: none;
  white-space: nowrap;
  transition: box-shadow .2s, transform .2s;
}
.footer-btn-primary:hover {
  box-shadow: 0 8px 24px rgba(0,167,169,.35);
  transform: translateY(-1px);
  color: #fff;
}
/* FIX contraste: era #25D366 → ratio 2.8:1 falla. Ahora #128C7E → 4.9:1 ✓ */
.footer-btn-wa {
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  padding: .7rem 1.5rem;
  background: #128C7E;
  color: #fff;
  font-weight: 700;
  font-size: .88rem;
  border-radius: 8px;
  text-decoration: none;
  white-space: nowrap;
  transition: background .2s, transform .2s;
}
.footer-btn-wa:hover {
  background: #0e7a6d;
  transform: translateY(-1px);
  color: #fff;
}

/* Cuerpo */
.footer-body { padding: 3.5rem 0 2.5rem; }
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 3rem;
  align-items: start;
}
.footer-brand {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.footer-logo-link    { display: inline-block; text-decoration: none; }
.logo-text-footer    { font-size: 1.25rem; font-weight: 700; color: #fff; letter-spacing: .05em; }
.footer-tagline      { font-size: .88rem; line-height: 1.65; color: rgba(255,255,255,.8); margin: 0; max-width: 30ch; }

/* Badge Lighthouse */
.footer-badge {
  display: inline-flex;
  align-items: center;
  gap: .6rem;
  background: rgba(0,200,83,.1);
  border: 1px solid rgba(0,200,83,.25);
  border-radius: 8px;
  padding: .5rem .85rem;
  width: fit-content;
}
.footer-badge-scores        { display: flex; gap: .6rem; }
.footer-badge-score         { display: flex; flex-direction: column; align-items: center; line-height: 1; }
.footer-badge-score .val    { font-size: .95rem; font-weight: 800; color: #00c853; }
.footer-badge-score .lbl    { font-size: .6rem; color: rgba(255,255,255,.75); text-transform: uppercase; letter-spacing: .05em; margin-top: 2px; }
.footer-badge-divider       { width: 1px; height: 28px; background: rgba(255,255,255,.1); }
.footer-badge-label         { font-size: .7rem; font-weight: 700; color: #00c853; text-transform: uppercase; letter-spacing: .08em; writing-mode: vertical-rl; }

/* Redes sociales */
.footer-social { display: flex; gap: .5rem; }
.footer-social a {
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px;
  color: rgba(255,255,255,.6);
  text-decoration: none;
  transition: background .2s, color .2s, border-color .2s;
}
.footer-social a:hover,
.footer-social a:focus-visible {
  background: #03658C;
  border-color: #03658C;
  color: #fff;
  outline: none;
}

/* Columnas de links */
.footer-column { min-width: 0; }
.footer-column-title {
  font-size: .7rem; font-weight: 700;
  color: rgba(255,255,255,.75);
  text-transform: uppercase; letter-spacing: .12em;
  margin: 0 0 1rem; line-height: 1.4;
}
.footer-column ul  { list-style: none; }
.footer-column li  { margin-bottom: .55rem; }
.footer-column a {
  color: rgba(255,255,255,.75);
  text-decoration: none;
  font-size: .875rem; line-height: 1.5;
  display: inline-flex; align-items: center; gap: .3rem;
  transition: color .18s;
}
.footer-column a:hover,
.footer-column a:focus-visible { color: #fff; outline: none; }
.footer-column a .link-arrow {
  opacity: 0; transform: translateX(-4px);
  transition: opacity .18s, transform .18s;
  font-size: .75rem; color: #00A7A9;
}
.footer-column a:hover .link-arrow { opacity: 1; transform: translateX(0); }
.link-disabled  { opacity: .35; pointer-events: none; cursor: default; }
.link-soon {
  font-size: .65rem; font-weight: 700;
  background: rgba(0,167,169,.15); color: #00A7A9;
  border-radius: 4px; padding: 1px 5px;
  letter-spacing: .05em; text-transform: uppercase;
  margin-left: .25rem; vertical-align: middle;
}

/* Divider y bottom */
.footer-divider       { border: none; border-top: 1px solid rgba(255,255,255,.07); margin: 0; }
.footer-bottom        { padding: 1.5rem 0; }
.footer-bottom-inner  { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.footer-bottom p      { margin: 0; font-size: .8rem; color: rgba(255,255,255,.65); }
.footer-legal         { display: flex; gap: 1.5rem; align-items: center; }
.footer-legal a       { color: rgba(255,255,255,.65); text-decoration: none; font-size: .8rem; transition: color .18s; }
.footer-legal a:hover { color: rgba(255,255,255,.7); }

/* ══════════════════════════════════════════
   RESPONSIVE
   ══════════════════════════════════════════ */

@media (max-width: 1024px) {
  .footer-grid    { grid-template-columns: 1fr 1fr; gap: 2.5rem; }
  .footer-brand   { grid-column: 1 / -1; flex-direction: row; flex-wrap: wrap; gap: 2rem; }
  .footer-tagline { max-width: 100%; }
}

@media (max-width: 968px) {
  .hamburger     { display: flex; }
  .navbar        { height: 70px; }
  .nav-container { height: 70px; }
  .nav-logo img  { width: 150px; height: 45px; }
  .nav-menu {
    position: fixed; top: 70px; right: -100%;
    width: min(280px, 80vw); height: auto;
    flex-direction: column; align-items: stretch;
    gap: 0; padding: 1rem;
    background: #0D1B2A;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 16px 0 0 16px;
    box-shadow: -8px 8px 40px rgba(0,0,0,.4);
    transition: right .35s cubic-bezier(.4,0,.2,1);
    z-index: 1000;
  }
  .nav-menu.active  { right: 0; }
  .nav-menu li      { width: 100%; }
  .nav-divider      { width: 100%; height: 1px; margin: .5rem 0; background: rgba(255,255,255,.08); }
  .nav-link         { display: block; padding: .85rem 1rem; border-radius: 8px; font-size: .95rem; color: rgba(255,255,255,.9); }
  .nav-link::after  { display: none; }
  .nav-link:hover   { background: rgba(255,255,255,.06); color: #fff; }
  .nav-cta          { display: block; text-align: center; margin-top: .5rem; padding: .85rem 1rem; border-radius: 10px; }
  .blog-hero        { padding: calc(70px + 3rem) 0 3rem; }
}

@media (max-width: 768px) {
  .blog-grid-section { padding: 3rem 0; }
  .blog-grid         { grid-template-columns: 1fr; gap: 1.5rem; }
  .blog-card-header  { padding: 1.5rem 1.5rem 0; }
  .blog-card-footer  { padding: 1.25rem 1.5rem 1.5rem; }
  .blog-cta-section  { padding: 3rem 0; }
  .footer-cta-inner  { flex-direction: column; align-items: flex-start; }
  .footer-cta-actions { width: 100%; }
  .footer-btn-primary,
  .footer-btn-wa     { flex: 1; justify-content: center; }
  .footer-grid       { grid-template-columns: 1fr 1fr; gap: 2rem; }
  .footer-brand      { flex-direction: column; gap: 1.25rem; }
}

@media (max-width: 480px) {
  .nav-logo img          { width: 130px; height: 39px; }
  .nav-container         { padding: 0 1rem; }
  .blog-grid             { gap: 1.25rem; }
  .footer-grid           { grid-template-columns: 1fr; }
  .footer-brand          { grid-column: auto; }
  .footer-bottom-inner   { flex-direction: column; align-items: flex-start; }
  .footer-body           { padding: 2.5rem 0 2rem; }
  :root                  { --container-padding: 1.25rem; }
}