/* =============================================================================
   Mypeptides storefront — generated baseline.
   =============================================================================
   This is a STARTER stylesheet. The palette tokens, typography choices, and
   structural styles below produce a launchable but visually generic brand
   storefront. Hand it to a designer.

   The compliance chassis (age gate, RUO/FDA disclaimer footer, no-therapeutic-
   claims grep, cross-store isolation) is wired automatically and does not
   depend on this stylesheet. You can rewrite this file end-to-end without
   breaking compliance.
   ============================================================================= */

/* Palette tokens — edit these first. The rest of the stylesheet pulls
   from these CSS variables, so a one-line edit at the top changes
   every component. */
.mypeptides {
  --color-bg: #ffffff;
  --color-surface: #f7f7f8;
  --color-accent: #111111;
  --color-text: #111111;
  --color-muted: #6b7280;
  --color-subtle: #e5e7eb;
  --color-border: #e5e7eb;

  background: var(--color-bg);
  color: var(--color-text);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  margin: 0;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.mypeptides main { display: block; }

.mypeptides a {
  color: var(--color-accent);
  text-decoration: none;
}

.mypeptides a:hover { text-decoration: underline; }

.mypeptides h1, .mypeptides h2, .mypeptides h3, .mypeptides h4 {
  margin: 0 0 0.5em;
  color: var(--color-text);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.1;
}

.mypeptides h1 { font-size: clamp(36px, 5vw, 48px); }
.mypeptides h2 { font-size: clamp(24px, 3.5vw, 32px); font-weight: 600; }
.mypeptides h3 { font-size: clamp(18px, 2.5vw, 22px); font-weight: 600; }

.mypeptides p {
  margin: 0 0 1em;
  font-size: 16px;
  line-height: 1.6;
  color: var(--color-text);
}

.mypeptides p.muted { color: var(--color-muted); }

/* ----- Nav header ----------------------------------------------------- */
.mypeptides-nav {
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg);
}
.mypeptides-nav__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 16px 24px;
}
.mypeptides-nav__brand {
  font-weight: 800;
  font-size: 20px;
  color: var(--color-text);
}
.mypeptides-nav__links {
  display: flex;
  align-items: center;
  gap: 24px;
}
.mypeptides-nav__link {
  color: var(--color-text);
  font-weight: 600;
}
.mypeptides-nav__cart {
  background: var(--color-accent);
  color: var(--color-bg);
  border: none;
  padding: 10px 20px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
}

/* ----- Hero ----------------------------------------------------------- */
.mypeptides-hero {
  padding: 80px 24px;
  text-align: center;
  background: var(--color-surface);
}
.mypeptides-hero__inner { max-width: 800px; margin: 0 auto; }
.mypeptides-hero__wordmark { margin-bottom: 16px; }
.mypeptides-hero__tagline { font-size: 20px; color: var(--color-muted); margin-bottom: 32px; }
.mypeptides-hero__cta {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-bg);
  padding: 14px 32px;
  font-weight: 600;
}
.mypeptides-hero__cta:hover { text-decoration: none; opacity: 0.9; }

/* ----- Trust strip ---------------------------------------------------- */
.mypeptides-trust-strip {
  border-bottom: 1px solid var(--color-border);
  padding: 16px 24px;
}
.mypeptides-trust-strip__inner {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
  font-size: 14px;
  color: var(--color-muted);
}

/* ----- Product grid (home + shop) ------------------------------------ */
.mypeptides-grid-section { padding: 64px 24px; }
.mypeptides-grid-section__inner { max-width: 1200px; margin: 0 auto; }
.mypeptides-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  list-style: none;
  padding: 0;
  margin: 0;
}
@media (max-width: 900px) { .mypeptides-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) { .mypeptides-grid { grid-template-columns: 1fr; } }

.mypeptides-card {
  background: var(--color-surface);
  border: 1px solid var(--color-border);
  padding: 24px;
}
.mypeptides-card__link { display: block; color: var(--color-text); }
.mypeptides-card__tagline { font-size: 12px; text-transform: uppercase; color: var(--color-muted); margin-bottom: 8px; }
.mypeptides-card__name { font-size: 22px; margin-bottom: 8px; }
.mypeptides-card__dose { font-size: 14px; color: var(--color-muted); }
.mypeptides-card__view { display: inline-block; margin-top: 16px; font-weight: 600; color: var(--color-accent); }

/* ----- Filter bar ----------------------------------------------------- */
.mypeptides-filter-bar {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  padding: 16px 0;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 32px;
}
.mypeptides-filter-bar__chip {
  padding: 8px 16px;
  border: 1px solid var(--color-border);
  color: var(--color-text);
  font-size: 14px;
}
.mypeptides-filter-bar__chip--active {
  background: var(--color-accent);
  color: var(--color-bg);
  border-color: var(--color-accent);
}

