/* Points map page: the guide's editorial frame (style.css) plus four data figures:
   ratio bars, the RC → programme → airline map, the same-seat price comparison and the
   distance-band ruler. Colour carries value only: red = cheapest, amber = cash you still pay. */

.points .vpanel { --vl: 184px; }
.points .toc { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.chain { margin-top: 14px; }
.chain .fm-node b { display: flex; align-items: center; gap: 6px; }

/* ---------- 02 ratio bars ---------- */
.cv { padding: 4px 18px; }
.cv-r { display: grid; grid-template-columns: minmax(0, 250px) minmax(0, 1fr) 92px; align-items: center; gap: 16px; padding: 9px 0; }
.cv-r + .cv-r { border-top: 1px solid var(--line); }
.cv-l { display: flex; flex-direction: column; min-width: 0; }
.cv-l b { font-size: 14px; font-weight: 600; }
.cv-l small { font-size: 12px; color: var(--ink-3); }
.cv-bar { position: relative; height: 10px; border-radius: 0 5px 5px 0; background: var(--surface-2); }
.cv-bar i { position: absolute; inset: 0 auto 0 0; width: var(--w); background: var(--ink-3); border-radius: 0 5px 5px 0; }
.cv-r.hi .cv-bar i { background: var(--red); }
.cv-v { text-align: right; display: flex; flex-direction: column; align-items: flex-end; }
.cv-v b { font: 600 15px/1.2 var(--num); font-variant-numeric: tabular-nums; }
.cv-r.hi .cv-v b { color: var(--red); }
.cv-v small { font: 11.5px/1.3 var(--num); color: var(--ink-3); }
.cv-r.off { opacity: .5; }

/* ---------- 03 map: three columns of nodes, edges drawn in an SVG behind them ---------- */
.pmap {
  position: relative; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1fr) minmax(0, 1fr);
  column-gap: clamp(30px, 7vw, 120px); align-items: start;
  background-color: var(--surface); background-image: radial-gradient(var(--line) 1px, transparent 1.2px); background-size: 14px 14px;
  border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 20px 20px;
}
.pm-lines { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; overflow: visible; }
.pm-lines path { fill: none; stroke: var(--line-2); stroke-width: 1.2; opacity: .45; transition: opacity .15s, stroke .15s; }
.pm-lines path.on { stroke: var(--ink-3); stroke-width: 1.6; opacity: 1; }
.pm-lines path.hot { stroke: var(--red); stroke-width: 2.2; opacity: 1; }
.pm-col { position: relative; z-index: 1; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.pm-h { font-size: 11.5px; color: var(--ink-3); font-weight: 500; letter-spacing: .04em; padding-bottom: 4px; }
.pm-g { font-size: 11px; color: var(--ink-3); margin-top: 10px; }
.pm-h + .pm-g { margin-top: 0; }
.pm-n {
  display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 2px 8px; min-height: 36px;
  background: var(--surface); border: 1px solid var(--line-2); border-radius: 9px; padding: 7px 10px; box-shadow: var(--shadow);
  font: inherit; color: var(--ink); text-align: left; cursor: pointer; transition: opacity .15s, border-color .15s;
}
.pm-n:hover { border-color: var(--ink-3); }
.pm-n:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.pm-n.sel { border-color: var(--ink); box-shadow: 0 0 0 1px var(--ink); }
.pm-n.dim { opacity: .36; }
.pm-n.hot { border-color: var(--red); }
.pm-n.hot.sel { box-shadow: 0 0 0 1px var(--red); }
.pm-t { display: flex; align-items: center; gap: 6px; min-width: 0; }
.pm-t b { font-size: 13px; font-weight: 600; line-height: 1.3; }
#pmPool .pm-t { flex-direction: column; align-items: flex-start; gap: 1px; }
.pm-t small { font-size: 11px; color: var(--ink-3); line-height: 1.3; }
.pm-v { font: 600 12px/1.3 var(--num); font-variant-numeric: tabular-nums; color: var(--ink-2); white-space: nowrap; margin-left: auto; }
.pm-v:empty { display: none; }
.pm-n.hot .pm-v { color: var(--red); }
.pm-info { margin-top: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px 16px; font-size: 13.5px; color: var(--ink-2); min-height: 48px; }
.pm-info b { color: var(--ink); font-weight: 600; }

/* ---------- 04 same seat, every programme ---------- */
.cmp-tools { display: grid; gap: 8px; margin: 0 0 12px; }
.cmp-tools .seg { justify-self: start; }
#cmpDest { flex-wrap: wrap; overflow: visible; }
.cmp-row2 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.cmp { padding: 4px 18px 12px; }
.cm-r { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1.5fr) repeat(4, 78px); align-items: center; gap: 14px; padding: 11px 0; }
.cm-r + .cm-r { border-top: 1px solid var(--line); }
.cm-l { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px; min-width: 0; }
.cm-l b { font-size: 14px; font-weight: 600; }
.cm-l small { flex-basis: 100%; font-size: 12px; color: var(--ink-3); }
.cm-bar { display: flex; height: 12px; background: var(--surface-2); border-radius: 0 4px 4px 0; overflow: hidden; }
.cm-bar i, .cm-legend i { display: block; height: 100%; }
.b-rc { background: var(--ink-3); }
.b-tax { background: color-mix(in srgb, var(--warn) 75%, transparent); }
.cm-r.hot .b-rc { background: var(--red); }
.cm-n { text-align: right; display: flex; flex-direction: column; align-items: flex-end; }
.cm-n b { font: 600 14.5px/1.25 var(--num); font-variant-numeric: tabular-nums; }
.cm-n small { font-size: 11px; color: var(--ink-3); }
.cm-n.tot b { font-weight: 650; }
.cm-r.hot .cm-n.tot b, .cm-r.hot .cm-l b { color: var(--red); }
.cm-r.off { opacity: .5; }
.cm-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; padding: 10px 0 0; border-top: 1px solid var(--line); font-size: 12px; color: var(--ink-3); }
.cm-legend span { display: inline-flex; align-items: center; gap: 6px; }
.cm-legend i { width: 10px; height: 10px; border-radius: 2px; }
.cmp-verdict { margin: 4px 0 0; font-size: 14px; color: var(--ink-2); max-width: 62em; }
.cmp-verdict b { color: var(--ink); font-weight: 600; }

