
:root{
  --blue:#1f4fbf;
  --blue-dark:#163a92;
  --yellow:#ffd84d;
  --soft:#eaf4ff;
  --white:#ffffff;
  --ink:#1f4fbf; /* no black */
  --radius-xl:28px;
  --shadow-soft:0 10px 30px rgba(16, 44, 120, .12);
  --shadow-card:0 8px 18px rgba(16, 44, 120, .10);
}

*{box-sizing:border-box;}
html{scroll-behavior:smooth;}
body{
  margin:0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color:var(--ink);
  background:
    radial-gradient(circle at 10% 10%, rgba(255,216,77,.25), transparent 35%),
    radial-gradient(circle at 90% 20%, rgba(31,79,191,.15), transparent 40%),
    linear-gradient(180deg, #f7fbff 0%, var(--soft) 40%, #f7fbff 100%);
  overflow-x:hidden;
}

/* Decorative floating layer */
.bg-decor{
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:0;
}
.float{
  position:absolute;
  opacity:.22;
  filter: drop-shadow(0 6px 12px rgba(0,0,0,.08));
  animation: drift 18s ease-in-out infinite;
}
.cloud{
  width:220px; height:140px;
  background: url("../img/cloud.svg") no-repeat center/contain;
}
.pencil{
  width:220px; height:80px;
  background: url("../img/pencil.svg") no-repeat center/contain;
  animation-duration:22s;
  opacity:.18;
}
.star{
  width:120px; height:120px;
  background: url("../img/star.svg") no-repeat center/contain;
  animation-duration:16s;
  opacity:.16;
}

.c1{top:8%; left:-40px;}
.c2{top:55%; right:-60px;}
.p1{bottom:12%; left:6%;}
.s1{top:22%; right:14%;}
.s2{bottom:28%; right:30%;}

@keyframes drift{
  0%,100%{transform:translateY(0) translateX(0) rotate(0deg);}
  50%{transform:translateY(-18px) translateX(10px) rotate(1deg);}
}

/* Header */
.hdr{
  position:sticky;
  top:0;
  z-index:20;
  background: linear-gradient(90deg, var(--blue), var(--blue-dark));
  box-shadow:0 6px 18px rgba(0,0,0,.10);
}
.hdr-inner{
  max-width:1200px;
  margin:0 auto;
  padding:10px 18px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:0;
}
.brand{
  display:flex;
  align-items:center;
  gap:10px;
  text-decoration:none;
  color:white;
}
.logo{
  width:44px; height:44px;
  border-radius:14px;
  background: white;
  padding:4px;
  box-shadow: inset 0 0 0 3px rgba(255,216,77,.35);
}
.brand-text{
  font-weight:800;
  letter-spacing:.2px;
  font-size:1.05rem;
  color:#fff6c7;
  text-shadow:0 2px 0 rgba(0,0,0,.08);
}

.menu{
  display:flex;
  align-items:center;
  gap:6px;
}
.menu a{
  color:#f7fbff;
  text-decoration:none;
  font-weight:700;
  font-size:.95rem;
  padding:10px 12px;
  border-radius:14px;
  transition:.2s ease;
}
.menu a:hover{
  background:rgba(255,255,255,.14);
  transform:translateY(-1px);
}
.menu .pill{
  background:rgba(255,216,77,.18);
  border:2px solid rgba(255,216,77,.55);
}

/* Hamburger */
.ham{
  display:none;
  width:44px; height:44px;
  border-radius:14px;
  border:2px solid rgba(255,255,255,.35);
  background:rgba(255,255,255,.08);
  cursor:pointer;
  padding:10px 9px;
}
.ham span{
  display:block;
  height:3px;
  background:white;
  border-radius:3px;
  margin:5px 0;
  transition:.2s ease;
}

/* Hero */
.hero{
  position:relative;
  z-index:1;
  padding:48px 0 0;
  background: transparent;
}
.hero-card{
  max-width:1200px;
  margin:0 auto;
  padding:0 18px 30px;
  display:grid;
  grid-template-columns: 1.15fr .85fr;
  gap:28px;
  align-items:center;
}
.hero-left h1{
  margin:0 0 10px 0;
  font-size: clamp(2rem, 3.6vw, 3rem);
  line-height:1.05;
  font-weight:900;
  color:var(--blue-dark);
  letter-spacing:.2px;
}
.hero-left h1 span{
  color:var(--blue);
}
.hero-left p{
  margin:0 0 18px 0;
  font-size:1.08rem;
  color:var(--blue);
  opacity:.9;
}
.hero-actions{
  display:flex;
  gap:12px;
  flex-wrap:wrap;
  margin-bottom:18px;
}
.hero-badges{
  display:flex;
  gap:8px;
  flex-wrap:wrap;
}
.hero-badges span{
  background:white;
  border:2px dashed rgba(31,79,191,.25);
  color:var(--blue);
  padding:6px 10px;
  border-radius:999px;
  font-size:.85rem;
  font-weight:700;
  box-shadow:var(--shadow-card);
}

.hero-right{
  display:flex;
  flex-direction:column;
  align-items:center;
  gap:14px;
}
.hero-photo-wrap{
  width:min(320px, 80vw);
  aspect-ratio:1/1;
  border-radius:50%;
  padding:10px;
  background:
    radial-gradient(circle at 30% 30%, rgba(255,216,77,.6), transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(31,79,191,.25), transparent 55%),
    white;
  box-shadow: var(--shadow-soft);
}
.hero-photo-wrap img{
  width:100%;
  height:100%;
  object-fit:cover;
  border-radius:50%;
  box-shadow: inset 0 0 0 6px rgba(31,79,191,.08);
}
.hero-bubble{
  background:white;
  border-radius:18px;
  padding:10px 14px;
  text-align:center;
  box-shadow:var(--shadow-card);
  border:2px solid rgba(31,79,191,.08);
}
.hero-bubble strong{
  display:block;
  color:var(--blue-dark);
}
.hero-bubble span{
  color:var(--blue);
  font-weight:600;
  font-size:.95rem;
}

/* Yellow wave under hero */
.hero-wave{
  height:120px;
  background:
    radial-gradient(120px 120px at 10% 0%, var(--yellow) 60%, transparent 61%),
    radial-gradient(140px 140px at 30% 0%, var(--yellow) 60%, transparent 61%),
    radial-gradient(150px 150px at 50% 0%, var(--yellow) 60%, transparent 61%),
    radial-gradient(140px 140px at 70% 0%, var(--yellow) 60%, transparent 61%),
    radial-gradient(120px 120px at 90% 0%, var(--yellow) 60%, transparent 61%),
    linear-gradient(180deg, var(--yellow), var(--yellow));
  border-radius:0 0 60px 60px;
}

/* Sections */
.section{
  position:relative;
  z-index:1;
  padding:44px 0;
}
.section-soft{
  background: linear-gradient(180deg, rgba(255,216,77,.08), rgba(31,79,191,.06));
}
.container{
  max-width:1200px;
  margin:0 auto;
  padding:0 18px;
}
h2{
  margin:0 0 10px 0;
  font-size: clamp(1.6rem, 2.6vw, 2.1rem);
  color:var(--blue-dark);
  font-weight:900;
}
.lead{
  margin:0 0 22px 0;
  color:var(--blue);
  font-weight:600;
  opacity:.9;
}

/* Cards */
.cards{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:14px;
}
.card{
  background:white;
  border-radius: var(--radius-xl);
  padding:20px 18px;
  box-shadow: var(--shadow-card);
  border:2px solid rgba(31,79,191,.06);
}
.card .icon{
  font-size:1.8rem;
}
.card h3{
  margin:10px 0 6px 0;
  color:var(--blue-dark);
}
.card p{
  margin:0;
  color:var(--blue);
}

/* Levels */
.levels{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:14px;
}
.level{
  background:white;
  border-radius: var(--radius-xl);
  padding:22px 18px;
  box-shadow: var(--shadow-card);
}
.badge{
  display:inline-block;
  background: rgba(255,216,77,.35);
  border:2px solid rgba(31,79,191,.15);
  color:var(--blue-dark);
  padding:4px 10px;
  border-radius:999px;
  font-weight:800;
  font-size:.82rem;
}
.level h3{margin:10px 0 6px 0; color:var(--blue-dark);}
.level p{margin:0; color:var(--blue);}

/* Method grid */
.method-grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap:14px;
}
.method{
  background:white;
  border-radius: var(--radius-xl);
  padding:20px 18px;
  box-shadow: var(--shadow-card);
}
.method h3{margin:0 0 6px 0; color:var(--blue-dark);}
.method p{margin:0; color:var(--blue);}

