/* =============================================================
   design-system.css — Affiliates Portal
   Base tokens + shared components used by all affiliate templates.
   Phase 4 CSP cleanup (extracts inline styles from templates).
   ============================================================= */

:root {
  --pm-color-primary: #92a4bb;
  --pm-color-primary-light: #d1e3f0;
  --pm-color-secondary: #f2b872;
  --pm-color-accent: #ff6d4d;
  --pm-color-background: #f7f1e3;
  --pm-color-surface: #ffffff;
  --pm-color-text-strong: #1a2533;
  --pm-color-text: #2f3a48;
  --pm-color-text-soft: #6b7280;
  --pm-color-blue-active: #1c5680;
  --pm-color-green-cta-strong: #2d8659;
  --pm-font-ui: 'Inter', system-ui, sans-serif;
  --pm-font-hand: 'Patrick Hand', cursive;
  --pm-radius-md: 8px;
  --pm-radius-xl: 16px;
}

/* ---- Layout sections ---- */
.pm-l-section { background: var(--pm-color-surface); }
.pm-l-section--soft { background: var(--pm-color-primary-light); }
.pm-l-section--ink { background: var(--pm-color-text-strong); }
.pm-l-section--surface { background: var(--pm-color-surface); }
.pm-u-pt-0 { padding-top: 0; }

