/* =========================================================
   RETAINERSHIP PAGE
   Values copied from the "Retainership" frame in Figma (1512 × 5212).
   Loaded after styles.css, so the header, buttons, footer and
   design tokens are shared with the homepage. Every class here
   starts with "rt-" so nothing on other pages is affected.
   ========================================================= */
:root {
  --rt-hero-bg: #0e4759;          /* hero card */
  --rt-purple: #aa00ff;           /* Family Plan */
  --rt-purple-light: #f3daff;
  --rt-teal: #0a5b75;             /* end of the Corporate gradient */
  --rt-muted: #787f82;            /* sign-up intro text */
  --rt-fade: #cef1fc;             /* soft edge over the dentist photo */
}

/* ---------- HERO (Figma: 1417 × 438, radius 30, navy) ---------- */
.rt-hero {
  position: relative;
  min-height: 438px;
  overflow: hidden;
  border-radius: var(--radius-card);
  background: var(--rt-hero-bg);
  color: var(--color-white);
}
.rt-hero-text {
  position: relative;
  z-index: 1;
  max-width: calc(131px + 683px);
  padding: 88px 0 64px 131px;
}
.rt-hero h1 {
  margin: 0;
  max-width: 677px;
  font-size: 64px;
  font-weight: 600;
  line-height: var(--lh);
}
.rt-hero-light { font-weight: 400; }
.rt-hero p {
  margin: 19px 0 0;
  font-size: 24px;
  font-weight: 500;
  line-height: var(--lh);
}
/* Poster sits on the hero's bottom edge, cut off exactly as in Figma */
.rt-poster {
  position: absolute;
  right: 99px;
  bottom: 0;
  width: 360.5px;
  height: 408px;
}
/* The two gold coins are stretched to their Figma box sizes, like the design */
.rt-hero-coin { position: absolute; max-width: none; pointer-events: none; }
.rt-hero-coin--left { left: -90px; top: 305px; width: 230px; height: 231px; }
.rt-hero-coin--top { left: 51.1%; top: -115px; width: 193px; height: 195px; }

/* ---------- PLAN HEADINGS (36px SemiBold + pills) ---------- */
.rt-plan { margin-top: 98px; }
.rt-plan-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 26px;
}
.rt-plan-head h2 {
  margin: 0;
  font-size: 36px;
  font-weight: 600;
  line-height: var(--lh);
  color: var(--color-text);
}
.rt-pill {
  display: inline-flex;
  align-items: center;
  height: 50px;
  padding: 0 30px;
  border-radius: var(--radius-pill);
  font-size: 16px;
  font-weight: 600;
  line-height: var(--lh);
  white-space: nowrap;
  color: var(--color-white);
}
.rt-pill--blue { background: var(--color-primary); }
.rt-pill--purple { background: var(--rt-purple); }
.rt-pill--navy { background: var(--color-navy); }
.rt-pill--gradient { background: linear-gradient(103.44deg, var(--color-primary) 4.426%, var(--rt-purple) 119.18%); }
.rt-pill--outline { border: 1px solid var(--color-text); color: var(--color-text); }
.rt-pill-medium { margin-left: 0.25em; font-weight: 500; }

/* ---------- PLAN CARDS (Figma: 1416 × 558, radius 30) ---------- */
.rt-card {
  position: relative;
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 558px;
  margin-top: 40px;
  padding-top: 55px;
  overflow: hidden;
  border-radius: var(--radius-card);
  color: var(--color-white);
}
.rt-card--blue { background: var(--gradient-blue); }
.rt-card--purple { background: linear-gradient(to bottom, var(--rt-purple), var(--rt-purple-light)); }
.rt-card--navy { background: linear-gradient(to bottom, var(--color-navy), var(--rt-teal)); }
.rt-card--school { grid-template-columns: 1fr; background: linear-gradient(147.17deg, var(--color-primary) 27.779%, var(--rt-purple) 100.73%); }

/* Thin white divider down the middle (Figma: Line 168, 366px tall) */
.rt-card:not(.rt-card--school)::before {
  content: "";
  position: absolute;
  left: calc(50% - 0.63px);
  top: 59px;
  width: 1.26px;
  height: 366px;
  background: var(--color-white);
}

.rt-col { position: relative; z-index: 1; padding: 0 24px 64px 84px; }
.rt-tier {
  margin: 0;
  font-size: 42px;
  font-weight: 500;
  line-height: var(--lh);
}
.rt-tier--regular { font-weight: 400; }
.rt-price {
  margin: 12px 0 0;
  font-size: 68px;
  font-weight: 600;
  line-height: var(--lh);
}
.rt-note {
  margin: 5px 0 0;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.72px;
}

