/* ============================================================
   Partner program landing page (src/pages/partner.astro)
   Mirrors Crystal Peptides' crystalpeptides.eu/en/partner structure with NZM
   visual system. Tokens come from global.css — never hardcode.
   ============================================================ */

/* ─── HERO ─────────────────────────────────────────────────── */
.pa-hero {
  background: var(--paper);
  padding: 96px 0 88px;
  border-bottom: 1px solid var(--line-soft);
}
.pa-hero__inner {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: 80px;
  align-items: center;
}
.pa-hero__eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 24px;
}
.pa-hero__title {
  font-size: var(--t-h1);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--ink);
  margin-bottom: 24px;
}
.pa-hero__lede {
  font-size: 18px;
  line-height: 1.55;
  color: var(--ink-soft);
  max-width: 560px;
  margin-bottom: 32px;
}
.pa-hero__cta {
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 56px;
}
.pa-hero__link {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.pa-hero__link:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

.pa-hero__stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  padding-top: 32px;
  border-top: 1px solid var(--line);
}
.pa-stat__num {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin-bottom: 6px;
}
.pa-stat__lbl {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
}

/* Hero ladder preview (right column) */
.pa-hero__ladder {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 32px 28px;
  position: relative;
}
.pa-ladder__head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--ink-muted);
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line-soft);
  margin-bottom: 20px;
}
.pa-ladder__head > span:first-child { color: var(--accent); }
.pa-ladder__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.pa-ladder__step {
  display: grid;
  grid-template-columns: minmax(40px, 1fr) auto auto;
  align-items: center;
  gap: 16px;
  font-size: 14px;
  color: var(--ink);
}
.pa-ladder__bar {
  display: block;
  height: 6px;
  background: var(--accent-soft);
  border-radius: 5px;
  position: relative;
  overflow: hidden;
  /* width scales with milestone index — instrumentation feel */
  width: calc(28% + (var(--step-i) / var(--step-of)) * 72%);
}
.pa-ladder__bar::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 32%;
  background: var(--accent);
  border-radius: 5px;
}
.pa-ladder__amount {
  font-weight: 700;
  font-size: 16px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
  min-width: 64px;
  text-align: right;
}
.pa-ladder__threshold {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--ink-muted);
  white-space: nowrap;
}

/* ─── SECTION HEAD (shared inside partner page) ───────────── */
.pa-section__head {
  max-width: 760px;
  margin-bottom: 56px;
}
.pa-section__eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 16px;
}
.pa-section__title {
  font-size: var(--t-h2);
  font-weight: 700;
  letter-spacing: -0.015em;
  line-height: 1.1;
  color: var(--ink);
}
.pa-section__head--light .pa-section__eyebrow { color: rgba(230, 233, 245, 0.7); }
.pa-section__head--light .pa-section__title { color: var(--white); }

/* ─── WHY JOIN ────────────────────────────────────────────── */
.pa-why {
  background: var(--paper);
  padding: 112px 0;
}
.pa-why__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
}
.pa-card {
  background: var(--white);
  border: 1px solid var(--line-soft);
  border-radius: 5px;
  padding: 32px 28px 36px;
  display: flex;
  flex-direction: column;
  transition: border-color 0.25s ease, transform 0.25s ease;
}
.pa-card:hover {
  border-color: var(--ink-muted);
  transform: translateY(-2px);
}
.pa-card__num {
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 20px;
}
.pa-card__title {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 12px;
  line-height: 1.25;
}
.pa-card__body {
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink-soft);
}

/* ─── MILESTONE LADDER (dark band, signature object) ──────── */
.pa-milestones {
  background: var(--ink);
  color: var(--white);
  padding: 112px 0 120px;
  position: relative;
  overflow: hidden;
}
.pa-milestones::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 80px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 80px);
  pointer-events: none;
}
.pa-milestones .pa-section__head { position: relative; max-width: 720px; }
.pa-milestones__lede {
  font-size: 16px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.7);
  margin-top: 16px;
  max-width: 600px;
}
.pa-milestones__row {
  position: relative;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 12px;
  align-items: end;
  padding-top: 32px;
}
.pa-milestone {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-start;
}
.pa-milestone__col {
  width: 100%;
  /* visual bar height scales by milestone index — taller = bigger bonus */
  height: calc(48px + (var(--m-i) / var(--m-of)) * 220px);
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent-hover) 100%);
  border-radius: 5px;
  position: relative;
}
.pa-milestone__col::after {
  /* subtle top cap for instrument feel */
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: rgba(255, 255, 255, 0.4);
  border-radius: 5px 5px 0 0;
}
.pa-milestone__amount {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--white);
  font-variant-numeric: tabular-nums;
}
.pa-milestone__threshold {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: rgba(255, 255, 255, 0.55);
  white-space: nowrap;
}

