:root {
  --primary: #0096d6;
  --background-light: #f5f7f8;
  --background-dark: #0f1d23;
  --slate-100: #f1f5f9;
  --slate-200: #e2e8f0;
  --slate-400: #94a3b8;
  --slate-500: #64748b;
  --slate-800: #1e293b;
  --slate-900: #0f172a;
  --white: #ffffff;
  --radius: 1rem;
  --radius-full: 9999px;
  --verde: #1e6e43;
  --verde-mid: #2d8a56;
  --verde-claro: rgba(30, 110, 67, 0.07);
  --dorado: #a06a10;
  --dorado-bg: rgba(160, 106, 16, 0.07);
  --bg-alt: #f0f4f2;
  --bg-card: #ffffff;
  --borde: #e2e8e4;
  --borde-medio: #c8d4cc;
  --texto: #111c16;
  --texto-suave: #4a5e52;
  --texto-medio: #2d3d32;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  background-color: var(--background-light);
  font-family: "Public Sans", sans-serif;
  color: var(--slate-900);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img {
  display: block;
  max-width: 100%;
}

a {
  text-decoration: none;
  color: inherit;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Libre Baskerville", serif;
}

p {
  font-family: "Lora", serif;
}

/* HEADER */
header {
  position: sticky;
  top: 0;
  z-index: 50;
  background-color: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--slate-200);
}

.header-inner {
  max-width: 80rem;
  margin: 0 auto;
  padding: 0 1rem;
  position: relative;
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 5rem;
  gap: 2rem;
}

.logo-wrap {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  height: 5rem;
  flex-shrink: 0;
}

.logo-icon {
  width: 6rem;
  height: 6rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.logo-text {
  font-size: 1.25rem;
  font-weight: 750;
  letter-spacing: -0.025em;
  color: var(--primary);
}

nav:not(.mobile-nav) {
  display: none;
  align-items: center;
  gap: 2.5rem;
  flex: 1;
  justify-content: center;
}

@media (min-width: 768px) {
  nav:not(.mobile-nav) {
    display: flex;
  }
}

nav:not(.mobile-nav) a {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--slate-900);
  transition: color 0.2s;
  white-space: nowrap;
  position: relative;
  padding-bottom: 3px;
  text-decoration: none;
}

nav:not(.mobile-nav) a::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--primary);
  border-radius: 2px;
  transition: width 0.25s ease;
}

nav:not(.mobile-nav) a:hover {
  color: var(--primary);
  text-decoration: none;
}

nav:not(.mobile-nav) a:hover::after {
  width: 100%;
}

.hamburger-btn {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 2.5rem;
  height: 2.5rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.375rem;
  border-radius: 0.5rem;
  transition: background-color 0.2s;
  flex-shrink: 0;
}

@media (max-width: 767px) {
  .hamburger-btn {
    display: flex;
  }
}

.hamburger-btn:hover {
  background-color: rgba(0, 150, 214, 0.1);
}

.hamburger-btn span {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--slate-900);
  border-radius: 2px;
  transition:
    transform 0.25s ease,
    opacity 0.25s ease;
}

.hamburger-btn.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.hamburger-btn.open span:nth-child(2) {
  opacity: 0;
}

.hamburger-btn.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background-color: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--slate-200);
  padding: 0.5rem 1rem 1rem;
  z-index: 49;
  flex-direction: column;
  gap: 0;
}

@media (max-width: 767px) {
  .mobile-nav.open {
    display: flex;
  }
}

@media (min-width: 768px) {
  .mobile-nav {
    display: none !important;
  }
}

.mobile-nav a {
  display: block;
  padding: 0.875rem 0.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--slate-900);
  border-bottom: 1px solid var(--slate-100);
  transition: color 0.2s;
  text-decoration: none;
}

.mobile-nav a:last-child {
  border-bottom: none;
}

.mobile-nav a:hover {
  color: var(--primary);
}

/* HERO */
.blog-hero {
  background: var(--bg-alt);
  padding: 80px 56px 64px;
  border-bottom: 1px solid var(--borde);
  position: relative;
  overflow: hidden;
}

