:root {
  --base-color: white;
  --primary-color: #24c34c;
  --secondary-color: #f2c331;
  --terciary-color: #487de0;
  --base-font: #4a494a;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Arial", sans-serif;
  line-height: 1.6;
  color: var(--base-font);
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* Header y Navegación */
header {
  background: white;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
  transition: transform 0.3s ease;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.hamburger {
  display: none; /* Oculto por defecto */
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
  color: var(--primary-color);
}

.hamburger svg {
  width: 24px;
  height: 24px;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2rem;
}

.nav-links a {
  text-decoration: none;
  color: var(--primary-color);
  font-weight: bold;
  transition: color 0.3s;
}

.nav-links a:hover {
  color: var(--terciary-color);
}

.logo img {
  max-width: 60px; /* Ajusta el tamaño del logo */
  height: auto; /* Mantén la proporción de la imagen */
}

/* Hero Section */
.hero {
  height: 80vh;
  background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
    url(assets/alumnos.jpg);
  background-size: cover;
  background-position: center;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: white;
  padding-top: 60px;
  background-attachment: fixed;
  position: relative;
}

.hero-content h1 {
  font-size: 3.5rem;
  margin-bottom: 1rem;
}

.hero-content p {
  font-size: 1.5rem;
  margin-bottom: 2rem;
}

.cta-button {
  display: inline-block;
  padding: 1rem 2rem;
  background: var(--secondary-color);
  color: var(--base-font);
  text-decoration: none;
  border-radius: 5px;
  font-weight: bold;
  transition: transform 0.3s;
}

.cta-button:hover {
  transform: scale(1.05);
}

/* Secciones */
.section {
  padding: 5rem 0;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
  position: relative;
  overflow: hidden;
}

.section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 100px;
  background: linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.1) 0%,
    transparent 100%
  );
  pointer-events: none;
  z-index: 1;
}

.section::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 100px;
  background: linear-gradient(
    to top,
    rgba(255, 255, 255, 0.1) 0%,
    transparent 100%
  );
  pointer-events: none;
  z-index: 1;
}

.blue::before,
.blue::after {
  background: linear-gradient(
    to bottom,
    rgba(0, 73, 133, 0.2) 0%,
    transparent 100%
  );
}

.section h2 {
  text-align: center;
  margin-bottom: 3rem;
  /* color: var(--primary-color); */
  position: relative;
  display: block;
  width: 100%;
}

.section h2::after {
  content: "";
  position: absolute;
  bottom: -10px;
  left: 50%;
  width: 0;
  height: 3px;
  background: var(--secondary-color);
  transition: all 0.6s ease-out;
  transform: translateX(-50%);
}

.section.visible h2::after {
  width: 100px;
}

.blue {
  background-color: var(--primary-color);
  color: var(--base-color);
}

.blue h2 {
  color: var(--base-color);
}

/* Features */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
  perspective: 1000px;
}

.feature {
  text-align: center;
  padding: 2rem;
  border-radius: 10px;
  background: white;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  opacity: 0;
  transform: rotateX(-20deg);
  transition: all 0.6s ease-out;
  transition-delay: calc(var(--delay) * 0.2s);
}

.section.visible .feature {
  opacity: 1;
  transform: rotateX(0);
}

.feature svg {
  width: 64px;
  height: 64px;
  margin-bottom: 1rem;
}

.feature .feature-icon {
  margin-bottom: 1.5rem;
  transition: transform 0.3s ease;
}

.feature:hover .feature-icon {
  transform: scale(1.1);
}

/* Orientaciones */
.orientaciones {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  perspective: 1000px;
}

.orientacion {
  background: rgba(255, 255, 255, 0.1);
  padding: 2rem;
  border-radius: 10px;
  text-align: center;
  opacity: 0;
  transform: rotateY(-20deg);
  transition: all 0.6s ease-out;
  transition-delay: calc(var(--delay) * 0.2s);
}

.section.visible .orientacion {
  opacity: 1;
  transform: rotateY(0);
}

.orientacion ul {
  list-style: none;
  margin-top: 1rem;
}

