/**
 * EvoLuz.mx - Custom Styles
 * Paleta Green Tech Professional
 */

/* Google Fonts - Sora (Professional font for tech/solar brands) */
@import url('https://fonts.googleapis.com/css2?family=Sora:wght@300;400;500;600;700&display=swap');

/* Typography */
body {
  font-family: 'Sora', system-ui, -apple-system, sans-serif;
  font-weight: 400;
  line-height: 1.6;
}

h1, h2, h3, h4, h5, h6 {
  font-family: 'Sora', system-ui, -apple-system, sans-serif;
  font-weight: 600;
  line-height: 1.2;
}

h1 { font-weight: 700; }
h2 { font-weight: 600; }

/* Icon System - Professional SVG Icons */
.icon-evo {
  display: inline-block;
  width: 2rem;
  height: 2rem;
}

.icon-evo-lg {
  width: 3rem;
  height: 3rem;
}

.icon-evo-xl {
  width: 6rem;
  height: 6rem;
}

/* Hero Section with Background Image */
.hero-section {
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
  position: relative;
}

.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at center, rgba(11, 31, 26, 0.25) 0%, rgba(11, 31, 26, 0.40) 100%),
    linear-gradient(135deg, rgba(11, 31, 26, 0.30) 0%, rgba(19, 90, 74, 0.25) 50%, rgba(11, 31, 26, 0.35) 100%);
  backdrop-filter: blur(2px) saturate(110%);
  -webkit-backdrop-filter: blur(2px) saturate(110%);
  z-index: 0;
}

.hero-section > * {
  position: relative;
  z-index: 1;
}

:root {
  /* Paleta Green Tech Professional */
  --evo-green-primary: #16A34A;    /* Verde EvoLuz principal - CTAs, acciones */
  --evo-white-solar: #F9FAFB;      /* Blanco Solar - fondo base */
  --evo-gray-carbon: #0E0F11;      /* Gris Carbón - títulos, texto principal */
  --evo-gray-medium: #4A4A4A;      /* Gris Medio - texto secundario */
  --evo-gray-light: #E5E7EB;       /* Gris Claro - bloques secundarios */
  --evo-yellow-reflect: #FFD580;   /* Amarillo Reflejo - acentos solares */
  --evo-beige-luminous: #F5E9D3;   /* Beige Luminoso - calidez */

  /* Colores complementarios (mantener compatibilidad con diseño actual) */
  --evo-deep: #0B1F1A;
  --evo-forest: #135A4A;
  --evo-mint: #9BE6C0;
  --evo-lime: #7AE582;
}

/* WhatsApp oficial colors */
.whatsapp-green {
  background-color: #25D366;
}

/* Botón WhatsApp principal */
.btn-whatsapp {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: linear-gradient(135deg, #25D366 0%, #128C7E 100%);
  color: white;
  padding: 1rem 2rem;
  border-radius: 9999px;
  font-weight: 700;
  box-shadow: 0 10px 15px -3px rgba(37, 211, 102, 0.3);
  transition: all 0.3s ease;
  text-decoration: none;
}

.btn-whatsapp:hover {
  transform: scale(1.05) translateY(-2px);
  box-shadow: 0 20px 25px -5px rgba(37, 211, 102, 0.4);
}

.btn-whatsapp:active {
  transform: scale(0.98);
}

/* Botón WhatsApp flotante (mobile sticky) */
.btn-whatsapp-float {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 1000;
  animation: pulse-whatsapp 2s infinite;
}

@keyframes pulse-whatsapp {
  0%, 100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
  }
  50% {
    transform: scale(1.05);
    box-shadow: 0 0 0 10px rgba(37, 211, 102, 0);
  }
}

/* Badge profesional - Liquid Glass iOS 26 Style */
.badge-profesional {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  position: relative;
  overflow: hidden;

  /* Liquid Glass Core - Base verde translúcido */
  background: linear-gradient(
    135deg,
    rgba(122, 229, 130, 0.28) 0%,
    rgba(155, 230, 192, 0.18) 100%
  );
  backdrop-filter: blur(16px) saturate(180%);
  -webkit-backdrop-filter: blur(16px) saturate(180%);

  /* Borders & Shadows con tinte verde */
  border: 1px solid rgba(122, 229, 130, 0.4);
  border-radius: 9999px;
  box-shadow:
    0 8px 32px 0 rgba(122, 229, 130, 0.3),
    inset 0 1px 2px 0 rgba(255, 255, 255, 0.5),
    inset 0 -1px 2px 0 rgba(0, 0, 0, 0.15);

  /* Typography con contraste optimizado */
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.98);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3), 0 1px 2px rgba(0, 0, 0, 0.2);

  /* Transitions */
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.badge-profesional:hover {
  background: linear-gradient(
    135deg,
    rgba(122, 229, 130, 0.38) 0%,
    rgba(155, 230, 192, 0.28) 100%
  );
  transform: translateY(-2px) scale(1.02);
  box-shadow:
    0 12px 40px 0 rgba(122, 229, 130, 0.4),
    inset 0 1px 3px 0 rgba(255, 255, 255, 0.6),
    inset 0 -1px 3px 0 rgba(0, 0, 0, 0.2);
  border-color: rgba(122, 229, 130, 0.6);
}

