/* RESET */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', sans-serif;
}

html {
    scroll-behavior: smooth;
}


body {
    padding-top: 80px;
}

/* HEADER */
.header {
    position: fixed;
    top: 0;
    width: 100%;
    background: #0d5c82;
    z-index: 1000;
}

.container-header {
    max-width: 1200px;
    margin: auto;
    padding: 18px 25px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* LOGO */
.logo img {
    height: 68px;
    max-width: 100%;
    transition: transform 0.3s ease;
}

/* pequeño efecto sutil */
.logo img:hover {
    transform: scale(1.03);
}


/* MENÚ */


.nav ul {
    display: flex;
    list-style: none;
    gap: 10px;
}

.nav ul li a {
    position: relative;
    padding: 10px 14px;
    text-decoration: none;
    color: #e9f6fb;
    font-weight: 500;
    border-radius: 6px;
    transition: all 0.3s ease;
}

/* EFECTO HOVER */
.nav ul li a::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 2px;
    width: 0%;
    height: 3px;
    background: #ffffff;
    border-radius: 2px;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}


.nav ul li a:hover {
    background: #00bcd4;
    color: #ffffff;
}

.nav ul li a:hover::after {
    width: 80%;
}


/* BOTÓN AULA */
.btn-aula {
    background: #ff8000;
    color: #ffffff !important;
    font-weight: 600;
}

.btn-aula:hover {
    background: #009fb3;
}

/* BOTÓN HAMBURGUESA */
.menu-toggle {
    display: none;
    font-size: 28px;
    color: #ffffff;
    cursor: pointer;
}

/* RESPONSIVE */
@media (max-width: 768px) {

    body {
        padding-top: 80px;
    }

    .nav {
        position: absolute;
        top: 80px;
        left: 0;
        width: 100%;
        background: #0d5c82;
        display: none;
        flex-direction: column;
        box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    }

    .nav ul {
        flex-direction: column;
        padding: 20px;
        gap: 12px;
    }

    .menu-toggle {
        display: block;
    }

    .nav.active {
        display: flex;
    }
}


/* =========================
   HERO SLIDER
========================= */

.hero-slider {
    width: 100%;
    height: 75vh;
    min-height: 480px;
    position: relative;
    overflow: hidden;
}

/* Contenedor */
.slider {
    width: 100%;
    height: 100%;
    position: relative;
}

/* Slides */
.slide {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transform: scale(1.05);
    transition: opacity 1s ease, transform 1s ease;
}

.slide.active {
    opacity: 1;
    transform: scale(1);
    z-index: 1;
}

/* Overlay elegante */
.slide::before {
    content: '';
    position: absolute;
    inset: 0;
    
}

/* Contenido */
.slide-content {
    position: relative;
    z-index: 2;
    max-width: 600px;
    padding: 80px 40px;
    color: #000;
}

.slide-content h1 {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
}

.slide-content h1 span {
    color: #00c6d7;
}

.slide-content p {
    margin: 20px 0 30px;
    font-size: 17px;
    opacity: 0.95;
}

/* Botones */
.buttons {
    display: flex;
    gap: 15px;
}

.btn {
    padding: 12px 26px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 600;
}

.btn-primary {
    background: #f6b21a;
    color: #fff;
}

.btn-secondary {
    background: #00c6d7;
    color: #fff;
}

/* Ajuste fino del fondo del slider */
.slide {
    background-size: contain;
    background-repeat: no-repeat;
    background-position: right center;
}

/* En pantallas grandes */
@media (min-width: 1024px) {
    .slide {
        background-size: 55%;
    }
}

/* En tablets */
@media (max-width: 1023px) {
    .slide {
        background-size: 65%;
        background-position: right bottom;
    }
}

/* En móviles */
@media (max-width: 768px) {
    .slide {
        background-size: 80%;
        background-position: center bottom;
    }

    .slide-content {
        padding: 60px 25px;
        text-align: center;
    }

    .buttons {
        justify-content: center;
        flex-wrap: wrap;
    }
}


