.home-page {
  height: auto;
  min-height: 100svh;
  overflow: hidden;
  position: relative;
}

/* Edge-bound fields: their physical size grows with the viewport, so the
   visible dot count changes naturally instead of scaling a fixed ornament. */
.home-page::before,
.home-page::after {
  content: "";
  position: fixed;
  z-index: 0;
  width: clamp(150px, 23vw, 380px);
  height: clamp(140px, 31vh, 300px);
  pointer-events: none;
  opacity: .8;
  background-image:
    radial-gradient(circle, #7fb7a8 0 2.6px, transparent 3.1px),
    radial-gradient(circle, #88b3d4 0 2.6px, transparent 3.1px);
  background-size: 29px 29px;
  background-position: 0 0, 14.5px 14.5px;
}

.home-page::before {
  top: 0;
  left: 0;
  -webkit-mask-image: linear-gradient(135deg, #000 0 18%, transparent 78%);
  mask-image: linear-gradient(135deg, #000 0 18%, transparent 78%);
}

.home-page::after {
  right: 0;
  bottom: 0;
  transform: rotate(180deg);
  -webkit-mask-image: linear-gradient(135deg, #000 0 18%, transparent 78%);
  mask-image: linear-gradient(135deg, #000 0 18%, transparent 78%);
}

.home-stage {
  position: relative;
  z-index: 1;
  width: min(1180px, calc(100% - 64px));
  min-height: 100svh;
  margin: 0 auto;
  padding: clamp(30px, 5vh, 58px) clamp(10px, 3vw, 40px) 28px;
  display: grid;
  grid-template-rows: auto 1fr auto;
}

.home-intro {
  width: min(760px, 78%);
  margin-top: clamp(150px, 24vh, 250px);
  margin-left: clamp(22px, 7vw, 104px);
  text-align: left;
}

.home-index {
  margin-bottom: 17px;
  color: #5f7d75;
  font-size: .625rem;
  font-weight: 600;
  letter-spacing: .11em;
  text-transform: uppercase;
}

.home-intro h1 {
  margin: 0 0 15px;
  font-size: clamp(2.55rem, 6.2vw, 5.3rem);
  line-height: .94;
  letter-spacing: -.075em;
}

.home-intro > p:last-child {
  max-width: 61ch;
  color: var(--color-text-light);
  font-size: clamp(.75rem, 1.2vw, .9375rem);
  line-height: 1.7;
}

.home-path {
  align-self: center;
  width: min(860px, 82%);
  margin: clamp(70px, 12vh, 130px) 0 clamp(50px, 8vh, 90px) auto;
  display: grid;
  grid-template-columns: 1fr minmax(60px, 120px) 1fr;
  align-items: center;
}

.home-route {
  position: relative;
  min-width: 0;
  padding: 23px 18px 20px;
  border-top: 1px solid rgba(63, 87, 80, .22);
  color: var(--color-text);
  text-decoration: none;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 8px 13px;
}

.home-route::after {
  content: "Explore →";
  position: absolute;
  right: 18px;
  top: 25px;
  color: var(--route-color);
  font-size: .625rem;
  opacity: 0;
  transform: translateX(-5px);
  transition: opacity 180ms ease, transform 220ms cubic-bezier(.22, 1, .36, 1);
}

.route-dot {
  position: absolute;
  width: 10px;
  height: 10px;
  top: -5px;
  left: 0;
  border-radius: 50%;
  background: var(--route-color);
}

.home-route-nexo { --route-color: #7fb7a8; }
.home-route-portfolio {
  --route-color: #88b3d4;
  transform: translateY(30px);
}

.route-number {
  grid-row: 1 / 3;
  color: var(--route-color);
  font-size: .625rem;
}

.home-route strong {
  max-width: calc(100% - 70px);
  font-size: clamp(1rem, 2vw, 1.35rem);
  line-height: 1.1;
}

.home-route > span:last-child {
  max-width: 31ch;
  color: var(--color-muted);
  font-size: .625rem;
  line-height: 1.55;
}

.home-connector {
  border-top: 1px dotted #8ca9a1;
}

.home-note {
  margin: 0;
  color: var(--color-muted);
  font-size: .5625rem;
  letter-spacing: .02em;
  text-align: left;
}

@media (hover: hover) and (prefers-reduced-motion: no-preference) {
  .home-route {
    transition: border-color 180ms ease, background-color 180ms ease, transform 220ms cubic-bezier(.22, 1, .36, 1);
  }

  .home-route:hover {
    border-color: var(--route-color);
    background: rgba(255, 255, 255, .2);
    transform: translateY(-3px);
  }

  .home-route-portfolio:hover {
    transform: translateY(27px);
  }

  .home-route:hover::after {
    opacity: 1;
    transform: translateX(0);
  }
}

@media (max-width: 700px) {
  .home-page::before,
  .home-page::after {
    width: clamp(130px, 45vw, 230px);
    height: clamp(125px, 25vh, 220px);
    background-size: 25px 25px;
    background-position: 0 0, 12.5px 12.5px;
  }

  .home-stage {
    width: calc(100% - 30px);
    padding-inline: 0;
  }

  .home-intro {
    width: min(100%, 520px);
    margin-top: clamp(145px, 22vh, 200px);
    margin-left: 0;
  }

  .home-intro h1 {
    font-size: clamp(2.45rem, 12vw, 4.2rem);
  }

  .home-path {
    width: 100%;
    margin: clamp(64px, 10vh, 92px) 0 60px;
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .home-connector {
    width: 1px;
    height: 22px;
    margin: -16px 0 -16px 20px;
    border-top: 0;
    border-left: 1px dotted #8ca9a1;
  }

  .home-route {
    padding: 18px 14px;
  }

  .home-route-portfolio {
    transform: none;
  }

  .home-note {
    max-width: 55%;
  }
}

@media (max-height: 700px) and (min-width: 701px) {
  .home-intro {
    margin-top: 110px;
  }

  .home-path {
    margin-block: 52px 40px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-route::after {
    transition: none;
  }
}
