/* One subject per viewport. Snap is desktop-only; touch keeps native momentum. */
:root { --header-height: 80px; }
html { scroll-snap-type: y mandatory; scroll-padding-top: var(--header-height); }
html.is-screen-moving { scroll-snap-type: none; scroll-behavior: auto; }
.header-inner { height: var(--header-height); }
main > section {
  min-height: calc(100svh - var(--header-height));
  scroll-snap-align: start;
  scroll-snap-stop: always;
  scroll-margin-top: 0;
  padding-block: clamp(36px, 6vh, 72px);
}
.hero { display: flex; flex-direction: column; justify-content: center; }
.hero .hero-bottom { margin-top: 52px; }
.services { border-top: 0; display: flex; flex-direction: column; justify-content: center; }
.services .section-heading { margin-bottom: clamp(24px, 4vh, 44px); }
.service-stage { display: grid; grid-template-columns: 1fr 1.25fr; gap: 80px; align-items: center; }
.service-tabs { display: flex; flex-direction: column; }
.service-tab {
  appearance: none; width: 100%; text-align: left; border: 0; border-top: 1px solid var(--line);
  border-radius: 0; background: transparent; display: grid; grid-template-columns: 22px 1fr 20px;
  align-items: center; gap: 20px; padding: 25px 0; color: var(--muted);
  transition: color .3s var(--ease); position: relative;
}
.service-tab:last-child { border-bottom: 1px solid var(--line); }
.service-tab::before { content: ''; position: absolute; left: 0; top: -1px; width: 100%; height: 1px; background: var(--gold); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease); }
.service-tab[aria-selected=true]::before { transform: scaleX(1); }
.service-tab[aria-selected=true], .service-tab:hover { color: var(--ink); }
.tab-index { font-size: 12px; color: var(--gold); }
.tab-name > span { font-size: 11px; display: block; margin-bottom: 9px; }
.tab-name strong { font-size: clamp(21px, 2.2vw, 30px); font-weight: 450; line-height: 1.4; letter-spacing: -.03em; }
.tab-arrow { color: var(--gold); opacity: 0; transform: translate(-5px, 5px); transition: opacity .35s, transform .35s var(--ease); }
.service-tab[aria-selected=true] .tab-arrow { opacity: 1; transform: none; }
.service-panels { display: grid; align-items: start; }
.service-panel { grid-area: 1/1; min-height: 330px; padding-block: 12px; }
.service-panel[hidden] { display: none; }
.service-panel > h3 { font-size: clamp(23px, 2.2vw, 30px); font-weight: 450; line-height: 1.6; margin-bottom: 20px; letter-spacing: -.025em; }
.service-panel .service-content { padding: 0; }
.service-panel .service-description { font-size: 15px; }
.service-panel .service-details { margin-top: 22px; }
.service-panel .service-note, .service-panel .detail-link { margin-top: 24px; }
.process { display: flex; align-items: center; }
.founder { align-content: center; }
.contact { display: flex; flex-direction: column; justify-content: center; position: relative; padding-bottom: 120px; border-top: 0; }
.contact .footer { position: absolute; bottom: 0; left: 50%; transform: translateX(-50%); }
.screen-rail { position: fixed; right: 24px; top: 50%; transform: translateY(-50%); z-index: 40; display: grid; gap: 15px; }
.screen-rail a { display: flex; align-items: center; justify-content: flex-end; gap: 8px; padding: 4px; min-height: 24px; }
.screen-rail a span { font-size: 10px; color: var(--muted); opacity: 0; transition: opacity .3s; }
.screen-rail i { width: 9px; height: 1px; background: var(--muted); transition: width .35s var(--ease), background .35s; }
.screen-rail a[aria-current] span, .screen-rail a:hover span { opacity: 1; }
.screen-rail a[aria-current] i { width: 19px; background: var(--gold); }
@media (prefers-reduced-motion: no-preference) {
  .service-panel.panel-enter { animation: panel-enter .45s var(--ease) both; }
  @keyframes panel-enter { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
}
@media (max-width: 1100px) {
  :root { --header-height: 78px; }
  .service-stage { gap: 38px; grid-template-columns: 1fr 1.35fr; }
  .service-tab { gap: 12px; }
  .tab-name strong { font-size: 22px; }
  .screen-rail { right: 6px; }
  .screen-rail a span { display: none; }
  .screen-rail a[aria-current] i { width: 12px; }
}
@media (max-width: 767px) {
  :root { --header-height: 72px; }
  main > section { padding-block: 32px; }
  .hero .hero-bottom { margin-top: 30px; }
  .screen-rail { display: none; }
  .mobile-menu { position: absolute; left: 0; right: 0; top: var(--header-height); }
  .services .section-heading { margin-bottom: 22px; }
  .services .section-heading h2 { font-size: 25px; }
  .services .section-heading p { font-size: 13px; }
  .service-stage { display: block; }
  .service-tabs { flex-direction: row; margin-bottom: 28px; }
  .service-tab { grid-template-columns: 1fr; align-content: start; align-items: start; gap: 7px; padding: 14px 8px 16px; border-bottom: 1px solid var(--line); flex: 1; }
  .service-tab:first-child { padding-left: 0; }
  .tab-name strong { font-size: 14px; font-weight: 500; letter-spacing: -.04em; }
  .tab-name > span, .tab-arrow { display: none; }
  .tab-index { font-size: 10px; }
  .service-panel { min-height: 340px; padding: 0; }
  .service-panel > h3 { font-size: 21px; margin-bottom: 15px; }
  .service-panel .service-description { font-size: 14px; }
  .service-panel .service-details { margin-top: 19px; gap: 18px; }
  .service-panel .service-details dd { font-size: 12px; }
  .service-panel .service-note, .service-panel .detail-link { margin-top: 18px; }
  .founder { gap: 26px; }
  .contact { padding-bottom: 115px; }
  .contact .footer { padding-block: 18px; }
}
@media (max-height: 720px) and (min-width: 768px) {
  main > section { padding-block: 26px; }
  .hero h1 { font-size: 64px; }
  .hero .eyebrow { margin-bottom: 20px; }
  .hero .hero-bottom { margin-top: 26px; }
  .services .section-heading { margin-bottom: 18px; }
  .service-tab { padding-block: 18px; }
  .service-panel { min-height: 295px; }
  .contact { padding-bottom: 95px; }
}
/* Do not pull touch scrolling back to section boundaries. Keep stable svh sizing
   and natural overflow, including landscape phones and touch-first tablets. */
@media (max-width: 767px), (pointer: coarse) {
  html { scroll-snap-type: none; }
  main > section { scroll-snap-align: none; scroll-snap-stop: normal; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
