/* =================================================================
   c-map: trips from Paris. A world map cropped to the northern band,
   great-circle arcs from home, a card for the selected city.
   Without JS: the map with every arc and label, and the card as a list of cities.
   With JS (html.js): city chips and markers select a city; a dot flies the route.
   ================================================================= */
.c-map{
  --c-ink:var(--ink,#161616);
  --c-ink2:var(--ink-2,#55575B);
  --c-rule:var(--rule,#C8CACE);
  --c-field:var(--field,#EEEFF1);
  --c-paper:var(--paper,#FFFFFF);
  --c-spot:var(--spot,#2852D6);
  --c-eo:var(--ease-out,cubic-bezier(.23,1,.32,1));
  --c-eio:var(--ease-in-out,cubic-bezier(.77,0,.175,1));
  --u:1.32;             /* viewBox units per CSS pixel; set by the script from the map's width */
  display:grid;
  grid-template-columns:minmax(0,1fr) minmax(240px,280px);
  gap:0 36px;
  contain:inline-size;
  align-items:start;
  font-family:var(--font,"Atkinson Hyperlegible Next",Verdana,sans-serif);
  color:var(--c-ink);
  font-size:16px;
  line-height:1.45;
}
.c-map *,.c-map *::before,.c-map *::after{box-sizing:border-box}
.c-map p{margin:0;max-width:none}
.c-map__sr{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap;border:0}
.c-map__main{min-width:0}

/* ---------- the map ---------- */
.c-map__frame{border:2px solid var(--c-ink);border-radius:16px;overflow:hidden;background:var(--c-paper)}
.c-map__canvas{position:relative;width:100%;contain:inline-size}
.c-map__svg{position:absolute;inset:0;width:100%;height:100%;display:block;overflow:visible}
.c-map__grat{fill:none;stroke:var(--c-rule);stroke-width:.75px;vector-effect:non-scaling-stroke;opacity:.75}
.c-map__land{fill:var(--c-field);stroke:var(--c-ink);stroke-width:.7px;stroke-linejoin:round;vector-effect:non-scaling-stroke}
.c-map__arc,.c-map__trail{fill:none;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:1 1}
.c-map__arc{stroke:var(--c-ink);stroke-width:calc(var(--u) * 1.5);stroke-dashoffset:0}
.c-map__trail{stroke:var(--c-spot);stroke-width:calc(var(--u) * 2.4);stroke-dashoffset:1;opacity:0}
.c-map__trail.is-sel{stroke-dashoffset:0;opacity:1}
.c-map.has-sel .c-map__arc:not(.is-sel){opacity:.3}

/* markers: a point with zero size at the city; the dot and the label hang from it */
.c-map__home,.c-map__pin{position:absolute;width:0;height:0;z-index:2}
.c-map__pin{appearance:none;-webkit-appearance:none;margin:0;padding:0;border:0;background:none;font:inherit;color:inherit;cursor:default;-webkit-tap-highlight-color:transparent}
html.js .c-map__pin{cursor:pointer}
.c-map__pin::before{content:"";position:absolute;left:-20px;top:-20px;width:40px;height:40px;border-radius:50%}
.c-map__dot{position:absolute;left:-5.5px;top:-5.5px;width:11px;height:11px;border-radius:50%;background:var(--c-paper);border:2px solid var(--c-ink)}
.c-map__dot::after{content:"";position:absolute;inset:-2px;border-radius:50%;background:var(--c-spot);opacity:0}
.c-map__dot::before{content:"";position:absolute;inset:-2px;border-radius:50%;border:2px solid var(--c-spot);opacity:0}
.c-map__pin.is-sel .c-map__dot{transform:scale(1.18)}
.c-map__pin.is-sel .c-map__dot::after{opacity:1}
.c-map__home .c-map__dot{left:-6.5px;top:-6.5px;width:13px;height:13px;background:var(--c-ink);border:2.5px solid var(--c-paper);outline:1.5px solid var(--c-ink);outline-offset:0}
.c-map__lab{position:absolute;left:0;top:0;white-space:nowrap;font-size:13.5px;font-weight:700;line-height:1.2;color:var(--c-ink);
  text-shadow:0 0 2px var(--c-paper),0 0 2px var(--c-paper),0 0 3px var(--c-paper),0 0 4px var(--c-paper);pointer-events:none}
.c-map__home .c-map__lab{color:var(--c-ink)}
.c-map__pin.is-sel .c-map__lab{color:var(--c-spot)}
.c-map__lab--e{transform:translate(10px,-50%)}
.c-map__lab--w{transform:translate(calc(-100% - 10px),-50%)}
.c-map__lab--n{transform:translate(-50%,calc(-100% - 9px))}
.c-map__lab--s{transform:translate(-50%,9px)}
.c-map__lab--ne{transform:translate(6px,calc(-100% - 5px))}
.c-map__lab--nw{transform:translate(calc(-100% - 6px),calc(-100% - 5px))}
.c-map__lab--se{transform:translate(6px,5px)}
.c-map__lab--sw{transform:translate(calc(-100% - 6px),5px)}
.c-map__home .c-map__lab--e{transform:translate(12px,-50%)}
.c-map__home .c-map__lab--w{transform:translate(calc(-100% - 12px),-50%)}

/* the flying dot */
.c-map__plane{position:absolute;left:0;top:0;width:13px;height:13px;margin:-6.5px 0 0 -6.5px;border-radius:50%;background:var(--c-spot);border:2.5px solid var(--c-paper);outline:1.5px solid var(--c-spot);transform:translate(var(--px,0px),var(--py,0px));opacity:0;z-index:3;pointer-events:none}
.c-map.is-flying .c-map__plane{opacity:1}

/* ---------- controls (JS only) ---------- */
.c-map__controls{display:none;flex-wrap:wrap;align-items:flex-end;gap:14px 28px;margin-top:18px}
html.js .c-map__controls{display:flex}
.c-map__play{display:inline-flex;align-items:center;gap:9px;min-height:44px;padding:10px 17px 10px 14px;border:1.5px solid var(--c-ink);border-radius:0;background:var(--c-paper);color:var(--c-ink);font:600 16px/1.2 var(--font,inherit);cursor:pointer;-webkit-tap-highlight-color:transparent}
.c-map__play:focus-visible{outline:2px solid var(--c-spot);outline-offset:2px}
.c-map__ico{width:16px;height:16px;flex:none;fill:currentColor}
.c-map__play-t{display:grid;text-align:left}
.c-map__play-l{grid-area:1 / 1}
.c-map__play-l--stop{visibility:hidden}
.c-map.is-playing .c-map__play-l--play{visibility:hidden}
.c-map.is-playing .c-map__play-l--stop{visibility:visible}
.c-map__ico-stop{display:none}
.c-map.is-playing .c-map__ico-play{display:none}
.c-map.is-playing .c-map__ico-stop{display:inline}
.c-map__cities{border:0;margin:0;padding:0;min-width:0;min-inline-size:0;max-width:100%}
.c-map__legend{padding:0;margin:0 0 8px;font-size:14px;font-weight:700}
.c-map__chips{display:inline-flex;flex-wrap:wrap;border:1.5px solid var(--c-ink);background:var(--c-paper)}
.c-map__chip{position:relative;display:block;cursor:pointer}
.c-map__chip input{position:absolute;inset:0;width:100%;height:100%;margin:0;opacity:0;cursor:pointer}
.c-map__chip span{display:block;padding:11px 15px;font-size:15px;line-height:1.2;border-left:1.5px solid var(--c-ink);white-space:nowrap}
.c-map__chip:first-child span{border-left:0}
.c-map__chip input:checked + span{background:var(--c-ink);color:var(--c-paper)}
.c-map__chip input:focus-visible + span{outline:2px solid var(--c-spot);outline-offset:-5px}
.c-map__chip input:checked:focus-visible + span{outline-color:var(--c-paper)}

/* ---------- the card ---------- */
.c-map__card{position:relative;border-top:2px solid var(--c-ink);padding-top:4px;min-width:0}
.c-map__hint{display:none}
/* without JS: every city, one line each */
.c-map__city{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:0 12px;align-items:baseline;padding:9px 0 10px;border-bottom:1px solid var(--c-rule)}
.c-map__name{margin:0;font-size:17px;line-height:1.25;font-weight:700}
.c-map__country{grid-column:1;font-size:14px;color:var(--c-ink2)}
.c-map__facts{grid-column:2;grid-row:1 / span 2;margin:0;text-align:right;font-variant-numeric:tabular-nums}
.c-map__facts > div{display:flex;justify-content:flex-end;gap:8px;align-items:baseline}
.c-map__facts dt{font-size:13px;font-weight:700;color:var(--c-ink2)}
.c-map__facts dd{margin:0;font-size:15px;font-weight:600;white-space:nowrap}
.c-map__why{margin-top:18px}
.c-map__why-h{margin:0 0 6px;font-size:13.5px;font-weight:700;color:var(--c-ink2);letter-spacing:.01em}
.c-map__why ul{margin:0;padding:0;list-style:none}
.c-map__why li{position:relative;padding:2px 0 3px 17px;font-size:15.5px;line-height:1.4}
.c-map__why li::before{content:"";position:absolute;left:1px;top:12px;width:8px;height:2px;border-radius:1px;background:var(--c-ink)}
.c-map__total{display:flex;flex-direction:column;gap:1px;margin-top:16px;padding-top:11px;border-top:1px solid var(--c-rule)}
.c-map__total span{font-size:13.5px;font-weight:700;color:var(--c-ink2)}
.c-map__total b{font-size:21px;line-height:1.2;font-weight:700;font-variant-numeric:tabular-nums;letter-spacing:-.005em}

/* with JS: one city at a time, all of them stacked in one cell so the card never changes height */
html.js .c-map__stack{display:grid}
html.js .c-map__stack > *{grid-area:1 / 1}
html.js .c-map__hint{display:block;padding:12px 0 0}
html.js .c-map__hint-t{font-size:22px;line-height:1.2;font-weight:600;color:var(--c-ink2)}
html.js .c-map__hint-t{min-height:1.182em;line-height:1.182}
.c-map__hint dd{color:var(--c-rule)}
html.js .c-map__city{display:block;padding:10px 0 0;border-bottom:0;visibility:hidden;opacity:0}
html.js .c-map__city.is-shown{visibility:visible;opacity:1}
html.js .c-map.has-sel .c-map__hint{visibility:hidden;opacity:0}
html.js .c-map__name{font-size:26px;line-height:1.1;letter-spacing:-.01em}
html.js .c-map__country{margin-top:3px;font-size:15.5px}
html.js .c-map__facts{margin-top:14px;text-align:left;border-top:1px solid var(--c-rule)}
html.js .c-map__facts > div{justify-content:space-between;gap:12px;padding:8px 0 9px;border-bottom:1px solid var(--c-rule)}
html.js .c-map__facts dt{font-size:13.5px}
html.js .c-map__facts dd{font-size:17px}

/* ---------- pointer devices only ---------- */
@media (hover:hover) and (pointer:fine){
  html.js .c-map__pin:hover .c-map__lab{text-decoration:underline;text-decoration-thickness:1.5px;text-underline-offset:2px}
  .c-map__chip:hover input:not(:checked) + span{text-decoration:underline;text-underline-offset:3px}
  .c-map__play:hover{text-decoration:underline;text-underline-offset:3px}
}

/* ---------- narrower screens ---------- */
@media (max-width:980px){
  .c-map{grid-template-columns:minmax(0,1fr);gap:0}
  .c-map__card{margin-top:26px}
  html.js .c-map__card{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);gap:0 32px}
  html.js .c-map__live{grid-column:1}
  html.js .c-map__stack{grid-column:1;grid-row:1 / span 2}
  html.js .c-map__why{grid-column:2;margin-top:12px}
  html.js .c-map__total{grid-column:2}
}
@media (max-width:699px){
  .c-map{--u:3}
  .c-map__frame{border-radius:12px}
  .c-map__lab{font-size:12px}
  /* the map is small: only home and the selected city keep their names */
  .c-map__pin .c-map__lab{opacity:0}
  html.js .c-map__pin.is-sel .c-map__lab{opacity:1}
  html.js .c-map.has-sel .c-map__home .c-map__lab{opacity:0}
  .c-map__dot{left:-4.5px;top:-4.5px;width:9px;height:9px;border-width:1.75px}
  .c-map__home .c-map__dot{left:-5.5px;top:-5.5px;width:11px;height:11px;border-width:2px}
  /* home's name over its dot, centred: on the left of Paris it ran off the map's edge (15/11) */
  .c-map__home .c-map__lab--w{transform:translate(-50%,calc(-100% - 9px))}
  .c-map__controls{flex-direction:column;align-items:stretch;gap:16px}
  .c-map__play{align-self:flex-start}
  .c-map__cities{width:100%}
  .c-map__chips{display:flex;flex-wrap:nowrap;min-width:0;max-width:100%;gap:8px;border:0;background:none;overflow-x:auto;padding:3px 2px 4px;margin:-3px -2px -4px;scrollbar-width:none}
  .c-map__chips::-webkit-scrollbar{display:none}
  .c-map__chip{flex:none}
  .c-map__chip span,.c-map__chip:first-child span{border:1.5px solid var(--c-ink);padding:10px 14px;min-height:44px}
  html.js .c-map__card{display:block}
  html.js .c-map__why{margin-top:18px}
  html.js .c-map__name{font-size:25px}
}

/* ---------- motion ---------- */
.motion .c-map__arc{transition:opacity 260ms var(--c-eo)}
.motion .c-map__trail.is-sel:not(.is-live){transition:stroke-dashoffset 700ms var(--c-eio),opacity 200ms var(--c-eo)}
.motion .c-map__trail:not(.is-sel){transition:opacity 260ms var(--c-eo)}
.motion .c-map__dot,.motion .c-map__dot::after{transition:transform 220ms var(--c-eo),opacity 220ms var(--c-eo)}
.motion .c-map__plane{transition:opacity 200ms var(--c-eo)}
.motion .c-map__city,.motion .c-map__hint{transition:opacity 180ms var(--c-eo),visibility 0s linear 180ms}
.motion .c-map__city.is-shown,.motion .c-map:not(.has-sel) .c-map__hint{transition:opacity 260ms var(--c-eo) 60ms,visibility 0s}
.motion .c-map__lab{transition:opacity 220ms var(--c-eo)}
.motion .c-map__play{transition:transform 140ms var(--c-eo)}
.motion .c-map__play:active{transform:scale(.97)}

.motion .c-map__pin.is-hit .c-map__dot::before{animation:c-map-hit 800ms var(--c-eo)}
@keyframes c-map-hit{from{opacity:.85;transform:scale(1)}to{opacity:0;transform:scale(2.8)}}

/* entrance (once): land develops, arcs draw one after the other, markers land at their ends */
.motion .c-map:not(.in) :is(.c-map__land,.c-map__grat){opacity:0}
.motion .c-map:not(.in) .c-map__arc{stroke-dashoffset:1}
.motion .c-map:not(.in) .c-map__pin{opacity:0;transform:scale(.95)}
.motion .c-map:not(.in) .c-map__home{opacity:0}
.motion .c-map.in:not(.is-settled) :is(.c-map__land,.c-map__grat){transition:opacity 700ms var(--c-eo)}
.motion .c-map.in:not(.is-settled) .c-map__home{transition:opacity 500ms var(--c-eo) 150ms}
.motion .c-map.in:not(.is-settled) .c-map__arc{transition:stroke-dashoffset 650ms var(--c-eio);transition-delay:calc(260ms + var(--i,0) * 160ms)}
.motion .c-map.in:not(.is-settled) .c-map__pin{transition:opacity 420ms var(--c-eo),transform 420ms var(--c-eo);transition-delay:calc(720ms + var(--i,0) * 160ms)}

@media print{
  .c-map__controls,.c-map__plane{display:none!important}
  html.js .c-map__stack{display:block}
  html.js .c-map__stack > *{visibility:visible!important;opacity:1!important}
  html.js .c-map__hint{display:none}
}
