/* Homepage story section — layout unchanged, cards and spacing refined */

.path-story {
  width: 100%;
  max-width: 1584px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 112px;
}

.path-story__title {
  margin: 0;
  color: var(--color-text);
  font-family: var(--font-heading) !important;
  font-size: 60px;
  font-weight: 400;
  line-height: 1.05;
  letter-spacing: -1.12px;
  text-align: center;
}

.path-story__title-accent {
  font-family: var(--font-heading) !important;
  font-style: italic;
  background-image: var(--gold-texture) !important;
  background-size: cover !important;
  background-position: center !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent !important;
  color: transparent !important;
}

.path-story__lede {
  margin: 20px auto 0;
  max-width: 58ch;
  color: var(--color-text-muted);
  font-family: var(--font-body) !important;
  font-size: var(--ui-text);
  font-weight: 400 !important;
  line-height: 1.55;
  text-align: center;
}

.path-gold-frame {
  position: relative;
  isolation: isolate;
}

.path-gold-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: var(--gold-texture) center / cover no-repeat;
  -webkit-mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask:
    linear-gradient(#fff 0 0) content-box,
    linear-gradient(#fff 0 0);
  mask-composite: exclude;
  pointer-events: none;
  z-index: 4;
}

/* ── Why Pathfyndr ── */
.path-why {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.path-why__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 28px;
  width: 100%;
  margin-top: 56px;
}

.path-why__card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-width: 0;
  min-height: 428px;
  border-radius: 6px;
  overflow: hidden;
  isolation: isolate;
  background: #050915;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.32);
  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.35s ease,
    filter 0.35s ease;
}

.path-why__card:hover {
  transform: translateY(-4px);
  box-shadow:
    0 0 0 1px rgba(229, 190, 1, 0.35),
    0 24px 48px rgba(0, 0, 0, 0.42);
  filter: brightness(1.04);
}

.path-why__photo {
  position: absolute;
  inset: 0;
  margin: 0;
  border-radius: 0;
  overflow: hidden;
  z-index: 1;
}

.path-why__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
  transform: scale(1.02);
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.path-why__card:hover .path-why__photo img {
  transform: scale(1.08);
}

.path-why__photo::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(5, 9, 21, 0.97) 0%,
    rgba(5, 9, 21, 0.88) 28%,
    rgba(5, 9, 21, 0.52) 52%,
    rgba(5, 9, 21, 0.18) 72%,
    rgba(5, 9, 21, 0.08) 100%
  );
  pointer-events: none;
}

.path-why__body {
  position: relative;
  z-index: 3;
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px 22px 24px;
}

.path-why__label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 14px;
  color: var(--color-text);
}

.path-why__icon {
  width: 48px;
  height: 48px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(229, 190, 1, 0.45);
  background: rgba(5, 9, 21, 0.55);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.28);
}

.path-why__icon img {
  width: 24px;
  height: 24px;
  display: block;
  object-fit: contain;
}

.path-why__name {
  margin: 0;
  color: var(--color-text) !important;
  -webkit-text-fill-color: var(--color-text) !important;
  background: none !important;
  background-image: none !important;
  font-family: var(--font-heading) !important;
  font-size: 26px;
  font-weight: 400 !important;
  line-height: 1.15;
  letter-spacing: -0.02em;
  text-transform: none;
}

.path-why__name::after {
  content: "";
  display: block;
  width: 28px;
  height: 1px;
  margin-top: 12px;
  background: var(--gold-texture) center / cover no-repeat;
}

.path-why__copy {
  margin: 0;
  color: var(--color-text-muted);
  font-family: var(--font-body) !important;
  font-size: var(--ui-text);
  font-weight: 400 !important;
  line-height: var(--ui-text-lh);
}

._1920-w-dark .path-why__cta {
  position: relative !important;
  left: auto !important;
  right: auto !important;
  top: auto !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  width: auto !important;
  min-width: var(--ui-btn-min-width);
  min-height: var(--ui-btn-height) !important;
  height: auto !important;
  margin: 48px auto 0;
  padding: 12px var(--ui-btn-padding-x) !important;
  border-radius: 9px;
  overflow: hidden;
  cursor: pointer;
  text-decoration: none;
  background: var(--gold-texture) center / cover no-repeat !important;
}

.path-why__cta .get-pre-approved {
  position: static !important;
  translate: none !important;
  left: auto !important;
  top: auto !important;
  width: auto !important;
  height: auto !important;
  color: #111111 !important;
  font-family: var(--font-body) !important;
  font-size: var(--ui-btn-text) !important;
  font-weight: 500 !important;
  line-height: var(--ui-btn-lh) !important;
  white-space: nowrap;
  text-transform: none;
}

