/* Peptide Tutorials — homepage mock
   Publisher / health-education hub
   Deep indigo + coral · cream surfaces
   Inspired by Healthline / Verywell / Bankrate / NerdWallet patterns (not a clone) */

:root {
  --indigo-950: #1a1540;
  --indigo-900: #241d5a;
  --indigo-800: #2f2770;
  --indigo-700: #3d348f;
  --indigo-100: #e8e6f5;
  --indigo-50: #f3f2fa;

  --coral-600: #e85d4c;
  --coral-500: #f06a58;
  --coral-700: #c94a3b;
  --coral-50: #fef0ee;

  --cream: #faf8f4;
  --cream-2: #f3efe8;
  --white: #ffffff;
  --ink: #1c1917;
  --ink-2: #3f3a36;
  --muted: #6b6560;
  --faint: #9a948c;
  --border: #e5e0d8;
  --border-soft: #eeeae3;

  --warn-bg: #fff8e8;
  --warn-border: #f0d9a0;
  --warn-ink: #6b5420;

  --font: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-display: "DM Sans", system-ui, sans-serif;

  --radius: 14px;
  --radius-sm: 10px;
  --radius-pill: 999px;
  --shadow: 0 1px 2px rgba(28, 25, 23, 0.04), 0 8px 24px rgba(28, 25, 23, 0.06);
  --shadow-card: 0 2px 8px rgba(28, 25, 23, 0.05), 0 12px 28px rgba(36, 29, 90, 0.06);
  --max: 1120px;
  --focus: 0 0 0 3px rgba(240, 106, 88, 0.45);
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink-2);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a {
  color: var(--indigo-800);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover { color: var(--coral-600); }

a:focus-visible,
button:focus-visible,
input:focus-visible {
  outline: none;
  box-shadow: var(--focus);
  border-radius: 4px;
}

.skip-link {
  position: absolute;
  left: -9999px;
  z-index: 100;
  padding: 0.65rem 1rem;
  background: var(--indigo-900);
  color: var(--white);
  font-weight: 600;
  text-decoration: none;
  border-radius: 0 0 var(--radius-sm) 0;
}

.skip-link:focus { left: 0; top: 0; }

.wrap {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ——— 1. Disclaimer ——— */
.disclaimer {
  background: var(--warn-bg);
  border-bottom: 1px solid var(--warn-border);
  color: var(--warn-ink);
  font-size: 0.8125rem;
  line-height: 1.45;
  padding: 0.5rem 0;
}

.disclaimer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 0.85rem;
  align-items: baseline;
  justify-content: center;
  text-align: center;
}

.disclaimer strong { font-weight: 700; color: var(--ink); }

.disclaimer a {
  color: var(--warn-ink);
  font-weight: 600;
}

/* ——— 2. Nav (dark top bar, Healthline-style) ——— */
.site-header {
  background: var(--indigo-950);
  color: var(--white);
  position: sticky;
  top: 0;
  z-index: 50;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.25rem;
  min-height: 3.75rem;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  text-decoration: none;
  color: var(--white);
  flex-shrink: 0;
}

.logo:hover { color: var(--white); opacity: 0.92; }

.logo-text {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.logo-text small {
  display: block;
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.65;
  margin-top: 1px;
}

.nav-toggle {
  display: none;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: var(--white);
  font-family: inherit;
  font-size: 0.8125rem;
  font-weight: 600;
  padding: 0.45rem 0.75rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
}

.primary-nav ul {
  display: flex;
  flex-wrap: wrap;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 0.15rem;
  align-items: center;
}

.primary-nav a {
  display: block;
  padding: 0.45rem 0.7rem;
  color: rgba(255, 255, 255, 0.88);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
  border-radius: 8px;
}

.primary-nav a:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
}

/* ——— 3. Trust strip ——— */
.trust-strip {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 0.7rem 0;
}

.trust-strip .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 1.5rem;
  font-size: 0.8125rem;
  color: var(--muted);
}

.trust-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--faint);
  background: var(--cream-2);
  padding: 0.2rem 0.45rem;
  border-radius: 4px;
}

.trust-item {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-weight: 500;
  color: var(--ink-2);
}

.trust-item svg {
  width: 1rem;
  height: 1rem;
  color: var(--indigo-700);
  flex-shrink: 0;
}

.trust-sep {
  width: 1px;
  height: 1rem;
  background: var(--border);
}

/* ——— 4. Hero ——— */
.hero {
  background:
    radial-gradient(ellipse 70% 80% at 100% 0%, rgba(240, 106, 88, 0.12), transparent 55%),
    radial-gradient(ellipse 50% 60% at 0% 100%, rgba(47, 39, 112, 0.1), transparent 50%),
    linear-gradient(165deg, var(--indigo-50) 0%, var(--cream) 55%, var(--white) 100%);
  padding: 2.75rem 0 0;
  border-bottom: 1px solid var(--border);
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
  padding-bottom: 2rem;
  max-width: 42rem;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--indigo-700);
  margin: 0 0 0.85rem;
}