/* Buttons */
.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:8px;
  text-decoration:none;
  font-weight:800;
  border-radius:18px;
  padding:12px 18px;
  transition:.2s ease;
  border:2px solid transparent;
}
.btn-primary{
  background: linear-gradient(90deg, var(--blue), var(--blue-dark));
  color:white;
  box-shadow:0 10px 18px rgba(16,44,120,.18);
}
.btn-primary:hover{transform:translateY(-1px) scale(1.01);}
.btn-secondary{
  background:white;
  color:var(--blue);
  border-color: rgba(31,79,191,.18);
}
.btn-secondary:hover{background: rgba(31,79,191,.06);}
.btn-block{width:100%;}

/* Carousel */
.carousel{
  background:white;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-soft);
  padding:22px 18px 18px;
  position:relative;
  overflow:hidden;
}
.car-viewport{
  overflow:hidden;
}
.car-track{
  display:flex;
  gap:0;
  transition: transform .45s ease;
  will-change: transform;
}
.car-item{
  flex: 0 0 100%;
  margin:0;
}
.car-item img{
  width:100%;
  height: clamp(220px, 36vw, 600px);
  object-fit: cover;
  border-radius: 22px;
  border: 4px solid rgba(31,79,191,.08);
}

.car-btn{
  position:absolute;
  top:50%;
  transform:translateY(-50%);
  width:44px; height:44px;
  border-radius:14px;
  border:2px solid rgba(31,79,191,.12);
  background:white;
  color:var(--blue-dark);
  font-size:1.8rem;
  font-weight:900;
  cursor:pointer;
  box-shadow: var(--shadow-card);
}
.car-btn.prev{left:10px;}
.car-btn.next{right:10px;}

