/* Shared homepage layout and visual styles. */
.home-page {
  --home-content-width: 1400px;
  --home-gutter: max(2.25rem, calc((100% - var(--home-content-width)) / 2));
  --home-panel-padding: 3rem clamp(1.5rem, 4vw, 4rem) 3.5rem;
  --home-panel-radius: 28px;
  --home-heading-size: clamp(2rem, 3vw, 3rem);
  --home-section-gap: 2.25rem;
  max-width: none;
}

.home-page > :is(section, .footer) {
  max-width: var(--home-content-width);
  margin-inline: var(--home-gutter);
}

.home-page > section {
  margin-block: var(--home-section-gap);
}

.home-page > :is(.features, .how-it-works, .about) {
  padding: var(--home-panel-padding);
  border-radius: var(--home-panel-radius);
}

.home-page :is(.features-inner, .how-it-works-inner, .about-inner) {
  max-width: 1240px;
}

.home-page > .pathways-showcase {
  padding: 1rem 0;
}

.home-page .about .accent {
  color: #173e32;
}

.home-intro {
  --intro-cream: #f6f5e9;
  --intro-muted: #c5d4c8;
  padding: 0 var(--home-gutter) 3rem;
  background-color: #173e32;
  background-image: radial-gradient(ellipse at 90% 18%, #365a45 0%, transparent 52%);
  color: var(--intro-cream);
}

.home-intro .hero {
  height: auto;
  min-height: 0;
  margin: 0;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  overflow: visible;
}

.home-intro .navbar {
  padding: 1.75rem 0;
}

.home-intro .navbar .nav-links {
  background: none;
  border-color: transparent;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.home-intro .navbar .nav-links a {
  font-size: 0.9rem;
  text-shadow: none;
}

.home-intro .nav-brand,
.home-intro .nav-links > li > a {
  color: var(--intro-cream);
}

.home-intro .nav-signin {
  min-height: 44px;
  background: transparent;
  text-shadow: none;
  backdrop-filter: none;
}

.home-intro .nav-signin:hover {
  background: rgba(255, 255, 255, 0.12);
  color: var(--intro-cream);
}

.home-intro .nav-account-trigger:hover .nav-account-initial {
  border-color: rgba(255, 255, 255, 0.34);
  background: rgba(255, 255, 255, 0.2);
  color: var(--intro-cream);
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 0.94fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
  padding: 1.75rem 0 2rem;
}

.hero-copy {
  min-width: 0;
  padding-block: 0;
}

.hero-eyebrow {
  margin-bottom: 1.5rem;
  color: var(--intro-muted);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.home-intro .hero h1 {
  font-size: clamp(3rem, 5.65vw, 5.6rem);
  font-weight: 500;
  line-height: 1.04;
  letter-spacing: -0.055em;
  color: var(--intro-cream);
  text-shadow: none;
}

.home-intro .hero h1 span {
  color: #dbe6b4;
}

.hero-description {
  max-width: 30rem;
  margin-top: 1.75rem;
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  line-height: 1.65;
  color: #d8e1d8;
}

.hero-actions {
  display: grid;
  grid-template-columns: minmax(0, 16.5rem) max-content;
  align-items: center;
  gap: 1rem 1.75rem;
  margin-top: 2rem;
}

.home-intro .hero-start {
  min-height: 58px;
  justify-content: space-between;
  gap: 1.5rem;
  padding: 0.7rem 1rem 0.7rem 1.5rem;
  border: 1px solid var(--intro-cream);
  background: var(--intro-cream);
  color: #173e32;
  font-size: 1rem;
  font-weight: 600;
  white-space: nowrap;
  backdrop-filter: none;
}

.home-intro .hero-start:hover {
  background: #dbe6b4;
  border-color: #dbe6b4;
}

.home-intro .hero-start .btn-arrow {
  flex-shrink: 0;
  background: #e3e8d7;
  font-size: 1.2rem;
}

.hero-learn {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 44px;
  font-size: 0.95rem;
  white-space: nowrap;
  text-underline-offset: 5px;
}

.hero-learn:hover {
  text-decoration: underline;
}

.hero-free-note {
  margin-top: 0.9rem;
  color: var(--intro-muted);
  font-size: 0.8rem;
}

.home-intro .social-proof {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 1rem;
  width: 100%;
  max-width: 100%;
  margin: 2.5rem 0 0;
  padding: 0.75rem 1rem;
  border: 1px solid rgba(220, 233, 217, 0.12);
  border-radius: 16px;
  background: rgba(246, 245, 233, 0.045);
}

.home-intro .social-proof:hover {
  border-color: rgba(220, 233, 217, 0.22);
  background: rgba(246, 245, 233, 0.07);
}

.home-intro .flag-stack {
  flex: 1 1 0;
  min-width: 0;
  max-width: var(--flag-stack-width, 100%);
  width: auto;
  justify-content: flex-start;
  overflow: hidden;
}

.home-intro .flag-circle {
  flex-shrink: 0;
  width: 30px;
  height: 30px;
  margin-right: -12px;
  border-color: #294d3e;
}

.home-intro .flag-circle:last-child,
.home-intro .flag-circle.is-visible-final {
  margin-right: 0;
}

.home-intro .social-proof-text {
  flex: 0 0 auto;
  white-space: nowrap;
  font-size: 0.75rem;
  text-align: left;
  line-height: 1.4;
  color: var(--intro-muted);
}

.home-intro .social-proof-text strong {
  display: block;
  font-size: 0.9rem;
  color: var(--intro-cream);
}

.home-intro .resource-count {
  min-height: 1.4em;
}

.home-intro .resource-count[hidden] {
  display: none;
}

.home-intro .resource-count.is-loading {
  position: relative;
  width: 6ch;
  overflow: hidden;
  border-radius: 4px;
  background: rgba(216, 225, 216, 0.16);
}

.home-intro .resource-count.is-loading::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(246, 245, 233, 0.28), transparent);
  transform: translateX(-100%);
  animation: resource-count-shimmer 1.5s ease-in-out infinite;
}

@keyframes resource-count-shimmer {
  to { transform: translateX(100%); }
}

@media (prefers-reduced-motion: reduce) {
  .home-intro .resource-count.is-loading::after {
    animation: none;
    display: none;
  }
}

.home-intro .desktop-proof-label {
  display: inline;
}

.home-intro .mobile-proof-label {
  display: none;
}

.hero-visual {
  display: block;
  height: clamp(430px, 39vw, 520px);
  overflow: hidden;
  border-radius: 160px 24px 24px 24px;
  background: #66806a;
}

.hero-visual img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 66% center;
}

