body{margin:0;font-family:Arial,"Noto Sans JP",sans-serif;color:#333}
.site-header{background:#000e59;color:#fff;padding:16px 20px 0;border-bottom:1px solid #ddd}
.site-brand{display:flex;align-items:baseline;gap:5px 14px;flex-wrap:wrap}
.site-brand h1{margin:0;font-size:22px}
.site-brand h1 a{color:inherit;text-decoration:none}
.site-brand p{margin:0;color:inherit;font-size:13px}
.global-nav{margin-top:14px}
.global-nav ul{display:flex;align-items:center;justify-content:flex-end;gap:0 22px;flex-wrap:wrap;list-style:none;margin:0;padding:0}
.global-nav a{display:block;padding:10px 0;color:inherit;text-decoration:none;font-size:13px;white-space:nowrap}
.global-nav a:hover{text-decoration:underline;text-underline-offset:4px}
.global-nav a[aria-current="page"]{font-weight:700;text-decoration:underline;text-underline-offset:4px}
#operationGuide{padding:12px 20px 4px;color:#666;font-size:13px;line-height:1.65;background:#fafafa}
#operationGuide p{margin:0}
#addressSearch{padding:8px 20px 12px;background:#fafafa;border-bottom:1px solid #ddd}
#addressSearchForm{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
#addressSearchForm label{font-size:13px;font-weight:bold}
#addressSearchInput{box-sizing:border-box;width:min(360px,70vw);padding:8px 10px;border:1px solid #aaa;border-radius:4px;font-size:14px}
#addressSearchForm button{padding:8px 16px;border:1px solid #777;border-radius:4px;background:#fff;cursor:pointer}
#addressSearchForm button:disabled{cursor:wait;opacity:0.6}
#addressSearchStatus{margin-top:6px;color:#555;font-size:12px;min-height:1.4em}
#map{width:100%;height:62vh;min-height:420px;background:#eee}
#mapLayerControls{padding:10px 20px;background:#fff;border-top:1px solid #ddd;font-size:13px}
#mapLayerControls .layer-options{display:flex;align-items:center;gap:8px 18px;flex-wrap:wrap}
#mapLayerControls label{white-space:nowrap}
#mapLayerHelp{margin:8px 0 0;color:#666;font-size:12px;line-height:1.5}
#legendPanel{padding:0 20px 12px;background:#fff;border-bottom:1px solid #ddd}
#legendToggle{padding:4px 12px;border:1px solid #888;border-radius:4px;background:#fff;cursor:pointer;font-size:12px}
#legendContent{margin-top:8px;max-height:260px;overflow:auto;padding:10px 12px;border:1px solid #ccc;border-radius:4px;background:#fff;font-size:12px}
#legendContent h3{margin:0 0 8px;font-size:14px}
.legend-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(190px,1fr));gap:6px 14px}
.legend-item{display:flex;align-items:center;gap:7px;min-height:20px}
.legend-swatch{box-sizing:border-box;width:24px;height:16px;border:1px solid #777;flex:0 0 auto}
.legend-swatch.dashed{background:transparent!important;border:2px dashed #0000b4;opacity:1!important}
#info{padding:18px 20px;background:#fafafa;border-top:1px solid #ddd}
.detail-subtitle{margin:-7px 0 12px;font-weight:normal;line-height:1.4}
.detail-section{margin:0 0 15px}
.detail-section h3{margin:0 0 7px;font-family:Arial,"Noto Sans JP",sans-serif;font-size:15px;font-weight:700}
.detail-item{margin:0 0 8px;line-height:1.45}
.detail-label{margin:0 0 1px;font-family:Arial,"Noto Sans JP",sans-serif;font-size:13px;font-weight:700}
.detail-value{margin:0;font-weight:400;overflow-wrap:anywhere}
.detail-note{display:block;margin-top:1px;font-size:0.85em;color:#666}
#status{margin-bottom:12px;color:#555}
.note{margin-top:12px;font-size:12px;color:#777;line-height:1.6}
#diagnosisComments{margin-bottom:18px;padding-bottom:14px;border-bottom:1px solid #ddd}
#diagnosisComments h2{margin:0 0 10px;font-size:18px}
#diagnosisCommentList{margin:0;padding-left:1.5em}
#diagnosisCommentList li{margin:7px 0;line-height:1.65}
#info h2.detail-heading{margin:14px 0 10px;font-size:18px}
#pageNotes,#credits{padding:16px 20px;border-top:1px solid #ddd}
#pageNotes h2,#credits h2{margin:0 0 10px;font-size:18px}
#credits h3{margin:16px 0 8px;font-size:16px}
#credits{font-size:12px}
#credits p{margin:8px 0;line-height:1.6}
#credits .credit-note{margin-top:16px;color:#555}
.service-source{display:block;margin-left:2.5em;font-size:0.85em}
.site-footer{padding:16px 20px;text-align:center;font-size:12px;background:#000e59;color:#fff;border-top:1px solid #ddd}
.footer-nav ul{display:flex;align-items:center;justify-content:center;gap:8px 18px;flex-wrap:wrap;list-style:none;margin:0;padding:0}
.footer-nav a{color:inherit;text-decoration:none}
.footer-nav a:hover{text-decoration:underline;text-underline-offset:3px}
.site-copyright{margin:14px 0 0}

/* v0.9.18: 関連するテーマ */
#relatedThemes{margin-bottom:18px;padding-bottom:14px;border-bottom:1px solid #ddd}
#relatedThemes h2{margin:0 0 10px;font-size:18px}
#relatedThemeList{list-style:none;margin:0;padding:0}
#relatedThemeList li{display:flex;align-items:baseline;flex-wrap:wrap;gap:0 16px;margin:8px 0}
#relatedThemeList h3{margin:0;font-size:15px;min-width:5em}
#relatedThemeList a{display:inline-block;max-width:100%;padding:4px 0;color:#155a85;line-height:1.6;overflow-wrap:anywhere;text-underline-offset:3px}

#relatedThemeList .theme-links{display:flex;align-items:baseline;flex-wrap:wrap;gap:0 8px}
#relatedThemeList .theme-link-separator{color:#777}
#pageNotes .note{padding-left:1.5em;margin-bottom:0}
#pageNotes .note li{margin:7px 0}
.site-header a:focus-visible,.site-footer a:focus-visible{outline:2px solid #fff;outline-offset:3px}

/* v0.9.19: ブラウザ標準の折り畳み */
.collapsible-section > summary{cursor:pointer;padding:11px 0;font-size:18px;line-height:1.4;font-weight:700}
#info .collapsible-section > summary h2.detail-heading,
#pageNotes .collapsible-section > summary h2,
#credits .collapsible-section > summary h2{display:inline;margin:0;font-size:inherit}
.collapsible-section > summary:hover{color:#000e59}
.collapsible-section > summary:focus-visible{outline:2px solid #000e59;outline-offset:3px}
.collapsible-section[open] > summary{margin-bottom:10px}

/* v0.9.21: スマホのメニュー・住所検索・地図操作 */
.global-menu-toggle{display:none}
@media (max-width:600px){
  .site-header{position:relative;padding-right:76px;padding-bottom:12px}
  .global-menu-toggle{display:flex;flex-direction:column;justify-content:center;gap:5px;position:absolute;top:10px;right:16px;width:44px;height:44px;padding:10px;border:1px solid currentColor;border-radius:4px;background:transparent;color:inherit;cursor:pointer}
  .global-menu-toggle span{display:block;width:100%;height:2px;background:currentColor}
  .global-menu-toggle:focus-visible{outline:2px solid #fff;outline-offset:3px}
  .global-nav{display:none;margin-right:-56px}
  .global-nav.is-open{display:block}
  .global-nav ul{flex-direction:column;align-items:stretch;gap:0}
  .global-nav a{padding:12px 0}
  #addressSearchForm{flex-wrap:nowrap}
  #addressSearchForm label,#addressSearchButton{flex-shrink:0;white-space:nowrap}
  #addressSearchInput{width:auto;flex:1;min-width:0}
}
/* Leaflet標準のtouch-action:noneを解除し、1本指でページをスクロール */
#map.mobile-gesture-handling{touch-action:pan-x pan-y}
