/* ==========================================================================
   /refer/ - referrals from healthcare professionals.

   Own class names throughout (refer-*), loaded after the shared sheets from
   {% block extra_head %}, so nothing here joins the argument style.css already
   has with itself over .content-card and friends. The form rules mirror the
   contact page's, which are inline in contact.html and so cannot be shared.
   ========================================================================== */

.refer-section { padding: 4.5rem 0; background: #fff; }
.refer-section--alt { background: var(--light-bg, #FAF9F7); }

.refer-eyebrow {
  color: var(--primary-color);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
}
.refer-h2 {
  font-family: var(--font-heading);
  font-size: 2.1rem;
  font-weight: 600;
  color: #2C2C3A;
  margin-bottom: 1rem;
}
.refer-lead { color: #5A5A6E; font-size: 1.08rem; line-height: 1.8; }

/* ── The phone strip: the one thing a busy GP should not have to look for ── */
.refer-phone-strip {
  background: var(--primary-color);
  color: #fff;
  padding: 1.75rem 0;
}
.refer-phone-strip__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.75rem 2rem;
  text-align: center;
}
.refer-phone-strip__label { font-size: 1.05rem; margin: 0; color: #fff; }
.refer-phone-strip__number {
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
  text-decoration: none;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.refer-phone-strip__number:hover,
.refer-phone-strip__number:focus-visible { color: var(--brand-gold-light, #E0B978); }
/* Target the <i> itself: style.css colours every bare i teal, which on this
   teal strip is nothing at all. */
.refer-phone-strip i { color: var(--brand-gold-light, #E0B978); margin-right: 0.5rem; }
.refer-phone-strip__hours { font-size: 0.95rem; margin: 0; color: rgba(255,255,255,0.88); }

/* ── Who the page is for ── */
.refer-audience {
  list-style: none;
  padding: 0;
  margin: 1.5rem 0 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}
.refer-audience li {
  background: #fff;
  border: 1px solid rgba(0,109,119,0.25);
  border-radius: 999px;
  padding: 0.45rem 1.1rem;
  color: #004E57;
  font-weight: 600;
  font-size: 0.95rem;
}

/* ── Nurse-led and regulated ── */
.refer-credentials {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-top: 2rem;
}
.refer-credential {
  background: #fff;
  border-radius: 14px;
  border-top: 3px solid var(--brand-gold, #C09041);
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
  padding: 1.5rem;
}
.refer-credential__title {
  font-family: var(--font-heading);
  font-size: 1.35rem;
  font-weight: 600;
  color: #004E57;
  margin-bottom: 0.4rem;
}
.refer-credential p { color: #5A5A6E; margin: 0; line-height: 1.65; }

/* ── Services ── */
/* A fixed column count, not auto-fit: six cards auto-fitted at desktop width
   came out as a row of five and one left on its own. */
.refer-services {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-top: 2rem;
}
.refer-service {
  background: #fff;
  border-radius: 14px;
  border: 1px solid #edf2ef;
  padding: 1.6rem 1.4rem;
  display: flex;
  flex-direction: column;
}
.refer-service__icon {
  width: 52px; height: 52px;
  border-radius: 50%;
  background: rgba(0,109,119,0.08);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1rem;
}
.refer-service__icon i { color: var(--primary-color); font-size: 1.3rem; }
.refer-service__title {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  font-weight: 600;
  color: #2C2C3A;
  margin-bottom: 0.5rem;
}
.refer-service p { color: #5A5A6E; line-height: 1.65; flex: 1; }
.refer-service a { color: #004E57; font-weight: 600; }

/* ── How to refer ── */
.refer-steps {
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1.25rem;
  counter-reset: refer-step;
}
.refer-step {
  counter-increment: refer-step;
  background: #fff;
  border-radius: 14px;
  padding: 1.6rem 1.4rem 1.4rem;
  box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}
.refer-step::before {
  content: counter(refer-step);
  display: inline-flex;
  align-items: center; justify-content: center;
  width: 2.2rem; height: 2.2rem;
  border-radius: 50%;
  background: var(--primary-color);
  color: #fff;
  font-weight: 700;
  margin-bottom: 0.8rem;
}
.refer-step__title { font-weight: 700; color: #2C2C3A; margin-bottom: 0.35rem; font-size: 1.1rem; }
.refer-step p { color: #5A5A6E; margin: 0; line-height: 1.65; }

/* ── Contact panel beside the form ── */
.refer-contact {
  background: #004E57;
  color: #fff;
  border-radius: 16px;
  padding: 2rem 1.75rem;
  height: 100%;
}
.refer-contact__title {
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 600;
  color: #fff;
  margin-bottom: 1.25rem;
}
.refer-contact ul { list-style: none; padding: 0; margin: 0; }
.refer-contact li { display: flex; gap: 0.75rem; margin-bottom: 1.1rem; line-height: 1.55; }
.refer-contact li i { color: var(--brand-gold-light, #E0B978); margin-top: 0.25rem; width: 1.1rem; flex-shrink: 0; }
.refer-contact a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.refer-contact a:hover, .refer-contact a:focus-visible { color: var(--brand-gold-light, #E0B978); }
.refer-contact__note { font-size: 0.9rem; color: rgba(255,255,255,0.85); margin: 1.5rem 0 0; }

/* ── Form ── */
.refer-form {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 30px rgba(0,0,0,0.08);
  padding: 2.25rem 2rem;
  border: 1px solid #edf2ef;
}
.refer-form__title { color: #004E57; font-size: 1.5rem; font-weight: 700; margin-bottom: 0.4rem; }
.refer-form__subtitle { color: #495057; font-size: 1.05rem; line-height: 1.6; margin-bottom: 1rem; }
.refer-form__privacy {
  display: flex;
  gap: 0.6rem;
  background: #fff8e1;
  border: 1px solid #ffc107;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: #664d03;
  line-height: 1.5;
  margin-bottom: 0.5rem;
}
.refer-form__privacy i { color: #664d03; margin-top: 0.2rem; }
.refer-form__label {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #006D77;
  font-weight: 700;
  margin: 1.5rem 0 0.75rem;
  padding-bottom: 0.35rem;
  border-bottom: 2px solid rgba(0,109,119,0.2);
  display: block;
}
.refer-form label {
  font-size: 1rem;
  font-weight: 600;
  color: #212529;
  margin-bottom: 0.3rem;
  display: block;
}
.refer-form input[type=text],
.refer-form input[type=email],
.refer-form select,
.refer-form textarea {
  border: 1px solid #adb5bd;
  border-radius: 8px;
  padding: 0.625rem 0.9rem;
  font-size: 16px;
  width: 100%;
  background: #fafafa;
  min-height: 44px;
  color: #212529;
  display: block;
}
.refer-form input:focus,
.refer-form select:focus,
.refer-form textarea:focus {
  border-color: #006D77;
  box-shadow: 0 0 0 3px rgba(0,109,119,0.2);
  outline: none;
  background: #fff;
}
.refer-form textarea,
.refer-form textarea.form-control { height: auto; min-height: 120px; resize: vertical; }
.refer-form__consent {
  background: #f0f9f4;
  border: 1px solid #c3e6cb;
  border-radius: 8px;
  padding: 0.875rem 1rem;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  color: #155724;
  margin-top: 1.25rem;
  line-height: 1.6;
}
.refer-form__consent input[type=checkbox] {
  width: 20px; height: 20px;
  flex-shrink: 0; margin-top: 2px;
  accent-color: #0f5132;
}
.refer-form__submit {
  background: linear-gradient(135deg, #006D77, #004E57);
  color: #fff;
  border: none;
  border-radius: 50px;
  padding: 0.875rem 2rem;
  font-size: 1.05rem;
  font-weight: 600;
  width: 100%;
  min-height: 48px;
  margin-top: 1.25rem;
}
.refer-form__submit:hover { box-shadow: 0 8px 25px rgba(0,109,119,0.32); color: #fff; }
.refer-form__submit i { color: #fff; }

@media (max-width: 991.98px) { .refer-services { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 575.98px) {
  .refer-services { grid-template-columns: 1fr; }
  .refer-section { padding: 3rem 0; }
  .refer-phone-strip__number { font-size: 1.6rem; }
  .refer-form { padding: 1.5rem 1.1rem; }
}