.hero h1 {
  font-size: clamp(2.1rem, 4.5vw, 2.85rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  color: var(--ink);
  margin: 0 0 0.75rem;
}

.hero-audience {
  font-size: clamp(1.15rem, 2vw, 1.3rem);
  font-weight: 600;
  color: var(--indigo-800);
  margin: 0 0 0.85rem;
  line-height: 1.35;
}

.hero-deck {
  font-size: 1.1rem;
  color: var(--muted);
  margin: 0 0 1.15rem;
  line-height: 1.55;
}

.hero-tldr {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.85rem 1rem;
  margin: 0 0 1.35rem;
  font-size: 0.9375rem;
  color: var(--ink-2);
  line-height: 1.5;
}

.hero-tldr strong {
  display: block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--coral-600);
  margin-bottom: 0.3rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  align-items: center;
  margin-bottom: 1.25rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  font-family: inherit;
  font-size: 0.975rem;
  font-weight: 650;
  text-decoration: none;
  border-radius: var(--radius-pill);
  padding: 0.75rem 1.4rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s, box-shadow 0.15s;
}

.btn-primary {
  background: var(--coral-500);
  color: var(--white);
  border-color: var(--coral-500);
  box-shadow: 0 4px 14px rgba(232, 93, 76, 0.3);
}

.btn-primary:hover {
  background: var(--coral-700);
  border-color: var(--coral-700);
  color: var(--white);
}

.btn-secondary {
  background: transparent;
  color: var(--indigo-800);
  border-color: var(--indigo-800);
}

.btn-secondary:hover {
  background: var(--indigo-50);
  color: var(--indigo-950);
}

.search-bar {
  display: flex;
  max-width: 28rem;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.search-bar:focus-within {
  box-shadow: var(--focus);
}

.search-bar input {
  flex: 1;
  border: none;
  background: transparent;
  padding: 0.7rem 1.1rem;
  font-family: inherit;
  font-size: 0.95rem;
  color: var(--ink);
  min-width: 0;
}

.search-bar input::placeholder { color: var(--faint); }

.search-bar input:focus { outline: none; box-shadow: none; }

.search-bar button {
  border: none;
  background: var(--indigo-900);
  color: var(--white);
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 600;
  padding: 0.7rem 1.15rem;
  cursor: pointer;
  border-radius: 0;
}

.search-bar button:hover { background: var(--indigo-800); }

/* ——— 5. Topic cards (overlapping near hero, NerdWallet-style) ——— */
.topics {
  margin-top: -1.25rem;
  padding-bottom: 2.5rem;
  position: relative;
  z-index: 2;
}

.topics-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.topic-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.2rem 1.35rem;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-card);
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
}

.topic-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 28px rgba(36, 29, 90, 0.12);
  border-color: var(--indigo-100);
  color: inherit;
}

.topic-icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 12px;
  background: var(--indigo-50);
  color: var(--indigo-800);
  display: grid;
  place-items: center;
  margin-bottom: 0.15rem;
}

.topic-icon svg { width: 1.25rem; height: 1.25rem; }

.topic-card h2 {
  font-size: 1.1rem;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin: 0;
}

.topic-card p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.45;
  flex: 1;
}

.topic-cta {
  font-size: 0.875rem;
  font-weight: 650;
  color: var(--coral-600);
  margin-top: 0.25rem;
}

.topic-card:hover .topic-cta { color: var(--coral-700); }

/* ——— Shared section ——— */
.section {
  padding: 2.75rem 0;
}

.section-alt {
  background: var(--white);
  border-block: 1px solid var(--border-soft);
}

.section-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 0.75rem 1.5rem;
  margin-bottom: 1.5rem;
}

.section-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--coral-600);
  margin: 0 0 0.35rem;
}

.section-head h2 {
  font-size: clamp(1.45rem, 2.5vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--ink);
  margin: 0 0 0.35rem;
}

.section-head p {
  margin: 0;
  color: var(--muted);
  font-size: 0.975rem;
  max-width: 36rem;
}

.section-link {
  font-size: 0.9rem;
  font-weight: 650;
  color: var(--coral-600);
  text-decoration: none;
  white-space: nowrap;
}

.section-link:hover { color: var(--coral-700); text-decoration: underline; }

/* ——— 6. Lab basics ——— */
.lab-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.85rem;
}

.lab-card {
  background: var(--cream);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 1.1rem 1rem;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  transition: border-color 0.15s, background 0.15s;
}

.section-alt .lab-card { background: var(--cream); }

.lab-card:hover {
  border-color: var(--indigo-700);
  background: var(--indigo-50);
  color: inherit;
}

.lab-cat {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--indigo-700);
}

.lab-card h3 {
  font-size: 1rem;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
  letter-spacing: -0.01em;
}

.lab-card p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.4;
}

/* ——— 7. Peptide profiles ——— */
.profile-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.profile-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.2rem;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  transition: transform 0.15s, box-shadow 0.15s;
}

.profile-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-card);
  color: inherit;
}

.profile-cat {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
}

.profile-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0;
}

.profile-card p {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.45;
  flex: 1;
}

