/* =====================================================================
   Nuvari Mobile Redesign — restyles the desktop HTML for mobile.
   ---------------------------------------------------------------------
   KILL SWITCH: remove the <link> to this file in <head>, everything
   reverts to the Phase 1 patches alone.
   Desktop (min-width 821px) is untouched — every rule below is inside
   a (max-width: 820px) media query.
   Mobile chrome (drawer, sticky CTA) is layered on top of the desktop
   HTML via position:fixed, not replacing it.
   ===================================================================== */

/* ═══════════════════════════════════════════════════════════════════
   DESKTOP GUARD — hide every mobile-chrome element on viewports ≥821px.
   This is the single rule that makes desktop render 100% unchanged.
   ═══════════════════════════════════════════════════════════════════ */
@media (min-width: 821px) {
  .nmd-toggle,
  .nmd-backdrop,
  .nmd-drawer,
  .nm-float-menu,
  .nm-sticky {
    display: none !important;
  }
}

/* ------ FLOATING HAMBURGER (mobile-only, appears after scroll) ----- */
.nm-float-menu { display: none; }
@media (max-width: 820px) {
  .nm-float-menu {
    position: fixed;
    top: calc(14px + env(safe-area-inset-top, 0px));
    right: 14px;
    z-index: 40;
    width: 44px;
    height: 44px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    background: rgba(251, 248, 245, 0.88);
    -webkit-backdrop-filter: blur(12px) saturate(1.2);
    backdrop-filter: blur(12px) saturate(1.2);
    border-radius: 12px;
    box-shadow: 0 2px 14px rgba(10, 22, 40, 0.06);
    cursor: pointer;
    -webkit-tap-highlight-color: transparent;
    /* Hidden initially — only appears once the user scrolls past the top nav */
    opacity: 0;
    transform: translateY(-14px);
    pointer-events: none;
    transition: opacity 0.28s ease, transform 0.28s cubic-bezier(0.22, 1, 0.36, 1);
  }
  body.nm-scrolled .nm-float-menu {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }
  .nm-float-menu span {
    display: block;
    width: 22px;
    height: 2.25px;
    background: #0A1628;
    border-radius: 2px;
  }
  .nm-float-menu:active { transform: translateY(0) scale(0.92); }
  /* Hide on pages where the desktop .nav bar already has its own hamburger */
  body:has(.nv-hamburger-btn) .nm-float-menu { display: none; }
}