/* ─── WHO THIS IS FOR ─────────────────────────────────────── */
.pa-who {
  background: var(--paper);
  padding: 112px 0;
}
.pa-who__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}
.pa-who__card {
  background: var(--paper-cool);
  border: 1px solid var(--line-soft);
  border-radius: 5px;
  padding: 28px 24px 28px;
  display: flex;
  flex-direction: column;
}
.pa-who__check {
  width: 28px;
  height: 28px;
  border-radius: 5px;
  background: var(--accent);
  color: var(--white);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}
.pa-who__title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.005em;
  color: var(--ink);
  margin-bottom: 8px;
  line-height: 1.25;
}
.pa-who__body {
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink-soft);
}
.pa-who__note {
  margin-top: 40px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
  text-align: center;
}

/* ─── HOW IT WORKS ────────────────────────────────────────── */
.pa-how {
  background: var(--paper-cool);
  padding: 112px 0;
}
.pa-how__grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
  counter-reset: pahow;
}
.pa-how__step {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 36px 32px 40px;
  position: relative;
}
.pa-how__num {
  font-family: var(--font-mono);
  font-size: 56px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: var(--accent);
  line-height: 1;
  margin-bottom: 24px;
  font-variant-numeric: tabular-nums;
}
.pa-how__title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--ink);
  margin-bottom: 10px;
}
.pa-how__body {
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-soft);
}

/* ─── TWO WAYS TO EARN ────────────────────────────────────── */
.pa-channels {
  background: var(--paper);
  padding: 112px 0;
}
.pa-channels__split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.pa-channel {
  background: var(--white);
  border: 1px solid var(--line);
  border-radius: 5px;
  padding: 40px 36px 36px;
  display: flex;
  flex-direction: column;
}
.pa-channel__label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 24px;
}
.pa-channel__title {
  font-size: 26px;
  font-weight: 700;
  letter-spacing: -0.015em;
  color: var(--ink);
  margin-bottom: 14px;
  line-height: 1.2;
}
.pa-channel__body {
  font-size: 15px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin-bottom: 28px;
  flex-grow: 1;
}
.pa-channel__sample {
  background: var(--paper-cool);
  border: 1px solid var(--line-soft);
  border-radius: 5px;
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.pa-channel__sample-lbl {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
}
.pa-channel__sample-val {
  font-size: 15px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--ink);
}
.pa-channels__note {
  margin-top: 32px;
  text-align: center;
  font-size: 14px;
  color: var(--ink-soft);
  font-style: normal;
}

/* ─── FAQ ─────────────────────────────────────────────────── */
.pa-faq {
  background: var(--paper);
  padding: 112px 0;
}
/* Partner FAQ — uses the canonical Faq class vocabulary (.faq__num /
   .faq__q / .faq__a / .faq__plus). Styles are scoped under .pa-faq__list
   because the matching rules in home.css aren't included on this page.
   If the FAQ block is ever lifted into global.css, these scoped rules
   still take precedence without conflict. */
.pa-faq__list {
  max-width: 880px;
  margin: 0 auto;
  border-top: 1px solid var(--line);
}
.pa-faq__list .faq__item {
  display: grid;
  grid-template-columns: 56px 1fr 32px;
  gap: 16px;
  align-items: start;
  padding: 28px 8px;
  border-bottom: 1px solid var(--line);
  cursor: pointer;
  transition: background 0.25s ease;
}
.pa-faq__list .faq__item:hover .faq__q { color: var(--ink-soft); }
.pa-faq__list .faq__num {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.1em;
  color: var(--ink-muted);
  padding-top: 4px;
}
.pa-faq__list .faq__q {
  font-size: 19px;
  font-weight: 600;
  letter-spacing: -0.005em;
  color: var(--ink);
  line-height: 1.35;
}
.pa-faq__list .faq__a {
  font-size: 15px;
  line-height: 1.65;
  color: var(--ink-soft);
  margin-top: 14px;
  max-width: 680px;
}
.pa-faq__list .faq__plus {
  font-family: var(--font-mono);
  font-size: 22px;
  font-weight: 300;
  color: var(--ink-muted);
  line-height: 1;
  text-align: right;
  transform-origin: 50% 50%;
  transition: transform 0.3s cubic-bezier(0.2, 0.8, 0.2, 1), color 0.25s ease;
  padding-top: 2px;
}
.pa-faq__list .faq__item--open .faq__plus {
  transform: rotate(45deg);
  color: var(--accent);
}

