/* Inner-page layout (milestone 2). Requires tokens.css and site.css. Typographic rows, no cards,
   no gradients, no decorative animation (spec 2.2). */

.page-head { padding-block: var(--s7) var(--s7); border-bottom: 1px solid var(--line); }
.page-head .lead { margin-top: var(--s4); }
.breadcrumb { margin-bottom: var(--s4); font-size: var(--fs-small); }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2); }
.breadcrumb li { display: inline-flex; align-items: center; min-height: 44px; }
.breadcrumb li + li::before { content: "/"; margin-right: var(--s2); }
.breadcrumb a { display: inline-flex; align-items: center; min-height: 44px; }

.stack > * + * { margin-top: var(--s4); }
.stack h2 + p, .stack h3 + p { margin-top: var(--s4); }

/* Service rows: tag, name, sentence, limit/scope line, one link */
.service-group { scroll-margin-top: 80px; }
.service-group + .service-group { margin-top: var(--s8); }
.group-head { display: grid; gap: var(--s4); margin-bottom: var(--s5); }
.group-diagram { max-width: 420px; }
/* m3b r1 review (8): /demos at >= 1024 px uses the full container: intro text left, the demo right. */
@media (min-width: 1024px) {
  .demo-sec .container { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); column-gap: var(--s7); align-items: start; }
  .demo-sec .container > * { grid-column: 1; }
  .demo-sec .container > [data-component] { grid-column: 2; grid-row: 1 / span 8; margin-top: 0 !important; max-width: none; }
}
.service-row { grid-template-columns: 1fr; }
.service-row .label { color: var(--ink); }
.service-row .scope { font-size: var(--fs-small); }

/* Plans: two text columns divided by a hairline, not boxes */
.plan-cols { display: grid; gap: var(--s7); }
.plan { display: grid; gap: var(--s4); align-content: start; padding-top: var(--s5); border-top: 2px solid var(--ink); }
.plan-price {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: var(--fs-h2);
  line-height: 1.1;
}
.plan-price span { font-family: var(--font-body); font-weight: 400; font-size: var(--fs-small); }
.plan h4 { margin: var(--s2) 0 0; font-size: var(--fs-small); font-weight: 600; }
.plan-note { font-size: var(--fs-small); }

/* FAQ: native details/summary, keyboard operable without script */
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex;
  align-items: center;
  min-height: 56px;
  padding-block: var(--s3);
  font-weight: 600;
  cursor: pointer;
}
.faq details > p { padding-bottom: var(--s5); }

/* Embeds (GHL form, booking calendar) with plain fallback underneath (spec 11.3) */
.embed-frame { width: 100%; border: 1px solid var(--line); border-radius: var(--radius); background: var(--white); }
.embed-form { min-height: 760px; }
.embed-booking { min-height: 720px; }
.embed-fallback { margin-top: var(--s4); font-size: var(--fs-small); }
/* QUALITY m3 r1: inline-block + vertical-align:top dropped link text below the sentence line. Inline links keep
   the baseline; vertical padding on an inline box enlarges the tap area (about 22px line + 2x12px) without moving text. */
.embed-fallback { line-height: 1.5; }
.embed-fallback a { display: inline; padding-block: 12px; overflow-wrap: anywhere; -webkit-box-decoration-break: clone; box-decoration-break: clone; }

/* QUALITY m3 r1/r2: chain diagrams. The HTML step list is the visible diagram at every width, so labels
   stay at body size. The SVG inside .group-diagram (max-width 420px) scaled its 13px labels to ~7.7px at
   640+ (DECISIONS 60), so it is no longer shown; the list carries the same steps and order. */
.chain-steps { list-style: none; counter-reset: step; display: grid; gap: var(--s2); margin: 0 0 var(--s5); padding: 0; }
.chain-steps li { counter-increment: step; display: flex; align-items: center; gap: var(--s3); min-height: 44px; padding: var(--s2) var(--s4); border: 1.5px solid var(--ink); border-radius: var(--radius); background: var(--white); font-size: var(--fs-body); }
.chain-steps li::before { content: counter(step); font-family: var(--font-mono); font-size: var(--fs-small); color: var(--button); }
.chain-steps li:last-child { border-color: var(--accent-light-bg); border-width: 2px; }
.chain-svg { display: none; }
@media (min-width: 640px) {
  .chain-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); margin-bottom: 0; }
  .chain-steps li { font-size: var(--fs-small); }
}

