@tailwind base;
@tailwind components;
@tailwind utilities;

@layer base {
  body {
    @apply bg-background-dark text-slate-100 antialiased selection:bg-primary/30;
    font-family: 'Inter', sans-serif;
  }
}

@layer components {
  /* -------- GLASSMORPHISM MAX PRO -------- */
  .glass-nav {
    background: rgba(16, 31, 34, 0.75);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(19, 200, 236, 0.12);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.05);
    transition: background 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  }
  
  .glass-nav.scrolled {
    background: rgba(10, 20, 22, 0.92);
    border-bottom: 1px solid rgba(19, 200, 236, 0.25);
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.7), 
                inset 0 1px 0 rgba(255, 255, 255, 0.08);
  }

  .glass-card {
    background: rgba(20, 37, 41, 0.45);
    backdrop-filter: blur(24px) saturate(140%);
    -webkit-backdrop-filter: blur(24px) saturate(140%);
    border: 1px solid rgba(19, 200, 236, 0.12);
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3), 
                inset 0 1px 1px rgba(255, 255, 255, 0.08), 
                inset 0 -1px 2px rgba(0, 0, 0, 0.2);
    transition: border-color 0.3s ease, box-shadow 0.3s ease, transform 0.3s ease;
  }
  
  .glass-card:hover {
    border-color: rgba(19, 200, 236, 0.35);
    box-shadow: 0 12px 40px rgba(19, 200, 236, 0.08), 
                inset 0 1px 1px rgba(255, 255, 255, 0.12);
  }

  /* --- SUBTLE LIFT AND NEON GLOW FOR CARDS --- */
  .hover-lift-glow {
    transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1),
                border-color 0.4s cubic-bezier(0.16, 1, 0.3, 1) !important;
  }
  
  .hover-lift-glow:hover {
    transform: translateY(-5px) scale(1.01) !important;
    box-shadow: 0 20px 40px -10px rgba(19, 200, 236, 0.15) !important;
    border-color: rgba(19, 200, 236, 0.35) !important;
  }


  /* -------- GLOWS & ACCENTS MAX PRO -------- */
  .glow-cyan {
    box-shadow: 0 0 20px rgba(19, 200, 236, 0.35),
                inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transition: box-shadow 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), 
                filter 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  }

  .glow-cyan:hover {
    box-shadow: 0 0 35px rgba(19, 200, 236, 0.65), 
                0 0 10px rgba(19, 200, 236, 0.3),
                inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
    filter: brightness(1.08);
  }
  
  .text-glow {
    text-shadow: 0 0 16px rgba(19, 200, 236, 0.6), 
                 0 0 30px rgba(19, 200, 236, 0.25);
  }

  .text-glow-orange {
    text-shadow: 0 0 16px rgba(245, 158, 11, 0.6), 
                 0 0 30px rgba(245, 158, 11, 0.25);
  }

  /* -------- BACKGROUNDS & SHIELDING -------- */
  .hero-gradient {
    background: radial-gradient(circle at 50% 25%, rgba(19, 200, 236, 0.16) 0%, rgba(16, 31, 34, 0) 55%),
                radial-gradient(circle at 15% 50%, rgba(19, 200, 236, 0.05) 0%, transparent 40%),
                radial-gradient(circle at 85% 65%, rgba(245, 158, 11, 0.04) 0%, transparent 45%);
  }

  /* -------- HYPER-MODERN INPUT STATES -------- */
  .glass-input {
    background: rgba(16, 31, 34, 0.6) !important;
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.2);
  }
  
  .glass-input:focus {
    border-color: #13c8ec !important;
    background: rgba(16, 31, 34, 0.8) !important;
    box-shadow: 0 0 20px rgba(19, 200, 236, 0.25), 
                inset 0 1px 2px rgba(0, 0, 0, 0.1);
  }

  /* -------- FLOATING MICRO-ANIMATIONS -------- */
  .float-anim {
    animation: float 6s ease-in-out infinite;
  }
  
  .float-anim-delayed {
    animation: float 6s ease-in-out infinite;
    animation-delay: -3s;
  }

  .float-anim-slow {
    animation: float 8s ease-in-out infinite;
  }

  .float-anim-slow-delayed {
    animation: float 8s ease-in-out infinite;
    animation-delay: -4s;
  }
  
  /* -------- SCROLL REVEAL -------- */
  .reveal {
    opacity: 0;
    transform: translateY(35px);
    transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 1s cubic-bezier(0.16, 1, 0.3, 1);
  }
  
  .reveal.from-left {
    transform: translateX(-40px);
  }
  
  .reveal.from-right {
    transform: translateX(40px);
  }

  .reveal.from-scale {
    transform: scale(0.94);
  }
  
  .reveal.visible {
    opacity: 1;
    transform: translateY(0) translateX(0) scale(1);
  }
  
  .reveal-stagger > * {
    opacity: 0;
    transform: translateY(25px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  }
  
  .reveal-stagger.visible > *:nth-child(1) { transition-delay: 0.05s; }
  .reveal-stagger.visible > *:nth-child(2) { transition-delay: 0.15s; }
  .reveal-stagger.visible > *:nth-child(3) { transition-delay: 0.25s; }
  .reveal-stagger.visible > *:nth-child(4) { transition-delay: 0.35s; }
  .reveal-stagger.visible > *:nth-child(5) { transition-delay: 0.45s; }
  
  .reveal-stagger.visible > * {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes float {
  0%, 100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-16px) rotate(1deg);
  }
}

