/* ================================================
   Homepage — index.css
   All values via tokens.css; no hardcoded colours
   that duplicate a token.
================================================ */

/* ── RESET & BASE ── */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-base);
  color: var(--clr-ink);
  background: var(--bg-page);
  line-height: 1.7;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: var(--clr-teal); }
a:hover { text-decoration: underline; color: var(--clr-teal-dark); }
h1, h2, h3, h4 { font-family: var(--font-head); line-height: 1.2; margin: 0; }
p { margin: 0; }
ul { list-style: none; margin: 0; padding: 0; }

/* ── SKIP LINK ── */
.skip-link {
  position: absolute; left: -9999px; top: auto;
  width: 1px; height: 1px; overflow: hidden;
}
.skip-link:focus {
  position: fixed; top: 0; left: 0; width: auto; height: auto;
  padding: 8px 16px; background: var(--clr-teal); color: var(--clr-white);
  font-family: var(--font-head); font-size: 14px; font-weight: 700; z-index: 9999;
}

/* ── CONTAINER ── */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

/* ── BUTTONS ── */
.btn {
  display: inline-block;
  font-family: var(--font-head);
  font-weight: 800;
  font-size: 14px;
  letter-spacing: 0.04em;
  padding: var(--pad-btn);
  border-radius: var(--radius-lg);
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.1s;
  text-decoration: none;
  line-height: 1;
}
.btn:hover { transform: translateY(-1px); text-decoration: none; }

.btn--primary  { background: var(--clr-teal);  border-color: var(--clr-teal);  color: var(--clr-white); }
.btn--primary:hover { background: var(--clr-teal-dark); border-color: var(--clr-teal-dark); color: var(--clr-white); }

.btn--outline  { background: transparent; border-color: var(--clr-teal); color: var(--clr-teal-dark); }
.btn--outline:hover { background: var(--clr-teal); color: var(--clr-white); }

.btn--outline-light { background: var(--clr-blue); border-color: var(--clr-white); color: var(--text-on-dark); }
.btn--outline-light:hover { background: var(--overlay-white-md); border-color: var(--clr-white); color: var(--text-on-dark); }

.btn--light { background: var(--clr-blue); border-color: var(--clr-white); color: var(--text-on-dark); box-shadow: var(--shadow-btn); }
.btn--light:hover { background: var(--clr-white); border-color: var(--clr-white); color: var(--clr-teal-dark); box-shadow: var(--shadow-btn-hover); }

.btn--submit {
  background: var(--clr-blue); border-color: var(--clr-blue); color: var(--clr-white);
  width: 100%; font-size: 15px; padding: 14px 28px;
}
.btn--submit:hover { background: var(--clr-blue-dark); border-color: var(--clr-blue-dark); color: var(--clr-white); }

.btn--large { padding: 16px 36px; font-size: 16px; }

/* ================================================
   HERO   bg: var(--clr-teal) brand teal
================================================ */
.hero {
  background: var(--clr-teal);
  padding: var(--section-pad) 0 calc(var(--section-pad) - 20px);
  position: relative; overflow: hidden;
}
.hero::before {
  content: ''; position: absolute; top: -60px; right: -80px;
  width: 400px; height: 400px; border-radius: 50%;
  background: var(--overlay-white-sm); pointer-events: none;
}
.hero__inner {
  display: grid;
  grid-template-columns: 55fr 45fr;
  gap: var(--gap-split);
  align-items: center;
}
.hero__title {
  font-size: var(--text-h1); font-weight: var(--weight-h1);
  color: var(--clr-white); margin-bottom: 20px; line-height: 1.15;
}
.hero__sub {
  font-size: 17px; font-weight: 700;
  color: var(--text-on-teal-hi);
  line-height: 1.5; margin-bottom: 16px;
}
.hero__lead {
  font-size: 15px; color: var(--text-on-teal);
  line-height: 1.6; margin-bottom: 32px;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.trust-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--clr-teal); flex-shrink: 0; display: inline-block;
}
.hero__media img {
  width: 100%; height: auto;
  object-fit: contain;
  background: var(--clr-teal);
  border-radius: var(--radius-lg);
  display: block;
}

