/* Measured fixed surfaces preserve the shell's original space in every application. */
html[data-fcp-fixed] {
  scroll-padding-top:calc(var(--fcp-obstruction,142px) + var(--fcp-question-bar,0px));
  scrollbar-gutter:stable;
}
html[data-fcp-fixed] body .fc-platform.fcp-shell[data-fcp-fixed] {
  position:relative; z-index:1030; height:var(--fcp-shell-height);
  min-height:var(--fcp-shell-height); isolation:isolate;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-fixed] > .fcp-utility {
  position:fixed; inset-inline:0; top:var(--fcp-toolbar-height,0px); width:auto; margin:0;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-fixed] > .fcp-header {
  position:fixed; inset-inline:0; top:calc(var(--fcp-toolbar-height,0px) + var(--fcp-utility-height));
  width:auto; margin:0; transition:box-shadow .2s ease,border-color .2s ease;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-scrolled] > .fcp-header {
  border-bottom-color:#b8cce7; box-shadow:0 8px 24px #0a2c541a;
}
html[data-fcp-fixed] body .fcp-shell .fcp-utility-inner { flex-wrap:wrap; }
html[data-fcp-fixed] body .fcp-shell .fcp-utility nav { flex-wrap:wrap; min-width:0; max-width:100%; }
html[data-fcp-fixed] body .fcp-shell .fcm-mega {
  max-height:calc(100vh - var(--fcp-obstruction) - 16px);
  max-height:calc(100dvh - var(--fcp-obstruction) - 16px);
  overflow:auto; overscroll-behavior:contain; scrollbar-gutter:stable;
  scroll-padding-block:16px;
}
html[data-fcp-fixed] body .fcp-shell .fcp-language {
  max-height:calc(100vh - var(--fcp-toolbar-height,0px) - var(--fcp-utility-height) - 12px);
  max-height:calc(100dvh - var(--fcp-toolbar-height,0px) - var(--fcp-utility-height) - 12px);
  overflow:auto; overscroll-behavior:contain; scroll-padding-block:12px;
}
html[data-fcp-fixed] body .fcp-shell .fcp-nav-shade {
  position:fixed; top:var(--fcp-obstruction); inset-inline:0; bottom:0;
  background:#071f4240; z-index:9; touch-action:none;
}
html[data-fcp-menu-open] { overflow:hidden; }
html[data-fcp-menu-open] body { overscroll-behavior:none; }

/* The primary row stays visible. Only the navigation sheet scrolls. */
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-header-inner { flex-wrap:nowrap; }
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-header-actions { margin-inline-start:auto; }
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-header-actions > a { display:none; }
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-mobile-toggle {
  display:inline-flex; align-items:center; justify-content:center; gap:8px;
  min-height:48px; padding:10px 14px; border:1px solid #b6cdec; border-radius:8px;
  color:#074bb7; background:#edf4ff; font-size:16px; line-height:1.5;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-navigation {
  position:absolute; top:100%; inset-inline:0; width:auto; max-width:none;
  display:none; flex-direction:column; align-items:stretch; gap:0; margin:0;
  padding:12px var(--fc-page-gutter,20px) max(24px,env(safe-area-inset-bottom));
  max-height:calc(100vh - var(--fcp-obstruction));
  max-height:calc(100dvh - var(--fcp-obstruction));
  overflow:auto; overscroll-behavior:contain; scrollbar-gutter:stable;
  background:#fff; border:0; border-top:1px solid #c8d9ee;
  box-shadow:0 12px 24px #0c2d5714; scroll-padding-block:16px;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-navigation[data-open=true] { display:flex; }
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-navigation > :is(a,button) {
  display:flex; justify-content:space-between; min-height:56px; white-space:normal;
  padding:14px 10px; border-bottom:1px solid #dce5f0; border-radius:0;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-navigation > :is(a,button)::after { content:none; }
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcm-mega {
  position:static; inset:auto; max-height:none; max-width:none; overflow:visible;
  width:100%; margin:10px 0; border-radius:11px; animation:none;
  box-shadow:0 5px 15px #102a4810; scrollbar-gutter:auto;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-mobile-account {
  display:flex; flex-wrap:wrap; gap:8px 22px; padding-top:14px;
}
html[data-fcp-fixed] body .fcp-shell[data-fcp-compact] .fcp-mobile-account > a {
  display:inline-flex; align-items:center; min-height:48px; font-size:16px; color:#0757c9;
}

/* Root scroll padding supplies the header offset once, including native fragments. */
html[data-fcp-fixed] body :is([id],a[name]):not(.fc-platform *) { scroll-margin-top:20px!important; }
html[data-fcp-fixed] body#pricing-page2 .fc-pricing-v3 .site-content [id] {
  scroll-margin-top:calc(var(--fc-price-control,58px) + 20px)!important;
}
html[data-fcp-fixed] body.fc-modern[data-fc-content=legal] main .sidebar {
  top:calc(var(--fcp-obstruction) + 16px);
  max-height:calc(100vh - var(--fcp-obstruction) - 32px);
  max-height:calc(100dvh - var(--fcp-obstruction) - 32px);
  overscroll-behavior:contain; scroll-padding-block:12px;
}
html[data-fcp-fixed] body.fc-modern .comp-sec .t-head.position-sticky,
html[data-fcp-fixed] body.fc-modern .custom-thead { top:var(--fcp-obstruction); }
@media(min-width:960px) {
  html[data-fcp-fixed] body.fc-modern .sticky-right { top:calc(var(--fcp-obstruction) + 24px); }
}
html[data-fcp-fixed] body:is(.fc-resource-v3,.fc-tutorials) .reading-bar-wrapper { top:var(--fcp-obstruction); z-index:1010; }
html[data-fcp-fixed] body.fc-community-questions .sticky-content { top:var(--fcp-obstruction); }
html[data-fcp-sidebar-flow] body.fc-community-questions :is(.warp-main-content,.warp-sidebar,.warp-left-menu) { min-height:0!important; }
html[data-fcp-sidebar-flow] body.fc-community-questions .theiaStickySidebar {
  position:static!important; top:auto!important; left:auto!important; width:auto!important;
}
html[data-fcp-fixed] body.fc-community-questions .tipsy { pointer-events:none; }
@media(prefers-reduced-motion:no-preference) {
  html[data-fcp-fixed] { scroll-behavior:smooth; }
}
@media(prefers-reduced-motion:reduce) {
  html[data-fcp-fixed], html[data-fcp-fixed] body .fcp-shell * { scroll-behavior:auto!important; transition:none!important; animation:none!important; }
}