.blog-hero::before {
  content: "BLOG";
  position: absolute;
  right: 20px;
  bottom: 60px;
  font-family: "Lora", serif;
  font-size: 12rem;
  font-weight: 600;
  color: transparent;
  -webkit-text-stroke: 1px rgba(30, 110, 67, 0.25);
  pointer-events: none;
  line-height: 1;
}

.hero-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--verde);
  font-weight: 500;
  margin-bottom: 20px;
}

.hero-label::before {
  content: "";
  width: 24px;
  height: 1px;
  background: var(--verde);
}

.blog-hero h1 {
  font-family: "Lora", serif;
  font-size: clamp(2.2rem, 4.5vw, 3.8rem);
  font-weight: 400;
  line-height: 1.15;
  color: var(--texto);
  max-width: 620px;
  margin-bottom: 20px;
}

.blog-hero h1 em {
  font-style: italic;
  color: var(--verde);
}

.blog-hero p {
  font-size: 1rem;
  font-weight: 300;
  line-height: 1.75;
  color: var(--texto-suave);
  max-width: 520px;
}

/* FILTROS */
.filtros {
  padding: 28px 56px;
  border-bottom: 1px solid var(--borde);
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.filtro-label {
  font-size: 0.72rem;
  color: var(--texto-suave);
  letter-spacing: 0.06em;
  margin-right: 4px;
}

.filtro-btn {
  padding: 7px 18px;
  border-radius: 50px;
  border: 1px solid var(--borde-medio);
  font-family: "Public Sans", sans-serif;
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--texto-medio);
  background: transparent;
  cursor: pointer;
  transition: all 0.2s;
  letter-spacing: 0.03em;
}

.filtro-btn:hover,
.filtro-btn.activo {
  background: var(--verde);
  color: #fff;
  border-color: var(--verde);
}

/* GRID */
.articulos-main {
  padding: 56px 56px 100px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
}

/* CARD */
.card {
  background: var(--bg-card);
  border: 1px solid var(--borde);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow: hidden;
  transition:
    transform 0.3s,
    box-shadow 0.3s;
  cursor: pointer;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 56px rgba(17, 28, 22, 0.1);
  z-index: 2;
}

.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--verde), var(--verde-mid));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s;
}

.card:hover::before {
  transform: scaleX(1);
}

.card.featured {
  grid-column: span 2;
}

.card.hidden {
  display: none;
}

/* Card image */
.card-img {
  width: 100%;
  height: 270px;
  object-fit: cover;
  border-radius: 0.75rem;
  margin-bottom: 1.25rem;
  flex-shrink: 0;
  transition:
    transform 0.4s ease,
    box-shadow 0.4s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.card:hover .card-img {
  transform: scale(1.02);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.card.featured .card-img {
  height: 240px;
}

.card-num {
  display: none;
}

.card-cat {
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--verde);
  font-weight: 500;
  margin-bottom: 12px;
}

.card h2 {
  font-family: "Lora", serif;
  font-size: 1.25rem;
  font-weight: 500;
  line-height: 1.35;
  color: var(--texto);
  margin-bottom: 8px;
}

.card.featured h2 {
  font-size: 1.7rem;
}

.card-sub {
  font-size: 0.82rem;
  font-style: italic;
  color: var(--texto-suave);
  margin-bottom: 18px;
  font-family: "Lora", serif;
  line-height: 1.5;
}

.card-resumen {
  font-size: 0.85rem;
  line-height: 1.75;
  color: var(--texto-suave);
  margin-bottom: 24px;
  flex: 1;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card.featured .card-resumen {
  -webkit-line-clamp: 5;
  line-clamp: 5;
}

.card-clave {
  background: var(--verde-claro);
  border-left: 3px solid var(--verde);
  border-radius: 0 10px 10px 0;
  padding: 14px 16px;
  margin-bottom: 24px;
}

.card-clave-titulo {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--verde-mid);
  font-weight: 500;
  margin-bottom: 6px;
}

.card-clave p {
  font-size: 0.8rem;
  line-height: 1.65;
  color: var(--texto-medio);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--borde);
}

.card-flecha {
  font-size: 0.72rem;
  letter-spacing: 0.06em;
  font-weight: 500;
  color: var(--dorado);
  display: flex;
  align-items: center;
  gap: 6px;
  transition: gap 0.2s;
}

