/* =========================================
   INDEX.CSS 
========================================= */

/* ---- VARIABLES PROPIAS DEL HOME ---- */
:root {
  --verde-hero:    #1a5c38;
  --verde-mid:     #2e8b57;
  --verde-bright:  #3ab26e;
  --verde-glow:    rgba(58, 178, 110, 0.18);
  --crema:         #f5f2ec;
  --blanco:        #ffffff;
  --texto-dark:    #0f1f14;
  --texto-mid:     #3d5247;
  --texto-suave:   #7a9185;
  --sombra-card:   0 20px 60px rgba(15, 31, 20, 0.12);
  --font-display:  'Playfair Display', Georgia, serif;
  --font-body:     'DM Sans', sans-serif;
}

/* ---- RESET HOME ---- */
.home-body {
  margin: 0;
  padding: 0;
  font-family: var(--font-body);
  background: var(--crema);
  color: var(--texto-dark);
  overflow-x: hidden;
}


/* =========================================
   NAVBAR
========================================= */
.home-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 60px;
  background: rgba(26, 92, 56, 0.92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255,255,255,0.08);
  animation: navSlide 0.7s ease both;
}

@keyframes navSlide {
  from { transform: translateY(-100%); opacity: 0; }
  to   { transform: translateY(0);     opacity: 1; }
}

.home-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: white;
}

.home-brand-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.home-brand-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.home-brand-icon.small {
  width: 30px;
  height: 30px;
  border-radius: 7px;
}

.home-brand-name {
  font-size: 16px;
  font-weight: 300;
  color: rgba(255,255,255,0.85);
  letter-spacing: 0.3px;
}

.home-brand-name strong {
  font-weight: 600;
  color: white;
}

.home-links {
  display: flex;
  gap: 8px;
  align-items: center;
}

.home-nav-link {
  color: rgba(255,255,255,0.75);
  text-decoration: none;
  font-size: 14px;
  font-weight: 400;
  padding: 8px 18px;
  border-radius: 8px;
  transition: all 0.2s;
}

.home-nav-link:hover {
  color: white;
  background: rgba(255,255,255,0.1);
}


/* =========================================
   HERO
========================================= */
.home-hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* Fondo con imagen */
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform: scale(0.8);
  animation: heroZoom 12s ease-in-out infinite alternate;
}

@keyframes heroZoom {
  from { transform: scale(1.05); }
  to   { transform: scale(1.12); }
}

/* Overlay en capas para impacto */
.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      160deg,
      rgba(10, 35, 20, 0.82) 0%,
      rgba(20, 70, 40, 0.70) 40%,
      rgba(30, 100, 55, 0.55) 100%
    );
}

/* Partículas decorativas */
.hero-particles {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}

.particle {
  position: absolute;
  border-radius: 50%;
  background: rgba(58, 178, 110, 0.15);
  border: 1px solid rgba(58, 178, 110, 0.2);
  animation: float 8s ease-in-out infinite;
}

.p1 { width: 300px; height: 300px; top: -80px; right: -60px; animation-delay: 0s; }
.p2 { width: 180px; height: 180px; bottom: 100px; left: -40px; animation-delay: 2s; }
.p3 { width: 80px;  height: 80px;  top: 30%;  right: 20%; animation-delay: 4s; }
.p4 { width: 120px; height: 120px; bottom: 20%; right: 10%; animation-delay: 1.5s; }

@keyframes float {
  0%, 100% { transform: translateY(0) scale(1); opacity: 0.6; }
  50%       { transform: translateY(-20px) scale(1.05); opacity: 1; }
}

/* Contenido hero */
.hero-content {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 120px 24px 80px;
  max-width: 800px;
  animation: heroFade 1s ease 0.3s both;
}

@keyframes heroFade {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Badge "oficial" */
.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(58, 178, 110, 0.2);
  border: 1px solid rgba(58, 178, 110, 0.4);
  color: #a8f0c6;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  padding: 7px 18px;
  border-radius: 40px;
  margin-bottom: 32px;
  backdrop-filter: blur(8px);
}

