:root {
  --pf-focus-ring: #5f7f8c;
}

html {
  scroll-padding-top: 96px;
  text-rendering: optimizeLegibility;
  -webkit-text-size-adjust: 100%;
}

::selection {
  color: #3d3a37;
  background: rgba(134, 161, 170, 0.3);
}

.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

:where(a[href], button, input, select, textarea, summary, [tabindex]:not([tabindex="-1"])):focus-visible {
  outline: 3px solid var(--pf-focus-ring);
  outline-offset: 3px;
}

:where(a[href], button, input, select, textarea, summary) {
  -webkit-tap-highlight-color: rgba(134, 161, 170, 0.2);
}

/*
 * Canonical site shell
 *
 * Individual landing pages predate the shared design pass and still carry
 * slightly different nav rules. Keep the public shell here so the logo,
 * header geometry and primary actions do not jump between routes.
 */
body > nav {
  position: fixed !important;
  inset: 0 0 auto !important;
  z-index: 1000 !important;
  width: 100% !important;
  height: 88px !important;
  min-height: 88px !important;
  padding: 0 clamp(24px, 4vw, 64px) !important;
  display: flex !important;
  align-items: center !important;
  justify-content: space-between !important;
  gap: clamp(18px, 2vw, 32px) !important;
  background: rgba(243, 238, 231, 0.94) !important;
  border-bottom: 1px solid rgba(140, 121, 97, 0.12) !important;
  box-shadow: none !important;
  -webkit-backdrop-filter: blur(20px) !important;
  backdrop-filter: blur(20px) !important;
}

body > nav > .logo {
  width: 132px !important;
  min-width: 132px !important;
  height: 36px !important;
  display: flex !important;
  align-items: center !important;
  color: #3d3a37 !important;
  text-decoration: none !important;
}

body > nav > .logo img {
  width: 132px !important;
  max-width: 132px !important;
  height: auto !important;
  max-height: 36px !important;
  display: block !important;
  object-fit: contain !important;
  object-position: left center !important;
}

body > nav > .nav-links {
  min-width: 0 !important;
  margin: 0 auto !important;
  padding: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: clamp(16px, 2vw, 32px) !important;
  list-style: none !important;
}

body > nav > .nav-links a {
  font-family: "DM Sans", sans-serif !important;
  font-size: 14px !important;
  font-weight: 400 !important;
  line-height: 1.2 !important;
  color: #3d3a37 !important;
  text-decoration: none !important;
  white-space: nowrap !important;
}

body > nav > .nav-links a[aria-current="page"] {
  color: #5f7f8c !important;
}

body > nav > .nav-r {
  min-width: 232px !important;
  display: flex !important;
  align-items: center !important;
  justify-content: flex-end !important;
  gap: 12px !important;
  flex: 0 0 auto !important;
}

body > nav > .nav-r > :is(.btn-ghost, .btn-navy) {
  min-height: 40px !important;
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  padding: 9px 20px !important;
  border-radius: 999px !important;
  font-family: "DM Sans", sans-serif !important;
  font-size: 14px !important;
  font-weight: 500 !important;
  line-height: 20px !important;
  text-decoration: none !important;
  white-space: nowrap !important;
}

body > nav > .nav-r > .btn-ghost {
  min-width: 92px !important;
  color: #3d3a37 !important;
  background: rgba(255, 255, 255, 0.45) !important;
  border: 1px solid rgba(190, 175, 159, 0.52) !important;
}

body > nav > .nav-r > .btn-navy {
  min-width: 126px !important;
  color: #fff !important;
  background: #3d3a37 !important;
  border: 1px solid #3d3a37 !important;
}

body > nav > .nav-r > .btn-navy:hover {
  background: #5f7f8c !important;
  border-color: #5f7f8c !important;
}

.nav-menu {
  position: relative;
  display: none;
  flex: 0 0 auto;
}

.nav-menu summary {
  width: 44px;
  height: 44px;
  display: grid;
  place-content: center;
  gap: 5px;
  list-style: none;
  cursor: pointer;
  border: 1px solid rgba(190, 175, 159, 0.58);
  border-radius: 999px;
  background: rgba(248, 248, 247, 0.9);
}

.nav-menu summary::-webkit-details-marker {
  display: none;
}

.nav-menu summary span {
  width: 18px;
  height: 1.5px;
  display: block;
  background: #3d3a37;
  transition: transform 180ms ease, opacity 180ms ease;
}

.nav-menu[open] summary span:first-child {
  transform: translateY(6.5px) rotate(45deg);
}

.nav-menu[open] summary span:nth-child(2) {
  opacity: 0;
}

.nav-menu[open] summary span:last-child {
  transform: translateY(-6.5px) rotate(-45deg);
}