.card:hover .card-flecha {
  gap: 12px;
}

.card-flecha-label {
  font-size: 0.72rem;
  color: var(--texto-suave);
  font-weight: 400;
}

/* MODAL */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 500;
  background: rgba(17, 28, 22, 0.55);
  backdrop-filter: blur(6px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

.modal {
  background: white;
  border-radius: 24px;
  max-width: 720px;
  width: 100%;
  max-height: 88vh;
  overflow-y: auto;
  padding: 0;
  transform: translateY(20px) scale(0.98);
  transition: transform 0.3s;
  box-shadow: 0 32px 100px rgba(17, 28, 22, 0.2);
}

.modal-overlay.open .modal {
  transform: translateY(0) scale(1);
}

.modal-header {
  padding: 48px 52px 32px;
  border-bottom: 1px solid var(--borde);
  background: var(--bg-alt);
  border-radius: 24px 24px 0 0;
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 32px;
  justify-content: space-between;
}

.modal-header-content {
  flex: 1;
}

.modal-icon {
  width: 80px;
  height: 80px;
  color: var(--verde);
  flex-shrink: 0;
  opacity: 0.8;
  filter: drop-shadow(0 4px 12px rgba(30, 110, 67, 0.15));
}

.modal-num {
  font-family: "Lora", serif;
  font-size: 5rem;
  font-weight: 600;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(30, 110, 67, 0.1);
  margin-bottom: 16px;
}

.modal-cat {
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--verde);
  font-weight: 500;
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.modal-cat::before {
  content: "";
  width: 20px;
  height: 1px;
  background: var(--verde);
}

.modal-header h2 {
  font-family: "Lora", serif;
  font-size: 2rem;
  font-weight: 500;
  line-height: 1.2;
  color: var(--texto);
  margin-bottom: 8px;
}

.modal-header .modal-sub {
  font-family: "Lora", serif;
  font-style: italic;
  font-size: 1rem;
  color: var(--texto-suave);
  line-height: 1.5;
}

.modal-close {
  position: absolute;
  top: 24px;
  right: 24px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--borde);
  background: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--texto-suave);
  transition: all 0.2s;
  z-index: 10;
}

.modal-close:hover {
  background: var(--verde);
  color: white;
  border-color: var(--verde);
}

.modal-body {
  padding: 40px 52px 52px;
}

.modal-body p {
  font-size: 0.92rem;
  line-height: 1.85;
  color: var(--texto-suave);
  margin-bottom: 20px;
  text-align: justify;
}

.modal-clave {
  background: var(--verde-claro);
  border-left: 4px solid var(--verde);
  border-radius: 0 12px 12px 0;
  padding: 20px 22px;
  margin: 28px 0;
}

.modal-clave-titulo {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--verde-mid);
  font-weight: 500;
  margin-bottom: 10px;
}

.modal-clave p {
  color: var(--texto-medio);
  margin-bottom: 0;
}

.modal-flecha {
  background: var(--dorado-bg);
  border: 1px solid rgba(160, 106, 16, 0.2);
  border-radius: 12px;
  padding: 18px 20px;
  margin-top: 28px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}

.modal-flecha-icon {
  font-size: 1.2rem;
  flex-shrink: 0;
  margin-top: 2px;
}

.modal-flecha-content h4 {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--dorado);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.modal-flecha-content p {
  font-size: 0.88rem;
  color: var(--texto-medio);
  margin: 0;
  text-align: left;
}

/* Modal icon animations */
@keyframes float-pulse {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }

  50% {
    transform: translateY(-6px) scale(1.05);
  }
}

.icon-light {
  animation: float-pulse 3s ease-in-out infinite;
}

@keyframes heartbeat {
  0%,
  100% {
    transform: scale(1);
  }

  25% {
    transform: scale(0.95);
  }

  50% {
    transform: scale(1.1);
  }
}

