/* Styles pour le bouton ultra-moderne */
@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@600;700&display=swap');

.ultra-button {
  --color-primary: #7C89FF;
  --color-secondary: #6574E6;
  --color-text: #ffffff;
  --sparkle-size: 20px;
  
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 40px;
  font-family: 'Plus Jakarta Sans', 'Rubik', -apple-system, sans-serif;
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 0.5px;
  color: var(--color-text);
  background: transparent;
  border: none;
  border-radius: 14px;
  cursor: pointer;
  overflow: hidden;
  isolation: isolate;
  transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 
    0 4px 20px rgba(124, 137, 255, 0.25),
    inset 0 0 0 2px rgba(255, 255, 255, 0.1);
}

/* Fond principal avec dégradé animé */
.ultra-button::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg, 
    var(--color-primary) 0%, 
    var(--color-secondary) 50%,
    var(--color-primary) 100%
  );
  background-size: 200% 200%;
  z-index: -2;
  animation: gradientShift 8s ease infinite;
}

/* Effet de brillance */
.ultra-button::after {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    to bottom right,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0) 40%,
    rgba(255, 255, 255, 0.3) 50%,
    rgba(255, 255, 255, 0) 60%,
    rgba(255, 255, 255, 0) 100%
  );
  transform: rotate(30deg) translate(-20%, -20%);
  transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: -1;
  opacity: 0;
}

/* Effet de particules */
.particles {
  position: absolute;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: -1;
}

.particle {
  position: absolute;
  background: white;
  border-radius: 50%;
  pointer-events: none;
  opacity: 0;
}

/* Texte et icône */
.button-content {
  display: flex;
  align-items: center;
  gap: 10px;
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  position: relative;
  z-index: 1;
}

.button-icon {
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* États interactifs */
.ultra-button:hover {
  transform: translateY(-2px) scale(1.02);
  box-shadow: 
    0 8px 30px rgba(124, 137, 255, 0.4),
    0 4px 12px rgba(0, 0, 0, 0.1);
}

.ultra-button:hover::after {
  opacity: 1;
  transform: rotate(30deg) translate(0, 0);
}

.ultra-button:active {
  transform: translateY(1px) scale(0.98);
}

.ultra-button:hover .button-content {
  transform: translateX(3px);
}

.ultra-button:hover .button-icon {
  transform: translateX(5px) rotate(-5deg);
}

/* Animation du dégradé */
@keyframes gradientShift {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

/* Style spécifique pour le bouton dans la barre de navigation */
.nav-ultra-button {
  padding: 0.75rem 2rem;
  font-size: 0.95rem;
  margin-left: 1rem;
  height: 100%;
  line-height: 1.5;
  min-width: 200px;
}

.nav-ultra-button .button-content {
  gap: 0.5rem;
}

.nav-ultra-button .button-icon {
  font-size: 0.9em;
}

/* Animation des particules */
@keyframes particle-float {
  0% { 
    transform: translate(0, 0) rotate(0deg);
    opacity: 0;
  }
  20% { opacity: 1; }
  100% { 
    transform: translate(var(--tx, 0), var(--ty, -100px)) rotate(360deg);
    opacity: 0;
  }
}
