:root {
  --navy: #0B2C3D;
  --navy-2: #133B4E;
  --teal: #1C8B87;
  --teal-soft: #E5F4F2;
  --ink: #13232D;
  --muted: #687983;
  --line: #DCE6EA;
  --soft: #F4F8F9;
  --white: #fff;
  --shadow: 0 20px 60px rgba(11, 44, 61, .10);
  --radius: 24px;
  --container: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--white);
  font-family: "DM Sans", sans-serif;
  line-height: 1.65;
}
body.modal-open { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; }
[hidden] { display: none !important; }

.container { width: min(calc(100% - 40px), var(--container)); margin: 0 auto; }
.section { padding: 110px 0; }
.skip-link {
  position: fixed; left: 20px; top: -100px; z-index: 2000;
  background: var(--navy); color: white; padding: 10px 14px; border-radius: 10px;
}
.skip-link:focus { top: 20px; }

.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255,255,255,.88);
  backdrop-filter: blur(18px);
  border-bottom: 1px solid rgba(220,230,234,.7);
}
.header-inner { min-height: 82px; display: flex; align-items: center; justify-content: space-between; gap: 30px; }
.brand { display: flex; align-items: center; gap: 11px; }
.brand-mark {
  width: 42px; height: 42px; border-radius: 13px; display: grid; place-items: center;
  background: var(--navy); color: white; font-family: "Manrope"; font-weight: 800; font-size: 13px;
}
.brand-copy { display: grid; line-height: 1.1; }
.brand-copy strong { font-family: "Manrope"; font-size: 14px; }
.brand-copy small { color: var(--muted); font-size: 11px; margin-top: 4px; }

