/* Mobile-only site navigation; original desktop headers remain intact. */
.mobile-header-bar{display:none}
.mobile-chapter-strip{display:none}
.mobile-drawer{box-sizing:border-box;position:fixed;inset:0 auto 0 0;margin:0;width:min(340px,88vw);max-width:100%;height:100%;height:100dvh;max-height:100%;border:0;border-right:1px solid #ced9d3;padding:0 20px calc(20px + env(safe-area-inset-bottom));background:#f8faf5;color:#173f37;font-family:system-ui,'Microsoft JhengHei',sans-serif;overflow-y:auto;overscroll-behavior:contain;box-shadow:12px 0 40px #0003}
.mobile-drawer::backdrop{background:#07192399}
.mobile-drawer-top{display:flex;align-items:center;justify-content:space-between;gap:12px;position:sticky;top:0;padding:18px 0 12px;background:#f8faf5;border-bottom:1px solid #d6e0d8;z-index:1}
.mobile-drawer-top strong{font-size:20px;letter-spacing:.02em}
.mobile-menu-close{font:400 30px/1 system-ui;background:transparent;color:#173f37;border:1px solid #bccfc5;border-radius:6px;width:44px;height:44px;padding:0;cursor:pointer}
.mobile-drawer nav{display:flex;flex-direction:column;padding-top:10px}
.mobile-drawer nav h2{font:800 14px/1.6 system-ui;margin:24px 0 10px;color:#637a70;letter-spacing:.06em}
.mobile-drawer nav a{display:block;font-size:17px;font-weight:700;line-height:1.6;padding:12px 14px;color:#173f37;text-decoration:none;border-radius:6px;overflow-wrap:anywhere}
.mobile-drawer nav a[aria-current=page]{background:#173f37;color:#fff}
.mobile-drawer nav a.mobile-chapter-link{font-size:15px;font-weight:650}
.mobile-drawer a:focus-visible,.mobile-drawer button:focus-visible,.mobile-header-bar a:focus-visible,.mobile-header-bar button:focus-visible{outline:3px solid #59927b;outline-offset:2px}
@media(max-width:780px){
 body>header.has-mobile-navigation{position:sticky!important;top:0!important;display:block!important;height:60px!important;min-height:60px!important;padding:0!important;z-index:100!important;background:#f8faf5!important;color:#173f37!important;border-bottom:1px solid #ced9d3;backdrop-filter:none!important}
 body>header.has-mobile-navigation>:not(.mobile-header-bar){display:none!important}
 body>header.has-mobile-navigation>.mobile-header-bar{height:60px;display:flex!important;align-items:center;gap:12px;padding:0 16px!important;box-sizing:border-box}
 .mobile-menu-toggle{display:flex;flex-direction:column;justify-content:center;gap:5px;width:44px;height:44px;flex:0 0 44px;background:transparent!important;border:1px solid #c3d3c9!important;border-radius:6px;padding:10px!important;cursor:pointer;color:#173f37}
 .mobile-menu-toggle span{display:block;height:2px;width:22px;background:currentColor}
 .mobile-header-brand{font:850 17px/1.2 system-ui!important;letter-spacing:.07em;color:#173f37!important;text-decoration:none!important;white-space:nowrap}
 .mobile-header-label{font:650 12px/1.4 system-ui;color:#637a70;margin-left:auto;white-space:nowrap}
 html{scroll-padding-top:76px!important}
 main section[id],main article[id],section.section[id]{scroll-margin-top:76px!important}
}
@media(max-width:780px){
 body>header.has-mobile-navigation.has-chapter-strip{height:108px!important;min-height:108px!important}
 body>header.has-mobile-navigation.has-chapter-strip>.mobile-chapter-strip{display:flex!important;position:relative;align-items:stretch;height:48px;min-height:48px;max-width:100%;width:100%;box-sizing:border-box;overflow-x:auto;overflow-y:hidden;white-space:nowrap;gap:6px;margin:0;padding:0 12px;border-top:1px solid #e1e8df;background:#f8faf5;scrollbar-width:none;-webkit-overflow-scrolling:touch}
 .mobile-chapter-strip::-webkit-scrollbar{display:none}
 body>header .mobile-chapter-strip a{display:flex;align-items:center;flex:none;padding:0 12px;border-bottom:3px solid transparent;color:#526d61;font:650 14px/1.4 system-ui;text-decoration:none;white-space:nowrap}
 body>header .mobile-chapter-strip a[aria-current=location]{color:#173f37;font-weight:850;border-bottom-color:#347b63;background:#edf3ea}
 .mobile-chapter-strip a:focus-visible{outline:2px solid #347b63;outline-offset:-4px}
 html:has(header.has-chapter-strip){scroll-padding-top:124px!important}
 body:has(header.has-chapter-strip) main section[id],body:has(header.has-chapter-strip) main article[id],body:has(header.has-chapter-strip) section.section[id]{scroll-margin-top:0!important}
}
