/* ==========================================================================
   chrome.css — Shared site chrome: top bar, sticky glass header, compact
   mega menu, app-style mobile drawer + bottom tab bar, footer, WhatsApp
   widget. Rendered by assets/js/core/shell.js on every public page.
   ========================================================================== */

:root {
  --chrome-header-bg: rgba(255, 255, 255, .78);
  --chrome-topbar-h: 38px;
  --chrome-header-h: 68px;
  --chrome-ink: #0f1b33;
  --chrome-ink-soft: #5a6a83;
  --chrome-line: #e6ebf3;
  --chrome-brand: #1a56db;
  --chrome-brand-soft: #eef3ff;
  --chrome-green: #15803d;
  --chrome-radius: 14px;
  --chrome-shadow: 0 18px 45px rgba(15, 27, 51, .13);
}
html[data-theme="dark"] {
  --chrome-header-bg: rgba(14, 20, 36, .74);
  --chrome-ink: #eef0ff;
  --chrome-ink-soft: #c3cbe4;
  --chrome-line: #263255;
  --chrome-brand: #c5d4ff;
  --chrome-brand-soft: rgba(147, 180, 255, .18);
}

@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .site-header { background: var(--color-surface-container-lowest); }
}
body.has-site-chrome { padding-top: 0; }
body.drawer-open { overflow: hidden; }

