/* Approved service-page composition. Deliberately isolated from home/pricing. */
.service-page {
  --service-content: 960px;
  --service-gutter: 32px;
  --service-section-space: 56px;
  --service-row-space: 24px;
  --service-ink: #315e95;
  --service-rule: rgba(89, 147, 196, .3);
}

.service-page .page-main {
  width: min(var(--service-content), calc(100% - 2 * var(--service-gutter)));
  padding-top: 96px;
}
.service-page .scene-image { opacity: .44; }
.service-page .service-hero {
  width: calc(100% + 64px);
  margin-left: -32px;
  min-height: 420px;
  padding: 48px 32px 60px;
}
.service-page .service-hero-copy { width: 46%; max-width: 440px; }
.service-page .service-hero h1 {
  max-width: none;
  font-size: clamp(40px, 4.5vw, 52px);
  line-height: 1.05;
  letter-spacing: -.03em;
  text-wrap: balance;
}
.service-page .service-hero h1 span { display: block; }
.expertise-page .service-hero h1 { font-size: clamp(36px, 3.9vw, 44px); }
.international-page .service-hero h1 { font-size: clamp(36px, 3.9vw, 44px); }
.service-page .service-hero .page-lead { max-width: 32ch; }
.service-page .service-hero-media {
  mask-image: linear-gradient(90deg, transparent, #000 10%, #000 94%, transparent), linear-gradient(0deg, transparent, #000 18%, #000 92%, transparent);
  mask-composite: intersect;
}
.service-page .service-hero-media img { object-position: var(--service-image-position, 85% 50%); }
.expertise-page { --service-image-position: 100% 50%; }
.international-page .service-hero-media {
  mask-image: linear-gradient(90deg, transparent 30%, #000 56%, #000 94%, transparent), linear-gradient(0deg, transparent, #000 18%, #000 92%, transparent);
}
.service-page .service-details { padding: 8px 0 var(--service-section-space); scroll-margin-top: 28px; }
.service-page .service-intro { max-width: 720px; padding: 0 0 16px; text-align: center; }
.service-page .service-intro h2 { font-size: 32px; line-height: 1.2; }
.service-rows { margin-top: 4px; }
.service-row {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: 40px;
  align-items: start;
  padding: var(--service-row-space) 0;
  scroll-margin-top: 28px;
}
.service-row + .service-row { border-top: 1px solid var(--service-rule); }
.service-row:last-child { padding-bottom: 0; }
.service-row h3 { font-size: 23px; line-height: 1.25; font-weight: 700; letter-spacing: -.025em; text-wrap: pretty; }
.service-row p { max-width: 60ch; font-size: 17px; line-height: 1.55; color: var(--service-ink); text-wrap: pretty; }
.expertise-page .service-row h3 { font-size: 21px; line-height: 1.3; }

.service-page .service-contact {
  position: relative;
  isolation: isolate;
  display: block;
  width: calc(100% + 96px);
  min-height: 348px;
  margin: 0 0 0 -48px;
  padding: 36px 48px;
  border: 1px solid rgba(255, 255, 255, .96);
  border-radius: 14px;
  background: #e6f5ff;
  overflow: hidden;
  scroll-margin-top: 24px;
}
.service-contact-image { position: absolute; inset: 0; z-index: -2; width: 100%; height: 100%; object-fit: cover; object-position: 65% 50%; }
.service-contact::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(90deg, rgba(230, 245, 255, .98), rgba(230, 245, 255, .95) 29%, rgba(230, 245, 255, .5) 43%, transparent 65%);
  pointer-events: none;
}
.service-contact-copy { position: relative; width: 44%; }
.service-page .service-contact h2 { margin: 0; font-size: 44px; line-height: 1.06; letter-spacing: -.03em; }
.service-contact h2 span { display: block; }
.service-page .service-contact .button { width: 176px; height: 48px; margin-top: 24px; font-size: 14px; }
.service-contact .contact-details { width: auto; gap: 4px; margin-top: 20px; color: var(--service-ink); font-size: 16px; line-height: 1.4; }
.service-contact .contact-details a { min-height: 44px; gap: 14px; width: fit-content; }
.service-contact .contact-details a:hover { color: var(--navy); text-decoration: underline; text-underline-offset: 4px; }
.service-contact .contact-details svg { width: 18px; height: 18px; }

@media (min-width: 961px) {
  /* Keep the text side quiet; the existing photo mask softens every outer edge. */
  .family-page .service-hero-media::after,
  .expertise-page .service-hero-media::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, rgba(244, 251, 255, .98), rgba(244, 251, 255, .96) 28%, rgba(244, 251, 255, .9) 34%, rgba(244, 251, 255, .62) 40%, rgba(244, 251, 255, .16) 48%, rgba(244, 251, 255, 0) 58%);
    pointer-events: none;
  }
}

