/*
  Shared group design system.
  Copied verbatim into each practice repo as assets/css/system.css.
  Per-practice colour/logo overrides live in assets/css/theme.css (loaded after this file).
*/

@font-face {
  font-family: "Jakarta";
  src: url("../fonts/jakarta-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jakarta";
  src: url("../fonts/jakarta-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Jakarta";
  src: url("../fonts/jakarta-800.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-500.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Group typography */
  --font-heading: "Jakarta", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  --font-body: "Inter", ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;

  /* Group spacing scale */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.5rem;
  --space-6: 2rem;
  --space-7: 3rem;
  --space-8: 4rem;
  --space-9: 6rem;

  /* Group layout */
  --container-max: 90rem; /* 1440px, full-width treatment across every page */
  --radius-sm: 0.5rem;
  --radius-md: 0.875rem;
  --radius-lg: 1.5rem;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 48px rgba(15, 23, 42, 0.14);

  /* Neutral palette (shared across the group) */
  --ink-900: #10161f;
  --ink-700: #33404f;
  --ink-500: #5b6a7c;
  --ink-300: #aab6c4;
  --ink-100: #e7ecf1;
  --surface-0: #ffffff;
  --surface-50: #f6f8fa;
  --surface-100: #eef2f5;

  /* Default brand tokens (overridden per site in theme.css) */
  --brand-primary: #0f6e5c;
  --brand-primary-dark: #0a4f42;
  --brand-primary-contrast: #ffffff;
  --brand-accent: #e7a33e;
  --focus-ring: #1d7bd6;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink-900);
  background: var(--surface-0);
  line-height: 1.6;
  font-size: 1rem;
  overflow-x: hidden;
}

img,
svg,
video {
  max-width: 100%;
  display: block;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 var(--space-4);
  color: var(--ink-900);
}

h1 {
  font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem);
  font-weight: 800;
}

h2 {
  font-size: clamp(1.5rem, 1.2rem + 1.2vw, 2.25rem);
}

h3 {
  font-size: clamp(1.15rem, 1.05rem + 0.4vw, 1.5rem);
}

p {
  margin: 0 0 var(--space-4);
  color: var(--ink-700);
  max-width: 42rem;
}

a {
  color: var(--brand-primary-dark);
  text-decoration-thickness: 1px;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 3px solid var(--focus-ring);
  outline-offset: 2px;
  border-radius: 2px;
}

ul,
ol {
  margin: 0 0 var(--space-4);
  padding-left: 1.25rem;
  color: var(--ink-700);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -3rem;
  background: var(--ink-900);
  color: #fff;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  z-index: 100;
  transition: top 0.15s ease;
}

.skip-link:focus {
  top: var(--space-4);
}

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding-inline: var(--space-5);
}

@media (min-width: 60rem) {
  .container {
    padding-inline: var(--space-7);
  }
}

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: saturate(180%) blur(6px);
  border-bottom: 1px solid var(--ink-100);
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-5);
  padding-block: var(--space-3);
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  text-decoration: none;
  flex-shrink: 0;
}

.brand img {
  height: 2.75rem;
  width: auto;
}

.brand-name {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--ink-900);
  line-height: 1.1;
}

.brand-sub {
  display: block;
  font-family: var(--font-body);
  font-weight: 500;
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand-primary-dark);
}

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--ink-100);
  background: var(--surface-0);
  cursor: pointer;
}

.nav-toggle svg {
  width: 1.4rem;
  height: 1.4rem;
}

@media (min-width: 60rem) {
  .nav-toggle {
    display: none;
  }
}

.primary-nav {
  display: none;
  align-items: center;
  gap: var(--space-6);
}

.primary-nav.is-open {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: var(--space-2);
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  background: var(--surface-0);
  border-bottom: 1px solid var(--ink-100);
  padding: var(--space-4) var(--space-5) var(--space-6);
  box-shadow: var(--shadow-md);
}

@media (min-width: 60rem) {
  .primary-nav {
    display: flex;
    position: static;
    box-shadow: none;
    padding: 0;
    border-bottom: 0;
  }
}

.primary-nav a {
  font-weight: 600;
  text-decoration: none;
  color: var(--ink-700);
  padding: var(--space-2) 0;
}

