/* Port of ProcessSection.astro scoped styles */

.process-section {
  background-color: var(--surface);
  border-top: 1px solid var(--border);
  overflow: hidden;
  position: relative;
}

.process-section--compact {
  background-color: var(--background);
}

.bg-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 800px;
  height: 300px;
  background: radial-gradient(circle, rgba(27, 84, 216, 0.08) 0%, transparent 80%);
  filter: blur(100px);
  pointer-events: none;
  z-index: 0;
}

.timeline-wrapper {
  position: relative;
  z-index: 1;
  margin-bottom: 16px;
  padding: 12px 0 10px;
  overflow: visible;
}

@media (min-width: 768px) {
  .timeline-wrapper {
    margin-bottom: 64px;
    padding: 20px 0 16px;
  }
}

.connecting-line {
  display: none;
  position: absolute;
  top: 80px;
  left: 10%;
  right: 10%;
  height: 1px;
  background: none;
  border-top: 2px dashed rgba(27, 84, 216, 0.25);
  z-index: 0;
}

@media (min-width: 1024px) {
  .connecting-line {
    display: block;
  }
}

.timeline-grid {
  column-gap: 20px;
  row-gap: 16px;
  grid-template-columns: 1fr;
  width: 100%;
  position: relative;
}

@media (max-width: 767px) {
  .timeline-grid {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    margin: 0 -16px;
    padding: 10px 24px 24px;
    width: auto;
    scrollbar-width: none;
  }

  .timeline-grid::-webkit-scrollbar {
    display: none;
  }
}

@media (min-width: 768px) {
  .timeline-grid {
    grid-template-columns: repeat(8, minmax(0, 1fr));
    row-gap: 24px;
  }
}

@media (min-width: 1024px) {
  .timeline-grid {
    grid-template-columns: repeat(10, minmax(0, 1fr));
    row-gap: 32px;
  }
}

.timeline-item-container {
  grid-column: span 1;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  position: relative;
  z-index: 1;
}

@media (max-width: 767px) {
  .timeline-item-container {
    flex: 0 0 76%;
    max-width: 300px;
    scroll-snap-align: center;
    margin-right: 12px;
  }

  .timeline-item-container:last-child {
    margin-right: 0;
  }
}

@media (min-width: 768px) {
  .timeline-item-container {
    grid-column: span 4;
  }
}

@media (min-width: 1024px) {
  .timeline-item-container {
    grid-column: span 2;
  }
}

/* ─── Dots (mobile) ───────────────────────────────────────── */
.process-dots {
  display: none;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: -16px;
  margin-bottom: 32px;
}

@media (max-width: 767px) {
  .process-dots {
    display: flex;
  }
}

.process-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--border, rgba(255, 255, 255, 0.12));
  border: none;
  cursor: pointer;
  padding: 0;
  transition: background-color 0.25s, transform 0.25s, width 0.25s;
}

.process-dot--active {
  background: var(--primary, #1B54D8);
  width: 24px;
  border-radius: 4px;
}

/* ─── Timeline card ───────────────────────────────────────── */
.step-num-display {
  position: absolute;
  top: 16px;
  right: 24px;
  font-size: clamp(40px, 5vw, 64px);
  font-weight: 900;
  letter-spacing: -0.04em;
  color: var(--decorative-faint);
  font-variant-numeric: tabular-nums;
  line-height: 1;
  display: block;
  user-select: none;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), color 0.3s ease;
}

.timeline-card {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 16px !important;
  overflow: visible !important;
}

@media (min-width: 768px) {
  .timeline-card {
    gap: 14px;
    padding: 24px !important;
  }
}

.timeline-card:hover {
  border-color: rgba(27, 84, 216, 0.30);
}

.timeline-card:hover .step-num-display {
  color: var(--primary-hover);
  transform: translateY(calc(-50% - 16px));
}

.icon-circle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background-color: rgba(27, 84, 216, 0.12);
  border: 1px solid rgba(27, 84, 216, 0.20);
  flex-shrink: 0;
}

@media (min-width: 768px) {
  .icon-circle {
    width: 44px;
    height: 44px;
    border-radius: 12px;
  }
}

.icon-circle svg {
  color: var(--primary-hover);
}

.step-title {
  color: var(--heading);
  margin: 0;
  font-size: 14px;
  letter-spacing: -0.02em;
}

@media (min-width: 768px) {
  .step-title {
    font-size: 17px;
  }
}

.step-desc {
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}

@media (min-width: 768px) {
  .step-desc {
    font-size: 14px;
    line-height: 1.65;
  }
}

/* ─── CTA ─────────────────────────────────────────────────── */
.cta-container {
  margin-top: 48px;
  position: relative;
  z-index: 1;
}