/* ================================================
   CTA FORM   bg: var(--bg-page) white
================================================ */
.cta-form {
  background: var(--bg-page);
  padding: var(--section-pad) 0;
}
.cta-form__inner {
  display: grid;
  grid-template-columns: 44fr 56fr;
  gap: var(--gap-split);
  align-items: center;
}
.cta-form__message {
  display: flex; flex-direction: column;
  text-align: left;
}
.cta-form__heading {
  font-size: clamp(24px, 3.2vw, 36px); font-weight: var(--weight-h2);
  color: var(--clr-ink); line-height: 1.2; margin-bottom: 14px;
}
.cta-form__brand-heading {
  font-family: var(--font-head);
  font-size: clamp(28px,3.6vw,40px); font-weight: 900;
  color: var(--clr-ink); line-height: 1.15; margin-bottom: 14px;
  max-width: 14ch;
}
.brand-color { color: var(--clr-teal); }
.cta-form__audience {
  font-size: var(--text-sm); color: var(--clr-ink);
  opacity: 0.6; margin-bottom: 32px; line-height: 1.6;
  max-width: 34ch;
}

.cta-form__callout {
  background: var(--bg-hero);
  border-radius: var(--radius-lg);
  border-left: 4px solid var(--clr-teal);
  padding: 32px 30px;
  margin-bottom: 20px;
}
.cta-form__diag-headline {
  font-family: var(--font-head);
  font-size: clamp(19px,2.3vw,24px); font-weight: 900;
  color: var(--clr-ink); line-height: 1.25; margin-bottom: 2px;
}
.cta-form__diag-sub {
  font-family: var(--font-head);
  font-size: clamp(19px,2.3vw,24px); font-weight: 900;
  color: var(--clr-teal); line-height: 1.25; margin-bottom: 16px;
}
.cta-form__callout-body {
  font-size: var(--text-sm); color: var(--clr-ink);
  opacity: 0.8; line-height: 1.75; margin-bottom: 24px;
}
.cta-form__callout .btn { width: fit-content; }

.cta-form__pills {
  list-style: none; margin: 0; padding: 0;
  display: flex; flex-wrap: nowrap; gap: 6px;
}
.cta-form__pills li {
  font-family: var(--font-head); font-size: 11.5px; font-weight: 800;
  text-align: center; white-space: nowrap;
  color: var(--clr-ink);
  background: var(--bg-section);
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 8px 12px;
}
.cta-form__pills li::before {
  content: "\2713";
  color: var(--clr-teal); font-weight: 900; margin-right: 5px;
}

.cta-form__card {
  background: var(--bg-section);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 40px 36px;
  box-shadow: var(--shadow);
  text-align: left;
}
.cta-form__card-title {
  font-size: var(--text-h3); font-weight: var(--weight-h3);
  color: var(--clr-ink); margin-bottom: 26px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--border);
}

/* Shared form field styles */
.form-row { display: grid; gap: 16px; }
.form-row--split   { grid-template-columns: 1fr 1fr; }
.form-row--70-30   { grid-template-columns: 2fr 1fr; }
.form-row--40-60   { grid-template-columns: 2fr 3fr; }
.form-field {
  display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px;
}
.form-field label {
  font-family: var(--font-head); font-size: var(--text-xs); font-weight: 700; color: var(--clr-ink);
}
.contact-form input,
.contact-form textarea,
.contact-form select {
  font-family: var(--font-body); font-size: var(--text-sm); color: var(--clr-ink);
  padding: 10px 12px; border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--bg-page); width: 100%; transition: border-color 0.2s;
}
.contact-form input:focus,
.contact-form textarea:focus { outline: none; border-color: var(--clr-teal); }
.form-field--checkbox label {
  display: flex; align-items: center; justify-content: flex-start;
  gap: 10px; cursor: pointer; font-weight: 400; opacity: 0.8;
}
.form-field--checkbox input[type="checkbox"] {
  width: auto; flex: 0 0 auto; margin: 0;
}
.form-field--checkbox { margin: 4px 0 20px; }
.btn--submit { width: 100%; }

/* ================================================
   SERVICES LIST   bg: var(--bg-section) teal-pale
================================================ */
.services-list {
  background: var(--bg-section);
  padding: var(--section-pad) 0;
}
.services-list__inner { text-align: center; }
.services-list__heading {
  font-size: var(--text-h2); font-weight: var(--weight-h2);
  color: var(--clr-ink); margin-bottom: 14px;
}
.services-list__intro {
  font-size: var(--text-sm);
  color: var(--clr-ink);
  opacity: 0.75;
  margin-bottom: 48px;
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.7;
}
.services-list__footer {
  font-size: var(--text-sm); color: var(--clr-ink); opacity: 0.55;
  margin-top: 40px; max-width: 600px;
  margin-left: auto; margin-right: auto; line-height: 1.65;
}

