
:root{--ink:#172f36;--brand:#064d51;--teal:#146365;--sub:#486168;--line:#cbd6d4;--paper:#fff;--bg:#f2f5f3;--pale:#eaf3ef;--warn:#7a490d;--warm:#fff1da}*{box-sizing:border-box}body{margin:0;background:var(--bg);color:var(--ink);font:15px/1.5 "Hiragino Sans","Yu Gothic UI",Meiryo,sans-serif;font-variant-numeric:tabular-nums}a{color:#065e69}button,input,select{font:inherit;color:inherit}button,select,input,summary{touch-action:manipulation}input,select,button{border:1px solid #aabeb9;border-radius:5px;background:#fff;padding:7px 10px}button,select,summary{cursor:pointer}button:hover,button:focus-visible{background:#e3efea}button:focus-visible,input:focus-visible,select:focus-visible,a:focus-visible{outline:3px solid #659a9b;outline-offset:2px}.top{background:var(--brand);color:#fff;padding:18px max(22px,3vw);display:flex;align-items:center;justify-content:space-between;gap:20px}.top h1{font-size:clamp(22px,2.4vw,34px);margin:0;font-weight:700;letter-spacing:.02em}.top small{display:block;color:#c6e4df;font-size:12px;margin-top:2px}.ys{display:flex;align-items:center;gap:4px;white-space:nowrap}.ys span{margin-right:6px;color:#d8eeea;font-size:13px}.ys button{color:#fff;background:transparent;border-color:#679795}.ys .active{background:#fff;color:var(--brand);font-weight:bold}nav{display:flex;gap:14px;padding:0 max(20px,3vw);background:#fff;border-bottom:1px solid var(--line);overflow:auto}nav button{color:var(--sub);white-space:nowrap;border:0;border-radius:0;border-bottom:3px solid transparent;background:none;padding:13px 8px}nav .active{color:var(--brand);border-bottom-color:#086360;font-weight:700}main{max-width:1900px;margin:auto;padding:18px max(16px,2.3vw)}.toolbar,.compact,.mapbar{display:flex;gap:10px;align-items:end;flex-wrap:wrap}.toolbar{margin-bottom:16px}.toolbar label,.compact label{display:grid;gap:3px;font-size:12px;color:var(--sub);font-weight:bold}.toolbar select,.compact select,.compact input{font-size:14px;font-weight:400}.layout{display:grid;grid-template-columns:minmax(315px,.68fr) minmax(0,1.32fr);gap:16px;align-items:start}.card{background:#fff;border:1px solid var(--line);border-radius:10px;padding:17px 18px;min-width:0}.mapcard{position:sticky;top:10px}.mapbar{justify-content:space-between;align-items:center;margin-bottom:8px}.mapwrap{height:clamp(338px,55vh,630px);border:1px solid var(--line);background:#e7efef;border-radius:6px;overflow:hidden}.mapwrap svg{width:100%;height:100%;display:block}.maptools{display:flex;gap:3px}.maptools button{min-width:34px;padding:3px 6px}.rightcol{min-width:0;display:grid;gap:14px}h2,h3,h4{margin:0 0 9px;line-height:1.35}h2{font-size:23px;letter-spacing:.02em}h3{font-size:17px}h4{font-size:15px}.sub,.subtle{color:var(--sub);font-size:12px}.summarytop{display:flex;align-items:baseline;justify-content:space-between;gap:12px;flex-wrap:wrap}.indicators{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:10px}.kpi{border-top:2px solid #78a69d;padding:6px 0 1px}.kpi b{display:block;font-size:12px;color:var(--sub)}.kpi strong{display:inline-block;font-size:clamp(19px,2vw,29px);letter-spacing:-.025em}.kpi .u{font-size:12px;margin-left:4px}.kpi small{display:block;font-size:11px;color:var(--sub)}.sect{margin-top:13px}.tablebox{overflow:auto;max-height:65vh;margin-top:8px;scrollbar-color:#a3b9b3 #edf1ef}table{border-collapse:separate;border-spacing:0;width:100%;font-size:13px;text-align:right;white-space:nowrap}th,td{border-bottom:1px solid #d9e2df;padding:8px 10px}th{background:#eaf1ee;color:var(--sub);font-size:12px;position:sticky;top:0;z-index:1;text-align:right}th button{border:0;padding:0;background:none;color:inherit;font-weight:bold}tr:hover td{background:#f0f6f2}td:first-child,th:first-child{text-align:left}.sticky th:first-child,.sticky td:first-child{position:sticky;left:0;z-index:1;background:#fff;white-space:normal;min-width:150px;max-width:240px}.sticky th:first-child{background:#eaf1ee;z-index:2}.cell{border:none;padding:0;background:transparent;font-weight:600;color:var(--ink)}.name{color:var(--teal);text-align:left;font-weight:650}.cell i,.tag{display:inline-block;font-style:normal;font-weight:500;background:var(--warm);color:var(--warn);border-radius:3px;padding:1px 4px;font-size:10px;margin-left:3px}.weak{color:#79908f}.foot{font-size:12px;color:var(--sub);margin:9px 0 0}.filters{margin-bottom:8px}.switches{display:flex;flex-wrap:wrap;align-items:center;gap:6px;margin:5px 0 8px}.switches button{font-size:12px;padding:4px 8px}.switches button.active{background:var(--pale);color:var(--brand);border-color:var(--brand);font-weight:700}.link{color:var(--teal);background:none;border:0;padding:0;text-decoration:underline}.compare{display:grid;gap:14px;grid-template-columns:repeat(2,minmax(0,1fr))}.compare.vertical{grid-template-columns:1fr}.comphead{display:flex;align-items:center;gap:7px;margin:0 0 9px}.comphead label{font-size:13px}.comphead select{max-width:100%}.comphead .choose{width:100%;min-width:0}dialog{color:var(--ink);border:1px solid var(--line);border-radius:10px;padding:20px;max-width:min(820px,96vw);width:790px;max-height:89vh}dialog::backdrop{background:#102e39aa}.dhead{display:flex;align-items:start;justify-content:space-between;gap:10px}.dhead button{white-space:nowrap}.dlist{margin-top:15px}.obs{border-top:1px solid var(--line);padding:9px 0}.obs b{margin-right:9px}.obs p{margin:2px 0;font-size:13px}.source-url{overflow-wrap:anywhere}.methods p,.methods li{max-width:88ch}.methods dt{font-weight:700}.methods dd{margin:4px 0 14px}.sr{position:absolute;width:1px;height:1px;clip-path:inset(50%);overflow:hidden}details{margin-top:10px}summary{font-size:13px;color:var(--teal);font-weight:600}.paging{display:flex;align-items:center;gap:8px;margin:10px 0 0}.paging button{padding:3px 8px}.dl{display:inline-block;text-decoration:none;color:var(--teal);font-size:13px}.mapnote{font-size:12px;color:var(--sub);margin-top:8px}.comparison-data td:first-child{text-align:left;white-space:normal}.comparison-data td small{white-space:normal}.nolist{padding:10px 0;color:var(--sub)}[hidden]{display:none!important}button:disabled{opacity:.45;cursor:default}.evidence-filter{display:inline-flex;align-items:center;gap:4px;font-size:12px}.cap{font-size:11px;line-height:1.3;margin:1px 0}.compact input[type=search]{min-width:170px}.fyline{display:block;font-weight:400;font-size:11px;color:var(--sub)}.mgroup{margin:15px 0 3px;font-weight:bold;color:var(--teal);font-size:13px}.dlgtable td,.dlgtable th{white-space:normal}.boardline{border-top:1px solid var(--line);padding-top:7px;margin-top:8px;font-size:12px}.legendtext{font-size:12px;color:var(--sub)}@media(min-width:1450px){.indicators{grid-template-columns:repeat(3,1fr)}.layout{grid-template-columns: minmax(380px,.63fr) minmax(0,1.37fr)}}@media(max-width:960px){.layout{grid-template-columns:1fr}.mapcard{position:static}.mapwrap{height:350px}.tablebox{max-height:60vh}.top{padding:14px 16px}}@media(max-width:620px){main{padding:10px}.top{align-items:start;flex-direction:column;gap:8px}.top small{font-size:11px}nav{padding:0 8px;gap:3px}nav button{font-size:13px;padding:10px 6px}.card{padding:12px}.compare{grid-template-columns:1fr}.indicators{gap:7px}.kpi b{font-size:11px}.kpi strong{font-size:20px}.mapwrap{height:310px}.toolbar{gap:6px}.toolbar select{max-width:46vw}.comphead{flex-wrap:wrap}}
.sticky .cell i{display:block;width:fit-content;margin:2px 0 0 auto;line-height:1.2}.sticky th:not(:first-child),.sticky td:not(:first-child){padding:7px 6px}.sticky .cell{line-height:1.4}.sticky .name{line-height:1.5}
/* モバイル向け補正。デスクトップの比較表・原典表示は維持します。 */
.app-loading{margin:14px auto;max-width:800px;padding:14px 18px;background:#eaf3ef;border:1px solid #cbd6d4;border-radius:8px;color:#064d51}
.app-loading.error{background:#fff1da;color:#7a490d}
@media(max-width:680px){
 html,body{max-width:100%}
 .top{padding:13px 12px;gap:8px}
 .top h1{font-size:clamp(19px,5.3vw,25px)}
 .ys{max-width:100%;flex-wrap:wrap;white-space:normal;gap:5px}
 .ys button{min-height:40px}
 nav{gap:3px;padding:0 8px;overscroll-behavior-x:contain;scrollbar-width:thin}
 nav button{padding:13px 9px;min-height:44px;flex:0 0 auto;scroll-snap-align:start}
 main{padding:10px 8px 28px}
 .toolbar{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:9px;margin-bottom:12px}
 .toolbar label{min-width:0;max-width:100%}
 .toolbar select{width:100%;max-width:100%;min-width:0;padding:9px 5px;font-size:16px}
 .card{padding:12px 10px}
 .mapbar{align-items:flex-start;gap:7px}
 .mapbar h3{flex:1 1 100%;margin-bottom:0}
 .maptools{max-width:100%;overflow-x:auto;min-width:0}
 .maptools button{min-height:40px;min-width:40px;flex-shrink:0}
 #mapback{background:#064d51;color:#fff;border-color:#064d51;min-width:76px;font-weight:700}
 #mapback:disabled{background:#dbe5e1;color:#59706c;border-color:#b8cbc5}
 .mapwrap{height:min(43svh,350px);min-height:240px}
 .tablebox{max-width:100%;overflow-x:auto;overscroll-behavior-x:contain;-webkit-overflow-scrolling:touch}
 .sticky th:first-child,.sticky td:first-child{min-width:120px;max-width:154px}
 .compare{grid-template-columns:minmax(0,1fr)}
 .comphead{flex-wrap:wrap}
 .comphead select,.comphead input{min-width:0;max-width:100%;font-size:16px}
 .indicators{grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
 dialog{max-width:calc(100vw - 16px);width:calc(100vw - 16px);padding:14px 10px;max-height:90dvh}
 dialog .dlgtable{font-size:12px}

}
@media(max-width:370px){.toolbar{grid-template-columns:minmax(0,1fr)}.maptools{gap:2px}.maptools button{min-width:36px;padding:5px}}

#csv-status:empty { display: none; }

/* Keep intrinsic select widths inside grid/flex cards on desktop and mobile. */
.toolbar label,.compact label,.comphead,.comphead>*{min-width:0;max-width:100%}
.compact select,.compact input{min-width:0;max-width:100%}
.compact label{flex:0 1 auto}
.mapcard .filters>label:first-child{width:100%}
#mapMetric{width:100%;min-width:0;max-width:100%;text-overflow:ellipsis}
.maptools{flex-wrap:wrap}
#mapback{background:var(--brand);color:white;border-color:var(--brand);font-weight:700;min-width:80px}
#mapback:hover:not(:disabled){background:var(--teal)}
#mapback:disabled{background:#e4ebe7;color:#59706c;border-color:#bdcbc5;opacity:1}
.coverage-note{background:var(--pale);border-radius:5px;color:var(--sub);font-size:12px;padding:9px 11px;margin:0 0 12px}
.related-value{display:block;font-size:11px;line-height:1.45;white-space:normal;margin:5px 0 0 auto;max-width:180px;color:var(--teal)}
.related-value span,.related-value b{display:block}
.related-value b{font-size:13px}
button.related-value{text-align:right;text-decoration:underline;text-underline-offset:3px}
.related-summary{font-size:11px;line-height:1.5;color:var(--teal);background:var(--pale);padding:7px;border-radius:4px;margin:7px 0 0;overflow-wrap:anywhere}
.related-summary b{font-size:12px;color:var(--teal)}
.kpi{min-width:0;overflow-wrap:anywhere}
.comphead{flex-wrap:wrap}
.comphead select[data-ctype]{flex:0 1 150px}
.comphead .choose{flex:1 1 190px;width:auto}
.comphead input{flex:1 1 150px;width:150px}
.comparison-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:12px}
.comparison-heading>div{min-width:0;overflow-wrap:anywhere}
.comparison-map{flex:0 0 140px;width:140px;margin:0;text-align:center}
.comparison-map svg{display:block;width:100%;height:120px;background:#f2f6f3;border-radius:6px}
.comparison-map figcaption{color:var(--sub);font-size:11px;margin-top:4px}
.comparison-data{table-layout:fixed;white-space:normal}
.comparison-data th,.comparison-data td{white-space:normal;overflow-wrap:anywhere;padding:10px 8px}
.comparison-data th:first-child{width:55%}
.comparison-data td small{display:block;color:var(--sub)}
.comparison-data .related-value{max-width:100%}
@media(max-width:400px){.comparison-map{flex-basis:105px;width:105px}.comparison-map svg{height:100px}.comparison-heading{gap:8px}}
