/* Agent referrals: a shared, static section that stays readable at every size. */
.agent-referrals {
  padding: clamp(3.5rem, 7vw, 7rem) clamp(1.25rem, 6vw, 7rem);
  color: #171510;
  background: #f4f0eb;
  border-top: 1px solid rgb(23 21 16 / 18%);
  scroll-margin-top: 6rem;
}

.referral-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
  gap: clamp(2rem, 6vw, 6rem);
  max-width: 100rem;
  margin: 0 auto;
  align-items: center;
}

.referral-eyebrow {
  margin: 0 0 1.5rem;
  color: #795a3d;
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.16em;
  line-height: 1.5;
  text-transform: uppercase;
}

.referral-copy h2 {
  margin: 0;
  font-size: clamp(2.3rem, 4.6vw, 5.25rem);
  font-weight: 650;
  letter-spacing: -0.065em;
  line-height: 0.98;
}

.referral-copy h2 span,
.referral-copy h2 em {
  display: block;
}

.referral-copy h2 em {
  margin-top: 0.08em;
  color: #795a3d;
  font-weight: 450;
}

.referral-description {
  max-width: 37rem;
  margin: 1.5rem 0 0;
  color: #575149;
  font-size: clamp(1rem, 1.25vw, 1.15rem);
  line-height: 1.65;
}

.referral-link {
  display: inline-flex;
  min-height: 3rem;
  max-width: 100%;
  margin-top: 1.5rem;
  padding: 0.85rem 0;
  align-items: center;
  gap: 1.25rem;
  border-bottom: 1px solid #795a3d;
  font-weight: 700;
  line-height: 1.4;
}

.referral-link:hover {
  color: #795a3d;
}

.referral-link:focus-visible {
  outline: 2px solid #795a3d;
  outline-offset: 5px;
}

.referral-rate {
  padding: clamp(1.5rem, 4vw, 3.5rem);
  color: #f4f0eb;
  background: #171510;
  border-top: 3px solid #ad8f6e;
}

.referral-rate strong {
  display: block;
  color: #c6a887;
  font-size: clamp(5.5rem, 11vw, 10rem);
  font-weight: 550;
  letter-spacing: -0.075em;
  line-height: 1;
}

.referral-rate p {
  max-width: 22rem;
  margin: 1rem 0 0;
  font-size: clamp(1.15rem, 2vw, 1.6rem);
  font-weight: 550;
  line-height: 1.35;
}

.referral-rate small {
  display: block;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgb(244 240 235 / 25%);
  color: #d3cbc0;
  font-size: 0.9rem;
  line-height: 1.6;
}

.referral-details {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
  max-width: 100rem;
  margin: clamp(2rem, 4vw, 4rem) auto 0;
  padding-top: 2rem;
  border-top: 1px solid rgb(23 21 16 / 18%);
}

.referral-details h3 {
  margin: 0 0 0.75rem;
  font-size: 1.15rem;
  letter-spacing: -0.025em;
}

.referral-details p {
  max-width: 36rem;
  margin: 0;
  color: #575149;
  line-height: 1.65;
}

@media (max-width: 900px) {
  .agent-referrals {
    /* mobile.css already offsets anchors below the fixed navigation. */
    scroll-margin-top: 0;
  }
}

@media (max-width: 700px) {
  .referral-layout,
  .referral-details {
    grid-template-columns: minmax(0, 1fr);
  }

  .referral-rate strong {
    font-size: clamp(5.5rem, 22vw, 8rem);
  }
}
