/*
 * Author: Pyrukent
 * assets/css/responsive.css
 * Proyecto VOFARI
 * Versión: 2.1 - Corrección definitiva móviles
 */

/* =====================================================================
 * ESTILOS PARA TABLETS
 * (Reglas para pantallas de hasta 992px)
 * ===================================================================== */
@media (max-width: 992px) {
  .nav-mobile-toggle {
    display: flex;
    z-index: 1001;
  }

  .nav-mobile-toggle.active span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  .nav-mobile-toggle.active span:nth-child(2) {
    opacity: 0;
  }
  .nav-mobile-toggle.active span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .nav-links {
    display: flex;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(44, 62, 80, 0.98);
    backdrop-filter: blur(10px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    transform: translateX(100%);
    transition: transform var(--transition-normal);
    z-index: 1000;
  }

  .nav-links.active {
    transform: translateX(0);
  }

  .nav-links a {
    font-size: 1.5rem;
    color: var(--clr-white);
    transform: translateY(20px);
    opacity: 0;
    animation: fadeInUp 0.3s ease-out forwards;
  }

  .nav-links.active li:nth-child(1) a { animation-delay: 0.2s; }
  .nav-links.active li:nth-child(2) a { animation-delay: 0.3s; }
  .nav-links.active li:nth-child(3) a { animation-delay: 0.4s; }
  .nav-links.active li:nth-child(4) a { animation-delay: 0.5s; }

  .about-hero,
  .mission-vision-grid,
  .processes-content,
  .contact-content {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }

  .about-image {
    order: -1;
  }

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

/* =====================================================================
 * ESTILOS PARA MÓVILES
 * (Reglas para pantallas de hasta 768px)
 * ===================================================================== */
@media (max-width: 768px) {
  html, body {
    overflow-x: hidden;
    width: 100%;
  }

  .container {
    padding: 0 1.5rem;
  }

  h2 {
    font-size: 1.75rem;
  }

  .section-subtitle {
    font-size: 1rem;
    margin-bottom: 2.5rem;
  }

  .hero-actions {
    flex-direction: column;
    width: 100%;
    max-width: 320px;
    gap: 1rem;
  }
  
  .btn-primary, .btn-secondary {
    justify-content: center;
    width: 100%;
  }

  .hero-stats {
    flex-direction: column;
    gap: 1.5rem;
    width: 100%;
    max-width: 320px;
  }
  
  .stat-item {
    flex-direction: row;
    justify-content: flex-start;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.15);
    width: 100%;
  }

  /* =====================================================================
   * CORRECCIÓN DEFINITIVA: Checkmarks sin sobreposición
   * Usando flexbox en lugar de position absolute
   * ===================================================================== */
  .service-features li {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    line-height: 1.6;
    font-size: 0.9rem;
    padding: 0.25rem 0;
  }

  .service-features li::before {
    flex-shrink: 0;
    width: 1.25rem;
    height: 1.25rem;
    font-size: 1rem;
    margin-top: 0.2rem;
  }

  /* =====================================================================
   * CORRECCIÓN: Rejillas forzadas a 1 columna en móviles
   * ===================================================================== */
  .services-grid,
  .methodology-grid,
  .values-grid,
  .benefits-grid {
    grid-template-columns: 1fr !important;
    gap: 1.5rem;
  }

  .form-row {
    grid-template-columns: 1fr !important;
  }

  .section-services,
  .section-about,
  .section-processes,
  .section-contact {
    padding: 4rem 0;
  }

  /* =====================================================================
   * CORRECCIÓN: Indicador de scroll que se sobrepone
   * ===================================================================== */
  .hero-scroll-indicator {
    bottom: 1rem;
    z-index: 15;
  }

  .hero-scroll-indicator span {
    font-size: 0.75rem;
  }
}

/* =====================================================================
 * AJUSTES FINALES PARA PANTALLAS MUY PEQUEÑAS
 * (Reglas para pantallas de hasta 480px)
 * ===================================================================== */
@media (max-width: 480px) {
  h1 {
    font-size: 2.2rem;
  }
  
  .hero-subtitle {
    font-size: 1rem;
  }
  
  h2 {
    font-size: 1.6rem;
  }
  
  .section-subtitle {
    font-size: 0.95rem;
  }

  .hero-scroll-indicator {
    bottom: 0.5rem;
  }
}

/* =====================================================================
 * KEYFRAMES PARA ANIMACIONES DEL MENÚ
 * ===================================================================== */
@keyframes fadeInUp {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}