/* ------ MOBILE RESTYLING OF DESKTOP HTML --------------------------- */
@media (max-width: 820px) {
  html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
    font-family: 'DM Sans', -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
  }
  body { padding-bottom: calc(80px + env(safe-area-inset-bottom, 0px)); }
  /* Global overflow guard — nothing should be wider than the viewport,
     nothing should escape its container. Works across all iPhone sizes
     (SE 375px, 13/14/15 390px, 14/15 Plus 428px, Pro Max 430px) and
     Android (360–412px). */
  body, body * {
    max-width: 100vw;
    box-sizing: border-box;
  }
  body img,
  body picture,
  body video,
  body svg {
    max-width: 100%;
    height: auto;
  }
  /* Allow the protocol marquee row to exceed viewport (clipped by its wrap) */
  .proto-row,
  .proto-row * {
    max-width: none !important;
  }
  /* Allow the comparison table to exceed viewport (clipped by its wrap) */
  .comparison-table,
  .comparison-table * {
    max-width: none !important;
  }

  /* DESKTOP .hero — collapse from 2-col to single column, shrink padding */
  .hero {
    padding: 40px 18px 28px !important;
  }
  .hero-top {
    flex-direction: column !important;
    gap: 16px !important;
    align-items: flex-start !important;
  }
  .hero h1 {
    font-size: clamp(36px, 9.5vw, 44px) !important;
    line-height: 1.05 !important;
    letter-spacing: -1px !important;
  }
  .hero .hero-top > a {
    font-size: 11px !important;
    line-height: 1.6 !important;
    padding: 10px 0;
  }
  /* Hero cards row — stack on mobile */
  .hero-cards {
    display: flex !important;
    flex-direction: column !important;
    gap: 14px !important;
    margin-top: 20px !important;
  }
  .hero-cards .hc {
    width: 100% !important;
    min-height: 180px !important;
    padding: 22px !important;
  }
  .hero-cards .hc h2 { font-size: 24px !important; line-height: 1.15 !important; }
  /* Category lifestyle-photo cards (.nm-cat-cards) — already handled inline in head */
  .nm-cat-cards {
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }
  .nm-cat-cards > a > div:first-child { height: 220px !important; }

  /* FEATURED SECTION — tighter padding, headline scales down */
  .featured-section { padding: 56px 16px !important; }
  .featured-section h2 { font-size: 30px !important; line-height: 1.12 !important; }
  .featured-section .sec-sub { font-size: 14px !important; line-height: 1.5 !important; }
  /* Protocol row — horizontal scroll-snap carousel (already handled in index.html) */

  /* MEMBERSHIP SECTION — single column, tighter */
  .membership-section { padding: 56px 18px !important; }
  .membership-grid { grid-template-columns: 1fr !important; gap: 32px !important; }
  .membership-section h2 { font-size: 30px !important; line-height: 1.12 !important; }
  .membership-stats { grid-template-columns: 1fr 1fr !important; gap: 12px !important; }
  .membership-stats .ms { padding: 18px 14px !important; }
  .membership-stats .ms-num { font-size: 26px !important; }

  /* HOW IT WORKS — single column steps */
  .how-section { padding: 56px 18px !important; }
  .how-section h2 { font-size: 30px !important; line-height: 1.12 !important; }
  .how-sub { font-size: 14px !important; }
  .how-grid { grid-template-columns: 1fr !important; gap: 16px !important; }
  .how-step { padding: 22px !important; }

  /* SPLIT-VALUE (Why Nuvari + Comparison) — single column stack */
  .split-value-section {
    padding: 56px 16px !important;
    overflow: hidden !important;
  }
  .split-value-section * { min-width: 0 !important; }
  .split-value-section h2 { font-size: 28px !important; line-height: 1.12 !important; }
  .split-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
    width: 100% !important;
    max-width: 100% !important;
  }
  /* Value prop cards — the inline-styled divs with border-left:3px and padding */
  .split-grid > div > div {
    max-width: 100% !important;
    width: 100% !important;
    padding: 20px 18px !important;
    box-sizing: border-box !important;
    overflow-wrap: break-word !important;
    word-wrap: break-word !important;
  }
  .split-grid > div > div h3 {
    font-size: 17px !important;
    line-height: 1.25 !important;
  }
  .split-grid > div > div p {
    font-size: 13px !important;
    line-height: 1.55 !important;
    overflow-wrap: break-word !important;
  }
  /* Comparison table — horizontal scroll within its own wrapper */
  .comparison-table-wrap {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    width: 100% !important;
    max-width: 100% !important;
    border-radius: 16px !important;
  }
  .comparison-table {
    min-width: 520px !important;
    font-size: 12px !important;
    width: 520px !important;
  }
  .comparison-table th,
  .comparison-table td {
    padding: 10px 8px !important;
    white-space: nowrap !important;
  }
  .comparison-table th:first-child,
  .comparison-table td:first-child {
    white-space: normal !important;
    min-width: 120px !important;
  }

  /* WOLVERINE BANNER — stack */
  #wolverine { padding: 30px 22px !important; margin: 24px 14px !important; border-radius: 16px !important; }
  #wolverine > div { grid-template-columns: 1fr !important; gap: 20px !important; }
  #wolverine h2 { font-size: 24px !important; }
  #wolverine form { flex-direction: column !important; width: 100%; }
  #wolverine input { width: 100% !important; box-sizing: border-box; font-size: 16px !important; }
  #wolverine button { width: 100% !important; }

  /* LEAD MAGNET — stack vertically */
  section > div[style*="grid-template-columns:1fr 1fr"] {
    grid-template-columns: 1fr !important;
    min-height: auto !important;
  }
  section > div[style*="grid-template-columns:1fr 1fr"] > div:first-child {
    padding: 48px 24px !important;
  }
  section > div[style*="grid-template-columns:1fr 1fr"] > div:first-child h2 {
    font-size: 28px !important;
  }
  section > div[style*="grid-template-columns:1fr 1fr"] > div:last-child {
    display: none !important;
  }

  /* CTA SECTION — tighter */
  .cta-section { padding: 56px 18px !important; }
  .cta-section h2 { font-size: 32px !important; line-height: 1.1 !important; }
  .cta-section p { font-size: 15px !important; max-width: 100% !important; }

  /* FOOTER — single column + collapsible accordions per section.
     Only top/side padding here; bottom clearance for the sticky CTA is
     already handled by body's padding-bottom so don't double it. */
  footer { padding: 48px 22px 32px !important; }
  .footer-inner {
    grid-template-columns: 1fr !important;
    gap: 0 !important;
  }
  /* The brand column (with logo + description + social) always shows */
  .footer-inner > .fb { padding-bottom: 20px; }
  /* Each column that became an accordion */
  .footer-inner > .nm-foot-acc {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 4px 0;
  }
  .footer-inner > .nm-foot-acc:last-of-type {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  .footer-inner > .nm-foot-acc h4 {
    position: relative;
    display: block !important;
    padding: 18px 32px 18px 0 !important;
    margin: 0 !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    letter-spacing: 2px !important;
    text-transform: uppercase !important;
    color: rgba(255, 255, 255, 0.85) !important;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
    -webkit-tap-highlight-color: transparent;
  }
  .footer-inner > .nm-foot-acc h4::after {
    content: '+';
    position: absolute;
    right: 4px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 22px;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1;
    transition: transform 0.2s ease;
  }
  .footer-inner > .nm-foot-acc--open h4::after {
    content: '−';
  }
  /* List collapsed by default, expand when --open */
  .footer-inner > .nm-foot-acc ul {
    display: none !important;
    padding: 0 0 16px !important;
    margin: 0 !important;
    list-style: none !important;
  }
  .footer-inner > .nm-foot-acc--open ul {
    display: block !important;
  }
  .footer-inner > .nm-foot-acc ul li {
    padding: 8px 0 !important;
  }
  .footer-inner > .nm-foot-acc ul li a {
    color: rgba(255, 255, 255, 0.7) !important;
    font-size: 14px !important;
    text-decoration: none !important;
  }

  /* Legacy sticky / floating CTAs — hidden on mobile, the new .nm-sticky owns the bottom.
     .float-chat is intentionally NOT in this list — the chat trigger must stay
     visible on mobile, sitting above the sticky bar (bottom:80px). */
  .sticky-quiz,
  .mobile-cta-bar,
  .mobile-cta-bar.visible,
  .fab-quiz,
  .nm-bottom-cta {
    display: none !important;
    opacity: 0 !important;
    pointer-events: none !important;
    visibility: hidden !important;
  }
  /* Hide the desktop nav's inline hamburger AND its slide-menu machinery on mobile.
     The .nm-float-menu (fixed top-right) + .nmd-drawer own the mobile menu. */
  nav.nav .hamburger,
  nav.nav > .hamburger,
  .hamburger,
  #slideMenu,
  .slide-menu,
  #menuOverlay,
  .menu-overlay,
  nav.nav .nav-login {
    display: none !important;
    visibility: hidden !important;
    pointer-events: none !important;
  }

  /* DESKTOP NAV — keep visible but compact on mobile, hide the wordmark */
  nav.nav {
    padding: 12px 18px !important;
    padding-right: 68px !important; /* leave room for floating hamburger */
  }
  nav.nav .nav-logo { font-size: 18px !important; letter-spacing: 3px !important; }
  nav.nav .nav-right { gap: 8px !important; }
  nav.nav .nav-login { font-size: 12px !important; padding: 8px 14px !important; }

  /* CTA ROW below hero */
  div[style*="background:#F5F0E8"] {
    flex-direction: column !important;
    gap: 10px !important;
    padding: 24px 18px !important;
  }
  div[style*="background:#F5F0E8"] > a {
    width: 100% !important;
    justify-content: center !important;
  }

  /* Trust marquee — keep visible but tighter */
  .trust-marquee { padding: 14px 0 !important; }
  .trust-marquee-item { font-size: 11px !important; padding: 0 20px !important; }

  /* Topbar announcement (if any) */
  .topbar { font-size: 12px !important; padding: 10px 14px !important; }
}