.car-dots{
  display:flex;
  justify-content:center;
  gap:8px;
  margin-top:14px;
}
.dot{
  width:10px; height:10px;
  border-radius:999px;
  border:2px solid rgba(31,79,191,.25);
  background: rgba(31,79,191,.08);
  cursor:pointer;
}
.dot.is-active{
  background: var(--yellow);
  border-color: rgba(31,79,191,.35);
}

/* Form */
.form-wrap{
  display:flex;
  justify-content:center;
}
.fancy-form{
  width:min(720px, 100%);
  background:white;
  border-radius: var(--radius-xl);
  padding:26px 22px;
  box-shadow: var(--shadow-soft);
  border:2px solid rgba(31,79,191,.06);
}
.fancy-form label{
  display:block;
  margin-bottom:14px;
}
.fancy-form span{
  display:block;
  font-weight:800;
  color:var(--blue-dark);
  margin-bottom:6px;
}
.fancy-form input{
  width:100%;
  padding:14px 14px;
  border-radius:14px;
  border:2px solid rgba(31,79,191,.18);
  background: #f8fbff;
  outline:none;
  font-size:1rem;
  color:var(--blue-dark);
  transition:.15s ease;
}
.fancy-form input::placeholder{color: rgba(31,79,191,.55);}
.fancy-form input:focus{
  border-color: var(--blue);
  box-shadow: 0 0 0 4px rgba(31,79,191,.12);
  background:white;
}
.fancy-form .row{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap:12px;
}
.note{
  display:block;
  margin-top:10px;
  color: rgba(31,79,191,.7);
  font-weight:600;
}

/* Contact */
.contact-grid{
  display:grid;
  grid-template-columns: .95fr 1.05fr;
  gap:14px;
  align-items:stretch;
}
.contact-card, .map-card{
  background:white;
  border-radius: var(--radius-xl);
  padding:22px 18px;
  box-shadow: var(--shadow-card);
}
.contact-card h3{
  margin:0 0 10px 0;
  color:var(--blue-dark);
}
.contact-card ul{
  margin:0 0 14px 0;
  padding-left:18px;
  color:var(--blue);
  font-weight:600;
}
.social{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
}
.map-card{padding:0; overflow:hidden;}
.map-card iframe{
  width:100%;
  height:100%;
  min-height:300px;
  border:0;
}

