/* ==========================================================================
   Buttons
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: var(--space-3) var(--space-8);
  font-family: var(--font-body);
  font-size: var(--text-sm);
  font-weight: 500;
  letter-spacing: var(--tracking-wide);
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--duration-normal) var(--ease-out);
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

/* Primary gradient button */
.btn--primary {
  background: var(--gradient-primary);
  color: var(--color-text-inverse);
  border: none;
  box-shadow: var(--shadow-md);
}

.btn--primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg), var(--shadow-glow-pink);
  opacity: 1;
}

.btn--primary:active {
  transform: translateY(0);
}

/* Shine effect on hover */
.btn--primary::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: var(--gradient-shine);
  transition: left var(--duration-slower) var(--ease-out);
}

.btn--primary:hover::after {
  left: 100%;
}

/* Outline button */
.btn--outline {
  background: transparent;
  color: var(--color-primary-dark);
  border: 2px solid var(--color-primary);
}

.btn--outline:hover {
  background: var(--color-primary);
  color: var(--color-text-inverse);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  opacity: 1;
}

/* Ghost button */
.btn--ghost {
  background: transparent;
  color: var(--color-text-muted);
  border: 1px solid var(--color-border);
}

.btn--ghost:hover {
  border-color: var(--color-primary);
  color: var(--color-primary-dark);
  opacity: 1;
}

/* Button sizes */
.btn--lg {
  padding: var(--space-4) var(--space-10);
  font-size: var(--text-base);
}

.btn--sm {
  padding: var(--space-2) var(--space-4);
  font-size: var(--text-xs);
}

/* CTA pulse animation */
.btn--pulse {
  animation: btnPulse 2s ease-in-out infinite;
}

@keyframes btnPulse {
  0%, 100% { box-shadow: var(--shadow-md); }
  50% { box-shadow: var(--shadow-lg), var(--shadow-glow-pink); }
}

/* ==========================================================================
   Sticky CTA — Circular Rotating Text Button
   Purple-pink gradient world (matches re;ALIZE tokens)
   ========================================================================== */
.sticky-cta {
  position: fixed;
  bottom: var(--space-4);
  right: var(--space-4);
  z-index: var(--z-sticky);
  width: 110px;
  height: 110px;
  will-change: transform;
  -webkit-transform: translateZ(0);
  transform: translateZ(0);
}

.sticky-cta__link {
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  text-decoration: none;
  border-radius: 50%;
}

/* Outer glow ring — purple-pink */
.sticky-cta__glow {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 1.5px solid rgba(200, 160, 230, 0.4);
  animation: ctaGlowPulse 2.5s ease-in-out infinite;
  pointer-events: none;
}

/* Rotating SVG ring with text */
.sticky-cta__ring {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  animation: ctaRingSpin 20s linear infinite;
}

.sticky-cta__ring-text {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.18em;
  fill: rgba(155, 111, 204, 0.9);
  text-transform: uppercase;
}

/* Inner circle — soft gradient matching site palette */
.sticky-cta__inner {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 72%;
  height: 72%;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 40%, #1e1230 0%, #0e0818 100%);
  border: 1.5px solid rgba(200, 160, 230, 0.5);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
  transition: all var(--duration-normal) var(--ease-out);
  box-shadow:
    0 0 20px rgba(200, 160, 230, 0.2),
    inset 0 0 15px rgba(232, 123, 197, 0.08);
}

.sticky-cta__label-en {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--color-accent-pink);
  line-height: 1;
}

.sticky-cta__label-ja {
  font-family: var(--font-heading);
  font-size: 13px;
  font-weight: 700;
  color: var(--color-primary-light);
  line-height: 1;
}

/* Hover */
.sticky-cta__link:hover .sticky-cta__inner {
  border-color: rgba(232, 123, 197, 0.8);
  box-shadow:
    0 0 30px rgba(232, 123, 197, 0.35),
    0 0 60px rgba(200, 160, 230, 0.15),
    inset 0 0 20px rgba(232, 123, 197, 0.12);
  transform: translate(-50%, -50%) scale(1.05);
}

.sticky-cta__link:hover .sticky-cta__ring {
  animation-duration: 8s;
}

.sticky-cta__link:hover .sticky-cta__ring-text {
  fill: rgba(232, 123, 197, 0.95);
}

.sticky-cta__link:hover {
  opacity: 1;
}

/* Animations */
@keyframes ctaRingSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes ctaGlowPulse {
  0%, 100% {
    opacity: 0.5;
    transform: scale(1);
  }
  50% {
    opacity: 1;
    transform: scale(1.06);
    border-color: rgba(232, 123, 197, 0.5);
    box-shadow: 0 0 18px rgba(200, 160, 230, 0.2);
  }
}

/* ── Tablet ── */
@media (min-width: 840px) {
  .sticky-cta {
    width: 130px;
    height: 130px;
    bottom: var(--space-6);
    right: var(--space-6);
  }

  .sticky-cta__ring-text {
    font-size: 14.5px;
  }

  .sticky-cta__label-en {
    font-size: 12px;
  }

  .sticky-cta__label-ja {
    font-size: 14px;
  }
}

/* ── Desktop ── */
@media (min-width: 1280px) {
  .sticky-cta {
    width: 150px;
    height: 150px;
    bottom: var(--space-8);
    right: var(--space-8);
  }

  .sticky-cta__ring-text {
    font-size: 14px;
  }

  .sticky-cta__label-en {
    font-size: 14px;
  }

  .sticky-cta__label-ja {
    font-size: 16px;
  }
}
