/* ET Tracking - Custom Styles */

/* Google Fonts Import */
@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap");

/* Global Font */
* {
  font-family: "Inter", sans-serif;
}

/* === ANIMATIONS === */

/* Fade in animation */
.fade-in {
  animation: fadeIn 0.8s ease-in-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Floating animation for no tracking icon */
.no-tracking-icon {
  animation: float 3s ease-in-out infinite;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

/* Spin animation */
@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

/* Progress fill animation */
@keyframes progressFill {
  from {
    transform: scaleX(0);
  }
  to {
    transform: scaleX(1);
  }
}

.progress-animated {
  transform-origin: left center;
  animation: progressFill 1.5s ease-out forwards;
}

/* Pulse animation for active steps */
.step-active {
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(2, 175, 171, 0.7);
  }
  70% {
    box-shadow: 0 0 0 10px rgba(2, 175, 171, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(2, 175, 171, 0);
  }
}

/* === COMPONENTS === */

/* Step styles */
.step-active {
  background: linear-gradient(135deg, #02afab, #059669);
}

.step-inactive {
  background: #e5e7eb;
}

/* Loading spinner */
.loading-spinner {
  border: 3px solid #f3f3f3;
  border-top: 3px solid #02afab;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

.loading-spinner::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  right: 2px;
  bottom: 2px;
  border-radius: 50%;
  border: 2px solid transparent;
  border-top: 2px solid rgba(2, 175, 171, 0.3);
  animation: spin 2s linear infinite reverse;
}

/* WhatsApp button */
.whatsapp-btn {
  background: linear-gradient(135deg, #25d366, #128c7e);
  transition: all 0.3s ease;
}

.whatsapp-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 25px rgba(37, 211, 102, 0.3);
}

/* Product cards */
.product-card {
  transition: all 0.3s ease;
  position: relative;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.product-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    135deg,
    rgba(2, 175, 171, 0.1),
    rgba(2, 175, 171, 0.2)
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  border-radius: inherit;
}

.product-card:hover::before {
  opacity: 1;
}

/* Info list items */
.info-list-item {
  transition: all 0.3s ease;
}

.info-list-item:hover {
  transform: translateX(5px);
  background-color: rgba(2, 175, 171, 0.1);
  border-radius: 0.5rem;
  padding: 0.5rem;
  margin: -0.5rem;
}

/* === GRADIENTS === */

.gradient-bg {
  background: linear-gradient(135deg, #02afab 0%, #029b97 100%);
}

.gradient-green {
  background: linear-gradient(135deg, #02afab 0%, #38ef7d 100%);
}

/* === SCROLLBAR === */

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: #02afab;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #029b97;
}

/* === ACCESSIBILITY === */

.whatsapp-btn:focus,
button:focus,
a:focus {
  outline: 2px solid #02afab;
  outline-offset: 2px;
}

/* Text shadow for readability */
.text-shadow {
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* === MOBILE RESPONSIVE === */

@media (max-width: 768px) {
  .step-item {
    margin-bottom: 1rem;
  }

  .step-item:last-child {
    margin-bottom: 0;
  }

  /* Mobile vertical progress styling */
  .step-connector-mobile {
    background-color: #e5e7eb; /* Stesso colore dei pallini inattivi (gray-200) */
    transition: background-color 0.3s ease;
  }

  .step-connector-mobile.step-active {
    background-color: #02afab;
  }

  /* Mobile step items alignment */
  .step-item-mobile {
    width: 100%;
    max-width: 200px;
  }

  .step-item-mobile .w-12 {
    width: 3rem !important;
    height: 3rem !important;
    margin-bottom: 0 !important;
  }
  .step-item .w-12 {
    width: 3rem; /* 48px */
    height: 3rem; /* 48px */
    margin-bottom: 0.75rem; /* Ridotto spacing */
  }

  /* Compact mobile touch targets */
  .whatsapp-btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
  }

  /* Compact spacing for mobile cards */
  .product-card {
    padding: 1rem 0.75rem;
  }
}

/* Enhanced mobile typography and layout */
@media (max-width: 640px) {
  h1 {
    font-size: 1.5rem;
    line-height: 1.4;
  }

  h2 {
    font-size: 1.25rem;
    line-height: 1.4;
  }

  h3 {
    font-size: 1.125rem;
    line-height: 1.4;
  }

  /* Progress bar extra mobile styling */
  .step-item p {
    font-size: 0.875rem; /* Testo più piccolo */
    line-height: 1.3;
  }

  /* Padding ridotto per steps su mobile molto piccolo */
  .step-item .w-12 {
    width: 2.5rem; /* 40px */
    height: 2.5rem; /* 40px */
  }
}