/* ----- PDP ------------------------------------------------------------ */
.mypeptides-pdp { padding: 64px 24px; }
.mypeptides-pdp__inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  max-width: 1200px;
  margin: 0 auto;
}
@media (max-width: 800px) { .mypeptides-pdp__inner { grid-template-columns: 1fr; } }
.mypeptides-pdp__image {
  background: var(--color-surface);
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-muted);
}
.mypeptides-pdp__data { }
.mypeptides-pdp__add {
  display: inline-block;
  background: var(--color-accent);
  color: var(--color-bg);
  padding: 14px 32px;
  font-weight: 600;
  border: none;
  font-family: inherit;
  cursor: pointer;
  margin-top: 16px;
}
.mypeptides-pdp__qty {
  width: 80px;
  padding: 10px;
  border: 1px solid var(--color-border);
  font-size: 16px;
  font-family: inherit;
}

/* ----- Cart ----------------------------------------------------------- */
.mypeptides-cart { padding: 64px 24px; max-width: 1200px; margin: 0 auto; }
.mypeptides-cart__items { width: 100%; border-collapse: collapse; margin-bottom: 24px; }
.mypeptides-cart__items th,
.mypeptides-cart__items td {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}
.mypeptides-cart__total { font-size: 24px; font-weight: 700; text-align: right; }

/* ----- Cart drawer ---------------------------------------------------- */
.mypeptides-cart-drawer {
  position: fixed;
  inset: 0;
  z-index: 900;
  pointer-events: none;
}
.mypeptides-cart-drawer--open { pointer-events: auto; }
.mypeptides-cart-drawer__scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.4);
  opacity: 0;
  transition: opacity 0.3s ease;
}
.mypeptides-cart-drawer--open .mypeptides-cart-drawer__scrim { opacity: 1; }
.mypeptides-cart-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  max-width: 420px;
  background: var(--color-bg);
  transform: translateX(100%);
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 24px rgba(0, 0, 0, 0.15);
}
.mypeptides-cart-drawer--open .mypeptides-cart-drawer__panel { transform: translateX(0); }
.mypeptides-cart-drawer__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px;
  border-bottom: 1px solid var(--color-border);
}
.mypeptides-cart-drawer__close {
  background: none;
  border: none;
  font-size: 32px;
  line-height: 1;
  cursor: pointer;
  color: var(--color-text);
}
.mypeptides-cart-drawer__list {
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  overflow-y: auto;
}
.mypeptides-cart-drawer__row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  padding: 16px 24px;
  border-bottom: 1px solid var(--color-border);
}
.mypeptides-cart-drawer__row-thumb {
  width: 64px;
  height: 64px;
  background: var(--color-surface);
  display: flex;
  align-items: center;
  justify-content: center;
}
.mypeptides-cart-drawer__row-thumb-name {
  font-size: 10px;
  text-align: center;
  color: var(--color-muted);
  padding: 4px;
}
.mypeptides-cart-drawer__footer {
  padding: 24px;
  border-top: 1px solid var(--color-border);
}
.mypeptides-cart-drawer__subtotal {
  display: flex;
  justify-content: space-between;
  margin-bottom: 16px;
  font-size: 18px;
}
.mypeptides-cart-drawer__checkout {
  display: block;
  text-align: center;
  background: var(--color-accent);
  color: var(--color-bg);
  padding: 14px;
  font-weight: 600;
  margin-bottom: 8px;
}
.mypeptides-cart-drawer__view-cart {
  display: block;
  text-align: center;
  font-size: 14px;
  color: var(--color-muted);
}

/* Cross-portfolio attach card (PORTFOLIO_PLAN.md §4.1). */
.mypeptides-cart-drawer__bacwater-attach {
  border-top: 1px solid var(--color-border);
  padding: 16px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.mypeptides-cart-drawer__bacwater-card { display: flex; flex-direction: column; gap: 4px; }
.mypeptides-cart-drawer__bacwater-eyebrow {
  margin: 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--color-muted);
}
.mypeptides-cart-drawer__bacwater-name {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--color-text);
}
.mypeptides-cart-drawer__bacwater-price {
  margin: 0;
  font-size: 14px;
  color: var(--color-text);
}
.mypeptides-cart-drawer__bacwater-add {
  background: transparent;
  color: var(--color-accent);
  border: 1px solid var(--color-accent);
  padding: 12px 16px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border-radius: 2px;
  cursor: pointer;
}
.mypeptides-cart-drawer__bacwater-add:hover {
  background: var(--color-accent);
  color: var(--color-bg);
}
.mypeptides-cart-drawer__empty {
  padding: 48px 24px;
  text-align: center;
}