.primary-nav a:hover,
.primary-nav a[aria-current="page"] {
  color: var(--brand-primary-dark);
}

a.header-cta {
  display: none;
  flex-shrink: 0;
}

@media (min-width: 60rem) {
  a.header-cta {
    display: inline-flex;
  }
}

/* ---------- Buttons / CTA ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.75rem 1.4rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.12s ease, box-shadow 0.12s ease, background-color 0.12s ease;
  line-height: 1.2;
}

.btn-primary {
  background: var(--brand-primary);
  color: var(--brand-primary-contrast);
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover {
  background: var(--brand-primary-dark);
}

.btn-outline {
  background: transparent;
  border-color: currentColor;
  color: var(--brand-primary-dark);
}

.btn-outline:hover {
  background: var(--surface-50);
}

.btn-lg {
  padding: 1rem 1.9rem;
  font-size: 1.05rem;
}

/* ---------- Hero ---------- */

.hero {
  padding-block: var(--space-8) var(--space-8);
  background: linear-gradient(180deg, var(--surface-50), var(--surface-0));
}

.hero-grid {
  display: grid;
  gap: var(--space-7);
  align-items: center;
}

@media (min-width: 60rem) {
  .hero-grid {
    grid-template-columns: 1.05fr 0.95fr;
  }
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-primary-dark);
  background: color-mix(in srgb, var(--brand-primary) 12%, white);
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  margin-bottom: var(--space-4);
}

.hero-actions {
  display: none;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-top: var(--space-6);
}

@media (min-width: 60rem) {
  .hero-actions {
    display: flex;
  }
}

.hero-media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}

.hero-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  aspect-ratio: 4 / 3;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-5);
  margin-top: var(--space-6);
  padding-top: var(--space-6);
  border-top: 1px solid var(--ink-100);
}

.trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  font-weight: 600;
  color: var(--ink-700);
  font-size: 0.92rem;
}

.trust-item svg {
  width: 1.3rem;
  height: 1.3rem;
  flex-shrink: 0;
  color: var(--brand-primary);
}

/* ---------- Sections ---------- */

.section {
  padding-block: var(--space-8);
}

.section-alt {
  background: var(--surface-50);
}

.section-head {
  max-width: 42rem;
  margin-bottom: var(--space-7);
}

.section-head.center {
  margin-inline: auto;
  text-align: center;
}

.kicker {
  display: block;
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--brand-primary-dark);
  margin-bottom: var(--space-2);
}

/* ---------- Cards / grids ---------- */

.grid {
  display: grid;
  gap: var(--space-5);
}

.grid-2 {
  grid-template-columns: 1fr;
}

.grid-3 {
  grid-template-columns: 1fr;
}

@media (min-width: 48rem) {
  .grid-2 {
    grid-template-columns: repeat(2, 1fr);
  }
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.card {
  background: var(--surface-0);
  border: 1px solid var(--ink-100);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  box-shadow: var(--shadow-sm);
  height: 100%;
}

.card h3 {
  margin-bottom: var(--space-2);
}

.card p:last-child {
  margin-bottom: 0;
}

.icon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: var(--radius-sm);
  background: color-mix(in srgb, var(--brand-primary) 12%, white);
  color: var(--brand-primary-dark);
  margin-bottom: var(--space-4);
}

.icon-badge svg {
  width: 1.5rem;
  height: 1.5rem;
}

/* ---------- Service detail list ---------- */

.service-list-item {
  padding-block: var(--space-6);
  border-bottom: 1px solid var(--ink-100);
}

.service-list-item:first-child {
  padding-top: 0;
}

.service-list-item:last-child {
  border-bottom: 0;
}

/* ---------- Contact / location block ---------- */

.info-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.info-list li {
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  color: var(--ink-700);
}

.info-list svg {
  width: 1.4rem;
  height: 1.4rem;
  color: var(--brand-primary);
  flex-shrink: 0;
  margin-top: 0.15rem;
}

.info-list a {
  color: var(--ink-700);
  font-weight: 600;
  text-decoration: none;
}

.info-list a:hover {
  color: var(--brand-primary-dark);
}

.map-frame {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--ink-100);
  box-shadow: var(--shadow-sm);
}