.icon-heart {
  animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes sway {
  0%,
  100% {
    transform: rotate(0deg);
  }

  50% {
    transform: rotate(2deg);
  }
}

.icon-mind {
  animation: sway 2.5s ease-in-out infinite;
}

@keyframes wave-motion {
  0%,
  100% {
    filter: blur(0px);
  }

  50% {
    filter: blur(0.5px);
  }
}

.icon-wave {
  animation: wave-motion 2s ease-in-out infinite;
}

@keyframes pull {
  0%,
  100% {
    transform: translateX(0);
  }

  50% {
    transform: translateX(4px);
  }
}

.icon-chain {
  animation: pull 2s ease-in-out infinite;
}

@keyframes scatter {
  0%,
  100% {
    transform: translate(0, 0) rotate(0deg);
  }

  50% {
    transform: translate(2px, -2px) rotate(5deg);
  }
}

.icon-fragments {
  animation: scatter 2.5s ease-in-out infinite;
}

@keyframes float-gentle {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }

  50% {
    transform: translateY(-8px) rotate(-3deg);
  }
}

.icon-leaf {
  animation: float-gentle 3.5s ease-in-out infinite;
}

@keyframes spin-slow {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

.icon-compass {
  animation: spin-slow 8s linear infinite;
}

@keyframes pulse-glow {
  0%,
  100% {
    opacity: 0.7;
    filter: drop-shadow(0 0 2px rgba(30, 110, 67, 0.3));
  }

  50% {
    opacity: 1;
    filter: drop-shadow(0 0 8px rgba(30, 110, 67, 0.6));
  }
}

.icon-pulse {
  animation: pulse-glow 1.5s ease-in-out infinite;
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(0.9);
  }
}

.icon-star {
  animation: twinkle 2s ease-in-out infinite;
}

/* REVEAL */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity 0.7s ease,
    transform 0.7s ease;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* FOOTER */
footer {
  background-color: var(--slate-900);
  color: white;
  padding: 6rem 1rem 3rem;
}

.footer-inner {
  max-width: 80rem;
  margin: 0 auto;
}

.footer-grid {
  display: grid;
  gap: 5rem;
  margin-bottom: 5rem;
}

@media (min-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.footer-grid h2 {
  font-size: 1.875rem;
  font-weight: 900;
  margin-bottom: 2rem;
}

form .form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

form label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--slate-400);
  margin-bottom: 0.5rem;
}

form input,
form textarea {
  width: 100%;
  background-color: var(--slate-800);
  border: none;
  border-radius: 0.5rem;
  padding: 1rem;
  color: white;
  font-family: inherit;
  font-size: 1rem;
  transition: box-shadow 0.2s;
}

form input:focus,
form textarea:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--primary);
}

form textarea {
  resize: vertical;
}

.btn-submit {
  width: 100%;
  background-color: var(--primary);
  color: white;
  padding: 1rem;
  border-radius: 0.5rem;
  font-weight: 700;
  font-size: 1.125rem;
  border: none;
  cursor: pointer;
  transition: box-shadow 0.2s;
}

.btn-submit:hover {
  box-shadow: 0 10px 15px -3px rgba(0, 150, 214, 0.2);
}

.program-select {
  background-color: var(--slate-800);
  border: 1px solid var(--primary);
  color: #f5f7f8;
  font-size: 1rem;
  font-family: "Lora", serif;
  padding: 1rem;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  width: 100%;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
}

.program-select:focus {
  outline: none;
  box-shadow: 0 0 0 2px var(--primary);
}

.program-select option {
  background: var(--background-light);
  color: var(--slate-900);
}