/* ===== SECCIÓN NOSOTROS ===== */
.nosotros {
    padding: 80px 8%;
    background-color: #ffffff;
}

.nosotros-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 50px;
}

.nosotros-texto {
    flex: 1;
}

.nosotros-texto h2 {
    font-size: 36px;
    color: #0d5c82;
    margin-bottom: 20px;
}

.nosotros-texto p {
    font-size: 16px;
    line-height: 1.7;
    color: #444;
    margin-bottom: 15px;
}

.nosotros-imagen {
    flex: 1;
    text-align: right;
}

.nosotros-imagen img {
    width: 100%;
    max-width: 420px;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.1);
}

/* ===== RESPONSIVE ===== */
@media (max-width: 900px) {
    .nosotros-container {
        flex-direction: column;
        text-align: center;
    }

    .nosotros-imagen {
        text-align: center;
    }

    .nosotros-texto h2 {
        font-size: 30px;
    }
}

/* ===== AJUSTES SLIDER EN MÓVIL ===== */
@media (max-width: 768px) {

    .slide {
        background-size: 85%;
        background-position: center bottom;
        padding-top: 0px;
        padding-bottom: 180px;
    }

    .slide-content {
        position: relative;
        z-index: 2;
        max-width: 100%;
        text-align: center;
    }

    .slide-content h1,
    .slide-content p {
        background: rgba(13, 92, 130, 0.75);
        padding: 15px 15px;
        border-radius: 8px;
        display: inline-block;
        margin-bottom: 12px;
    }
}


/* ===== CURSOS FLIP ===== */
.section-title{
    font-size: 36px;
    color: #0d5c82;
    margin-bottom: 20px;
}
.cursos-flip {
    padding: 80px 8%;
    background: #ffffff;
    text-align: center;
}

.flip-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    margin-top: 50px;
}

.flip-card {
    perspective: 1200px;
}

.flip-inner {
    position: relative;
    width: 100%;
    height: 280px;
    transform-style: preserve-3d;
    transition: transform 0.7s ease;
    cursor: pointer;
}

.flip-card.active .flip-inner {
    transform: rotateY(180deg);
}

/* Frente */
.flip-front,
.flip-back {
    position: absolute;
    width: 100%;
    height: 100%;
    border-radius: 16px;
    backface-visibility: hidden;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.flip-front {
    background: #ffffff;
    color: #000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border: 1px solid #ccc;
}

.flip-front img {
    width: 50%;
    height: 150px;
    object-fit: cover;
    border-radius: 16px 16px 0 0;
}

.flip-front h3 {
    padding: 15px;
    font-size: 20px;
}

/* Reverso */
.flip-back {
    background: #ff8000;
    transform: rotateY(180deg);
    padding: 25px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.flip-back img {
    width: 90px;
    margin-bottom: 15px;
}

.flip-back p {
    font-size: 15px;
    color: #000;
    margin-bottom: 20px;
}

.btn-curso {
    background: #00bcd4;
    color: #fff;
    padding: 10px 22px;
    border-radius: 25px;
    text-decoration: none;
    font-size: 14px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 1200px) {
    .flip-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .flip-container {
        grid-template-columns: 1fr;
    }
}

/* ===== FLIP AL PASAR EL MOUSE (DESKTOP) ===== */
@media (hover: hover) and (pointer: fine) {
    .flip-card:hover .flip-inner {
        transform: rotateY(180deg);
    }
}

/* ===== FLIP AL HACER CLICK (MÓVIL) ===== */
.flip-card.active .flip-inner {
    transform: rotateY(180deg);
}


/* ===== HOVER BOTÓN CURSO ===== */
.btn-curso {
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-curso:hover {
    background: #0d5c82;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(13, 92, 130, 0.4);
}

.btn-curso::after {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255,255,255,0.25);
    transition: left 0.3s ease;
}

.btn-curso:hover::after {
    left: 100%;
}


/* Sección de OPINIONES */

.opiniones {
  padding: 60px 20px;
  background-color: #f1f6f5;
  text-align: center;
}

.opiniones h2 {
  color: #0d5c82;
  font-size: 2rem;
  margin-bottom: 40px;
}

.opiniones-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px;
  justify-items: center;
}

.opinion-card-vertical {
  background-color: white;
  border: 1px solid #ddd;
  border-radius: 12px;
  padding: 20px;
  max-width: 280px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
  transition: transform 0.3s ease;
}

.opinion-card-vertical:hover {
  transform: translateY(-35px);
}

.opinion-card-vertical img {
  width: 100px;
  height: 100px;
  object-fit: cover;
  border-radius: 50%;
  border: 3px solid #7cb7cc;
  margin-bottom: 15px;
}

.opinion-card-vertical h3 {
  margin-bottom: 10px;
  font-size: 1.1rem;
  color: #2b2b29;
}

.opinion-card-vertical p {
  font-size: 0.95rem;
  color: #57737e;
  line-height: 1.4;
}

/* SECCIÓN DE ESTADÍSTICAS */

.estadisticas {
  background-color: #0d5c82;
  color: #f1f6f5;
  padding: 60px 20px;
  text-align: center;
}

.estadisticas h2 {
  font-size: 2rem;
  margin-bottom: 40px;
  color: #ec7c1c;
}

.estadisticas-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 30px;
  justify-items: center;
}