.primary-nav { display: flex; align-items: center; gap: 22px; }
.primary-nav a { font-size: 13px; font-weight: 600; color: #425963; }
.primary-nav a:hover { color: var(--navy); }
.primary-nav .nav-cta { padding: 12px 17px; color: white; background: var(--navy); border-radius: 11px; }
.nav-toggle { display: none; border: 0; background: transparent; padding: 8px; }
.nav-toggle span { display: block; width: 25px; height: 2px; margin: 5px 0; background: var(--navy); }

.hero { position: relative; padding-top: 75px; padding-bottom: 0; overflow: hidden; background: linear-gradient(135deg, #F8FBFC 0%, #EEF7F7 100%); }
.hero-grid { display: grid; grid-template-columns: 1.02fr .98fr; gap: 60px; align-items: center; min-height: 650px; }
.eyebrow {
  font-family: "Manrope"; letter-spacing: .13em; font-weight: 800; color: var(--teal);
  font-size: 11px; text-transform: uppercase; display: flex; align-items: center; gap: 10px;
}
.eyebrow.light { color: #9FE2DD; }
.eyebrow-dot { width: 7px; height: 7px; background: var(--teal); border-radius: 50%; }
h1,h2,h3,h4 { font-family: "Manrope", sans-serif; line-height: 1.12; margin: 0 0 18px; color: var(--navy); }
h1 { font-size: clamp(48px, 6vw, 76px); letter-spacing: -.055em; max-width: 700px; margin-top: 18px; }
h1 span { color: var(--teal); }
.hero-lead { font-size: 18px; color: var(--muted); max-width: 630px; }
.hero-actions { display: flex; gap: 12px; margin-top: 30px; }
.btn {
  display: inline-flex; justify-content: center; align-items: center; gap: 12px;
  min-height: 48px; padding: 0 20px; border-radius: 12px; border: 1px solid transparent;
  font-weight: 700; font-size: 13px; cursor: pointer; transition: .25s ease;
}
.btn-primary { background: var(--navy); color: white; box-shadow: 0 12px 28px rgba(11,44,61,.18); }
.btn-primary:hover { transform: translateY(-2px); background: #123A51; }
.btn-secondary { background: white; border-color: var(--line); color: var(--navy); }
.btn-secondary:hover { border-color: var(--teal); transform: translateY(-2px); }
.btn-white { background: white; color: var(--navy); }
.btn-outline-white { color: white; border-color: rgba(255,255,255,.35); }
.btn-outline-white:hover { background: rgba(255,255,255,.08); }
.hero-trust { display: flex; flex-wrap: wrap; gap: 14px 22px; margin-top: 28px; color: #58707A; font-size: 12px; }
.hero-visual { position: relative; min-height: 560px; }
.doctor-frame {
  width: min(500px, 100%); height: 600px; margin-left: auto; overflow: hidden;
  border-radius: 34px; background: #CFE2E2; position: relative; box-shadow: var(--shadow);
}
.doctor-frame img { width: 100%; height: 100%; object-fit: cover; }
.doctor-badge {
  position: absolute; bottom: 24px; left: 24px; right: 24px; padding: 15px 17px;
  background: rgba(255,255,255,.92); backdrop-filter: blur(14px); border-radius: 18px; display: flex; gap: 13px; align-items: center;
}
.badge-icon { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--teal-soft); color: var(--teal); font-weight: 800; }
.doctor-badge strong, .doctor-badge span { display: block; }
.doctor-badge strong { font-size: 12px; color: var(--navy); }
.doctor-badge span { font-size: 11px; color: var(--muted); margin-top: 2px; }
.floating-note {
  position: absolute; right: -20px; top: 58px; transform: rotate(4deg);
  background: var(--navy); color: white; padding: 15px 17px; border-radius: 14px; font-size: 11px;
  box-shadow: var(--shadow); display: flex; align-items: center; gap: 9px;
}
.note-line { width: 24px; height: 2px; background: #86D6D1; }

.hero-bottom { border-top: 1px solid rgba(11,44,61,.08); background: rgba(255,255,255,.72); }
.quick-links { display: grid; grid-template-columns: repeat(3, 1fr); }
.quick-links a { min-height: 92px; padding: 18px 22px; border-right: 1px solid var(--line); display: flex; align-items: center; gap: 14px; transition: .25s ease; }
.quick-links a:first-child { border-left: 1px solid var(--line); }
.quick-links a:hover { background: white; }
.quick-links strong,.quick-links small { display: block; }
.quick-links strong { font-size: 13px; }
.quick-links small { font-size: 11px; color: var(--muted); margin-top: 2px; }
.quick-links b { margin-left: auto; color: var(--teal); }
.quick-icon { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--soft); color: var(--teal); font-size: 11px; font-weight: 800; }

.two-col { display: grid; grid-template-columns: .9fr 1.1fr; gap: 90px; align-items: center; }
.image-card { border-radius: 30px; overflow: hidden; background: #DDEDED; min-height: 530px; box-shadow: var(--shadow); }
.image-card img { width: 100%; height: 100%; min-height: 530px; object-fit: cover; }
.section-image { position: relative; }
.experience-chip {
  position: absolute; bottom: 30px; right: -18px; background: var(--navy); color: white; border-radius: 18px;
  padding: 17px 20px; display: flex; align-items: center; gap: 13px; box-shadow: var(--shadow);
}
.experience-chip strong { font: 800 38px/1 "Manrope"; }
.experience-chip span { font-size: 11px; line-height: 1.35; color: #CFE1E7; }
.section-copy h2,.section-heading h2,.prevention-intro h2,.innovation-card h2,.cta-inner h2 { font-size: clamp(35px, 4vw, 54px); letter-spacing: -.045em; }
.section-copy p { color: var(--muted); font-size: 16px; }
.credentials { margin: 28px 0; border-top: 1px solid var(--line); }
.credentials div { display: flex; gap: 16px; align-items: center; padding: 14px 0; border-bottom: 1px solid var(--line); }
.credentials span { width: 27px; color: var(--teal); font-size: 11px; font-weight: 800; }
.credentials strong { font-size: 13px; }
.text-link { font-size: 13px; font-weight: 800; color: var(--teal); }
.text-link span { margin-left: 5px; transition: .25s; }
.text-link:hover span { margin-left: 10px; }

.services-section { background: var(--soft); }
.centered { text-align: center; max-width: 800px; margin: 0 auto 45px; }
.section-heading p { color: var(--muted); max-width: 650px; margin: 0 auto; }
.service-feature-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 18px; }
.service-feature { position: relative; padding: 32px; min-height: 330px; background: white; border: 1px solid var(--line); border-radius: var(--radius); transition: .3s; overflow: hidden; }
.service-feature:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.service-feature.featured { background: var(--navy); color: white; border-color: var(--navy); }
.service-feature.featured h3,.service-feature.featured p,.service-feature.featured a { color: white; }
.service-number { position: absolute; right: 25px; top: 23px; font: 800 11px "Manrope"; color: #A8B9BF; }
.service-icon { width: 54px; height: 54px; display: grid; place-items: center; border-radius: 17px; background: var(--teal-soft); color: var(--teal); font-size: 24px; margin-bottom: 48px; }
.service-feature.featured .service-icon { background: rgba(255,255,255,.12); color: #95DED8; }
.service-feature h3 { font-size: 24px; }
.service-feature p { color: var(--muted); font-size: 13px; }
.service-feature a { color: var(--teal); font-size: 12px; font-weight: 800; position: absolute; left: 32px; bottom: 27px; }
.service-list-wrap { margin-top: 18px; display: grid; grid-template-columns: 1.25fr .75fr; background: white; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.service-list-main, .service-list-advanced { padding: 35px; }
.service-list-advanced { background: #F9FCFC; border-left: 1px solid var(--line); }
.service-list-main h3 { font-size: 25px; margin-top: 9px; }
.tag-grid { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 20px; }
.tag-grid span { border: 1px solid var(--line); border-radius: 999px; padding: 8px 11px; font-size: 11px; color: #52666F; background: #FBFDFD; }
.advanced-item { padding: 17px 0; border-bottom: 1px solid var(--line); }
.advanced-item:last-child { border-bottom: 0; }
.advanced-item strong { font-size: 14px; }
.advanced-item p { color: var(--muted); font-size: 12px; margin: 7px 0 0; }

.prevention-section { background: var(--navy); color: white; }
.prevention-section h2 { color: white; }
.prevention-intro { display: grid; grid-template-columns: 1fr .8fr; gap: 60px; align-items: end; margin-bottom: 42px; }
.prevention-intro p { color: #B5CED7; max-width: 500px; margin-left: auto; }
.prevention-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 14px; }
.prevention-card { padding: 30px; min-height: 430px; border: 1px solid rgba(255,255,255,.14); border-radius: 24px; background: rgba(255,255,255,.035); position: relative; transition: .3s; }
.prevention-card:hover { transform: translateY(-5px); background: rgba(255,255,255,.06); }
.prevention-index { position: absolute; top: 24px; right: 24px; color: #7093A0; font: 800 11px "Manrope"; }
.prevention-icon { width: 49px; height: 49px; border-radius: 15px; background: rgba(134,214,209,.12); color: #97DCD7; display: grid; place-items: center; margin-bottom: 52px; font-weight: 800; }
.prevention-card h3 { color: white; font-size: 22px; max-width: 290px; }
.prevention-card ul { padding-left: 18px; color: #BCD2D9; font-size: 12px; }
.prevention-card li { margin: 7px 0; }
.prevention-card a { position: absolute; bottom: 25px; color: #98DFDA; font-size: 12px; font-weight: 800; }
.liver-path { color: #B9D2D8; font-size: 11px; padding: 10px 0; border-top: 1px solid rgba(255,255,255,.1); border-bottom: 1px solid rgba(255,255,255,.1); }

.content-grid { display: grid; grid-template-columns: 1fr .7fr; gap: 18px; }
.content-card { min-height: 270px; border-radius: 24px; padding: 26px; border: 1px solid var(--line); position: relative; overflow: hidden; background: white; }
.content-card.large { background: linear-gradient(135deg, #0B2C3D, #1B4D62); color: white; grid-row: span 2; min-height: 560px; }
.content-card.large h3 { color: white; max-width: 520px; font-size: 33px; }
.content-label { font: 800 10px "Manrope"; letter-spacing: .12em; color: var(--teal); }
.content-card.large .content-label { color: #95DED8; }
.content-card-bottom { position: absolute; left: 26px; right: 26px; bottom: 26px; }
.content-card a { font-size: 12px; font-weight: 800; color: var(--teal); }
.content-card.large a { color: #98DFDA; }
.video-card { background: linear-gradient(135deg, #E8F4F2, #F9FCFC); }
.play-button { width: 60px; height: 60px; border-radius: 50%; background: var(--navy); color: white; display: grid; place-items: center; margin: 45px auto 0; padding-left: 3px; }
.video-card h3 { font-size: 19px; margin-bottom: 10px; }
.faq-card { min-height: 290px; }
.faq-list { margin-top: 20px; }
.faq-item { width: 100%; background: transparent; border: 0; padding: 13px 0; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; gap: 20px; text-align: left; cursor: pointer; color: var(--navy); font-weight: 700; font-size: 12px; }
.faq-item b { color: var(--teal); font-size: 18px; line-height: 1; }
.faq-answer { max-height: 0; overflow: hidden; transition: max-height .28s ease; }
.faq-answer p { font-size: 11px; color: var(--muted); margin: 8px 0 11px; }

.innovation-section { background: var(--soft); }
.innovation-card { display: grid; grid-template-columns: .9fr 1.1fr; gap: 60px; padding: 46px; background: white; border-radius: 30px; border: 1px solid var(--line); box-shadow: var(--shadow); }
.innovation-card p { color: var(--muted); }
.innovation-list { display: grid; gap: 10px; align-content: center; }
.innovation-list div { padding: 15px 17px; border: 1px solid var(--line); border-radius: 14px; font-size: 12px; font-weight: 700; display: flex; gap: 10px; align-items: center; }
.innovation-list span { width: 23px; height: 23px; border-radius: 7px; background: var(--teal-soft); color: var(--teal); display: grid; place-items: center; font-size: 11px; }

.cta-section { background: var(--teal); color: white; padding: 72px 0; }
.cta-inner { display: flex; justify-content: space-between; gap: 40px; align-items: center; }
.cta-inner h2 { color: white; margin-top: 8px; }
.cta-inner p { color: #D8F0EE; margin: 0; }
.cta-actions { display: flex; gap: 10px; flex-shrink: 0; }

.site-footer { background: #071E2A; color: white; padding: 70px 0 25px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr .7fr .7fr; gap: 55px; padding-bottom: 45px; }
.footer-brand .brand-mark { background: white; color: var(--navy); }
.footer-brand .brand-copy strong { color: white; }
.footer-brand .brand-copy small { color: #93AAB3; }
.footer-note { max-width: 500px; color: #91A9B2; font-size: 11px; margin-top: 18px; }
.site-footer h4 { color: white; font-size: 12px; margin-bottom: 13px; }
.site-footer .footer-grid > div:not(:first-child) a, .site-footer .footer-grid > div:not(:first-child) span { display: block; color: #90A8B1; font-size: 11px; margin: 8px 0; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.08); padding-top: 20px; display: flex; justify-content: space-between; color: #78919B; font-size: 10px; }

.floating-whatsapp { position: fixed; right: 20px; bottom: 20px; z-index: 900; width: 56px; height: 56px; border-radius: 50%; background: #1CA572; color: white; display: grid; place-items: center; box-shadow: 0 18px 35px rgba(0,0,0,.18); font-weight: 800; font-size: 12px; }

.appointment-modal { width: min(94vw, 530px); border: 0; padding: 0; border-radius: 24px; box-shadow: 0 35px 100px rgba(0,0,0,.25); }
.appointment-modal::backdrop { background: rgba(5,24,34,.65); backdrop-filter: blur(5px); }
.modal-card { padding: 34px; position: relative; }
.modal-card h2 { font-size: 34px; margin-top: 8px; }
.modal-card > p { color: var(--muted); font-size: 12px; }
.modal-close { position: absolute; top: 16px; right: 17px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--line); background: white; cursor: pointer; font-size: 21px; color: var(--muted); }
#appointmentForm { display: grid; gap: 13px; margin-top: 22px; }
#appointmentForm label { display: grid; gap: 6px; font-weight: 700; font-size: 11px; }
#appointmentForm input, #appointmentForm select { width: 100%; height: 45px; border: 1px solid var(--line); border-radius: 11px; padding: 0 12px; outline: 0; color: var(--ink); background: white; }
#appointmentForm input:focus, #appointmentForm select:focus { border-color: var(--teal); box-shadow: 0 0 0 4px rgba(28,139,135,.1); }
.full { width: 100%; margin-top: 6px; }

.reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s ease, transform .7s ease; }
.reveal.is-visible { opacity: 1; transform: none; }
.hero-orb { position: absolute; border-radius: 50%; filter: blur(1px); pointer-events: none; }
.orb-a { width: 440px; height: 440px; background: rgba(28,139,135,.07); top: -180px; right: 22%; }
.orb-b { width: 260px; height: 260px; background: rgba(11,44,61,.04); bottom: -130px; left: -80px; }

@media (max-width: 980px) {
  .primary-nav { gap: 13px; }
  .primary-nav .nav-cta { padding: 10px 12px; }
  .hero-grid { gap: 35px; }
  .doctor-frame { height: 520px; }
  .two-col { gap: 50px; }
  .service-feature-grid, .prevention-grid { grid-template-columns: 1fr; }
  .prevention-card { min-height: auto; padding-bottom: 70px; }
  .content-grid { grid-template-columns: 1fr; }
  .content-card.large { min-height: 390px; grid-row: auto; }
  .innovation-card { grid-template-columns: 1fr; }
  .cta-inner { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 780px) {
  .container { width: min(calc(100% - 28px), var(--container)); }
  .section { padding: 80px 0; }
  .nav-toggle { display: block; }
  .primary-nav {
    position: absolute; left: 14px; right: 14px; top: calc(100% + 10px);
    background: white; border: 1px solid var(--line); border-radius: 18px; padding: 10px;
    box-shadow: var(--shadow); flex-direction: column; align-items: stretch; display: none;
  }
  .primary-nav.active { display: flex; }
  .primary-nav a { padding: 11px 12px; }
  .primary-nav .nav-cta { text-align: center; margin-top: 4px; }
  .hero { padding-top: 40px; }
  .hero-grid, .two-col, .prevention-intro, .service-list-wrap { grid-template-columns: 1fr; }
  .hero-grid { min-height: auto; }
  .hero-visual { min-height: 430px; margin-top: 15px; }
  .doctor-frame { margin: 0 auto; width: 100%; height: 460px; }
  .floating-note { right: 4px; }
  .experience-chip { right: 8px; }
  .quick-links { grid-template-columns: 1fr; }
  .quick-links a { border-left: 1px solid var(--line); border-bottom: 1px solid var(--line); }
  .quick-links a:first-child { border-top: 0; }
  .service-list-advanced { border-left: 0; border-top: 1px solid var(--line); }
  .innovation-card { padding: 30px 22px; }
  .cta-actions { width: 100%; }
  .cta-actions .btn { flex: 1; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
}

@media (max-width: 520px) {
  h1 { font-size: 46px; }
  .hero-lead { font-size: 16px; }
  .hero-actions { flex-direction: column; }
  .hero-actions .btn { width: 100%; }
  .hero-trust { display: grid; }
  .doctor-frame { height: 400px; }
  .section-copy h2,.section-heading h2,.prevention-intro h2,.innovation-card h2,.cta-inner h2 { font-size: 36px; }
  .experience-chip { right: 8px; bottom: 18px; }
  .service-feature { min-height: 310px; }
  .cta-actions { flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-grid > div:first-child { grid-column: auto; }
  .footer-bottom { flex-direction: column; gap: 7px; }
  .floating-whatsapp { width: 50px; height: 50px; right: 14px; bottom: 14px; }
}

/* ============================================================
   Fase 4 — contenido dinámico del CMS
   (servicios, videos, publicaciones y productos)
   ============================================================ */

/* Entrada de las tarjetas insertadas por JS. No usan .reveal para no
   depender del IntersectionObserver; "backwards" evita que la animación
   bloquee el transform del :hover al terminar. */
.contenido-card { animation: contenido-aparecer .45s ease backwards; }
@keyframes contenido-aparecer {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

/* Estado de carga */
.skeleton-card {
  min-height: 260px; border-radius: var(--radius);
  background: linear-gradient(100deg, #EEF4F5 30%, #F7FBFB 50%, #EEF4F5 70%);
  background-size: 200% 100%;
  animation: skeleton-brillo 1.3s infinite linear;
}
@keyframes skeleton-brillo {
  from { background-position: 200% 0; }
  to   { background-position: -200% 0; }
}
.contenido-vacio {
  grid-column: 1 / -1; text-align: center; color: var(--muted);
  padding: 34px; border: 1px dashed var(--line); border-radius: var(--radius);
}

/* Videos */
.videos-section { background: var(--soft); }
.videos-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.video-item {
  display: flex; flex-direction: column; overflow: hidden; background: white;
  border: 1px solid var(--line); border-radius: var(--radius); transition: .3s;
}
.video-item:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.video-media {
  min-height: 168px; display: grid; place-items: center;
  background: linear-gradient(135deg, #0B2C3D, #1B4D62);
}
/* Reproductor embebido (YouTube/Vimeo) */
.video-embed { position: relative; aspect-ratio: 16 / 9; background: #0B2C3D; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-play {
  width: 58px; height: 58px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255,255,255,.92); color: var(--navy); font-size: 16px; padding-left: 3px;
  transition: .3s;
}
.video-item:hover .video-play { transform: scale(1.08); }
.video-cuerpo { padding: 24px; display: flex; flex-direction: column; gap: 8px; }
.video-categoria {
  align-self: flex-start; font: 800 10px "Manrope"; letter-spacing: .08em; text-transform: uppercase;
  color: var(--teal); background: var(--teal-soft); padding: 5px 10px; border-radius: 999px;
}
.video-cuerpo h3 { font-size: 19px; margin: 2px 0 0; }
.video-cuerpo p { color: var(--muted); font-size: 13px; margin: 0; }
.video-fecha { color: #90A2AA; font-size: 11px; font-weight: 700; margin-top: auto; }

/* Publicaciones */
.papers-section { background: white; }
.papers-filtro { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin: -6px 0 26px; }
.filtro-chip {
  border: 1px solid var(--line); background: white; border-radius: 999px;
  padding: 8px 15px; font-size: 12px; font-weight: 700; color: #52666F; cursor: pointer; transition: .2s;
}
.filtro-chip:hover { border-color: var(--teal); color: var(--teal); }
.filtro-chip.activo { background: var(--navy); border-color: var(--navy); color: white; }
.papers-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.paper-card {
  display: flex; flex-direction: column; gap: 10px; padding: 30px; background: white;
  border: 1px solid var(--line); border-radius: var(--radius); transition: .3s;
}
.paper-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.paper-meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.paper-anio { font: 800 12px "Manrope"; color: white; background: var(--teal); padding: 4px 10px; border-radius: 8px; }
.paper-revista { color: var(--muted); font-size: 12px; font-weight: 600; }
.paper-card h3 { font-size: 20px; margin: 0; }
.paper-autores { color: #52666F; font-size: 12px; font-weight: 600; margin: 0; }
.paper-doi { color: #90A2AA; font-size: 11px; margin: 0; }
.paper-resumen {
  color: var(--muted); font-size: 13px; margin: 0;
  display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden;
}
.paper-link { margin-top: auto; color: var(--teal); font-size: 12px; font-weight: 800; }

/* Productos */
.productos-section { background: var(--soft); }
.productos-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.producto-card {
  display: flex; flex-direction: column; gap: 12px; padding: 32px; background: white;
  border: 1px solid var(--line); border-radius: var(--radius); transition: .3s;
}
.producto-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.producto-imagen { width: 100%; height: 170px; object-fit: cover; border-radius: 18px; }
.producto-card h3 { font-size: 22px; margin: 0; }
.producto-descripcion { color: var(--muted); font-size: 13px; margin: 0; }
.producto-precio { display: flex; align-items: baseline; gap: 6px; margin-top: auto; }
.precio-moneda { color: var(--muted); font-size: 13px; font-weight: 700; }
.producto-precio strong { font: 800 30px/1 "Manrope"; color: var(--navy); }
.producto-cta { margin-top: 6px; }

@media (max-width: 980px) {
  .videos-grid, .productos-grid { grid-template-columns: repeat(2, 1fr); }
  .papers-grid { grid-template-columns: 1fr; }
}

@media (max-width: 780px) {
  .videos-grid, .productos-grid { grid-template-columns: 1fr; }
}

/* ============================================================
   Educación (artículos + videos + preguntas frecuentes)
   ============================================================ */

.education-section { background: white; }
.edu-bloque { margin-top: 46px; }
.edu-bloque-cabecera {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 20px;
}
.edu-bloque-cabecera h3 { font-size: 26px; margin: 0; letter-spacing: -.02em; }
.edu-vacio {
  text-align: center; color: var(--muted); font-size: 13px; padding: 26px;
  border: 1px dashed var(--line); border-radius: var(--radius);
}

/* Contenido destacado */
.edu-destacado-card {
  display: grid; grid-template-columns: 1.05fr .95fr; background: white;
  border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow);
}
.edu-destacado-media { min-height: 320px; background: var(--teal-soft); }
.edu-destacado-imagen { width: 100%; height: 100%; object-fit: cover; display: block; }
.edu-destacado-cuerpo { padding: 38px; display: flex; flex-direction: column; gap: 10px; }
.edu-destacado-cuerpo h3 { font-size: clamp(24px, 2.6vw, 34px); margin: 6px 0 0; }
.edu-destacado-resumen { color: var(--muted); font-size: 15px; margin: 0; }

/* Marcador de imagen (cuando falta la imagen) */
.img-placeholder {
  width: 100%; height: 100%; min-height: 170px; display: grid; place-items: center;
  background: linear-gradient(135deg, #E5F4F2, #F4F8F9);
}
.img-placeholder-marca { font: 800 26px "Manrope"; color: #9CC3C0; letter-spacing: .08em; }

/* Tarjetas de artículo */
.paper-card { padding: 0; overflow: hidden; gap: 0; }
.paper-media { height: 180px; overflow: hidden; }
.paper-imagen { width: 100%; height: 100%; object-fit: cover; display: block; }
.paper-cuerpo { padding: 24px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.paper-fecha { color: #90A2AA; font-size: 11px; font-weight: 700; }
.paper-acciones { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: auto; padding-top: 10px; }

/* Modal de artículo */
.articulo-modal {
  width: min(94vw, 760px); max-height: 88vh; border: 0; padding: 0;
  border-radius: 24px; box-shadow: 0 35px 100px rgba(0, 0, 0, .3);
}
.articulo-modal::backdrop { background: rgba(5, 24, 34, .65); backdrop-filter: blur(5px); }
.articulo-card { padding: 34px; position: relative; overflow-y: auto; max-height: 88vh; }
.articulo-imagen { width: 100%; max-height: 320px; object-fit: cover; border-radius: 18px; margin-bottom: 18px; }
.articulo-card h2 { font-size: clamp(24px, 3vw, 34px); margin: 6px 0 8px; }
.articulo-meta { color: var(--muted); font-size: 12px; margin: 0 0 14px; }
.articulo-contenido p { color: #3B4E58; font-size: 15px; margin: 0 0 12px; }
.articulo-acciones { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 18px; }

/* Video con portada (el iframe se carga al pulsar) */
.video-facade {
  position: absolute; inset: 0; width: 100%; height: 100%; border: 0; padding: 0;
  cursor: pointer; background: #0B2C3D; display: grid; place-items: center;
}
.video-miniatura { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.video-miniatura-vacia { position: absolute; inset: 0; background: linear-gradient(135deg, #0B2C3D, #1B4D62); }
.video-facade .video-play { position: relative; z-index: 1; }
.video-facade:hover .video-play { transform: scale(1.08); }

/* Preguntas frecuentes */
.faq-lista { background: white; border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 26px; }
.faq-entrada { border-bottom: 1px solid var(--line); }
.faq-entrada:last-child { border-bottom: 0; }
.faq-entrada .faq-item { padding: 17px 0; font-size: 14px; }
.faq-entrada .faq-answer p { font-size: 13px; }

@media (max-width: 980px) {
  .edu-destacado-card { grid-template-columns: 1fr; }
  .edu-destacado-media { min-height: 220px; }
}
@media (max-width: 620px) {
  .edu-destacado-cuerpo { padding: 26px; }
  .faq-lista { padding: 6px 18px; }
}

/* ============================================================
   Secciones personalizadas (bloques)
   ============================================================ */

.seccion-custom { background: white; }
#seccionesPersonalizadas > .seccion-custom:nth-child(even) { background: var(--soft); }
.seccion-cabecera { max-width: 820px; margin: 0 auto 26px; text-align: center; }
.seccion-cabecera h2 { font-size: clamp(35px, 4vw, 54px); letter-spacing: -.045em; }
.seccion-descripcion { color: var(--muted); font-size: 16px; }
.seccion-portada { margin: 0 0 28px; border-radius: var(--radius); overflow: hidden; max-height: 420px; box-shadow: var(--shadow); }
.seccion-portada-img { width: 100%; height: 100%; object-fit: cover; display: block; }

.seccion-bloques { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.bloque { background: white; border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; min-width: 0; }
.bloque-texto, .bloque-articulo, .bloque-video { grid-column: 1 / -1; }
.bloque-titulo { font-size: 22px; margin: 0 0 10px; }
.bloque-texto-parrafo { color: #3B4E58; font-size: 15px; margin: 0 0 12px; }
.bloque-texto-parrafo:last-child { margin-bottom: 0; }
.bloque-video .video-embed { border-radius: 18px; overflow: hidden; margin-top: 6px; }

.bloque-imagen { padding: 0; overflow: hidden; }
.bloque-imagen img { width: 100%; height: 100%; min-height: 220px; object-fit: cover; display: block; }
.bloque-imagen figcaption { padding: 14px 18px; color: var(--muted); font-size: 12px; }

.bloque-caracteristicas ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.bloque-caracteristicas li { display: flex; gap: 9px; align-items: flex-start; color: #3B4E58; font-size: 14px; }
.bloque-caracteristicas li::before { content: '✓'; color: var(--teal); font-weight: 800; }

.bloque-precio { display: flex; flex-direction: column; justify-content: center; gap: 6px; }
.bloque-precio .precio { font: 800 34px/1 "Manrope"; color: var(--navy); }
.bloque-precio .precio-moneda { font-size: 15px; color: var(--muted); font-weight: 700; margin-right: 4px; }
.bloque-precio .precio-nota { color: var(--muted); font-size: 12px; }

.bloque-pdf p, .bloque-boton p { color: var(--muted); font-size: 13px; }
.bloque-boton { display: flex; flex-direction: column; justify-content: center; }

@media (max-width: 780px) {
  .seccion-bloques { grid-template-columns: 1fr; }
}