/* Noticias Carousel */
.news-carousel {
  display: flex;
  overflow-x: auto;
  scroll-behavior: smooth;
  padding: 2rem 0;
  gap: 2rem;
}

.news-card {
  min-width: 300px;
  background: white;
  border-radius: 10px;
  padding: 1.5rem;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
  opacity: 0;
  transform: translateX(30px);
  transition: all 0.6s ease-out;
  transition-delay: calc(var(--delay) * 0.2s);
}

.section.visible .news-card {
  opacity: 1;
  transform: translateX(0);
}

/* Contacto */
.contact-info {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
}

.contact-form form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-form input,
.contact-form textarea {
  padding: 0.8rem;
  border: 1px solid #ddd;
  border-radius: 5px;
}

.submit-button {
  background: var(--primary-color);
  color: var(--base-color);
  padding: 1rem;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.submit-button:hover {
  background-color: var(--secondary-color);
}

/* Footer */
footer {
  background: var(--primary-color);
  color: var(--base-color);
  padding: 3rem 0 1rem;
}

.footer-content {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.footer-section h4 {
  margin-bottom: 1rem;
}

.footer-section ul {
  list-style: none;
}

.footer-section a {
  color: var(--base-color);
  text-decoration: none;
  transition: color 0.3s;
}

.footer-section a:hover {
  color: var(--terciary-color);
}

.social-links {
  display: flex;
  gap: 1rem;
}

.footer-bottom {
  text-align: center;
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Nueva sección de Aniversario */
.anniversary-section {
  background: linear-gradient(
    135deg,
    var(--primary-color) 0%,
    var(--secondary-color) 100%
  );
  color: var(--base-color);
  overflow: hidden;
}

.anniversary-content {
  display: flex;
  align-items: center;
  gap: 4rem;
  padding: 2rem 0;
}

.anniversary-number {
  position: relative;
  min-width: 300px;
  text-align: center;
}

.number {
  font-size: 12rem;
  font-weight: bold;
  color: var(--terciary-color);
  line-height: 1;
  text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
  opacity: 0;
  transform: scale(0.5);
  transition: all 1s ease-out;
}

.section.visible .number {
  opacity: 1;
  transform: scale(1);
}

.years {
  font-size: 3rem;
  display: block;
  color: var(--base-color);
  opacity: 0;
  transform: translateY(20px);
  transition: all 1s ease-out 0.5s;
}

.section.visible .years {
  opacity: 1;
  transform: translateY(0);
}

.anniversary-text {
  flex: 1;
}

.anniversary-text p {
  font-size: 1.2rem;
  margin-bottom: 2rem;
  opacity: 0;
  transform: translateX(30px);
  transition: all 1s ease-out 0.3s;
}

.section.visible .anniversary-text p {
  opacity: 1;
  transform: translateX(0);
}

.timeline {
  display: flex;
  justify-content: space-between;
  position: relative;
  padding-top: 30px;
}

.timeline::before {
  content: "";
  position: absolute;
  top: 45px;
  left: 0;
  right: 0;
  height: 2px;
  background: var(--terciary-color);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 1.5s ease-out 0.5s;
  margin-top: 15px; /*agregado por mi*/
}

.section.visible .timeline::before {
  transform: scaleX(1);
}

.milestone {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.8s ease-out;
}

.section.visible .milestone {
  opacity: 1;
  transform: translateY(0);
}

.milestone::before {
  content: "";
  width: 12px;
  height: 12px;
  background: var(--terciary-color);
  border-radius: 50%;
  position: absolute;
  top: 15px;
  margin-top: 5px; /*agregado por mi*/
}

.year {
  font-weight: bold;
  color: var(--terciary-color);
  margin-bottom: 0.5rem;
}

.event {
  font-size: 0.9rem;
  text-align: center;
  max-width: 100px;
}

/* Estilos para la sección Cooperativa */
.organigrama {
  margin: 2rem 0;
  padding: 2rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 15px;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
  overflow: visible;
}

.org-chart {
  width: 100%;
  max-width: 1000px;
  margin: 0 auto;
  overflow: visible;
  padding-bottom: 2rem;
}

.org-line {
  stroke: var(--primary-color);
  stroke-width: 2;
  fill: none;
}

.org-node circle {
  fill: white;
  stroke: var(--primary-color);
  stroke-width: 2;
}

.org-node text {
  font-size: 10px;
  fill: var(--primary-color);
  font-weight: bold;
}

.section.visible .organigrama {
  opacity: 1;
  transform: translateY(0);
}

.members-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  margin-top: 4rem;
}

.member-card {
  background: white;
  border-radius: 15px;
  padding: 2rem;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
  transition-delay: calc(var(--delay) * 0.2s);
}

.section.visible .member-card {
  opacity: 1;
  transform: translateY(0);
}

.member-card:hover {
  transform: translateY(-5px);
}

.member-photo {
  width: 150px;
  height: 150px;
  margin: 0 auto 1.5rem;
  margin-bottom: 20%;
}

.placeholder-avatar {
  width: 100%;
  height: 100%;
}

.placeholder-avatar .head {
  fill: var(--primary-color);
}

.placeholder-avatar .body {
  fill: var(--secondary-color);
}

.member-card h3 {
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

.member-card h4 {
  color: var(--secondary-color);
  margin-bottom: 1rem;
  font-weight: normal;
}

.member-card p {
  font-size: 0.9rem;
  color: var(--base-font);
  line-height: 1.6;
}

/* Estilos para la sección de Enlaces de interés */
.links-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  margin-top: 2rem;
}

.link-card {
  background: white;
  border-radius: 15px;
  padding: 2rem;
  text-align: center;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(30px);
}

.section.visible .link-card {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.6s ease-out;
  transition-delay: calc(var(--delay) * 0.2s);
}

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

.link-icon {
  margin-bottom: 1.5rem;
}

.link-card h3 {
  color: var(--primary-color);
  margin-bottom: 1rem;
}

.link-card p {
  color: var(--base-font);
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
}

.link-button {
  display: inline-block;
  padding: 0.8rem 2rem;
  background: var(--primary-color);
  color: var(--base-color);
  text-decoration: none;
  border-radius: 25px;
  font-weight: bold;
  transition: all 0.3s ease;
}

.link-button:hover {
  background: var(--secondary-color);
  transform: scale(1.05);
}

/* School image in academic section */
.school-image-container {
  width: 100%;
  max-width: 800px;
  margin: 4rem auto 2rem;
  padding: 0 20px;
}

.school-image {
  width: 100%;
  height: auto;
  border-radius: 15px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

.school-image:hover {
  transform: scale(1.02);
}

/* Floating back to top button */
.back-to-top {
  position: fixed;
  bottom: 30px;
  right: -60px;
  width: 50px;
  height: 50px;
  background: var(--primary-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease-in-out;
  opacity: 0;
  z-index: 1000;
  border: none;
}

.back-to-top.visible {
  right: 30px;
  opacity: 1;
}

.back-to-top:hover {
  background: var(--secondary-color);
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.back-to-top svg {
  width: 24px;
  height: 24px;
  fill: var(--base-color);
  animation: bounce 2s infinite;
}

@keyframes bounce {
  0%,
  20%,
  50%,
  80%,
  100% {
    transform: translateY(0);
  }
  40% {
    transform: translateY(-5px);
  }
  60% {
    transform: translateY(-3px);
  }
}

/**************************** Events Grid con el lightbox agregado nuevo hecho en websim**********************************/
.events-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  padding: 2rem 0;
}

.event-card {
  background: white;
  border-radius: 15px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  opacity: 0;
  transform: translateY(30px);
}

.section.visible .event-card {
  opacity: 1;
  transform: translateY(0);
  transition: all 0.6s ease-out;
  transition-delay: calc(var(--delay) * 0.2s);
}

.event-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.event-image {
  width: 100%;
  height: 200px;
  overflow: hidden;
}

.event-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s ease;
  cursor: pointer;
}

.event-card:hover .event-img {
  transform: scale(1.1);
}

.event-card h3 {
  color: var(--primary-color);
  padding: 1.5rem 1.5rem 0.5rem;
  margin: 0;
}

.event-card p {
  padding: 0 1.5rem;
  color: var(--base-font);
  font-size: 0.9rem;
  line-height: 1.6;
}

.event-date {
  display: block;
  padding: 0.5rem 1.5rem 1.5rem;
  color: var(--secondary-color);
  font-weight: bold;
}

/* Lightbox styles */
.lightbox {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  z-index: 1100;
  justify-content: center;
  align-items: center;
}

.lightbox.active {
  display: flex;
}

.lightbox-img {
  max-width: 90%;
  max-height: 90vh;
  border-radius: 5px;
}

.close-lightbox {
  position: absolute;
  top: 20px;
  right: 30px;
  color: white;
  font-size: 40px;
  cursor: pointer;
  transition: transform 0.3s ease;
}

.close-lightbox:hover {
  transform: rotate(90deg);
}
/**************************** Fin del Events Grid con el lightbox agregado nuevo hecho en websim**********************************/

/*agregado .message resize none por mi*/
.message {
  resize: none;
}

/* Responsive */
@media (max-width: 1200px) {
  .container {
    width: 95%;
    padding: 0 15px;
  }
}

@media (max-width: 991px) {
  .hamburger {
    display: block; /* Mostrar solo en tablets y móviles */
    z-index: 1000;
  }

  .nav-links {
    display: none;
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background: white;
    flex-direction: column;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  }

  .nav-links.active {
    display: flex;
  }

  .features,
  .orientaciones,
  .members-grid,
  .links-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-info {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .anniversary-content {
    padding: 1rem;
  }
}

@media (max-width: 768px) {
  .nav-links {
    display: none;
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    background: white;
    flex-direction: column;
    padding: 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  }

  .nav-links.active {
    display: flex;
  }

  .hero-content h1 {
    font-size: 2rem;
  }

  .hero-content p {
    font-size: 1.1rem;
  }

  .features,
  .orientaciones,
  .members-grid,
  .links-grid {
    grid-template-columns: 1fr;
  }

  .anniversary-content {
    flex-direction: column;
    text-align: center;
    gap: 2rem;
  }

  .number {
    font-size: 8rem;
  }

  .years {
    font-size: 2rem;
  }

  .org-chart {
    transform: scale(0.8);
    transform-origin: top center;
  }

  .timeline {
    flex-direction: column;
    align-items: flex-start;
    padding: 20px;
    margin: 20px;
  }

  .milestone {
    width: 100%;
    margin-bottom: 1rem;
  }

  .back-to-top {
    bottom: 20px;
  }

  .back-to-top.visible {
    right: 20px;
  }
}

@media (max-width: 480px) {
  .section {
    padding: 3rem 0;
  }

  .hero-content h1 {
    font-size: 1.8rem;
  }

  .hero-content p {
    font-size: 1rem;
  }

  .feature,
  .orientacion,
  .news-card,
  .member-card,
  .link-card {
    padding: 1.5rem;
  }

  .news-carousel {
    padding: 1rem 0;
  }

  .news-card {
    min-width: 250px;
  }

  .org-chart {
    transform: scale(0.6);
  }

  .footer-content {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .social-links {
    justify-content: center;
  }
}

@media (min-width: 1600px) {
  .container {
    max-width: 1400px;
  }

  .hero-content h1 {
    font-size: 4rem;
  }

  .hero-content p {
    font-size: 1.8rem;
  }

  .feature,
  .orientacion,
  .member-card,
  .link-card {
    padding: 2.5rem;
  }

  .org-chart {
    transform: scale(1.2);
    transform-origin: top center;
  }
}

@media (hover: none) {
  .nav-links a,
  .cta-button,
  .link-button,
  .submit-button {
    padding: 1rem 1.5rem;
  }

  .feature,
  .member-card,
  .link-card {
    touch-action: pan-y pinch-zoom;
  }
}

/* Mejora en la transición del scroll suave */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 80px;
}

/*****************************Agregados por mi*********************************/
.feature-icon img {
  width: 250px;
  height: auto;
  margin-bottom: 1rem;
}
.orientacion img {
  width: 70%;
  height: auto;
  margin-bottom: 20px;
  border-radius: 5px;
}
.member-photo img {
  width: 100%;
  height: auto;
  border-radius: 5%;
}