.badge-profesional svg {
  width: 1.25rem;
  height: 1.25rem;
  color: rgba(255, 255, 255, 0.95);
  filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.3));
}

/* Testimonial card */
.testimonial-card {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 1.5rem;
  padding: 2rem;
  transition: all 0.3s ease;
}

.testimonial-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Proyecto card */
.proyecto-card {
  position: relative;
  overflow: hidden;
  border-radius: 1rem;
  background: var(--evo-gray-light);
  transition: all 0.3s ease;
}

.proyecto-card:hover {
  transform: scale(1.02);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.proyecto-card img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  transition: transform 0.3s ease;
}

.proyecto-card:hover img {
  transform: scale(1.1);
}

.proyecto-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, transparent 100%);
  padding: 1.5rem;
  color: white;
}

/* Glass effect para cards - Liquid Glass iOS 26 Enhanced */
.glass-card {
  /* Liquid Glass Base */
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.12) 0%,
    rgba(255, 255, 255, 0.06) 100%
  );
  backdrop-filter: blur(24px) saturate(160%);
  -webkit-backdrop-filter: blur(24px) saturate(160%);

  /* Borders & Depth */
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow:
    0 8px 32px 0 rgba(0, 0, 0, 0.37),
    inset 0 2px 4px 0 rgba(255, 255, 255, 0.15),
    inset 0 -2px 4px 0 rgba(0, 0, 0, 0.1);

  /* Subtle animation */
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glass-card:hover {
  background: linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.16) 0%,
    rgba(255, 255, 255, 0.08) 100%
  );
  box-shadow:
    0 12px 48px 0 rgba(0, 0, 0, 0.42),
    inset 0 2px 6px 0 rgba(255, 255, 255, 0.2),
    inset 0 -2px 6px 0 rgba(0, 0, 0, 0.12);
}

/* Section divider con icono solar */
.section-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 3rem 0;
}

.section-divider::before,
.section-divider::after {
  content: '';
  flex: 1;
  border-bottom: 2px solid var(--evo-gray-light);
}

.section-divider::before {
  margin-right: 1rem;
}

.section-divider::after {
  margin-left: 1rem;
}

/* Animaciones */
@keyframes float {
  0%, 100% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(-10px);
  }
}

.float-animation {
  animation: float 3s ease-in-out infinite;
}

/* Responsive utilities */
@media (max-width: 768px) {
  .btn-whatsapp-float {
    bottom: 1rem;
    right: 1rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.875rem;
  }
}

/* Loading skeleton (para imágenes lazy load) */
.skeleton {
  background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% {
    background-position: 200% 0;
  }
  100% {
    background-position: -200% 0;
  }
}

/* Print styles (para QR codes en materiales) */
@media print {
  .btn-whatsapp-float,
  header.sticky {
    display: none !important;
  }
}

/* Navigation Active States */
nav a.active {
  color: var(--evo-lime);
  font-weight: 600;
}

nav a {
  position: relative;
  transition: color 0.3s ease;
}

nav a:not(.active):hover {
  color: var(--evo-lime);
}

/* Active underline for desktop nav */
@media (min-width: 768px) {
  header nav a.active::after {
    content: '';
    position: absolute;
    bottom: -8px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--evo-lime);
    border-radius: 1px;
  }
}

/* Mobile Menu Animations */
#mobile-menu {
  opacity: 0;
  transition: opacity 0.3s ease;
}

#mobile-menu.showing {
  opacity: 1;
}

/* Mobile menu smooth slide in for nav links */
#mobile-menu nav a {
  animation: slideInLeft 0.4s ease forwards;
  opacity: 0;
}

#mobile-menu nav a:nth-child(1) { animation-delay: 0.1s; }
#mobile-menu nav a:nth-child(2) { animation-delay: 0.15s; }
#mobile-menu nav a:nth-child(3) { animation-delay: 0.2s; }
#mobile-menu nav a:nth-child(4) { animation-delay: 0.25s; }
#mobile-menu nav a:nth-child(5) { animation-delay: 0.3s; }

@keyframes slideInLeft {
  from {
    opacity: 0;
    transform: translateX(-20px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* Back to top button (optional) */
#back-to-top {
  transition: opacity 0.3s ease, transform 0.3s ease;
}

#back-to-top:hover {
  transform: translateY(-3px);
}

/* Badge Images - Estandarización 3:2 Aspect Ratio */
.badge-img {
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  border-radius: 0.5rem;
  display: block;
  margin: 0 auto 0.5rem;
}

/* Shimmer Animation for Badges - Liquid Glass Effect */
@keyframes shimmer {
  0%, 100% {
    background-position: -200% center;
  }
  50% {
    background-position: 200% center;
  }
}

.badge-profesional::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  background-size: 200% 100%;
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.3s;
  animation: shimmer 3s infinite;
}

.badge-profesional:hover::after {
  opacity: 0.7;
}

