/*
  buttons.css - Todos los botones CTA (Primary, Secondary, Solar Sun)
  Prioridad: ABOVE THE FOLD
  Tamaño: ~5.5KB
*/

/* ============================================
   PRIMARY CTA - Solar Energy Activation
   ============================================ */

.btn-solar-primary {
  position: relative !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  padding: 0.625rem 1.25rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: white !important;
  overflow: hidden;

  background: linear-gradient(135deg,
      rgb(255, 122, 0) 0%,
      rgb(255, 140, 30) 50%,
      rgb(255, 122, 0) 100%) !important;
  background-size: 200% 200%;

  box-shadow:
    0 4px 12px rgba(255, 122, 0, 0.25),
    0 2px 4px rgba(0, 0, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.3),
    inset 0 -1px 0 rgba(0, 0, 0, 0.1);

  border: none;
  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  opacity: 1 !important;
  user-select: none;
  -webkit-user-select: none;
  z-index: 1;
}

.btn-solar-primary>* {
  position: relative;
  z-index: 3;
  opacity: 1 !important;
}

.btn-solar-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg,
      rgba(255, 255, 255, 0.1) 0%,
      transparent 100%);
  pointer-events: none;
  z-index: 1;
  opacity: 0.5;
}

.btn-solar-primary::after {
  content: none;
}

.btn-solar-primary:hover {
  background-position: 100% 50%;
  box-shadow:
    0 8px 20px rgba(255, 122, 0, 0.4),
    0 4px 8px rgba(255, 122, 0, 0.2),
    inset 0 1px 0 rgba(255, 255, 255, 0.4),
    inset 0 -1px 0 rgba(0, 0, 0, 0.15);
  transform: translateY(-2px) scale(1.02);
}

.btn-solar-primary:active {
  box-shadow:
    0 2px 8px rgba(255, 122, 0, 0.3),
    0 1px 3px rgba(0, 0, 0, 0.2),
    inset 0 2px 4px rgba(0, 0, 0, 0.2);
  transform: translateY(0) scale(0.98);
}

.btn-solar-primary:focus-visible {
  outline: 2px solid rgb(255, 122, 0);
  outline-offset: 2px;
}

.btn-solar-primary i {
  position: relative;
  z-index: 1;
}

/* ============================================
   SECONDARY CTA - Solar Panel Module
   ============================================ */

.btn-solar-secondary {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.625rem 1.25rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: rgb(23, 23, 23);
  overflow: visible;

  background: linear-gradient(135deg,
      rgba(245, 245, 245, 0.6) 0%,
      rgba(255, 255, 255, 0.4) 50%,
      rgba(245, 245, 245, 0.6) 100%);
  backdrop-filter: blur(8px);

  border: 1.5px solid rgba(212, 212, 212, 0.5);

  box-shadow:
    0 2px 8px rgba(0, 0, 0, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.5);

  cursor: pointer;
  transition: all 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  user-select: none;
  -webkit-user-select: none;
  z-index: 1;
}

.btn-solar-secondary>* {
  position: relative;
  z-index: 2;
}

.btn-solar-secondary:hover {
  color: rgb(255, 122, 0);
  background: linear-gradient(135deg,
      rgba(255, 235, 220, 0.7) 0%,
      rgba(255, 245, 235, 0.6) 50%,
      rgba(255, 235, 220, 0.7) 100%);
  border-color: rgba(255, 122, 0, 0.4);
  box-shadow:
    0 4px 16px rgba(255, 122, 0, 0.15),
    0 2px 8px rgba(255, 122, 0, 0.1),
    inset 0 1px 0 rgba(255, 255, 255, 0.6);
  transform: translateY(-2px) scale(1.01);
}

.btn-solar-secondary:active {
  box-shadow:
    0 1px 4px rgba(255, 122, 0, 0.2),
    inset 0 2px 4px rgba(0, 0, 0, 0.1);
  transform: translateY(0) scale(0.99);
}

.btn-solar-secondary:focus-visible {
  outline: 2px solid rgba(255, 122, 0, 0.5);
  outline-offset: 2px;
}

.btn-solar-secondary:hover i {
  transform: scale(1.1);
  color: rgb(255, 122, 0);
}

.btn-solar-secondary i {
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  position: relative;
  z-index: 1;
}

/* ============================================
   SOLAR SUN CTA BUTTON
   Representa el sol en la narrativa "sistema solar vivo"
   ============================================ */

