/* =========================================
   how-it-work.css — section Como Funciona
   (fundo igual ao our-services + steps + badges)
   ========================================= */

.how-it-work {
  padding: clamp(10px, 2vw, 24px) 0;
}

.how-it-work__surface {
  position: relative;
  border-radius: 26px;
  overflow: hidden;

  background: #f4f6fb;
  border: 1px solid rgba(11, 18, 32, 0.06);
  box-shadow: 0 22px 70px rgba(11, 18, 32, 0.10);

  padding: clamp(26px, 4vw, 44px);
  isolation: isolate;
}

.how-it-work__surface::before,
.how-it-work__surface::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}

.how-it-work__surface::before {
  background:
    radial-gradient(900px 620px at 12% 10%, rgba(11, 18, 32, 0.14), transparent 60%),
    radial-gradient(900px 620px at 92% 92%, rgba(255, 106, 138, 0.16), transparent 60%);
  opacity: 1;
}

.how-it-work__surface::after {
  opacity: 0.10;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='180' height='180' filter='url(%23n)' opacity='.6'/%3E%3C/svg%3E");
}

.how-it-work__surface > * {
  position: relative;
  z-index: 1;
}

/* head */
.how-it-work__head {
  text-align: center;
  max-width: 900px;
  margin: 0 auto 28px;
}

.how-it-work__kicker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 14px;
}

.how-it-work__kickerIcon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--c-accent);
}

.how-it-work__kickerIcon svg {
  width: 18px;
  height: 18px;
}

.how-it-work__kickerText {
  font-size: 12px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(11, 18, 32, 0.62);
}

.how-it-work__title {
  margin: 0;
  font-size: clamp(28px, 3.6vw, 46px);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.12;
  color: var(--c-text);
}

/* steps grid */
.how-it-work__steps {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(14px, 2.2vw, 24px);
  margin-top: 18px;
}

/* step item */
.work-step {
  text-align: center;
  padding: 18px 14px 12px;
  border-radius: 18px;

  background: rgba(255, 255, 255, 0.0);
  border: 1px solid rgba(11, 18, 32, 0.00);

  transition:
    transform 240ms var(--ease, ease),
    background-color 240ms var(--ease, ease),
    border-color 240ms var(--ease, ease);
}

.work-step:hover {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.45);
  border-color: rgba(11, 18, 32, 0.06);
}

.work-step__tag {
  display: inline-block;
  font-size: 10px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: rgba(11, 18, 32, 0.62);
  margin-bottom: 10px;
}

.work-step__icon {
  width: 62px;
  height: 62px;
  margin: 0 auto 12px;
  display: grid;
  place-items: center;
}

.work-step__icon img {
  width: 58px;
  height: 58px;
  object-fit: contain;
}

.work-step__title {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 850;
  color: var(--c-text);
}

.work-step__text {
  margin: 0;
  font-size: 12px;
  line-height: 1.65;
  color: rgba(11, 18, 32, 0.64);
}

/* divider */
.how-it-work__divider {
  height: 1px;
  border: 0;
  margin: 26px 0 18px;
  background: rgba(11, 18, 32, 0.10);
  opacity: 0.55;
}

/* badges */
.how-it-work__badges {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}

.work-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;

  padding: 10px 14px;
  border-radius: 999px;

  background: rgba(255, 255, 255, 0.60);
  border: 1px solid rgba(11, 18, 32, 0.10);
  box-shadow: 0 12px 34px rgba(11, 18, 32, 0.10);

  font-size: 12px;
  color: rgba(11, 18, 32, 0.78);
}

.work-badge__icon {
  color: var(--c-accent);
  display: inline-flex;
}
.work-badge__icon svg {
  width: 16px;
  height: 16px;
}

/* responsive */
@media (max-width: 1060px) {
  .how-it-work__steps {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 560px) {
  .how-it-work__surface {
    border-radius: 22px;
  }

  .how-it-work__steps {
    grid-template-columns: 1fr;
  }
}

/* =========================================================
   reveal: fallback first
   - sem js: aparece sempre
   - com js: anima via .has-reveal no <html>
   ========================================================= */

/* fallback: visível por padrão */
.how-it-work [data-reveal]{
  opacity: 1;
  transform: none;
  filter: none;
}

/* somente quando o js habilitar */
html.has-reveal .how-it-work [data-reveal]{
  opacity: 0;
  transform: translateY(22px);
  /* blur costuma dar bug de render em alguns Safari/GPUs; se quiser, mantenha, mas com prefixo */
  -webkit-filter: blur(2px);
  filter: blur(2px);

  transition:
    transform 720ms var(--ease, ease),
    opacity 720ms var(--ease, ease),
    filter 720ms var(--ease, ease);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: transform, opacity, filter;
}

html.has-reveal .how-it-work [data-reveal].is-inview{
  opacity: 1;
  transform: translateY(0);
  -webkit-filter: blur(0);
  filter: blur(0);
}

/* acessibilidade */
@media (prefers-reduced-motion: reduce) {
  html.has-reveal .how-it-work [data-reveal]{
    opacity: 1 !important;
    transform: none !important;
    -webkit-filter: none !important;
    filter: none !important;
    transition: none !important;
  }
}