/* UNCTAD InfoVis style — palette as in the UNCTAD infovis colour file (blue / grey / yellow / green, each with its light and dark steps).
   UI chrome = UN blue / warm grey only. Data hues: plastics = UN blue ramp, substitutes = UN green ramp.
   EMPHASIS IS SET IN COLOUR AND WEIGHT, NOT IN BOXES AND LINES:
     · what is selected is navy and bold (text) or carries a pale blue wash (the economy on the map);
     · what is pointed at turns blue; what is not concerned steps back;
     · surfaces are flat: no accent stripes, no outlined pills, no cards around text. A rule is a hairline that separates
       two things, never a decoration; the only thick line is the blue band of the UNCTAD header.
     · a caveat (†, °, provisional, not reliable) is ochre text (--caveat), never a coloured box. */
:root{
  --un-blue:#009edb; --un-blue-dark:#004990; --un-blue-darkest:#003a75; --un-blue-text:#0077b8; --un-blue-light:#7bb7e1; --un-blue-lightest:#c3dff0;
  --un-green:#72bf44; --un-green-text:#27833a; --un-yellow:#fbaf17; --un-red:#eb1f48;
  --unblue-bg:#f2f8fc; --unblue-bg-alt:#f3f8fd;
  --grey:#aea29a; --grey-text:#6e6259; --grey-dark:#231f20; --grey-border:#ded9d5; --grey-bg:#ebeae6; --grey-rule:#cfc9c4;
  --land:#e3dfdb; --land-hover:#c8c2bb; --nodata:#f7f5f3; --nodata-line:#b8aea7;
  --plastic:#004990; --subs:#27833a;
  --sel:#004990; --sel-wash:#c5dfef;                 /* selection: navy ink, pale blue wash */
  --caveat:#9a5e22;                                  /* UN yellow, darkest step, deepened until it reads as small text on white */
  --font:Inter,"Helvetica Neue",Helvetica,Arial,sans-serif;
  --shadow-sm:0 1px 3px rgba(0,0,0,.08); --shadow-md:0 2px 8px rgba(0,0,0,.10); --shadow-lg:0 10px 40px rgba(0,0,0,.15);
  --pop:0 0 0 1px var(--grey-border),0 8px 28px rgba(0,58,117,.12);   /* what floats above the page (menus, story, dialog): a hairline and a soft lift */
}
*,*::before,*::after{box-sizing:border-box}
html,body{margin:0;padding:0;height:100dvh}
body{font-family:var(--font);font-size:13px;line-height:1.4;color:var(--grey-dark);background:var(--unblue-bg-alt);display:flex;flex-direction:column;overflow:hidden}
::-webkit-scrollbar{width:6px;height:6px}::-webkit-scrollbar-track{background:var(--unblue-bg)}
::-webkit-scrollbar-thumb{background:var(--grey-border);border-radius:3px}::-webkit-scrollbar-thumb:hover{background:var(--grey)}
.hidden{display:none!important}
button{font-family:var(--font)}
button:focus-visible,input:focus-visible{outline:2px solid var(--un-blue);outline-offset:1px}
.cap{font-size:11px;font-weight:600;letter-spacing:.06em;text-transform:uppercase;color:var(--grey-text)}