/* ── Process ── */
.path-steps {
  display: grid;
  grid-template-columns: minmax(220px, 280px) minmax(0, 1fr);
  gap: 48px;
  align-items: center;
}

.path-steps .path-story__title {
  text-align: left;
  font-size: 60px;
}

.path-steps__track {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr)) 210px;
  gap: 20px;
  align-items: stretch;
  min-width: 0;
}

.path-steps__item {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 0;
  min-width: 0;
  min-height: 448px;
  padding: 0;
  border-radius: 6px;
  overflow: hidden;
  isolation: isolate;
  background: #050915;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.32);
  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.35s ease,
    filter 0.35s ease;
}

.path-steps__item:hover {
  transform: translateY(-4px);
  box-shadow:
    0 0 0 1px rgba(229, 190, 1, 0.4),
    0 24px 48px rgba(0, 0, 0, 0.42);
  filter: brightness(1.05);
}

.path-steps__item::after {
  content: attr(data-step);
  position: absolute;
  right: 10px;
  top: 8px;
  z-index: 2;
  font-family: var(--font-heading) !important;
  font-style: italic;
  font-size: 88px;
  line-height: 1;
  letter-spacing: -0.06em;
  color: rgba(254, 250, 243, 0.08);
  pointer-events: none;
}

.path-steps__thumb {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  border-radius: 0;
  overflow: hidden;
  z-index: 1;
}

.path-steps__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  display: block;
  transform: scale(1.02);
  transition: transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

.path-steps__item:hover .path-steps__thumb img {
  transform: scale(1.08);
}

.path-steps__thumb::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(5, 9, 21, 0.96) 0%,
    rgba(5, 9, 21, 0.88) 26%,
    rgba(5, 9, 21, 0.42) 52%,
    rgba(5, 9, 21, 0.12) 74%,
    rgba(5, 9, 21, 0.06) 100%
  );
  pointer-events: none;
}

.path-steps__num {
  position: absolute;
  top: 16px;
  left: 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: 0;
  border: 1px solid transparent !important;
  border-radius: 50%;
  color: var(--color-gold);
  font-family: var(--font-body) !important;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.08em;
  background:
    linear-gradient(#0b132b, #0b132b) padding-box,
    var(--gold-texture) border-box !important;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.4);
  z-index: 5;
}

.path-steps__body {
  position: relative;
  z-index: 3;
  display: grid;
  grid-template-rows: 40px 3.5em 4.4em;
  gap: 10px;
  width: 100%;
  padding: 0 18px 22px;
  box-sizing: border-box;
}

.path-steps__icon {
  width: 40px;
  height: 40px;
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: 1px solid rgba(229, 190, 1, 0.45);
  background: rgba(5, 9, 21, 0.55);
  color: var(--color-gold);
}

.path-steps__icon svg {
  width: 18px;
  height: 18px;
  display: block;
}

.path-steps__name {
  display: flex;
  flex-direction: column;
  margin: 0;
  color: var(--color-text) !important;
  -webkit-text-fill-color: var(--color-text) !important;
  background: none !important;
  font-family: var(--font-heading) !important;
  font-size: 22px;
  font-weight: 400 !important;
  line-height: 1.15;
  letter-spacing: -0.02em;
  text-transform: none;
}

.path-steps__name::after {
  content: "";
  display: block;
  width: 24px;
  height: 1px;
  margin-top: auto;
  background: var(--gold-texture) center / cover no-repeat;
}

.path-steps__copy {
  margin: 0;
  color: var(--color-text-muted);
  font-family: var(--font-body) !important;
  font-size: 14px;
  font-weight: 400 !important;
  line-height: 1.45;
}

.path-steps__cta {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  gap: 14px;
  min-height: 100%;
  padding: 28px 22px 24px;
  border-radius: 6px;
  overflow: hidden;
  background: var(--gold-texture) center / cover no-repeat !important;
  cursor: pointer;
  text-align: left;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.32);
  transition: filter 0.25s ease, transform 0.25s ease;
}

.path-steps__cta:hover {
  filter: brightness(1.06);
  transform: translateY(-4px);
}

.path-steps__cta-icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px solid #111111 !important;
  border-radius: 50%;
  color: #111111;
}

.path-steps__cta-icon svg {
  width: 18px;
  height: 18px;
}

.path-steps__cta-title {
  margin: 0;
  color: #111111;
  font-family: var(--font-heading) !important;
  font-size: 26px;
  font-weight: 400 !important;
  line-height: 1.15;
  text-transform: none;
  letter-spacing: -0.02em;
}