.profile-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  margin-top: 0.35rem;
  padding-top: 0.65rem;
  border-top: 1px solid var(--border-soft);
  font-size: 0.8rem;
}

.profile-reviewed {
  color: var(--muted);
  font-weight: 500;
}

.profile-go {
  font-weight: 650;
  color: var(--coral-600);
}

/* ——— 8. Comparisons ——— */
.compare-list {
  list-style: none;
  margin: 0;
  padding: 0;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.compare-list li {
  border-bottom: 1px solid var(--border-soft);
}

.compare-list li:last-child { border-bottom: none; }

.compare-list a {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1rem;
  align-items: center;
  padding: 1.1rem 1.25rem;
  text-decoration: none;
  color: inherit;
  transition: background 0.12s;
}

.compare-list a:hover {
  background: var(--indigo-50);
  color: inherit;
}

.compare-rank {
  width: 2rem;
  height: 2rem;
  border-radius: 8px;
  background: var(--coral-50);
  color: var(--coral-700);
  font-size: 0.85rem;
  font-weight: 700;
  display: grid;
  place-items: center;
}

.compare-body h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 0.2rem;
  letter-spacing: -0.015em;
}

.compare-body p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--muted);
  line-height: 1.4;
}

.compare-go {
  font-size: 0.875rem;
  font-weight: 650;
  color: var(--coral-600);
  white-space: nowrap;
}

/* ——— Credibility band ——— */
.cred-band {
  background: var(--indigo-950);
  color: rgba(255, 255, 255, 0.85);
  padding: 2.25rem 0;
}

.cred-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.cred-grid h3 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--white);
  margin: 0 0 0.4rem;
}

.cred-grid p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.72);
}

.cred-grid a {
  color: #f9a89c;
  font-weight: 600;
}

.cred-grid a:hover { color: var(--white); }

/* ——— Footer ——— */
.site-footer {
  background: var(--ink);
  color: #a8a29e;
  padding: 2.75rem 0 1.5rem;
  font-size: 0.9rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid rgba(168, 162, 158, 0.2);
}

.footer-brand .logo-text { color: var(--white); }
.footer-brand .logo-text small { opacity: 0.5; color: #a8a29e; }
.footer-brand .logo { margin-bottom: 0.75rem; }

.footer-brand p {
  margin: 0 0 0.85rem;
  max-width: 22rem;
  font-size: 0.875rem;
  line-height: 1.5;
}

.no-sell {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #f9a89c;
  background: rgba(240, 106, 88, 0.12);
  border: 1px solid rgba(240, 106, 88, 0.3);
  padding: 0.35rem 0.7rem;
  border-radius: var(--radius-pill);
}

.footer-col h3 {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #78716c;
  margin: 0 0 0.75rem;
}

.footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-col li { margin-bottom: 0.4rem; }

.footer-col a {
  color: #d6d3d1;
  text-decoration: none;
}

.footer-col a:hover { color: var(--white); }

.footer-bottom {
  font-size: 0.8rem;
  color: #78716c;
  line-height: 1.5;
}

.footer-bottom p { margin: 0; }

/* ——— Responsive ——— */
@media (max-width: 960px) {
  .topics-grid { grid-template-columns: repeat(2, 1fr); }
  .lab-grid { grid-template-columns: repeat(3, 1fr); }
  .profile-grid { grid-template-columns: repeat(2, 1fr); }
  .cred-grid { grid-template-columns: 1fr; gap: 1.25rem; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .trust-sep { display: none; }
}

@media (max-width: 720px) {
  .nav-toggle { display: block; }

  .primary-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: var(--indigo-900);
    padding: 0.5rem 1rem 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }

  .primary-nav.is-open { display: block; }

  .primary-nav ul { flex-direction: column; align-items: stretch; }

  .primary-nav a { padding: 0.7rem 0.85rem; }

  .site-header { position: relative; }
  .header-inner { position: relative; }

  .lab-grid { grid-template-columns: repeat(2, 1fr); }
  .profile-grid { grid-template-columns: 1fr; }
  .compare-list a { grid-template-columns: auto 1fr; }
  .compare-go { display: none; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .btn { width: 100%; }
  .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; }
}

@media (max-width: 480px) {
  .topics-grid { grid-template-columns: 1fr; }
  .lab-grid { grid-template-columns: 1fr; }
  .topics { margin-top: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .topic-card, .profile-card { transition: none; }
  .topic-card:hover, .profile-card:hover { transform: none; }
}

/* Client-side title/description search (index: /search-index.json) */
.search-results{list-style:none;margin:.6rem 0 0;padding:0;max-width:28rem;background:var(--white);border:1px solid var(--border);border-radius:var(--radius-sm,8px);box-shadow:var(--shadow)}
.search-results li{padding:.55rem .9rem;border-bottom:1px solid var(--border);font-size:.92rem}
.search-results li:last-child{border-bottom:none}
.search-results a{font-weight:600;display:block}
.search-results span{display:block;color:var(--muted);font-size:.8rem;margin-top:.15rem}