.home-intro .endorsement {
  margin: 0;
  padding: 2.75rem 0 0;
  border-radius: 0;
}

.home-intro .endorsement-inner {
  width: 100%;
  max-width: none;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.75rem;
  align-items: start;
  padding: 1.75rem 2rem;
  border: 1px solid rgba(220, 233, 217, 0.12);
  border-radius: 20px;
  background: rgba(246, 245, 233, 0.045);
}

.home-intro .endorsement-kicker.home-section-eyebrow {
  max-width: none;
  margin: 0;
  color: var(--intro-muted);
  font-size: 0.7rem;
  line-height: 1.8;
}

.home-intro .endorsement blockquote {
  padding: 0 0 0 1.25rem;
  border: 0;
  border-left: 3px solid rgba(219, 230, 180, 0.65);
}

.home-intro .endorsement blockquote > p {
  margin-bottom: 0.7rem;
  color: #e1e8dc;
  font-size: 1rem;
  line-height: 1.65;
}

.home-intro .endorsement footer,
.home-intro .endorsement footer a {
  color: var(--intro-muted);
  font-size: 0.8rem;
}

.home-intro .endorsement footer strong,
.home-intro .endorsement footer a:hover {
  color: var(--intro-cream);
}

.home-intro .product-preview {
  margin: 0;
  padding: var(--home-panel-padding);
  border-radius: var(--home-panel-radius);
  background: #e9efdf;
  scroll-margin-top: 1.5rem;
}

.home-intro .product-preview-inner {
  max-width: 1240px;
}

.home-intro .preview-layout {
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.15fr);
  gap: clamp(2rem, 5vw, 5rem);
}

.home-intro .preview-copy h2 {
  max-width: none;
}

.home-intro :is(a, button):focus-visible {
  outline: 2px solid #dbe6b4;
  outline-offset: 5px;
}

.home-intro .product-preview :is(a, button):focus-visible,
.home-intro .nav-account-menu :is(a, button):focus-visible {
  outline-color: #173e32;
}