.estadistica-card {
  background-color: #1d4452;
  padding: 30px 20px;
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  width: 100%;
  max-width: 220px;
}

.estadistica-card:hover {
  transform: translateY(-8px);
  box-shadow: 0 6px 14px rgba(0,0,0,0.25);
}

.estadistica-card h3 {
  font-size: 2.5rem;
  margin-bottom: 10px;
  color: #7cb7cc;
}

.estadistica-card p {
  font-size: 1rem;
  color: #f1f6f5;
}


/* SECCIÓN DE FORMULARIO */

.contacto {
  padding: 60px 20px;
  background-color: #f1f6f5;
  color: #2b2b29;
  text-align: center;
}

.contacto h2 {
  font-size: 2rem;
  margin-bottom: 40px;
  color: #0d5c82;
}

.formulario-contacto {
  max-width: 600px;
  margin: 0 auto;
  background-color: #ffffff;
  padding: 30px;
  border-radius: 12px;
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.campo {
  display: flex;
  flex-direction: column;
  margin-bottom: 20px;
  text-align: left;
}

.campo label {
  margin-bottom: 8px;
  color: #1d4452;
  font-weight: 600;
}

.campo input,
.campo textarea {
  padding: 12px;
  border: 1px solid #ccc;
  border-radius: 8px;
  font-size: 1rem;
  outline: none;
  transition: border 0.3s ease;
}

.campo input:focus,
.campo textarea:focus {
  border-color: #0d5c82;
}

.btn-enviar {
  background-color: #0d5c82;
  color: #f1f6f5;
  border: none;
  padding: 12px 25px;
  font-size: 1rem;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.btn-enviar:hover {
  background-color: #1d4452;
  transform: scale(1.05);
}


/* ===== FOOTER ===== */
.footer {
    background: #0d5c82;
    color: #fff;
    padding: 50px 8% 20px;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px;
    align-items: center;
}

.footer-logo img {
    max-width: 180px;
}

.footer-info h4,
.footer-links h4 {
    margin-bottom: 15px;
    font-size: 18px;
    color: #00bcd4;
}

.footer-info p {
    font-size: 14px;
    line-height: 1.6;
    color: #e0f4fb;
}

.footer-links ul {
    list-style: none;
    padding: 0;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: #e0f4fb;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #ffffff;
}

/* Derechos */
.footer-copy {
    margin-top: 40px;
    text-align: center;
    font-size: 13px;
    color: #cdebf5;
    border-top: 1px solid rgba(255,255,255,0.2);
    padding-top: 15px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-info,
    .footer-links {
        display: none;
    }

    .footer-logo img {
        margin: 0 auto;
    }
}