.path-steps__cta-sub {
  margin: 0;
  color: #12121d;
  font-family: var(--font-body) !important;
  font-size: 14px;
  font-weight: 400 !important;
}

/* ── Ambition banner ── */
.path-ambition {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 36px 48px;
  align-items: center;
  padding: 36px 44px;
  border-radius: 8px;
  overflow: hidden;
  isolation: isolate;
  z-index: 2;
  background: #050915 !important;
  background-image: none !important;
  border: 1px solid #c9a227;
  box-shadow: none !important;
}

.path-ambition.path-gold-frame::before {
  content: none !important;
}

.path-ambition__logo {
  width: 340px;
  height: 180px;
  object-fit: contain;
  object-position: left center;
  display: block;
}

.path-ambition__title {
  margin: 0 0 12px;
  color: var(--color-text);
  font-family: var(--font-heading) !important;
  font-size: 52px;
  font-weight: 400 !important;
  line-height: 1.05;
  letter-spacing: -1.12px;
  text-transform: none;
}

.path-ambition__title .path-story__title-accent {
  font-size: inherit;
}

.path-ambition__copy {
  margin: 0;
  max-width: 560px;
  color: var(--color-text-muted);
  font-family: var(--font-body) !important;
  font-size: var(--ui-text);
  font-weight: 400 !important;
  line-height: var(--ui-text-lh);
}

.path-ambition__map {
  position: relative;
  width: 240px;
  height: 200px;
  flex-shrink: 0;
  overflow: visible;
}

.path-ambition__map img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  display: block;
  position: relative;
  z-index: 1;
  filter: none;
}

.path-ambition__map::before,
.path-ambition__map::after {
  content: none !important;
  display: none !important;
}

@media (min-width: 1280px) {
  .section5 {
    height: auto !important;
    min-height: 0 !important;
    overflow: visible !important;
    padding: 88px 168px 36px;
    box-sizing: border-box;
  }

  .ellipse-3,
  .ellipse-22 {
    display: none !important;
  }
}

@media (max-width: 1279px) {
  .path-story {
    gap: 36px;
  }

  .path-story__title {
    font-size: 34px;
  }

  .path-why__grid {
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-top: 32px;
  }

  .path-why__card {
    min-height: 360px;
  }

  .path-why__body {
    padding: 22px 16px 18px;
  }

  .path-why__icon {
    width: 42px;
    height: 42px;
  }

  .path-why__name {
    font-size: 22px;
    color: var(--color-text) !important;
    -webkit-text-fill-color: var(--color-text) !important;
    text-transform: none;
  }

  .path-why__copy {
    font-size: 14px;
  }

  .path-why__cta {
    width: auto;
    margin-top: 32px;
  }

  .path-steps {
    grid-template-columns: 1fr;
    gap: 28px;
    width: 100%;
  }

  .path-steps .path-story__title {
    text-align: center;
    font-size: 34px;
  }

  .path-steps__track {
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    width: 100%;
  }

  .path-steps__item {
    min-height: 340px;
  }

  .path-steps__item::after {
    font-size: 64px;
  }

  .path-steps__cta {
    grid-column: 1 / -1;
    width: 100%;
    max-width: none;
    min-height: 0;
    height: auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "title icon"
      "sub icon";
    align-items: center;
    justify-content: stretch;
    column-gap: 16px;
    row-gap: 4px;
    padding: 18px 18px 18px 20px;
  }

  .path-steps__cta-icon {
    grid-area: icon;
    width: 40px;
    height: 40px;
    margin: 0;
  }

  .path-steps__cta-title {
    grid-area: title;
    font-size: 22px;
  }

  .path-steps__cta-sub {
    grid-area: sub;
  }

  .path-ambition {
    grid-template-columns: 1fr;
    justify-items: center;
    text-align: center;
    padding: 28px 20px;
    gap: 20px;
  }

  .path-ambition__logo {
    width: 260px;
    height: 130px;
  }

  .path-ambition__title {
    font-size: 34px;
  }

  .path-ambition__copy {
    max-width: 40ch;
  }

  .path-ambition__map {
    width: 196px;
    height: 164px;
  }
}

@media (max-width: 575px) {
  .path-why__grid {
    grid-template-columns: 1fr;
  }

  .path-why__card {
    min-height: 340px;
  }

  .path-steps__track {
    grid-template-columns: 1fr;
    width: 100%;
  }

  .path-steps__item {
    min-height: 320px;
  }

  .path-story__title,
  .path-steps .path-story__title {
    font-size: 30px;
  }
}