/* ---------- 05 distance-band ruler ---------- */
.band { padding: 4px 18px 12px; }
.bd-r { display: grid; grid-template-columns: 158px minmax(0, 1fr) 64px 76px 60px; align-items: center; gap: 14px; padding: 7px 0; }
.bd-r + .bd-r { border-top: 1px solid var(--line); }
.bd-hd { font-size: 11.5px; color: var(--ink-3); font-weight: 500; padding-top: 12px; }
.bd-hd .bd-n { font: 500 11.5px var(--sans); color: var(--ink-3); }
.bd-hd .bd-n.q { color: var(--ink); font-weight: 600; }
.bd-c { display: flex; flex-direction: column; min-width: 0; }
.bd-c b { font-size: 13.5px; font-weight: 600; }
.bd-c small { font: 11.5px/1.35 var(--num); color: var(--ink-3); font-variant-numeric: tabular-nums; }
.bd-c em { font-style: normal; color: var(--warn); font-weight: 600; }
.bd-track { position: relative; height: 8px; border-radius: 0 4px 4px 0; background: var(--surface-2); }
.bd-hd .bd-track, .bd-z .bd-track { background: none; }
.bd-hd .bd-track { height: 14px; }
.bd-hd .bd-track em { position: absolute; top: 0; transform: translateX(-50%); font: 500 11px/1 var(--num); font-style: normal; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.bd-z { padding: 0 0 6px; border-top: 0 !important; }
.bd-z .bd-c { font-size: 11.5px; color: var(--ink-3); }
.bd-z .bd-track { height: 24px; }
.bd-z .bd-track span { position: absolute; top: 0; bottom: 0; display: flex; align-items: center; justify-content: center; border-left: 1px dashed var(--line-2); background: color-mix(in srgb, var(--red) 5%, transparent); }
.bd-z .bd-track span:nth-child(even) { background: color-mix(in srgb, var(--red) 10%, transparent); }
.bd-z .bd-track span:first-child { border-left: 0; }
.bd-z .bd-track b { font: 600 12px/1 var(--num); color: var(--red); font-variant-numeric: tabular-nums; }
.bd-line { position: absolute; top: -5px; bottom: -5px; border-left: 1px dashed var(--ink-3); opacity: .55; }
.bd-fill { position: absolute; inset: 0 auto 0 0; background: var(--ink-3); border-radius: 0 4px 4px 0; }
.bd-r.edge .bd-fill { background: var(--warn); }
.bd-n { text-align: right; font: 600 13.5px/1.2 var(--num); font-variant-numeric: tabular-nums; color: var(--ink-2); }
.bd-n.q { color: var(--ink); }
.bd-n.bd-lo { color: var(--red); }
.bd-zl { display: none; margin: 0; padding: 4px 0 8px; font-size: 12px; color: var(--ink-3); }
.bd-zl b { color: var(--red); font: 600 12px var(--num); }
.bd-foot { margin: 6px 0 0; padding-top: 10px; border-top: 1px solid var(--line); font-size: 12px; color: var(--ink-3); }

/* ---------- 07 cheat sheet ---------- */
.cheat td { white-space: normal; }
.cheat td:first-child { min-width: 220px; }
.cheat .ch-one { display: block; margin-top: 2px; font-size: 12.5px; color: var(--ink-2); max-width: 30em; }
.cheat .ratio { margin: 2px 4px 2px 0; white-space: nowrap; }
.ch-air { display: flex; flex-wrap: wrap; gap: 4px 9px; }
.legend-cards.two div { grid-template-columns: 1fr; align-items: start; }

@media (max-width: 1040px) {
  .cm-r { grid-template-columns: minmax(0, 1fr) repeat(4, 72px); }
  .cm-bar { grid-column: 1 / -1; grid-row: 2; }
}
@media (max-width: 720px) {
  .points .vpanel { --vl: 118px; }
  .points .toc { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .points .toc a { padding: 10px 12px; font-size: 13px; }
  .cv { padding: 2px 14px; }
  .cv-r { grid-template-columns: minmax(0, 1fr) 76px; gap: 4px 12px; }
  .cv-bar { grid-column: 1 / -1; grid-row: 2; }
  .cv-v { grid-row: 1; grid-column: 2; }
  .pmap { padding: 12px 10px 14px; column-gap: 20px; grid-template-columns: minmax(0, .8fr) minmax(0, 1fr) minmax(0, 1fr); }
  .pm-n { padding: 6px 7px; min-height: 32px; border-radius: 7px; }
  .pm-t b { font-size: 12px; }
  .pm-t small { display: none; }
  .pm-t .al { font-size: 10px; }
  .pm-v { font-size: 11px; margin-left: 0; }
  .pm-g { font-size: 10.5px; }
  .cmp { padding: 2px 14px 12px; }
  .cm-r { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px 10px; }
  .cm-l { grid-column: 1 / -1; }
  .cm-bar { grid-row: 2; }
  .cm-n { align-items: flex-start; text-align: left; }
  .band { padding: 2px 12px 12px; }
  .bd-r { grid-template-columns: 88px minmax(0, 1fr) 50px 56px; gap: 8px; }
  .bd-ba { display: none; }
  .bd-z { display: none; }
  .bd-hd .bd-track em { display: none; }
  .bd-zl { display: block; }
  .bd-c small { font-size: 10.5px; }
  .bd-n { font-size: 12.5px; }
  /* cheat sheet: one stacked card per programme */
  .cheat thead { display: none; }
  .cheat, .cheat tbody, .cheat tr, .cheat td { display: block; }
  .cheat tr { padding: 10px 16px; border-bottom: 1px solid var(--line); }
  .cheat td { border: 0; padding: 3px 0 !important; }
  .cheat td:first-child { min-width: 0; }
  .cheat td + td::before { content: attr(data-l); display: inline-block; width: 82px; font-size: 12px; color: var(--ink-3); }
  .cheat td + td { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 0; }
}
#bandNote { white-space: normal; font-weight: 400; flex: 1 1 260px; }