/* ----- Age gate modal ------------------------------------------------- */
.mypeptides-age-gate {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}
/* Chained-class selector beats Nutreko base.css's `div:empty {
   display: none }` rule — same fix as peprally + surfpeptides. The
   scrim is an empty <div>; without `display: block` it inherits
   none. (0,2,0) beats (0,1,1). */
.mypeptides-age-gate .mypeptides-age-gate__scrim {
  display: block;
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
.mypeptides-age-gate__card {
  position: relative;
  background: var(--color-bg);
  padding: 40px;
  max-width: 480px;
  width: calc(100% - 32px);
  text-align: center;
  border: 1px solid var(--color-border);
}
.mypeptides-age-gate__heading { margin-bottom: 16px; }
.mypeptides-age-gate__actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  margin: 24px 0;
}
.mypeptides-age-gate__btn {
  padding: 12px 24px;
  border: 1px solid var(--color-accent);
  font-family: inherit;
  font-weight: 600;
  cursor: pointer;
}
.mypeptides-age-gate__btn--primary {
  background: var(--color-accent);
  color: var(--color-bg);
}
.mypeptides-age-gate__btn--ghost {
  background: transparent;
  color: var(--color-text);
}
.mypeptides-age-gate__legal {
  font-size: 12px;
  color: var(--color-muted);
  margin-top: 16px;
}

/* ----- Compliance footer (shared partial — shape) -------------------- */
.mypeptides .brand-footer {
  background: var(--color-surface);
  border-top: 1px solid var(--color-border);
  padding: 48px 24px;
  margin-top: 64px;
}
.mypeptides .brand-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}
.mypeptides .brand-footer__nav {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 24px;
  margin-bottom: 24px;
}
.mypeptides .brand-footer__nav a {
  color: var(--color-text);
  font-size: 14px;
}
.mypeptides .brand-footer__ruo,
.mypeptides .brand-footer__fda,
.mypeptides .brand-footer__copy {
  font-size: 12px;
  color: var(--color-muted);
  margin-bottom: 8px;
}

/* ----- Content pages -------------------------------------------------- */
.mypeptides-content { padding: 64px 24px; max-width: 800px; margin: 0 auto; }
.mypeptides-content h1 { margin-bottom: 32px; }
.mypeptides-content h2 { margin-top: 48px; margin-bottom: 16px; }

/* ----- Lab Results (COAs) -------------------------------------------- */
.mypeptides-coas { padding: 64px 24px; max-width: 1200px; margin: 0 auto; }
.mypeptides-coas__hero {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 64px;
  padding: 32px;
  background: var(--color-surface);
}
@media (max-width: 800px) { .mypeptides-coas__hero { grid-template-columns: repeat(2, 1fr); } }
.mypeptides-coas__stat { text-align: center; }
.mypeptides-coas__stat-value { font-size: 32px; font-weight: 800; }
.mypeptides-coas__stat-label { font-size: 12px; text-transform: uppercase; color: var(--color-muted); }


/* Mypeptides shop is research-paper data-table not a card grid, but defensive
   override in case any inner grid component renders. */
.mypeptides .ap-productlist__inner {
  display: block !important;
  overflow: visible !important;
  margin: 0 !important;
}



.mypeptides ap-productfacet,
.mypeptides .ap-productfacet { display: block !important; }
.mypeptides .ap-productfacet__main { width: 100% !important; }


/* ----------------------------------------------------------------
   Nutreko2 home features — clinical trust strip + newsletter.
   Slideshow + carousel intentionally NOT wired here per brand voice
   (single-paragraph hero + tabular catalog is the §3.1 register).
   ---------------------------------------------------------------- */

/* Trust strip — research-paper data row. Two-up on mobile, four-up
   on desktop. Plex Mono for the values to lean into the clinical
   register. */
body.mypeptides .mp-home__trust-strip {
  background: #FFFFFF;
  border-top: 1px solid #E5E0D6;
  border-bottom: 1px solid #E5E0D6;
  padding: 32px 24px;
}
body.mypeptides .mp-home__trust-strip-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}
@media (min-width: 800px) {
  body.mypeptides .mp-home__trust-strip-inner {
    grid-template-columns: repeat(4, 1fr);
  }
}
body.mypeptides .mp-home__trust-item {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-left: 16px;
  border-left: 2px solid #1B4965;
}
body.mypeptides .mp-home__trust-key {
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-size: 11px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: #5A6E7A;
}
body.mypeptides .mp-home__trust-value {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 14px;
  font-weight: 500;
  color: #1B4965;
}

/* Newsletter — light/clinical surface, navy headline. Form uses the
   ingested .newsletter-form / .field__input class names. */
