/**
 * VIP How It Works V2 - Premium 2025 UX/UI Styles
 * Features: Glassmorphism, Micro-animations, Scroll-triggered effects
 * 
 * @package VIP_Theme
 */

/* ========================================
   MAIN CONTAINER
   ======================================== */

.vip-how-it-works-v2 {
  position: relative;
  padding: 6rem 2rem;
  overflow: hidden;
}

/* Background Ambient Glow */
.vip-how-it-works-v2::before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(214, 183, 123, 0.08) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

/* ========================================
   SECTION HEADER
   ======================================== */

.vip-hiw-header {
  text-align: center;
  margin-bottom: 5rem;
  position: relative;
  z-index: 1;
}

.vip-hiw-title {
  font-family: 'Montserrat', sans-serif;
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  background: linear-gradient(135deg, #D6B77B 0%, #F2E6C9 50%, #D6B77B 100%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 1.5rem;
  letter-spacing: -0.02em;
  animation: shimmer 3s ease-in-out infinite;
}

@keyframes shimmer {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

.vip-hiw-subtitle {
  font-family: 'Manrope', sans-serif;
  font-size: clamp(1rem, 2vw, 1.25rem);
  color: var(--secondary-text, #B7B7C2);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ========================================
   STEPS CONTAINER - TIMELINE LAYOUT
   ======================================== */

.vip-hiw-layout--timeline .vip-hiw-steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1400px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  padding-bottom: 6rem; /* Increased space for progress line and card shadows */
}

/* ========================================
   STEPS CONTAINER - CARDS LAYOUT
   ======================================== */

.vip-hiw-layout--cards .vip-hiw-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 3rem;
  max-width: 1509px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  padding-bottom: 4rem; /* Space for card shadows */
}

.vip-hiw-layout--cards .vip-hiw-connector {
  display: none;
}

/* ========================================
   STEPS CONTAINER - VERTICAL LAYOUT
   ======================================== */

.vip-hiw-layout--vertical .vip-hiw-steps {
  display: flex;
  flex-direction: column;
  gap: 3rem;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
  padding-bottom: 4rem; /* Space for card shadows */
}

.vip-hiw-layout--vertical .vip-hiw-connector {
  transform: rotate(90deg);
  margin: 1rem 0;
}

/* ========================================
   PROGRESS LINE (Timeline only) - AT ARROW POSITION
   ======================================== */

.vip-hiw-progress-line {
  position: absolute;
  bottom: -2rem; /* Position at arrow level (below cards) */
  left: 10%;
  right: 10%;
  height: 4px; /* Slightly thicker */
  background: rgba(214, 183, 123, 0.15);
  border-radius: 10px;
  overflow: hidden;
  z-index: 0; /* Below cards */
}

.vip-hiw-layout--cards .vip-hiw-progress-line,
.vip-hiw-layout--vertical .vip-hiw-progress-line {
  display: none;
}

.vip-hiw-progress-fill {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #D6B77B 0%, #F2E6C9 50%, #D6B77B 100%);
  background-size: 200% 100%;
  border-radius: 10px;
  box-shadow: 0 0 20px rgba(214, 183, 123, 0.6);
  transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Progress line grows with card visibility */
.vip-hiw-progress-fill.step-1-visible {
  width: 33.33%; /* First third when card 1 visible */
}

.vip-hiw-progress-fill.step-2-visible {
  width: 66.66%; /* Two thirds when card 2 visible */
}

.vip-hiw-progress-fill.step-3-visible {
  width: 100%; /* Full width when card 3 visible */
}

@keyframes shimmerFlow {
  0%, 100% { background-position: 0% center; }
  50% { background-position: 100% center; }
}

/* ========================================
   INDIVIDUAL STEP
   ======================================== */

.vip-hiw-step {
  position: relative;
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* ========================================
   STEP CARD - GLASSMORPHISM - EQUAL HEIGHT/WIDTH
   ======================================== */

.vip-hiw-card {
  position: relative;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(214, 183, 123, 0.2);
  border-radius: 24px;
  padding: 2.5rem 2rem;
  transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
  overflow: hidden;
  flex: 1;
  min-height: 420px; /* Fixed minimum height for consistency */
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  z-index: 10; /* Above progress line */
}

.vip-hiw-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, transparent, #D6B77B, transparent);
  opacity: 0;
  transition: opacity 0.5s ease;
}

.vip-hiw-card:hover {
  transform: translateY(-12px) scale(1.02);
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(214, 183, 123, 0.5);
  box-shadow: 
    0 20px 60px rgba(0, 0, 0, 0.4),
    0 0 40px rgba(214, 183, 123, 0.2);
}

.vip-hiw-card:hover::before {
  opacity: 1;
}

/* ========================================
   ICON WRAPPER - FLOATING EFFECT
   ======================================== */

.vip-hiw-icon-wrapper {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 0 auto 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Pulse Effect */
.vip-hiw-icon-pulse {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 100%;
  height: 100%;
  border-radius: 50%;
  background: rgba(214, 183, 123, 0.3);
  animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% {
    transform: translate(-50%, -50%) scale(1);
    opacity: 0.5;
  }
  50% {
    transform: translate(-50%, -50%) scale(1.3);
    opacity: 0;
  }
}

/* Icon Background */
.vip-hiw-icon-bg {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 80px;
  height: 80px;
  background: linear-gradient(135deg, rgba(214, 183, 123, 0.2) 0%, rgba(242, 230, 201, 0.1) 100%);
  border: 2px solid rgba(214, 183, 123, 0.4);
  border-radius: 50%;
  transition: all 0.4s ease;
}

.vip-hiw-card:hover .vip-hiw-icon-bg {
  transform: translate(-50%, -50%) rotate(180deg) scale(1.1);
  background: linear-gradient(135deg, rgba(214, 183, 123, 0.3) 0%, rgba(242, 230, 201, 0.2) 100%);
  border-color: rgba(214, 183, 123, 0.6);
  box-shadow: 0 0 30px rgba(214, 183, 123, 0.4);
}

/* Icon - Properly Styled for All Iconoir Icons */
.vip-hiw-icon {
  position: relative;
  font-size: 2.5rem;
  color: #D6B77B;
  z-index: 2;
  transition: all 0.4s ease;
  filter: drop-shadow(0 4px 8px rgba(214, 183, 123, 0.3));
  display: inline-block;
  line-height: 1;
}

/* Ensure all Iconoir icons are visible */
.vip-hiw-icon::before {
  display: inline-block;
  font-family: 'iconoir' !important;
  font-style: normal;
  font-weight: normal;
  font-variant: normal;
  text-transform: none;
  line-height: 1;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.vip-hiw-card:hover .vip-hiw-icon {
  color: #F2E6C9;
  transform: scale(1.15);
  filter: drop-shadow(0 8px 16px rgba(214, 183, 123, 0.5));
}

/* Specific icon styles for better visibility */
i[class*="iconoir-"] {
  display: inline-block;
  font-style: normal;
  line-height: 1;
}

/* Make sure icons inherit color properly */
.vip-hiw-icon-wrapper i {
  color: inherit;
}

/* Step Number Badge */
.vip-hiw-number {
  position: absolute;
  top: -8px;
  right: -8px;
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, #D6B77B 0%, #F2E6C9 100%);
  color: #0B0B0C;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.875rem;
  font-weight: 700;
  z-index: 3;
  box-shadow: 0 4px 12px rgba(214, 183, 123, 0.4);
  transition: all 0.3s ease;
}

.vip-hiw-card:hover .vip-hiw-number {
  transform: scale(1.2) rotate(360deg);
  box-shadow: 0 6px 20px rgba(214, 183, 123, 0.6);
}

/* ========================================
   CONTENT
   ======================================== */

.vip-hiw-content {
  text-align: center;
}

.vip-hiw-step-title {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--pure-white, #FAFAFA);
  margin-bottom: 1rem;
  transition: color 0.3s ease;
}

.vip-hiw-card:hover .vip-hiw-step-title {
  color: #F2E6C9;
}

.vip-hiw-step-desc {
  font-family: 'Manrope', sans-serif;
  font-size: 1rem;
  color: var(--secondary-text, #B7B7C2);
  line-height: 1.6;
  margin: 0;
}

/* ========================================
   DECORATIVE GLOW
   ======================================== */

.vip-hiw-glow {
  position: absolute;
  bottom: -50%;
  left: 50%;
  transform: translateX(-50%);
  width: 200px;
  height: 200px;
  background: radial-gradient(circle, rgba(214, 183, 123, 0.15) 0%, transparent 70%);
  opacity: 0;
  transition: opacity 0.5s ease;
  pointer-events: none;
}

.vip-hiw-card:hover .vip-hiw-glow {
  opacity: 1;
}

/* ========================================
   CONNECTOR ARROW
   ======================================== */

.vip-hiw-connector {
  flex-shrink: 0;
  width: 100px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0.7;
  transition: opacity 0.3s ease;
  position: relative;
  z-index: 5; /* Above progress line, below cards */
}

.vip-hiw-connector:hover {
  opacity: 1;
}

.vip-hiw-arrow {
  width: 100%;
  height: 100%;
}

/* ========================================
   ANIMATIONS - SEQUENTIAL CARD APPEARANCE
   ======================================== */

.vip-hiw-animated .vip-hiw-step {
  opacity: 0;
  transform: translateY(40px);
}

.vip-hiw-animated .vip-hiw-step.vip-hiw-visible {
  animation: fadeInUp 0.8s cubic-bezier(0.4, 0, 0.2, 1) forwards;
}

/* Sequential delays - Card 1 instant, Card 2 after Card 1, Card 3 after Card 2 */
.vip-hiw-animated .vip-hiw-step:nth-child(1) { 
  animation-delay: 0s; /* Card 1 appears instantly */
}

.vip-hiw-animated .vip-hiw-step:nth-child(2) { 
  animation-delay: 0.6s; /* Card 2 appears 0.6s after Card 1 */
}

.vip-hiw-animated .vip-hiw-step:nth-child(3) { 
  animation-delay: 1.2s; /* Card 3 appears 0.6s after Card 2 */
}

@keyframes fadeInUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ========================================
   RESPONSIVE DESIGN
   ======================================== */

@media (max-width: 1024px) {
  .vip-hiw-layout--timeline .vip-hiw-steps {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
  
  .vip-hiw-connector {
    display: none;
  }
  
  .vip-hiw-progress-line {
    display: none;
  }
}

@media (max-width: 768px) {
  .vip-how-it-works-v2 {
    padding: 4rem 1rem;
  }
  
  .vip-hiw-header {
    margin-bottom: 3rem;
  }
  
  .vip-hiw-title {
    font-size: 2rem;
  }
  
  .vip-hiw-subtitle {
    font-size: 1rem;
  }
  
  .vip-hiw-card {
    padding: 2rem 1.5rem;
  }
  
  .vip-hiw-icon-wrapper {
    width: 80px;
    height: 80px;
  }
  
  .vip-hiw-icon-bg {
    width: 64px;
    height: 64px;
  }
  
  .vip-hiw-icon {
    font-size: 2rem;
  }
  
  .vip-hiw-number {
    width: 32px;
    height: 32px;
    font-size: 0.75rem;
  }
  
  .vip-hiw-step-title {
    font-size: 1.25rem;
  }
  
  .vip-hiw-step-desc {
    font-size: 0.9rem;
  }
}

/* ========================================
   DARK MODE ENHANCEMENTS
   ======================================== */

@media (prefers-color-scheme: dark) {
  .vip-hiw-card {
    background: rgba(255, 255, 255, 0.04);
  }
  
  .vip-hiw-card:hover {
    background: rgba(255, 255, 255, 0.08);
  }
}

/* ========================================
   ACCESSIBILITY
   ======================================== */

@media (prefers-reduced-motion: reduce) {
  .vip-hiw-card,
  .vip-hiw-icon,
  .vip-hiw-icon-bg,
  .vip-hiw-number,
  .vip-hiw-step {
    animation: none !important;
    transition: none !important;
  }
  
  .vip-hiw-icon-pulse {
    display: none;
  }
}

/* Focus States for Accessibility - REMOVED PER USER REQUEST */
.vip-hiw-card:focus-within {
  outline: none !important;
}

/* ========================================
   FOOTER PAYMENT BADGES - INLINE WITH COPYRIGHT
   ======================================== */

.copyright-content-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.copyright-content {
  flex: 1;
}

.footer-badges-inline {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.badge-link {
  display: inline-block;
  transition: transform 0.3s ease;
  line-height: 0;
}

.badge-link:hover {
  transform: translateY(-4px);
}

.badge-img {
  max-height: 46px;
  width: auto;
  object-fit: contain;
  height: 44px;
}

/* Footer Bottom Grid Layout */
.footer-bottom {
  border-top: 1px solid #000 !important;
}

.footer-bottom .container,
.footer-bottom > div {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  max-width: 100rem;
  margin: 0 auto;
  padding: 0 0rem;
  margin-top: 6px;
}

.copyright-content {
  background: transparent !important;
  padding: 0 0rem 0rem 0rem !important;
  margin: 0 !important;
  border-radius: 0 !important;
}

.copyright-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  align-items: center;
  max-width: 100rem;
  margin: 0 auto;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  .footer-bottom .container,
  .footer-bottom > div {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .copyright-content-wrapper {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }
  
  .copyright-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }
  
  .footer-badges-inline {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .footer-bottom .container,
  .footer-bottom > div {
    padding: 0 1rem;
    gap: 1.5rem;
  }
  
  .copyright-grid {
    gap: 1rem;
  }
  
  .badge-img {
    max-height: 40px;
    height: 38px;
  }
  
  .footer-badges-inline {
    gap: 0.75rem;
  }
}
