/* ============================================================
   Family & Lifestyle Medicine — Reset, document defaults, layout primitives, typography helpers
   Part 02 of 11. The cascade depends on load order:
   these files must stay linked in numeric sequence (see any page <head>).
   ============================================================ */

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  /* The off-canvas nav sits outside the viewport when closed; clip (not hidden)
     so it never creates horizontal scroll and the sticky header still works. */
  overflow-x: clip;
}

/* The header is sticky, so anything an in-page link lands on has to clear it —
   otherwise the section heading arrives hidden underneath. */
:target { scroll-margin-top: clamp(5.5rem, 9vw, 7rem); }

body {
  font-family: var(--font-body);
  font-size: clamp(1.04rem, .98rem + .22vw, 1.12rem);
  line-height: 1.66;
  color: var(--body);
  background: var(--ivory);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--crimson); text-decoration: none; }
ul { list-style: none; padding: 0; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.08;
  font-weight: 600;
  letter-spacing: -.01em;
  text-wrap: balance;
}

::selection { background: var(--crimson); color: #fff; }

:focus-visible {
  outline: 3px solid var(--crimson);
  outline-offset: 3px;
  border-radius: 4px;
}

.skip-link {
  position: absolute; left: 50%; top: -100px; transform: translateX(-50%);
  z-index: 999; background: var(--crimson); color: #fff;
  padding: .8rem 1.4rem; border-radius: 0 0 var(--r-sm) var(--r-sm); font-weight: 600;
  transition: top .2s var(--ease);
}
.skip-link:focus { top: 0; }

/* Available to the document outline and to screen readers, absent from the
   page. Used where a section's visible heading has been folded into the banner
   above it but the section still needs one. */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0; border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

/* ---------- Layout primitives ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section { padding-block: var(--section-y); position: relative; }
.section--tint { background: linear-gradient(180deg, var(--cream), var(--ivory)); }
.section--dark {
  background:
    radial-gradient(120% 80% at 85% 0%, rgba(155, 27, 47, .38), transparent 60%),
    linear-gradient(160deg, #2F4C59, #223B46 60%, #1C333D);
  color: rgba(255, 255, 255, .82);
}
.section--dark h2, .section--dark h3 { color: #fff; }

.section-head { max-width: 62ch; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.section-head--center { margin-inline: auto; text-align: center; }
.section-title {
  font-size: clamp(2rem, 1.3rem + 2.9vw, 3.35rem);
  line-height: 1.06;
}
.section-title em { font-style: italic; color: var(--crimson); }
.section-title + p, .section-title + .lead { margin-top: 1.3rem; }
.section-sub { margin-top: 1.25rem; font-size: 1.12rem; }
.section-head--center .btn { margin-top: 2rem; }

.lead { font-size: 1.14rem; }
.mission__text p + p { margin-top: 1.15rem; }

.eyebrow {
  font-family: var(--font-body);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--crimson);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: .7rem;
}
.section-head--center .eyebrow { justify-content: center; }
.eyebrow::before {
  content: ""; width: 28px; height: 2px; background: var(--crimson); border-radius: 2px;
}
.eyebrow--light { color: #E9AEB6; }
.eyebrow--light::before { background: #E9AEB6; }