.home-landing .solar-cta-button {
  position: relative;
  isolation: isolate;

  background: radial-gradient(circle at center,
      rgba(255, 140, 40, 0.25) 0%,
      rgba(255, 122, 0, 0.20) 40%,
      rgba(255, 100, 0, 0.15) 100%);

  backdrop-filter: blur(12px) saturate(1.1);
  -webkit-backdrop-filter: blur(12px) saturate(1.1);

  box-shadow:
    0 4px 16px rgba(255, 122, 0, 0.12),
    0 2px 8px rgba(255, 122, 0, 0.08),
    0 0 0 1px rgba(255, 160, 80, 0.15),
    inset 0 1px 2px rgba(255, 255, 255, 0.2),
    inset 0 -1px 2px rgba(200, 80, 0, 0.08);

  border: 1.5px solid rgba(255, 140, 60, 0.25);
  transition: all 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  animation: solarPulseSubtle 4s ease-in-out infinite;
}

.home-landing .solar-rays {
  position: absolute;
  inset: -30%;
  background: repeating-conic-gradient(from 0deg at center,
      transparent 0deg,
      rgba(255, 180, 80, 0.04) 2deg,
      transparent 4deg,
      transparent 8deg);
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  animation: solarRotate 90s linear infinite;
}

.home-landing .solar-glow {
  position: absolute;
  inset: -8%;
  background: radial-gradient(circle at center,
      rgba(255, 255, 255, 0.15) 0%,
      rgba(255, 200, 100, 0.08) 40%,
      transparent 70%);
  border-radius: 50%;
  pointer-events: none;
  z-index: 1;
  filter: blur(6px);
  opacity: 0.5;
  animation: glowPulseSubtle 3.5s ease-in-out infinite alternate;
}

.home-landing .solar-cta-button:hover {
  transform: scale(1.05) translateY(-2px);
  background: radial-gradient(circle at center,
      rgba(255, 150, 50, 0.45) 0%,
      rgba(255, 122, 0, 0.35) 40%,
      rgba(255, 100, 0, 0.28) 100%);
  box-shadow:
    0 8px 28px rgba(255, 122, 0, 0.25),
    0 4px 14px rgba(255, 122, 0, 0.18),
    0 0 0 2px rgba(255, 180, 100, 0.35),
    inset 0 2px 4px rgba(255, 255, 255, 0.35),
    inset 0 -2px 4px rgba(200, 80, 0, 0.15);
  border-color: rgba(255, 160, 80, 0.45);
}

.home-landing .solar-cta-button:hover .solar-rays {
  inset: -38%;
  opacity: 1;
  animation: solarRotate 45s linear infinite;
}

.home-landing .solar-cta-button:hover .solar-glow {
  filter: blur(8px);
}

.home-landing .solar-cta-button:active {
  transform: scale(1.02) translateY(0px);
  transition: all 0.1s ease;
}

.home-landing .solar-cta-button:focus-visible {
  outline: none;
  box-shadow:
    0 8px 28px rgba(255, 122, 0, 0.25),
    0 4px 14px rgba(255, 122, 0, 0.18),
    0 0 0 3px rgba(255, 180, 100, 0.4),
    inset 0 2px 4px rgba(255, 255, 255, 0.35),
    inset 0 -2px 4px rgba(200, 80, 0, 0.15);
}

/* ============================================
   REDUCED MOTION SUPPORT
   ============================================ */

@media (prefers-reduced-motion: reduce) {
  .btn-solar-primary::after,
  .btn-solar-primary:hover,
  .btn-solar-secondary:hover,
  .home-landing .solar-cta-button,
  .home-landing .solar-rays,
  .home-landing .solar-glow {
    animation: none;
  }

  .btn-solar-primary:hover,
  .btn-solar-secondary:hover {
    transform: none;
  }

  .home-landing .solar-cta-button:hover {
    transform: scale(1.03);
  }
}

/* ============================================
   BEMCO OVERRIDES
   ============================================ */