/* Benefit lists: 24px Medium, 36px lines, a sparkle before each line.
   The sparkle comes from Figma's bullet column (Group 513119); only its
   first sparkle is shown, so long lines can wrap and stay aligned. */
.rt-list {
  margin: 41px 0 0;
  padding: 0;
  list-style: none;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.5;
  letter-spacing: -0.72px;
}
.rt-note + .rt-list { margin-top: 26px; }
.rt-card--school .rt-note + .rt-list { margin-top: 42px; }
.rt-list li { position: relative; padding-left: 32px; white-space: nowrap; }
.rt-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 4.85px;
  width: 17.37px;
  height: 21.58px;
  background: url("assets/sparkles-soft.svg") 0 0 / 17.3683px 133.247px no-repeat;
}
.rt-list--light li::before {
  background-image: url("assets/sparkles-light.svg");
  background-size: 17.8026px 169.931px;
}
.rt-list strong { font-weight: 700; }
/* Family Premium text box is 539px wide in Figma, so its last line wraps */
.rt-list--wrap { max-width: 571px; }
.rt-list--wrap li { white-space: normal; }

/* Gold coin peeking up from the bottom (same crop as the homepage cards) */
.rt-coin {
  position: absolute;
  left: calc(50% + 1px);
  top: 425px;
  width: 426px;
  height: 429px;
  overflow: hidden;
  transform: translateX(-50%);
  pointer-events: none;
}
.rt-coin img {
  position: absolute;
  left: -78.5%;
  top: -34.39%;
  width: 257.73%;
  max-width: none;
  height: 170.42%;
}
.rt-coin--large { left: calc(50% + 317px); top: 206px; width: 634px; height: 639px; }

/* ---------- SIMPLE STEPS ---------- */
.rt-steps {
  display: grid;
  grid-template-columns: 1fr 831px;
  margin-top: 98px;
}
.rt-steps h2 {
  margin: 0;
  font-size: 36px;
  font-weight: 600;
  line-height: var(--lh);
  color: var(--color-text);
}
.rt-steps-lead {
  margin: 12px 0 0;
  font-size: 18px;
  font-weight: 500;
  line-height: var(--lh);
}
.rt-step-list { margin: 31px 0 0; padding: 0; list-style: none; }
.rt-step {
  position: relative;
  display: flex;
  align-items: center;
  gap: 19px;
}
.rt-step + .rt-step { margin-top: 91px; }
/* Grey connector line between the circles (Figma: Line 164/165, 75px) */
.rt-step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 41.5px;
  top: calc(100% + 8px);
  width: 1px;
  height: 75px;
  background: var(--color-text);
}
.rt-step-icon {
  display: flex;
  flex: none;
  align-items: center;
  justify-content: center;
  width: 84px;
  height: 84px;
  border: 1px solid rgba(63, 71, 74, 0.7);
  border-radius: 42px;
  font-size: 40px;
  line-height: 1;
  color: #000;
}
.rt-step div { flex: 0 1 342px; min-width: 0; }
.rt-step h3 {
  margin: 0;
  font-size: 24px;
  font-weight: 600;
  line-height: var(--lh);
  color: var(--color-navy);
}
.rt-step p {
  margin: 8px 0 0;
  font-size: 16px;
  font-weight: 500;
  line-height: var(--lh);
}
.rt-steps-photo {
  width: 831px;
  height: 543px;
  object-fit: cover;
  border-radius: var(--radius-card);
}