.nav-menu-panel {
  position: absolute;
  z-index: 1000;
  top: calc(100% + 12px);
  right: 0;
  width: min(300px, calc(100vw - 32px));
  padding: 12px;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(190, 175, 159, 0.5);
  border-radius: 20px;
  background: rgba(248, 248, 247, 0.98);
  box-shadow: 0 24px 60px rgba(61, 58, 55, 0.18);
  backdrop-filter: blur(18px);
}

.nav-menu-panel a {
  min-height: 44px;
  padding: 11px 14px;
  display: flex;
  align-items: center;
  border-radius: 12px;
  color: #3d3a37;
  font-family: "DM Sans", sans-serif;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
}

.nav-menu-panel a:hover {
  color: #3d3a37;
  background: rgba(134, 161, 170, 0.16);
}

.nav-menu-panel a[aria-current="page"] {
  color: #3d3a37;
  background: rgba(134, 161, 170, 0.24);
}

.nav-menu-panel .nav-menu-primary {
  margin-top: 6px;
  justify-content: center;
  color: #fff;
  background: #3d3a37;
}

.nav-menu-panel .nav-menu-primary:hover {
  color: #fff;
  background: #5f7f8c;
}

/* Shared safeguards for the legacy page components. */
:where(
  .page-hero-copy,
  .page-hero-visual,
  .section-inner,
  .section-pad,
  .cat-copy,
  .cat-stage,
  .cat-card,
  .product-card,
  .result-card,
  .faq-item,
  .quiz-card,
  .quiz-option
) {
  min-width: 0;
}

:where(
  .page-hero-actions,
  .cat-actions,
  .hero-btns,
  .hero-cta-row,
  .hims-btns,
  .hims-cta-row,
  .product-btns,
  .result-card-actions,
  .final-cta-actions,
  .explore-actions,
  .actions
) {
  flex-wrap: wrap;
  row-gap: 12px;
}

:where(
  .cascade-pill,
  .final-btn,
  .hiw-cta-button,
  .pricing-cta,
  .products-continue-btn,
  .quiz-continue,
  .quiz-submit,
  .quiz-next,
  .quiz-back,
  .result-btn,
  .success-btn,
  .hims-btn-solid,
  .hims-btn-ghost,
  .himscard-btn
) {
  max-width: 100%;
  min-height: 44px;
  height: auto;
  line-height: 1.25;
  overflow-wrap: break-word;
  text-wrap: balance;
}

:where(.quiz-option, .product-card, .result-card, .cat-card, .faq-item) {
  overflow-wrap: break-word;
}

@media (max-width: 1180px) {
  body > nav {
    height: 64px !important;
    min-height: 64px !important;
    padding-inline: 20px !important;
  }

  body > nav > .logo,
  body > nav > .logo img {
    width: 126px !important;
    min-width: 126px !important;
  }

  body > nav > .nav-links {
    display: none !important;
  }

  body > nav > .nav-r {
    min-width: 0 !important;
    margin-left: auto !important;
  }

  body > nav > .nav-r > .btn-navy {
    display: none !important;
  }

  nav > .nav-menu {
    display: block;
  }

  body > nav .nav-hamburger {
    width: 44px !important;
    height: 44px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex-direction: column !important;
    gap: 5px !important;
    padding: 0 !important;
    border: 1px solid rgba(190, 175, 159, 0.58) !important;
    border-radius: 999px !important;
    background: rgba(248, 248, 247, 0.9) !important;
  }
}

@media (max-width: 640px) {
  body > nav {
    padding-inline: 14px !important;
  }

  body > nav > .nav-r > .btn-ghost {
    display: none !important;
  }

  .nav-menu-panel {
    position: fixed;
    top: 72px;
    right: 12px;
    left: 12px;
    width: auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto !important;
}

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

.ls-seal {
  display: inline-flex;
  margin-top: 14px;
  line-height: 0;
}
.ls-seal img {
  display: block;
  width: 73px;
  height: 79px;
}
.ft-contact .ls-seal {
  margin-top: 16px;
}

#faq {
  position: relative;
}
.ls-seal-faq {
  position: absolute;
  left: max(16px, calc((100% - min(940px, 100% - 48px)) / 2));
  bottom: 20px;
  margin: 0;
  z-index: 2;
}
#faq.faq-page .ls-seal-faq,
#faq.section-pad .ls-seal-faq {
  left: max(16px, calc((100% - min(980px, 100% - 48px)) / 2));
}
@media (max-width: 760px) {
  .ls-seal-faq {
    left: 16px;
    bottom: 16px;
  }
}
#faq {
  padding-bottom: 120px;
}
