/* Header V5: original navigation SVGs, V4 chrome unchanged. */
/* Desktop: remove the outer header's vertical padding; nav contents keep their existing dimensions. */
@media(min-width:861px){.ld-v4-header.ld-v5-header{padding-block:0;}}
.ld-v5-header .nav-links a {display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-height:60px;padding:4px 2px 6px;position:relative;text-decoration:none!important;}
.ld-v5-header .nav-links a svg {display:block;width:24px;height:24px;flex:none;fill:none;stroke:currentColor;stroke-width:1.9;stroke-linecap:round;stroke-linejoin:round;}
.ld-v5-header .nav-links a[aria-current="page"]::after {content:"";position:absolute;bottom:0;left:50%;transform:translateX(-50%);width:38px;height:3px;background:var(--ld-chrome-yellow);border-radius:3px;}
/* Center the search underline under the rendered label, retaining the shared 38×3px chrome style. */
@media(min-width:1101px){
 .ld-v4-header .nav-links a.ld-v5-search:is(:hover,:focus-visible,[aria-current="page"]){text-decoration:none;}
 .ld-v4-header .nav-links a.ld-v5-search:is(:hover,:focus-visible,[aria-current="page"])::after{content:"";position:absolute;bottom:0;left:50%;transform:translateX(-50%);width:38px;height:3px;background:var(--ld-chrome-yellow);border-radius:3px;}
}
@media(max-width:1100px){
 .ld-v5-header .ld-v4-nav{flex-wrap:wrap;}
 .ld-v5-header #menu-toggle{display:inline-grid;order:2;}
 .ld-v5-header #theme-toggle{order:3;}
 .ld-v5-header .nav-links{display:none;position:absolute;top:100%;left:0;right:0;width:100%;margin:0;padding:12px 20px;background:var(--ld-chrome-bg);box-shadow:0 8px 20px rgba(0,0,0,.18);}
 .ld-v5-header .nav-links.open,.ld-v5-header .nav-links[data-open="true"]{display:block;gap:4px;max-height:calc(100dvh - 112px);overflow-y:auto;}
 .ld-v5-header .nav-links ul{display:flex;flex-direction:column;align-items:stretch;gap:4px;}
 .ld-v5-header .nav-links li{width:100%;}
 .ld-v5-header .nav-links a {width:100%;flex-direction:row;justify-content:flex-start;gap:14px;min-height:48px;padding:8px 12px;border-radius:6px;}
 .ld-v5-header .nav-links a[aria-current="page"]{background:#123d48;}
 .ld-v5-header .nav-links a[aria-current="page"]::after{width:3px;height:24px;left:0;top:50%;bottom:auto;transform:translateY(-50%);}
 .ld-v5-header .nav-links a.ld-v5-search {border-left:0;border-top:1px solid var(--ld-chrome-line);padding:10px 12px 8px;}
}

/* Shared theme control: symmetric vector geometry, no glyph metrics. */
.ld-v4-header.ld-v5-header :is(#theme-toggle,.theme-toggle){display:grid;place-items:center;position:relative;padding:0;line-height:1;box-sizing:border-box}
.ld-v4-header.ld-v5-header :is(#theme-toggle,.theme-toggle) > .ld-theme-symbol{display:block;width:24px;height:24px;min-width:24px;max-width:none;flex:none;margin:0;padding:0;transform:none;align-self:center;justify-self:center;color:inherit}
body.dark .ld-theme-half,.ld-v4-header.ld-v5-header .ld-theme-half.is-dark{transform:rotate(180deg);transform-origin:12px 12px}
