/* Affiliate Program page — all rules namespaced .ap-* so shared nav/footer keep their own styles */

.ap-page {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: #1F2937;
    background: #fff;
    -webkit-font-smoothing: antialiased;
}

/* global.css forces DM Sans with !important on headings/spans/inputs/buttons;
   this page follows the Poppins refresh, so out-specific it within .ap-page */
.ap-page h1, .ap-page h2, .ap-page h3, .ap-page h4, .ap-page h5, .ap-page h6,
.ap-page p, .ap-page span, .ap-page input, .ap-page button {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif !important;
}

.ap-container {
    max-width: 1200px;
    margin: 0 auto;
    padding-left: 24px;
    padding-right: 24px;
}

.ap-eyebrow {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .14em;
    text-transform: uppercase;
    color: #9CA3AF;
}

.ap-accent { color: #2563EB; }

.ap-page a { color: #2563EB; text-decoration: none; transition: color 150ms cubic-bezier(0.4,0,0.2,1); }
.ap-page a:hover { color: #16306C; }

/* ---- Hero ---- */
.ap-hero { padding: 88px 0 96px; }

.ap-hero-head { text-align: center; max-width: 760px; margin: 0 auto 48px; }

.ap-hero-head h1 {
    font-size: clamp(38px, 5vw, 56px);
    line-height: 1.08;
    font-weight: 600;
    color: #111827;
    letter-spacing: -.02em;
    margin: 0 0 20px;
    text-wrap: balance;
}

.ap-hero-sub {
    font-size: 18px;
    line-height: 1.5;
    color: #6B7280;
    margin: 0 auto;
    max-width: 520px;
    text-wrap: pretty;
}

.ap-hero-chips { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 28px; }

/* ---- Chips ---- */
.ap-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 9999px;
    font-size: 12.5px;
    font-weight: 600;
    background: #EFF4FE;
    color: #2563EB;
}

.ap-chip--outline { background: #fff; color: #374151; border: 1px solid #D1D5DB; }

/* ---- Buttons ---- */
.ap-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    border-radius: 9999px;
    border: 1px solid transparent;
    cursor: pointer;
    transition: background 150ms, color 150ms, border-color 150ms;
}

.ap-btn--primary { background: #2563EB; color: #fff; }
.ap-btn--primary:hover { background: #1D4ED8; color: #fff; }
.ap-btn--outline { background: #fff; color: #374151; border-color: #D1D5DB; }
.ap-btn--outline:hover { border-color: #9CA3AF; color: #374151; }
.ap-btn--lg { padding: 14px 32px; font-size: 15px; }
.ap-btn:disabled { opacity: .5; cursor: not-allowed; }

/* ---- Segmented control ---- */
.ap-seg { display: inline-flex; background: #E9EAEE; border-radius: 9999px; padding: 4px; gap: 2px; }
.ap-seg > button {
    border: 0;
    background: transparent;
    color: #6B7280;
    font-family: inherit;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 18px;
    border-radius: 9999px;
    cursor: pointer;
}
.ap-seg > button.active { background: #2563EB; color: #fff; font-weight: 600; }

.ap-seg--dark { background: #1A1B1E; }
.ap-seg--dark > button { color: #9CA3AF; }
.ap-seg--dark > button.active { background: #2563EB; color: #fff; }

/* ---- Registration form ---- */
.ap-form-wrap { max-width: 620px; margin: 0 auto; }

.ap-card {
    background: #F4F5F7;
    border-radius: 20px;
    padding: 32px;
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.ap-card-title { font-size: 22px; font-weight: 600; color: #111827; letter-spacing: -.01em; margin-bottom: 4px; }
.ap-card-sub { font-size: 14px; color: #6B7280; }

.ap-field-label { font-size: 12px; color: #6B7280; font-weight: 500; margin-bottom: 6px; }

.ap-input {
    width: 100%;
    padding: 14px 16px;
    border-radius: 12px;
    border: 1px solid #D1D5DB;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    color: #111827;
    outline: none;
    background: #fff;
}
.ap-input::placeholder { color: #9CA3AF; font-weight: 400; }
.ap-input:focus { border-color: #2563EB; box-shadow: 0 0 0 3px #DBEAFE; }
.ap-input.ap-invalid { border-color: #DC2626; }

.ap-field-hint { font-size: 12px; color: #9CA3AF; margin-top: 6px; }
.ap-field-error { font-size: 12px; color: #DC2626; margin-top: 6px; }

.ap-form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }

.ap-agree { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.ap-agree input { width: 20px; height: 20px; margin: 2px 0 0; accent-color: #2563EB; flex: none; }
.ap-agree span { font-size: 14px; color: #374151; line-height: 1.55; }

.ap-submit-error { font-size: 14px; color: #DC2626; }

/* ---- Success state ---- */
.ap-success { background: #F4F5F7; border-radius: 20px; padding: 48px 32px; text-align: center; }
.ap-success-icon {
    width: 44px;
    height: 44px;
    border-radius: 9999px;
    background: #DCFCE7;
    color: #15803D;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    font-size: 20px;
    font-weight: 600;
}
.ap-success h3 { font-size: 24px; font-weight: 600; margin: 0 0 8px; color: #111827; }
.ap-success p { font-size: 16px; color: #6B7280; line-height: 1.6; margin: 0 0 24px; }

/* ---- Section headings ---- */
.ap-h2 {
    font-size: clamp(30px, 4vw, 40px);
    font-weight: 600;
    letter-spacing: -.015em;
    color: #111827;
    margin: 0;
}

/* ---- How it works ---- */
.ap-steps-section { background: #F4F5F7; padding: 96px 0; }
.ap-steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 20px; }
.ap-step { background: #fff; border-radius: 20px; padding: 32px; }
.ap-step-num {
    width: 32px;
    height: 32px;
    border-radius: 9999px;
    background: #EFF4FE;
    color: #2563EB;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}
.ap-step h3 { font-size: 22px; font-weight: 600; margin: 0 0 8px; color: #111827; }
.ap-step p { font-size: 15px; color: #6B7280; margin: 0; line-height: 1.6; }

/* ---- Rate card + calculator ---- */
.ap-rates-section { padding: 96px 0; }
.ap-rates-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 56px; align-items: start; }

.ap-rates-intro { font-size: 16px; color: #6B7280; line-height: 1.55; margin: 12px 0 28px; max-width: 420px; text-wrap: pretty; }

.ap-rate-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding: 16px 0;
    border-top: 1px solid #E5E7EB;
    gap: 16px;
}
.ap-rate-row:last-child { border-bottom: 1px solid #E5E7EB; }
.ap-rate-row span:first-child { font-size: 15px; color: #374151; }
.ap-rate-row span:last-child { font-size: 24px; font-weight: 600; color: #111827; letter-spacing: -.02em; }

.ap-calc { background: #111214; border-radius: 28px; padding: 40px; color: #fff; }
.ap-calc-eyebrow { font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: #60A5FA; margin-bottom: 24px; }
.ap-calc-row { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 12px; }
.ap-calc-row span:first-child { font-size: 14px; color: #9CA3AF; }
.ap-calc-row span:last-child { font-size: 22px; font-weight: 600; letter-spacing: -.02em; }
.ap-calc input[type=range] { width: 100%; margin: 0 0 28px; display: block; accent-color: #2563EB; }
.ap-calc-tiles { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ap-calc-tile { background: #1A1B1E; border-radius: 16px; padding: 20px; }
.ap-calc-tile--net { background: #1E2A47; }
.ap-calc-tile-label { font-size: 12px; color: #9CA3AF; margin-bottom: 8px; }
.ap-calc-tile-value { font-size: 26px; font-weight: 600; letter-spacing: -.02em; line-height: 1.1; }
.ap-calc-tile--net .ap-calc-tile-value { color: #60A5FA; }
.ap-calc-note { font-size: 13px; color: #9CA3AF; margin-top: 16px; line-height: 1.6; }

@media (max-width: 480px) {
    .ap-calc { padding: 28px 24px; }
    .ap-calc-tiles { grid-template-columns: 1fr; }
}

/* ---- Who joins ---- */
.ap-who-section { padding: 0 0 96px; }
.ap-who {
    background: #F4F5F7;
    border-radius: 28px;
    padding: 48px 56px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    align-items: center;
}
.ap-who-chips { display: flex; flex-wrap: wrap; gap: 10px; }

@media (max-width: 576px) {
    .ap-who { padding: 32px 24px; }
    .ap-hero { padding: 56px 0 72px; }
    .ap-steps-section, .ap-rates-section { padding: 64px 0; }
}

/* ---- Contact strip ---- */
.ap-contact { border-top: 1px solid #E5E7EB; padding: 32px 0; }
.ap-contact-inner {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 16px;
    font-size: 13px;
    color: #9CA3AF;
}
.ap-contact-inner a { color: #6B7280; }