/* ---------- SIGN-UP CARD + DENTIST PHOTO ---------- */
.rt-signup {
  position: relative;
  margin-top: 63px;           /* photo top; the card starts 47px lower */
  padding-top: 47px;
}
.rt-signup-card {
  min-height: 464px;
  overflow: hidden;
  border-radius: var(--radius-card);
  background: linear-gradient(to right, var(--color-card-grey), var(--color-blue-light));
}
.rt-signup-copy {
  position: relative;
  z-index: 2;
  max-width: calc(80px + 471px);
  padding: 54px 0 62px 80px;
}
.rt-signup-kicker {
  margin: 0;
  font-size: 16px;
  font-weight: 500;
  line-height: var(--lh);
}
.rt-signup h2 {
  margin: 16px 0 0;
  font-size: 32px;
  font-weight: 600;
  line-height: var(--lh);
  white-space: nowrap;
}
.rt-signup-intro {
  margin: 16px 0 0;
  max-width: 471px;
  font-size: 16px;
  font-weight: 500;
  line-height: var(--lh);
  color: var(--rt-muted);
}
.rt-form { display: flex; flex-direction: column; align-items: flex-start; margin-top: 16px; }
.rt-form input {
  width: 465px;
  max-width: 100%;
  height: 50px;
  padding: 0 18px;
  border: 0;
  border-radius: 10px;
  background: var(--color-white);
  font: 500 14px/var(--lh) var(--font-main);
  color: var(--color-text);
}
.rt-form label + input:not(:nth-child(2)) { margin-top: 16px; }
.rt-form input::placeholder { color: rgba(120, 127, 130, 0.5); }
.rt-form input:focus-visible { outline: 2px solid var(--color-primary); outline-offset: 1px; }
.rt-form button {
  margin-top: 35px;
  padding: 15px 30px;
  border: 0;
  border-radius: 10px;
  background: var(--color-primary);
  font: 600 16px/var(--lh) var(--font-main);
  color: var(--color-white);
  cursor: pointer;
  transition: filter 0.2s ease;
}
.rt-form button:hover { filter: brightness(1.08); }

/* Cut-out photo overlaps the top of the card; a soft fade blends its left edge */
.rt-signup-photo {
  position: absolute;
  right: 0;
  bottom: 0;
  width: min(525px, 44%);
  aspect-ratio: 525 / 511;
}
.rt-signup-photo img {
  width: 100%;
  height: 100%;
  border-bottom-right-radius: var(--radius-card);
}
.rt-signup-photo::after {
  content: "";
  position: absolute;
  left: -12%;               /* Figma: 63px left of the photo */
  top: 19.77%;              /* 101px below its top */
  width: 61.9%;             /* 325px */
  height: 81.02%;           /* 414px (ends 4px below the card, as in Figma) */
  background: linear-gradient(to right, var(--rt-fade) 40.615%, rgba(206, 241, 252, 0) 95.238%);
  pointer-events: none;
}

/* Footer sits 67px below the sign-up card on this page */
.page-retainership .site-footer { margin-top: 67px; }


/* =========================================================
   LAPTOP (up to 1400px)
   ========================================================= */
@media (max-width: 1400px) {
  .rt-hero-text { max-width: calc(100% - 360px - 99px - 32px); padding-left: 8.5%; }
  .rt-hero h1 { font-size: clamp(48px, 4.6vw, 64px); }
  .rt-hero p { font-size: 22px; }
  .rt-hero-coin--left { left: -130px; }

  .rt-col { padding-left: 6%; }
  .rt-list, .rt-note { font-size: 21px; }
  .rt-list li::before { top: 3px; }
  .rt-tier { font-size: 38px; }
  .rt-price { font-size: 60px; }

  .rt-steps { grid-template-columns: minmax(0, 1fr) 55%; gap: 32px; }
  .rt-steps-photo { width: 100%; height: auto; aspect-ratio: 831 / 543; }
}