/* ---- Text utilities ---- */
.pm-u-text-white { color: #fff; }
.pm-u-text-white-80 { color: rgba(255, 255, 255, 0.8); }
.pm-u-text-white-75 { color: rgba(255, 255, 255, 0.75); }
.pm-u-text-white-60 { color: rgba(255, 255, 255, 0.6); }
.pm-u-text-blue-active { color: var(--pm-color-blue-active); }
.pm-u-text-soft { color: var(--pm-color-text-soft); }
.pm-u-color-error { color: #b00020; }
.pm-u-color-success { color: var(--pm-color-green-cta-strong); }
.pm-u-color-info { color: var(--pm-color-blue-active); }
.pm-u-max-width-580 { max-width: 580px; }
.pm-u-mt-xs { margin-top: 12px; }
.pm-u-mt-top { margin-top: 12px; }

/* ---- Hero ---- */
.pm-c-hero { padding: 64px 24px; text-align: center; max-width: 960px; margin: 0 auto; }
.pm-c-hero__title {
  font-size: 30px;
  font-weight: 800;
  margin: 12px 0 16px;
  color: var(--pm-color-text-strong);
  font-family: var(--pm-font-ui);
}
.pm-c-hero__title--md { font-size: 26px; }
.pm-c-hero__title--lg { font-size: 36px; font-weight: 800; margin-bottom: 20px; }
.pm-c-hero__title--hero { font-size: 32px; font-weight: 800; margin-top: 12px; margin-bottom: 16px; }
.pm-c-hero__title--lp-vuelta { font-size: 28px; }
.pm-c-hero__copy { padding: 40px 24px 32px; max-width: 720px; margin: 0 auto; }
.pm-c-hero__copy--compact { padding: 40px 24px 32px; max-width: 400px; margin: 0 auto; text-align: left; }
.pm-c-hero__emoji { font-size: 64px; line-height: 1; margin-bottom: 16px; }
.pm-c-hero__media { max-width: 240px; padding: 24px; }
.pm-c-hero__media--md { max-width: 280px; padding: 24px; }

/* ---- Buttons ---- */
.pm-c-button--primary {
  background: var(--pm-color-primary);
  color: #fff;
  padding: 14px 32px;
  border-radius: var(--pm-radius-md);
  font-weight: 700;
  text-decoration: none;
  display: inline-block;
}
.pm-c-button--accent {
  background: var(--pm-color-accent);
  color: #fff;
  padding: 14px 32px;
  border-radius: var(--pm-radius-md);
  font-weight: 700;
  text-decoration: none;
  display: inline-block;
}
.pm-c-button--ghost {
  background: transparent;
  border: 2px solid var(--pm-color-primary);
  color: var(--pm-color-primary);
  padding: 12px 28px;
  border-radius: var(--pm-radius-md);
  font-weight: 600;
  text-decoration: none;
  display: inline-block;
}
.pm-c-button--ghost-white {
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
  background: transparent;
}
.pm-c-cta-cta { min-width: 240px; padding: 14px 32px; }

/* ---- Card ---- */
.pm-c-card {
  background: #fff;
  border-radius: var(--pm-radius-md);
  padding: 24px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.05);
}
.pm-c-card--narrow { max-width: 400px; margin: 0 auto; text-align: left; }

/* ---- Images ---- */
.pm-c-image--full { width: 100%; max-width: 480px; border-radius: var(--pm-radius-md); }
.pm-c-image--wide { width: 100%; border-radius: var(--pm-radius-md); }
.pm-c-qr-image { width: 140px; max-width: 200px; }

/* ---- Flex layouts ---- */
.pm-c-flex-row-center {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
}
.pm-c-flex-row-end {
  display: flex;
  gap: 12px;
  justify-content: flex-end;
  flex-wrap: wrap;
}
.pm-c-list-item {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.pm-c-list-check {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.pm-c-list-check--inline {
  list-style: none;
  padding: 0;
  margin: 0 0 24px;
  display: inline-flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-start;
}

/* ---- Check marks (icons) ---- */
.pm-c-check-mark {
  font-size: 16px;
  line-height: 1;
}
.pm-c-check-mark--success {
  color: var(--pm-color-green-cta-strong);
  font-size: 16px;
  line-height: 1;
  flex-shrink: 0;
}
.pm-c-check-mark--success-static {
  color: var(--pm-color-green-cta-strong);
  font-size: 16px;
  line-height: 1;
}
.pm-c-check-mark--info {
  color: var(--pm-color-blue-active);
  font-size: 16px;
  line-height: 1;
}
.pm-c-check-mark--error {
  color: #b00020;
  font-size: 16px;
  line-height: 1;
  flex-shrink: 0;
}

/* ---- Text sizes / typography ---- */
.pm-c-text-15 {
  font-family: var(--pm-font-ui);
  font-size: 15px;
  color: var(--pm-color-text-strong);
  margin: 0 0 8px;
}
.pm-c-text-15-bold {
  font-family: var(--pm-font-ui);
  font-size: 15px;
  color: var(--pm-color-text-strong);
  margin: 0 0 8px;
}
.pm-c-text-14 { font-size: 14px; }
.pm-c-text-13 { font-size: 13px; }
.pm-c-text-12 { font-size: 12px; }
.pm-c-text-13-soft {
  font-family: var(--pm-font-ui);
  font-size: 13px;
  color: var(--pm-color-text-soft);
  margin: 0;
}
.pm-c-text-13-hand {
  font-family: var(--pm-font-hand);
  font-size: 13px;
  color: var(--pm-color-text-soft);
}
.pm-c-link-ui {
  color: var(--pm-color-blue-active);
  font-family: var(--pm-font-ui);
  font-size: 14px;
}
.pm-c-footer-note {
  color: rgba(255, 255, 255, 0.75);
  font-family: var(--pm-font-ui);
  font-size: 13px;
}

/* ---- Step / nav / trust ---- */
.pm-c-step-highlight {
  background: var(--pm-color-green-cta-strong);
  color: #fff;
}
.pm-c-nav-divider {
  margin: 0 12px;
  color: var(--pm-color-text-soft);
}
.pm-c-trust-band {
  background: var(--pm-color-text-strong);
  padding: 24px;
}
.pm-c-trust-band__item {
  color: #fff;
  font-size: 14px;
}
.pm-c-field__hint--center {
  text-align: center;
  margin: 0;
}
/* ============================================================
   AFFILIATES PM-* COMPONENTS — used by /landing-afiliados/*.html
   Scoped under .pm-l-page so they don't leak to /tienda/ pages.
   Color tokens: --pm-primary (warm beige), --pm-ink (warm black),
   --pm-bg (warm cream), --pm-border (soft slate).
   ============================================================ */

.pm-l-page {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--pm-ink, #1f2328);
  background: var(--pm-bg, #f7f1e3);
  line-height: 1.55;
  margin: 0;
  padding: 0;
}

.pm-l-page.pm-l-page--with-sticky { padding-bottom: 96px; }

.pm-l-container { width: 100%; max-width: 1120px; margin: 0 auto; padding: 0 24px; box-sizing: border-box; }
.pm-l-container--md { max-width: 760px; }
.pm-l-container--lg { max-width: 1040px; }

.pm-l-section { padding: 64px 0; }
.pm-l-section--soft { background: #faf6ec; }
.pm-l-section--ink { background: #1f2328; color: #f7f1e3; }

.pm-l-grid { display: grid; gap: 24px; }
.pm-l-grid--2 { grid-template-columns: 1fr; }
.pm-l-grid--3 { grid-template-columns: 1fr; }
@media (min-width: 720px) {
  .pm-l-grid--2 { grid-template-columns: 1fr 1fr; }
  .pm-l-grid--3 { grid-template-columns: 1fr 1fr 1fr; }
}

.pm-l-split { display: grid; gap: 32px; }
@media (min-width: 720px) { .pm-l-split { grid-template-columns: 1fr 1fr; } }

.pm-c-eyebrow {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  color: var(--pm-primary, #92a4bb);
  margin-bottom: 12px;
}

.pm-c-section-title {
  font-family: 'Inter', sans-serif;
  font-size: clamp(24px, 3.5vw, 32px);
  font-weight: 600;
  margin: 0 0 12px;
  color: inherit;
}
.pm-c-section-title--underlined {
  display: inline-block;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--pm-primary, #92a4bb);
}
.pm-u-center { text-align: center; }
.pm-u-mb-sm { margin-bottom: 8px; }
.pm-u-mb-md { margin-bottom: 16px; }
.pm-u-mb-lg { margin-bottom: 32px; }
.pm-u-text-white { color: #fff; }
.pm-u-text-white-80 { color: rgba(255,255,255,.8); }

.pm-c-card {
  background: #fff;
  border: 1px solid #e6dfce;
  border-radius: 12px;
  padding: 24px;
  box-sizing: border-box;
}
.pm-c-card--soft { background: #fffaf0; border-color: #f0e6d0; }
.pm-c-card--outlined { background: #fff; border: 1px solid #d8cfb8; }
.pm-c-card__icon { font-size: 28px; margin-bottom: 8px; }
.pm-c-card__title { font-size: 18px; font-weight: 600; margin: 0 0 8px; color: inherit; }
.pm-c-card__body { font-size: 15px; line-height: 1.6; margin: 0; color: rgba(31,35,40,.85); }

.pm-c-lead { font-size: 17px; line-height: 1.55; margin: 0; }

/* FORM */
.pm-c-form { display: grid; gap: 18px; }

.pm-c-field { display: grid; gap: 6px; }
.pm-c-field__label {
  font-size: 14px;
  font-weight: 500;
  color: inherit;
}
.pm-c-field__control {
  width: 100%;
  padding: 12px 14px;
  font-family: inherit;
  font-size: 15px;
  color: #1f2328;
  background: #fff;
  border: 1px solid #d8cfb8;
  border-radius: 8px;
  box-sizing: border-box;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.pm-c-field__control:focus {
  outline: none;
  border-color: var(--pm-primary, #92a4bb);
  box-shadow: 0 0 0 3px rgba(146,164,187,.18);
}
.pm-c-field__control::placeholder { color: #a8a292; }

.pm-c-checkbox { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; }
.pm-c-checkbox input { margin-top: 3px; }

.pm-c-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 20px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 600;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  transition: transform .1s ease, background .15s ease, border-color .15s ease;
  text-decoration: none;
}
.pm-c-button:active { transform: translateY(1px); }
.pm-c-button--purchase {
  background: var(--pm-accent, #ff6d4d);
  color: #fff;
  border-color: var(--pm-accent, #ff6d4d);
}
.pm-c-button--purchase:hover { background: #e85a3a; border-color: #e85a3a; }
.pm-c-button--full { width: 100%; }

/* HERO */
.pm-c-hero {
  display: grid;
  gap: 32px;
  padding: 48px 24px;
  max-width: 1120px;
  margin: 0 auto;
}
@media (min-width: 820px) {
  .pm-c-hero { grid-template-columns: 1.1fr 1fr; align-items: center; padding: 72px 24px; }
}
.pm-c-hero__media { border-radius: 16px; overflow: hidden; }
.pm-c-hero__image { display: block; width: 100%; height: auto; }
.pm-c-hero__copy { display: grid; gap: 16px; align-content: center; }
.pm-c-hero__title {
  font-size: clamp(28px, 5vw, 44px);
  font-weight: 700;
  line-height: 1.1;
  margin: 0;
  color: #1f2328;
}
.pm-c-hero__lead { font-size: 17px; line-height: 1.55; margin: 0; color: rgba(31,35,40,.78); }
.pm-c-hero__cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  align-self: start;
  padding: 14px 22px;
  background: var(--pm-accent, #ff6d4d);
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 600;
  font-size: 15px;
}
.pm-c-hero__cta:hover { background: #e85a3a; }
.pm-c-hero__microcopy { font-size: 13px; color: rgba(31,35,40,.6); margin: 0; }

/* LISTS */
.pm-c-list-check { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.pm-c-list-check__item {
  position: relative;
  padding-left: 28px;
  font-size: 15px;
  line-height: 1.5;
}
.pm-c-list-check__item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #92a4bb;
}
.pm-c-list-check__item.pm-c-check-mark--info::before { background: #92a4bb; }
.pm-c-list-check__item.pm-c-check-mark--success-static::before { background: #4caf50; }

/* STEPS */
.pm-c-step-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 18px; }
.pm-c-step {
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 16px;
  align-items: start;
  padding: 20px;
  background: #fff;
  border: 1px solid #e6dfce;
  border-radius: 12px;
}
.pm-c-step__number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--pm-primary, #92a4bb);
  color: #fff;
  font-weight: 700;
  font-size: 17px;
}
.pm-c-step__title { font-size: 16px; font-weight: 600; margin: 0 0 4px; }
.pm-c-step__text { font-size: 14px; line-height: 1.5; margin: 0; color: rgba(31,35,40,.78); }

/* FAQ */
.pm-c-faq { display: grid; gap: 14px; }
.pm-c-faq__item { background: #fff; border: 1px solid #e6dfce; border-radius: 12px; padding: 18px 20px; }
.pm-c-faq__q { font-weight: 600; font-size: 15px; margin: 0 0 6px; }
.pm-c-faq__a { font-size: 14px; line-height: 1.55; margin: 0; color: rgba(31,35,40,.78); }

/* MOBILE STICKY CTA */
.pm-c-mobile-sticky {
  display: none;
  position: fixed;
  bottom: 16px;
  left: 16px;
  right: 16px;
  z-index: 50;
  background: #fff;
  border: 1px solid #e6dfce;
  border-radius: 12px;
  padding: 12px 16px;
  box-shadow: 0 8px 24px rgba(31,35,40,.18);
  text-align: center;
}
.pm-c-mobile-sticky__cta {
  display: block;
  background: var(--pm-accent, #ff6d4d);
  color: #fff;
  text-decoration: none;
  padding: 10px 14px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
}
.pm-c-mobile-sticky__microcopy { font-size: 12px; color: rgba(31,35,40,.6); margin: 6px 0 0; }
@media (max-width: 720px) { .pm-c-mobile-sticky { display: block; } }