/* Footer */
.ftr{
  background: linear-gradient(90deg, var(--blue), var(--blue-dark));
  color:white;
  padding:18px 0 26px;
  position:relative;
  z-index:1;
}
.ftr-inner{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:14px;
  flex-wrap:wrap;
}
.ftr-brand{
  display:flex;
  align-items:center;
  gap:10px;
  font-weight:800;
  color:#fff6c7;
}
.ftr-brand img{
  width:36px; height:36px;
  border-radius:10px;
  background:white;
  padding:3px;
}
.ftr-text{
  font-weight:600;
  opacity:.95;
}

/* Responsive */
@media (max-width: 1020px){
  .hero-card{grid-template-columns: 1fr; text-align:center;}
  .hero-actions{justify-content:center;}
  .hero-badges{justify-content:center;}
  .cards, .levels, .method-grid{grid-template-columns: 1fr 1fr;}
  .contact-grid{grid-template-columns: 1fr;}
}

@media (max-width: 760px){
  .menu{
    position:absolute;
    right:12px;
    top:64px;
    background:white;
    border-radius:18px;
    padding:10px;
    flex-direction:column;
    align-items:stretch;
    gap:2px;
    min-width: 220px;
    box-shadow: var(--shadow-soft);
    border:2px solid rgba(31,79,191,.08);
    transform-origin: top right;
    transform: scale(.98);
    opacity:0;
    pointer-events:none;
    transition:.18s ease;
  }
  .menu a{
    color:var(--blue-dark);
    padding:10px 12px;
  }
  .menu a:hover{background: rgba(31,79,191,.06);}
  .menu.is-open{
    opacity:1;
    pointer-events:auto;
    transform: scale(1);
  }
  .ham{display:inline-block;}
  .cards, .levels, .method-grid{grid-template-columns: 1fr;}
  .fancy-form .row{grid-template-columns: 1fr;}
  .car-btn{display:none;}
  .brand-text{display:none;}
}

@media (max-width: 420px){
  .hero-photo-wrap{width: min(260px, 85vw);}
}


/* Logo gigante decorativo en Hero */
.hero {
  position: relative;
}

.hero-logo-giant{
  position: absolute;
  left: 10px;
  top: 28px;
  width: 420px;
  max-width: 36vw;
  height: auto;
  z-index: 1;
  pointer-events: none;
  filter: drop-shadow(0 10px 20px rgba(0,0,0,0.08));
  opacity: .40;

}

.hero-card{
  position: relative;
  z-index: 2;
}

@media (max-width: 1600px){
  .hero-logo-giant{
    width: 420px;
    left: -24px;
    top: 28px;
    opacity: .10;
  }
}
@media (max-width: 920px){
  .hero-logo-giant{
    width: 250px;
    left: -24px;
    top: 110px;
    opacity: .40;
  }
}

@media (max-width: 680px){
  .hero-logo-giant{
    display: none;
  }
}

/* =========================
   LIGHTBOX (Galería desde carrusel)
========================= */
.lightbox{
  position: fixed;
  inset:0;
  background: rgba(10, 24, 70, .55);
  backdrop-filter: blur(6px);
  display:flex;
  flex-direction: column;
  align-items:center;
  justify-content:center;
  padding:18px;
  opacity:0;
  pointer-events:none;
  transition:.2s ease;
  z-index:50;
}

.lightbox.is-open{
  opacity:1;
  pointer-events:auto;
}

.lightbox-img{
  max-width:min(980px, 92vw);
  max-height:78vh;
  border-radius: 22px;
  background:white;
  padding:8px;
  box-shadow: var(--shadow-soft, 0 10px 30px rgba(16, 44, 120, .12));
  border: 4px solid rgba(255,216,77,.45);
}

.lightbox-caption{
  margin-top:10px;
  text-align:center;
  font-weight:800;
  color:#fff6c7;
  text-shadow: 0 2px 0 rgba(0,0,0,.12);
}

.lightbox-close{
  position:absolute;
  top:14px;
  right:14px;
  width:46px;
  height:46px;
  border-radius:14px;
  border:2px solid rgba(255,255,255,.35);
  background: rgba(255,255,255,.12);
  color:white;
  font-size:28px;
  font-weight:900;
  cursor:pointer;
}


