/*===================*/
/*=== BASE BUTTONS ===*/
/*===================*/

.btn,
.btn-2 {
  display: flex;
  justify-content: center;
  align-items: center;
  font-weight: 400;
  cursor: pointer;
  border: none;
  position: relative;
  overflow: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-family: "Gilroy", sans-serif;
  user-select: none;
  -webkit-user-select: none;
  will-change: transform;
}

.btn:active,
.btn-2:active {
  transform: scale(0.98);
}

/*====================*/
/*=== VARIANT: HECTOR ===*/
/*====================*/

.btn-hector {
  background: linear-gradient(
    135deg,
    var(--primary-color) 0%,
    var(--primary-dark) 100%
  );
  color: var(--white);
  box-shadow:
    0 5px 20px rgba(238, 10, 16, 0.4),
    inset 0 0 0 2px rgba(255, 255, 255, 0.1);
}

.btn-hector::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0;
  height: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%);
  transition:
    width 0.6s ease,
    height 0.6s ease;
  z-index: 1;
}

.btn-hector::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    45deg,
    transparent 30%,
    rgba(255, 255, 255, 0.2) 50%,
    transparent 70%
  );
  transform: translateX(-100%) skewX(-15deg);
  transition: transform 0.8s ease;
  z-index: 1;
}

.btn-hector:hover::before {
  width: 300%;
  height: 300%;
}

.btn-hector:hover::after {
  transform: translateX(100%) skewX(-15deg);
}

.btn-hector:hover {
  box-shadow:
    0 8px 30px rgba(238, 10, 16, 0.6),
    0 0 40px rgba(238, 10, 16, 0.4),
    inset 0 0 0 2px rgba(255, 255, 255, 0.2);
  transform: translateY(-3px) scale(1.02);
}

/*===================*/
/*=== VARIANT: ZEUS ===*/
/*===================*/

.btn-zeus {
  background: linear-gradient(
    135deg,
    var(--primary-dark) 0%,
    var(--primary-color) 50%,
    var(--primary-dark) 100%
  );
  background-size: 200% 100%;
  background-position: 100% 0;
  color: var(--white);
  box-shadow:
    0 0 20px rgba(238, 10, 16, 0.5),
    0 5px 15px rgba(238, 10, 16, 0.3);
  animation: zeus-glow 3s ease-in-out infinite;
}

.btn-zeus::before {
  content: "";
  position: absolute;
  inset: -2px;
  background: linear-gradient(
    45deg,
    var(--primary-light),
    var(--primary-color),
    var(--primary-light),
    var(--primary-color)
  );
  background-size: 400% 400%;
  border-radius: inherit;
  z-index: -1;
  opacity: 0;
  animation: zeus-border 3s ease-in-out infinite;
  filter: blur(10px);
}

.btn-zeus:hover {
  background-position: 0 0;
  box-shadow:
    0 0 40px rgba(238, 10, 16, 0.8),
    0 8px 25px rgba(238, 10, 16, 0.5),
    inset 0 0 20px rgba(255, 255, 255, 0.1);
  transform: translateY(-3px);
}

.btn-zeus:hover::before {
  opacity: 1;
}

/*====================*/
/*=== VARIANT: APOLLO ===*/
/*====================*/

.btn-apollo {
  background: linear-gradient(
    135deg,
    var(--primary-color) 0%,
    var(--primary-dark) 100%
  );
  color: var(--white);
  box-shadow:
    0 4px 15px rgba(238, 10, 16, 0.3),
    inset 0 0 20px rgba(255, 255, 255, 0.05);
  overflow: hidden;
}

/* Энергетические волны */
.btn-apollo::before {
  content: "";
  position: absolute;
  inset: -50%;
  background: conic-gradient(
    from 0deg at 50% 50%,
    transparent 0deg,
    rgba(255, 255, 255, 0.15) 45deg,
    transparent 90deg,
    transparent 180deg,
    rgba(255, 255, 255, 0.15) 225deg,
    transparent 270deg,
    transparent 360deg
  );
  animation: apollo-rotate 4s linear infinite;
  z-index: 1;
}