/* Six service cards — 3 columns, 2 even rows */
.services-list__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap-card);
  text-align: left;
}
.service-card {
  background: var(--bg-page);
  border-radius: var(--radius);
  padding: 28px 24px;
  box-shadow: var(--shadow);
  display: flex; flex-direction: column; gap: 12px;
  border-top: 3px solid var(--clr-teal);
  transition: transform 0.2s, box-shadow 0.2s;
}
.service-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.service-card__icon {
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--clr-teal-mid);
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}
.service-card__icon svg { width: 24px; height: 24px; stroke: var(--clr-teal); }
.service-card__name {
  font-family: var(--font-head); font-size: 15px; font-weight: 800;
  color: var(--clr-ink); margin: 0; line-height: 1.3;
}
.service-card__name a { color: var(--clr-ink); text-decoration: none; }
.service-card__name a:hover { color: var(--clr-teal); text-decoration: none; }
.service-card__desc {
  font-size: var(--text-xs); color: var(--clr-ink);
  opacity: 0.7; line-height: 1.6; flex: 1;
}

/* ================================================
   FAMILY SUPPORT   bg: var(--bg-hero) warm beige
================================================ */
.family-support {
  background: var(--bg-hero);
  padding: var(--section-pad) 0;
}
.family-support__inner {
  display: grid;
  grid-template-columns: 45fr 55fr;
  gap: var(--gap-split);
  align-items: center;
}
.family-support__media img {
  width: 100%; height: auto;
  aspect-ratio: 1 / 1;
  object-fit: contain;
  background: var(--bg-hero);
  border-radius: var(--radius-lg);
}
.family-support__heading {
  font-size: var(--text-h2); font-weight: var(--weight-h2);
  color: var(--clr-ink); margin-bottom: 16px;
  text-wrap: balance;
}
.family-support__body {
  font-size: var(--text-base); color: var(--clr-ink);
  opacity: 0.85; line-height: 1.75; margin-bottom: 24px;
}
.family-support__list {
  list-style: none; margin: 0 0 28px; padding: 0;
  display: flex; flex-direction: column; gap: 10px;
}
.family-support__list li {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--font-head); font-size: var(--text-base); font-weight: 800;
  color: var(--clr-ink);
}
.family-support__list li::before {
  content: '';
  flex-shrink: 0; width: 20px; height: 20px;
  background: var(--clr-teal);
  border-radius: 50%;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 12 10' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 5l3.5 3.5L11 1' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 10px 8px;
}

/* ================================================
   CREDENTIALS   bg: var(--bg-hero) warm beige
================================================ */
.credentials {
  background: var(--bg-hero);
  padding: var(--section-pad) 0;
  border-top: 1px solid var(--border);
}
.credentials__inner { text-align: center; }
.credentials__heading {
  font-size: var(--text-h2); font-weight: var(--weight-h2);
  color: var(--clr-ink); margin-bottom: 14px;
}
.credentials__lead {
  font-size: var(--text-sm); color: var(--clr-ink);
  opacity: 0.7; line-height: 1.75;
  max-width: 580px; margin: 0 auto 48px;
}
.credentials__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--gap-card);
  max-width: 760px;
  margin: 0 auto;
}
.credential-card {
  background: var(--bg-page);
  border-radius: var(--radius-lg);
  padding: 40px 36px 36px;
  box-shadow: var(--shadow);
  border-top: 3px solid var(--clr-teal);
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  gap: 16px;
}
.credential-card__logo {
  width: 130px; height: 130px;
  display: flex; align-items: center; justify-content: center;
}
.credential-card__logo img {
  width: 100%; height: 100%;
  object-fit: contain; background: transparent;
}
.credential-card__body {
  display: flex; flex-direction: column; gap: 10px;
}
.credential-card__name {
  font-size: var(--text-h3); font-weight: var(--weight-h3);
  color: var(--clr-ink);
}
.credential-card__desc {
  font-size: var(--text-sm); color: var(--clr-ink);
  opacity: 0.75; line-height: 1.75;
}

