html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
body {
  font-family: 'Inter', sans-serif;
  background: radial-gradient(circle at top right, #26253b 0%, #171722 35%, #0f1017 75%, #090a0f 100%);
}

::selection { background: #3E8FD0; color: #fff; }
a, button { -webkit-tap-highlight-color: transparent; }

/* ---------- researcher verification gate ---------- */
.age-gate {
  position: fixed; inset: 0; z-index: 300;
  display: flex; align-items: center; justify-content: center;
  padding: 1.25rem;
  background: rgba(2,6,14,0.9);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.age-gate[hidden] { display: none; }
body.age-gate-open { overflow: hidden; }
.age-gate__panel {
  width: 100%; max-width: 26rem; max-height: 92vh; overflow-y: auto;
  background: #050D1A;
  border: 1px solid rgba(143,163,189,0.16);
  border-radius: 0.25rem;
  padding: 2rem;
}
.age-gate__eyebrow-rule {
  display: inline-block; width: 1.5rem; height: 1px;
  background: linear-gradient(90deg, #6FCF57, #3E8FD0);
}
.age-gate__option {
  display: flex; align-items: flex-start; gap: 0.75rem;
  border: 1px solid rgba(143,163,189,0.16);
  border-radius: 0.25rem;
  padding: 0.875rem 1rem;
  margin-top: 0.75rem;
  cursor: pointer;
  font-size: 13.5px; line-height: 1.6; color: rgba(226,230,236,0.78);
  transition: border-color .2s;
}
.age-gate__option:hover { border-color: rgba(255,255,255,0.32); }
.age-gate__checkbox {
  appearance: none; -webkit-appearance: none; flex-shrink: 0;
  width: 1.125rem; height: 1.125rem; margin-top: 0.15rem;
  border: 1px solid rgba(143,163,189,0.45);
  border-radius: 3px;
  position: relative;
  cursor: pointer;
}
.age-gate__checkbox:checked { border-color: #3E8FD0; background: #3E8FD0; }
.age-gate__checkbox:checked::after {
  content: ''; position: absolute; left: 5px; top: 1px;
  width: 4px; height: 9px;
  border: solid #050D1A; border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}
.age-gate__submit {
  width: 100%; margin-top: 1.25rem;
  padding: 0.9rem 1rem;
  border-radius: 0.25rem; border: none;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 500; font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase;
  background: rgba(143,163,189,0.12); color: rgba(226,230,236,0.35);
  display: flex; align-items: center; justify-content: center; gap: 0.5rem;
  cursor: not-allowed;
  transition: background .2s, color .2s;
}
.age-gate__submit:not(:disabled),
#age-gate-submit:not(:disabled) {
  background: linear-gradient(90deg, #6FCF57, #3E8FD0);
  color: #050D1A !important; cursor: pointer;
}

/* ---------- sold out (catalog card + popup) ---------- */
.sold-out-badge {
  color: #F2A7A9;
  border: 1px solid rgba(229,72,77,0.5);
  background: rgba(229,72,77,0.1);
}
.sold-out-badge[hidden] { display: none; }
.restock-form[hidden], #restock-status[hidden] { display: none; }
.restock-hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* ---------- peptide detail popup (catalog) ---------- */
.catalog-card { cursor: pointer; }
.peptide-modal {
  position: fixed; inset: 0; z-index: 200;
  display: flex; align-items: center; justify-content: center;
  padding: 1rem;
  background: rgba(2,6,14,0.82);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
  opacity: 0; transition: opacity .25s ease;
}
.peptide-modal[hidden] { display: none; }
.peptide-modal.is-open { opacity: 1; }
body.peptide-modal-open { overflow: hidden; }
.peptide-modal__panel {
  position: relative;
  width: min(83vw, 90rem); height: min(83vh, 57.5rem);
  min-height: min(37.5rem, 92vh);
  display: grid; grid-template-columns: 2fr 3fr;
  background: #050D1A;
  border: 1px solid rgba(143,163,189,0.16);
  border-radius: 0.25rem;
  overflow: hidden;
  transform: translateY(12px) scale(.98);
  transition: transform .3s cubic-bezier(0.16,1,0.3,1);
}
.peptide-modal.is-open .peptide-modal__panel { transform: none; }
.peptide-modal__media {
  position: relative; min-height: 0;
  background: radial-gradient(circle at 50% 45%, rgba(62,143,208,0.16), rgba(5,13,26,0) 65%);
  border-right: 1px solid rgba(143,163,189,0.16);
}
.peptide-modal__vial { position: absolute; inset: 9% 1.5rem; width: calc(100% - 3rem); height: 82%; object-fit: contain; }
.peptide-modal__body { overflow-y: auto; padding: 2.5rem 2.5rem 2rem; }
.peptide-modal__close {
  position: absolute; top: 0.875rem; right: 0.875rem; z-index: 1;
  width: 2.25rem; height: 2.25rem;
  display: flex; align-items: center; justify-content: center;
  color: rgba(226,230,236,0.78);
  border: 1px solid rgba(143,163,189,0.16); border-radius: 0.25rem;
  background: rgba(5,13,26,0.8);
  transition: color .2s, border-color .2s;
}
.peptide-modal__close:hover { color: #fff; border-color: rgba(255,255,255,0.32); }
.peptide-modal__btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.8rem 1.25rem;
  border: 1px solid rgba(143,163,189,0.16); border-radius: 0.25rem;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 500; font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: rgba(226,230,236,0.78);
  transition: color .2s, border-color .2s, opacity .2s;
}
.peptide-modal__btn:hover { color: #fff; border-color: rgba(255,255,255,0.32); }
.peptide-modal__btn--primary {
  border: none; color: #050D1A;
  background: linear-gradient(90deg, #6FCF57, #3E8FD0);
}
.peptide-modal__btn--primary:hover { color: #050D1A; opacity: .9; }
.peptide-modal__btn--primary[aria-disabled="true"] {
  background: rgba(143,163,189,0.12); color: rgba(226,230,236,0.35); cursor: not-allowed; opacity: 1;
}
.peptide-modal__specs {
  display: grid; grid-template-columns: max-content 1fr; gap: 0.625rem 1.5rem;
  font-size: 13.5px;
}
.peptide-modal__specs dt { color: rgba(143,163,189,0.68); }
.peptide-modal__specs dd { color: rgba(226,230,236,0.92); min-width: 0; overflow-wrap: anywhere; }
@media (max-width: 1024px) {
  .peptide-modal__panel { width: min(92vw, 60rem); }
}
@media (max-width: 767px) {
  .peptide-modal__panel {
    width: 100%; height: auto; max-height: 92vh; min-height: 0;
    grid-template-columns: 1fr; grid-template-rows: auto 1fr;
  }
  .peptide-modal__media { height: 13rem; border-right: none; border-bottom: 1px solid rgba(143,163,189,0.16); }
  .peptide-modal__body { padding: 1.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  .peptide-modal, .peptide-modal__panel { transition: none; }
}

.focus-ring:focus-visible {
  outline: 2px solid #6FCF57;
  outline-offset: 3px;
  border-radius: 2px;
}

/* ---------- gradient text / fills (Helix Gradient: 135deg, Green -> Blue) ---------- */
.grad-text {
  background-image: linear-gradient(135deg, #6FCF57, #3E8FD0);
  background-color: #fff;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.grad-fill { background-image: linear-gradient(135deg, #6FCF57, #3E8FD0); }

/* ---------- grain overlay ---------- */
.grain { position: absolute; inset: 0; pointer-events: none; mix-blend-mode: overlay; opacity: 0.5; }

/* ---------- reveal-on-scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.9s cubic-bezier(0.16,1,0.3,1), transform 0.9s cubic-bezier(0.16,1,0.3,1);
}
.reveal.is-visible { opacity: 1; transform: translateY(0); }
@media (prefers-reduced-motion: reduce) {
  .reveal { transition: none; opacity: 1; transform: none; }
}

/* ---------- header ---------- */
.site-header { position: fixed; top: 0; inset-inline: 0; z-index: 40; }
.site-header .tag { transition: opacity .3s cubic-bezier(.39,.575,.565,1) .3s; }
@media (prefers-reduced-motion: reduce) {
  .site-header .tag { transition: none; }
}

/* ---------- full-screen menu ---------- */
.menu-overlay {
  position: fixed; inset: 0; z-index: 50;
  background: radial-gradient(circle at top right, #26253b 0%, #171722 35%, #0f1017 75%, #090a0f 100%);
  opacity: 0; visibility: hidden;
  transition: opacity .45s cubic-bezier(.39,.575,.565,1), visibility 0s linear .45s;
}
.menu-overlay.is-open {
  opacity: 1; visibility: visible;
  transition: opacity .45s cubic-bezier(.39,.575,.565,1);
}
.menu-overlay::before {
  content: '';
  position: absolute; top: -30%; left: -20%;
  width: 70%; height: 160%;
  background: radial-gradient(closest-side, rgba(62,143,208,0.2), rgba(62,143,208,0) 70%);
  pointer-events: none;
}
.menu-primary a { font-family: 'Space Grotesk', sans-serif; }

/* ---------- scanline (COA-style card, reused for stat panel) ---------- */
@keyframes scanline {
  0%   { top: -20%; opacity: 0; }
  8%   { opacity: 1; }
  92%  { opacity: 1; }
  100% { top: 105%; opacity: 0; }
}
.scanline { position: relative; overflow: hidden; }
.scanline::after {
  content: '';
  position: absolute; left: 0; right: 0; top: -20%;
  height: 26%;
  background: linear-gradient(180deg, rgba(111,207,87,0) 0%, rgba(111,207,87,0.14) 45%, rgba(62,143,208,0.14) 55%, rgba(62,143,208,0) 100%);
  animation: scanline 6s cubic-bezier(0.65,0,0.35,1) infinite;
  pointer-events: none;
}
@media (prefers-reduced-motion: reduce) {
  .scanline::after { animation: none; display: none; }
}

/* ---------- stat circles ---------- */
.stat-circle {
  position: relative;
  width: 100%;
  max-width: 15.625rem;
  aspect-ratio: 1;
  border-radius: 9999px;
  border: 1px solid rgba(244,246,249,0.3);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto;
  opacity: 0;
  transform: scale(0.85);
  transition: opacity .8s cubic-bezier(.16,1,.3,1), transform .8s cubic-bezier(.16,1,.3,1);
}
.stat-circle.is-visible { opacity: 1; transform: scale(1); }
.stat-circle.ring-accent { border-color: #3E8FD0; }
.stat-circle.ring-muted { border-color: rgba(143,163,189,0.4); }
.stat-circle__value { font-family: 'Space Grotesk', sans-serif; font-weight: 500; font-size: 2.75rem; color: #F4F6F9; font-variant-numeric: tabular-nums; }
.stat-circle__label {
  position: absolute; top: calc(100% + 1.25rem); left: 50%; transform: translateX(-50%);
  width: 13.75rem; text-align: center;
  font-weight: 400; font-size: 0.9375rem; line-height: 1.5em; color: rgba(226,230,236,0.62);
}
@media (prefers-reduced-motion: reduce) {
  .stat-circle { transition: none; opacity: 1; transform: none; }
}

/* ---------- parallax image block ---------- */
.parallax-frame { position: relative; overflow: hidden; border-radius: 2px; }
.parallax-frame img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  transform: scale(1.25);
  will-change: transform;
}
.parallax-frame::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(5,13,26,0) 40%, rgba(5,13,26,0.8) 100%), linear-gradient(100deg, rgba(62,143,208,0.35), rgba(62,143,208,0) 60%);
  mix-blend-mode: multiply;
}

/* ---------- background DNA helix canvas ---------- */
/* Fixed full-viewport layer behind all page content; stays put while the
   page scrolls over it. See dna-helix.js. */
.hero-canvas-wrap {
  position: fixed; top: 0; left: 0; width: 100%; height: 100%;
  pointer-events: none; z-index: -1; overflow: hidden;
}
.hero-canvas-wrap canvas { display: block; width: 100%; height: 100%; }

/* ---------- buttons (text + underline, matches reference) ---------- */
.btn {
  position: relative;
  display: inline-flex; flex-direction: column; align-items: flex-start; gap: 0.6rem;
  padding: 0 0 0.5rem;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 500; font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase;
  color: #F4F6F9;
}
.btn .btn-underline {
  width: 2.25rem; height: 1px;
  background: linear-gradient(90deg, #6FCF57, #3E8FD0);
  transition: width .3s cubic-bezier(.39,.575,.565,1);
}
.btn:hover .btn-underline { width: 3.5rem; }

/* ---------- eyebrow ---------- */
.eyebrow { font-family: 'Space Grotesk', sans-serif; font-weight: 500; font-size: 0.75rem; letter-spacing: 0.18em; text-transform: uppercase; }

/* ---------- data / technical labels (lot numbers, legal nav, badges) ---------- */
.font-data { font-family: 'Inter', sans-serif; font-variant-numeric: tabular-nums; letter-spacing: 0.03em; }

/* ---------- scroll indicator ---------- */
.scroll-indicator { opacity: 0; transition: opacity .5s ease .6s; }
.scroll-indicator.is-visible { opacity: 1; }
.scroll-indicator__line { width: 2px; height: 3.5rem; background: linear-gradient(180deg, #6FCF57, #3E8FD0); }
