/* ================================================
   HOW IT WORKS SECTION STYLES
   ================================================ */

.how-it-works-section {
  padding: 80px 0;
  background: transparent;
  position: relative;
  overflow: hidden;
}

.how-it-works-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 20% 30%, rgba(var(--secondary-rgb), 0.03) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(var(--theme-rgb), 0.03) 0%, transparent 50%);
  pointer-events: none;
}

.how-it-works-header {
  text-align: center;
  margin-bottom: 4rem;
  position: relative;
  z-index: 2;
}

.how-it-works-title {
  font-size: 2.8rem;
  font-weight: 700;
  color: var(--dark-text);
  margin-bottom: 1.5rem;
  position: relative;
}

.how-it-works-title::after {
  content: "";
  position: absolute;
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 120px;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-gold), var(--accent-gold-dark));
  border-radius: 2px;
}

.how-it-works-subtitle {
  font-size: 1.3rem;
  color: var(--dark-text-muted);
  font-weight: 500;
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.6;
}

.steps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 3rem;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 2;
}

.step-card {
  background: rgba(255, 255, 255, 0.05);
  backdrop-filter: blur(10px);
  border-radius: 20px;
  padding: 2.5rem;
  text-align: center;
  position: relative;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
  transition: all 0.4s ease;
  border: 2px solid rgba(255, 255, 255, 0.1);
  overflow: hidden;
}

.step-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--secondary-color), var(--theme-color));
  transform: scaleX(0);
  transition: transform 0.4s ease;
  transform-origin: left;
  border-radius: 20px 20px 0 0;
}

.step-card:hover::before {
  transform: scaleX(1);
}

.step-card:hover {
  transform: translateY(-10px);
  background: rgba(255, 255, 255, 0.08);
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25);
  border-color: rgba(255, 255, 255, 0.2);
}

.step-number {
  width: 60px; /* kisebb méret */
  height: 60px;
  background: linear-gradient(135deg, var(--secondary-color), var(--theme-color));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 2rem;
  position: relative;
  box-shadow: 0 10px 30px rgba(var(--secondary-rgb), 0.2);
  transition: all 0.3s ease;
}

.step-card:hover .step-number {
  transform: scale(1.1);
  box-shadow: 0 15px 40px rgba(var(--secondary-rgb), 0.3);
}

.step-digit {
  color: var(--bg-white);
  font-size: 1.5rem; /* kisebb szám */
  font-weight: 700;
}

.step-content {
  margin-bottom: 2rem;
}

.step-title {
  color: var(--dark-text);
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 1.5rem;
  line-height: 1.3;
}

.step-description {
  color: var(--dark-text-muted);
  font-size: 1.05rem;
  line-height: 1.7;
  text-align: justify;
  margin: 0;
}

.step-icon {
  width: 60px;
  height: 60px;
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  color: var(--dark-text);
  transition: all 0.3s ease;
}

.step-card:hover .step-icon {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.35);
  transform: scale(1.05);
}

/* Process Connection Lines */
.process-connections {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  height: 2px;
  pointer-events: none;
  z-index: 1;
}

.connection-line {
  position: absolute;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(var(--secondary-rgb), 0.3), transparent);
  top: 0;
}

.connection-1-2 {
  left: 25%;
  width: 25%;
  animation: connectionFlow1 3s ease-in-out infinite;
}

.connection-2-3 {
  left: 58.33%;
  width: 25%;
  animation: connectionFlow2 3s ease-in-out infinite 1.5s;
}

@keyframes connectionFlow1 {
  0%,
  100% {
    opacity: 0.3;
    transform: scaleX(1);
  }
  50% {
    opacity: 0.7;
    transform: scaleX(1.1);
  }
}

@keyframes connectionFlow2 {
  0%,
  100% {
    opacity: 0.3;
    transform: scaleX(1);
  }
  50% {
    opacity: 0.7;
    transform: scaleX(1.1);
  }
}

/* Responsive Design */
@media (max-width: 1199px) {
  .steps-grid {
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2.5rem;
  }

  .step-card {
    padding: 2rem;
  }

  .process-connections {
    display: none; /* Hide connection lines on smaller screens */
  }
}

@media (max-width: 991px) {
  .how-it-works-section {
    padding: 60px 0;
  }

  .how-it-works-title {
    font-size: 2.4rem;
  }

  .how-it-works-subtitle {
    font-size: 1.2rem;
  }

  .how-it-works-header {
    margin-bottom: 3rem;
  }

  .steps-grid {
    gap: 2rem;
  }
}

@media (max-width: 767px) {
  .steps-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .how-it-works-title {
    font-size: 2rem;
  }

  .how-it-works-subtitle {
    font-size: 1.1rem;
  }

  .step-card {
    margin: 0 15px;
    padding: 2rem 1.5rem;
  }

  .step-title {
    font-size: 1.3rem;
  }

  .step-description {
    font-size: 1rem;
    text-align: left;
  }
}

@media (max-width: 575px) {
  .how-it-works-section {
    padding: 50px 0;
  }

  .step-card {
    margin: 0 10px;
    padding: 1.5rem;
  }

  .step-number {
    width: 70px;
    height: 70px;
    margin-bottom: 1.5rem;
  }

  .step-digit {
    font-size: 1.7rem;
  }

  .step-title {
    font-size: 1.2rem;
    margin-bottom: 1rem;
  }

  .step-description {
    font-size: 0.95rem;
  }

  .step-icon {
    width: 60px;
    height: 60px;
  }
}

/* Special animations for step cards */
.step-card:nth-child(1) {
  animation-delay: 0.2s;
}

.step-card:nth-child(2) {
  animation-delay: 0.4s;
}

.step-card:nth-child(3) {
  animation-delay: 0.6s;
}

/* Enhanced hover effect for step progression */
.step-card:hover ~ .step-card {
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.steps-grid:hover .step-card:not(:hover) {
  opacity: 0.8;
  transform: scale(0.98);
}
