/* =========================================================
   ProFound Peptides - Design Tokens
   Palette pulled from the client's real logo (navy/green/teal)
   Type: Inter (display + body), JetBrains Mono (COA/lot data)
   Signature element: the hexagon/molecule mark from the logo,
   used as a recurring structural device (dividers, verified
   badges, hover states) rather than a one-off header image.
   ========================================================= */

:root {
  /* Color */
  --navy-900: #082c42;
  --navy-800: #0b3d5c;
  --navy-700: #0f4d73;
  --teal-500: #2fb8c4;
  --teal-400: #5cd0da;
  --green-500: #7bc648;
  --green-600: #66ab37;
  --ink: #10242f;
  --ink-soft: #435c68;
  --paper: #ffffff;
  --paper-soft: #f5f9fa;
  --paper-tint: #eef7f6;
  --line: #dde7ea;
  --danger: #c2452f;
  --text-heading: var(--navy-900);
  --header-bg: rgba(255,255,255,0.92);
  --card-bg: #ffffff;

  /* Type */
  --font-display: "Poppins", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-body: "Poppins", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "JetBrains Mono", "SF Mono", Consolas, monospace;

  /* Layout */
  --maxw: 1240px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --shadow-sm: 0 2px 10px rgba(8, 44, 66, 0.06);
  --shadow-md: 0 12px 32px rgba(8, 44, 66, 0.10);
  --shadow-lg: 0 24px 60px rgba(8, 44, 66, 0.16);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; overflow-x: hidden; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  line-height: 1.55;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--text-heading);
  line-height: 1.12;
  margin: 0 0 0.5em;
  letter-spacing: -0.02em;
}

h1 { font-size: clamp(2.4rem, 4.2vw, 3.6rem); font-weight: 800; }
h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.3rem; font-weight: 700; }
p { margin: 0 0 1em; color: var(--ink-soft); }

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-500);
  font-weight: 600;
  margin-bottom: 14px;
}
.eyebrow::before {
  content: "";
  width: 14px; height: 14px;
  background: url('../assets/img/hex-mark.svg') center/contain no-repeat;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease;
}
.btn-primary {
  background: linear-gradient(135deg, var(--navy-800), var(--navy-700));
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn-outline {
  background: transparent;
  color: var(--text-heading);
  border-color: var(--line);
}
.btn-outline:hover { border-color: var(--navy-800); }
.btn-sm { padding: 10px 18px; font-size: 0.85rem; }
.btn-block { width: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--header-bg);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 92px;
}
.brand { display: flex; align-items: center; gap: 10px; }
.brand img { height: 52px; }
.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  font-weight: 600;
  font-size: 0.92rem;
}
@media (min-width: 981px) and (max-width: 1240px) {
  /* The desktop nav has no wrapping and no mobile fallback until 980px,
     so this middle zone (small laptops, landscape tablets) is where a
     7th nav item is most likely to get cramped or overflow. Tightening
     the gap and font size here keeps everything on one line without
     needing to shorten any labels further. */
  .nav-links { gap: 16px; font-size: 0.84rem; }
}
.nav-links a { color: var(--text-heading); position: relative; padding: 6px 0; }
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 0; height: 2px;
  background: var(--teal-500);
  transition: width 0.2s ease;
}
.nav-links a:hover::after { width: 100%; }
.nav-actions { display: flex; align-items: center; gap: 14px; }
.icon-btn {
  width: 40px; height: 40px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--paper-soft);
  border: 1px solid var(--line);
  color: var(--text-heading);
  transition: background 0.2s ease;
}
.icon-btn:hover { background: var(--paper-tint); }
.menu-toggle { display: none; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 70px 0 90px;
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(47,184,196,0.12), transparent 60%),
    linear-gradient(180deg, var(--paper-soft), var(--paper));
}
.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 56px;
  align-items: center;
}
.hero-copy p.lead {
  font-size: 1.1rem;
  max-width: 46ch;
}
.hero-stats {
  display: flex;
  gap: 28px;
  margin-top: 30px;
  padding-top: 26px;
  border-top: 1px solid var(--line);
}
.hero-stat .num {
  font-family: var(--font-mono);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-heading);
  display: block;
}
.hero-stat .label {
  font-size: 0.78rem;
  color: var(--ink-soft);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.hero-cta { display: flex; gap: 14px; margin-top: 34px; flex-wrap: wrap; }
.hero-visual {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.hero-visual img { width: 100%; height: 100%; object-fit: cover; }
.hero-visual::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(8,44,66,0.55));
  z-index: 1;
}
.hero-visual-badge {
  position: absolute;
  left: 20px; bottom: 20px;
  z-index: 2;
  background: rgba(255,255,255,0.95);
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--text-heading);
  box-shadow: var(--shadow-sm);
}
.hero-visual-badge .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--green-500);
}