/* ------ GLOBAL MOBILE RESET ---------------------------------------- */
@media (max-width: 820px) {
  html, body {
    margin: 0 !important;
    padding: 0 !important;
    background: #FBF8F5 !important;
    color: #0A1628 !important;
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    overflow-x: hidden !important;
    text-rendering: optimizeLegibility;
  }
  body { padding-bottom: calc(76px + env(safe-area-inset-bottom, 0px)) !important; }
  .nm-mobile-overlay * { box-sizing: border-box; }
  .nm-mobile-overlay img { max-width: 100%; display: block; }
}

/* ------ DESIGN TOKENS ---------------------------------------------- */
.nm-mobile-overlay {
  --dark: #0A1628;         /* deep navy — primary dark */
  --dark-2: #0D1B2A;
  --dark-3: #14243C;
  --cream: #FBF8F5;
  --cream-2: #F5F0E8;
  --white: #FFFFFF;
  --text: #0A1628;
  --text-dim: #2C3E50;
  --sub: #4A5562;
  --mute: #8A9199;
  --border: #E8E2D5;
  --border-dark: rgba(255, 255, 255, 0.14);
  --accent: #00B4C6;
  --accent-dark: #009DAE;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --radius-pill: 100px;
  --radius: 14px;
  --radius-lg: 20px;
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--text);
}