/* Внутреннее свечение */
.btn-apollo::after {
  content: "";
  position: absolute;
  inset: 2px;
  background: radial-gradient(
    circle at center,
    rgba(255, 255, 255, 0.1) 0%,
    transparent 60%
  );
  border-radius: inherit;
  opacity: 0;
  transition: opacity 0.4s ease;
  z-index: 1;
  animation: apollo-pulse 2s ease-in-out infinite;
}

.btn-apollo:hover::before {
  animation: apollo-rotate 2s linear infinite;
}

.btn-apollo:hover::after {
  opacity: 1;
}

.btn-apollo:hover {
  background: linear-gradient(
    135deg,
    var(--primary-light) 0%,
    var(--primary-color) 100%
  );
  box-shadow:
    0 8px 30px rgba(238, 10, 16, 0.6),
    0 0 40px rgba(238, 10, 16, 0.4),
    inset 0 0 30px rgba(255, 255, 255, 0.1);
  transform: translateY(-2px) scale(1.02);
}

/*====================*/
/*=== VARIANT: ARES ===*/
/*====================*/

.btn-ares {
  background: var(--primary-color);
  color: var(--white);
  box-shadow:
    0 5px 15px rgba(238, 10, 16, 0.4),
    inset 0 -3px 0 rgba(0, 0, 0, 0.2);
}

.btn-ares::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.4),
    transparent
  );
  transition: left 0.5s ease;
  z-index: 1;
}

.btn-ares::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 2px solid rgba(255, 255, 255, 0);
  transition: border-color 0.3s ease;
  z-index: 1;
}

.btn-ares:hover {
  box-shadow:
    0 8px 30px rgba(238, 10, 16, 0.6),
    0 0 0 4px rgba(238, 10, 16, 0.2),
    inset 0 -3px 0 rgba(0, 0, 0, 0.3);
  transform: translateY(-2px);
}

.btn-ares:hover::before {
  left: 100%;
}

.btn-ares:hover::after {
  border-color: rgba(255, 255, 255, 0.3);
}

.btn-ares:active {
  box-shadow:
    0 2px 10px rgba(238, 10, 16, 0.4),
    inset 0 3px 0 rgba(0, 0, 0, 0.2);
  transform: translateY(0);
}

/*========================*/
/*=== BTN-2 BASE STYLE ===*/
/*========================*/

.btn-2::after {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    120deg,
    transparent,
    var(--light-gray),
    transparent
  );
  transform: skewX(15deg);
  transition: left 0.6s ease;
  z-index: 1;
}

.btn-2:hover {
  transform: scale(1.05);
}

.btn-2:hover::after {
  left: 125%;
}

/*==================*/
/*=== ANIMATIONS ===*/
/*==================*/

@keyframes zeus-glow {
  0%,
  100% {
    box-shadow:
      0 0 20px rgba(238, 10, 16, 0.5),
      0 5px 15px rgba(238, 10, 16, 0.3);
  }
  50% {
    box-shadow:
      0 0 30px rgba(238, 10, 16, 0.7),
      0 5px 20px rgba(238, 10, 16, 0.5);
  }
}

@keyframes zeus-border {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@keyframes apollo-stripes {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(20px);
  }
}

@keyframes apollo-rotate {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

@keyframes apollo-pulse {
  0%,
  100% {
    opacity: 0.3;
    transform: scale(0.95);
  }
  50% {
    opacity: 0.6;
    transform: scale(1.05);
  }
}

/*=====================*/
/*=== REDUCED MOTION ===*/
/*=====================*/

@media (prefers-reduced-motion: reduce) {
  .btn,
  .btn-2,
  .btn-hector,
  .btn-zeus,
  .btn-apollo,
  .btn-ares {
    animation: none !important;
    transition: none !important;
  }

  .btn::before,
  .btn::after,
  .btn-2::before,
  .btn-2::after,
  .btn-hector::before,
  .btn-hector::after,
  .btn-zeus::before,
  .btn-zeus::after,
  .btn-apollo::before,
  .btn-apollo::after,
  .btn-ares::before,
  .btn-ares::after {
    animation: none !important;
    transition: none !important;
  }
}