/* ---------- Trust bar ---------- */
.trust-bar {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}
.trust-bar ul {
  list-style: none;
  margin: 0; padding: 20px 0;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}
.trust-bar li {
  display: flex; align-items: center; gap: 10px;
  font-size: 0.86rem; font-weight: 600; color: var(--text-heading);
}
.trust-bar li .hexbadge { color: var(--teal-500); }

/* ---------- Section shell ---------- */
.section { padding: 90px 0; }
.section-tint { background: var(--paper-soft); }
.section-head {
  max-width: 640px;
  margin: 0 auto 50px;
  text-align: center;
}
.section-head.left { margin: 0 0 46px; text-align: left; }

/* ---------- Category grid ---------- */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.cat-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  aspect-ratio: 4/3;
  display: block;
  background: linear-gradient(160deg, var(--paper-soft), var(--paper-tint));
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.cat-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.cat-card img { width: 100%; height: 100%; object-fit: cover; }
.cat-card .cat-overlay {
  position: absolute; inset: auto 0 0 0;
  padding: 16px 18px;
  background: linear-gradient(180deg, transparent, rgba(8,44,66,0.82) 70%);
  display: flex; align-items: center; justify-content: space-between;
}
.cat-card .cat-overlay span {
  color: #fff; font-weight: 700; font-size: 0.86rem;
}
.cat-card .cat-overlay .go {
  color: var(--teal-400); font-family: var(--font-mono); font-size: 0.78rem; font-weight: 700;
}
/* fallback style for categories without a provided banner image */
.cat-card.no-image {
  background: var(--paper);
  border: 1px solid var(--line);
  display: flex; flex-direction: column; justify-content: center;
  padding: 26px 22px;
}
.cat-card.no-image .hexicon {
  width: 46px; height: 46px;
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--paper-tint);
  color: var(--teal-500);
  margin-bottom: 18px;
  font-size: 1.3rem;
}
.cat-card.no-image h3 { font-size: 1.02rem; margin-bottom: 6px; }
.cat-card.no-image p { font-size: 0.86rem; margin-bottom: 0; }

/* ---------- Product grid / cards ---------- */
.product-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 22px;
}
.product-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.product-card .thumb {
  aspect-ratio: 1/1;
  background: linear-gradient(160deg, var(--paper-soft), var(--paper-tint));
  position: relative;
  overflow: hidden;
}
.product-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.product-card .purity-chip {
  position: absolute; top: 12px; right: 12px;
  background: var(--navy-900);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  padding: 4px 9px;
  border-radius: 999px;
  font-weight: 700;
}
.product-card .body { padding: 18px 18px 20px; }
.product-card .cat-tag {
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--teal-500);
  font-weight: 700;
  margin-bottom: 6px;
  display: block;
}
.product-card h3 { font-size: 1.02rem; margin-bottom: 4px; }
.product-card .sub { font-size: 0.82rem; color: var(--ink-soft); margin-bottom: 14px; }
.product-card .row {
  display: flex; align-items: center; justify-content: space-between;
}
.price-tag { font-weight: 700; color: var(--text-heading); font-family: var(--font-mono); font-size: 0.92rem; }

/* ---------- Filters ---------- */
.filter-bar {
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-bottom: 40px;
}
.filter-pill {
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  font-size: 0.84rem; font-weight: 600;
  color: var(--text-heading);
  background: var(--paper);
  cursor: pointer;
  transition: all 0.2s ease;
}
.filter-pill:hover { border-color: var(--teal-500); }
.filter-pill.active {
  background: var(--navy-900);
  border-color: var(--navy-900);
  color: #fff;
}

/* ---------- Two-column layout (contact, cart) ---------- */
.split-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 50px; }
.split-grid-wide { display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: start; }

