/* ============================================================
   Singdia — How It Works (block 5)
   4 steps: Pick Language → Describe → Choose Genre → Get 2 Versions
   ============================================================ */

.how {
  position: relative;
  padding: 110px 0 130px;
  background:
    linear-gradient(180deg, var(--cream) 0%, var(--cream-warm) 100%);
  overflow: hidden;
}
.how__bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.how__bg::before {
  content: '';
  position: absolute;
  width: 600px;
  height: 600px;
  top: -200px;
  left: 50%;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(217, 164, 65, 0.14) 0%, transparent 70%);
  filter: blur(60px);
}

.how__inner {
  position: relative;
  z-index: 1;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 32px;
}

.how__head {
  text-align: center;
  margin-bottom: 64px;
}
.how__head .eyebrow {
  justify-content: center;
  margin-bottom: 18px;
}
.how__head .eyebrow::before { display: none; }
.how__head .eyebrow::after {
  content: '';
  width: 18px;
  height: 1px;
  background: var(--saffron);
}
.how__title {
  font-family: var(--font-display);
  font-size: clamp(34px, 4vw, 56px);
  font-weight: 400;
  line-height: 1.04;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
  text-wrap: balance;
}
.how__title em {
  font-style: italic;
  font-weight: 500;
  color: var(--maroon);
}
.how__subtitle {
  margin: 14px 0 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* Steps grid */
.how__steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  position: relative;
}

/* Connecting dashed line behind cards (desktop only) */
.how__steps::before {
  content: '';
  position: absolute;
  top: 64px;
  left: 8%;
  right: 8%;
  height: 1px;
  background-image: linear-gradient(
    90deg,
    rgba(217,164,65,0.45) 0%,
    rgba(217,164,65,0.45) 50%,
    transparent 50%
  );
  background-size: 14px 1px;
  background-repeat: repeat-x;
  z-index: 0;
}

.how__card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(107, 18, 49, 0.08);
  border-radius: 24px;
  padding: 28px 24px 28px;
  box-shadow: 0 16px 32px -20px rgba(74, 8, 32, 0.2);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.how__card:hover {
  transform: translateY(-4px);
  box-shadow: 0 26px 48px -22px rgba(74, 8, 32, 0.35);
}

.how__number {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  margin-bottom: 18px;
  background: linear-gradient(135deg, var(--cream) 0%, #fef3df 100%);
  border-radius: 50%;
  position: relative;
}
.how__number::after {
  content: '';
  position: absolute;
  inset: -3px;
  border-radius: 50%;
  border: 1px dashed rgba(217, 164, 65, 0.4);
  pointer-events: none;
}
.how__number img {
  width: 56px;
  height: 56px;
  object-fit: contain;
  display: block;
}

.how__step-title {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: -0.005em;
  color: var(--ink);
  margin: 0 0 12px;
  text-wrap: balance;
}
.how__step-title em {
  font-style: italic;
  color: var(--maroon);
}

.how__step-desc {
  font-size: 14.5px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin: 0;
  text-wrap: pretty;
}

/* CTA strip */
.how__cta {
  margin-top: 56px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.how__cta-note {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* ============================================================
   Tablet
   ============================================================ */
@media (max-width: 980px) {
  .how__steps {
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
  }
  .how__steps::before {
    display: none;
  }
}

/* Mobile */
@media (max-width: 640px) {
  .how {
    padding: 72px 0 88px;
  }
  .how__inner {
    padding: 0 18px;
  }
  .how__head {
    margin-bottom: 40px;
  }
  .how__steps {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .how__card {
    padding: 22px 22px;
    flex-direction: row;
    align-items: flex-start;
    gap: 18px;
  }
  .how__number {
    width: 60px;
    height: 60px;
    margin-bottom: 0;
    flex-shrink: 0;
  }
  .how__number img {
    width: 40px;
    height: 40px;
  }
  .how__step-title {
    font-size: 18px;
    margin-bottom: 8px;
  }
  .how__step-desc {
    font-size: 14px;
  }
  .how__cta {
    margin-top: 36px;
  }
}