@media (max-width: 1240px) {
  .rt-poster { right: 48px; }
  .rt-hero-coin--left { left: -160px; }
  .rt-hero-text { max-width: calc(100% - 360px - 48px - 24px); padding-left: 56px; }
  .rt-list, .rt-note { font-size: 19px; }
  .rt-list li { white-space: normal; }
  .rt-signup-copy { padding-left: 56px; max-width: 56%; }
  .rt-signup h2 { white-space: normal; }
  .rt-steps { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
}


/* =========================================================
   TABLET (up to 1080px): everything stacks into one column
   ========================================================= */
@media (max-width: 1080px) {
  /* Hero: text first, poster below it, still cut off by the hero's bottom edge */
  .rt-hero { display: flex; flex-direction: column; align-items: center; min-height: 0; }
  .rt-hero-text { max-width: none; padding: 56px 40px 0; align-self: stretch; }
  .rt-hero h1 { font-size: 52px; max-width: 620px; }
  .rt-hero p { font-size: 20px; max-width: 640px; }
  .rt-poster { position: relative; right: auto; margin-top: 40px; }
  .rt-hero-coin--left { top: auto; bottom: 40px; }
  .rt-hero-coin--top { left: auto; right: -40px; }

  .rt-plan { margin-top: 72px; }
  .rt-plan-head h2 { font-size: 32px; }
  .rt-card { grid-template-columns: 1fr; min-height: 0; margin-top: 28px; padding: 44px 0 170px; }
  .rt-card:not(.rt-card--school)::before { display: none; }
  .rt-col { padding: 0 40px; }
  /* Premium gets a thin white line above it instead of the middle divider */
  .rt-col + .rt-col { margin-top: 40px; padding-top: 40px; }
  .rt-col + .rt-col::before {
    content: "";
    position: absolute;
    left: 40px;
    right: 40px;
    top: 0;
    height: 1.26px;
    background: var(--color-white);
  }
  .rt-list, .rt-note { font-size: 20px; }
  .rt-list { margin-top: 28px; }
  .rt-coin { top: auto; bottom: -206px; width: 340px; height: 343px; }
  .rt-card--school { padding-bottom: 260px; }
  .rt-coin--large { left: auto; right: -60px; bottom: -150px; transform: none; width: 420px; height: 423px; }

  .rt-steps { grid-template-columns: 1fr; gap: 40px; margin-top: 72px; }

  .rt-signup { margin-top: 48px; }
  .rt-signup-copy { padding: 44px 40px 48px; max-width: 58%; }
  .rt-form input { width: 100%; }
  /* On narrower cards the fade's edge would show against the lighter gradient,
     so the photo fades its own left edge instead */
  .rt-signup-photo img {
    -webkit-mask-image: linear-gradient(to right, transparent 0%, #000 40%);
    mask-image: linear-gradient(to right, transparent 0%, #000 40%);
  }
  .rt-signup-photo::after { display: none; }
  .page-retainership .site-footer { margin-top: 56px; }
}


/* =========================================================
   PHONE (up to 640px)
   ========================================================= */
@media (max-width: 640px) {
  .rt-hero { border-radius: 20px; }
  .rt-hero-text { padding: 40px 24px 0; }
  .rt-hero h1 { font-size: 38px; }
  .rt-hero p { font-size: 17px; margin-top: 16px; }
  .rt-poster { width: min(300px, 82%); height: auto; margin-top: 32px; }
  .rt-hero-coin--left { width: 140px; height: 141px; left: -70px; bottom: 24px; }
  .rt-hero-coin--top { width: 120px; height: 121px; top: -70px; right: -30px; }

  .rt-plan { margin-top: 56px; }
  .rt-plan-head { gap: 12px; }
  .rt-plan-head h2 { flex-basis: 100%; font-size: 28px; }
  .rt-pill { height: 42px; padding: 0 20px; font-size: 14px; }

  .rt-card { border-radius: 20px; padding: 36px 0 120px; }
  .rt-col { padding: 0 24px; }
  .rt-col + .rt-col::before { left: 24px; right: 24px; }
  .rt-tier { font-size: 30px; }
  .rt-price { font-size: 44px; margin-top: 6px; }
  .rt-list, .rt-note { font-size: 17px; letter-spacing: -0.4px; }
  .rt-list { margin-top: 22px; }
  .rt-note + .rt-list, .rt-card--school .rt-note + .rt-list { margin-top: 18px; }
  .rt-list li { padding-left: 28px; }
  .rt-list li + li { margin-top: 4px; }
  .rt-list li::before { top: 2px; }
  .rt-coin { width: 240px; height: 242px; bottom: -150px; }
  .rt-card--school { padding-bottom: 190px; }
  .rt-coin--large { width: 300px; height: 302px; right: -50px; bottom: -110px; }

  .rt-steps { margin-top: 56px; }
  .rt-steps h2 { font-size: 30px; }
  .rt-steps-lead { font-size: 16px; }
  .rt-step { align-items: flex-start; gap: 16px; }
  .rt-step + .rt-step { margin-top: 56px; }
  .rt-step-icon { width: 64px; height: 64px; font-size: 30px; }
  .rt-step:not(:last-child)::after { left: 31.5px; top: calc(100% + 8px); height: 40px; }
  .rt-step h3 { font-size: 20px; }
  .rt-steps-photo { border-radius: 20px; }

  /* Sign-up: form on top, the dentist photo sits along the bottom of the card */
  .rt-signup { --photo-w: min(330px, 86%); margin-top: 40px; padding-top: 0; }
  .rt-signup-card { border-radius: 20px; padding-bottom: calc(var(--photo-w) * 511 / 525 + 8px); }
  .rt-signup-copy { max-width: none; padding: 36px 24px 0; }
  .rt-signup h2 { font-size: 26px; }
  .rt-form button { margin-top: 24px; }
  .rt-signup-photo { width: var(--photo-w); }
  .rt-signup-photo img { border-bottom-right-radius: 20px; }
  .page-retainership .site-footer { margin-top: 48px; }
}