/* ------ ANNOUNCEMENT BAR (Hims slim banner above top nav) ---------- */
.nm-banner {
  background: var(--dark);
  color: var(--white);
  font-size: 12px;
  font-weight: 500;
  text-align: center;
  padding: calc(8px + var(--safe-top)) 16px 8px;
  letter-spacing: 0.2px;
}
.nm-banner a { color: var(--white); text-decoration: underline; text-underline-offset: 2px; font-weight: 600; }

/* ------ TOP NAV (minimal, cream, tight) ---------------------------- */
.nm-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--cream);
  border-bottom: 1px solid rgba(10, 22, 40, 0.06);
  padding: 12px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 56px;
}
.nm-nav__logo {
  font-family: 'DM Sans', sans-serif;
  font-size: 22px;
  font-weight: 700;
  letter-spacing: 5px;
  color: var(--accent);
  text-decoration: none;
  text-transform: uppercase;
}
.nm-nav__right { display: flex; align-items: center; gap: 4px; }
.nm-nav__icon-btn {
  width: 44px;
  height: 44px;
  border: none;
  background: transparent;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text);
  cursor: pointer;
}
.nm-nav__icon-btn:active { background: rgba(10, 22, 40, 0.08); }
.nm-nav__icon-btn svg { width: 22px; height: 22px; stroke-width: 2; }
.nm-nav__menu {
  flex-direction: column !important;
  gap: 5px;
  cursor: pointer;
}
.nm-nav__menu span {
  display: block;
  width: 22px;
  height: 2.25px;
  background: var(--text);
  border-radius: 2px;
  margin: 0 !important;
}