body.mypeptides .brand-newsletter-section {
  background: #FAFAF7;
  border-top: 1px solid #E5E0D6;
  padding: 80px 24px;
}
body.mypeptides .brand-newsletter-section__inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: left;
}
body.mypeptides .brand-newsletter-section__heading {
  margin: 0 0 12px;
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-weight: 300;
  font-size: clamp(28px, 4vw, 40px);
  letter-spacing: -0.01em;
  color: #1B4965;
}
body.mypeptides .brand-newsletter-section__body {
  margin: 0 0 24px;
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-size: 15px;
  line-height: 1.65;
  color: #5A6E7A;
}
body.mypeptides .brand-newsletter-section .field__input {
  background: #FFFFFF;
  border: 1px solid #C6D5DE;
  color: #1B4965;
  padding: 14px 16px;
  width: 100%;
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-size: 15px;
  border-radius: 0; /* Square corners read clinical, not consumer. */
}
body.mypeptides .brand-newsletter-section .newsletter-form__button {
  background: #1B4965;
  color: #FAFAF7;
  border: 0;
  border-radius: 0;
  margin-top: 12px;
  padding: 14px 22px;
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}
body.mypeptides .brand-newsletter-section .newsletter-form__message--success {
  color: #2C6E5C;
  margin-top: 0;
  margin-bottom: 24px;
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-size: 14px;
}
body.mypeptides .brand-newsletter-section .newsletter-form__message--error {
  color: #B5443A;
  margin-top: 0;
  margin-bottom: 24px;
  font-family: 'IBM Plex Sans', 'Inter', sans-serif;
  font-size: 14px;
}


/* =============================================================================
   MyPeptides — Safety Data Sheet pages
   =============================================================================
   Per-chemistry SDS library. MyPeptides is the clinical/professional brand,
   so SDS pages lean on monospace Plex Mono for the revision number (it
   reads as a document version stamp) over Plex Sans body. Navy headers
   anchor section titles. The brand's overall palette is being defined,
   so we hard-code the SDS section to a neutral navy that won't clash
   with any future palette token rewrite.
   ============================================================================= */
body.mypeptides .mypeptides-sds-page {
  max-width: 980px;
  margin: 0 auto;
  padding: 56px 24px 80px;
}
body.mypeptides .mypeptides-sds h1,
body.mypeptides .mypeptides-sds-detail h1 {
  font-family: "IBM Plex Sans", "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 28px;
  font-weight: 700;
  color: #0d2c4f;
  margin-bottom: 8px;
}
body.mypeptides .mypeptides-sds__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin: 24px 0;
}
body.mypeptides .mypeptides-sds__card {
  border: 1px solid var(--color-border);
  border-left: 3px solid #0d2c4f;
  background: #ffffff;
  padding: 20px;
}
body.mypeptides .mypeptides-sds__card-title {
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 16px;
  font-weight: 600;
  color: #0d2c4f;
  margin-bottom: 8px;
}
body.mypeptides .mypeptides-sds__card-meta dt {
  font-family: "IBM Plex Mono", "JetBrains Mono", "Menlo", monospace;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-muted);
  margin-top: 6px;
}
body.mypeptides .mypeptides-sds__card-meta dd {
  margin: 0 0 4px;
  font-family: "IBM Plex Sans", sans-serif;
  color: #0d2c4f;
}
body.mypeptides .mypeptides-sds__card-cta,
body.mypeptides .mypeptides-sds-detail__pdf-cta {
  display: inline-block;
  margin-top: 8px;
  padding: 8px 14px;
  background: #0d2c4f;
  color: #ffffff;
  text-decoration: none;
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 13px;
  font-weight: 600;
}
body.mypeptides .mypeptides-sds-detail__meta {
  font-family: "IBM Plex Mono", monospace;
  font-size: 12px;
  color: var(--color-muted);
  margin: 12px 0 24px;
  padding: 6px 0;
  border-top: 1px solid var(--color-subtle);
  border-bottom: 1px solid var(--color-subtle);
  display: inline-block;
}
body.mypeptides .mypeptides-sds-detail__body section {
  margin: 20px 0;
  padding: 16px 20px;
  background: #f7f9fc;
  border-left: 2px solid #0d2c4f;
}
body.mypeptides .mypeptides-sds-detail__body section h3 {
  font-family: "IBM Plex Sans", sans-serif;
  color: #0d2c4f;
  font-size: 15px;
  margin: 0 0 8px;
}
body.mypeptides .mypeptides-sds-detail__body p {
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 13px;
  line-height: 1.65;
  color: #2d3748;
}
body.mypeptides .mypeptides-sds__empty,
body.mypeptides .mypeptides-sds__note,
body.mypeptides .mypeptides-sds-detail__note {
  font-family: "IBM Plex Mono", monospace;
  font-size: 11px;
  color: var(--color-muted);
}