/* ================================================
   NEWS   bg: var(--bg-section) teal-pale
================================================ */
.news-band {
  background: var(--bg-section);
  padding: var(--section-pad) 0;
  border-top: 1px solid var(--border);
}
.news-band__heading {
  font-size: var(--text-h2); font-weight: var(--weight-h2);
  color: var(--clr-ink); margin-bottom: 40px;
}
.news-band__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--gap-card);
}
.news-card {
  background: var(--bg-page);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex; flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}
.news-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.news-card__img-wrap {
  aspect-ratio: 16 / 9;
  overflow: hidden;
}
.news-card__img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover; display: block;
}
.news-card__body {
  padding: 22px 20px;
  display: flex; flex-direction: column; gap: 10px; flex: 1;
}
.news-card__date {
  font-family: var(--font-head); font-size: var(--text-2xs); font-weight: 700;
  color: var(--clr-teal);
}
.news-card__title {
  font-family: var(--font-head); font-size: 16px; font-weight: 800;
  color: var(--clr-ink); line-height: 1.3;
}
.news-card__title a { color: var(--clr-ink); text-decoration: none; }
.news-card__title a:hover { color: var(--clr-teal); text-decoration: none; }
.news-card__read {
  font-family: var(--font-head); font-size: var(--text-xs); font-weight: 700;
  color: var(--clr-teal); margin-top: auto; padding-top: 6px;
}
.news-card__read:hover { color: var(--clr-teal-dark); text-decoration: underline; }
.news-band__footer {
  margin-top: 32px;
  font-family: var(--font-head); font-size: var(--text-sm); font-weight: 700;
}
.news-band__footer a { color: var(--clr-teal); }
.news-band__footer a:hover { color: var(--clr-teal-dark); }

/* reviews-band, final-cta, accordion, faq-section, footer, sr-only — moved to components.css */

/* ================================================
   RESPONSIVE — 1024px
================================================ */
@media (max-width: 1024px) {
  .container { padding: 0 var(--container-pad-sm); }
  .services-list__grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 768px) {
  .container { padding: 0 var(--gutter-mobile); }
  .cta-form { padding: 50px 0; }
}

/* ================================================
   RESPONSIVE — 900px
================================================ */
@media (max-width: 900px) {
  .hero__inner,
  .cta-form__inner,
  .family-support__inner { grid-template-columns: 1fr; gap: 40px; }

  .hero__media { order: -1; }
  .cta-form__pills { margin-top: 0; flex-wrap: wrap; }
  .cta-form__callout { padding: 26px 22px; }

  .services-list__grid { grid-template-columns: repeat(2, 1fr); }
  .credentials__grid  { grid-template-columns: 1fr; max-width: 520px; }
  .credential-card    { flex-direction: column; gap: 16px; }
  .news-band__grid    { grid-template-columns: 1fr 1fr; }
}

/* ================================================
   RESPONSIVE — 767px
================================================ */
@media (max-width: 767px) {
  .hero__actions { flex-direction: column; align-items: flex-start; }
  .btn--large { width: 100%; text-align: center; }

  .services-list__grid { grid-template-columns: 1fr 1fr; }
  .credentials__grid  { grid-template-columns: 1fr; }
  .news-band__grid    { grid-template-columns: 1fr; }

  .form-row--split,
  .form-row--70-30,
  .form-row--40-60 { grid-template-columns: 1fr; }
}

/* ================================================
   RESPONSIVE — 480px
================================================ */
@media (max-width: 480px) {
  .services-list__grid { grid-template-columns: 1fr; }
  .credential-card { padding: 28px 22px; }
}

/* ================================================
   TYPOGRAPHY GUARD — no orphan words
================================================ */
h1, h2, h3, h4,
.hero__title, .hero__lead,
.cta-form__heading, .cta-form__brand-heading,
.cta-form__diag-headline, .cta-form__diag-sub,
.services-list__heading, .insurance__heading,
.credentials__heading, .news-band__heading,
.service-card__name, .credential-card__name, .news-card__title {
  text-wrap: balance;
}
.btn { text-wrap: nowrap; }

/* Centred lead paragraphs — prevent orphan last lines */
.credentials__lead,
.services-list__intro,
.services-list__footer {
  text-wrap: pretty;
}

/* Heading sizes tuned for the homepage — shorter phrasing than the Woburn page
   so lines fill evenly without a stranded last word. */
.hero__title          { font-size: clamp(24px, 3.2vw, 38px); }
.cta-form__heading    { font-size: clamp(22px, 3.0vw, 34px); }