/* ------ HERO (light teal/cream, dark text, teal pill CTA) ---------- */
.nm-hero {
  background:
    radial-gradient(120% 70% at 80% 10%, rgba(0, 180, 198, 0.22) 0%, transparent 55%),
    linear-gradient(165deg, #E6F7F9 0%, #F5FBFC 35%, #FBF8F5 100%);
  color: var(--text);
  padding: 56px 22px 64px;
  position: relative;
  overflow: hidden;
}
.nm-hero::before {
  content: '';
  position: absolute;
  top: -20%;
  left: -30%;
  width: 90%;
  aspect-ratio: 1;
  background: radial-gradient(circle, rgba(0, 180, 198, 0.18) 0%, transparent 65%);
  pointer-events: none;
}
.nm-hero__content { position: relative; z-index: 1; }
.nm-hero__eyebrow {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin-bottom: 20px;
  padding: 7px 14px;
  background: rgba(255, 255, 255, 0.65);
  border-radius: 100px;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.nm-hero h1 {
  font-family: 'DM Sans', sans-serif;
  font-size: clamp(40px, 11vw, 52px);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -1.4px;
  margin: 0 0 18px;
  color: var(--text);
}
.nm-hero__sub {
  font-size: 17px;
  line-height: 1.5;
  color: var(--sub);
  margin: 0 0 32px;
  max-width: 32ch;
  font-weight: 400;
}
.nm-hero__ctas { display: flex; flex-direction: column; gap: 10px; }
.nm-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 18px 28px;
  font-size: 15px;
  font-weight: 700;
  border: none;
  border-radius: var(--radius-pill);
  text-decoration: none;
  cursor: pointer;
  letter-spacing: -0.1px;
  transition: transform 0.08s ease, background 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}
.nm-btn:active { transform: scale(0.98); }
.nm-btn--primary { background: var(--accent); color: var(--white); box-shadow: 0 10px 28px rgba(0, 180, 198, 0.3); }
.nm-btn--primary:active { background: var(--accent-dark); box-shadow: 0 4px 12px rgba(0, 180, 198, 0.25); }
.nm-btn--dark { background: var(--dark); color: var(--white); }
.nm-btn--dark:active { background: var(--dark-3); }
.nm-btn--outline {
  background: rgba(255, 255, 255, 0.6);
  color: var(--text);
  border: 1.5px solid rgba(10, 22, 40, 0.18);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.nm-btn--outline:active { background: rgba(255, 255, 255, 0.9); }
.nm-btn--full { width: 100%; }

.nm-hero__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 28px;
  padding-top: 24px;
  border-top: 1px solid rgba(10, 22, 40, 0.12);
  font-size: 12px;
  color: var(--sub);
}
.nm-hero__meta strong { color: var(--text); font-weight: 700; }
.nm-hero__meta-dot { width: 3px; height: 3px; background: rgba(10, 22, 40, 0.28); border-radius: 50%; }

/* ------ ALTERNATING SECTIONS --------------------------------------- */
.nm-sect { padding: 56px 22px; }
.nm-sect--cream { background: var(--cream); color: var(--text); }
.nm-sect--white { background: var(--white); color: var(--text); }
.nm-sect--dark { background: var(--dark); color: var(--white); }
.nm-sect--warm { background: var(--cream-2); color: var(--text); }
.nm-sect--sky {
  background:
    radial-gradient(100% 60% at 90% 0%, rgba(0, 180, 198, 0.18) 0%, transparent 60%),
    linear-gradient(170deg, #E6F7F9 0%, #F3FAFB 50%, #FBF8F5 100%);
  color: var(--text);
  position: relative;
  overflow: hidden;
}

.nm-eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent-dark);
  margin: 0 0 12px;
}
.nm-sect--dark .nm-eyebrow { color: var(--accent); }

.nm-h2 {
  font-family: 'DM Sans', sans-serif;
  font-size: 34px;
  line-height: 1.08;
  font-weight: 800;
  letter-spacing: -0.9px;
  margin: 0 0 14px;
  color: inherit;
}
.nm-lede {
  font-size: 16px;
  line-height: 1.55;
  color: var(--sub);
  margin: 0 0 28px;
  max-width: 34ch;
}
.nm-sect--dark .nm-lede { color: rgba(255, 255, 255, 0.72); }

/* ------ 2-COLUMN PRODUCT GRID (the Hims protocol grid) ------------- */
.nm-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.nm-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  display: flex;
  flex-direction: column;
  box-shadow: 0 1px 3px rgba(10, 22, 40, 0.04);
  border: 1px solid rgba(10, 22, 40, 0.05);
  transition: transform 0.12s ease, box-shadow 0.25s ease;
}
.nm-card:active { transform: scale(0.98); }
.nm-sect--dark .nm-card { background: var(--white); color: var(--text); }
.nm-card__img {
  aspect-ratio: 4 / 5;
  background: var(--cream-2);
  overflow: hidden;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}
