/*
 * Standalone pages (affiliate registration, 404): same hero + panel look as the checkout.
 * The checkout keeps its own copy inline in woocommerce/checkout/form-checkout.php; values mirror it.
 * Loaded only by page-affiliate-registration.php and 404.php.
 */

.gfp-page {
  padding: 0 0 80px;
}

/* Hero — mirrors .checkout-hero-header / -title / -subtitle */
.gfp-hero {
  text-align: center;
  padding: 40px 20px 36px;
}
.gfp-hero-title {
  font-family: var(--title-font);
  font-size: clamp(40px, 8vw, 72px);
  font-weight: 900;
  color: var(--title-color);
  text-transform: uppercase;
  line-height: 1;
  letter-spacing: -0.02em;
  margin: 0 0 12px;
}
.gfp-hero-subtitle {
  font-size: 18px;
  line-height: 1.5;
  color: rgba(255, 255, 255, 0.85);
  max-width: 560px;
  margin: 0 auto;
}

/* Link to the sibling page (login <-> registration), above the card: yellow outline so it reads before the form */
.gfp-hero-switch {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 12px 16px;
  margin: 28px 0 0;
  font-size: 16px;
  color: rgba(255, 255, 255, 0.85);
}
.gfp-hero-switch .gfp-btn {
  padding: 14px 28px;
  border-color: var(--theme-color);
  color: var(--theme-color);
}
.gfp-hero-switch .gfp-btn:hover {
  background: var(--theme-color);
  color: var(--black-color);
}

/* Panel + card — mirrors .checkout-content / .single-checkout-widget */
.gfp-panel {
  max-width: 912px;
  margin: 0 auto;
  background: #101010;
  border-radius: 24px;
  padding: 16px;
}
.gfp-panel--narrow {
  max-width: 560px;
}
.gfp-card {
  background: #151515;
  border: 1px solid #222;
  border-radius: 20px;
  padding: 30px;
}

/* Affiliate registration form: two short fields per row, long ones full width */
.gfp-page .affwp-register-form fieldset {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 20px;
}
/* :last-of-type beats the theme's "last field has no margin": Turnstile and the button follow it */
.gfp-page .affwp-register-form fieldset > p,
.gfp-page .affwp-register-form fieldset > p:last-of-type {
  margin: 0 0 24px;
}
.gfp-card form {
  margin: 0;
}
.gfp-card form > :last-child {
  margin-bottom: 0;
}
.gfp-page .affwp-register-form fieldset > p:has(textarea),
.gfp-page .affwp-register-form fieldset > p:has(#affwp-user-url),
.gfp-page .affwp-register-form fieldset > p:has(input[type="checkbox"]),
.gfp-page .affwp-register-form fieldset > p:has(input[type="submit"]),
.gfp-page .affwp-register-form fieldset > :not(p):not(legend) {
  grid-column: 1 / -1;
}
.gfp-page .affwp-register-form textarea {
  min-height: 140px;
}
.gfp-page .affwp-form .cf-turnstile {
  margin: 0 0 24px;
  min-height: 65px;
}
.gfp-page .affwp-form input[type="submit"] {
  width: 100%;
}

/* Login form: single column, "Lost your password?" centred under the button */
.gfp-page .affwp-login-form fieldset > p,
.gfp-page .affwp-login-form fieldset > p:last-of-type {
  margin: 0 0 24px;
}
.gfp-page .affwp-login-form .affwp-lost-password {
  text-align: center;
  margin: 16px 0 0;
}

/* Dashboard: logged-in affiliates; guests see AffiliateWP's "unauthorized" notice here */
.gfp-page--dashboard {
  padding-top: 40px;
}
.gfp-page .affwp-errors,
.gfp-page .affwp-notice {
  margin: 0 0 24px;
}

/* 404 */
.gfp-404-code {
  font-family: var(--title-font);
  font-size: clamp(96px, 18vw, 180px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--theme-color);
  margin: 0 0 8px;
}
.gfp-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 32px;
}
.gfp-btn {
  display: inline-block;
  padding: 18px 32px;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 500;
  text-transform: uppercase;
  text-decoration: none;
  line-height: 1;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
}
.gfp-btn--primary {
  background: var(--theme-color);
  color: var(--black-color);
}
.gfp-btn--primary:hover {
  background: var(--title-color);
  color: var(--black-color);
}
.gfp-btn--ghost {
  background: #1a1a1a;
  border: 1px solid #333;
  color: var(--title-color);
}
.gfp-btn--ghost:hover {
  border-color: var(--theme-color);
  color: var(--theme-color);
}

@media (max-width: 767px) {
  .gfp-hero {
    padding: 28px 0 24px;
  }
  .gfp-hero-subtitle {
    font-size: 16px;
  }
  .gfp-panel {
    padding: 8px;
    border-radius: 18px;
  }
  .gfp-card {
    padding: 20px;
    border-radius: 14px;
  }
  .gfp-page .affwp-register-form fieldset {
    grid-template-columns: minmax(0, 1fr);
  }
  .gfp-btn {
    width: 100%;
    text-align: center;
  }
}
