/* ---- STICKY WRAPPER ---- */

.process-section {
  position: relative !important;
  z-index: 1000 !important;
}

.sticky-section {
  position: relative;
  height: 350vh;
  z-index: 100;
}

.sticky-inner {
  position: sticky;
  top: 0;
  height: 90vh;
  display: flex;
  justify-content: space-between;
  align-items: center;
  overflow: hidden;
  gap: 1rem;
  padding-top: 50px;
}

/* ---- LEFT CONTENT ---- */
.left-content {
  width: 100%;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2rem;
  height: 100vh;
}

/* ---- CENTER PHONE ---- */
.phone-wrap {
  width: 25%;
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
  flex-shrink: 0;
  /* margin-top: 20px; */
}

.phone-frame {
  position: relative;
  z-index: 2;
  /* KEY FIX: height based on viewport */
  height: 80vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* KEY FIX: phone shell uses vh - adapts to all screen sizes */
.phone-shell {
  /* aspect ratio 9:18.5 like a real phone */
  height: 78vh;
  width: calc(78vh * (9 / 19.5));
  max-height: 620px;
  max-width: 300px;
  min-height: 380px;
  min-width: 175px;
  border-radius: 40px;
  position: relative;
  box-shadow: rgba(0, 0, 0, 0.24) 0px 3px 8px;
}

/* .phone-shell::before {
  content: "";
  position: absolute;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  width: 30%;
  height: 3.5%;
  background: #111;
  border-radius: 0 0 16px 16px;
  z-index: 10;
} */

.phone-screen {
  width: 100%;
  height: 100%;
  border-radius: 30px;
  overflow: hidden;
  background: #f5f5f5;
  position: relative;
}

.phone-screen img {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  transition: opacity 0.5s ease;
  object-fit: cover;
}

.phone-screen img.active {
  opacity: 1;
}

/* ---- RIGHT CONTENT ---- */
.right-content {
  width: 100%;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2rem;
  height: 100vh;
}

/* ---- STEP CARDS ---- */
.step-card {
  position: relative;
  opacity: 0;
  max-height: 0;
  overflow: hidden;
  transition:
    opacity 0.5s ease,
    max-height 0.6s ease;
  pointer-events: none;
}

.step-card.active {
  opacity: 1;
  max-height: 300px;
  pointer-events: auto;
}

.step-card .step-number {
  font-size: 20px;
  font-weight: 700;
  color: #144f93;
  margin-bottom: 0.5rem;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #828282;
  padding-bottom: 10px;
  display: block;
}

.step-card p {
  font-size: 17px;
  color: #555;
  line-height: 1.7;
  margin-top: 0.5rem;
}

.left-content .step-card {
  text-align: end;
}

/* ---- BOTTOM CELEBRATE ---- */
.sticky-only-bottom {
  text-align: center;
  padding: 10px 1rem;
  background: #fff;
  opacity: 0;
  transition: opacity 0.6s ease;
}

.sticky-only-bottom.active {
  opacity: 1;
}

.bottom-line-sitcky {
  width: 360px;
  height: 2px;
  background: #828282;
  margin: 0.5rem auto;
}

.sticky-only-bottom .step-number {
  font-size: 20px;
  font-weight: 700;
  color: #144f93;
  margin-bottom: 0.5rem;
  letter-spacing: 0.05em;
  padding-bottom: 13px;
  display: block;
}

/* ---- PROGRESS DOTS ---- */
.progress-dots {
  position: fixed;
  right: 1.5rem;
  top: 50%;
  transform: translateY(-50%);
  display: flex;
  flex-direction: column;
  gap: 10px;
  z-index: 100;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #ddd;
  transition:
    background 0.3s,
    transform 0.3s;
  cursor: pointer;
}

.dot.active {
  background: #1a73e8;
  transform: scale(1.4);
}

/* =====================
   DESKTOP BREAKPOINTS
   - small laptop to large monitor fix
===================== */

/* Small laptop - 1024px to 1280px */
@media (min-width: 1024px) and (max-width: 1280px) {
  .phone-shell {
    height: 72vh;
    width: calc(72vh * (9 / 19.5));
    max-height: 520px;
    max-width: 245px;
  }

  .step-card .step-number {
    font-size: 17px;
  }

  .step-card p {
    font-size: 15px;
  }
}

/* Medium desktop - 1280px to 1440px */
@media (min-width: 1280px) and (max-width: 1440px) {
  .phone-shell {
    height: 75vh;
    width: calc(75vh * (9 / 18.5));
    max-height: 570px;
    max-width: 268px;
  }
}

/* Large desktop - 1440px to 1920px */
@media (min-width: 1440px) and (max-width: 1920px) {
  .phone-shell {
    height: 78vh;
    width: calc(78vh * (9 / 19.5));
    max-height: 620px;
    max-width: 290px;
  }
}

/* 4K / Large monitor - 1920px+ */
@media (min-width: 1920px) {
  .phone-shell {
    height: 75vh;
    width: calc(75vh * (9 / 19.5));
    max-height: 700px;
    max-width: 325px;
  }

  .step-card .step-number {
    font-size: 22px;
  }

  .step-card p {
    font-size: 18px;
  }
}

/* =====================
   TABLET - 992px
===================== */
@media (max-width: 992px) {
  .sticky-section {
    height: auto;
  }

  .sticky-inner {
    position: relative;
    height: auto;
    flex-direction: column;
    align-items: center;
    padding: 2rem 1rem;
    gap: 2rem;
  }

  .left-content,
  .right-content {
    width: 100%;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: center;
    height: auto;
    padding: 0;
  }

  .left-content .step-card,
  .right-content .step-card {
    text-align: left;
    max-height: none !important;
    opacity: 1 !important;
    pointer-events: auto;
    width: calc(50% - 1rem);
  }

  .phone-wrap {
    width: 100%;
    height: auto;
    padding: 1rem 0;
  }

  .phone-shell {
    height: 420px;
    width: 200px;
    max-height: none;
    max-width: none;
    min-height: none;
    min-width: none;
  }

  .progress-dots {
    display: none;
  }

  .bottom-line-sitcky {
    width: 100%;
    max-width: 360px;
  }

  .step-card .step-number,
  .step-number {
    font-size: 18px;
    width: 100%;
  }

  .sticky-only-bottom {
    opacity: 1;
  }
}

/* =====================
   MOBILE - 576px
===================== */
@media (max-width: 576px) {
  .sticky-inner {
    padding: 1.5rem 1rem;
  }

  .left-content .step-card,
  .right-content .step-card {
    width: 100%;
  }

  .phone-shell {
    height: 340px;
    width: 160px;
  }

  .phone-shell::before {
    width: 60px;
    height: 18px;
  }

  .step-card .step-number,
  .step-number {
    font-size: 18px;
    width: 100%;
  }

  .sticky-only-bottom {
    text-align: start;
    opacity: 1;
  }

  .bottom-line-sitcky {
    width: 100% !important;
    height: 1px;
    margin: 0px;
  }

  .sticky-only-bottom .step-number {
    font-size: 18px;
  }

  .sticky-only-bottom .bottom-sticky-para {
    font-size: 15px;
  }

  .step-card p {
    font-size: 15px;
  }
  .phone-wrap {
    width: 100%;
    height: 30vh;
    padding: 1rem 0;
  }
}
