/* Animation and Visual Enhancement Styles */

/* Smooth scrolling for the entire page */
html {
  scroll-behavior: smooth;
}

/* Section Background Overlays */
.section-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  pointer-events: none;
  opacity: 0.1;
  z-index: 0;
}

#hero .section-overlay {
  background: 
    radial-gradient(circle at 10% 20%, rgba(52, 152, 219, 0.1), transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(46, 204, 113, 0.1), transparent 40%);
}

#trust-section .section-overlay {
  background: 
    linear-gradient(135deg, rgba(52, 152, 219, 0.05) 0%, transparent 50%),
    linear-gradient(45deg, rgba(46, 204, 113, 0.05) 0%, transparent 50%);
}

#how-it-works .section-overlay {
  background: 
    repeating-linear-gradient(
      45deg,
      rgba(52, 152, 219, 0.03) 0px,
      rgba(52, 152, 219, 0.03) 2px,
      transparent 2px,
      transparent 10px
    );
}

/* Enhanced Section Transitions */
.hero,
.trust-section,
.how-it-works,
.premium {
  position: relative;
  transition: background-color 0.5s ease;
  overflow: hidden;
  background-color: white;
}

/* Enhanced Trust Items */
.trust-item {
  position: relative;
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.trust-item::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--primary-gradient);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.trust-item:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.trust-item:hover::before {
  transform: scaleX(1);
}

/* Enhanced Steps Animation */
.steps-container {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  margin-top: var(--spacing-lg);
  padding: 2rem 0;
  min-height: 300px;
}

.step {
  position: relative;
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: var(--spacing-lg);
  text-align: center;
  background-color: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  z-index: 1;
  margin: 0 1rem;
  height: 100%;
  /* Ensure the element's total width includes its padding, preventing overflow on small screens */
  box-sizing: border-box;
}

.step:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
}

.step-number {
  background: var(--primary-gradient);
  color: white;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0 auto var(--spacing-md);
  font-weight: 700;
  font-size: 1.2rem;
  box-shadow: 0 4px 10px rgba(52, 152, 219, 0.2);
  flex-shrink: 0;
}

.step-title {
  font-weight: 700;
  margin-bottom: var(--spacing-sm);
  font-size: 1.2rem;
  color: var(--text-primary);
  flex-shrink: 0;
}

.step-description {
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 1rem;
  flex-grow: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-connector {
  position: absolute;
  top: 4rem;
  right: -30%;
  width: 60%;
  height: 2px;
  background: linear-gradient(to right, var(--primary-color), var(--secondary-color));
  transform-origin: left;
  z-index: 0;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
  .section-overlay {
    opacity: 0.05;
  }

  .steps-container {
    flex-direction: column;
    gap: var(--spacing-lg);
    padding: 1rem 0;
    min-height: auto;
  }

  .step {
    width: 100%;
    margin: 0 0 var(--spacing-md);
    min-height: 200px;
  }

  .step-connector {
    display: none;
  }

  /* Give the premium card some breathing room on small screens */
  .premium {
    margin-left: var(--spacing-md);
    margin-right: var(--spacing-md);
  }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .section-overlay {
    display: none;
  }
}

/* Extra-small screens (<=480px) */
@media (max-width: 480px) {
  .premium-button {
    display: block;           /* occupies the full line */
    width: 100%;              /* span available width */
    box-sizing: border-box;   /* include padding in total width */
    padding: 12px 20px;       /* reduced horizontal padding */
    font-size: 1rem;          /* slightly smaller text for small screens */
  }
}

/* Premium Section Animations */
.premium {
    position: relative;
    overflow: hidden;
    padding: var(--spacing-xl) var(--spacing-lg);
    background: linear-gradient(135deg, white 0%, #f8f9fa 100%);
    border-radius: var(--radius-lg);
}

.premium::before {
    content: '';
    position: absolute;
    inset: -4px;
    background: linear-gradient(90deg, 
        #3498db,
        #2ecc71,
        #3498db
    );
    background-size: 200% 100%;
    animation: borderMove 5s linear infinite;
    z-index: 0;
    border-radius: inherit;
    mask: linear-gradient(white 0 0) content-box, linear-gradient(white 0 0);
    mask-composite: exclude;
    -webkit-mask: linear-gradient(white 0 0) content-box, linear-gradient(white 0 0);
    -webkit-mask-composite: xor;
    padding: 4px;
}

.premium > * {
    position: relative;
    z-index: 1;
}

@keyframes borderMove {
    0% {
        background-position: 0% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.premium .section-overlay {
    background: 
        radial-gradient(circle at 20% 20%, rgba(52, 152, 219, 0.1), transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(46, 204, 113, 0.1), transparent 50%);
    animation: premiumGlow 8s ease-in-out infinite;
    z-index: 0;
}

@keyframes premiumGlow {
    0% {
        opacity: 0.5;
        transform: scale(1);
    }
    50% {
        opacity: 0.8;
        transform: scale(1.1);
    }
    100% {
        opacity: 0.5;
        transform: scale(1);
    }
}

.premium-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: var(--spacing-md);
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.premium-description {
    font-size: 1.2rem;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

.premium-button {
    display: inline-block;
    background: linear-gradient(90deg, 
        #3498db,
        #2ecc71,
        #3498db
    );
    background-size: 200% 100%;
    animation: buttonGradient 5s linear infinite;
    color: white;
    padding: 18px 40px;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 1.2rem;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
    position: relative;
    overflow: hidden;
    border: none;
}

@keyframes buttonGradient {
    0% {
        background-position: 0% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

.premium-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
}

.premium-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    transition: left 0.5s ease;
}

.premium-button:hover::before {
    left: 100%;
}

/* Add sparkle effect */
.premium::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 20%, white 0%, transparent 0.5%),
        radial-gradient(circle at 80% 80%, white 0%, transparent 0.5%);
    pointer-events: none;
    animation: sparkle 4s linear infinite;
}

@keyframes sparkle {
    0% {
        opacity: 0;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0;
    }
} 