/* Old duplicate headers from page markup must never double up */
body.has-site-chrome .site-header-premium:not(#siteHeader),
body.has-site-chrome > header:not(#siteHeader),
body.has-site-chrome > footer:not(#siteFooter),
body.has-site-chrome > .govt-banner:not(.topbar),
body.has-site-chrome .mobile-drawer:not(#mobileDrawer) { display: none !important; }

/* ── Top bar ─────────────────────────────────────────────────────────── */
.topbar {
  background: #0d1526;
  color: rgba(255, 255, 255, .72);
  font-size: 12px;
  min-height: var(--chrome-topbar-h);
  display: flex;
  align-items: center;
}
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; width: 100%; }
.topbar-note { display: inline-flex; align-items: center; gap: 6px; font-weight: 500; }
.topbar-note .icon { color: #34d399; }
.topbar-links { display: flex; align-items: center; gap: 18px; }
.topbar-links a {
  display: inline-flex; align-items: center; gap: 5px;
  color: rgba(255, 255, 255, .72); text-decoration: none; font-weight: 500;
  transition: color .16s ease;
}
.topbar-links a:hover { color: #fff; }
@media (max-width: 860px) {
  .topbar { display: none !important; }
}
@media (max-width: 767px) {
  .container { padding-inline: 16px !important; }
}

/* ── Header ──────────────────────────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 200;
  background: rgba(255, 255, 255, .78);
  background: var(--chrome-header-bg, rgba(255, 255, 255, .78));
  -webkit-backdrop-filter: saturate(185%) blur(20px);
  backdrop-filter: saturate(185%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: box-shadow .25s ease, border-color .25s ease, background .25s ease;
}
/* Glass once the page scrolls under it */
.site-header.is-stuck {
  border-bottom-color: var(--chrome-line);
  box-shadow: 0 10px 30px rgba(15, 27, 51, .08);
}
.header-inner {
  display: flex; align-items: center; gap: 12px;
  height: var(--chrome-header-h);
}

.brand-premium { display: inline-flex; align-items: center; text-decoration: none; flex-shrink: 0; }
.brand-mark { display: block; object-fit: contain; }
.brand-logo { display: block; height: 38px; width: auto; max-width: 190px; object-fit: contain; }
@media (max-width: 640px) { .brand-logo { height: 32px; max-width: 150px; } }
.site-footer .brand-logo { height: 42px; filter: brightness(0) invert(1); opacity: .95; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-premium-name { font-family: 'Poppins', system-ui, sans-serif; font-size: 19px; font-weight: 700; color: var(--chrome-ink); letter-spacing: -.01em; }
.brand-premium-tag { font-size: 9.5px; letter-spacing: .16em; text-transform: uppercase; color: var(--chrome-ink-soft); font-weight: 600; }

/* Primary nav */
.main-nav { display: none; align-items: center; gap: 0; margin-left: 14px; flex: 1; }
@media (min-width: 1180px) { .main-nav { display: flex; } }
.main-nav .nav-link,
.nav-mega-trigger {
  display: inline-flex; align-items: center; gap: 3px;
  padding: 9px 11px; border-radius: 10px;
  font-family: inherit; font-size: 13.5px; font-weight: 500; letter-spacing: -0.005em;
  color: var(--chrome-ink-soft); background: none; border: 0; cursor: pointer;
  text-decoration: none; white-space: nowrap;
  transition: color .16s ease, background .16s ease;
}
.main-nav .nav-link:hover,
.nav-mega-trigger:hover,
.nav-mega-item.is-open .nav-mega-trigger { color: var(--chrome-brand); background: var(--chrome-brand-soft); }
.main-nav .nav-link[aria-current="page"] { color: var(--chrome-brand); }
.nav-chev { width: 16px; height: 16px; transition: transform .2s ease; }
.nav-mega-item.is-open .nav-chev { transform: rotate(180deg); }

/* ── Compact mega menu (anchored, never full width) ───────────────────── */
.nav-mega-item { position: relative; }
.mega-dropdown {
  position: absolute; top: calc(100% + 10px); left: 0;
  transform: translateY(8px);
  width: min(560px, calc(100vw - 24px));
  padding: 14px;
  border-radius: 18px;
  background: #ffffff;
  background: var(--color-surface-container-lowest, #ffffff);
  border: 1px solid rgba(15, 27, 51, .08);
  box-shadow: 0 26px 60px rgba(15, 27, 51, .18), 0 2px 8px rgba(15, 27, 51, .06);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .18s ease, transform .18s ease, visibility .18s;
  z-index: 210;
}
.nav-mega-item.is-open .mega-dropdown { opacity: 1; visibility: visible; pointer-events: auto; transform: translateY(0); }
.mega-dropdown::before {
  content: ''; position: absolute; top: -6px; left: 22px; width: 12px; height: 12px;
  transform: rotate(45deg);
  background: inherit; border-left: 1px solid rgba(15, 27, 51, .08); border-top: 1px solid rgba(15, 27, 51, .08);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  .mega-dropdown { background: var(--color-surface-container-lowest); }
}
.mega-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: 12px;
  padding: 2px 6px 12px; margin-bottom: 8px;
  border-bottom: 1px solid rgba(15, 27, 51, .07);
}
.mega-head strong { display: block; font-size: 14px; color: var(--chrome-ink); font-weight: 700; }
.mega-head span { display: block; font-size: 12px; color: var(--chrome-ink-soft); margin-top: 2px; }
.mega-head-link {
  display: inline-flex; align-items: center; gap: 4px; white-space: nowrap;
  font-size: 12.5px; font-weight: 700; color: var(--chrome-brand); text-decoration: none;
}
.mega-head-link:hover { text-decoration: underline; }
.mega-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
.mega-card {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px; border-radius: 12px;
  text-decoration: none; color: inherit;
  transition: background .16s ease, transform .16s ease;
}
.mega-card:hover { background: var(--color-surface-container-lowest); transform: translateX(2px); box-shadow: 0 6px 18px rgba(15, 27, 51, .08); }
.mega-card-icon {
  width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--chrome-brand-soft); color: var(--chrome-brand);
  transition: background .16s ease, color .16s ease;
}
.mega-card:hover .mega-card-icon { background: var(--chrome-brand); color: #fff; }
.mega-card-text b { display: block; font-size: 13px; font-weight: 600; color: var(--chrome-ink); line-height: 1.25; }
.mega-card-text span { display: block; font-size: 11px; color: var(--chrome-ink-soft); margin-top: 1px; }

/* ── Header actions ──────────────────────────────────────────────────── */
.header-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.icon-action {
  width: 40px; height: 40px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  color: var(--chrome-ink-soft); border: 1px solid var(--chrome-line);
  background: var(--color-surface-container-lowest); text-decoration: none;
  transition: color .16s ease, border-color .16s ease, background .16s ease, transform .16s ease;
}
.icon-action:hover { color: var(--chrome-brand); border-color: var(--chrome-brand); background: var(--chrome-brand-soft); transform: translateY(-1px); }
.btn-get-started {
  display: inline-flex; align-items: center; gap: 7px;
  height: 40px; padding: 0 16px; border-radius: 12px;
  background: var(--chrome-brand); color: #fff;
  font-size: 14px; font-weight: 700; text-decoration: none;
  box-shadow: 0 8px 20px rgba(26, 86, 219, .28);
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.btn-get-started:hover { background: #1447c0; transform: translateY(-1px); box-shadow: 0 12px 26px rgba(26, 86, 219, .34); }

.nav-toggle {
  width: 42px; height: 42px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--chrome-line); background: var(--color-surface-container-lowest); color: var(--chrome-ink);
  cursor: pointer; position: relative;
}
@media (min-width: 1180px) { .nav-toggle { display: none; } }
.nav-toggle .nav-toggle-icon { display: inline-flex; transition: opacity .18s ease, transform .18s ease; }
.nav-toggle .nav-toggle-close { position: absolute; opacity: 0; transform: rotate(-90deg) scale(.7); }
.nav-toggle[aria-expanded="true"] .nav-toggle-icon:not(.nav-toggle-close) { opacity: 0; transform: rotate(90deg) scale(.7); }
.nav-toggle[aria-expanded="true"] .nav-toggle-close { opacity: 1; transform: rotate(0) scale(1); }

/* ── Mobile drawer ───────────────────────────────────────────────────── */
.mobile-drawer { position: fixed; inset: 0; z-index: 400; visibility: hidden; pointer-events: none; }
.mobile-drawer[data-open="true"] { visibility: visible; pointer-events: auto; }
.drawer-backdrop {
  position: absolute; inset: 0; background: rgba(9, 16, 30, .5);
  -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  opacity: 0; transition: opacity .26s ease;
}
.mobile-drawer[data-open="true"] .drawer-backdrop { opacity: 1; }
.drawer-panel {
  position: absolute; top: 0; left: 0; right: auto; bottom: 0;
  width: min(288px, 78vw);
  display: flex; flex-direction: column;
  background: var(--color-surface-container-lowest);
  box-shadow: 16px 0 40px rgba(9, 16, 30, .22);
  transform: translateX(-100%);
  transition: transform .32s cubic-bezier(.22, 1, .36, 1);
}
.mobile-drawer[data-open="true"] .drawer-panel { transform: translateX(0); }
.drawer-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--chrome-line);
}
.drawer-close {
  width: 40px; height: 40px; border-radius: 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--chrome-line); background: var(--color-surface-container-lowest); color: var(--chrome-ink); cursor: pointer;
}
.drawer-close:hover { background: var(--chrome-brand-soft); color: var(--chrome-brand); }
.drawer-scroll { flex: 1; overflow-y: auto; padding: 0 0 12px; -webkit-overflow-scrolling: touch; }
.drawer-link, .drawer-group-trigger {
  display: flex; align-items: center; gap: 12px; width: 100%;
  padding: 12px 10px; border-radius: 0;
  font-family: inherit; font-size: 15px; font-weight: 600; color: var(--chrome-ink);
  background: none; border: 0; text-decoration: none; cursor: pointer; text-align: left;
  border-bottom: 1px solid var(--chrome-line);
}
.drawer-link:active, .drawer-group-trigger:active { background: var(--chrome-brand-soft); }
.drawer-link:hover, .drawer-group-trigger:hover { background: var(--color-surface-container-low); }
.drawer-item-icon {
  width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--chrome-brand-soft); color: var(--chrome-brand);
}
.drawer-group-trigger { justify-content: space-between; }
.drawer-group-trigger > .drawer-item-icon { flex: 0 0 auto; }
.drawer-group-trigger > span:not(.drawer-item-icon) { flex: 1; text-align: left; }
.drawer-chev { transition: transform .2s ease; color: var(--chrome-ink-soft); }
.drawer-group.is-open .drawer-chev { transform: rotate(180deg); }
.drawer-group-body { display: none; padding: 2px 0 8px 8px; }
.drawer-group.is-open .drawer-group-body { display: block; animation: drawerIn .22s ease; }
@keyframes drawerIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
.drawer-group-body a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 10px;
  font-size: 14px; font-weight: 500; color: var(--chrome-ink); text-decoration: none;
}
html[data-theme="dark"] .drawer-group-body a { color: #e8eefc; }
html[data-theme="dark"] .drawer-group-body a .drawer-item-icon {
  background: rgba(255, 255, 255, .12); color: #fff;
}
.drawer-group-body a:hover { background: var(--color-surface-container-low); color: var(--chrome-brand); }
.drawer-group-all { font-weight: 700 !important; color: var(--chrome-brand) !important; font-size: 13px !important; }
.drawer-foot {
  padding: 14px 16px calc(14px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--chrome-line);
  display: flex; flex-direction: column; gap: 8px;
  background: var(--color-surface-container-low);
}
.drawer-call {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-size: 13px; font-weight: 600; color: var(--chrome-ink-soft); text-decoration: none; padding-top: 4px;
}

/* ── Mobile bottom tab bar ───────────────────────────────────────────── */
.bottom-nav {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 180;
  display: none;
  background: rgba(255, 255, 255, .88);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-top: 1px solid rgba(15, 27, 51, .08);
  padding-bottom: env(safe-area-inset-bottom);
  box-shadow: 0 -8px 26px rgba(15, 27, 51, .08);
}
@media (max-width: 1179px) {
  .bottom-nav { display: grid; grid-template-columns: repeat(5, 1fr); }
  body.has-site-chrome { padding-bottom: 68px; }
}
.bottom-nav a {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
  padding: 9px 4px 8px;
  font-size: 10.5px; font-weight: 600; color: var(--chrome-ink-soft); text-decoration: none;
  transition: color .16s ease;
}
.bottom-nav a .icon { font-size: 21px; }
.bottom-nav a:active { color: var(--chrome-brand); }
.bottom-nav a[aria-current="page"] { color: var(--chrome-brand); }

/* ── Footer ──────────────────────────────────────────────────────────── */
.site-footer {
  background: #0d1526; color: rgba(255, 255, 255, .72);
  padding: 56px 0 28px; margin-top: 64px;
}
.site-footer .footer-grid {
  display: grid; gap: 28px 18px;
  grid-template-columns: 1fr 1fr;
}
.site-footer .footer-brand { grid-column: 1 / -1; }
@media (min-width: 1024px) {
  .site-footer .footer-grid { grid-template-columns: 1.6fr repeat(4, 1fr); gap: 32px; }
  .site-footer .footer-brand { grid-column: auto; }
}
.site-footer .brand-premium-name { color: #fff; }
.site-footer .brand-premium-tag { color: rgba(255, 255, 255, .5); }
.site-footer .footer-brand p { font-size: 13.5px; line-height: 1.65; margin: 14px 0 16px; max-width: 320px; }
.footer-contact { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.footer-contact li { display: flex; align-items: flex-start; gap: 9px; font-size: 13px; }
.footer-contact .icon { color: #34d399; margin-top: 2px; flex-shrink: 0; }
.footer-contact a { color: rgba(255, 255, 255, .82); text-decoration: none; }
.footer-contact a:hover { color: #fff; text-decoration: underline; }
.site-footer h4 { color: #fff; font-size: 14px; font-weight: 700; margin: 0 0 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 9px; }
.site-footer ul a { color: rgba(255, 255, 255, .68); font-size: 13.5px; text-decoration: none; transition: color .16s ease; }
.site-footer ul a:hover { color: #fff; }
.site-footer .footer-bottom {
  margin-top: 36px; padding-top: 20px; border-top: 1px solid rgba(255, 255, 255, .1);
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
  font-size: 12.5px; color: rgba(255, 255, 255, .5);
}
.site-footer .legal { display: flex; gap: 18px; flex-wrap: wrap; }
.site-footer .legal a { color: rgba(255, 255, 255, .6); text-decoration: none; }
.site-footer .legal a:hover { color: #fff; }
.site-footer .social-links { display: flex; gap: 8px; }
.site-footer .social-links a {
  width: 36px; height: 36px; border-radius: 11px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid rgba(255, 255, 255, .14); color: rgba(255, 255, 255, .8);
  transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
}
.site-footer .social-links a:hover { background: var(--chrome-brand); border-color: transparent; color: #fff; transform: translateY(-2px); }
.site-footer .social-links svg.icon { fill: currentColor; stroke: none; font-size: 17px; }

/* ── WhatsApp float widget ───────────────────────────────────────────── */
.wa-widget {
  position: fixed; right: 18px; z-index: 190;
  bottom: 18px;
  display: flex; flex-direction: column; align-items: flex-end; gap: 10px;
}
@media (max-width: 1179px) { .wa-widget { bottom: calc(78px + env(safe-area-inset-bottom)); right: 14px; } }
.wa-bubble {
  position: relative;
  max-width: 250px; padding: 12px 30px 12px 14px;
  background: var(--color-surface-container-lowest); color: var(--color-on-surface);
  border-radius: 14px 14px 4px 14px;
  border: 1px solid var(--chrome-line);
  box-shadow: var(--chrome-shadow);
  font-size: 13px; line-height: 1.5;
  animation: waIn .35s ease both .8s;
}
@keyframes waIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.wa-bubble-close {
  position: absolute; top: 6px; right: 6px;
  width: 22px; height: 22px; border-radius: 50%;
  border: 0; background: none; color: #94a3b8; cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
}
.wa-bubble-close:hover { background: var(--color-surface-container); color: var(--color-on-surface); }
.wa-btn {
  display: inline-flex; align-items: center; gap: 9px;
  height: 54px; padding: 0 18px; border-radius: 27px;
  background: #25d366; color: #fff; text-decoration: none;
  font-weight: 700; font-size: 14px;
  box-shadow: 0 12px 28px rgba(37, 211, 102, .38);
  transition: transform .18s ease, box-shadow .18s ease;
}
.wa-btn:hover { transform: translateY(-2px); box-shadow: 0 16px 34px rgba(37, 211, 102, .46); }
.wa-btn .icon { font-size: 26px; fill: currentColor; stroke: none; }
@media (max-width: 560px) {
  .wa-btn { height: 52px; width: 52px; padding: 0; justify-content: center; border-radius: 50%; }
  .wa-btn-label { display: none; }
}

/* Active menu item gets a quiet underline instead of a heavy weight */
.main-nav .nav-link { position: relative; }
.main-nav .nav-link[aria-current="page"]::after {
  content: ''; position: absolute; left: 11px; right: 11px; bottom: 2px;
  height: 2px; border-radius: 2px; background: var(--chrome-brand);
}
.nav-mega-item.is-open .nav-mega-trigger,
.main-nav .nav-link:hover { background: var(--chrome-brand-soft); }
.mega-dropdown { padding: 16px; }
.mega-grid { gap: 6px; }

/* ── Drawer polish: an app-style panel, opening from the left ──────────── */
.drawer-head { gap: 10px; }
.drawer-head .brand-logo { height: 30px; }
.drawer-scroll { padding: 4px 8px 16px; }
.drawer-link, .drawer-group-trigger { font-size: 14.5px; padding: 12px 12px; }
.drawer-group { border-bottom: 1px solid var(--chrome-line); }
.drawer-group-trigger { border-bottom: 0; }
.drawer-group-body a { border-bottom: 1px solid var(--chrome-line); }
.drawer-group.is-open { background: var(--chrome-brand-soft); }
.drawer-group.is-open > .drawer-group-trigger { color: var(--chrome-brand); }
.drawer-group-body { padding: 0; }
.drawer-group-body a { font-size: 13.5px; padding: 9px 10px; }
.drawer-group-body a .drawer-item-icon { width: 28px; height: 28px; }
.drawer-section-label {
  font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--chrome-ink-soft); padding: 10px 10px 4px; display: block;
  border-bottom: 1px solid var(--chrome-line);
}
.drawer-foot .btn { justify-content: center; }

/* Header actions: one auth button, one theme toggle, one menu button */
.header-actions { gap: 10px; }
.btn-get-started { gap: 8px; }
@media (max-width: 480px) { .btn-get-started span { display: none; } .btn-get-started { padding: 0 12px; } }

/* Shared header wins over layout.css / public-theme.css on every public page */
body.has-site-chrome .site-header .header-inner.container {
  height: var(--chrome-header-h) !important;
  justify-content: flex-start !important;
  gap: 12px !important;
  max-width: var(--container-max, 1180px);
}
body.has-site-chrome .nav-mega-item { position: relative !important; height: auto !important; }
body.has-site-chrome .mega-dropdown {
  left: 0 !important;
  right: auto !important;
  top: calc(100% + 10px) !important;
  width: min(560px, calc(100vw - 24px)) !important;
  transform: translateY(8px) !important;
  border-bottom: 0;
  border-radius: 18px;
}
body.has-site-chrome .nav-mega-item.is-open .mega-dropdown { transform: translateY(0) !important; }
body.has-site-chrome .mega-dropdown::before {
  left: 22px !important;
  transform: rotate(45deg) !important;
}
body.has-site-chrome .mobile-drawer .drawer-panel {
  left: 0 !important;
  right: auto !important;
  width: min(288px, 78vw) !important;
  padding: 0 !important;
  transform: translateX(-100%) !important;
  box-shadow: 16px 0 40px rgba(9, 16, 30, .22) !important;
}
body.has-site-chrome .mobile-drawer[data-open="true"] .drawer-panel {
  transform: translateX(0) !important;
}
@media (min-width: 1180px) {
  body.has-site-chrome .main-nav { display: flex !important; }
  body.has-site-chrome .nav-toggle { display: none !important; }
}
@media (max-width: 1179px) {
  body.has-site-chrome .main-nav { display: none !important; }
  body.has-site-chrome .nav-toggle { display: inline-flex !important; }
}

/* Sticky rails stay below the chrome on desktop; never pin over the page on phones */
.services-sidebar { top: calc(var(--chrome-topbar-h) + var(--chrome-header-h) + 12px) !important; align-self: start; }
.svc-pricing-sidebar { top: calc(var(--chrome-topbar-h) + var(--chrome-header-h) + 12px) !important; }
.svc-section-nav { top: calc(var(--chrome-header-h) + 8px) !important; }
.blog-toc, .blog-rail-sticky { top: calc(var(--chrome-topbar-h) + var(--chrome-header-h) + 12px) !important; }

@media (max-width: 1023px) {
  .svc-pricing-sidebar,
  .svc-section-nav {
    position: static !important;
    top: auto !important;
  }
}
@media (max-width: 1179px) {
  .blog-toc,
  .blog-rail-left .blog-toc,
  .blog-rail-sticky {
    position: static !important;
    top: auto !important;
  }
}

.services-filter-bar {
  display: none;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}
.services-filter-bar .results-inline { font-size: 13px; color: var(--chrome-ink-soft); }

@media (max-width: 1023px) {
  .services-filter-bar { display: flex; }
  .services-layout { display: block; }
  .filter-sheet-backdrop {
    position: fixed; inset: 0; z-index: 420;
    background: rgba(9, 16, 30, .45);
    -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
    opacity: 0; visibility: hidden; pointer-events: none;
    transition: opacity .22s ease, visibility .22s;
  }
  .filter-sheet-backdrop.is-open { opacity: 1; visibility: visible; pointer-events: auto; }
  .services-sidebar {
    position: fixed !important;
    top: 0 !important; left: 0; bottom: 0;
    width: min(360px, 92vw) !important;
    max-height: 100dvh;
    z-index: 430;
    margin: 0;
    border-radius: 0 18px 18px 0;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    transform: translateX(-105%);
    transition: transform .28s cubic-bezier(.22, 1, .36, 1);
    box-shadow: 18px 0 40px rgba(9, 16, 30, .22);
  }
  .services-sidebar.is-open { transform: translateX(0); }
  body.filter-sheet-open { overflow: hidden; }
}

@media (min-width: 1024px) {
  .services-filter-bar { display: none !important; }
  .filter-sheet-backdrop { display: none !important; }
}

/* ── Header profile menu (signed-in) ───────────────────────────────────── */
.header-profile { position: relative; }
.header-profile-btn {
  display: inline-flex; align-items: center; gap: 8px;
  height: 42px; padding: 0 10px 0 6px; border-radius: 12px;
  border: 1px solid var(--chrome-line); background: transparent;
  color: var(--chrome-ink); cursor: pointer; font-family: inherit;
}
.header-profile-btn:hover { background: var(--chrome-brand-soft); border-color: var(--chrome-brand); }
.header-profile-btn img { border-radius: 50%; display: block; }
/* The chip is one line per row and never wraps: a long role label is trimmed
   rather than pushing the header taller. */
.header-profile-meta {
  display: flex; flex-direction: column; justify-content: center;
  line-height: 1.2; text-align: left; min-width: 0; max-width: 132px;
}
.header-profile-meta strong,
.header-profile-meta span {
  display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.header-profile-meta strong { font-size: 13px; font-weight: 500; }
.header-profile-meta span { font-size: 10.5px; color: var(--chrome-ink-soft); }
.header-profile-btn img { width: 34px; height: 34px; object-fit: cover; flex-shrink: 0; }
.header-profile-btn .icon { flex-shrink: 0; }
.header-profile-panel {
  position: absolute; top: calc(100% + 8px); right: 0;
  min-width: 232px; padding: 6px;
  border-radius: 14px;
  background: var(--color-surface-container-lowest, #fff);
  border: 1px solid var(--chrome-line);
  box-shadow: 0 18px 44px rgba(15, 27, 51, .16);
  z-index: 220;
}
.header-profile-head { padding: 10px 12px 12px; border-bottom: 1px solid var(--chrome-line); margin-bottom: 6px; }
.header-profile-head strong { display: block; font-size: 13.5px; }
.header-profile-head span { display: block; font-size: 11.5px; color: var(--chrome-ink-soft); overflow: hidden; text-overflow: ellipsis; }
.header-profile-panel a, .header-profile-signout {
  display: flex; align-items: center; gap: 9px; width: 100%;
  padding: 9px 12px; border-radius: 10px;
  font-size: 13.5px; color: var(--chrome-ink); text-decoration: none;
  background: none; border: 0; cursor: pointer; font-family: inherit; text-align: left;
}
.header-profile-panel a:hover, .header-profile-signout:hover { background: var(--chrome-brand-soft); color: var(--chrome-brand); }
.header-profile-signout { color: #dc2626; margin-top: 4px; border-top: 1px solid var(--chrome-line); border-radius: 0 0 10px 10px; }
@media (max-width: 1179px) {
  .header-profile-btn { height: 40px; padding: 0 4px; border: 0; }
  /* Bottom tab bar already has Sign in — hide the header login tile on phones/tablets */
  body.has-site-chrome .site-header .btn-get-started,
  .site-header .hide-on-mobile-header { display: none !important; }
}

/* Drawer: calmer spacing */
.drawer-scroll { padding: 4px 6px 14px; }
.drawer-link, .drawer-group-trigger { padding: 10px 10px; font-size: 14px; gap: 10px; }
.drawer-item-icon { width: 30px; height: 30px; border-radius: 9px; }
.drawer-section-label { padding: 12px 10px 4px; }
.drawer-group-body { padding: 0 2px 4px 4px; }
.drawer-group-body a { padding: 8px 10px; font-size: 13px; gap: 8px; }
.drawer-head { padding: 12px 14px; }
.drawer-foot { padding: 12px 14px calc(12px + env(safe-area-inset-bottom)); gap: 6px; }

/* Light theme: primary buttons stay brand-blue on hover (not pale container color) */
html:not([data-theme="dark"]) .btn-primary:hover,
html:not([data-theme="dark"]) .btn-get-started:hover {
  background: #1447c0 !important;
  color: #fff !important;
}
html:not([data-theme="dark"]) .cta-panel .btn-primary:hover,
html:not([data-theme="dark"]) .blog-cta .btn-primary:hover,
html:not([data-theme="dark"]) .support-band .btn-primary:hover,
html:not([data-theme="dark"]) .hub-cta .btn-primary:hover,
html:not([data-theme="dark"]) .hub-cta-primary:hover {
  background: #ffffff !important;
  color: #0f1b33 !important;
}

@media (max-width: 700px) {
  .cta-panel-actions, .blog-cta-actions, .support-band-actions, .hub-cta-actions, .site-cta-actions, .hero-actions {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 10px;
  }
  .cta-panel-actions .btn,
  .blog-cta-actions .btn,
  .support-band-actions .btn,
  .hub-cta-actions .btn,
  .hub-cta-actions a.btn,
  .site-cta-actions .btn,
  .hero-actions .btn {
    width: 100%;
    justify-content: center;
    white-space: normal;
    height: auto;
    min-height: 48px;
    padding: 12px 16px;
    box-sizing: border-box;
  }
  .cta-panel, .blog-cta, .support-band, .hub-cta, .site-cta-inner {
    padding: 22px 18px;
    border-radius: 18px;
  }
  /* the band is inside .container, but keep a floor of its own so it can
     never sit flush against the screen edge */
  .site-cta { padding-inline: 16px; }
  .site-cta > .container { padding-inline: 0; }
  .blog-cta, .cta-panel, .support-band { margin-inline: 0; }
}

@media (max-width: 719px) {
  .site-footer { padding: 32px 0 20px; margin-top: 36px; }
  .site-footer .footer-grid { gap: 22px 16px; }
  .site-footer .footer-brand p { margin: 10px 0 12px; }
  .site-footer h4 { margin: 0 0 8px; }
  .site-footer ul { gap: 7px; }
  .site-footer .footer-bottom {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 12px;
    margin-top: 24px;
    padding-top: 16px;
  }
  .site-footer .footer-copy { display: block; width: 100%; text-align: center; }
  .site-footer .legal { justify-content: center; gap: 10px 14px; width: 100%; }
}

/* Drawer level two: a service category inside the Services group */
.drawer-group-root > .drawer-group-body { padding-left: 0; }
.drawer-group-root .drawer-group { border-bottom: 0; }
.drawer-group-root .drawer-group-trigger { padding-left: 26px; font-size: 14px; }
.drawer-group-root .drawer-group-body a { padding-left: 42px; }
.drawer-group-root .drawer-group.is-open { background: transparent; }
.drawer-group-root .drawer-group-all { padding-left: 42px; }