/* ─── FINAL CTA ───────────────────────────────────────────── */
.pa-cta {
  background: var(--paper-cool);
  padding: 120px 0;
}
.pa-cta__inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}
.pa-cta__eyebrow {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 24px;
}
.pa-cta__title {
  font-size: var(--t-h2);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  color: var(--ink);
  margin-bottom: 20px;
}
.pa-cta__body {
  font-size: 17px;
  line-height: 1.55;
  color: var(--ink-soft);
  margin-bottom: 40px;
}
.pa-cta__row {
  display: inline-flex;
  align-items: center;
  gap: 28px;
}
.pa-cta__link {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--ink);
  border-bottom: 1px solid var(--line);
  padding-bottom: 2px;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.pa-cta__link:hover {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* ─── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 1024px) {
  .pa-hero { padding: 72px 0 64px; }
  .pa-hero__inner { grid-template-columns: 1fr; gap: 56px; }
  .pa-hero__ladder { max-width: 520px; }

  .pa-why,
  .pa-who,
  .pa-how,
  .pa-channels,
  .pa-faq { padding: 88px 0; }
  .pa-milestones { padding: 88px 0 96px; }
  .pa-cta { padding: 96px 0; }

  .pa-why__grid { grid-template-columns: repeat(2, 1fr); gap: 20px; }
  .pa-who__grid { grid-template-columns: repeat(2, 1fr); }
  .pa-how__grid { grid-template-columns: 1fr; gap: 20px; }
  .pa-channels__split { grid-template-columns: 1fr; }

  /* On tablet the 8-column milestone row gets cramped — drop to 4×2 */
  .pa-milestones__row {
    grid-template-columns: repeat(4, 1fr);
    gap: 16px 12px;
  }
  .pa-milestone__col {
    height: calc(36px + (var(--m-i) / var(--m-of)) * 140px);
  }
}

@media (max-width: 640px) {
  .pa-hero { padding: 56px 0 48px; }
  .pa-hero__cta { flex-direction: column; align-items: flex-start; gap: 16px; margin-bottom: 40px; }
  .pa-hero__stats { grid-template-columns: 1fr 1fr; gap: 20px; }
  .pa-hero__ladder { padding: 24px 20px; }

  .pa-why,
  .pa-who,
  .pa-how,
  .pa-channels,
  .pa-faq { padding: 64px 0; }
  .pa-milestones { padding: 64px 0 72px; }
  .pa-cta { padding: 72px 0; }

  .pa-section__head { margin-bottom: 40px; }

  .pa-why__grid { grid-template-columns: 1fr; gap: 16px; }
  .pa-card { padding: 28px 24px 32px; }

  .pa-who__grid { grid-template-columns: 1fr; }

  .pa-channel { padding: 32px 24px 28px; }
  .pa-channel__title { font-size: 22px; }

  .pa-milestones__row { grid-template-columns: repeat(2, 1fr); gap: 20px 12px; }
  .pa-milestone__col { height: calc(32px + (var(--m-i) / var(--m-of)) * 100px); }

  .pa-faq__list .faq__item { grid-template-columns: 40px 1fr 24px; gap: 12px; padding: 22px 4px; }
  .pa-faq__list .faq__q { font-size: 16px; }
  .pa-faq__list .faq__a { font-size: 14px; }

  .pa-cta__row { flex-direction: column; gap: 20px; }
}

/* ─── REDUCED MOTION ──────────────────────────────────────────
   Short-circuit decorative hover transforms + FAQ toggle rotate
   when the user prefers reduced motion. Pure CSS, no JS. */
@media (prefers-reduced-motion: reduce) {
  .pa-card,
  .pa-faq__list .faq__qtoggle {
    transition: none;
  }
  .pa-card:hover {
    transform: none;
  }
  .pa-faq__list .faq__item--open .faq__qtoggle {
    transform: none;
  }
}
