/* ForecastsPro landing — the affiliate program's page (/affiliates, ARCHITECTURE §15).
 *
 * Loaded after site.css on /affiliates only (site.css keeps its size budget): the facts
 * under the hero, the three-step grid and the application form
 * (assets/js/affiliate-apply.js). Tokens only, no inline styles (the CSP).
 */

/* The program at a glance, under the hero: four facts on one row, two by two on phones. */
.aff-facts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: var(--lp-gap);
  max-width: 980px;
  margin: 36px auto 0;
  list-style: none;
  text-align: left;
}
.aff-facts li { display: flex; align-items: flex-start; gap: 12px; }
.aff-facts li > span:last-child { display: grid; gap: 2px; color: var(--text-muted); font-size: var(--lp-small); line-height: 1.45; }
.aff-facts strong { color: var(--text-primary); font-size: var(--text-md); font-weight: 600; }
@media (max-width: 900px) {
  .aff-facts { grid-template-columns: repeat(2, minmax(0, 1fr)); max-width: 560px; }
}
@media (max-width: 380px) {
  .aff-facts { grid-template-columns: 1fr; }
}

/* How it works, in three steps (the four-step grid of /how-it-works, three wide). */
.steps.steps-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 860px) {
  .steps.steps-3 { grid-template-columns: 1fr; }
}

/* The application: the pitch beside the form, stacked on phones. */
.aff-apply {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  align-items: start;
  gap: 28px clamp(28px, 5vw, 64px);
  padding: clamp(20px, 3.5vw, 40px);
  border: 1px solid var(--border-soft);
  border-radius: var(--lp-card-radius);
  background: var(--lp-card-sheen), var(--bg-base);
}
.aff-apply-copy h2 { font-size: var(--lp-h2); letter-spacing: -0.025em; }
.aff-points { display: grid; gap: 10px; margin-top: 22px; list-style: none; }
.aff-points li { display: flex; align-items: center; gap: 10px; color: var(--text-default); font-size: var(--lp-card-text); }
.aff-points .icon-sm { color: var(--success); }
.aff-form { display: grid; gap: 16px; }
.aff-form .updates-status:empty { display: none; }
.aff-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.aff-field { display: grid; gap: 6px; min-width: 0; margin: 0; padding: 0; border: 0; }
.aff-label { color: var(--text-primary); font-size: var(--text-base); font-weight: 600; }
legend.aff-label { padding: 0; margin-bottom: 6px; }
.aff-opt { margin-left: 6px; color: var(--text-dim); font-size: var(--text-sm); font-weight: 500; }
.aff-input {
  width: 100%;
  min-width: 0;
  height: 48px;
  padding: 0 14px;
  border: 1px solid var(--border-soft);
  border-radius: 8px;
  background: var(--bg-input);
  color: var(--text-primary);
  font: inherit;
  font-size: 16px; /* no zoom-on-focus on iOS */
}
.aff-input::placeholder { color: var(--text-dim); }
.aff-input:hover { border-color: #4b4e57; }
.aff-input:focus-visible { border-color: var(--accent); }
.aff-input[aria-invalid="true"] { border-color: var(--danger); }
.aff-textarea { height: auto; min-height: 88px; padding: 12px 14px; line-height: 1.5; resize: vertical; }
.aff-mono { font-family: var(--font-mono); font-size: 15px; }
.aff-hint { color: var(--text-muted); font-size: var(--lp-small); line-height: 1.5; }
.aff-net-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; padding: 4px; border-radius: 10px; background: var(--bg-input); }
.aff-net-opt { position: relative; display: block; }
.aff-net-opt input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.aff-net-opt span {
  display: flex;
  align-items: center;
  justify-content: center;
  height: var(--lp-tap);
  border-radius: 7px;
  color: var(--text-muted);
  font-size: var(--text-base);
  font-weight: 600;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}
.aff-net-opt:hover span { color: var(--text-primary); background: var(--bg-hover); }
.aff-net-opt input:checked + span { background: var(--accent); color: #fff; }
.aff-net-opt input:focus-visible + span { box-shadow: var(--focus-ring); }
.aff-check { display: flex; align-items: flex-start; gap: 10px; min-height: var(--lp-tap); color: var(--text-default); font-size: var(--text-md); line-height: 1.5; cursor: pointer; }
.aff-check input { flex: none; width: 20px; height: 20px; margin: 2px 0 0; accent-color: var(--accent); }
.aff-check input[aria-invalid="true"] { outline: 2px solid var(--danger); outline-offset: 2px; }
/* The honeypot: out of sight, out of the tab order and the accessibility tree. */
.aff-hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.aff-done { display: grid; justify-items: start; gap: 10px; padding: 8px 0; }
.aff-done:focus { outline: none; }
.aff-done h3 { font-size: var(--lp-h3); }
.aff-done p { color: var(--text-muted); font-size: var(--lp-card-text); line-height: 1.6; }
@media (max-width: 900px) {
  .aff-apply { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .aff-pair { grid-template-columns: 1fr; }
}