.sms-disclosure { margin-top: var(--s7); padding-top: var(--s5); border-top: 1px solid var(--line); font-size: var(--fs-small); }
.sms-disclosure h2 { font-size: var(--fs-h3); font-family: var(--font-body); }
.sms-disclosure p + p { margin-top: var(--s3); }

.work-item { grid-template-columns: 1fr; }
.process-v { max-width: 640px; margin: 0 0 var(--s7); }
.audit-diagram { max-width: 720px; margin: 0 0 var(--s6); }
.fact-list { list-style: none; border-top: 1px solid var(--line); }
.fact-list li { display: grid; gap: var(--s1); padding-block: var(--s4); border-bottom: 1px solid var(--line); }

.primary-nav a[aria-current="page"], .mobile-menu a[aria-current="page"] { text-decoration: underline; text-decoration-thickness: 2px; }

@media (min-width: 820px) {
  .page-head { padding-block: var(--s8) var(--s8); }
  /* m3 polish (QUALITY 94 defect 4): heading stays above its step grid at every width */
  .group-head { grid-template-columns: 1fr; align-items: start; }
  .service-row { grid-template-columns: 14rem 1fr; column-gap: var(--s6); }
  .service-row .label { grid-row: 1 / span 4; padding-top: var(--s1); }
  .service-row > :not(.label) { grid-column: 2; }
  .plan-cols { grid-template-columns: 1fr 1fr; gap: var(--s8); }
  .work-item { grid-template-columns: 14rem 1fr; column-gap: var(--s6); }
  .work-item .label { grid-row: 1 / span 4; padding-top: var(--s1); }
  .work-item > :not(.label) { grid-column: 2; }
}

/* m3 polish (QUALITY 94 defect 3): plan card booking buttons scroll to the in-page booking section */
.book-section { scroll-margin-top: calc(var(--header-h, 72px) + var(--s4)); }
.book-section:focus { outline: none; }

/* rework r1 defect 5 (/services 1440: ~130px empty band above the first heading): the page-head already
   closes with its own bottom padding and rule, so the service-group section starts at one step of rhythm
   (48px) instead of the full 128px section padding. Scoped to /services only. */
.page-head + .section[aria-label="Service groups"] { padding-top: var(--s7); }

/* claude takeover 2026-11-29: inner pages open with the same dark, editorial band as the homepage hero */
.page-head { position: relative; overflow: hidden; background: linear-gradient(180deg, #0B1218 0%, #14202B 60%, #123A38 100%); color: #F4F2EE; border-bottom: 0; padding-block: var(--s8) var(--s8); }
.page-head::after { content: ""; position: absolute; width: 520px; height: 520px; right: -120px; top: -160px; border-radius: 50%; background: radial-gradient(circle, rgba(63,184,175,.22) 0%, rgba(63,184,175,0) 70%); pointer-events: none; }
.page-head .container { position: relative; z-index: 1; }
.page-head h1 { color: #F4F2EE; font-size: clamp(2.4rem, 1.4rem + 3.6vw, 4.25rem); line-height: 1.02; letter-spacing: -0.01em; max-width: 18ch; text-wrap: balance; }
.page-head .lead { color: #E4E9E8; max-width: 60ch; }
.page-head .eyebrow { color: #EAD9BE; }
.page-head .breadcrumb a { color: #F4F2EE; }
.page-head .breadcrumb [aria-current] { color: #C9D3D2; }
.page-head .breadcrumb li + li::before { color: #8FA3A1; }
.page-head :focus-visible { outline-color: #F4F2EE; }
@media (min-width: 1024px) { .page-head { padding-block: calc(var(--s8) + 24px) var(--s8); } }
