/*
* Diseñado por: Ezequiel Ronaldo Espíritu Apolinar
* Formación: Lic. Animación y arte digital
* Correo: ezequielapolinar512@gmail.com
* Redes: @kabu.studios y @Cheku.exe
* Este código está protegido por derechos de autor
*/

/* styles.css */
/* Animaciones personalizadas */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fadeIn {
    animation: fadeIn 0.8s ease-out forwards;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.floating {
    animation: float 6s ease-in-out infinite;
}

/* Efectos para tarjetas */
.card-hover {
    transition: all 0.3s ease;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.card-hover:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.medal-effect {
    transition: all 0.3s ease;
}

.medal-effect:hover {
    transform: scale(1.05);
    filter: drop-shadow(0 0 12px rgba(216, 72, 132, 0.8));
}

.newspaper-card {
    transition: all 0.3s ease;
}

.newspaper-card:hover {
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
    transform: translateY(-5px);
}

/* Efecto de vidrio para elementos */
.backdrop-blur {
    backdrop-filter: blur(10px);
    background: rgba(255, 255, 255, 0.1);
}

/* Transiciones suaves */
.smooth-transition {
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}

/* Nuevos estilos para el menú lateral semicircular */
.side-menu-container {
    position: fixed;
    right: 20px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.menu-trigger {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #ff6b6b, #ff8e53);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.5);
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.27, 1.55);
    z-index: 10;
    position: relative;
    border: 2px solid rgb(0, 110, 255);
    transform: translateY(-50%);
}

.menu-trigger i {
    font-size: 20px;
    color: white;
    transition: transform 0.4s ease;
}

.menu-items {
    position: relative;
    width: 0;
    height: 0;
    pointer-events: none;
}

.menu-item {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
    background-size: cover;
    background-position: center;
    border: 2px solid white;
    position: absolute;
    top: 0;
    left: 0;
    opacity: 0;
    pointer-events: none;
    z-index: 1;
}

.menu-item i {
    font-size: 18px;
    color: white;
}

/* Colores para cada ítem */
.item-home { background: linear-gradient(45deg, #4facfe, #00f2fe); }
.item-diplomas { background: linear-gradient(45deg, #0ba360, #3cba92); }
.item-recognitions { background: linear-gradient(45deg, #ff9a9e, #fad0c4); }
.item-notes { background: linear-gradient(45deg, #a1c4fd, #c2e9fb); }
.item-videos { background: linear-gradient(45deg, #ff758c, #ff7eb3); }

/* Tooltips */
.menu-item::after {
    content: attr(data-tooltip);
    position: absolute;
    left: -150px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0, 0, 0, 0.85);
    color: rgb(52, 108, 182);
    padding: 6px 12px;
    border-radius: 6px;
    font-size: 13px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.menu-item:hover::after {
    opacity: 1;
}

.click-area {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 5;
    pointer-events: none;
    background: transparent;
}

/* Diseño responsivo */
@media (max-width: 768px) {
    .side-menu-container {
        right: 10px;
    }
    
    .menu-trigger {
        width: 45px;
        height: 45px;
    }
    
    .menu-item {
        width: 40px;
        height: 40px;
    }
    
    .menu-item::after {
        left: -130px;
        font-size: 11px;
        padding: 5px 10px;
    }
}

.menu-item.scale-95 {
    transform: scale(0.95) !important;
}

.swiper {
    width: 100%;
    padding-top: 20px;
    padding-bottom: 40px;
}

.swiper-slide {
    background: rgba(75, 77, 223, 0.812);
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: transform 0.4s ease;
}

.swiper-slide:hover {
    transform: scale(1.05);
}

.swiper-button-next,
.swiper-button-prev {
    color: #4f46e5;
    transition: transform 0.2s ease;
}

.swiper-button-next:hover,
.swiper-button-prev:hover {
    transform: scale(1.2);
}

.notas-masonry {
    column-count: 1;
    column-gap: 1rem;
}

@media (min-width: 768px) {
    .notas-masonry {
        column-count: 2;
    }
}
@media (min-width: 1024px) {
    .notas-masonry {
        column-count: 3;
    }
}

.nota-card {
    display: inline-block;
    margin-bottom: 1rem;
    break-inside: avoid;
    background: rgb(92, 149, 255);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.08);
}

.nota-card:hover {
    transform: scale(1.03);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

.nota-active {
    transform: scale(1.05);
    box-shadow: 0 0 20px 4px rgba(91, 33, 182, 0.3), 0 0 0 2px rgba(91, 33, 182, 0.1);
    z-index: 10;
}

/* Estilos para el footer */
footer {
  margin-top:150px;
  padding: 20px;
  background: linear-gradient(135deg, #5a5280 0%, #443d68 100%);
  color: #fff;
  font-weight: bold;
  position: relative;
  text-align: center;
  width: 100vw; /* Ocupa todo el ancho de la vista */
  left: 50%; /* Centrado horizontal */
  transform: translateX(-50%); /* Compensación para centrado perfecto */
  box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.2);
  margin-bottom: 0;
  position: relative;
  padding-bottom: 50px; /* Espacio para el contador */
  overflow: visible !important;
}

/*h5 texto del footer */
h5 {
    display: block;
    font-size: 0.83em;
    margin-block-start: 1.67em;
    margin-block-end: 1.67em;
    margin-inline-start: 0px;
    margin-inline-end: 0px;
    font-weight: bold;
    unicode-bidi: isolate;
}

h3 {
  font-family: 'CenturyGothicBold', sans-serif;
  margin-top: 5px;
  line-height: 1.6;
  margin-inline-end: auto;
  letter-spacing: 0.5px;
  text-align: center;
}

/* Extender el fondo hasta el borde inferior */
body {
  position: relative;
  padding-bottom: 0;
  overflow-x: hidden; /* Evita barras de desplazamiento horizontales */
}

/* Asegurar que el footer llegue hasta abajo */
html, body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

body > main {
  flex: 1;
}

/* Efecto divisor decorativo */
footer::before {
  content: "";
  position: absolute;
  top: -8px; /* Ajuste para mejor integración */
  left: -20%; /* Extender más allá de los bordes */
  right: -20%; /* Extender más allá de los bordes */
  height: 16px;
  background: linear-gradient(to right, 
    transparent 0%, 
    #f2264f 15%, 
    #6171fb 50%, 
    #79d4f3 85%, 
    transparent 100%);
  border-radius: 50% 50% 0 0;
  z-index: 1;
}

/* Efecto decorativo inferior (nuevo) */
footer::after {
  content: "";
  position: absolute;
  bottom: -8px;
  left: -20vw;
  right: -20vw;
  height: 16px;
  background: linear-gradient(to right, 
    transparent 0%, 
    #79d4f3 15%, 
    #6171fb 50%, 
    #f2264f 85%, 
    transparent 100%);
  z-index: 1;
}

/* Redes sociales con íconos mejorados */
.social {
  margin-top: 50px;
  display: flex;
  gap: 25px;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.social a {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.2rem;
  font-weight: 600;
  color: #fff;
  text-decoration: none;
  background: linear-gradient(135deg, #e591ff, #ff76aa, #ffc874);
  padding: 12px 25px;
  border-radius: 50px;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 4px 15px rgba(255, 73, 255, 0.477);
  position: relative;
  overflow: hidden;
  border: 2px linear-gradient(135deg, #7ab3fd, #ff70b1, #ff4d4d);
}

.social a::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.692), transparent);
  transition: 0.5s;
}

.social a:hover {
  background: linear-gradient(135deg, #ff80ce, #ff87bd);
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 8px 25px rgb(255, 64, 64);
  color: #fff;
}

.social a:hover::before {
  left: 100%;
}

.social img {
  width: 28px;
  height: 28px;
  transition: transform 0.3s ease;
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.54));
}

.social a:hover img {
  transform: scale(1.2) rotate(10deg);
}

/* Animaciones específicas para cada red social */
.social a:nth-child(1) { /*whatsapp */
  background: linear-gradient(135deg, #06e44c, #14d166, #70ea93);
  box-shadow: 0 4px 15px rgba(59, 152, 70, 0.433);
}
.social a:nth-child(1):hover {
  background: linear-gradient(135deg, #25d366, #128c7e);
  box-shadow: 0 8px 25px rgba(59, 152, 70, 0.522);
}
.social a:nth-child(2) { /* Facebook */
  background: linear-gradient(135deg, #3b5998, #368bfa, #78b2fe);
  box-shadow: 0 4px 15px rgba(59, 88, 152, 0.437);
}
.social a:nth-child(2):hover {
  background: linear-gradient(135deg, #1877f2, #3b5998);
  box-shadow: 0 8px 25px rgba(63, 99, 178, 0.59);
}
.social a:nth-child(3) { /* Instagram */
  background: linear-gradient(135deg, #ba52ff, #ff59cd, #ffcb51, #ff5f52, #8352ff);
  background-size: 200% 200%;
  box-shadow: 0 4px 15px rgba(137, 43, 200, 0.493);
  animation: instagramGradient 8s ease infinite;
}
.social a:nth-child(3):hover {
  background: linear-gradient(135deg, #db78ff, #ff8ddb, #ffcc80, #fd8f83, #b88fff);
  box-shadow: 0 8px 25px rgba(59, 89, 152, 0.4);
}

.social a:nth-child(4) { /* YouTube */
  background: linear-gradient(135deg, #ff5959, #c72c2c);
  box-shadow: 0 4px 15px rgba(167, 11, 11, 0.601);
}
.social a:nth-child(4):hover {
  background: linear-gradient(135deg, #cc0000, #ff0000);
  box-shadow: 0 8px 25px rgba(255, 0, 0, 0.4);
}
.social a:nth-child(5) { /* Pinterest */
  background: linear-gradient(135deg, #f40156, #bb002f, #fb2e5a);
  box-shadow: 0 4px 15px rgba(170, 13, 60, 0.597);
}
.social a:nth-child(5):hover {
  background: linear-gradient(135deg, #ff2a6e, #ff1d46, #b9033d);
  box-shadow: 0 8px 25px rgba(229, 17, 102, 0.641);
}
.social a:nth-child(6) { /* Mail */
  background: linear-gradient(135deg, #00eeff, #56a5f0, #88dbff);
  box-shadow: 0 4px 15px rgba(0, 139, 177, 0.693);
}
.social a:nth-child(6):hover {
  background: linear-gradient(135deg, #4298bb, #64d3ff);
  box-shadow: 0 8px 25px rgba(0, 106, 177, 0.4);
}
.social a:nth-child(7) { /* Google Maps */
  background: linear-gradient(135deg, #4285f4, #2eab4f, #fbbc05, #ea4335);
  box-shadow: 0 4px 15px rgba(255, 255, 255, 0.381);
}
.social a:nth-child(7):hover {
  background: linear-gradient(135deg, #34a853, #fbbc05, #f76255, #538ae3);
  box-shadow: 0 8px 25px rgba(255, 255, 255, 0.332);
}

@keyframes instagramGradient {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Efecto de onda al hacer clic */
.social a:active {
  animation: clickWave 0.4s ease-out;
}

@keyframes clickWave {
  0% { transform: translateY(-5px) scale(1.05); }
  50% { transform: translateY(0) scale(0.95); }
  100% { transform: translateY(-5px) scale(1.05); }
}

/* Responsive */
@media (max-width: 768px) {
  .social {
    gap: 15px;
  }
  .social a {
    padding: 10px 20px;
    font-size: 1rem;
  }
  .social img {
    width: 24px;
    height: 24px;
  }
}

/* Diseño responsivo */
@media (max-width: 780px) {
  .carousel {
    gap: 10px;
    padding: 10px;
  }
  .card {
    min-width: 180px;
    height: 250px;
  }
  .social a {
    font-size: 1rem;
    padding: 8px 10px;
  }
  .social img {
    width: 20px;
    height: 20px;
  }
}
/* Redes sociales interactivas renovadas */
.social {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: -25px;
  padding: 10px;
}
.social a {
  border-radius: 15px;
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.4);;
  transition: all 0.3s ease;
}
.social a:hover {
  transform: scale(1.05);
}
.social img {
  width: 24px;
  height: 24px;
}

/* Contenedor principal */
.school-title-container {
  display: flex;
  justify-content: center; /* Centrado horizontal */
  align-items: center;     /* Centrado vertical */
  flex-wrap: wrap;         /* Permite apilamiento en móviles */
  gap: 15px;               /* Espacio entre imágenes */
  margin: 10px 0;
  padding: 10px;
}

/* Logo original */
.school-logo {
  width: 80px;
  height: 90px;
  transition: all 0.3s ease;
  padding: 5px;
  object-fit: contain; /* Mantiene proporciones */
}

/* Efectos hover para el logo */
.school-logo:hover {
  transform: scale(1.2) rotate(5deg);
  filter: brightness(1.1);
}

/* Nueva imagen (reemplazo del título) */
.school-logo-2 {
  height: 90px;          /* Misma altura que el logo */
  width: auto;           /* Ancho proporcional */
  max-width: 400px;      /* Ancho máximo inicial */
  transition: all 0.3s ease;
  padding: 5px;
  object-fit: contain;
  position: relative;
  top: 3px;
  
  /* Ajuste de alineación vertical */
  position: relative;
  top: 3px; /* Compensa diferencia visual de altura */
}

/* Responsive */
@media (max-width: 900px) {
  .school-logo-2 {
    max-width: 350px;
  }
}

@media (max-width: 768px) {
  .school-title-container {
    flex-direction: column; /* Apilamiento vertical */
    gap: 10px;
  }
  
  .school-logo-2 {
    max-width: 300px;
    top: 0; /* Restablece ajuste vertical */
  }
}

@media (max-width: 480px) {
  .school-logo-2 {
    max-width: 250px;
  }
  
  .school-logo {
    width: 70px;
    height: 80px;
  }
}

/* responsive */
@media (max-width: 768px) {
  .school-title-container {
    flex-direction: column;
  }
  
  .school-logo-2 {
    max-width: 250px; 
  }
}

@media (max-width: 480px) {
  .school-logo-2 {
    max-width: 200px;
  }
}

/* ESTILOS PARA CONTADOR MEJORADO */
.visit-counter {
  position: absolute;
  bottom: 15px;
  right: -15px;
  display: flex;
  align-items: center;
  gap: 10px;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(10px);
  border-radius: 30px;
  padding: 5px 5px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3),
              0 0 0 1px rgba(88, 255, 177, 0.995),
              inset 0 0 10px rgba(255, 255, 255, 0.1);
  z-index: 10;
  border: 1px solid rgba(255, 255, 255, 0.15);
  transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
  font-family: 'Segoe UI', sans-serif;
  min-width: 120px;
}

.visit-counter:hover {
  transform: translateY(-3px);
  box-shadow: 0 7px 20px rgba(0, 0, 0, 0.4),
              0 0 0 2px rgba(121, 212, 243, 0.6),
              inset 0 0 15px rgba(255, 255, 255, 0.2);
  background: rgba(0, 0, 0, 0.75);
}

.counter-icon {
  background: linear-gradient(135deg, #61fbb8, #59b182);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  animation: pulseIcon 2.5s ease infinite;
  box-shadow: 0 0 10px rgba(97, 113, 251, 0.5);
}

.counter-icon i {
  font-size: 16px;
  color: white;
}

#visit-container {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
}

#visit-count {
  font-size: 1.2rem;
  font-weight: 700;
  color: white;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  text-shadow: 0 0 5px rgba(255, 255, 255, 0.5);
}

.loading-icon {
  width: 24px;
  height: 24px;
  transition: all 0.3s ease;
}

@keyframes pulseIcon {
  0%, 100% { 
    transform: scale(1); 
    box-shadow: 0 0 10px rgba(97, 113, 251, 0.5);
  }
  50% { 
    transform: scale(1.1); 
    box-shadow: 0 0 15px rgba(97, 113, 251, 0.8);
  }
}

/* Efecto de brillo al completar */
@keyframes countComplete {
  0% { text-shadow: 0 0 5px rgba(247, 247, 247, 0.7); }
  50% { text-shadow: 0 0 15px rgb(72, 157, 255); }
  100% { text-shadow: 0 0 5px rgba(183, 183, 183, 0.873); }
}

/* Fondo de video */
.video-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: -1;
    overflow: hidden;
}
.video-background video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.video-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4); /* Oscurece ligeramente el video */
}

/* Menú lateral con fondo translúcido y sombreado */
.side-menu {
    position: fixed;
    top: 50%;
    left: 20px;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 999;
    background: rgba(255, 255, 255, 0.15);
    padding: 20px 15px;
    border-radius: 16px;
    backdrop-filter: blur(10px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
}
.side-menu a {
    color: #fff;
    font-weight: 600;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 15px;
    border-radius: 8px;
    transition: background 0.3s, transform 0.2s;
    background-color: rgba(0, 0, 0, 0.2);
}
.side-menu a:hover {
    background-color: #f0b429;
    color: #000;
    transform: translateX(5px);
}
.side-menu i {
    font-size: 1rem;
}

/* Imágenes y videos siempre adaptables */
img, video, iframe {
  max-width: 100%;
  height: auto;
}

/* Contenedores flexibles */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* Títulos adaptativos */
h1 { font-size: clamp(1.8rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.2rem, 3vw, 2rem); }

/* Footer adaptativo */
footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 15px;
  padding: 20px;
  text-align: center;
}

/* Ajustes extra para móviles */
@media (max-width: 480px) {
  .side-menu a {
    width: 45px;
    height: 45px;
    font-size: 1.2rem;
  }
  .diploma-card {
    height: auto;
  }
}

#modal-image {
  transition: transform 0.25s ease-out;
  cursor: grab;
}
#modal-image:active {
  cursor: grabbing;
}

body.modal-open {
  overflow: hidden;
  position: fixed;
  width: 100%;
}

/* Ajustar tamaño de las tarjetas dentro del carrusel */
.mySwiper {
  padding-bottom: 50px; /* espacio para la paginación */
}

.mySwiper .swiper-slide {
  width: auto; 
  max-width: 350px; 
}

.mySwiper .swiper-wrapper {
  gap: 20px; /* separación entre cards */
}

/* Botones personalizados abajo */
.mySwiper .swiper-button-next,
.mySwiper .swiper-button-prev {
  position: static !important; /* ya no flotan al centro */
  color: white !important;
  font-size: 18px !important;
  transition: background 0.3s ease;
}

.mySwiper .swiper-button-next:hover,
.mySwiper .swiper-button-prev:hover {
  background: rgba(255, 255, 255, 0.3);
}

/* Botones de navegación dentro del modal */
#detail-modal .modal-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(50%);
  width: 50px;
  height: 50px;
  border-radius: 9999px;
  background: rgba(104, 57, 233, 0.45);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 60;
  font-size: 25px;
  cursor: pointer;
  transition: background .15s ease;
}
#detail-modal .modal-nav-btn:hover {
  background: rgba(183, 19, 63, 0.766);
}
#detail-modal #modal-prev { left: 25px; }
#detail-modal #modal-next { right: 25px; }

/* Ocultar flechas en pantallas muy pequeñas */
@media (max-width: 640px) {
  #detail-modal .modal-nav-btn { display: none; }
}