/* ---------- Value cards (Why ProFound Peptides) ---------- */
.value-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.value-card {
  background: var(--card-bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 26px 22px;
  box-shadow: var(--shadow-sm);
}
.value-card .value-icon {
  width: 42px; height: 42px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--paper-tint);
  color: var(--teal-500);
  margin-bottom: 16px;
}
.value-card h3 { font-size: 1.02rem; margin-bottom: 8px; }
.value-card p { font-size: 0.86rem; margin-bottom: 0; }

/* ---------- Product page stock status text ---------- */
.stock-status-text { font-size: 0.86rem; font-weight: 700; margin: 0; }
.stock-status-text.in { color: var(--green-600); }
.stock-status-text.out { color: var(--ink-soft); text-decoration: line-through; }

/* ---------- FAQ accordion ---------- */
.faq-list { max-width: 820px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid var(--line);
  padding: 6px 0;
}
.faq-item summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 4px;
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--text-heading);
  font-size: 1.02rem;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary .faq-icon {
  flex: none;
  width: 26px; height: 26px;
  border-radius: 50%;
  border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--teal-500);
  transition: transform 0.2s ease;
}
.faq-item[open] summary .faq-icon { transform: rotate(45deg); }
.faq-item summary:focus-visible { outline: 2px solid var(--teal-500); outline-offset: 3px; }
.faq-item .faq-answer { padding: 0 4px 20px; color: var(--ink-soft); font-size: 0.94rem; }
.faq-item .faq-answer p:last-child { margin-bottom: 0; }

/* ---------- Steps ---------- */
.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}
.step-card { position: relative; padding-left: 4px; }
.step-num {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--teal-500);
  font-weight: 700;
  margin-bottom: 10px;
  display: block;
}