.map-frame iframe {
  width: 100%;
  height: 100%;
  min-height: 20rem;
  border: 0;
  display: block;
}

.booking-frame-wrap {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--ink-100);
  box-shadow: var(--shadow-sm);
}

.booking-frame {
  width: 100%;
  height: 46rem;
  max-height: 80vh;
  border: 0;
  display: block;
}

.booking-note {
  margin-top: var(--space-4);
  color: var(--ink-500);
  font-size: 0.92rem;
}

/* ---------- Pricing list ---------- */

.price-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.price-list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: var(--space-3);
  padding-block: var(--space-3);
  border-bottom: 1px solid var(--ink-100);
}

.price-list li:last-child {
  border-bottom: 0;
}

.price-item-name {
  color: var(--ink-700);
}

.price-item-value {
  font-weight: 700;
  color: var(--brand-primary-dark);
  white-space: nowrap;
}

/* ---------- Forms ---------- */

.form-grid {
  display: grid;
  gap: var(--space-4);
}

@media (min-width: 40rem) {
  .form-row-2 {
    grid-template-columns: repeat(2, 1fr);
  }
}

.field {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.field label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--ink-900);
}

.field .hint {
  font-size: 0.8rem;
  color: var(--ink-500);
  font-weight: 400;
}

.field input,
.field textarea,
.field select {
  font: inherit;
  padding: 0.7rem 0.85rem;
  border: 1.5px solid var(--ink-100);
  border-radius: var(--radius-sm);
  background: var(--surface-0);
  color: var(--ink-900);
}

.field input:invalid:not(:placeholder-shown) {
  border-color: #c23b3b;
}

.form-note {
  font-size: 0.85rem;
  color: var(--ink-500);
}

.form-status {
  display: none;
  padding: var(--space-4);
  border-radius: var(--radius-sm);
  font-weight: 600;
  margin-top: var(--space-4);
}

.form-status.is-visible {
  display: block;
}

.form-status.success {
  background: #e8f5ee;
  color: #1a5c3a;
  border: 1px solid #b7e3c9;
}

.form-status.error {
  background: #fcebeb;
  color: #8a1f1f;
  border: 1px solid #f1c3c3;
}

/* ---------- CTA band ---------- */

.cta-band {
  background: var(--brand-primary-dark);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: var(--space-7);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-6);
}

.cta-band h2,
.cta-band p {
  color: #fff;
}

.cta-band .btn-primary {
  background: #fff;
  color: var(--brand-primary-dark);
}

.cta-band .btn-primary:hover {
  background: var(--surface-100);
}

/* ---------- Footer ---------- */

.site-footer {
  background: var(--ink-900);
  color: var(--ink-300);
  padding-block: var(--space-8) var(--space-6);
  margin-top: var(--space-8);
}

.site-footer p {
  color: var(--ink-300);
}

.footer-grid {
  display: grid;
  gap: var(--space-7);
  grid-template-columns: 1fr;
}

@media (min-width: 48rem) {
  .footer-grid {
    grid-template-columns: 1.3fr 1fr 1fr;
  }
}

.site-footer a {
  color: var(--ink-100);
  text-decoration: none;
}

.site-footer a:hover {
  color: #fff;
  text-decoration: underline;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-4);
}

.footer-brand img {
  width: auto;
  height: 2.25rem;
  filter: brightness(0) invert(1);
}

.footer-heading {
  color: #fff;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
}

.footer-bottom {
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  justify-content: space-between;
  font-size: 0.85rem;
}

.group-badge {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 0.78rem;
  color: var(--ink-300);
}

.group-badge a {
  color: var(--ink-100);
  font-weight: 600;
}

/* ---------- Breadcrumb ---------- */

.breadcrumb {
  font-size: 0.85rem;
  color: var(--ink-500);
  padding-top: var(--space-5);
}

