/* peptidesfordummies — single stylesheet, no external deps */

:root {
  --bg: #ffffff;
  --bg-soft: #fafaf9;
  --text: #1a1a1a;
  --muted: #6b7280;
  --accent: #2563eb;
  --accent-soft: #eff6ff;
  --border: #e5e7eb;
  --human: #059669;
  --human-bg: #d1fae5;
  --animal: #d97706;
  --animal-bg: #fef3c7;
  --both: #2563eb;
  --both-bg: #dbeafe;
  --warn-bg: #fef3c7;
  --warn-border: #f59e0b;
  --radius: 10px;
  --max-width: 720px;
}

/* Per-peptide color themes. Each blog page sets a body class like
   .peptide-bpc-157, which rebinds --accent and --accent-soft so every
   existing component (links, study cards, card hover border) picks up
   the peptide's color with zero per-page overrides. */
.peptide-bpc-157      { --accent: #0d9488; --accent-soft: #ccfbf1; }
.peptide-epitalon     { --accent: #7c3aed; --accent-soft: #ede9fe; }
.peptide-ghk-cu       { --accent: #b45309; --accent-soft: #fef3c7; }
.peptide-kisspeptin-10{ --accent: #db2777; --accent-soft: #fce7f3; }
.peptide-retatrutide  { --accent: #059669; --accent-soft: #d1fae5; }
.peptide-selank       { --accent: #4f46e5; --accent-soft: #e0e7ff; }
.peptide-semax        { --accent: #0284c7; --accent-soft: #e0f2fe; }
.peptide-tb-500       { --accent: #dc2626; --accent-soft: #fee2e2; }
.peptide-ipamorelin   { --accent: #65a30d; --accent-soft: #ecfccb; }
.peptide-cjc-1295     { --accent: #475569; --accent-soft: #f1f5f9; }

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 18px;
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
}

a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
a:hover { text-decoration: none; }
a:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 2px; }

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

/* Header / nav */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
}
.site-header .brand {
  font-weight: 700;
  font-size: 20px;
  color: var(--text);
  text-decoration: none;
}
.site-nav a {
  color: var(--text);
  text-decoration: none;
  margin-left: 20px;
  font-size: 16px;
}
.site-nav a:hover { color: var(--accent); }

/* Language switcher */
.lang-switcher {
  display: inline-flex;
  gap: 2px;
  margin-left: 16px;
  font-size: 12px;
}
.lang-switcher a {
  padding: 4px 8px;
  color: var(--muted);
  text-decoration: none;
  border-radius: 4px;
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.3px;
}
.lang-switcher a:hover { background: var(--accent-soft); color: var(--accent); }
.lang-switcher a.active { background: var(--accent); color: #ffffff; }

/* Main */
main { padding: 40px 0 60px; }

h1 { font-size: 40px; line-height: 1.2; margin: 0 0 8px; }
h2 { font-size: 28px; line-height: 1.3; margin: 40px 0 12px; color: var(--accent); }
h3 { font-size: 22px; line-height: 1.35; margin: 28px 0 8px; }
p { margin: 0 0 16px; }
ul, ol { padding-left: 22px; margin: 0 0 16px; }

.subtitle { color: var(--muted); font-size: 20px; margin: 0 0 16px; }
.meta { color: var(--muted); font-size: 14px; }

/* Study-type badge */
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
}
.badge-human  { background: var(--human-bg);  color: var(--human);  }
.badge-animal { background: var(--animal-bg); color: var(--animal); }
.badge-both   { background: var(--both-bg);   color: var(--both);   }

/* Quick facts box */
.facts {
  background: var(--accent-soft);
  border: 1px solid var(--accent);
  border-left-width: 4px;
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 24px 0 32px;
}
.facts dl {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 6px 20px;
  margin: 0;
}
.facts dt { color: var(--muted); font-size: 14px; font-weight: 600; }
.facts dd { margin: 0; font-size: 15px; color: var(--text); }

/* Study card */
.study {
  border-left: 4px solid var(--accent);
  background: var(--accent-soft);
  padding: 16px 20px;
  margin: 16px 0;
  border-radius: 0 var(--radius) var(--radius) 0;
}
.study h3 { margin-top: 0; font-size: 19px; color: var(--text); }
.study .cite { color: var(--muted); font-size: 14px; margin-bottom: 8px; }
.study .badge { margin-left: 6px; }

/* Pros / Cons / Dosing boxes */
.pros, .cons, .dosing {
  border-radius: var(--radius);
  padding: 18px 22px;
  margin: 20px 0;
  border: 1px solid;
}
.pros {
  background: #ecfdf5;
  border-color: #10b981;
}
.pros h3 { color: #047857; }
.cons {
  background: #fef2f2;
  border-color: #f87171;
}
.cons h3 { color: #b91c1c; }
.dosing {
  background: var(--accent-soft);
  border-color: var(--accent);
}
.dosing h3 { color: var(--accent); }
.pros h3, .cons h3, .dosing h3 {
  margin: 0 0 10px;
  font-size: 18px;
}
.pros ul, .cons ul { margin: 0; padding-left: 22px; }
.pros li, .cons li { margin-bottom: 6px; font-size: 16px; }
.dosing p { margin: 0 0 10px; font-size: 16px; }
.dosing p:last-child { margin-bottom: 0; }
.dosing ul { margin: 0; padding-left: 22px; }
.dosing li { margin-bottom: 6px; font-size: 16px; }

/* Affiliate / related products */
.affiliate {
  margin: 40px 0 24px;
  padding: 24px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.affiliate h2 {
  margin: 0 0 6px;
  font-size: 22px;
  color: var(--accent);
}
.affiliate .aff-intro {
  margin: 0 0 18px;
  font-size: 14px;
  color: var(--muted);
}
.aff-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
}
.aff-card {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}
.aff-card:hover {
  border-color: var(--accent);
  transform: translateY(-2px);
}
.aff-card h3 {
  margin: 0 0 6px;
  font-size: 16px;
  color: var(--text);
}
.aff-card p {
  margin: 0 0 12px;
  font-size: 14px;
  color: var(--muted);
  flex-grow: 1;
}
.aff-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.aff-links a {
  display: inline-block;
  padding: 6px 12px;
  background: var(--accent);
  color: #ffffff;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  border-radius: 6px;
  transition: opacity 0.2s ease;
}
.aff-links a:hover { opacity: 0.85; }
.aff-links a.aff-amazon { background: #ff9900; color: #111; }
.aff-links a.aff-iherb  { background: #5a8a00; }
.aff-disclosure {
  margin: 18px 0 0;
  padding: 12px 14px;
  background: var(--warn-bg);
  border-left: 3px solid var(--warn-border);
  font-size: 13px;
  color: #78350f;
  border-radius: 6px;
}
@media (max-width: 640px) {
  .aff-grid { grid-template-columns: 1fr; }
}

/* Shop page */
.shop-hero {
  padding: 40px 0 10px;
  text-align: center;
}
.shop-hero h1 {
  font-size: 44px;
  margin-bottom: 12px;
  background: linear-gradient(135deg, #0d9488 0%, #2563eb 50%, #7c3aed 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.shop-hero p { color: var(--muted); font-size: 18px; max-width: 620px; margin: 0 auto 16px; }

.shop-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin: 20px 0 40px;
  padding: 16px;
  background: var(--bg-soft);
  border: 1px solid var(--border);
  border-radius: var(--radius);
}
.shop-nav a {
  padding: 6px 14px;
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 999px;
  text-decoration: none;
  transition: all 0.15s ease;
}
.shop-nav a:hover {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.shop-cat {
  margin: 48px 0 16px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--border);
}
.shop-cat h2 {
  margin: 0 0 6px;
  font-size: 26px;
  color: var(--text);
}
.shop-cat p {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.shop-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 18px;
  margin: 20px 0 10px;
}
.product {
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}
.product:hover {
  border-color: var(--accent);
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(0,0,0,0.08);
}
.product-img {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 160px;
  background: var(--p-bg, linear-gradient(135deg, #eff6ff, #ede9fe));
  border-bottom: 1px solid var(--border);
}
.product-img svg {
  width: 72%;
  height: 72%;
  color: var(--p-color, #1f2937);
}
.product-body { padding: 16px 18px 18px; display: flex; flex-direction: column; flex-grow: 1; }
.product-body h3 {
  margin: 0 0 6px;
  font-size: 17px;
  color: var(--text);
  line-height: 1.3;
}
.product-body p {
  margin: 0 0 14px;
  font-size: 14px;
  color: var(--muted);
  flex-grow: 1;
}
.product .aff-links { margin-top: auto; }

@media (max-width: 640px) {
  .shop-grid { grid-template-columns: 1fr; }
  .shop-hero h1 { font-size: 32px; }
  .product-img { height: 140px; }
}

/* Disclaimer box */
.disclaimer {
  background: var(--warn-bg);
  border: 1px solid var(--warn-border);
  border-radius: var(--radius);
  padding: 14px 18px;
  margin: 36px 0 0;
  font-size: 14px;
  color: #78350f;
}
.disclaimer strong { display: block; margin-bottom: 4px; }

/* Sources list */
.sources ol { padding-left: 22px; font-size: 15px; }
.sources li { margin-bottom: 8px; word-wrap: break-word; }

/* Homepage hero */
.hero {
  padding: 40px 0 20px;
  text-align: center;
  position: relative;
}
.hero-art {
  display: block;
  width: 100%;
  max-width: 760px;
  height: auto;
  margin: 0 auto 28px;
  border-radius: 16px;
  box-shadow: 0 20px 60px rgba(37, 99, 235, 0.15);
}
.hero h1 {
  font-size: 52px;
  margin-bottom: 14px;
  background: linear-gradient(135deg, #2563eb 0%, #7c3aed 50%, #db2777 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero p { color: var(--muted); font-size: 20px; max-width: 580px; margin: 0 auto 16px; }

/* Peptide card grid */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 40px 0;
}
.card {
  display: block;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0;
  text-decoration: none;
  color: inherit;
  background: var(--bg);
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
  position: relative;
}
.card:hover {
  border-color: var(--card-color, var(--accent));
  transform: translateY(-3px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
}
.card-icon {
  display: block;
  width: 100%;
  height: 110px;
  background: var(--card-bg, var(--accent-soft));
  border-bottom: 1px solid var(--border);
}
.card-icon svg { width: 100%; height: 100%; color: var(--card-color, var(--accent)); }
.card-body { padding: 18px 20px 20px; }
.card h3 { margin: 0 0 6px; font-size: 20px; color: var(--text); }
.card p  { margin: 0 0 10px; color: var(--muted); font-size: 15px; }

/* Per-card colors: apply via class on the .card element. Each sets
   --card-color + --card-bg so the icon and hover border match the
   blog page's theme. */
.card.bpc-157       { --card-color: #0d9488; --card-bg: #ccfbf1; }
.card.epitalon      { --card-color: #7c3aed; --card-bg: #ede9fe; }
.card.ghk-cu        { --card-color: #b45309; --card-bg: #fef3c7; }
.card.kisspeptin-10 { --card-color: #db2777; --card-bg: #fce7f3; }
.card.retatrutide   { --card-color: #059669; --card-bg: #d1fae5; }
.card.selank        { --card-color: #4f46e5; --card-bg: #e0e7ff; }
.card.semax         { --card-color: #0284c7; --card-bg: #e0f2fe; }
.card.tb-500        { --card-color: #dc2626; --card-bg: #fee2e2; }
.card.ipamorelin    { --card-color: #65a30d; --card-bg: #ecfccb; }
.card.cjc-1295      { --card-color: #475569; --card-bg: #f1f5f9; }

/* Blog page header color band */
.article-header {
  margin: -40px -20px 32px;
  padding: 48px 20px 32px;
  background: var(--accent-soft);
  border-bottom: 4px solid var(--accent);
}
.article-header .container { padding: 0; }
.article-header h1 { color: var(--accent); margin-bottom: 10px; }
.article-header .subtitle { color: var(--text); }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 24px 0 40px;
  margin-top: 60px;
  color: var(--muted);
  font-size: 14px;
  text-align: center;
}
.site-footer a { color: var(--muted); }

/* Consent modal (first-visit disclaimer + cookies) */
.consent-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 9998;
  backdrop-filter: blur(2px);
}
.consent-modal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  overflow-y: auto;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  padding: 28px 28px 20px;
  z-index: 9999;
  font-size: 15px;
  line-height: 1.55;
}
.consent-disclaimer h2 {
  margin: 0 0 12px;
  font-size: 22px;
  color: var(--text);
  line-height: 1.25;
}
.consent-disclaimer p {
  margin: 0 0 20px;
  font-size: 16px;
}
.consent-cookies {
  border-top: 1px solid #e5e7eb;
  padding-top: 16px;
  margin-bottom: 20px;
}
.consent-cookies p {
  margin: 0;
  font-size: 14px;
  color: var(--muted);
}
.consent-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: flex-end;
}
.consent-btn {
  padding: 10px 18px;
  border: none;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s;
}
.consent-btn:hover { opacity: 0.85; }
.consent-btn-accept { background: var(--accent); color: #fff; }
.consent-btn-decline { background: transparent; color: var(--text); border: 1px solid #d1d5db; }
@media (max-width: 640px) {
  .consent-modal { padding: 22px 20px 16px; }
  .consent-disclaimer h2 { font-size: 19px; }
  .consent-actions { flex-direction: column-reverse; }
  .consent-btn { width: 100%; }
}

/* Mobile */
@media (max-width: 640px) {
  body { font-size: 17px; }
  h1 { font-size: 32px; }
  h2 { font-size: 24px; }
  .hero h1 { font-size: 36px; }
  .hero-art { border-radius: 12px; }
  .grid { grid-template-columns: 1fr; }
  .site-header .container { flex-direction: column; gap: 10px; }
  .site-nav a { margin: 0 10px; }
  .article-header { margin: -40px -20px 24px; padding: 36px 20px 24px; }
}


/* News section */
.news-section { margin: 40px 0; }
.news-section h2 {
  font-size: 26px;
  margin: 0 0 18px;
}
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
}
.news-item {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.news-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.08);
}
.news-thumb-wrap {
  position: relative;
  aspect-ratio: 16 / 10;
  background: #f1f5f9;
  overflow: hidden;
}
.news-thumb-wrap.news-thumb-pubmed { background: linear-gradient(135deg,#ede9fe,#e0e7ff); }
.news-thumb-wrap.news-thumb-news   { background: linear-gradient(135deg,#dbeafe,#e0f2fe); }
.news-thumb {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.news-badge {
  position: absolute;
  top: 8px;
  left: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 3px 8px;
  border-radius: 4px;
  color: #fff;
}
.news-badge-news   { background: #2563eb; }
.news-badge-pubmed { background: #7c3aed; }
.news-body {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.news-title {
  font-size: 15px;
  line-height: 1.35;
  margin: 0 0 8px;
  font-weight: 600;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.news-meta {
  font-size: 12px;
  color: var(--muted);
  margin: auto 0 0;
}
.news-title-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-top: 1px solid #e5e7eb;
}
.news-title-list li { border-bottom: 1px solid #e5e7eb; }
.news-title-link {
  display: block;
  padding: 12px 4px;
  color: inherit;
  text-decoration: none;
  font-size: 16px;
  font-weight: 500;
  line-height: 1.4;
}
.news-title-link:hover { color: var(--accent); }
.news-see-all {
  text-align: right;
  margin: 14px 0 0;
}
.news-see-all a {
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
}
.news-fallback {
  color: var(--muted);
  font-style: italic;
  padding: 20px;
  text-align: center;
  border: 1px dashed #d1d5db;
  border-radius: 8px;
}
@media (max-width: 640px) {
  .news-grid { grid-template-columns: 1fr; }
}