.nm-card__img img { width: 100%; height: 100%; object-fit: cover; object-position: center 30%; }
/* Gradient protocol tiles (when no photo available) */
.nm-card__tile {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.nm-card__tile::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -20%;
  width: 70%;
  aspect-ratio: 1;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.18) 0%, transparent 60%);
  pointer-events: none;
}
.nm-card__letter {
  font-family: 'DM Sans', sans-serif;
  font-size: 96px;
  font-weight: 800;
  letter-spacing: -5px;
  color: rgba(255, 255, 255, 0.96);
  line-height: 1;
  z-index: 1;
  position: relative;
}
/* Per-protocol tile colors — each protocol has a unique gradient */
.nm-tile--shed   { background: linear-gradient(155deg, #00B4C6 0%, #008B9A 100%); }
.nm-tile--drive  { background: linear-gradient(155deg, #0A1628 0%, #1B3A5F 100%); }
.nm-tile--rewind { background: linear-gradient(155deg, #5B4B8A 0%, #2C1F4A 100%); }
.nm-tile--ignite { background: linear-gradient(155deg, #D4742C 0%, #7A3A10 100%); }
.nm-tile--desire { background: linear-gradient(155deg, #B8355A 0%, #5A1425 100%); }
.nm-tile--burn   { background: linear-gradient(155deg, #E2574C 0%, #8A1E15 100%); }
.nm-tile--glow   { background: linear-gradient(155deg, #E8C08A 0%, #A0742A 100%); }
.nm-tile--quiz   { background: linear-gradient(155deg, #0D1B2A 0%, #00B4C6 120%); }
.nm-card__body {
  padding: 16px 14px 18px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.nm-card__title {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.3px;
  line-height: 1.15;
  margin: 0 0 4px;
  color: var(--text);
}
.nm-card__tag {
  font-size: 12px;
  color: var(--mute);
  font-weight: 500;
  margin: 0 0 10px;
  line-height: 1.35;
}
.nm-card__price {
  font-size: 13px;
  color: var(--sub);
  margin: auto 0 10px;
}
.nm-card__price strong { color: var(--text); font-weight: 800; }
.nm-card__cta {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-top: 1px solid rgba(10, 22, 40, 0.08);
  padding-top: 12px;
  margin-top: auto;
}
.nm-card__cta::after { content: '→'; font-size: 15px; }

/* ------ CATEGORY HERO ROWS (full-bleed tiles) ---------------------- */
.nm-cat-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.nm-cat-tile {
  display: block;
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-lg);
  overflow: hidden;
  text-decoration: none;
  color: var(--white);
}
.nm-cat-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.nm-cat-tile::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(10, 22, 40, 0.82) 0%, rgba(10, 22, 40, 0.12) 70%);
}
.nm-cat-tile__content {
  position: absolute;
  left: 22px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 1;
  max-width: 60%;
}
.nm-cat-tile__kicker {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--accent);
  margin: 0 0 6px;
}
.nm-cat-tile__label {
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.4px;
  margin: 0 0 10px;
  line-height: 1.1;
}
.nm-cat-tile__arrow {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--white);
}
.nm-cat-tile__arrow::after { content: '→'; }

/* ------ BIG STAT BLOCK (social proof) ------------------------------ */
.nm-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-top: 28px;
}
.nm-sect--cream .nm-stats, .nm-sect--white .nm-stats, .nm-sect--sky .nm-stats {
  background: rgba(10, 22, 40, 0.1);
  border-color: rgba(10, 22, 40, 0.1);
}
.nm-stat {
  background: var(--dark);
  padding: 24px 18px;
  text-align: left;
}
.nm-sect--cream .nm-stat, .nm-sect--white .nm-stat { background: var(--cream); color: var(--text); }
.nm-sect--sky .nm-stat { background: rgba(255, 255, 255, 0.75); color: var(--text); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.nm-stat__num {
  font-size: 34px;
  font-weight: 800;
  letter-spacing: -1px;
  line-height: 1;
  margin: 0 0 8px;
  color: var(--white);
}
.nm-sect--cream .nm-stat__num, .nm-sect--white .nm-stat__num, .nm-sect--sky .nm-stat__num { color: var(--text); }
.nm-stat__label {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.65);
  line-height: 1.4;
  margin: 0;
  font-weight: 500;
}
.nm-sect--cream .nm-stat__label, .nm-sect--white .nm-stat__label, .nm-sect--sky .nm-stat__label { color: var(--sub); }

/* ------ HOW IT WORKS (3 steps, Hims-minimal) ----------------------- */
.nm-steps { display: flex; flex-direction: column; gap: 0; }
.nm-step {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 22px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}
.nm-sect--cream .nm-step, .nm-sect--white .nm-step, .nm-sect--warm .nm-step {
  border-bottom-color: rgba(10, 22, 40, 0.1);
}
.nm-step:last-child { border-bottom: none; }
.nm-step__num {
  flex: 0 0 auto;
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -1.5px;
  line-height: 1;
  color: var(--accent);
  min-width: 46px;
}
.nm-step__title {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.3px;
  margin: 0 0 6px;
  line-height: 1.2;
}
.nm-step__body {
  font-size: 14px;
  line-height: 1.55;
  color: var(--sub);
  margin: 0;
}
.nm-sect--dark .nm-step__body { color: rgba(255, 255, 255, 0.68); }

/* ------ TESTIMONIAL / REVIEW BLOCK --------------------------------- */
.nm-review {
  background: var(--white);
  border: 1px solid rgba(10, 22, 40, 0.08);
  border-radius: var(--radius-lg);
  padding: 24px 22px;
  margin-top: 18px;
}
.nm-review__stars {
  color: var(--accent);
  font-size: 16px;
  letter-spacing: 2px;
  margin-bottom: 12px;
}
.nm-review__quote {
  font-size: 17px;
  line-height: 1.45;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 16px;
  letter-spacing: -0.3px;
}
.nm-review__author {
  font-size: 13px;
  color: var(--mute);
  font-weight: 500;
  margin: 0;
}

/* ------ FAQ (Hims-style expandable rows) --------------------------- */
.nm-faq { margin-top: 12px; }
.nm-faq__item {
  border-top: 1px solid rgba(10, 22, 40, 0.12);
  padding: 22px 0;
}
.nm-faq__item:last-child { border-bottom: 1px solid rgba(10, 22, 40, 0.12); }
.nm-sect--dark .nm-faq__item { border-color: rgba(255, 255, 255, 0.14); }
.nm-faq summary {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.2px;
  color: inherit;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}
.nm-faq summary::-webkit-details-marker { display: none; }
.nm-faq summary::after {
  content: '+';
  font-size: 24px;
  font-weight: 400;
  color: var(--mute);
  transition: transform 0.2s ease;
}
.nm-faq[open] summary::after { content: '−'; }
.nm-faq__body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--sub);
  margin: 12px 0 0;
}
.nm-sect--dark .nm-faq__body { color: rgba(255, 255, 255, 0.72); }

/* ------ FOOTER (Hims-style: dark, tight, grouped) ------------------ */
.nm-footer {
  background: var(--dark);
  color: rgba(255, 255, 255, 0.72);
  padding: 48px 22px calc(140px + var(--safe-bottom));
  font-size: 14px;
}
.nm-footer__logo {
  font-family: 'DM Sans', sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 6px;
  text-transform: uppercase;
  display: block;
  margin-bottom: 14px;
}
.nm-footer__tag {
  font-size: 13px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.55);
  margin: 0 0 32px;
  max-width: 28ch;
}
.nm-footer__group { margin-bottom: 20px; }
.nm-footer__group summary {
  list-style: none;
  cursor: pointer;
  padding: 14px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.nm-footer__group summary::-webkit-details-marker { display: none; }
.nm-footer__group summary::after { content: '+'; font-size: 20px; font-weight: 400; color: rgba(255, 255, 255, 0.5); }
.nm-footer__group[open] summary::after { content: '−'; }
.nm-footer__group a {
  display: block;
  padding: 10px 0;
  color: rgba(255, 255, 255, 0.72);
  text-decoration: none;
  font-size: 14px;
}
.nm-footer__legal {
  margin-top: 32px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 11px;
  color: rgba(255, 255, 255, 0.45);
  line-height: 1.6;
}

/* ------ STICKY BOTTOM CTA (Hims-style: dark pill) ------------------ */
.nm-sticky {
  position: fixed;
  left: 0; right: 0;
  bottom: 0;
  z-index: 10000;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom, 0px));
  padding-left: calc(16px + env(safe-area-inset-left, 0px));
  padding-right: calc(16px + env(safe-area-inset-right, 0px));
  background: rgba(251, 248, 245, 0.96);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  backdrop-filter: blur(20px) saturate(1.2);
  border-top: 1px solid rgba(10, 22, 40, 0.08);
  /* Always visible — never hides on scroll */
}
.nm-sticky__btn,
a.nm-sticky__btn {
  display: block !important;
  width: 100% !important;
  padding: 17px 22px !important;
  background: #00B4C6 !important;
  color: #ffffff !important;
  font-family: 'DM Sans', sans-serif !important;
  font-size: 16px !important;
  font-weight: 700 !important;
  border: none !important;
  border-radius: 100px !important;
  text-align: center !important;
  text-decoration: none !important;
  letter-spacing: -0.1px !important;
  box-shadow: 0 10px 28px rgba(0, 180, 198, 0.32) !important;
  -webkit-tap-highlight-color: transparent;
  box-sizing: border-box;
}
.nm-sticky__btn:active,
a.nm-sticky__btn:active {
  background: #009DAE !important;
  transform: scale(0.98);
}

/* Suppress the legacy bottom CTA on redesigned pages */
@media (max-width: 820px) {
  body.nm-redesigned .nm-bottom-cta { display: none !important; }
}

/* ------ SELF-CONTAINED MOBILE DRAWER (pure CSS via checkbox) ------- */
@media (max-width: 820px) {
  /* Hidden checkbox drives the drawer */
  .nmd-toggle {
    position: absolute;
    opacity: 0;
    pointer-events: none;
    width: 0;
    height: 0;
  }
  .nmd-backdrop {
    position: fixed;
    inset: 0;
    background: rgba(10, 22, 40, 0);
    z-index: 10000;
    pointer-events: none;
    transition: background 0.3s ease;
    cursor: pointer;
  }
  .nmd-toggle:checked ~ .nmd-backdrop {
    background: rgba(10, 22, 40, 0.55);
    pointer-events: auto;
  }
  .nmd-drawer {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    width: min(88vw, 380px);
    background: #FBF8F5;
    z-index: 10001;
    transform: translateX(100%);
    transition: transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: transform;
    display: flex;
    flex-direction: column;
    font-family: 'DM Sans', sans-serif;
    box-shadow: -20px 0 60px rgba(10, 22, 40, 0.25);
  }
  .nmd-toggle:checked ~ .nmd-drawer { transform: translateX(0); }
  /* When open, lock body scroll via :has() (Safari 16.4+, Chrome 105+) */
  body:has(.nmd-toggle:checked) { overflow: hidden; }

  .nmd-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: calc(14px + env(safe-area-inset-top, 0px)) 20px 14px;
    border-bottom: 1px solid rgba(10, 22, 40, 0.08);
    background: #FBF8F5;
    position: sticky;
    top: 0;
    z-index: 1;
  }
  .nmd-logo {
    font-family: 'DM Sans', sans-serif;
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 5px;
    color: #00B4C6;
    text-transform: uppercase;
    text-decoration: none;
  }
  .nmd-close {
    width: 44px;
    height: 44px;
    border: none;
    background: transparent;
    font-size: 32px;
    line-height: 1;
    color: #0A1628;
    cursor: pointer;
    border-radius: 10px;
    padding: 0;
  }
  .nmd-close:active { background: rgba(10, 22, 40, 0.08); }

  .nmd-body {
    flex: 1;
    overflow-y: auto;
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    padding: 8px 20px calc(32px + env(safe-area-inset-bottom, 0px));
  }

  .nmd-group { padding: 20px 0; border-bottom: 1px solid rgba(10, 22, 40, 0.06); }
  .nmd-group:last-of-type { border-bottom: none; }
  .nmd-group h4 {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #9B9B9B;
    margin: 0 0 14px;
  }
  .nmd-link {
    display: block;
    padding: 12px 0;
    text-decoration: none;
    color: #0A1628;
    border-bottom: 1px solid rgba(10, 22, 40, 0.05);
  }
  .nmd-link:last-child { border-bottom: none; }
  .nmd-link:active { opacity: 0.6; }
  .nmd-link strong {
    display: block;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: -0.2px;
    line-height: 1.3;
  }
  .nmd-link span {
    display: block;
    font-size: 13px;
    color: #6B6B6B;
    margin-top: 2px;
  }

  .nmd-cta {
    display: block;
    width: 100%;
    margin-top: 20px;
    padding: 17px 22px;
    background: #0A1628;
    color: #fff;
    font-size: 15px;
    font-weight: 700;
    border: none;
    border-radius: 100px;
    text-align: center;
    text-decoration: none;
    letter-spacing: -0.1px;
  }
}

/* ------ REVEAL ON SCROLL ------------------------------------------- */
@media (max-width: 820px) {
  .nm-fade {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.6s ease, transform 0.6s cubic-bezier(0.22, 1, 0.36, 1);
  }
  .nm-fade.is-in { opacity: 1; transform: none; }
  @media (prefers-reduced-motion: reduce) {
    .nm-fade { opacity: 1; transform: none; transition: none; }
  }
}