/* ---------- Compliance banner ---------- */
.compliance-band {
  background: var(--navy-900);
  color: #fff;
  padding: 46px 0;
}
.compliance-band h3 { color: #fff; }
.compliance-band p { color: rgba(255,255,255,0.75); margin-bottom: 0; }
.compliance-band .container { display: flex; gap: 24px; align-items: flex-start; }
.compliance-band .icon {
  flex: none;
  width: 46px; height: 46px;
  border-radius: 12px;
  background: rgba(255,255,255,0.1);
  display: flex; align-items: center; justify-content: center;
  color: var(--teal-400);
  font-size: 1.3rem;
}

/* ---------- COA hub ---------- */
.coa-search {
  display: flex;
  gap: 10px;
  margin-bottom: 36px;
}
.coa-search input {
  flex: 1;
  padding: 14px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  font-family: var(--font-body);
  font-size: 0.95rem;
}
.coa-table {
  width: 100%;
  min-width: 560px; /* keeps columns readable; .table-scroll handles the overflow on narrow screens */
  border-collapse: collapse;
  font-size: 0.9rem;
}
.table-scroll {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
.coa-table th {
  text-align: left;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
  padding: 12px 14px;
  border-bottom: 2px solid var(--line);
}
.coa-table td {
  padding: 14px;
  border-bottom: 1px solid var(--line);
}
.coa-table tr:hover td { background: var(--paper-soft); }
.lot-code { font-family: var(--font-mono); font-weight: 600; color: var(--text-heading); }
.verified-badge {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 0.75rem; font-weight: 700; color: var(--green-600);
}
.verified-badge svg { width: 14px; height: 14px; }

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-900);
  color: rgba(255,255,255,0.72);
  padding: 70px 0 30px;
  font-size: 0.9rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr repeat(4, 1fr);
  gap: 30px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.footer-grid h4 {
  color: #fff;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 18px;
}
.footer-grid a { display: block; margin-bottom: 10px; color: rgba(255,255,255,0.68); }
.footer-grid a:hover { color: var(--teal-400); }
.footer-brand img { height: 30px; margin-bottom: 14px; filter: brightness(0) invert(1); }
.footer-bottom {
  display: flex; justify-content: space-between; align-items: center;
  padding-top: 24px;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.8rem;
}
.footer-disclaimer {
  font-size: 0.76rem;
  color: rgba(255,255,255,0.5);
  max-width: 900px;
  margin: 0 auto 26px;
  text-align: center;
  line-height: 1.6;
}

/* ---------- Scroll-reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s cubic-bezier(.2,.7,.2,1), transform 0.7s cubic-bezier(.2,.7,.2,1);
}
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal-stagger .reveal:nth-child(1) { transition-delay: 0.02s; }
.reveal-stagger .reveal:nth-child(2) { transition-delay: 0.09s; }
.reveal-stagger .reveal:nth-child(3) { transition-delay: 0.16s; }
.reveal-stagger .reveal:nth-child(4) { transition-delay: 0.23s; }
.reveal-stagger .reveal:nth-child(5) { transition-delay: 0.30s; }
.reveal-stagger .reveal:nth-child(6) { transition-delay: 0.37s; }
.reveal-stagger .reveal:nth-child(7) { transition-delay: 0.44s; }
.reveal-stagger .reveal:nth-child(8) { transition-delay: 0.51s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  html { scroll-behavior: auto; }
}

/* ---------- Inner page hero (policy/product/etc) ---------- */
.page-hero {
  padding: 54px 0 40px;
  background: var(--paper-soft);
  border-bottom: 1px solid var(--line);
}
.breadcrumb {
  font-size: 0.82rem;
  color: var(--ink-soft);
  margin-bottom: 14px;
}
.breadcrumb a { color: var(--teal-500); font-weight: 600; }

/* ---------- Product detail ---------- */
.product-detail {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 60px;
  padding: 60px 0;
}
.product-gallery {
  position: sticky;
  top: 100px;
  align-self: start;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: linear-gradient(160deg, var(--paper-soft), var(--paper-tint));
  padding: 40px;
  text-align: center;
}
.dose-options { display: flex; gap: 10px; margin: 18px 0 26px; flex-wrap: wrap; }
.dose-pill {
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  font-family: var(--font-mono);
  font-size: 0.84rem;
  font-weight: 600;
  cursor: pointer;
}
.dose-pill.active { border-color: var(--navy-800); background: var(--navy-800); color: #fff; }
.spec-table { width: 100%; border-collapse: collapse; margin: 26px 0; }
.spec-table td { padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 0.9rem; }
.spec-table td:first-child { color: var(--ink-soft); width: 40%; }
.spec-table td:last-child { font-weight: 600; color: var(--text-heading); }
.tab-bar { display: flex; gap: 26px; border-bottom: 1px solid var(--line); margin: 50px 0 26px; }
.tab-btn {
  padding-bottom: 14px;
  font-weight: 700;
  font-size: 0.92rem;
  color: var(--ink-soft);
  border-bottom: 2px solid transparent;
  cursor: pointer;
}
.tab-btn.active { color: var(--text-heading); border-color: var(--teal-500); }
.tab-panel { display: none; }
.tab-panel.active { display: block; }

/* ---------- Forms ---------- */
.form-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-sm);
}
.field { margin-bottom: 18px; }
.field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 7px;
}
.field input, .field select, .field textarea {
  width: 100%;
  padding: 13px 15px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  font-family: var(--font-body);
  font-size: 0.95rem;
  background: var(--paper-soft);
}
.field input:focus, .field select:focus, .field textarea:focus,
button:focus-visible, a:focus-visible, .filter-pill:focus-visible {
  outline: 2px solid var(--teal-500);
  outline-offset: 2px;
}
.checkbox-row { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 20px; }
.checkbox-row input { width: auto; margin-top: 3px; }
.checkbox-row label { font-size: 0.82rem; color: var(--ink-soft); font-weight: 400; }
.form-msg { font-size: 0.85rem; margin-top: 12px; padding: 10px 14px; border-radius: var(--radius-sm); display: none; }
.form-msg.show { display: block; }
.form-msg.ok { background: #eaf7ea; color: var(--green-600); }
.form-msg.err { background: #fbeae7; color: var(--danger); }
.two-col-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

/* ---------- Policy / legal pages ---------- */
.policy-body { max-width: 780px; padding: 50px 0 90px; }
.policy-body h2 { font-size: 1.3rem; margin-top: 2em; }
.policy-body p, .policy-body li { color: var(--ink-soft); }
.policy-body ul { padding-left: 20px; }
.policy-updated {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--ink-soft);
  margin-bottom: 30px;
}

/* ---------- Research notes: one horizontal + one vertical ---------- */
.notes-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  align-items: stretch;
}
.note-card {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  display: block;
  background: linear-gradient(160deg, var(--paper-soft), var(--paper-tint));
}
.note-card img { width: 100%; height: 100%; object-fit: cover; display: block; }
.note-card.horizontal { aspect-ratio: 16/10; }
.note-card.vertical { aspect-ratio: 3/4; }
.note-card .note-overlay {
  position: absolute; inset: auto 0 0 0;
  padding: 22px;
  background: linear-gradient(180deg, transparent, rgba(8,44,66,0.85) 75%);
  color: #fff;
}
.note-card .note-overlay .cat-tag { color: var(--teal-400); }
.note-card .note-overlay h3 { color: #fff; margin-bottom: 4px; }
.note-card .note-overlay p { color: rgba(255,255,255,0.78); font-size: 0.85rem; margin-bottom: 0; }
@media (max-width: 780px) {
  .notes-grid { grid-template-columns: 1fr; }
  .note-card.vertical { aspect-ratio: 16/10; }
}

/* ---------- Cart icon + badge ---------- */
.cart-btn { position: relative; }
.cart-count {
  position: absolute; top: -4px; right: -4px;
  background: var(--teal-500);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 700;
  min-width: 17px; height: 17px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px;
}

/* ---------- Cart page ---------- */
.cart-item {
  display: grid;
  grid-template-columns: 74px 1fr auto auto;
  gap: 16px;
  align-items: center;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
}
.cart-item img { width: 74px; height: 74px; object-fit: cover; border-radius: var(--radius-sm); }
.cart-item .qty-input {
  width: 56px; padding: 8px; border-radius: var(--radius-sm); border: 1px solid var(--line);
  text-align: center; font-family: var(--font-mono);
}
.cart-remove { color: var(--danger); font-size: 0.8rem; font-weight: 600; cursor: pointer; }
.cart-summary {
  background: var(--paper-soft);
  border-radius: var(--radius-md);
  padding: 26px;
}
.cart-summary .row { display: flex; justify-content: space-between; margin-bottom: 12px; font-size: 0.92rem; }
.cart-empty { text-align: center; padding: 60px 0; color: var(--ink-soft); }

/* ---------- Age gate ---------- */
.age-gate {
  position: fixed; inset: 0; z-index: 1000;
  background: rgba(8,44,66,0.96);
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.age-gate[hidden] { display: none; }
.age-gate-card {
  background: var(--card-bg); border-radius: var(--radius-lg);
  max-width: 380px; padding: 30px 28px;
  text-align: center;
  box-shadow: var(--shadow-lg);
  position: relative;
}
.age-gate-card h2 { font-size: 1.15rem; }
.age-gate-card p { font-size: 0.82rem; margin-bottom: 20px; }
.age-gate-actions { display: flex; flex-direction: column; gap: 8px; }
.age-gate-actions .btn { padding: 11px 20px; font-size: 0.88rem; }

/* ---------- Mobile nav (fixes hamburger menu having no visible effect) ---------- */
.nav-links.mobile-open {
  display: flex !important;
  position: absolute;
  top: 92px; left: 0; right: 0;
  background: var(--card-bg);
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  padding: 10px 24px 20px;
  border-bottom: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  z-index: 120;
}
.nav-links.mobile-open a { padding: 12px 0; width: 100%; border-bottom: 1px solid var(--paper-soft); }

/* ---------- Sales combos ---------- */
.combo-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.combo-card {
  border: 1px solid var(--line); border-radius: var(--radius-md);
  overflow: hidden; background: var(--paper);
}
.combo-card .combo-thumb { aspect-ratio: 16/10; overflow: hidden; background: linear-gradient(160deg, var(--paper-soft), var(--paper-tint)); }
.combo-card .combo-thumb img { width: 100%; height: 100%; object-fit: cover; }
.combo-card .combo-body { padding: 22px; }
.combo-card h3 { margin-bottom: 6px; }
.combo-card .combo-items { font-size: 0.84rem; color: var(--ink-soft); margin-bottom: 14px; }
.combo-price-row { display: flex; align-items: baseline; gap: 10px; margin-bottom: 4px; }
.combo-price-row .was { text-decoration: line-through; color: var(--ink-soft); font-size: 0.9rem; }
.combo-price-row .now { font-family: var(--font-mono); font-weight: 700; font-size: 1.25rem; color: var(--text-heading); }
.combo-save { font-size: 0.78rem; color: var(--green-600); font-weight: 700; margin-bottom: 16px; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .combo-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .value-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: repeat(2, 1fr); }
  .product-detail { grid-template-columns: 1fr; }
  .product-gallery { position: static; }
  .nav-links { display: none; }
  .menu-toggle { display: flex; }
  .lab-strip { grid-template-columns: repeat(2, 1fr) !important; }
}
@media (max-width: 780px) {
  .split-grid, .split-grid-wide { grid-template-columns: 1fr; gap: 30px; }
  .two-col-fields { grid-template-columns: 1fr; gap: 0; }
}
@media (max-width: 700px) {
  .container { padding: 0 18px; }
  .site-header .container { height: 76px; }
  .brand img { height: 40px; }
  .hero { padding: 44px 0 60px; }
  .section { padding: 56px 0; }
  .hero-stats { gap: 18px; flex-wrap: wrap; }
  .nav-actions .btn-sm { display: none; }
  .product-detail { padding: 30px 0; gap: 30px; }
  .trust-bar ul { flex-direction: column; align-items: flex-start; gap: 12px; }
  .footer-grid { grid-template-columns: 1fr; gap: 26px; }
  .steps { gap: 26px; }
  .value-grid { grid-template-columns: 1fr; }
  .form-card { padding: 26px; }
  .age-gate-card { padding: 28px 22px; }
}
@media (max-width: 600px) {
  .cat-grid { grid-template-columns: 1fr; }
  .product-grid { grid-template-columns: 1fr 1fr; gap: 12px; }
  .product-card .body { padding: 12px 12px 14px; }
  .product-card .purity-chip { font-size: 0.58rem; padding: 3px 7px; top: 8px; right: 8px; }
  .product-card h3 { font-size: 0.9rem; }
  .product-card .sub { font-size: 0.76rem; }
  .product-card .price-tag { font-size: 0.86rem; }
  .product-card .btn-sm { font-size: 0.76rem; padding: 8px 10px; }
  .trust-bar ul { justify-content: flex-start; }
  .compliance-band .container { flex-direction: column; }
  .cart-item { grid-template-columns: 56px 1fr; row-gap: 8px; }
  .cart-item .qty-input, .cart-item .cart-remove { grid-column: 2; }
}

/* ---------- Product page trust row ---------- */
.trust-row {
  display: flex; gap: 20px; justify-content: center;
  margin-top: 16px; flex-wrap: wrap;
}
.trust-item {
  display: flex; align-items: center; gap: 8px;
  font-size: 0.8rem; font-weight: 600; color: var(--text-heading);
}
.trust-icon { color: var(--teal-500); font-size: 0.9rem; }

/* ---------- Announcement bar ---------- */
.announce-bar {
  background: var(--navy-900);
  color: #fff;
  text-align: center;
  padding: 9px 16px;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}
.announce-msg { transition: opacity 0.4s ease; }
.announce-msg.fade { opacity: 0; }

/* =========================================================
   Dark mode
   Toggled via [data-theme="dark"] on <html>, persisted in
   localStorage. Overrides the same tokens every component
   already reads from, so no component-level dark rules
   are needed beyond the few noted below.
   ========================================================= */
html[data-theme="dark"] {
  --paper: #0d1f2b;
  --paper-soft: #122a38;
  --paper-tint: #103042;
  --line: #1f3d4d;
  --ink: #eaf3f5;
  --ink-soft: #a9c1c9;
  --text-heading: #f2f8f9;
  --header-bg: rgba(13, 31, 43, 0.86);
  --card-bg: #122a38;
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 12px 32px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, 0.55);
}
html[data-theme="dark"] .hero-visual-badge { background: var(--card-bg); }
html[data-theme="dark"] .form-msg.ok { background: rgba(123, 198, 72, 0.14); }
html[data-theme="dark"] .form-msg.err { background: rgba(194, 69, 47, 0.14); }
html[data-theme="dark"] .cat-card.no-image { border: 1px solid var(--line); }
html[data-theme="dark"] input,
html[data-theme="dark"] select,
html[data-theme="dark"] textarea {
  background: var(--paper-soft);
  color: var(--ink);
  border-color: var(--line);
}

