/* Affiliate hub (/affiliates/): builds on site.css (.legal layout, tokens). */
.aff .legal__in > * { max-width: 78ch; }
.aff .aff__lead { font-size: 1.15rem; color: var(--text); }
.aff__status { display: inline-flex; align-items: center; gap: 8px; margin: 4px 0 8px; padding: 6px 12px; border-radius: 999px; font-size: 14px; font-weight: 600; background: var(--navy-2); border: 1px solid var(--line-2); color: var(--steel-mid); }
.aff__status::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--steel-lo); }
.aff__status--open::before { background: var(--signal); box-shadow: 0 0 8px var(--signal-glow); }
.aff__nets { list-style: none; padding: 0 !important; margin: 24px 0 !important; display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); max-width: none !important; }
.aff__nets li { margin: 0 !important; }
.aff__nets a { display: block; height: 100%; padding: 18px 20px; border-radius: 16px; background: var(--navy-2); border: 1px solid var(--line-2); text-decoration: none; transition: border-color .2s; }
.aff__nets a:hover { border-color: var(--steel-mid); }
.aff__nets b { display: block; font-size: 1.1rem; }
.aff__nets span { display: block; margin-top: 4px; font-size: 14px; color: var(--muted); }
.aff__facts { width: 100%; border-collapse: collapse; margin: 18px 0; font-size: 15px; }
.aff__facts th, .aff__facts td { text-align: left; vertical-align: top; padding: 10px 12px; border-bottom: 1px solid var(--line); color: #d3dbe5; }
.aff__facts th { width: 34%; color: var(--muted); font-weight: 500; }
.aff__table-wrap { overflow-x: auto; max-width: none !important; }
.aff__gallery { display: grid; gap: 14px; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); margin: 18px 0; max-width: none !important; }
.aff__gallery figure { margin: 0; padding: 10px; border-radius: 14px; background: var(--navy-2); border: 1px solid var(--line); }
.aff__gallery img { display: block; width: 100%; height: 140px; object-fit: contain; background: var(--navy-0); border-radius: 8px; }
.aff__gallery figcaption { margin-top: 8px; font-size: 13px; color: var(--muted); word-break: break-word; }
.aff__gallery a { color: #fff; }
.aff pre { white-space: pre-wrap; font: 14px/1.55 var(--sans); background: var(--navy-2); border: 1px solid var(--line); border-radius: 12px; padding: 16px 18px; color: #d3dbe5; }
.aff details { border-bottom: 1px solid var(--line); padding: 10px 0; }
.aff summary { cursor: pointer; font-weight: 600; color: #fff; }

/* Affiliate header: program pages linked to each other; wraps on small screens */
.hdr__nav--aff { flex-wrap: wrap; justify-content: flex-end; column-gap: clamp(12px, 2.4vw, 32px); row-gap: 0; }
@media (max-width: 640px) {
  .hdr__nav--aff { column-gap: 12px; max-width: 58vw; }
  .hdr__nav--aff a { font-size: .85rem; padding: 4px 0; }
  .hdr .hdr__name { display: none; }
}

/* Network switcher on the network pages: compact pills, current page highlighted */
.aff__netbar { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 28px; }
.aff__netbar a { display: inline-block; padding: 8px 16px; border-radius: 999px; border: 1px solid var(--line-2); background: var(--navy-2); font-size: 15px; line-height: 1.2; text-decoration: none; color: inherit; transition: border-color .2s; }
.aff__netbar a:hover { border-color: var(--steel-mid); }
.aff__netbar a[aria-current="page"] { border-color: var(--steel-mid); font-weight: 600; }
@media (max-width: 640px) { .aff__netbar a { padding: 7px 12px; font-size: 14px; } }

/* facts stacked on phones: label above value, nothing runs off the screen */
@media (max-width: 640px) {
  .aff__facts, .aff__facts tbody, .aff__facts tr, .aff__facts th, .aff__facts td { display: block; width: auto !important; }
  .aff__facts th { padding: 14px 0 2px !important; border: 0 !important; }
  .aff__facts td { padding: 0 0 14px !important; overflow-wrap: anywhere; }
  .aff__facts tr { border-bottom: 1px solid var(--line-2); }
}