@media (max-width: 1120px) and (min-width: 961px) {
  .service-page { --service-content: 800px; }
  .service-page .service-hero-copy { width: 48%; }
  .service-page .service-hero-media img { object-position: var(--service-image-position, 85% 50%); }
  .expertise-page .service-hero-media {
    mask-image: linear-gradient(90deg, transparent 44%, #000 62%, #000 94%, transparent), linear-gradient(0deg, transparent, #000 18%, #000 92%, transparent);
  }
  .service-page .service-contact h2 { font-size: 40px; }
  .service-contact-copy { width: 48%; }
}
@media (max-width: 960px) {
  .service-page { --service-gutter: 24px; --service-section-space: 40px; }
  .service-page .page-main { padding-top: 100px; }
  .service-page .service-hero { width: 100%; margin: 0; padding: 20px 0 0; min-height: 0; gap: 28px; }
  .service-page .service-hero-copy { width: 100%; max-width: 620px; }
  .service-page .service-hero h1 { font-size: clamp(32px, 5.5vw, 44px); max-width: 25ch; line-height: 1.08; }
  .family-page .service-hero h1 span { display: inline; }
  .service-page .service-hero .page-lead { max-width: 44ch; }
  .service-page .service-hero-media { mask-image: none; height: clamp(196px, 32vw, 280px); border: 0; border-radius: 14px; }
  .service-page .service-hero-media img { object-position: var(--service-image-position, 85% 50%); }
  .service-page .service-details { padding-top: 36px; }
  .service-page .service-intro { padding: 0 0 12px; max-width: 620px; }
  .service-page .service-intro h2 { font-size: 28px; }
  .service-row { gap: 28px; }
  .service-row h3, .expertise-page .service-row h3 { font-size: 21px; }
  .service-row p { font-size: 16px; line-height: 1.6; }
  .service-page .service-contact { width: 100%; margin: 0; padding: 32px; min-height: 330px; }
  .service-contact-copy { width: 52%; }
  .service-page .service-contact h2 { font-size: 36px; }
  .service-contact .contact-details { font-size: 15px; }
}
@media (max-width: 640px) {
  .service-page { --service-gutter: 20px; --service-row-space: 24px; }
  .service-page .service-hero h1 { font-size: clamp(30px, 7.5vw, 40px); overflow-wrap: normal; }
  .family-page .service-hero h1 { max-width: 9ch; }
  .family-page .service-hero h1 span { display: block; }
  .service-page .service-hero .page-actions { gap: 8px 20px; }
  .service-page .service-hero-media { height: auto; aspect-ratio: 1.8; }
  .service-page .service-intro { text-align: left; margin: 0; }
  .service-page .service-intro h2 { font-size: 27px; }
  .service-row { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .service-row p { max-width: 50ch; }
  .service-page .service-contact { padding: 28px 24px 220px; }
  .service-contact-copy { width: 100%; }
  .service-page .service-contact h2 { font-size: clamp(32px, 8vw, 40px); max-width: 14ch; }
  .service-page .service-contact .button { margin-top: 20px; }
  .service-contact .contact-details { margin-top: 16px; font-size: 15px; gap: 4px; }
  .service-contact .contact-details a { min-height: 44px; }
  .service-contact-image { top: auto; height: 224px; object-position: 78% 50%; }
  .service-contact::after { background: linear-gradient(180deg, #e6f5ff 0%, #e6f5ff calc(100% - 236px), rgba(230, 245, 255, .95) calc(100% - 206px), transparent calc(100% - 154px)); }
}
@media (prefers-contrast: more) {
  .service-page { --service-ink: #163e73; --service-rule: #416dac; }
}
