.mobile-brand-name,
.mobile-menu-toggle { display: none; }
.mobile-menu-toggle,
.mobile-nav { -webkit-tap-highlight-color: transparent; }

html.mobile-navigation-open { overflow: hidden; }
.mobile-nav,
.mobile-nav *,
.mobile-nav *::before,
.mobile-nav *::after { box-sizing: border-box; }

.mobile-nav {
    position: fixed;
    inset: 0 auto auto max(0px, calc(100vw - 440px));
    width: min(440px, 100vw);
    height: 100dvh;
    max-width: none;
    max-height: none;
    margin: 0;
    padding: 0;
    border: 0;
    background: #fff;
    color: #323548;
    font-family: "DM-sans", Arial, sans-serif;
    box-shadow: -16px 0 60px #20233b26;
    overflow: hidden;
}

.mobile-nav:not([open]) { display: none; }
.mobile-nav[open] { display: flex; flex-direction: column; animation: mobile-nav-enter .22s ease-out; }
.mobile-nav::backdrop { background: #20233b66; backdrop-filter: blur(4px); }
.mobile-nav a { color: inherit; text-decoration: none; }
.mobile-nav button { font: inherit; cursor: pointer; }
.mobile-nav-header { flex-shrink: 0; display: flex; align-items: center; justify-content: space-between; min-height: 84px; padding: max(12px, env(safe-area-inset-top)) 24px 12px 16px; border-bottom: 1px solid #eeeef5; }
.mobile-nav-brand { display: inline-flex; align-items: center; gap: 5px; font-size: 22px; font-weight: 700; letter-spacing: .015em; color: #3e47f0 !important; }
.mobile-nav-brand img { display: block; flex-shrink: 0; width: 52px; height: 52px; object-fit: contain; }
.mobile-nav-close { display: grid; place-items: center; width: 44px; height: 44px; padding: 0; border: 1px solid #e8e7f1; border-radius: 50%; background: #f8f8fc; color: #515569; }
.mobile-nav-close svg { width: 21px; height: 21px; }
.mobile-nav-close:hover { background: #ececff; color: #3e47f0; }

.mobile-nav-scroll { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; scrollbar-color: #d8d8ee transparent; padding: 24px 24px 28px; }
.mobile-nav .mobile-nav-eyebrow { margin: 0 0 14px; font-size: 11px !important; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: #8a8c9d; }
.mobile-nav-links { display: flex; flex-direction: column; }
.mobile-nav-group,
.mobile-nav-link { border-bottom: 1px solid #eeeef5; }
.mobile-nav-group > summary,
.mobile-nav-link { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 56px; padding: 13px 0; font-size: 18px; font-weight: 600; line-height: 1.45; list-style: none; cursor: pointer; }
.mobile-nav-group > summary::-webkit-details-marker { display: none; }
.mobile-nav-chevron { flex: 0 0 18px; width: 18px; height: 18px; color: #a0a1b4; transition: transform .18s ease; }
.mobile-nav-group[open] > summary .mobile-nav-chevron { transform: rotate(90deg); }
.mobile-nav-group[open] > summary,
.mobile-nav-group.is-current > summary,
.mobile-nav-group > summary:hover,
.mobile-nav-link:hover,
.mobile-nav-link[aria-current] { color: #3e47f0; }
.mobile-nav-group.is-current > summary .mobile-nav-chevron { color: #3e47f0; }
.mobile-nav-children { display: flex; flex-direction: column; gap: 2px; padding: 0 0 12px; }
.mobile-nav-children > a,
.mobile-nav-unavailable { display: flex; align-items: center; min-height: 46px; padding: 11px 14px; border-left: 2px solid #e9e8f4; font-size: 14px; font-weight: 500; line-height: 1.5; }
.mobile-nav-children > a:hover { background: #f7f7fc; }
.mobile-nav-children > a[aria-current] { border-left-color: #3e47f0; border-radius: 0 8px 8px 0; background: #f0f0ff; color: #3e47f0; font-weight: 600; }
.mobile-nav-unavailable { justify-content: space-between; gap: 12px; color: #878998; }
.mobile-nav-unavailable small { flex-shrink: 0; padding: 3px 6px; border-radius: 4px; background: #f1f1f6; font-size: 10px; line-height: 1.4; }

.mobile-nav-footer { flex-shrink: 0; padding: 16px 24px max(16px, env(safe-area-inset-bottom)); border-top: 1px solid #eeeef5; background: #fafafe; }
.mobile-nav-contact { display: flex; align-items: center; justify-content: space-between; min-height: 48px; padding: 12px 16px; border-radius: 10px; background: #3e47f0; color: #fff !important; font-size: 14px; font-weight: 600; }
.mobile-nav-contact:hover { background: #3038cc; }
.mobile-nav-contact svg { width: 20px; height: 20px; }
.mobile-nav-utilities { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 12px; }
.mobile-nav-socials { display: flex; gap: 4px; }
.mobile-nav-socials a { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 8px; color: #646b91; font-size: 19px; }
.mobile-nav-socials a:hover { background: #ededfa; color: #3e47f0; }
.mobile-nav .mobile-nav-privacy { min-height: 44px; padding: 8px 0 8px 8px; border: 0; background: none; color: #747789; font-size: 12px; text-decoration: underline; text-underline-offset: 3px; }
.mobile-nav :focus-visible,
.mobile-menu-toggle:focus-visible { outline: 3px solid #ffb866; outline-offset: 3px; border-radius: 8px; }

@media screen and (max-width: 1260px) {
    .section.container:has(> .navbar) { position: sticky; top: 0; z-index: 40; width: 100%; max-width: none; border-bottom: 1px solid #eeeef5; background: #fff; }
    .navbar .navbar-brand { align-items: center; justify-content: space-between; min-height: 76px; padding: 0 20px 0 8px; }
    .navbar .site-brand { display: flex; align-items: center; gap: 2px; padding: 0; }
    .navbar .site-brand img { width: 64px; height: 64px; }
    .mobile-brand-name { display: inline; color: #3e47f0; font-size: 21px; font-weight: 700; letter-spacing: .015em; }
    .mobile-menu-toggle { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-width: 94px; height: 44px; padding: 0 14px; border: 1px solid #dedfeb; border-radius: 12px; background: #fff; color: #414661; font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
    .mobile-menu-toggle:hover { background: #f4f3fc; border-color: #c8cbed; }
    .mobile-menu-toggle svg { width: 20px; height: 20px; }
}

@media screen and (min-width: 1261px) {
    .mobile-nav { display: none !important; }
}

@media (max-width: 360px), (max-height: 540px) {
    .mobile-nav-header { min-height: 72px; padding-block: 8px; }
    .mobile-nav-scroll { padding: 16px 20px 20px; }
    .mobile-nav-footer { padding: 12px 20px max(12px, env(safe-area-inset-bottom)); }
    .mobile-nav-group > summary, .mobile-nav-link { min-height: 52px; font-size: 17px; }
}

@keyframes mobile-nav-enter {
    from { opacity: 0; transform: translateX(24px); }
    to { opacity: 1; transform: translateX(0); }
}

@media (prefers-reduced-motion: reduce) {
    .mobile-nav[open] { animation: none; }
    .mobile-nav-chevron { transition: none; }
}