/* --- TESTIMONIAL CAROUSEL --- */
.testimonial-carousel {
  position: relative;
  max-width: 900px;
  margin: 0 auto;
  overflow: hidden;
}

.carousel-track {
  display: flex;
  transition: transform 0.55s cubic-bezier(0.4, 0, 0.2, 1);
  will-change: transform;
}

.carousel-slide {
  flex: 0 0 100%;
  min-width: 0;
  opacity: 0;
  transition: opacity 0.55s;
  pointer-events: none;
}

.carousel-slide.active {
  opacity: 1;
  pointer-events: auto;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: rgba(16, 31, 34, 0.7);
  border: 1px solid rgba(19, 200, 236, 0.3);
  color: #13C8EC;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s;
  backdrop-filter: blur(8px);
}

.carousel-arrow:hover {
  background: rgba(19, 200, 236, 0.15);
  border-color: #13C8EC;
  transform: translateY(-50%) scale(1.1);
}

.carousel-prev { left: -10px; }
.carousel-next { right: -10px; }

@media (max-width: 768px) {
  .carousel-prev { left: 0; }
  .carousel-next { right: 0; }
  .carousel-arrow { width: 38px; height: 38px; }
}

.carousel-dot.active {
  background-color: #13C8EC;
  opacity: 1;
  transform: scale(1.3);
  box-shadow: 0 0 8px #13C8EC;
}

/* --- FRONTEND MAX PRO ANIMATIONS & GLOWS --- */
@keyframes glow-breathing {
  0%, 100% {
    text-shadow: 0 0 8px rgba(245, 158, 11, 0.15), 0 0 15px rgba(245, 158, 11, 0.05);
    filter: drop-shadow(0 0 15px rgba(245, 158, 11, 0.1));
  }
  50% {
    text-shadow: 0 0 25px rgba(245, 158, 11, 0.65), 0 0 40px rgba(245, 158, 11, 0.35);
    filter: drop-shadow(0 0 30px rgba(245, 158, 11, 0.3));
  }
}

.animate-glow-breathing {
  animation: glow-breathing 4s ease-in-out infinite;
}

@keyframes pulse-slow {
  0%, 100% {
    opacity: 0.9;
    filter: brightness(1);
  }
  50% {
    opacity: 1;
    filter: brightness(1.2) drop-shadow(0 0 12px rgba(245, 158, 11, 0.5));
  }
}

.animate-pulse-slow {
  animation: pulse-slow 3s ease-in-out infinite;
}

/* --- GRADIENT SHIMMER BORDER EFFECT --- */
.premium-coupon-card {
  position: relative;
}

.premium-coupon-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 24px; /* match rounded-3xl (24px) */
  padding: 2px; /* width of border */
  background: linear-gradient(135deg, rgba(245,158,11,0.4), rgba(245,158,11,0), rgba(19,200,236,0.3));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  transition: opacity 0.5s ease;
}

.premium-coupon-card:hover::before {
  background: linear-gradient(135deg, rgba(245,158,11,0.9), rgba(245,158,11,0.2), rgba(19,200,236,0.8));
}

/* --- METALLIC GLOWING CARD FOR POPULAR PLANS --- */
.metallic-card {
  position: relative;
  z-index: 10;
}

.metallic-card::before {
  content: '';
  position: absolute;
  inset: -1px;
  border-radius: 24px;
  padding: 2.5px;
  background: linear-gradient(90deg, #13c8ec, #f59e0b, #10b981, #13c8ec);
  background-size: 300% 300%;
  animation: border-flow-glow 8s linear infinite;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.85;
}

.metallic-card:hover::before {
  animation-duration: 4s;
  opacity: 1;
}

@keyframes border-flow-glow {
  0% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
  100% {
    background-position: 0% 50%;
  }
}

/* --- PULSING GLOW BACKGROUNDS --- */
.accent-glow-bg {
  position: relative;
}
.accent-glow-bg::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 140px;
  height: 140px;
  background: radial-gradient(circle, rgba(19, 200, 236, 0.25) 0%, transparent 70%);
  filter: blur(10px);
  pointer-events: none;
  z-index: -1;
  animation: breathing-glow 4s ease-in-out infinite;
}

@keyframes breathing-glow {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.7;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.3);
    opacity: 1;
  }
}