/* ── header ── */
#main-header{background:var(--unblue-bg);border-bottom:5px solid var(--un-blue);flex-shrink:0;z-index:30}
.header-inner{padding:0 16px}
.header-title{display:flex;align-items:center;gap:10px;padding:9px 0 8px}
.header-logo{width:36px;height:36px;object-fit:contain;flex-shrink:0}
.header-text{min-width:0;flex:1}
.header-text h3{font-size:20px;font-weight:800;letter-spacing:-.012em;color:#000;margin:0;line-height:1.2}
.header-text h4{font-size:12.5px;font-weight:400;color:rgba(0,0,0,.6);margin:2px 0 0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.header-actions{display:flex;align-items:center;gap:18px;flex-shrink:0}
/* a text button: no rule under it at rest; it turns blue and underlines itself when pointed at */
.btn-line{border:0;background:transparent;padding:6px 0;font:600 13px/1.2 var(--font);color:var(--un-blue-dark);cursor:pointer;white-space:nowrap;text-underline-offset:3px;text-decoration-thickness:1px;transition:color .15s}
.btn-line:hover{color:var(--un-blue-text);text-decoration:underline}
.btn-line:disabled{color:var(--grey);cursor:default;text-decoration:none}
.header-actions .btn-line{color:var(--grey-dark)}
.header-actions .btn-line:hover{color:var(--un-blue-text)}
.tb-sel{appearance:none;-webkit-appearance:none;border:0;border-bottom:1px solid var(--grey-rule);background:transparent;padding:6px 18px 6px 2px;font:600 13px/1.2 var(--font);color:var(--grey-text);cursor:pointer;max-width:170px;
  background:url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236e6259' stroke-width='2.2'><path d='M6 9l6 6 6-6'/></svg>") no-repeat right 2px center / 11px 11px}
.tb-sel:hover{border-bottom-color:var(--un-blue-dark);color:var(--un-blue-dark)}
.search{position:relative}
.search input{width:230px;border:0;border-bottom:1px solid var(--grey-rule);background:transparent;padding:6px 2px;font:600 13px/1.2 var(--font);color:var(--grey-dark)}
.search input::placeholder{color:var(--grey-text);font-weight:500}
.search input:focus{border-bottom-color:var(--un-blue-dark);outline:none}
.search-list{position:absolute;top:calc(100% + 6px);right:0;width:300px;max-height:340px;overflow:auto;margin:0;padding:4px 0;list-style:none;background:#fff;border:0;border-radius:2px;box-shadow:var(--pop);z-index:60}
.search-list li{padding:6px 12px;cursor:pointer;display:flex;justify-content:space-between;gap:10px;font-size:12.5px}
.search-list li small{color:var(--grey-text)}
.search-list li:hover,.search-list li.on{background:var(--unblue-bg);color:var(--un-blue-dark)}

/* ── toolbar pieces ── */
/* a set of choices is plain words: the one that is on is navy, with a short blue bar under that word only */
.tb-fld{display:flex;align-items:center;gap:8px}
.tb-cap{font-size:12px;font-weight:500;color:var(--grey-text);white-space:nowrap}
.tb-seg{display:flex;gap:2px}
.btn-toggle{padding:6px 8px 7px;font:600 13px/1.2 var(--font);border:0;border-radius:0;color:var(--grey-text);cursor:pointer;white-space:nowrap;transition:color .15s,background-size .2s;
  background:linear-gradient(var(--un-blue),var(--un-blue)) no-repeat 8px 100%/0 2px}
.btn-toggle:hover{color:var(--grey-dark)}
.btn-toggle.active{color:var(--un-blue-dark);background-size:calc(100% - 16px) 2px}
.btn-toggle:disabled{opacity:.4;cursor:default}

/* ── KPI bar ── */
#kpi-bar{background:rgba(255,255,255,.97);border-bottom:1px solid rgba(203,213,224,.9);padding:6px 16px;flex-shrink:0;z-index:20;display:flex;align-items:center;gap:18px}
.kpi-inner{display:flex;align-items:center;gap:4px 18px;flex-wrap:nowrap;overflow-x:auto;flex:1;min-width:0}
#meas-fld{flex-shrink:0}
.kpi-ctx{display:flex;flex-direction:column;gap:1px;flex-shrink:0;padding-right:6px}
.kpi-ctx b{font-size:14px;line-height:1.2;white-space:nowrap}
.kpi-ctx span{font-size:11px;color:var(--grey-text);white-space:nowrap}
.kpi-item{display:flex;flex-direction:column;gap:1px;white-space:nowrap;flex-shrink:0}
.kpi-label{font-size:11px;color:var(--grey-text);font-weight:500}
.kpi-value{font-size:15px;font-weight:700;line-height:1.25;color:var(--grey-dark)}
.kpi-value.c-p{color:var(--plastic)} .kpi-value.c-s{color:var(--subs)}
.kpi-lead .kpi-value{font-size:18px;font-weight:800;letter-spacing:-.01em}
sup.mir{color:var(--caveat);font-weight:700;font-size:.7em;margin-left:1px;cursor:help}
.row.wq .rk{color:var(--caveat)}
.row.wq .why{grid-column:2/4;font-size:11px;color:var(--caveat);line-height:1.3;padding-left:6px}
.panel p.wnote{color:var(--grey-dark)}
.kpi-divider{width:1px;height:26px;background:var(--grey-border);flex-shrink:0}
/* a caveat is said in words, with a small yellow mark; it is not put in a box */
.kpi-warn{margin-left:auto;font-size:11.5px;font-weight:600;color:var(--caveat);white-space:nowrap;flex-shrink:0;display:flex;align-items:center;gap:7px}
.kpi-warn::before{content:"";width:7px;height:7px;background:var(--un-yellow);flex-shrink:0}

/* ── stage ── */
/* the widths of the two panels and the height of the time line are set from the shape of the window (app.js, layoutStage):
   what the map cannot use is given to them instead of lying empty beside the map. The values after the commas apply until then. */
#stage{flex:1;min-height:0;display:grid;grid-template-columns:var(--dockw,clamp(270px,22vw,340px)) minmax(0,1fr) var(--panelw,clamp(300px,25vw,380px))}
#dock,#panel{background:#fff;overflow-y:auto;overflow-x:hidden;padding:10px 12px}
#dock{border-right:1px solid var(--grey-border)}
#panel{border-left:1px solid var(--grey-border)}
.dock-head{display:flex;align-items:baseline;gap:8px;min-height:20px}
.crumbs{font-size:12px;color:var(--grey-text);line-height:1.35}
.crumbs button{border:0;background:none;color:var(--un-blue-dark);cursor:pointer;font:inherit;font-weight:600;padding:0}
.crumbs button:hover{text-decoration:underline}
.crumbs .sep{margin:0 4px}
.crumbs .cur{color:var(--grey-dark);font-weight:600}
.pizza-wrap{max-width:330px;margin:2px auto 0;position:relative}
.pizza-wrap.landed::after{content:"";position:absolute;inset:7.5%;border-radius:50%;border:2px solid var(--un-blue);pointer-events:none;animation:np-ring .8s cubic-bezier(.2,.7,.2,1) both}
@keyframes np-ring{from{transform:scale(.94);opacity:.85}to{transform:scale(1.24);opacity:0}}
.dock-x{margin-left:auto;border:0;background:none;color:var(--un-blue-dark);font:600 11.5px/1.2 var(--font);cursor:pointer;padding:2px 0;white-space:nowrap;flex-shrink:0;align-self:flex-start}
.dock-x:hover{text-decoration:underline}
.header-logo{cursor:pointer}
#pizza{width:100%;height:auto;display:block}
.pz .arc{stroke:#fff;stroke-width:.6px;cursor:pointer;transition:opacity .15s}
.pz .arc.sel{stroke:var(--grey-dark);stroke-width:1px}      /* the slices around it step back (pizza.js); the line only keeps it findable while another one is pointed at */
.pz .wref{stroke:#fff;stroke-width:.5px;pointer-events:none}
.pz text{pointer-events:none;font-size:calc(8.5px * var(--pzs,1));font-weight:500;fill:#fff;text-anchor:middle;dominant-baseline:middle}
.pz text.dark{fill:var(--grey-dark)}
.pz .hole{fill:var(--unblue-bg);stroke:var(--grey-border)}
.pz .center-hit{fill:transparent;cursor:pointer}
.pz .c-eyebrow{font-size:calc(7px * (1 + (var(--pzs,1) - 1) * .7));font-weight:600;letter-spacing:.05em;text-transform:uppercase;fill:var(--grey-text)}
.pz .c-big{font-size:calc(13px * (1 + (var(--pzs,1) - 1) * .3));font-weight:700;fill:var(--un-blue-dark)}
.pz .c-sub{font-size:calc(7.5px * (1 + (var(--pzs,1) - 1) * .6));fill:var(--grey-text);font-weight:500}
.pz .c-hint{font-size:calc(7px * (1 + (var(--pzs,1) - 1) * .7));font-weight:600;fill:var(--un-blue-dark)}
.pz .wref-label{font-size:calc(7px * var(--pzs,1));fill:var(--grey-text);font-weight:600}
.pz text .dl{font-size:calc(7px * var(--pzs,1));font-weight:400;transition:opacity .2s}
.pz.flying .dl{opacity:0}
.pz .cutline{fill:none;stroke:var(--grey-dark);stroke-width:.9px;stroke-linejoin:round;pointer-events:none}
.pz .cutline.draw{stroke-dasharray:1;stroke-dashoffset:1;animation:pz-knife .34s ease-out forwards}
@keyframes pz-knife{to{stroke-dashoffset:0}}
.pizza-note{font-size:11px;color:var(--grey-text);min-height:16px;text-align:center;margin:2px 0 6px}
.slice-list .group-h,.panel .group-h{font-size:11px;font-weight:700;color:var(--grey-dark);margin:12px 0 3px;padding-bottom:4px;border-bottom:1px solid var(--grey-border)}
/* a row of a list. Its value is a pale bar BEHIND the words (width = value, tint = plastics blue / substitutes green / grey for both):
   the list reads as a bar chart and no line is drawn under any name. Pointed at → the name turns blue; selected → navy and bold. */
.row{position:relative;display:grid;grid-template-columns:10px minmax(0,1fr) auto;column-gap:6px;align-items:center;padding:4px 0;cursor:pointer}
.row>span{position:relative;z-index:1}
.row .sw{width:9px;height:9px;border-radius:2px}
.row .nm{font-size:12px;padding-left:6px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;transition:color .15s}
.row .nm.px{display:flex;min-width:0}
.row .nm.px>span{overflow:hidden;text-overflow:ellipsis}
.row .nm.px>b{flex-shrink:0;font-weight:700;color:var(--caveat);margin-left:1px}
.row .nm small{color:var(--grey-text);font-weight:400}
.row .vl{font-size:11.5px;color:var(--grey-text);text-align:right;white-space:nowrap;font-weight:500;padding-right:6px}
.row .vl abbr{text-decoration:none;cursor:help}
.row .bar{position:absolute;left:16px;right:0;top:2px;bottom:2px;pointer-events:none}
.row .bar i{display:block;height:100%;background:var(--grey-bg);background:color-mix(in srgb,var(--c,#6e6259) 13%,#fff);transition:width .3s,background-color .15s}
.row:hover .nm,.row.hl .nm{color:var(--un-blue-text)}
.row:hover .vl,.row.hl .vl{color:var(--grey-dark)}
.row:hover .bar i,.row.hl .bar i{background:color-mix(in srgb,var(--c,#6e6259) 22%,#fff)}
.row.on .nm{color:var(--sel);font-weight:700}
.row.on .vl{color:var(--grey-dark);font-weight:600}
.row.on .bar i{background:color-mix(in srgb,var(--c,#6e6259) 24%,#fff)}
.row.dim{opacity:.45}
.row.rank{grid-template-columns:18px minmax(0,1fr) auto}
.row.rank .bar{left:24px}
.row.rank .rk{font-size:11px;color:var(--grey-text);text-align:right;font-weight:600;font-variant-numeric:tabular-nums}

/* ── map ── */
#mapwrap{position:relative;overflow:hidden;background:var(--unblue-bg-alt);min-height:0}
.map-top{position:absolute;top:6px;left:12px;right:12px;display:flex;justify-content:space-between;align-items:flex-start;gap:6px 10px;z-index:12;pointer-events:none;flex-wrap:wrap}
.map-top>*{pointer-events:auto;background:rgba(243,248,253,.9);border-radius:2px;padding:0 4px;min-width:0}
#lens{flex-wrap:wrap}
@media (max-width:1300px){.map-top .tb-cap{display:none}}
#map,#mapover,#flowcanvas{position:absolute;inset:0;width:100%;height:100%}
#mapover,#flowcanvas{pointer-events:none}
#map .sphere{fill:#fff;stroke:rgba(0,73,144,.18);stroke-width:1.2px}
#map .graticule{fill:none;stroke:rgba(0,73,144,.07);stroke-width:.8px}
#map .land{stroke:none;cursor:pointer;transition:fill .25s}
#map .land.nohit{cursor:default}
#map .border{fill:none;stroke:#fff;stroke-linecap:round;pointer-events:none;vector-effect:non-scaling-stroke;stroke-width:.9px}
#map .border-dashed{stroke-dasharray:4 3}
#map .border-dotted{stroke-dasharray:1 2.5}
#map .border-dashdot{stroke-dasharray:4 2.5 1 2.5}
/* the selected economy: a pale blue wash with a navy hairline on the plain grey map. Where the colour of the land is the data
   (#mapwrap.choro: Which side, Balance, Specialisation) the wash would hide it, so only the hairline is drawn, on a white casing. */
#map .sel-outline,#map .sel-halo,#map .hover-outline{fill:none;stroke-linejoin:round;vector-effect:non-scaling-stroke;pointer-events:none}
#map .sel-outline{fill:var(--sel-wash);stroke:var(--sel);stroke-width:.9px}
#map .sel-halo{stroke:none}
#mapwrap.choro #map .sel-outline{fill:none;stroke-width:1.3px}
#mapwrap.choro #map .sel-halo{stroke:#fff;stroke-width:3.6px}
#map .sel-outline.cmp{fill:none;stroke-width:1.1px;stroke-dasharray:3 2.5}
#map .hover-outline{stroke:var(--un-blue-text);stroke-width:1px}
#mapover .spike{stroke-width:1px;stroke-linejoin:round}
#mapover .spike-hit,#mapover .dot{pointer-events:auto;cursor:pointer}
#mapover .dot{stroke:#fff;stroke-width:.8px}
#mapover .lbl{font-size:10.5px;font-weight:600;fill:var(--grey-dark);paint-order:stroke;stroke:#fff;stroke-width:3px;stroke-linejoin:round;text-anchor:middle;pointer-events:none}
#mapover .lbl .v{font-weight:500;fill:var(--grey-text)}
#mapover .partner-lbl{font-size:10px}
/* the legend is words and keys laid on the map, on a veil of white that keeps them readable over land: no frame */
.legend{position:absolute;left:12px;bottom:10px;background:rgba(255,255,255,.9);border:0;border-radius:2px;padding:8px 10px;font-size:11.5px;max-width:330px;z-index:10}
.legend b{display:block;font-size:11.5px;margin-bottom:4px;padding-right:18px}
.legend .lg-seg{display:flex;gap:10px;margin:2px 0 7px}
.legend .lg-seg button{border:0;font:600 11px/1.2 var(--font);color:var(--grey-text);padding:3px 0 4px;cursor:pointer;white-space:nowrap;background:linear-gradient(var(--un-blue),var(--un-blue)) no-repeat 0 100%/0 2px;transition:color .15s,background-size .2s}
.legend .lg-seg button:hover{color:var(--grey-dark)}
.legend .lg-seg button.on{color:var(--un-blue-dark);background-size:100% 2px}
.legend .lg-seg button:disabled{opacity:.4;cursor:default}
.legend .lg-x{position:absolute;right:4px;top:3px;border:0;background:none;color:var(--grey-text);cursor:pointer;font-size:13px;line-height:1;padding:3px 5px}
.legend.min{padding:4px 26px 4px 10px;cursor:pointer}
.legend.min>*:not(.lg-x):not(.lg-t){display:none}
.legend .lg-t{display:none;font-weight:600;font-size:11.5px;color:var(--un-blue-dark)}
.legend.min .lg-t{display:inline}
@media (max-height:760px){.legend{font-size:10.5px;padding:6px 8px;max-width:250px}#foot p{font-size:9.5px}}
.row:focus-visible{outline:2px solid var(--un-blue);outline-offset:-2px}
.legend .sw-row{display:flex;gap:0;margin:4px 0 2px}
.legend .sw-row i{flex:1;height:10px}
.legend .ticks{display:flex;justify-content:space-between;font-size:10px;color:var(--grey-text)}
.legend .li{display:flex;align-items:center;gap:6px;color:var(--grey-text);margin-top:3px;font-size:11px}
.legend .li i{width:14px;height:10px;display:inline-block;border:1px solid var(--grey-border)}
.legend .li.keys{flex-wrap:wrap;gap:1px 12px}
.legend .li .k{display:inline-flex;align-items:center;gap:5px;white-space:nowrap}
.legend .li .k i{width:9px;height:9px;border:0;border-radius:2px}
.legend .hatch{background:repeating-linear-gradient(135deg,var(--nodata) 0 3px,var(--nodata-line) 3px 4px)}
.legend svg{display:block}
/* map tools: one strip, separated by hairlines (the gaps of the grid show the strip's own grey) */
.zoomctl{position:absolute;right:12px;bottom:10px;display:flex;flex-direction:column;gap:1px;padding:1px;background:var(--grey-border);border-radius:2px;z-index:10}
.zoomctl button{width:28px;height:28px;border:0;background:#fff;border-radius:0;cursor:pointer;font-size:15px;color:var(--grey-text);line-height:1;transition:color .15s,background .15s}
.zoomctl button:hover{color:var(--un-blue-text);background:var(--unblue-bg)}
.zoomctl button[aria-pressed="true"]{background:var(--un-blue-dark);color:#fff}
#mapwrap.globe #map{cursor:grab}#mapwrap.globe #map:active{cursor:grabbing}
#mapwrap.globe #map .sphere{fill:#fff;stroke:rgba(0,73,144,.28);stroke-width:1.2px}
/* what the explorer is narrowed to (an economy or a group): one solid navy pill, as UNCTAD's buttons are */
.scope{flex-basis:auto;margin-right:auto;order:3;background:var(--un-blue-dark)!important;border:0;border-radius:99px;padding:3px 4px 3px 12px;font-size:12.5px;font-weight:600;color:#fff;display:flex;align-items:center;gap:4px}
.scope .dir{display:flex;gap:1px}
.scope .dir button{padding:3px 6px;font-size:12px}
.scope .x{border:0;background:transparent;border-radius:50%;width:20px;height:20px;cursor:pointer;color:#fff;font:400 16px/1 var(--font);padding:0 0 1px;transition:background .15s}
.scope .x:hover{background:rgba(255,255,255,.22)}
.mapmsg{position:absolute;left:50%;top:44px;transform:translateX(-50%);z-index:11;background:rgba(255,255,255,.94);border:0;color:var(--caveat);border-radius:2px;padding:5px 12px;font-size:12px;font-weight:600;max-width:70%}

/* ── loader ── */
#loader{position:fixed;inset:0;display:flex;flex-direction:column;align-items:center;justify-content:center;background:var(--unblue-bg-alt);z-index:100;gap:14px}
#loader .spin{width:44px;height:44px;border:4px solid rgba(0,73,144,.2);border-top-color:var(--un-blue-dark);border-radius:50%;animation:spin .8s linear infinite}
#loader p{margin:0;color:var(--un-blue-dark);font-size:13px;font-weight:500;max-width:80vw;text-align:center}
@keyframes spin{to{transform:rotate(360deg)}}
/* ── tooltip ── */
.tip{position:fixed;pointer-events:none;background:#fff;color:var(--grey-dark);border:0;padding:10px 12px;border-radius:2px;font-size:12.5px;max-width:330px;min-width:210px;z-index:95;box-shadow:var(--pop);line-height:1.4}
.tip b.t{display:block;font-size:13px;color:var(--un-blue-dark);margin-bottom:1px}
.tip .u{color:var(--grey-text);font-size:11px;margin-bottom:5px}
.tip table{border-collapse:collapse;width:100%}
.tip td{padding:1px 8px 1px 0;vertical-align:top}.tip td:first-child{color:var(--grey-text)}.tip td:last-child{text-align:right;font-weight:600;padding-right:0;white-space:nowrap}
.tip .mini{display:flex;align-items:center;gap:8px;margin-top:6px;padding-top:6px;border-top:1px solid var(--grey-bg);font-size:11.5px;color:var(--grey-text)}
.tip .warn{color:var(--caveat);font-size:11.5px;margin-top:4px}

/* ── right panel ── */
.panel h2{font-size:18px;font-weight:800;letter-spacing:-.012em;margin:0;line-height:1.2}
.panel .sub{font-size:12px;color:var(--grey-text);margin:2px 0 8px}
/* what an economy is (region, status, LDC…): words in a line, separated by dots. Groups UNCTAD follows are navy, a caveat is ochre.
   Written as they are typed, not in capitals (the checks in qa/ read the text as it is shown) */
.panel .tags{display:flex;flex-wrap:wrap;margin:4px 0 7px;row-gap:1px}
.tag{font-size:11.5px;font-weight:600;color:var(--un-blue-dark);white-space:nowrap}
.tags .tag+.tag::before{content:"·";margin:0 6px;color:var(--grey);font-weight:400}
.tag.grey{color:var(--grey-text)}
.tag.warn{color:var(--caveat)}
.panel p.note .tag{font-size:inherit;font-weight:700}
.panel p.note .tag::after{content:" —";font-weight:400;color:var(--grey)}
/* key figures: a ledger of two columns ruled by hairlines; the figure is the emphasis, nothing stands beside it */
.facts{display:grid;grid-template-columns:1fr 1fr;gap:0 16px;margin:8px 0 6px}
.fact{border-top:1px solid var(--grey-border);padding:6px 0 8px;min-width:0}
.fact .v{font-size:17px;font-weight:700;letter-spacing:-.01em;line-height:1.15;white-space:nowrap}
.fact .l{font-size:11px;color:var(--grey-text);line-height:1.3;margin-top:1px}
.fact .l abbr{text-decoration:none;cursor:help}
.fact .l abbr:hover{text-decoration:underline dotted var(--grey);text-underline-offset:2px}
.fact.pos .v{color:var(--un-green-text)} .fact.neg .v{color:#ab1d37}
.panel p.note{font-size:11.5px;color:var(--grey-text);margin:6px 0}
.panel .spark{margin:2px 0 0}
.panel .spark svg{width:100%;height:auto;display:block}
.ns{display:flex;height:14px;overflow:hidden;margin:5px 0 3px}
.ns i{display:block;height:100%}
.ns-l{display:flex;flex-wrap:wrap;gap:2px 10px;font-size:11px;color:var(--grey-text)}
.ns-l span::before{content:"";display:inline-block;width:8px;height:8px;border-radius:2px;margin-right:4px;background:var(--c)}
table.rr{border-collapse:separate;border-spacing:2px;width:100%;font-size:11px;margin:4px 0 2px}
table.rr th{font-weight:600;color:var(--grey-text);text-align:left;padding:1px 4px;white-space:nowrap}
table.rr tr:first-child th{text-align:center}
table.rr td{text-align:center;padding:3px 0;color:var(--grey-dark);min-width:30px}
table.rr td.hi{color:#fff}
table.rr td.d{outline:1px solid var(--grey-dark);outline-offset:-1px;font-weight:700}
table.cmp{border-collapse:collapse;width:100%;font-size:12px;margin:4px 0 6px}
table.cmp th{font-size:11px;color:var(--grey-text);font-weight:600;text-align:right;padding:2px 4px;border-bottom:1px solid var(--grey-border);max-width:110px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
table.cmp th:first-child,table.cmp td:first-child{text-align:left;color:var(--grey-text);font-weight:500}
table.cmp td{text-align:right;padding:3px 4px;border-bottom:1px solid #f1efed;white-space:nowrap;font-weight:600}
.cmp-bar{display:flex;height:12px;overflow:hidden;margin:3px 0 6px;background:var(--grey-bg)}
.cmp-bar i{display:block;height:100%}
.cmp-l{font-size:11px;color:var(--grey-text);display:flex;justify-content:space-between;gap:8px}
.cmp-l span:last-child{white-space:nowrap}
.cmp-pick{display:flex;gap:6px;align-items:center;margin:6px 0 2px}
.cmp-pick input{flex:1;min-width:0;border:0;border-bottom:1px solid var(--grey-rule);background:transparent;padding:4px 2px;font:500 12px/1.2 var(--font);color:var(--grey-dark)}
.cmp-pick input:focus{outline:none;border-bottom-color:var(--un-blue-dark)}
.hs{font-size:11px;color:var(--grey-text);max-height:120px;overflow:auto;padding:2px 0;margin-top:4px}
.hs div{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
details>summary{cursor:pointer;font-size:11.5px;font-weight:600;color:var(--un-blue-dark);margin-top:8px}

/* ── layers in the panel ── */
.layer-h{font-size:10.5px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--grey);margin:16px 0 4px;display:flex;align-items:center;gap:8px}
.layer-h::after{content:"";flex:1;height:1px;background:var(--grey-border)}
details.sec{border-bottom:1px solid var(--grey-bg)}
details.sec>summary{list-style:none;cursor:pointer;display:flex;align-items:baseline;gap:8px;padding:7px 2px 7px 16px;position:relative;margin:0}
details.sec>summary::-webkit-details-marker{display:none}
details.sec>summary::before{content:"";position:absolute;left:3px;top:12px;width:5px;height:5px;border-right:1.6px solid var(--un-blue-dark);border-bottom:1.6px solid var(--un-blue-dark);transform:rotate(-45deg);transition:transform .15s}
details.sec[open]>summary::before{transform:rotate(45deg);top:10px}
details.sec>summary:hover .st{color:var(--un-blue-text)}
details.sec .st{font-size:12.5px;font-weight:600;color:var(--un-blue-dark);white-space:nowrap;transition:color .15s}
details.sec .sh{font-size:11px;color:var(--grey-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;min-width:0;flex:1;text-align:right}
details.sec[open] .sh{visibility:hidden}
details.sec .sb{padding:2px 0 10px}
.mk-l{display:flex;flex-wrap:wrap;gap:1px 10px;font-size:11px;color:var(--grey-text);margin:-2px 0 8px}
.mk-l span::before{content:"";display:inline-block;width:8px;height:8px;border-radius:2px;margin-right:4px;background:var(--c)}
.panel p.dl{margin-top:14px}
.panel p.dl .btn-line{white-space:normal;text-align:left;line-height:1.35}      /* the panel can be as narrow as 300 px: the label wraps instead of being cut */
/* ── "More maps" menu ── */
.more{position:relative;display:flex}
.menu{position:absolute;top:calc(100% + 4px);left:0;width:300px;background:#fff;border:0;border-radius:2px;box-shadow:var(--pop);padding:4px 0;z-index:40;display:flex;flex-direction:column}
.menu button{border:0;background:none;text-align:left;padding:7px 12px;cursor:pointer;font:inherit;display:flex;flex-direction:column;gap:1px;color:var(--grey-dark)}
.menu button b{font-size:12.5px;font-weight:600;transition:color .15s}.menu button span{font-size:11px;color:var(--grey-text);white-space:normal}
.menu button:hover{background:var(--unblue-bg)}.menu button:hover b,.menu button.on b{color:var(--un-blue-dark)}
/* ── timeline ── */
#timeline{flex-shrink:0;background:#fff;border-top:1px solid var(--grey-border);display:flex;align-items:center;gap:10px;padding:4px 16px;height:var(--tlh,92px)}
/* the one round button: play. Solid, as UNCTAD's buttons are */
button.icon{width:30px;height:30px;border-radius:50%;border:0;background:var(--un-blue-dark);cursor:pointer;font-size:10px;color:#fff;flex-shrink:0;padding:0 0 0 1px;transition:background .15s}
button.icon:hover{background:var(--un-blue-text)}
.tl-year{display:flex;flex-direction:column;align-items:flex-start;flex-shrink:0;width:54px}
.tl-year b{font-size:20px;line-height:1.1}
.tl{flex:1;min-width:0;height:calc(var(--tlh,92px) - 8px)}
.tl svg{width:100%;height:100%;display:block;cursor:ew-resize}
.tl .ax text{font-size:10px;fill:var(--grey-text)}
.tl .ax path,.tl .ax line{stroke:var(--grey-border)}
.tl .tl-lab{font-size:10px;fill:var(--grey-text)}
.tl .ev{font-size:9.5px;fill:var(--grey-text)}

/* ── footer ── */
#foot{background:var(--unblue-bg);border-top:1px solid var(--grey-border);padding:4px 16px 6px;flex-shrink:0}
#foot p{font-size:10px;line-height:1.45;color:var(--grey-text);margin:0}
#foot strong{color:var(--grey-dark);font-weight:700}

/* ── story ── */
/* a sheet of paper on the map: no coloured edge; the chapter count is the only blue, the progress is a row of short bars */
.story{position:absolute;left:12px;bottom:10px;width:min(400px,calc(100% - 60px));background:#fff;border:0;border-radius:2px;box-shadow:var(--pop);padding:14px 16px 12px;z-index:25}
.story .step{font-size:11px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--un-blue-text)}
.story h3{font-size:19px;font-weight:800;letter-spacing:-.012em;margin:3px 0 6px;line-height:1.2}
.story p{font-size:13px;margin:0 0 8px;line-height:1.45}
.story p b{color:var(--un-blue-dark)}
.story .nav{display:flex;align-items:center;gap:14px;margin-top:6px}
.story .dots{display:flex;gap:3px;flex:1}
.story .dots i{width:14px;height:15px;padding:6px 0;box-sizing:border-box;background:var(--grey-border) content-box;cursor:pointer;transition:background-color .15s}
.story .dots i:hover{background-color:var(--grey)}
.story .dots i.on{background-color:var(--un-blue)}
.btn-solid{border:0;background:var(--un-blue-text);color:#fff;border-radius:99px;padding:7px 16px;font:600 12.5px/1.2 var(--font);cursor:pointer;transition:background .15s}
.btn-solid:hover{background:var(--un-blue-dark)}
.btn-solid:disabled{background:var(--grey-border);cursor:default}

/* ── compare (chart) ── */
#scatter{position:absolute;inset:0;background:var(--unblue-bg-alt);z-index:9;padding:calc(var(--toph,34px) + 14px) 12px 8px;display:flex;gap:clamp(10px,2%,16px)}
#scatter .sc-side{flex:0 0 clamp(180px,30%,232px);min-width:0;overflow-y:auto;display:flex;flex-direction:column;gap:7px;padding-right:2px}
#scatter .sc-dots{display:flex;align-items:center;gap:8px;flex-wrap:wrap}
#scatter .sc-eye{font-size:10.5px;font-weight:600;letter-spacing:.04em;text-transform:uppercase;color:var(--grey-text);margin-top:4px}
#scatter h4{font:700 15.5px/1.25 var(--font);color:var(--un-blue-dark);margin:0}
#scatter .sc-find{font-size:12.5px;line-height:1.45;color:var(--grey-dark);margin:0}
#scatter .sc-warn{color:var(--caveat)}
#scatter .sc-sel{font-size:12px;line-height:1.45;margin:0;padding:7px 0 0;border-top:1px solid var(--grey-rule);color:var(--grey-dark)}
#scatter .sc-sel b{color:var(--sel)}
#scatter .sc-xy{font-weight:600;font-variant-numeric:tabular-nums}
#scatter .sc-path{color:var(--grey-text);font-size:11px}
/* the key: what the colour stands for (a menu) and its classes with the number of dots. A name that is a door to a region, a group or a
   slice turns blue when pointed at and is navy and bold when it is the one selected (no pill, no frame) */
#scatter .sc-keyblock{margin-top:auto;padding-top:7px;border-top:1px solid var(--grey-rule);display:flex;flex-direction:column;gap:4px}
#scatter .sc-colby{font-size:11.5px;color:var(--grey-text);display:flex;align-items:center;gap:6px;min-width:0}
#scatter .sc-leg{display:flex;flex-wrap:wrap;gap:3px 10px;font-size:11.5px;color:var(--grey-text)}
#scatter .sc-key small{font-size:10.5px;font-variant-numeric:tabular-nums;opacity:.8}
#scatter .sc-key.door{cursor:pointer}
#scatter .sc-key.door:hover{color:var(--un-blue-text)}
#scatter .sc-key.on{color:var(--sel);font-weight:700}
#scatter #sc-mode{flex-wrap:wrap}
#scatter #sc-mode .btn-toggle{padding-left:4px;padding-right:4px;font-size:12.5px}
#scatter .sc-side.tight #sc-mode .btn-toggle{padding-left:3px;padding-right:3px;font-size:12px}
#scatter .sc-leg>span{white-space:nowrap}
#scatter .sc-leg>span.sz{white-space:normal;flex-basis:100%}
#scatter .sc-dot{display:inline-block;width:9px;height:9px;border-radius:50%;margin-right:4px;box-sizing:border-box}
#scatter .sc-dot.hol{background:transparent;border:1.5px solid}
#scatter .sc-size{display:inline-block;width:11px;height:11px;border-radius:50%;border:1px solid var(--grey-text);margin-right:4px;vertical-align:-1px;box-sizing:border-box}
#scatter .sc-hint{font-size:11px;line-height:1.4;color:var(--grey-text);margin:0}
#scatter .sc-side.tight .sc-hint,#scatter .sc-side.tight .sc-eye{display:none}
#scatter .sc-side.tight{gap:5px}
#scatter .sc-side.tight h4{font-size:14.5px}
#scatter .sc-side.tight .sc-find{font-size:12px;line-height:1.4}
#scatter .sc-side.tight .sc-keyblock{margin-top:0}
#scatter .sc-main{flex:1;min-width:0;display:flex;flex-direction:column}
#scatter .sc-yrow,#scatter .sc-xrow{display:flex;align-items:center;gap:5px;min-height:26px;font-size:11.5px;min-width:0}
#scatter .sc-xrow{padding-right:38px}
#scatter .sc-xr{display:flex;align-items:center;gap:5px;margin-left:auto;min-width:0;flex:0 1 auto;max-width:75%}
#scatter .sc-arr{font-weight:700;color:var(--un-blue-dark);flex-shrink:0}
#scatter .sc-axt{font-weight:600;color:var(--grey-dark);min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
#scatter .sc-axt:empty{display:none}
#scatter select{border:0;border-bottom:1px solid var(--grey-rule);background:transparent;padding:3px 2px;font:600 12px/1.2 var(--font);color:var(--grey-dark);min-width:0;max-width:100%;field-sizing:content;cursor:pointer}
#scatter select:hover{border-bottom-color:var(--un-blue-dark);color:var(--un-blue-dark)}
#scatter #sc-reset{margin-left:auto;font-size:11.5px;padding:3px 0;flex-shrink:0}
#scatter .sc-note{font-size:11px;color:var(--grey-text);min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;flex:1 1 0}
#scatter .sc-body{flex:1;min-height:0;position:relative}
#scatter svg{position:absolute;inset:0;width:100%;height:100%}
#scatter .ax text{font-size:10.5px;fill:var(--grey-text)}
#scatter .ax path,#scatter .ax line{stroke:var(--grey-border)}
#scatter .bub{stroke:#fff;stroke-width:.8px;cursor:pointer;fill-opacity:.78}
#scatter .bub.hol{fill-opacity:.1;stroke-width:1.4px}
#scatter .bub.cmp{stroke:var(--grey-dark);stroke-width:1.2px;stroke-dasharray:3 2}
#scatter .bub.sel{stroke:var(--grey-dark);stroke-width:1.4px;fill-opacity:1}      /* the selected dot: solid, with a fine ring, its name in bold and its path over the years */
#scatter .bub.hol.sel{fill-opacity:.35}
#scatter .blab{font-size:10px;font-weight:600;fill:var(--grey-dark);paint-order:stroke;stroke:#fff;stroke-width:3px;pointer-events:none}
#scatter .blab.sel{font-size:11.5px;font-weight:800;fill:#000}
#scatter .refline{stroke:var(--grey);stroke-dasharray:3 3}
#scatter .refline.diag{stroke:var(--grey-text);stroke-dasharray:5 3}
#scatter .sc-quad,#scatter .sc-ref{font-size:10.5px;font-weight:600;fill:var(--grey-text);pointer-events:none;paint-order:stroke;stroke:var(--unblue-bg-alt);stroke-width:3px}
#scatter .sc-ref{fill:var(--grey-dark)}
#scatter .sc-empty{font-size:13px;fill:var(--grey-text)}
#scatter .trail{pointer-events:none}
#scatter .trail path{fill:none;stroke:var(--grey-dark);stroke-width:1px;opacity:.6}
#scatter .trail circle{fill:var(--grey-dark);opacity:.6}
#scatter .trail text{font-size:9.5px;font-weight:600;fill:var(--grey-text);paint-order:stroke;stroke:var(--unblue-bg-alt);stroke-width:3px}
#scatter .trail.cmp path{stroke-dasharray:3 3;opacity:.45}
#scatter .trail.hov path,#scatter .trail.hov circle{opacity:.5}
#scatter svg.few .bub{fill-opacity:.66}
#scatter .trail.cmp circle,#scatter .trail.cmp text{opacity:.45}
#scatter .sc-year{font-size:56px;font-weight:700;fill:rgba(0,73,144,.10);pointer-events:none}
/* narrow stage: the words go above the chart */
#scatter.narrow{flex-direction:column;gap:6px;overflow-y:auto}
#scatter.narrow .sc-side{flex:none;overflow:visible;gap:4px}
#scatter.narrow .sc-keyblock{margin-top:0}
#scatter.narrow .sc-hint{display:none}
#scatter.narrow .sc-main{flex:1 0 250px}

/* ── table view ── */
#tableview{position:absolute;inset:0;background:var(--unblue-bg-alt);z-index:9;padding:calc(var(--toph,34px) + 12px) 12px 8px;display:flex;flex-direction:column;min-height:0}
.tv-note{font-size:11.5px;color:var(--grey-text);margin:0 0 6px;display:flex;gap:12px;align-items:baseline;justify-content:space-between}
.tv-note .btn-line{font-size:12px;padding:3px 0;flex-shrink:0}
/* a table as in a printed report: a firm rule above, a fine one under the headings, hairlines between rows, no frame.
   The selected economy is navy and bold; the row pointed at gets a pale band from edge to edge */
.tv-scroll{flex:1;min-height:0;overflow:auto;background:#fff;border-top:2px solid var(--grey-dark)}
table.tv{border-collapse:collapse;width:100%;font-size:12px}
table.tv th{position:sticky;top:0;background:#fff;box-shadow:inset 0 -1px 0 var(--grey-dark);color:var(--grey-dark);font-weight:700;font-size:11.5px;text-align:right;padding:7px 8px 6px;cursor:pointer;white-space:normal;line-height:1.2;vertical-align:bottom;user-select:none;transition:color .15s}
table.tv th:not(.l){max-width:92px}
table.tv th:hover{color:var(--un-blue-text)}
table.tv td{text-align:right;padding:4px 8px;border-bottom:1px solid #f1efed;white-space:nowrap;font-variant-numeric:tabular-nums}
table.tv .l{text-align:left}
table.tv td.l{max-width:190px;overflow:hidden;text-overflow:ellipsis}
table.tv .rk{display:inline-block;width:26px;color:var(--grey-text);font-size:11px}
table.tv td small{color:var(--caveat);font-size:10.5px}
table.tv tbody tr{cursor:pointer}
table.tv tbody tr:hover{background:var(--unblue-bg)}
table.tv tbody tr.on td,table.tv tbody tr.on .rk{color:var(--sel);font-weight:700}
table.tv tbody tr.norep td{color:var(--grey-text)}
table.tv tbody tr:focus-visible{outline:2px solid var(--un-blue);outline-offset:-2px}
/* ── methodology dialog ── */
dialog#method{border:0;border-top:5px solid var(--un-blue);border-radius:0;box-shadow:var(--shadow-lg);padding:0;width:min(820px,92vw);max-height:86vh}
dialog#method::backdrop{background:rgba(0,29,61,.35)}
.method-in{padding:20px 26px 22px;position:relative}
.method-in h2{font-size:22px;font-weight:800;letter-spacing:-.015em;margin:0 0 8px}
.method-in h3{font-size:13px;color:var(--un-blue-dark);margin:16px 0 4px;text-transform:uppercase;letter-spacing:.04em}
.method-in p,.method-in li{font-size:12.5px;line-height:1.5;margin:4px 0}
.method-in h4.lay{font-size:12px;margin:12px 0 2px;color:var(--grey-dark)}
.method-in dl{display:grid;grid-template-columns:220px 1fr;gap:5px 14px;font-size:12.5px;margin:6px 0}
.method-in dt{font-weight:600}.method-in dd{margin:0;color:#3b3531}
#method-close{position:absolute;right:20px;top:14px}

/* ── first page (cover): the world pizza on a full page, in front of the explorer (js/cover.js) ──
   Everything except the sheet, the blades and the edge tab sits on an ARTBOARD of fixed height (760) and flexible width (1250–1600)
   that is scaled as one object to the window (cover.js, fit()): headline, text and pizza keep the same proportions on every
   landscape window, whatever its shape, and only the margins take up what is left. Sizes on the artboard are therefore plain px.
   Narrow or very low windows get the stacked page (.cover.stack), which flows and scrolls. */
.c-p{color:var(--plastic)}.c-s{color:var(--subs)}
.cover{--edge:58px;position:fixed;inset:0;z-index:90;overflow:hidden}
.cover.off{display:none}
body.covered{overflow:hidden;height:100dvh}
.cv-sheet{position:absolute;inset:0;border-top:5px solid var(--un-blue);background:#fff}      /* a white page under the blue band of the header: no glow behind the pizza */
.cv-art{position:absolute;z-index:3;left:var(--ax,0px);top:var(--ay,0px);width:var(--aw,1320px);height:760px;transform:scale(var(--k,1));transform-origin:0 0;
  display:grid;grid-template-columns:minmax(500px,580px) minmax(630px,1fr);grid-template-rows:auto minmax(0,1fr);column-gap:36px;padding:0 36px 0 48px}
.cv-top{grid-column:1/-1;position:relative;z-index:5;display:flex;align-items:center;gap:10px;padding:16px 0 0;font-size:12.5px;font-weight:500;color:var(--grey-text)}
.cv-top img{width:34px;height:34px;flex-shrink:0}
.cv-top .sp{flex:1}
.cv-text{position:relative;z-index:1;align-self:start;min-width:0;padding:30px 0 0}
.cv-eyebrow{font-size:11.5px;font-weight:700;letter-spacing:.09em;text-transform:uppercase;color:var(--un-blue-dark);margin:0 0 10px}
.cv-text h1{font-size:46px;line-height:1.04;font-weight:800;letter-spacing:-.025em;color:#000;margin:0 0 14px}
.cv-lead{font-size:15.5px;line-height:1.5;color:#3b3531;margin:0 0 18px}
.cv-lead b{color:#000}
.cv-prov{color:var(--caveat);font-weight:500}
/* key figures: large numerals with their words under them, set apart by space alone */
.cv-nums{display:grid;grid-template-columns:repeat(3,auto);justify-content:start;gap:10px 30px;margin:0 0 18px}
.cv-num{min-width:0}
.cv-num b{display:block;font-size:27px;line-height:1.1;font-weight:800;letter-spacing:-.02em;white-space:nowrap}
.cv-num b i{font-style:normal;font-weight:400;color:var(--grey);margin:0 .28em}
.cv-num>span{display:block;font-size:12px;line-height:1.3;color:var(--grey-text);max-width:18ch;margin-top:3px}
/* reading notes under a hairline: how to read the pizza, or the slice under the pointer (a square of its colour before its name) */
.cv-card{border-top:1px solid var(--grey-border);padding:13px 0 0;min-height:200px;margin:0 0 18px;display:flex;flex-direction:column;justify-content:flex-start}      /* as high as its tallest content (a slice with its trend): nothing below moves when the pointer crosses the pizza */
.cv-how>b{display:block;font-size:14px;font-weight:700;margin-bottom:8px}
.cv-how>div{display:flex;gap:9px;align-items:baseline;font-size:13px;line-height:1.4;margin:5px 0;color:#3b3531}
.cv-how>div i{width:10px;height:10px;border-radius:2px;flex-shrink:0;transform:translateY(1px)}
.cv-how p{font-size:12.5px;color:var(--grey-text);margin:10px 0 0}
.cv-how p b{color:var(--grey-dark)}
.cv-ch b{display:block;font-size:16px;font-weight:700;line-height:1.25;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cv-ch>b::before,.cv-bt>div>b::before{content:"";display:inline-block;width:10px;height:10px;border-radius:2px;background:var(--c,var(--un-blue));margin-right:8px}
.cv-ch sup{color:var(--caveat);cursor:help}
.cv-ch span{display:block;font-size:12px;color:var(--grey-text);overflow:hidden;text-overflow:ellipsis;white-space:nowrap;margin-top:1px}
.cv-cn{display:flex;gap:22px;margin:8px 0 2px}
.cv-cn b{display:block;font-size:17px;line-height:1.2;white-space:nowrap}
.cv-cn span{display:block;font-size:11.5px;color:var(--grey-text);white-space:nowrap}
.cv-cs svg{display:block;width:100%;max-width:360px;height:auto}
.cv-ct{font-size:12.5px;margin:2px 0 4px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.cv-ct span{color:var(--grey-text);margin-right:4px}
.cv-cf{display:flex;gap:16px;align-items:center;font-size:12px;color:var(--grey-text);min-height:24px}
.cv-cta{display:flex;align-items:center;gap:20px;flex-wrap:wrap}
/* the way in: one solid pill, as on UNCTAD's report pages; darker when pointed at, nothing else moves but the arrow */
.cv-btn{border:0;background:var(--un-blue-text);color:#fff;border-radius:99px;padding:13px 24px;font:700 15px/1 var(--font);cursor:pointer;display:inline-flex;align-items:center;gap:10px;transition:background .15s}
.cv-btn:hover{background:var(--un-blue-dark)}
.cv-btn span{display:inline-block;transition:transform .2s}
.cv-btn:hover span{transform:translateX(4px)}
.cv-cta .btn-line{font-size:13.5px}
.cv-src{font-size:11px;line-height:1.45;color:var(--grey-text);margin:14px 0 0}
.cv-src strong{color:var(--grey-dark)}
.cv-stage{position:relative;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:4px;min-width:0;min-height:0;padding:0 0 8px}
.cv-pizza{position:relative;z-index:3;width:630px;height:630px;flex-shrink:0;margin-top:-22px}      /* its square reaches into the row above (the circle does not): room for the ribbon below */
.cv-fy,.cv-spin{width:100%;height:100%}
.cv-spin{transform-origin:50% 50%}
#cover-pizza{display:block;width:100%;height:100%;overflow:visible}
/* under the pizza: play, the year with its total, and the ribbon = the same pizza over the years (js/cover.js). The row reaches 28 px
   into the empty margin of the pizza's drawing (the circle is 85% of its square), so the pizza keeps its size */
.cv-year{position:relative;z-index:4;display:flex;align-items:flex-end;gap:12px;width:630px;height:114px;margin-top:-28px;flex-shrink:0;pointer-events:none}
.cv-year>*{pointer-events:auto}
.cv-year>button.icon{margin-bottom:38px}
.cv-yr{flex:0 0 82px;display:flex;flex-direction:column;height:62px;justify-content:flex-start;margin-bottom:20px}
.cv-yr b{font-size:25px;line-height:1;font-weight:800;letter-spacing:-.02em;font-variant-numeric:tabular-nums}
.cv-yr span{font-size:11.5px;line-height:1.3;color:var(--grey-text);margin-top:4px;white-space:nowrap}
.cv-yr span i{display:block;font-style:normal;font-weight:600;color:var(--caveat)}
.cv-rib{position:relative;flex:1;min-width:0;height:100%}
.cv-rib input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;pointer-events:none}
.cv-rib:has(input:focus-visible){outline:2px solid var(--un-blue);outline-offset:3px}
#cv-ribbon{display:block;width:100%;height:100%;overflow:visible;cursor:ew-resize;touch-action:pan-y;user-select:none}
#cv-ribbon .bd{stroke:#fff;stroke-width:.6px;stroke-linejoin:round;transition:opacity .18s}
#cv-ribbon.hot .bd{opacity:.2}
#cv-ribbon.hot .bd.in{opacity:.45}
#cv-ribbon .hl{stroke-width:.8px;stroke-linejoin:round;pointer-events:none}
#cv-ribbon .pv{pointer-events:none;opacity:.6}
#cv-ribbon .ax line{stroke:var(--grey-rule)}
#cv-ribbon text{font-family:var(--font);pointer-events:none}
#cv-ribbon .ax text{font-size:10px;fill:var(--grey-text);font-variant-numeric:tabular-nums}
#cv-ribbon .ax text.prov{fill:var(--caveat)}
#cv-ribbon .rc{font-size:10.5px;fill:var(--grey-text)}
#cv-ribbon .ev{font-size:9.5px;fill:var(--grey-text)}
#cv-ribbon .evl{stroke:var(--grey);stroke-dasharray:1.5 2}
#cv-ribbon .guide{stroke:var(--grey-dark);stroke-width:1px;stroke-dasharray:2 2;pointer-events:none}
#cv-ribbon .mk{pointer-events:none}
#cv-ribbon .mk line{stroke:var(--grey-dark);stroke-width:1px}
#cv-ribbon .mk circle{fill:#fff;stroke:var(--grey-dark);stroke-width:1.4px}
/* a piece taken from the pizza: the board replaces the text below the headline */
.cover.cut .cv-lead,.cover.cut .cv-nums,.cover.cut .cv-card,.cover.cut .cv-src{display:none}
.cover.cutting .cv-text{z-index:4}
.cv-board{margin:0 0 14px;animation:np-fade .3s ease-out both}
.cv-bh{display:flex;align-items:baseline;gap:10px;margin:2px 0 8px}
.cv-crumbs{font-size:12.5px;color:var(--grey-text);line-height:1.4;flex:1;min-width:0}
.cv-crumbs button{border:0;background:none;color:var(--un-blue-dark);cursor:pointer;font:inherit;font-weight:600;padding:0}
.cv-crumbs button:hover{text-decoration:underline}
.cv-crumbs .sep{margin:0 5px}.cv-crumbs .cur{color:var(--grey-dark);font-weight:600}
.cv-x{border:0;background:none;color:var(--un-blue-dark);font:600 12.5px/1.2 var(--font);cursor:pointer;padding:3px 0;white-space:nowrap;flex-shrink:0;text-underline-offset:3px;transition:color .15s}
.cv-x:hover{color:var(--un-blue-text);text-decoration:underline}
.cv-bt{display:flex;gap:10px;align-items:flex-start;margin:0 0 12px}
.cv-bt b{display:block;font-size:19px;font-weight:800;letter-spacing:-.012em;line-height:1.2}
.cv-bt sup{color:var(--caveat);cursor:help}
.cv-bt span{display:block;font-size:12.5px;color:var(--grey-text);margin-top:3px}
.cv-bt span b{display:inline;font-size:inherit;color:var(--grey-dark)}
.cv-cap{font-size:11px;font-weight:700;letter-spacing:.08em;text-transform:uppercase;color:var(--grey-text);margin:0 0 2px}
.cv-cap small{font-weight:500;letter-spacing:0;text-transform:none;font-size:11.5px;margin-left:6px}
#cv-cut{display:block;width:100%;max-width:540px;height:auto;overflow:visible;margin:0 0 8px}
#cv-cut .pc{stroke:#fff;stroke-width:.6px;stroke-linejoin:round}
#cv-cut .fly{stroke:#fff;stroke-width:.8px;pointer-events:none}
#cv-cut .knife{stroke:var(--grey-dark);stroke-width:1.4px;stroke-linecap:round;pointer-events:none}
#cv-cut .base{stroke:var(--grey-rule);stroke-width:1px}
#cv-cut text{font-family:var(--font);text-anchor:middle;pointer-events:none}
#cv-cut .sh{font-size:13px;font-weight:700;fill:var(--grey-dark)}
#cv-cut .nm{font-size:12px;font-weight:500;fill:var(--grey-text)}
#cv-cut .hit{fill:transparent;cursor:pointer}
#cv-cut .lb.hl .nm{fill:var(--un-blue-dark);font-weight:700}
#cv-cut .none{font-size:13px;fill:var(--grey-text)}
/* the same cut laid flat: every piece keeps its true share, the rest of the world included */
#cv-cut .sg{stroke:none}
#cv-cut .sg.rest{stroke:var(--grey);stroke-width:.6px}
#cv-cut .sl{font-size:12px;font-weight:500;fill:var(--grey-text)}
#cv-cut .sl .b{font-size:13px;font-weight:700;fill:var(--grey-dark)}
/* the pieces inside (or next to) the taken one: a key of colour squares and names that can be clicked, not a row of pills */
.cv-chips{display:flex;flex-wrap:wrap;gap:3px 18px;max-height:96px;overflow-y:auto;padding:3px 0}
.cv-chip{display:inline-flex;align-items:center;gap:6px;border:0;background:none;padding:2px 0;font:500 12.5px/1.3 var(--font);color:var(--grey-dark);cursor:pointer;max-width:100%;transition:color .15s}
.cv-chip:hover{color:var(--un-blue-text)}
.cv-chip:hover span{text-decoration:underline;text-underline-offset:3px;text-decoration-thickness:1px}
.cv-chip.on{color:var(--sel);font-weight:700}
.cv-chip i{width:9px;height:9px;border-radius:2px;flex-shrink:0}
.cv-chip span{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.cv-chip small{color:var(--grey-text);font-size:11.5px;font-weight:500;flex-shrink:0}
/* the tab on the right edge: at rest one blue strip; in the film it is the middle one of three slanted blades */
.cv-blades{position:absolute;inset:0;z-index:2;pointer-events:none}
.cv-blades i{position:absolute;inset:0;transition:clip-path .3s cubic-bezier(.2,.7,.2,1)}
.cv-blades .b1{background:var(--un-blue);clip-path:polygon(calc(100% - var(--edge)) 0,100% 0,100% 100%,calc(100% - var(--edge)) 100%)}
.cv-blades .b2{background:var(--un-blue-dark);clip-path:polygon(calc(100% - var(--edge)) 0,calc(100% - var(--edge)) 0,calc(100% - var(--edge)) 100%,calc(100% - var(--edge)) 100%)}
.cv-blades .b3{background:var(--un-green);clip-path:polygon(100% 0,100% 0,100% 100%,100% 100%)}
.cover.peek .b1{clip-path:polygon(calc(100% - var(--edge) - 22px) 0,100% 0,100% 100%,calc(100% - var(--edge)) 100%)}
.cover.peek .b2{clip-path:polygon(calc(100% - var(--edge) - 32px) 0,calc(100% - var(--edge) - 22px) 0,calc(100% - var(--edge)) 100%,calc(100% - var(--edge) - 3px) 100%)}
.cv-edge{position:absolute;z-index:4;top:0;right:0;bottom:0;width:var(--edge);border:0;padding:0;background:transparent;color:#fff;cursor:pointer;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:16px}
.cv-edge span{writing-mode:vertical-rl;rotate:180deg;font:700 12px/1 var(--font);letter-spacing:.18em;text-transform:uppercase;white-space:nowrap}
.cv-edge b{font-size:22px;font-weight:400;line-height:1;animation:cv-nudge 1.8s ease-in-out infinite}
.cv-edge:focus-visible{outline:2px solid #fff;outline-offset:-5px}
@keyframes cv-nudge{0%,100%{transform:translateX(0)}50%{transform:translateX(5px)}}
/* arrival of the page */
@keyframes cv-up{from{opacity:0;transform:translateY(14px)}}
@keyframes cv-pop{from{opacity:0;transform:scale(.9) rotate(-24deg)}}
@keyframes cv-slide{from{transform:translateX(100%)}}
.cover.intro .cv-top,.cover.intro .cv-text>*,.cover.intro .cv-year{animation:cv-up .6s cubic-bezier(.2,.7,.2,1) both}
.cover.intro .cv-text>*:nth-child(2){animation-delay:.06s}.cover.intro .cv-text>*:nth-child(3){animation-delay:.12s}.cover.intro .cv-text>*:nth-child(4){animation-delay:.18s}
.cover.intro .cv-text>*:nth-child(5){animation-delay:.24s}.cover.intro .cv-text>*:nth-child(6){animation-delay:.3s}.cover.intro .cv-text>*:nth-child(7){animation-delay:.36s}.cover.intro .cv-year{animation-delay:.5s}
.cover.intro .cv-spin{animation:cv-pop .9s cubic-bezier(.2,.7,.2,1) both}
.cover.intro .cv-blades,.cover.intro .cv-edge{animation:cv-slide .6s .45s cubic-bezier(.2,.7,.2,1) both}
/* arrival of the explorer while the blades pass over it (right to left) */
@keyframes np-down{from{transform:translateY(-100%)}}
@keyframes np-up{from{transform:translateY(100%)}}
@keyframes np-left{from{transform:translateX(40px);opacity:0}}
@keyframes np-fade{from{opacity:0}}
body.np-in #main-header{animation:np-down .6s .3s cubic-bezier(.2,.7,.2,1) both}
body.np-in #kpi-bar{animation:np-fade .5s .6s both}
body.np-in #panel{animation:np-left .65s .28s cubic-bezier(.2,.7,.2,1) both}
body.np-in #timeline,body.np-in #foot{animation:np-up .6s .45s cubic-bezier(.2,.7,.2,1) both}
body.np-in .map-top,body.np-in #legend,body.np-in .zoomctl{animation:np-fade .5s .8s both}
body.np-in #dock>*:not(.pizza-wrap){animation:np-fade .5s 1.05s both}
/* stacked page: narrow or very low windows. No artboard, no scaling; the page flows and scrolls */
.cover.stack{--edge:0px;overflow-y:auto}
.cover.stack .cv-sheet{position:fixed}
.cover.stack .cv-blades,.cover.stack .cv-edge{display:none}
.cover.stack .cv-art{position:static;width:auto;height:auto;transform:none;display:flex;flex-direction:column;padding:0 16px 28px}
.cover.stack .cv-art>*,.cover.stack .cv-text>*{flex-shrink:0;position:relative;z-index:1}
.cover.stack .cv-text{display:contents}
.cover.stack .cv-top{order:0;padding-top:16px}.cover.stack .cv-eyebrow{order:1;margin-top:14px}.cover.stack .cv-text h1{order:2;font-size:clamp(30px,7vw,44px)}.cover.stack .cv-lead{order:3}
.cover.stack .cv-cta{order:4;margin-bottom:6px}.cover.stack .cv-stage{order:5}.cover.stack .cv-nums{order:6}.cover.stack .cv-card,.cover.stack .cv-board{order:7}.cover.stack .cv-src{order:8}
.cover.stack .cv-board{margin-top:10px}
.cover.stack .cv-nums{display:flex;flex-wrap:wrap}
.cover.stack .cv-pizza{width:min(100%,520px);height:auto;aspect-ratio:1;margin-top:0}
.cover.stack .cv-year{width:min(100%,520px);height:100px;margin-top:-12px}
.cover.stack .cv-top span:not(.sp){display:none}
.cover.stack .cv-chips{max-height:none}

/* ── narrow screens: stack and scroll ── */
@media (max-width:1050px){
  html,body{height:auto}
  body{overflow:auto}
  #stage{display:flex;flex-direction:column}
  #mapwrap{order:1;height:62vh;min-height:360px}
  #dock{order:2;border-right:0;border-top:1px solid var(--grey-border)}
  #panel{order:3;border-left:0;border-top:1px solid var(--grey-border)}
  #dock,#panel{overflow:visible}
  .header-title{flex-wrap:wrap}
  .header-actions{flex-wrap:wrap;gap:6px 14px;width:100%}
  .search{flex:1;min-width:120px}.search input{width:100%}.search-list{left:0;right:auto;width:min(300px,86vw)}
  .tb-sel{max-width:150px}
  .header-text h4{white-space:normal}
  .header-sources{display:none}
  #timeline{position:sticky;bottom:0;z-index:40}
  .search input{width:150px}
  .map-top{flex-direction:column}
  #lens{flex-wrap:wrap}
  .map-top .tb-cap{display:none}
  #timeline{height:74px;padding:2px 8px;gap:6px}
  .tl{height:68px}
  .legend{max-width:230px;font-size:10.5px;padding:6px 8px}
  .story{position:fixed;left:8px;right:8px;bottom:80px;width:auto;z-index:45}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}

/* ═══ touch: no pointer to aim with ═══
   Targets are about 40 px, fields are 16 px (a smaller one makes iOS zoom the page), the time line is dragged sideways by a finger. */
.tl svg{touch-action:pan-y;-webkit-tap-highlight-color:transparent}
.defnote{position:fixed;left:10px;right:10px;bottom:calc(var(--bars,110px) + 10px);z-index:97;background:#fff;box-shadow:var(--pop);padding:10px 12px;font-size:13px;line-height:1.4;color:var(--grey-dark);border-radius:2px;max-width:560px}
@media (pointer:coarse){
  .btn-line,.btn-toggle,.dock-x,.crumbs button{min-height:40px}
  .btn-toggle{display:inline-flex;align-items:center}
  .tb-sel,.search input,#scatter select{font-size:16px}
  .tb-sel{min-height:40px}
  .row{min-height:40px;padding:2px 0}
  .search-list li{padding:11px 12px;font-size:14px}
  .zoomctl button{width:40px;height:40px;font-size:17px}
  .legend .lg-x{padding:11px 13px;right:0;top:0}
  .legend .lg-seg button{padding:11px 0}
  #scatter .sc-key.door{padding:9px 2px}
  .story .dots i{height:30px;padding:13px 0}
  .scope .x{width:36px;height:36px}
  #scatter select,#scatter .sc-colby,#cmp-input{min-height:40px}
  #scatter .sc-colby select{padding:6px 2px}
  table.tv td{padding-top:9px;padding-bottom:9px}
  table.tv th{padding-top:10px;padding-bottom:9px}
  #foot p{font-size:11px}
  .tl .ax text,.tl .tl-lab{font-size:11px}
}

/* ═══ phone ═══
   One column, read from top to bottom as the page was before: header, key numbers, the lens bar and the map (or the chart, or the table),
   then the pizza, then the details. The PAGE scrolls (the browser's own bars fold away); the time line and the five tabs stay at the foot.
   Type is larger than on a desk (the screen is held at arm's length), controls are 44–48 px, and rows of lists are 46 px. The tabs jump to
   a place in the page (Pizza, Details) or change what the first block shows (Map, Compare, Table).
   Emphasis stays in colour and weight, not in boxes (see "the look"). */
.hdr-icon,#tabbar,.hdr-note{display:none}
html.phone{--bars:calc(120px + env(safe-area-inset-bottom,0px));--mw:100vw}
html.phone,html.phone body{height:auto;min-height:100dvh}
html.phone body{display:block;overflow:visible;overscroll-behavior-y:none;padding:0 env(safe-area-inset-right,0px) var(--bars) env(safe-area-inset-left,0px);font-size:14.5px}
/* header: the logo, the title on two lines, search and a menu that holds the rest */
html.phone #main-header{position:relative;border-bottom-width:3px}
html.phone .header-inner{padding:0 4px 0 12px}
html.phone .header-title{flex-wrap:nowrap;gap:8px;padding:0;min-height:54px}
html.phone .header-logo{width:32px;height:32px;padding:0}
html.phone .header-text{flex:1;min-width:0}
html.phone .header-text h3{font-size:15.5px;line-height:1.2;display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;overflow:hidden}
html.phone .header-text h4{display:none}
html.phone .hdr-icon{display:flex;align-items:center;justify-content:center;width:46px;height:46px;border:0;background:none;color:var(--grey-dark);cursor:pointer;flex-shrink:0;padding:0}
html.phone .hdr-icon[aria-expanded="true"]{color:var(--un-blue-dark)}
html.phone .header-actions{display:none;position:absolute;left:0;right:0;top:100%;z-index:60;width:auto;flex-direction:column;align-items:stretch;gap:2px;background:#fff;box-shadow:var(--pop);padding:10px 16px 12px}
html.phone.menu-open .header-actions{display:flex}
html.phone .header-actions .search input{width:100%;padding:12px 2px;font-size:16px}
html.phone .search-list{left:0;right:0;width:auto;max-height:50dvh}
html.phone .search-list li{padding:13px 12px;font-size:15px}
html.phone .header-actions .tb-sel{max-width:none;width:100%;padding:12px 20px 12px 2px;font-size:16px}
html.phone .header-actions .btn-line{text-align:left;padding:13px 0;font-size:16px;min-height:48px;border-top:1px solid var(--grey-border)}
html.phone .header-actions .search,html.phone .header-actions .tb-sel{margin-bottom:4px}
/* key numbers: the name of what is shown, then the four figures two by two */
html.phone #kpi-bar{padding:10px 16px 12px;gap:6px 12px;flex-wrap:wrap;align-items:flex-start}
html.phone .kpi-inner{display:grid;grid-template-columns:1fr 1fr;gap:10px 18px;overflow:visible;align-items:start;width:100%;flex:1 1 100%}
html.phone .kpi-ctx{grid-column:1/-1;flex-direction:row;align-items:baseline;flex-wrap:wrap;gap:0 10px;padding:0;min-width:0}
html.phone .kpi-ctx b{font-size:17px;line-height:1.25;white-space:normal;min-width:0}
html.phone .kpi-ctx span{font-size:13px;white-space:normal}
html.phone .kpi-divider{display:none}
html.phone .kpi-item{white-space:normal;min-width:0;flex-shrink:1;gap:2px}
html.phone .kpi-value{font-size:21px;line-height:1.15;white-space:nowrap;letter-spacing:-.01em}
html.phone .kpi-lead .kpi-value{font-size:23px}
html.phone .kpi-label{font-size:12.5px;line-height:1.25}
html.phone .kpi-warn{grid-column:1/-1;margin-left:0;white-space:normal;font-size:13px}
html.phone #meas-fld{flex-basis:100%}
html.phone #meas .btn-toggle{font-size:15px;padding:10px 12px}
/* the page: map (or chart, or table), then the pizza, then the details */
html.phone #stage{display:flex;flex-direction:column;flex:none;min-height:0}
html.phone #mapwrap{order:1;position:relative;overflow:hidden;min-height:0;flex:none;
  height:calc(var(--toph,48px) + 8px + (var(--mw) - 20px) / 2.05 + 14px)}      /* toolbar + the map, as high as it is wide / 2.05 */
html.phone[data-view="scatter"] #mapwrap,html.phone[data-view="table"] #mapwrap{height:auto;overflow:visible}
html.phone #dock{order:2;display:block;position:static;visibility:visible;overflow:visible;border:0;border-top:1px solid var(--grey-border);padding:14px 16px 8px}
html.phone #panel{order:3;display:block;position:static;visibility:visible;overflow:visible;border:0;border-top:1px solid var(--grey-border);padding:16px 16px 20px}
html.phone .dock-head{min-height:30px}
html.phone .dock-head .cap{font-size:12px}
html.phone .crumbs{font-size:14px;line-height:1.4}
html.phone .dock-x{font-size:13.5px;padding:6px 0}
html.phone .pizza-wrap{max-width:min(100%,440px);margin:6px auto 0}
html.phone .pz{--pzs:1.42}
html.phone .pizza-note{font-size:13px;margin:6px 0 10px}
/* lists: rows a finger can hit, names and values that can be read */
html.phone .row{min-height:46px;padding:4px 0;column-gap:8px}
html.phone .row .nm{font-size:14.5px;padding-left:8px}
html.phone .row .vl{font-size:13.5px;padding-right:8px}
html.phone .row .sw{width:11px;height:11px}
html.phone .row.rank .rk{font-size:12.5px}
html.phone .row .bar{top:3px;bottom:3px}
html.phone .slice-list .group-h,html.phone .panel .group-h{font-size:13px;margin:16px 0 4px;padding-bottom:5px}
/* the panel */
html.phone .panel h2{font-size:24px}
html.phone .panel .sub{font-size:14px;margin:3px 0 10px}
html.phone .tag{font-size:13px}
html.phone .facts{gap:0 22px;margin:10px 0 8px}
html.phone .fact{padding:10px 0 11px}
html.phone .fact .v{font-size:22px}
html.phone .fact .l{font-size:13px;line-height:1.35;margin-top:2px}
html.phone .panel p.note{font-size:13.5px;line-height:1.45;margin:8px 0}
html.phone .layer-h{font-size:12px;margin:22px 0 6px}
html.phone details.sec>summary{padding:13px 2px 13px 22px;min-height:48px;align-items:center}
html.phone details.sec>summary::before{left:5px;top:20px;width:7px;height:7px}
html.phone details.sec[open]>summary::before{top:18px}
html.phone details.sec .st{font-size:15px}
html.phone details.sec .sh{font-size:12.5px}
html.phone .ns-l,html.phone .mk-l,html.phone .cmp-l{font-size:12.5px}
html.phone table.cmp{font-size:13.5px}
html.phone table.cmp th{font-size:12.5px}
html.phone table.rr{font-size:12.5px}
html.phone .cmp-pick input{font-size:16px;padding:10px 2px}
html.phone .hs{font-size:12.5px}
html.phone .panel p.dl .btn-line{font-size:15px;padding:12px 0;line-height:1.35}
html.phone .panel .spark svg{max-height:120px}
/* the lens bar over the map: one row that scrolls sideways; the second-layer lenses are in it, not in a menu; the view is chosen in the tabs */
html.phone .map-top{left:0;right:0;top:0;padding:0;gap:0;flex-wrap:wrap;background:#fff;border-bottom:1px solid var(--grey-border);pointer-events:auto;flex-direction:row;z-index:12}
html.phone .map-top>*:not(.scope){background:none;padding:0;border-radius:0}
html.phone .map-top>.tb-fld:nth-child(2){display:none}
html.phone .map-top>.tb-fld:first-child{flex:1 1 100%;min-width:0}
html.phone .map-top .tb-cap{display:none}
html.phone #lens{flex-wrap:nowrap;overflow-x:auto;scrollbar-width:none;padding:0 6px;gap:0;width:100%;-webkit-mask-image:linear-gradient(to right,#000 calc(100% - 30px),transparent);mask-image:linear-gradient(to right,#000 calc(100% - 30px),transparent)}
html.phone #lens::-webkit-scrollbar{display:none}
html.phone #lens .btn-toggle{flex-shrink:0;font-size:15px;padding:14px 11px 15px;background-position:11px 100%;min-height:50px}
html.phone .btn-toggle.active{background-size:calc(100% - 22px) 3px}
html.phone .more{display:contents}
html.phone #lens-more{display:none}
html.phone #lens-menu,html.phone #lens-menu.hidden{display:contents!important}
html.phone .menu button{display:block;flex-shrink:0;padding:14px 11px 15px;border-radius:0;font:600 15px/1.2 var(--font);color:var(--grey-text);white-space:nowrap;background:linear-gradient(var(--un-blue),var(--un-blue)) no-repeat 11px 100%/0 3px;text-align:left}
html.phone .menu button b{font-size:15px;font-weight:600;color:inherit}
html.phone .menu button span{display:none}
html.phone .menu button.active{color:var(--un-blue-dark);background-size:calc(100% - 22px) 3px}
html.phone .scope{margin:6px 10px 8px;order:3;flex:0 0 auto;min-height:38px;padding-left:16px;font-size:14.5px}
html.phone .scope .x{width:38px;height:38px;font-size:20px}
html.phone .legend{max-width:calc(100% - 76px);bottom:8px;left:8px;font-size:13px;padding:10px 12px}
html.phone .legend b{font-size:13px}
html.phone .legend .li{font-size:12.5px}
html.phone .legend .ticks{font-size:11.5px}
html.phone .legend.min{padding:0;min-height:44px;display:flex;align-items:center}
html.phone .legend .lg-t{font-size:13.5px;padding:0 34px 0 12px;line-height:44px}
html.phone .legend .lg-x{width:44px;height:44px;padding:0;right:0;top:0;font-size:18px}
html.phone .zoomctl{right:8px;bottom:8px}
html.phone .zoomctl button{width:44px;height:44px}
html.phone #zin,html.phone #zout{display:none}
html.phone #mapover .lbl{font-size:11.5px}
html.phone .mapmsg{max-width:90%;font-size:13.5px;top:60px}
html.phone .story{position:fixed;left:0;right:0;bottom:var(--bars);width:auto;max-height:46dvh;overflow-y:auto;box-shadow:0 -6px 24px rgba(0,58,117,.14);padding:14px 18px 12px;border-radius:0;z-index:45}
html.phone.storying #kpi-bar{display:none}
html.phone .story p{font-size:15px;line-height:1.5}
html.phone .story h3{font-size:19px}
html.phone .story .step{font-size:12px}
html.phone .story .nav{gap:16px}
html.phone .story .btn-line,html.phone .story .btn-solid{font-size:15.5px;min-height:46px}
/* time line and tabs: fixed at the foot, above the home bar */
html.phone #timeline{position:fixed;left:0;right:0;bottom:calc(54px + env(safe-area-inset-bottom,0px));z-index:40;height:60px;padding:2px 12px;gap:8px}
html.phone .tl{height:56px}
html.phone .tl-year{width:56px}
html.phone .tl-year b{font-size:21px}
html.phone .tl-year .cap{font-size:11px}
html.phone #play{width:46px;height:46px;flex-shrink:0}
html.phone #foot{padding:14px 16px 20px}
html.phone #foot p{font-size:12px;line-height:1.5;margin-bottom:6px}
html.phone #tabbar{display:flex;position:fixed;left:0;right:0;bottom:0;background:#fff;border-top:1px solid var(--grey-border);padding-bottom:env(safe-area-inset-bottom,0px);z-index:41}
#tabbar button{flex:1 1 0;min-width:0;min-height:54px;border:0;background:none;font:600 14.5px/1.1 var(--font);color:var(--grey-text);position:relative;cursor:pointer;padding:0 2px;-webkit-tap-highlight-color:transparent}
#tabbar button.on{color:var(--un-blue-dark);font-weight:700}
#tabbar button.on::before{content:"";position:absolute;left:24%;right:24%;top:-1px;height:3px;background:var(--un-blue)}
#tabbar button.first-page-tab{border-left:1px solid var(--grey-border)}
#tabbar button.has::after{content:"";position:absolute;top:12px;left:calc(50% + 30px);width:7px;height:7px;border-radius:50%;background:var(--un-blue)}
/* Compare: the question, the chart, then what it says */
html.phone #scatter{position:relative;inset:auto;z-index:auto;padding:calc(var(--toph,50px) + 10px) 14px 18px;flex-direction:column;gap:8px}
html.phone #scatter .sc-side{display:contents}
html.phone #scatter .sc-dots{order:0;gap:6px 10px}
html.phone #scatter .sc-dots .tb-cap{font-size:14px}
html.phone #scatter #sc-mode .btn-toggle{font-size:15px;padding:12px 8px 13px;min-height:46px;background-position:8px 100%}
html.phone #scatter h4{order:1;flex:0 0 auto;font-size:18px;line-height:1.3}
html.phone #scatter .sc-main{order:2;flex:0 0 auto;min-height:0}
html.phone #scatter .sc-body{flex:none;height:clamp(250px,56vw,380px)}
html.phone #scatter .sc-find,html.phone #scatter .sc-sel,html.phone #scatter .sc-keyblock,html.phone #scatter .sc-hint{order:3;flex:0 0 auto}
html.phone #scatter .sc-find{font-size:15px;line-height:1.5}
html.phone #scatter .sc-sel{font-size:14px}
html.phone #scatter .sc-hint{font-size:13px}
html.phone #scatter .sc-keyblock{margin-top:6px}
html.phone #scatter .sc-eye{display:none}
html.phone #scatter .sc-yrow,html.phone #scatter .sc-xrow{min-height:46px;font-size:14px}
html.phone #scatter .sc-xrow{padding-right:0}
html.phone #scatter select{font-size:16px;max-width:100%}
html.phone #scatter .sc-note{display:none}
html.phone #scatter .sc-colby{font-size:14px}
html.phone #scatter .sc-leg{font-size:13.5px;gap:4px 14px}
html.phone #scatter .sc-key small{font-size:12px}
html.phone #scatter .ax text,html.phone #scatter .sc-quad,html.phone #scatter .sc-ref,html.phone #scatter .trail text{font-size:11.5px}
html.phone #scatter .blab{font-size:11.5px}
/* Table: the economy stays in view while the columns scroll sideways; the table is as high as a screen and scrolls inside */
html.phone #tableview{position:relative;inset:auto;z-index:auto;padding:calc(var(--toph,50px) + 8px) 0 0}
html.phone .tv-note{padding:0 14px;flex-wrap:wrap;gap:4px 12px;font-size:13px}
html.phone .tv-note .btn-line{font-size:14.5px;padding:8px 0}
html.phone .tv-scroll{flex:none;height:min(78dvh,640px)}
html.phone table.tv{font-size:13.5px}
html.phone table.tv th{font-size:12.5px;padding:10px 8px 9px}
html.phone table.tv td{padding:11px 8px}
html.phone table.tv th.l,html.phone table.tv td.l{position:sticky;left:0;background:#fff;z-index:2;max-width:44vw;box-shadow:1px 0 0 var(--grey-border)}
html.phone table.tv tbody tr:hover td.l{background:#fff}
/* axes and ticks that sit in drawings: the drawings are in screen pixels here */
html.phone .tl .ax text,html.phone .tl .tl-lab{font-size:11px}
/* the first page: the headline and the way in come first, the pizza next, the explanation after it */
html.phone .cover.stack .cv-eyebrow{display:none}
html.phone .cover.stack .cv-text h1{order:1;font-size:30px;line-height:1.1;margin:10px 0 10px}
html.phone .cover.stack .cv-cta{order:2;margin-bottom:6px}
html.phone .cover.stack .cv-btn{font-size:17px;min-height:52px}
html.phone .cover.stack .cv-stage{order:3}
html.phone .cover.stack .cv-card,html.phone .cover.stack .cv-board{order:4}
html.phone .cover.stack .cv-lead{order:5;margin-top:14px;font-size:16px;line-height:1.55}
html.phone .cover.stack .cv-nums{order:6}
html.phone .cover.stack .cv-src{order:7;font-size:12px}
html.phone .cover.stack .cv-art{padding:0 16px 28px}
html.phone .cover.stack .cv-card{min-height:0;margin-bottom:8px}
html.phone .cover.stack .cv-card,html.phone .cover.stack .cv-how{font-size:15px}
html.phone .cover.stack .cv-pizza{width:min(100%,440px);margin-left:auto;margin-right:auto}
html.phone .cover.stack .cv-year{width:min(100%,440px);margin-left:auto;margin-right:auto}
html.phone .cover.stack .cv-num b{font-size:26px}
html.phone .cover.stack .cv-num>span{font-size:13.5px}
html.phone small,html.phone table.tv td small{font-size:max(11.5px,.85em)}
html.phone .panel input,html.phone .panel select,html.phone input[type=text],html.phone input[type=search]{font-size:16px}
.cv-btn.wait{opacity:.75;cursor:progress}
/* tablets on touch (up to 1050 px): the pizza and the details stand side by side under the map */
@media (min-width:701px){
  html.phone{--mw:100vw}
  html.phone .map-top .tb-cap{display:inline}
  html.phone #stage{flex-direction:row;flex-wrap:wrap;align-items:flex-start}
  html.phone #mapwrap{flex:0 0 100%}
  html.phone #dock{flex:1 1 42%;min-width:0;border-right:1px solid var(--grey-border)}
  html.phone #panel{flex:1 1 52%;min-width:0;border-top:1px solid var(--grey-border)}
  html.phone #scatter{flex-direction:row;gap:20px}
  html.phone #scatter .sc-side{display:flex}
  html.phone #scatter .sc-body{height:auto;flex:1}
  html.phone #scatter .sc-main{flex:1;min-height:340px}
  html.phone .cover.stack .cv-pizza,html.phone .cover.stack .cv-year{width:min(100%,520px)}
  html.phone .pizza-wrap{max-width:min(100%,480px)}
}
/* a phone held sideways (a window of about 340 px): the tabs become a rail on the right, the bars are thin, the map keeps what is left of the screen */
html.land{--mw:calc(100vw - 62px)}
html.land body{padding-right:calc(62px + env(safe-area-inset-right,0px));padding-bottom:50px}
html.land #tabbar{top:0;left:auto;right:0;width:calc(62px + env(safe-area-inset-right,0px));flex-direction:column;border-top:0;border-left:1px solid var(--grey-border);padding:0 env(safe-area-inset-right,0px) 0 0}
html.land #tabbar button{min-height:0;flex:1 1 0;font-size:13px}
html.land #tabbar button.on::before{left:-1px;right:auto;top:22%;bottom:22%;width:3px;height:auto}
html.land #tabbar button.first-page-tab{border-left:0;border-top:1px solid var(--grey-border)}
html.land #tabbar button.has::after{top:6px;left:calc(50% + 24px)}
html.land #main-header{border-bottom-width:2px}
html.land .header-title{min-height:38px}
html.land .header-logo{width:26px;height:26px}
html.land .header-text h3{font-size:14px;-webkit-line-clamp:1}
html.land .hdr-icon{width:40px;height:38px}
html.land #kpi-bar{padding:6px 14px}
html.land .kpi-inner{display:flex;flex-wrap:nowrap;gap:2px 20px;overflow-x:auto;scrollbar-width:none}
html.land .kpi-ctx{grid-column:auto;flex-direction:row;flex-shrink:0}
html.land .kpi-item{flex-shrink:0;white-space:nowrap;max-width:170px}
html.land .kpi-label{font-size:11.5px;overflow:hidden;text-overflow:ellipsis}
html.land .kpi-ctx span{display:none}
html.land .kpi-value{font-size:16px}
html.land .kpi-lead .kpi-value{font-size:17px}
html.land #mapwrap{height:min(calc(var(--toph,48px) + 8px + (var(--mw) - 20px) / 2.05 + 14px),calc(100dvh - 52px))}      /* the screen is the limit: the header and the key numbers are above it, one swipe away */
html.land[data-view="scatter"] #scatter .sc-main,html.land[data-view="table"] #tableview .tv-scroll{min-height:min(300px,100dvh - 120px)}
html.land #scatter .sc-body{min-height:200px}
html.land #timeline{right:calc(62px + env(safe-area-inset-right,0px));bottom:0;height:48px}
html.land .tl{height:46px}
html.land .tl-year{width:auto;flex-direction:row;align-items:baseline;gap:6px}
html.land .tl-year .cap{display:none}
html.land .tl-year b{font-size:18px}
html.land #play{width:42px;height:42px}
html.land .tl .ev{display:none}
html.land .legend{display:none}
html.land .story{right:calc(62px + env(safe-area-inset-right,0px));bottom:48px;max-height:70dvh}
html.land #lens .btn-toggle{padding-top:9px;padding-bottom:10px;min-height:42px}