.breadcrumb a {
  color: var(--ink-500);
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

/* ---------- Page header (non-home) ---------- */

.page-header {
  padding-block: var(--space-7) var(--space-6);
}

.page-header p {
  max-width: 48rem;
}

/* ---------- Utility ---------- */

.text-center {
  text-align: center;
}

.mt-0 {
  margin-top: 0;
}

.stack {
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  * {
    transition-duration: 0.001ms !important;
    animation-duration: 0.001ms !important;
  }
}

/* ---------- Team / people photos (normalized across the group) ---------- */

.team-photo {
  width: 100%;
  height: auto;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: center top;
  border-radius: var(--radius-md);
  margin-bottom: var(--space-4);
}

/* ---------- Section brand watermark ---------- */

.section-brand-bg {
  position: relative;
  overflow: hidden;
}

.section-brand-bg > .container {
  position: relative;
  z-index: 1;
}

.section-watermark {
  position: absolute;
  top: 50%;
  right: -9rem;
  transform: translateY(-50%);
  width: 34rem;
  max-width: 70%;
  height: auto;
  opacity: 0.045;
  pointer-events: none;
  z-index: 0;
  user-select: none;
}

@media (max-width: 48rem) {
  .section-watermark {
    width: 20rem;
    right: -7rem;
  }
}

/* ---------- Full-bleed homepage hero ----------
   `--container-max` is full-width for every page (see :root above); this
   block only handles the homepage hero photo bleeding to the viewport
   edge, since it's the only page with a hero image to bleed.

   Image-led banner at every width: the photo is a full-bleed background
   behind the copy, with a brand-tinted scrim for contrast, rather than a
   separate side-by-side block. Mobile and desktop share this structure;
   only the crop, overlay direction and copy width are tuned per
   breakpoint below. */

.hero-bleed {
  position: relative;
  isolation: isolate;
  padding-block: 0 var(--space-7);
  min-height: 30rem;
}

.hero-bleed .hero-grid {
  gap: 0;
}

.hero-copy {
  position: relative;
  z-index: 2;
  padding-inline: var(--space-5);
  padding-block: var(--space-9) var(--space-8);
}

.hero-media-bleed {
  position: absolute;
  inset: 0;
  z-index: 0;
  border-radius: 0;
  box-shadow: none;
}

.hero-media-bleed img {
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: cover;
  object-position: 65% 40%;
}

.hero-media-bleed::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    color-mix(in srgb, var(--brand-primary-dark) 50%, transparent) 0%,
    color-mix(in srgb, var(--brand-primary-dark) 80%, transparent) 55%,
    color-mix(in srgb, var(--brand-primary-dark) 94%, transparent) 100%
  );
}

.hero-copy p,
.hero-copy .trust-item {
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
}

.hero-copy .eyebrow {
  background: rgba(255, 255, 255, 0.92);
}

.hero-copy h1 {
  color: #fff;
}

.hero-copy p {
  color: rgba(255, 255, 255, 0.92);
}

.hero-copy .trust-row {
  border-top-color: rgba(255, 255, 255, 0.28);
}

.hero-copy .trust-item,
.hero-copy .trust-item svg {
  color: #fff;
}

.hero-copy .btn-outline {
  color: #fff;
  border-color: #fff;
}

.hero-copy .btn-outline:hover {
  color: var(--brand-primary-dark);
  border-color: var(--brand-primary-dark);
}

/* Desktop: wider, shorter banner. The generic two-column `.hero-grid`
   split (defined earlier for non-bleed heroes) is neutralised here so
   the copy block doesn't get squeezed into half the viewport now that
   the photo is a full-bleed background, not a grid column. The overlay
   switches to a left-to-right gradient (dark behind the copy, clear
   over the right of the photo) since a short wide banner doesn't have
   room for the mobile's top-to-bottom scrim to read as a gradient. */
@media (min-width: 60rem) {
  .hero-bleed {
    min-height: 38rem;
  }

  .hero-bleed .hero-grid {
    grid-template-columns: 1fr;
  }

  .hero-copy {
    padding-inline: var(--space-7);
    padding-block: var(--space-9);
    max-width: 40rem;
  }

  .hero-media-bleed img {
    object-position: 68% 38%;
  }

  .hero-media-bleed::after {
    background: linear-gradient(
      100deg,
      color-mix(in srgb, var(--brand-primary-dark) 80%, transparent) 0%,
      color-mix(in srgb, var(--brand-primary-dark) 62%, transparent) 32%,
      color-mix(in srgb, var(--brand-primary-dark) 22%, transparent) 58%,
      color-mix(in srgb, var(--brand-primary-dark) 8%, transparent) 78%
    );
  }
}
