/* Only loaded on explicitly selected pages. If wp_body_open is missing, leave old header visible. */
body:has(> .tanba-site-header) .elementor-location-header,
body:has(> .tanba-site-header) header#site-header,
body:has(> .tanba-site-header) header.site-header.dynamic-header { display:none !important; }
.tanba-site-header,.tanba-site-header *,.tanba-site-drawer,.tanba-site-drawer * { box-sizing:border-box; }
.tanba-site-header { width:100%; height:100px; background:#fff url('../images/ta-header.webp') center center/cover no-repeat; }
body:has(> .tanba-site-header--top) { position:relative; }
body > .tanba-site-header--top { position:absolute; inset:0 0 auto; z-index:21; background:transparent; }
.tanba-site-header__inner { width:min(1120px, calc(100% - 40px)); height:100%; margin:auto; display:flex; justify-content:space-between; align-items:center; gap:20px; }
.tanba-site-header__logo { display:block; width:min(340px, 65%); line-height:0; }
.tanba-site-header__logo img { display:block; width:100%; height:auto; }
.tanba-site-header a.tanba-site-header__access,.tanba-site-drawer a.tanba-site-drawer__access { display:flex; justify-content:center; align-items:center; min-height:42px; width:280px; max-width:100%; padding:7px 12px; gap:8px; border:1px solid #8cbc57; border-radius:999px; font-size:16px; font-weight:700; line-height:1.4; color:#456331; background:#ffffff; text-decoration:none; white-space:nowrap; }
.tanba-site-header a.tanba-site-header__access:hover,.tanba-site-drawer a.tanba-site-drawer__access:hover { background:#e2efcf; color:#365322; }
.tanba-site-header button.tanba-site-header__menu { display:none; }
.tanba-site-drawer[hidden],.tanba-site-drawer-overlay[hidden] { display:none !important; }
.tanba-site-header :focus-visible,.tanba-site-drawer :focus-visible { outline:3px solid #557b38; outline-offset:3px; }
.tanba-site-drawer-overlay { position:fixed; inset:0; z-index:1090; background:rgba(20,38,17,.45); }
.tanba-site-drawer { position:fixed; inset:0 0 0 auto; z-index:1100; width:min(88vw,390px); display:flex; flex-direction:column; background:#fff; color:#3f4741; box-shadow:-10px 0 28px rgba(28,55,19,.16); }
.tanba-site-drawer__head { display:flex; align-items:center; justify-content:space-between; min-height:70px; padding:12px 16px; border-bottom:1px solid #b4d18e; background:#eff5e6; font-size:18px; }
.tanba-site-drawer button.tanba-site-drawer__close { width:44px; height:44px; border:0; padding:0; border-radius:0; background:transparent; color:#3f5c30; font-size:32px; line-height:1; cursor:pointer; }
.tanba-site-drawer__body { padding:16px; overflow-y:auto; min-height:0; flex:1; }
.tanba-access-pin,.tanba-access-arrow { display:block; flex:none; width:18px; height:18px; color:#557b38; }
.tanba-access-arrow { width:14px; height:14px; }
.tanba-site-drawer a.tanba-site-drawer__access { width:calc((100% - 10px)/2); margin:18px auto 0; min-height:42px; padding:7px 5px; gap:4px; font-size:14px; }
.tanba-site-drawer .tanba-access-pin { width:16px; height:16px; }
.tanba-site-drawer .tanba-access-arrow { width:12px; height:12px; }
.tanba-site-drawer__body h2 { margin:14px 0 10px; font-size:16px; line-height:1.5; color:#3f5c30; border-left:4px solid #8cbc57; padding-left:8px; }
.tanba-site-drawer__links { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.tanba-site-drawer__links a { display:flex; align-items:center; min-width:0; }
.tanba-site-drawer__links img { display:block; width:100%; height:auto; }
body.tanba-site-drawer-open { overflow:hidden; }
@media (max-width:1023px) {
 .tanba-site-header__inner { width:calc(100% - 32px); gap:10px; }
 .tanba-site-header__logo { width:min(330px,62vw); min-width:0; flex:0 1 auto; }
 .tanba-site-header a.tanba-site-header__access { display:none; }
 .tanba-site-header button.tanba-site-header__menu { display:inline-flex; flex-direction:row; align-items:center; justify-content:center; min-height:44px; padding:8px 13px; gap:8px; border:2px solid #456331; border-radius:14px; background:rgba(255,255,255,.92); color:#456331; font-family:inherit; font-size:14px; font-weight:700; line-height:1; white-space:nowrap; cursor:pointer; flex:none; }
 .tanba-site-header button.tanba-site-header__menu:is(:hover,:focus,:active) { background:rgba(255,255,255,.92); color:#456331; }
 .tanba-site-header__bars { width:18px; flex:none; display:grid; gap:3px; }
 .tanba-site-header__bars span { display:block; width:100%; height:2px; background:currentColor; border-radius:999px; }
}
@media (max-width:767px) {
 .tanba-site-header { height:80px; }
 .tanba-site-header__inner { width:calc(100% - 26px); }
 .tanba-site-header__logo { width:min(290px,66vw); }
 .tanba-site-header button.tanba-site-header__menu { padding:8px 11px; border-radius:12px; font-size:13px; }
}
@media (min-width:1024px) { .tanba-site-drawer,.tanba-site-drawer-overlay { display:none !important; } }

/* Utility navigation: independent from saved page content. */
.tanba-utility-nav { display:grid; gap:10px; width:100%; min-width:0; }
.tanba-utility-nav a.tanba-utility-link { box-sizing:border-box; display:flex; align-items:center; justify-content:space-between; gap:8px; width:100%; min-height:48px; padding:10px 14px; border:1px solid #8CBC57; border-radius:10px; background:#fff; color:#3F5C30; font-size:16px; font-weight:700; line-height:1.5; text-decoration:none; overflow-wrap:anywhere; }
.tanba-utility-nav a.tanba-utility-link:is(:hover,:focus-visible) { background:#EFF6E8; color:#3F5C30; border-color:#557B38; text-decoration:none; }
.tanba-utility-nav a.tanba-utility-link:focus-visible { outline:2px solid #557B38; outline-offset:2px; }
.tanba-utility-link > span:last-child { flex:none; font-size:22px; line-height:1; }

.tanba-site-header__utility { display:flex; align-items:center; gap:12px; }
.tanba-site-drawer .tanba-utility-nav { margin-top:18px; }
@media(max-width:1023px) { .tanba-site-header__utility { display:none; } }
@media print { .tanba-site-header__utility { display:none!important; } }