/* ---------- Theme toggle ---------- */
.theme-toggle svg { display: none; }
.theme-toggle .icon-sun { display: block; }
html[data-theme="dark"] .theme-toggle .icon-sun { display: none; }
html[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

/* ---------- Search ---------- */
.search-toggle-btn { position: relative; }
.search-panel {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: var(--card-bg);
  box-shadow: var(--shadow-md);
  padding: 18px 0;
  z-index: 150;
  transform: translateY(-100%);
  transition: transform 0.25s ease;
}
.search-panel.open { transform: translateY(0); }
.search-panel .container { display: flex; align-items: center; gap: 12px; }
.search-panel input {
  flex: 1;
  border: 1px solid var(--line);
  background: var(--paper-soft);
  color: var(--ink);
  padding: 13px 16px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 1rem;
}
.search-panel input:focus { outline: 2px solid var(--teal-500); outline-offset: 1px; }
.search-close-btn {
  border: none; background: transparent; cursor: pointer;
  width: 40px; height: 40px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--ink-soft);
}
.search-close-btn:hover { background: var(--paper-soft); }
.search-results {
  max-width: var(--maxw);
  margin: 14px auto 0;
  padding: 0 24px;
  max-height: 60vh;
  overflow-y: auto;
}
.search-result-item {
  display: flex; align-items: center; gap: 14px;
  padding: 10px 8px;
  border-radius: var(--radius-sm);
}
.search-result-item:hover { background: var(--paper-soft); }
.search-result-item img { width: 44px; height: 44px; object-fit: cover; border-radius: var(--radius-sm); background: var(--paper-soft); }
.search-result-item .name { font-weight: 600; color: var(--text-heading); font-size: 0.92rem; }
.search-result-item .cat { font-size: 0.76rem; color: var(--ink-soft); }
.search-result-item .price { margin-left: auto; font-family: var(--font-mono); font-weight: 700; color: var(--text-heading); font-size: 0.86rem; }
.search-empty { padding: 20px 8px; color: var(--ink-soft); font-size: 0.9rem; }
.search-backdrop {
  position: fixed; inset: 0; background: rgba(8,20,28,0.4);
  z-index: 140; opacity: 0; pointer-events: none; transition: opacity 0.2s ease;
}
.search-backdrop.open { opacity: 1; pointer-events: auto; }