.btn-solar-primary {
  color: var(--bemco-white) !important;
  background: linear-gradient(135deg,
      #003A8C 0%,
      #0052C0 48%,
      #00205B 100%) !important;
  box-shadow:
    0 10px 24px rgba(0, 32, 91, 0.32),
    0 4px 10px rgba(0, 32, 91, 0.18),
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    inset 0 -1px 0 rgba(0, 0, 0, 0.14);
}

.btn-solar-primary::before {
  background: linear-gradient(180deg,
      rgba(255, 255, 255, 0.18) 0%,
      rgba(255, 255, 255, 0.02) 100%);
}

.btn-solar-primary:hover {
  box-shadow:
    0 14px 28px rgba(0, 32, 91, 0.40),
    0 8px 18px rgba(0, 32, 91, 0.24),
    inset 0 1px 0 rgba(255, 255, 255, 0.28),
    inset 0 -1px 0 rgba(0, 0, 0, 0.16);
}

.btn-solar-primary:active {
  box-shadow:
    0 4px 10px rgba(0, 32, 91, 0.28),
    0 2px 4px rgba(0, 32, 91, 0.22),
    inset 0 2px 4px rgba(0, 0, 0, 0.14);
}

.btn-solar-primary:focus-visible {
  outline: 2px solid var(--bemco-accent);
}

/* Gold CTA on dark-background sections (hero, asesoria & contacto) — tertiary gold accent */
.home-landing .hero-section .btn-solar-primary,
.home-landing #asesoria .btn-solar-primary,
.home-landing #contacto .btn-solar-primary {
  color: var(--bemco-primary) !important;
  background: linear-gradient(135deg,
      #F9B03F 0%,
      #FFD166 48%,
      #F0A126 100%) !important;
  box-shadow:
    0 10px 24px rgba(249, 176, 63, 0.28),
    0 4px 10px rgba(249, 176, 63, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.55),
    inset 0 -1px 0 rgba(128, 84, 10, 0.16);
}

.btn-solar-secondary {
  color: var(--bemco-text);
  background: linear-gradient(135deg,
      rgba(255, 255, 255, 0.92) 0%,
      rgba(245, 247, 250, 0.96) 50%,
      rgba(255, 255, 255, 0.92) 100%);
  border: 1.5px solid rgba(0, 32, 91, 0.12);
  box-shadow:
    0 6px 18px rgba(0, 32, 91, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.85);
}

.btn-solar-secondary:hover {
  color: var(--bemco-primary);
  background: linear-gradient(135deg,
      rgba(0, 32, 91, 0.06) 0%,
      rgba(255, 255, 255, 0.98) 52%,
      rgba(0, 58, 140, 0.06) 100%);
  border-color: rgba(0, 58, 140, 0.30);
  box-shadow:
    0 10px 22px rgba(0, 32, 91, 0.10),
    0 3px 10px rgba(0, 32, 91, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.90);
}

.btn-solar-secondary:focus-visible {
  outline: 2px solid rgba(0, 58, 140, 0.48);
}

.btn-solar-secondary:hover i {
  color: var(--bemco-primary);
}

.home-landing .solar-cta-button {
  background: radial-gradient(circle at center,
      rgba(249, 176, 63, 0.30) 0%,
      rgba(249, 176, 63, 0.18) 40%,
      rgba(0, 58, 140, 0.14) 100%);
  box-shadow:
    0 6px 20px rgba(249, 176, 63, 0.14),
    0 3px 10px rgba(0, 32, 91, 0.10),
    0 0 0 1px rgba(249, 176, 63, 0.18),
    inset 0 1px 2px rgba(255, 255, 255, 0.22),
    inset 0 -1px 2px rgba(0, 32, 91, 0.10);
  border: 1.5px solid rgba(249, 176, 63, 0.28);
}

.home-landing .solar-rays {
  background: repeating-conic-gradient(from 0deg at center,
      transparent 0deg,
      rgba(249, 176, 63, 0.05) 2deg,
      transparent 4deg,
      transparent 8deg);
}

.home-landing .solar-glow {
  background: radial-gradient(circle at center,
      rgba(255, 255, 255, 0.16) 0%,
      rgba(249, 176, 63, 0.10) 42%,
      transparent 72%);
}

.home-landing .solar-cta-button:hover {
  background: radial-gradient(circle at center,
      rgba(249, 176, 63, 0.42) 0%,
      rgba(249, 176, 63, 0.28) 42%,
      rgba(0, 58, 140, 0.18) 100%);
  box-shadow:
    0 12px 30px rgba(249, 176, 63, 0.24),
    0 5px 16px rgba(0, 32, 91, 0.16),
    0 0 0 2px rgba(249, 176, 63, 0.26),
    inset 0 2px 4px rgba(255, 255, 255, 0.35),
    inset 0 -2px 4px rgba(0, 32, 91, 0.12);
  border-color: rgba(249, 176, 63, 0.44);
}