@media (max-width: 1240px) {
  .home-intro .nav-toggle {
    width: 44px;
    height: 44px;
    align-items: center;
    justify-content: center;
  }

  .home-intro .navbar .nav-links {
    top: calc(100% - 0.5rem);
    left: 0;
    right: 0;
    z-index: 25;
    margin: 0;
    padding: 0 1.5rem;
    border: 1px solid transparent;
    border-radius: 18px;
    background: #234b3c;
    visibility: hidden;
    pointer-events: none;
  }

  .home-intro .navbar .nav-links.open {
    max-height: min(560px, calc(100dvh - 7rem));
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: 1.5rem;
    border-color: rgba(255, 255, 255, 0.15);
    box-shadow: 0 20px 40px rgba(9, 29, 22, 0.2);
    visibility: visible;
    pointer-events: auto;
    gap: 0.5rem;
  }

  .home-intro .navbar .nav-links > li {
    flex-shrink: 0;
  }

  .home-intro .navbar .nav-links a {
    display: flex;
    align-items: center;
    min-height: 44px;
  }

  .home-intro .navbar .nav-signin-item {
    width: 100%;
    margin-top: 0.5rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
  }

  .home-intro .nav-signin-item .nav-account-trigger {
    width: 100%;
    max-width: none;
    justify-content: flex-start;
    padding: 0.5rem 0.75rem;
  }

  .home-intro .nav-signin-item .nav-account-label {
    flex: 1;
    max-width: none;
    text-align: left;
  }

  .home-intro .nav-signin-item .nav-account-menu {
    width: 100%;
    border-radius: 12px;
  }

  .home-intro .nav-account-menu button {
    min-height: 44px;
  }

  .home-intro .navbar.menu-open {
    background: none;
  }
}

@media (max-width: 1000px) {
  .home-intro .preview-layout {
    grid-template-columns: minmax(0, 1fr);
    gap: 2.5rem;
  }
}

@media (max-width: 880px) {
  .home-page {
    --home-gutter: 1.25rem;
    --home-panel-padding: 2rem 1.5rem;
    --home-section-gap: 1.25rem;
  }

  .home-intro {
    padding-bottom: 1.25rem;
  }

  .home-intro .navbar {
    padding-block: 1.1rem;
  }

  .hero-grid {
    gap: 1.5rem;
    padding-top: 1.75rem;
  }

  .hero-eyebrow {
    font-size: 0.65rem;
    letter-spacing: 0.08em;
  }

}

@media (max-width: 760px) {
  .home-page {
    --home-panel-padding: 2rem 1.25rem;
    --home-panel-radius: 22px;
    --home-heading-size: 2rem;
  }

  .hero-grid {
    container-type: inline-size;
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "eyebrow"
      "title"
      "description"
      "actions"
      "note"
      "proof";
    gap: 0;
    padding: 1.25rem 0 2rem;
  }

  .hero-copy {
    display: contents;
  }

  .hero-eyebrow {
    grid-area: eyebrow;
    margin-bottom: 1.25rem;
  }

  .home-intro .hero h1 {
    grid-area: title;
    font-size: clamp(2.75rem, 16cqw, 7.25rem);
  }

  .hero-description {
    grid-area: description;
    max-width: 32rem;
    margin-top: 1.25rem;
    font-size: 1.05rem;
  }

  .hero-actions {
    grid-area: actions;
    grid-template-columns: minmax(0, 1fr) max-content;
    margin-top: 1.5rem;
    gap: clamp(0.75rem, 3vw, 1.25rem);
  }

  .home-intro .hero-start {
    min-height: 54px;
    gap: 0.5rem;
    padding-inline: 1rem 0.75rem;
  }

  .hero-learn {
    gap: 0.5rem;
    font-size: 0.85rem;
  }

  .hero-free-note {
    grid-area: note;
  }

  .home-intro .social-proof {
    grid-area: proof;
    margin-top: 1.75rem;
  }

  .hero-visual,
  .home-intro .match-preview-frame {
    display: none;
  }

  .home-intro .endorsement {
    padding: 2rem 0 0;
  }

  .home-intro .endorsement-inner {
    padding: 1.5rem 1.25rem;
  }

  .home-intro .endorsement blockquote > p {
    font-size: 0.9rem;
  }

}

/* One type treatment for section labels and titles throughout the homepage. */
.home-page .home-section-eyebrow {
  margin: 0 0 1.25rem;
  color: #56725a;
  font-family: 'DM Sans', sans-serif;
  font-size: .72rem;
  font-weight: 700;
  line-height: 1.6;
  letter-spacing: .12em;
  text-transform: uppercase;
  text-align: center;
}

.home-page .home-section-title {
  color: #173e32;
  font-family: 'DM Sans', sans-serif;
  font-size: var(--home-heading-size);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -.035em;
  text-wrap: balance;
}

.home-page :is(.hero-eyebrow, .endorsement-kicker, .pricing-kicker).home-section-eyebrow {
  color: #c5d4c8;
  text-align: left;
}

.home-page .endorsement-kicker.home-section-eyebrow {
  color: #bdcdb2;
}

.home-page .pricing .home-section-title { color: #fff; }