.badge-dot {
  width: 7px;
  height: 7px;
  background: #3ab26e;
  border-radius: 50%;
  animation: pulse-dot 2s infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 0 rgba(58,178,110,0.5); }
  50%       { box-shadow: 0 0 0 5px rgba(58,178,110,0); }
}

/* Título principal */
.hero-title {
  font-family: var(--font-body);
  font-size: clamp(28px, 4.5vw, 52px);
  font-weight: 700;
  line-height: 1.18;
  color: white;
  margin: 0 0 28px;
  letter-spacing: -0.5px;
}

.hero-title em {
  font-style: normal;
  font-weight: 300;
  color: #a8f0c6;
}

/* Descripción */
.hero-desc {
  font-size: 17px;
  font-weight: 300;
  color: rgba(255,255,255,0.75);
  line-height: 1.7;
  max-width: 520px;
  margin: 0 auto 44px;
}

/* Botones CTA */
.hero-cta {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 56px;
}

.cta-primary {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--verde-bright);
  color: white;
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  padding: 15px 32px;
  border-radius: 12px;
  transition: all 0.25s;
  box-shadow: 0 8px 30px rgba(58, 178, 110, 0.4);
  letter-spacing: 0.2px;
}

.cta-primary:hover {
  background: #2ea05c;
  transform: translateY(-2px);
  box-shadow: 0 14px 40px rgba(58, 178, 110, 0.5);
}

.cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.25);
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 15px;
  font-weight: 400;
  padding: 15px 28px;
  border-radius: 12px;
  transition: all 0.25s;
  backdrop-filter: blur(8px);
}

.cta-secondary:hover {
  background: rgba(255,255,255,0.18);
  color: white;
  transform: translateY(-2px);
}

/* Mini estadísticas */
.hero-stats {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 20px 36px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 16px;
  backdrop-filter: blur(12px);
  width: fit-content;
  margin: 0 auto;
}

.hero-stat {
  text-align: center;
  padding: 0 28px;
}

.hero-stat strong {
  display: block;
  font-size: 22px;
  font-weight: 700;
  color: #a8f0c6;
  font-family: var(--font-display);
}

.hero-stat span {
  font-size: 11px;
  color: rgba(255,255,255,0.55);
  text-transform: uppercase;
  letter-spacing: 0.8px;
  margin-top: 2px;
  display: block;
}

.hero-stat-divider {
  width: 1px;
  height: 36px;
  background: rgba(255,255,255,0.15);
}

/* Scroll hint */
.hero-scroll {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 2;
}

.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom, rgba(255,255,255,0.5), transparent);
  margin: auto;
  animation: scrollPulse 2s ease-in-out infinite;
}

@keyframes scrollPulse {
  0%, 100% { opacity: 0.4; transform: scaleY(1); }
  50%       { opacity: 1;   transform: scaleY(0.6); }
}


/* =========================================
   SECCIÓN CARDS ACCESO
========================================= */
.home-cards {
  background: var(--crema);
  padding: 90px 24px 100px;
  position: relative;
}

.home-cards::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, #c8d8cc, transparent);
}

.cards-wrapper {
  max-width: 960px;
  margin: 0 auto;
}

.section-label {
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--verde-mid);
  margin-bottom: 48px;
}

.cards-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

/* Card de acceso base */
.access-card {
  display: block;
  text-decoration: none;
  color: var(--texto-dark);
  border-radius: 20px;
  padding: 40px 36px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  overflow: hidden;
}

.access-card::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 20px;
  opacity: 0;
  transition: opacity 0.3s;
}

.access-card:hover {
  transform: translateY(-6px);
}

.access-card:hover::after {
  opacity: 1;
}

/* Card Estudiante */
.card-student {
  background: white;
  box-shadow: var(--sombra-card);
  border: 1px solid rgba(46, 139, 87, 0.1);
}