/* Mensaje de estado del formulario (dentro de la tarjeta) */
.fancy-form .alert{
  margin-bottom: 16px;
  padding: 10px 14px;
  border-radius: 14px;
  font-size: .95rem;
  font-weight: 600;
  box-shadow: var(--shadow-soft);
  border: 2px solid transparent;
}

/* Texto dentro del alert */
.fancy-form .alert strong{
  margin-right: 4px;
}

/* Éxito */
.fancy-form .alert-ok{
  background: #e9f7ff;
  border-color: rgba(31,79,191,.25);
  color: var(--blue-dark);
}

/* Error */
.fancy-form .alert-error{
  background: #ffe9e9;
  border-color: #ff8a8a;
  color: #a12626;
}

/* ===== Banner flotante Matrículas 2026 ===== */

.matriculas-overlay{
  position: fixed;
  inset: 0;
  background: rgba(6, 22, 60, .55);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 80px 16px 20px;
  z-index: 60;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}

.matriculas-overlay.is-visible{
  opacity: 1;
  pointer-events: auto;
}

.matriculas-card{
  width: min(520px, 100%);
  background: radial-gradient(circle at top left, rgba(255,216,77,.25), transparent 55%), #ffffff;
  border-radius: 24px;
  box-shadow: 0 18px 45px rgba(15, 35, 90, .28);
  padding: 22px 22px 20px;
  position: relative;
  border: 2px solid rgba(31,79,191,.14);
}

.matriculas-close{
  position: absolute;
  top: 10px;
  right: 12px;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  border: none;
  background: rgba(31,79,191,.06);
  color: var(--blue-dark);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .15s ease, transform .15s ease;
}
.matriculas-close:hover{
  background: rgba(31,79,191,.12);
  transform: translateY(-1px);
}

.matriculas-pill{
  display: inline-block;
  margin: 4px 0 10px;
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(255,216,77,.32);
  border: 1px solid rgba(31,79,191,.12);
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: .3px;
  color: var(--blue-dark);
  text-transform: uppercase;
}

.matriculas-card h2{
  margin: 0 30px 8px 0;
  font-size: 1.45rem;
  color: var(--blue-dark);
  font-weight: 900;
}

.matriculas-text{
  margin: 0 0 16px 0;
  color: var(--blue);
  font-weight: 500;
  line-height: 1.45;
}

.matriculas-actions{
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.matriculas-btn{
  flex: 1 1 180px;
  justify-content: center;
}

.matriculas-btn-secondary{
  flex: 0 0 auto;
  font-size: .9rem;
  padding-inline: 14px;
}

/* --- Móvil: versión más compacta del banner y botones --- */
@media (max-width: 640px){
  .matriculas-overlay{
    align-items: center;
    padding-top: 40px;
  }

  .matriculas-card{
    padding: 16px 14px 14px;
    border-radius: 20px;
  }

  .matriculas-card h2{
    font-size: 1.18rem;
    line-height: 1.25;
  }

  .matriculas-text{
    font-size: .95rem;
  }

  .matriculas-actions{
    flex-direction: column;
    gap: 8px;
  }

  /* Aquí achicamos los botones del banner en móvil */
  .matriculas-card .btn{
    width: 100%;
    justify-content: center;
    font-size: .95rem;
    padding: 10px 12px;      /* menos alto */
    border-radius: 16px;
  }

  .matriculas-btn-secondary{
    font-size: .95rem;
  }
}

/* Ajuste especial de botones del banner en móvil */
@media (max-width: 640px){

  /* Contenedor de botones en columna y con poco espacio */
  .matriculas-actions{
    flex-direction: column;
    gap: 8px;
  }

  /* Botón azul */
  .matriculas-actions .matriculas-btn{
    flex: 0 0 auto !important;     /* que no se estire */
    width: 100% !important;
    font-size: 0.95rem !important;  /* texto más pequeño */
    padding: 10px 14px !important;  /* menos alto */
    line-height: 1.2 !important;
    border-radius: 16px !important;
  }

  /* Botón "Ahora no" */
  .matriculas-actions .matriculas-btn-secondary{
    flex: 0 0 auto !important;
    width: 100% !important;
    font-size: 0.95rem !important;
    padding: 9px 14px !important;
    line-height: 1.2 !important;
    border-radius: 16px !important;
  }
}


/* Bloquear scroll cuando el banner está abierto */
body.matriculas-open{
  overflow: hidden;
}





