:root {
  --navy: #15215f;
  --deep-blue: #17276f;
  --royal: #3457c4;
  --sky: #9fd0f4;
  --sky-soft: #dff1ff;
  --teal: #57b8bf;
  --ink: #12204b;
  --muted: #5d6684;
  --surface: #ffffff;
  --shadow: 0 18px 45px rgba(18, 32, 75, .14);
  --radius: 28px;
}
* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; font-family: "Public Sans", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; color: var(--ink); background: linear-gradient(180deg, #ffffff 0%, #f3f9ff 55%, #dff1ff 100%); }
body::before, body::after { content: ""; position: fixed; z-index: -1; pointer-events: none; opacity: .95; }
body::before { width: 52vw; height: 28vh; right: -6vw; top: 76px; background: radial-gradient(circle at 30% 50%, rgba(87,184,191,.35), transparent 35%), radial-gradient(circle at 70% 30%, rgba(52,87,196,.28), transparent 40%); filter: blur(18px); border-radius: 999px; }
body::after { width: 42vw; height: 28vh; left: -12vw; bottom: -10vh; background: radial-gradient(circle at 65% 45%, rgba(52,87,196,.38), transparent 38%), radial-gradient(circle at 30% 60%, rgba(159,208,244,.55), transparent 42%); filter: blur(18px); border-radius: 999px; }
.topbar { position: sticky; top: 0; z-index: 100; height: 76px; display: flex; align-items: center; gap: 24px; padding: 0 clamp(18px, 5vw, 72px); background: rgba(21, 33, 95, .96); color: #fff; box-shadow: 0 10px 30px rgba(21,33,95,.2); backdrop-filter: blur(18px); }
.brand { text-decoration: none; color: #fff; margin-right: auto; }
.brand-logos { display: flex; align-items: center; gap: clamp(12px, 1.8vw, 26px); min-width: 0; }
.brand-logo { display: block; width: auto; max-width: 160px; max-height: 34px; object-fit: contain; }
.logo-innovatur { max-height: 38px; }
.logo-bid { max-height: 28px; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav-link { border: 0; border-radius: 999px; background: transparent; color: rgba(255,255,255,.86); padding: 12px 16px; font: inherit; font-weight: 500; cursor: pointer; text-decoration: none; transition: background .2s ease, color .2s ease, transform .2s ease; }
.nav-link:hover, .nav-link.active { background: rgba(159,208,244,.18); color: #fff; transform: translateY(-1px); }
.nav-campus { background: #fff; color: var(--navy); font-weight: 800; box-shadow: 0 6px 18px rgba(0,0,0,.16); }
.nav-campus:hover { background: #fff; color: var(--navy); }
.menu-toggle { display: none; }
#app { position: relative; min-height: calc(100vh - 76px); overflow: hidden; }
.panel { display: none; min-height: calc(100vh - 76px); padding: clamp(28px, 5vw, 72px) clamp(18px, 5vw, 72px); animation: panelIn .55s ease both; }
.panel.active { display: block; }
@keyframes panelIn { from { opacity: 0; transform: translateY(22px) scale(.99); } to { opacity: 1; transform: translateY(0) scale(1); } }
#presentacion.panel { padding: 0; }
.hero { position: relative; width: 100%; min-height: calc(100vh - 76px); overflow: hidden; display: flex; align-items: center; }
.hero-frame { position: absolute; inset: 0; z-index: 1; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.hero-bg-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center; z-index: 0; }
.hero-overlay { position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(21, 33, 95, 0.88) 0%, rgba(21, 33, 95, 0.68) 38%, rgba(21, 33, 95, 0.26) 68%, rgba(21, 33, 95, 0.10) 100%); }
.hero-content { position: relative; z-index: 2; width: min(1120px, 100%); margin: 0 auto; padding: clamp(32px, 6vw, 96px); color: #fff; }
.hero-content h1 { color: #fff; margin: 0 0 18px; font-size: clamp(4rem, 11vw, 10rem); line-height: .88; letter-spacing: -.07em; font-weight: 800; }
.hero-eyebrow { color: var(--sky); margin-bottom: 18px; }
.hero-description { max-width: 760px; color: rgba(255,255,255,.94); font-size: clamp(1.5rem, 4vw, 4.6rem); line-height: 1.02; font-weight: 800; letter-spacing: -.045em; }
.hero-logo-title {
  margin: 0 0 18px;
  line-height: 1;
}

.hero-logo-title img {
  display: block;
  width: min(720px, 82vw);
  height: auto;
}

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

.eyebrow { margin: 0 0 12px; color: var(--royal); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: .78rem; }
h1, h2, h3 { color: var(--navy); line-height: 1.1; }
h2 { margin: 0 0 18px; font-size: clamp(2rem, 4vw, 3.35rem); }
h3 { margin: 0 0 12px; font-size: 1.25rem; }
p { line-height: 1.68; color: var(--muted); font-size: clamp(.98rem, 1.35vw, 1.08rem); }
a { color: var(--royal); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 24px; }
.primary-action, .secondary-action { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; border-radius: 999px; padding: 0 22px; font: inherit; font-weight: 800; text-decoration: none; cursor: pointer; }
.primary-action { border: 0; background: var(--royal); color: #fff; box-shadow: 0 10px 24px rgba(52,87,196,.25); }
.secondary-action { border: 1px solid rgba(21,33,95,.16); background: #fff; color: var(--navy); }
.hero .primary-action { background: #fff; color: var(--navy); }
.hero-secondary { background: rgba(255,255,255,.1); color: #fff; border-color: rgba(255,255,255,.35); backdrop-filter: blur(12px); }
.content-grid { margin: 0; padding: clamp(38px, 6vw, 86px) clamp(18px, 5vw, 72px); display: grid; grid-template-columns: .85fr 1.15fr; gap: 28px; align-items: center; }
.image-card, .material-card, .timeline-card, .info-card, .module-card, .qr-card, .stage-video-card, .footer-card, .footer-info article { background: rgba(255,255,255,.86); border: 1px solid rgba(255,255,255,.78); border-radius: var(--radius); box-shadow: var(--shadow); }
.image-card { padding: 22px; min-height: 380px; display: grid; place-items: center; overflow: hidden; }
.soft-blue { background: linear-gradient(135deg, var(--sky) 0%, #e9f6ff 100%); }
.image-card img, .timeline-card img { width: 100%; height: auto; display: block; }
.timeline-card{padding:clamp(38px, 6vw, 86px) clamp(18px, 5vw, 72px);display: flex;flex-direction: column;}
.material-card { padding: clamp(24px, 4vw, 44px); }
.material-card.wide { margin-top: 30px; }
.section-head { max-width: 980px; margin: 0 auto 36px; text-align: center; }
.video-carousel { position: relative; max-width: 1120px; margin: 0 auto 30px; }
.carousel-track { overflow: hidden; }
.stage-video-card { display: none; grid-template-columns: minmax(320px, 1fr) .8fr; gap: 28px; align-items: center; padding: clamp(18px, 3vw, 32px); background: linear-gradient(135deg, var(--sky) 0%, #edf8ff 100%); }
.stage-video-card.active { display: grid; }
.stage-video-card video { width: 100%; aspect-ratio: 16/9; border: 0; border-radius: 20px; background: #c8d6e8; object-fit: cover; }
.stage-video-card span { color: var(--royal); font-weight: 800; }
.carousel-control { position: absolute; top: 50%; transform: translateY(-50%); width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--navy); color: #fff; font-size: 2rem; cursor: pointer; z-index: 3; box-shadow: var(--shadow); }
.carousel-control.prev { left: -18px; }
.carousel-control.next { right: -18px; }
.qr-card { max-width: 920px; margin: 0 auto; display: grid; grid-template-columns: 1fr 160px; gap: 28px; align-items: center; padding: 28px; }
.qr-card img { width: 160px; height: 160px; object-fit: contain; justify-self: end; background: #fff; border-radius: 18px; }
.cards-row { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.course-summary { margin: 0 auto 34px; max-width: 1220px;}
.flip-card { perspective: 1200px; min-height: 230px; padding: 0 !important; background: transparent; border: 0; box-shadow: none; cursor: pointer; }
.flip-inner { position: relative; width: 100%; height: 100%; min-height: 230px; transform-style: preserve-3d; transition: transform .58s cubic-bezier(.2,.8,.2,1); }
.flip-card:hover .flip-inner, .flip-card:focus .flip-inner, .flip-card.flipped .flip-inner { transform: rotateY(180deg); }
.flip-front, .flip-back { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: center;align-items: center; padding: 28px; border-radius: var(--radius); background: rgba(255,255,255,.92); box-shadow: var(--shadow); border-top: 4px solid var(--teal); backface-visibility: hidden; overflow: hidden; }
.flip-front img { width: 100px; height: 100px; object-fit: contain; margin-bottom: 12px; }
.flip-back { transform: rotateY(180deg); background: var(--navy); }
.flip-back p { color: rgba(255,255,255,.88); margin: 0; }
.card-icon { display: inline-grid; place-items: center; width: 46px; height: 46px; margin-bottom: 14px; border-radius: 50%; color: #fff; background: var(--navy); font-weight: 800; }
.modules-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; max-width: 1220px; margin: 0 auto; padding: 3em 0;}

.module-card{display: flex;flex-direction: column;}
.module-card .flip-front { border-top-color: var(--royal); }
.module-card span { color: var(--royal); font-weight: 800; font-size: 22px;}
.module-card h3 { margin-top: 12px; font-size: 1rem; font-weight: 100;}
.module-card p { margin-bottom: 0; font-weight: 700; margin: 0;}


.full-footer { display: grid; grid-template-columns: .9fr 1.1fr; gap: 30px; padding: clamp(32px, 6vw, 74px) clamp(18px, 5vw, 72px); color: var(--ink); background: linear-gradient(180deg, #344780 0%, #0d1439 100%); }
.site-footer { min-height: auto; }
.footer-card { padding: clamp(24px, 4vw, 44px); }
.footer-info { display: grid; gap: 22px; }
.footer-info article { padding: 32px; background: var(--navy); color: #fff; }
.footer-info h3 { color: #fff; }
.footer-info p { color: rgba(255,255,255,.8); margin: 8px 0; }
.mail-link { display: inline-block; margin: 10px 0 12px; color: var(--royal); font-size: 1.25rem; font-weight: 800; text-decoration: none; }
.notice-modal[hidden] { display: none; }
.notice-backdrop { position: fixed; inset: 0; background: rgba(4,8,28,.72); z-index: 200; }
.notice-card { position: fixed; z-index: 201; inset: 50% auto auto 50%; transform: translate(-50%, -50%); width: min(420px, 90vw); background: #fff; padding: 18px; border-radius: 24px; box-shadow: var(--shadow); }
.notice-card img { width: 100%; border-radius: 18px; }
.notice-close { position: absolute; right: 10px; top: 10px; border: 0; border-radius: 50%; width: 34px; height: 34px; background: var(--navy); color: #fff; font-size: 1.35rem; cursor: pointer; }
@media (max-width: 1180px) { .brand-logo { max-width: 118px; } .nav-link { padding-inline: 11px; } .modules-grid, .cards-row { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px) { .content-grid, .stage-video-card, .full-footer { grid-template-columns: 1fr; } .qr-card { grid-template-columns: 1fr; text-align: center; } .qr-card img { justify-self: center; } }
@media (max-width: 768px) {
  .topbar { height: 64px; min-height: 64px; gap: 12px; padding: 0 16px; }
  .brand-logos { gap: 10px; max-width: calc(100vw - 78px); overflow: hidden; }
  .brand-logo { max-width: 78px; max-height: 28px; }
  .logo-innovatur { max-width: 112px; }
  .menu-toggle { display: flex; align-items: center; justify-content: center; width: 48px; height: 48px; margin-left: auto; border: none; background: transparent; color: #fff; font-size: 32px; cursor: pointer; }
  .nav { position: fixed; top: 64px; right: -100%; width: min(320px, 84vw); height: calc(100vh - 64px); display: flex; flex-direction: column; align-items: stretch; gap: 0; padding: 24px; background: #15215f; transition: right .35s ease; box-shadow: -8px 0 25px rgba(0,0,0,.25); z-index: 999; }
  .nav.open { right: 0; }
  .nav-link { width: 100%; text-align: left; padding: 16px 0; border-radius: 0; border-bottom: 1px solid rgba(255,255,255,.1); color: white; background: transparent; }
  .nav-link.active { background: none; color: #9fd0f4; }
  .nav-campus { color: #fff; box-shadow: none; font-weight: 800; }
  .hero { min-height: calc(100vh - 64px); }
  .hero-description { font-size: clamp(2rem, 10vw, 4rem); }
  .cards-row, .modules-grid { grid-template-columns: 1fr; }
  .carousel-control.prev { left: 4px; }
  .carousel-control.next { right: 4px; }
}


/* Módulos fijos con modal */
.module-trigger {
  position: relative;
  min-height: 260px;
  padding: 30px 24px;
  border-top: 4px solid var(--royal);
  cursor: pointer;
  overflow: hidden;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}

.module-trigger::before {
  content: "";
  position: absolute;
  width: 110px;
  height: 110px;
  border-radius: 50%;
  right: -34px;
  top: -34px;
  background: rgba(159,208,244,.55);
  transition: transform .28s ease;
}

.module-trigger:hover,
.module-trigger:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 22px 55px rgba(18,32,75,.18);
  outline: none;
  border-top-color: var(--teal);
}

.module-trigger:hover::before,
.module-trigger:focus-visible::before {
  transform: scale(1.2);
}

.module-trigger img {
  position: relative;
  z-index: 1;
  width: 92px;
  height: 92px;
  object-fit: contain;
  display: block;
  margin: 0 auto 18px;
}

.module-trigger span,
.module-trigger h3,
.module-trigger p {
  position: relative;
  z-index: 1;
  text-align: center;
}

.module-trigger h3 {
  margin-top: 12px;
  font-size: 1rem;
  font-weight: 600;
}

.module-trigger p {
  margin-bottom: 0;
  font-weight: 700;
}

/* Modal de objetivos por módulo */
body.modal-open {
  overflow: hidden;
}

.module-modal[hidden] {
  display: none;
}

.module-modal {
  position: fixed;
  inset: 0;
  z-index: 300;
  display: grid;
  place-items: center;
  padding: 24px;
}

.module-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4,8,28,.72);
  opacity: 0;
  transition: opacity .18s ease;
}

.module-modal-card {
  position: relative;
  z-index: 1;
  width: min(760px, 94vw);
  max-height: min(82vh, 720px);
  overflow: auto;
  padding: clamp(28px, 5vw, 52px);
  border-radius: 28px;
  background:
    radial-gradient(circle at 96% 0%, rgba(159,208,244,.55), transparent 28%),
    #ffffff;
  box-shadow: 0 26px 80px rgba(4,8,28,.32);
  opacity: 0;
  transform: translateY(18px) scale(.98);
  transition: opacity .18s ease, transform .18s ease;
}

.module-modal.open .module-modal-backdrop {
  opacity: 1;
}

.module-modal.open .module-modal-card {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.module-modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 50%;
  background: var(--navy);
  color: #fff;
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
}

.module-modal-number {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  margin-bottom: 14px;
  padding: 0 16px;
  border-radius: 999px;
  background: var(--sky-soft);
  color: var(--royal);
  font-weight: 800;
}

.module-modal-card h2 {
  margin-bottom: 14px;
}

.module-modal-duration {
  margin: 0 0 26px;
  color: var(--royal);
  font-weight: 800;
}

.module-modal-card h3 {
  color: var(--navy);
  margin-bottom: 8px;
}

.module-modal-objective {
  margin-bottom: 0;
  font-size: clamp(1rem, 1.6vw, 1.18rem);
}

@media (max-width: 768px) {
  .module-trigger {
    min-height: 230px;
  }

  .module-modal {
    padding: 16px;
  }

  .module-modal-card {
    max-height: 84vh;
    border-radius: 22px;
  }
}