.card-student:hover {
  box-shadow: 0 28px 70px rgba(15, 31, 20, 0.18);
  border-color: rgba(46, 139, 87, 0.25);
}

/* Card Admin */
.card-admin {
  background: var(--verde-hero);
  box-shadow: 0 20px 60px rgba(26, 92, 56, 0.3);
}

.card-admin h3,
.card-admin p,
.card-admin .access-tag {
  color: rgba(255,255,255,0.9) !important;
}

.card-admin .access-icon {
  background: rgba(255,255,255,0.12) !important;
  color: #a8f0c6 !important;
  border-color: rgba(255,255,255,0.2) !important;
}

.card-admin .access-tag {
  background: rgba(255,255,255,0.1) !important;
  color: rgba(255,255,255,0.7) !important;
}

.card-admin .access-cta {
  background: rgba(255,255,255,0.15) !important;
  color: white !important;
  box-shadow: none !important;
}

.card-admin:hover .access-cta {
  background: rgba(255,255,255,0.25) !important;
  transform: translateY(-2px);
}

.card-admin:hover {
  box-shadow: 0 30px 80px rgba(26, 92, 56, 0.45);
}

/* Partes internas de cada card */
.access-card-top {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}

.access-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: #eaf7ef;
  border: 1px solid rgba(46,139,87,0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--verde-mid);
  flex-shrink: 0;
}

.access-tag {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--texto-suave);
  background: #eef2ee;
  padding: 4px 12px;
  border-radius: 20px;
}

.access-card h3 {
  font-family: var(--font-body);
  font-size: 26px;
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 14px;
  color: var(--texto-dark);
}

.access-card p {
  font-size: 14px;
  font-weight: 400;
  color: var(--texto-mid);
  line-height: 1.7;
  margin: 0 0 28px;
}

.access-cta {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--blanco);
  background: var(--verde-bright);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: fit-content;
  padding: 13px 26px;
  margin-top: 20px;
  border-radius: 999px;
  box-shadow: 0 8px 20px rgba(58, 178, 110, 0.35);
  transition: background 0.25s ease, transform 0.2s ease, box-shadow 0.25s ease;
}

.access-card:hover .access-cta {
  background: #2ea05c;
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(58, 178, 110, 0.45);
}

.arrow {
  display: inline-block;
  transition: transform 0.25s;
}

.access-card:hover .arrow {
  transform: translateX(5px);
}


/* =========================================
   FOOTER
========================================= */
.home-footer {
  background: var(--verde-hero);
  padding: 50px 24px;
}

.footer-inner {
  max-width: 960px;
  margin: 0 auto;
  text-align: center;
}

.footer-brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: rgba(255,255,255,0.9);
  font-size: 15px;
  margin-bottom: 16px;
}

.footer-brand .home-brand-icon {
  width: 44px;
  height: 44px;
}

.footer-desc {
  font-size: 13px;
  color: rgba(255,255,255,0.5);
  max-width: 480px;
  margin: 0 auto 20px;
  line-height: 1.7;
}

.footer-copy {
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  margin: 0;
}


/* =========================================
   RESPONSIVO
========================================= */
@media (max-width: 768px) {

  .home-nav {
    padding: 16px 24px;
  }

  .hero-content {
    padding: 100px 20px 60px;
  }

  .hero-stats {
    gap: 0;
    padding: 16px 20px;
  }

  .hero-stat {
    padding: 0 16px;
  }

  .hero-stat strong {
    font-size: 18px;
  }

  .cards-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .access-card {
    padding: 30px 24px;
  }

  .access-card h3 {
    font-size: 24px;
  }

  .hero-cta {
    flex-direction: column;
    align-items: center;
  }

  .cta-primary,
  .cta-secondary {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .hero-stats {
    flex-wrap: wrap;
    gap: 16px;
  }
  .hero-stat-divider {
    display: none;
  }
}