.contact-info {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.contact-item {
  display: flex;
  gap: 1rem;
}

.contact-item p {
  color: var(--slate-400);
}

.map-iframe {
  height: 255px;
  width: 100%;
  max-width: 600px;
  border: 0;
  border-radius: var(--radius);
  display: block;
  margin: auto;
  margin-bottom: 1rem;
}

.footer-bottom {
  border-top: 1px solid var(--slate-800);
  padding-top: 3rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
}

@media (min-width: 768px) {
  .footer-bottom {
    flex-direction: row;
    justify-content: space-between;
  }
}

.footer-logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.footer-logo .icon {
  width: 4rem;
  height: 4rem;
  border-radius: 0.25rem;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.footer-logo .icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.footer-logo span.name {
  font-weight: 700;
  color: var(--primary);
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

.footer-links a {
  color: var(--slate-400);
  transition: color 0.2s;
  font-size: 0.875rem;
}

.footer-links a:hover {
  color: white;
}

.footer-copy {
  text-align: center;
  color: var(--slate-100);
  font-size: 0.75rem;
  margin-top: 4.3rem;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
  .blog-hero,
  .filtros,
  .articulos-main {
    padding-left: 24px;
    padding-right: 24px;
  }

  .articulos-main {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  .card.featured {
    grid-column: span 2;
  }
}

@media (max-width: 768px) {
  .header-row {
    padding: 0 0.75rem;
    height: auto;
    min-height: 4rem;
  }

  .logo-wrap {
    height: auto;
    gap: 0.75rem;
  }

  .logo-icon {
    width: 3rem;
    height: 3rem;
  }

  .logo-text {
    font-size: 1rem;
  }

  .blog-hero {
    padding: 40px 18px 28px;
    min-height: 20rem;
  }

  .blog-hero h1 {
    font-size: 2.5rem;
  }

  .blog-hero::before {
    font-size: 8rem;
    opacity: 0.08;
  }

  .filtros {
    padding: 20px 18px;
  }

  .articulos-main {
    padding: 32px 18px 60px;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

  .card {
    padding: 24px 18px;
  }

  .card.featured {
    grid-column: span 2;
  }

  .card-img {
    height: 150px;
  }

  .card.featured .card-img {
    height: 190px;
  }
}

@media (max-width: 640px) {
  .articulos-main {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .card.featured {
    grid-column: 1;
  }

  .card-img {
    height: 180px;
  }

  .card.featured .card-img {
    height: 200px;
  }

  .modal-header {
    padding: 24px 16px 16px;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
  }

  .modal-body {
    padding: 24px 16px 32px !important;
  }

  .modal {
    max-width: 95vw;
    max-height: 90vh;
  }

  .modal-icon {
    width: 60px;
    height: 60px;
  }

  .modal-num {
    font-size: 2.8rem;
  }

  .modal-header h2 {
    font-size: 1.3rem;
  }

  .blog-hero {
    padding: 35px 16px 25px;
  }

  .blog-hero h1 {
    font-size: 2.2rem;
  }

  .blog-hero::before {
    font-size: 6rem;
    right: 10px;
    bottom: 20px;
    opacity: 0.1;
  }

  .filtros {
    padding: 16px;
    gap: 8px;
  }

  .filtro-btn {
    font-size: 0.75rem;
    padding: 8px 12px;
  }
}

@media (max-width: 480px) {
  .header-row {
    padding: 0 0.5rem;
    min-height: 3.5rem;
  }

  .logo-icon {
    width: 2.5rem;
    height: 2.5rem;
  }

  .logo-text {
    font-size: 0.85rem;
  }

  .articulos-main {
    padding: 24px 12px 48px;
    gap: 1rem;
  }

  .card {
    padding: 16px 12px;
  }

  .card-img {
    height: 150px;
  }

  .card-num {
    display: none;
  }

  .card h2 {
    font-size: 0.95rem;
  }

  .modal {
    max-width: 98vw;
    max-height: 95vh;
  }

  .modal-body {
    padding: 16px 12px 24px !important;
  }
}

/* Imagen ocupa toda la parte superior del modal header */
.modal-header-img {
  width: 100%;
  height: 550px;
  object-fit: cover;
  display: block;
  border-radius: 24px 24px 0 0;
  flex-shrink: 0;
}
/* Header en columna: imagen arriba, texto abajo */
#modalHeader {
  flex-direction: column !important;
  padding: 0 !important;
  gap: 0 !important;
  align-items: stretch !important;
}
.modal-header-content {
  padding: 28px 52px 24px !important;
  width: 100%;
}
/* Ocultar contenedor de SVG */
#modalIconWrap {
  display: none !important;
}
/* Botón cerrar flotando sobre la imagen */
.modal-close {
  top: 14px !important;
  right: 14px !important;
  background: rgba(255, 255, 255, 0.92) !important;
  backdrop-filter: blur(6px);
  border: none !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
}
@media (max-width: 640px) {
  .modal-header-img {
    height: 190px;
    border-radius: 20px 20px 0 0;
  }
  .modal-header-content {
    padding: 20px 16px 16px !important;
  }
}