/* ---------- Shop: category banner + sort ---------- */
.cat-banner {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 30px;
  min-height: 180px;
  display: flex; align-items: flex-end;
}
.cat-banner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.cat-banner::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(0deg, rgba(8,44,66,0.88), rgba(8,44,66,0.15));
}
.cat-banner-copy { position: relative; padding: 26px 30px; color: #fff; }
.cat-banner-copy .eyebrow { color: var(--teal-400); }
.cat-banner-copy h2 { color: #fff; margin-bottom: 6px; }
.cat-banner-copy p { color: rgba(255,255,255,0.82); margin-bottom: 0; max-width: 60ch; }

.shop-toolbar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; margin-bottom: 6px;
}
.sort-select {
  padding: 10px 34px 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--card-bg) url('data:image/svg+xml;utf8,<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="%23435c68" stroke-width="2"><path d="M6 9l6 6 6-6"/></svg>') no-repeat right 12px center;
  color: var(--ink);
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  appearance: none;
  cursor: pointer;
}

/* ---------- Stock badge ---------- */
.stock-badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 0.72rem; font-weight: 700;
  padding: 4px 9px; border-radius: 999px;
}
.stock-badge::before { content: ""; width: 6px; height: 6px; border-radius: 50%; }
.stock-badge.in-stock { color: var(--green-600); background: rgba(123,198,72,0.14); }
.stock-badge.in-stock::before { background: var(--green-600); }
.stock-badge.low-stock { color: #b5750f; background: rgba(181,117,15,0.14); }
.stock-badge.low-stock::before { background: #b5750f; }

/* ---------- Recently viewed ---------- */
.recently-viewed-strip {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
}
.rv-card { display: block; }
.rv-card .thumb {
  aspect-ratio: 1/1; border-radius: var(--radius-md);
  overflow: hidden; background: var(--paper-soft);
  border: 1px solid var(--line); margin-bottom: 8px;
}
.rv-card .thumb img { width: 100%; height: 100%; object-fit: cover; }
.rv-card .name { font-size: 0.82rem; font-weight: 600; color: var(--text-heading); }
.rv-card .price { font-size: 0.78rem; font-family: var(--font-mono); color: var(--ink-soft); }

@media (max-width: 780px) {
  .cat-banner-copy { padding: 20px; }
  .shop-toolbar { flex-direction: column; align-items: stretch; }
}
