/* Type (fonts/, SIL Open Font License): Atkinson Hyperlegible Next for text, drawn to stay legible small and tired;
   Barlow Semi Condensed for what reads like airport signage: page titles, trip numbers, countdowns and airport codes.
   Latin only, the rest of Latin loading if a name needs it; anything else falls back to the system's. */
@font-face { font-family: 'Atkinson Hyperlegible Next'; font-style: normal; font-weight: 200 800; font-display: swap;
             src: url("fonts/atkinson-hyperlegible-next-v7-latin.825fabef695f.woff2") format('woff2');
             unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329,
                            U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Atkinson Hyperlegible Next'; font-style: normal; font-weight: 200 800; font-display: swap;
             src: url("fonts/atkinson-hyperlegible-next-v7-latin-ext.290c109915a4.woff2") format('woff2');
             unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329,
                            U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F,
                            U+A720-A7FF; }
@font-face { font-family: 'Barlow Semi Condensed'; font-style: normal; font-weight: 600; font-display: swap;
             src: url("fonts/barlow-semi-condensed-v16-600-latin.64a19a7cafc2.woff2") format('woff2'); }
@font-face { font-family: 'Barlow Semi Condensed'; font-style: normal; font-weight: 700; font-display: swap;
             src: url("fonts/barlow-semi-condensed-v16-700-latin.d829c77621b7.woff2") format('woff2'); }

/* --well fills a panel inside a card, in place of a second border; --edge outlines what takes input; --night is the
   progress panel's sky, under the 3D globe's colours (--route, --flying); --mine marks the owner's own travel;
   --reserve, --training and --personal colour those kinds of event on the Calendar, each with its own text colour. */
:root {
  --bg: #f1f3f6; --card: #fff; --well: #f3f5f8; --thumb: #fff; --text: #172133; --muted: #5a6577; --line: #e1e6ec;
  --edge: #c7cfd9; --accent: #1d5fbf; --on-accent: #fff;
  --tint: color-mix(in srgb, var(--accent) 11%, var(--card)); --tint-strong: color-mix(in srgb, var(--accent) 19%, var(--card));
  --ok: #2e7d4f; --warn: #946200; --review: #c2410c; --block: #b42318;
  --ok-bg: #e7f4ec; --warn-bg: #fdf3dc; --review-bg: #fdebe1; --block-bg: #fde4e2;
  --night: #0f2244; --route: #7aa7ff; --flying: #6fcf97;
  --mine: #0b7466;
  --reserve: #a3236f; --on-reserve: #fff; --training: #6d28d9; --on-training: #fff; --personal: #2e7d4f; --on-personal: #fff;
  --sans: 'Atkinson Hyperlegible Next', system-ui, -apple-system, sans-serif;
  --signage: 'Barlow Semi Condensed', 'Arial Narrow', system-ui, sans-serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1216; --card: #171b21; --well: #1e232b; --thumb: #353c47; --text: #e6e9ee; --muted: #9ba4b0; --line: #2a3038;
    --edge: #3b434e; --accent: #7aa7ff; --on-accent: #0d1626;
    --ok: #6fcf97; --warn: #e2b44c; --review: #f0965f; --block: #f27b72;
    --ok-bg: #16281e; --warn-bg: #2d2412; --review-bg: #33200f; --block-bg: #361715;
    --night: #0c1a33; --mine: #4cc9b4;
    --reserve: #f08cc4; --on-reserve: #2a0a1c; --training: #c4b5fd; --on-training: #1e1240;
    --personal: #6fcf97; --on-personal: #0b2416;
  }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }                     /* over any display a component sets */
body { margin: 0; background: var(--bg); color: var(--text); font: 15px/1.5 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: .2em;
    text-decoration-color: color-mix(in srgb, currentColor 40%, transparent); }
a:hover { text-decoration-color: currentColor; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1 { font: 700 2rem/1.1 var(--signage); letter-spacing: .005em; margin: 0 0 .6rem; }
h1 small { font: 500 .95rem/1 var(--sans); color: var(--muted); letter-spacing: 0; }
h2 { font-size: 1.15rem; line-height: 1.3; margin: 0 0 .5rem; }
h3 { font-size: .9rem; color: var(--muted); margin: .25rem 0; }
code { font-size: .9em; }
.muted { color: var(--muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.icon { width: 1.3rem; height: 1.3rem; flex: none; fill: none; stroke: currentColor; stroke-width: 1.7;
        stroke-linecap: round; stroke-linejoin: round; }

/* Buttons, and links that act as one, by what they do: tinted blue for any action; solid for the one that saves,
   sends or creates (primary); red-tinted for one that takes something away (caution); solid red to confirm a
   deletion (danger). */
button, .button { display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 2.4rem;
                  padding: .45rem 1rem; border: 0; border-radius: 8px; background: var(--tint); color: var(--accent);
                  font: 600 .93rem/1.2 var(--sans); text-decoration: none; cursor: pointer; }
button:hover, .button:hover { background: var(--tint-strong); }
button.primary, .button.primary { background: var(--accent); color: var(--on-accent); }
button.primary:hover, .button.primary:hover { background: color-mix(in srgb, var(--accent) 86%, var(--text)); }
button.caution, .button.caution { background: var(--block-bg); color: var(--block); }
button.caution:hover, .button.caution:hover { background: color-mix(in srgb, var(--block) 20%, var(--card)); }
button.danger { background: var(--block); color: var(--card); }
button.danger:hover { background: color-mix(in srgb, var(--block) 86%, var(--text)); }
button:disabled { opacity: .45; cursor: not-allowed; }
button.linklike { display: inline; min-height: 0; padding: 0; border: 0; background: none; color: var(--accent); font: inherit;
                  cursor: pointer; }
button.linklike:hover { background: none; text-decoration: underline; }

/* Fields: one outline and radius everywhere, the select's arrow drawn in, the file picker's button a button. */
input[type=text], input[type=email], input[type=password], input[type=url], input[type=search], input[type=tel],
input[type=number], input:not([type]), select, textarea {
  font: inherit; color: var(--text); background-color: var(--card); border: 1px solid var(--edge); border-radius: 8px;
  padding: .5rem .65rem; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline-offset: 0; border-color: var(--accent); }
select { appearance: none; padding-right: 2.2rem; background: var(--card) no-repeat right .75rem center / .7rem
         url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5l5 5 5-5' fill='none' stroke='%23808a99' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E"); }
input[type=checkbox], input[type=radio] { width: 1rem; height: 1rem; margin: 0 .3rem 0 0; vertical-align: -.15em;
                                          accent-color: var(--accent); }
input[type=file] { max-width: 100%; color: var(--muted); font: inherit; }
input[type=file]::file-selector-button { min-height: 2.4rem; margin-right: .75rem; padding: .45rem 1rem; border: 0;
                                         border-radius: 8px; background: var(--tint); color: var(--accent);
                                         font: 600 .93rem/1.2 var(--sans); cursor: pointer; }
input[type=file]::file-selector-button:hover { background: var(--tint-strong); }

/* The header: the name, the pages as tabs, the time switch, then Import schedule, What's new and the account menu.
   On a phone the tabs become a bar along the bottom and Import schedule moves into the menu. */
.bar { display: flex; flex-wrap: wrap; align-items: center; gap: .35rem; min-height: 3.5rem;
       padding: .4rem max(1.25rem, env(safe-area-inset-right)) .4rem max(1.25rem, env(safe-area-inset-left));
       background: var(--card); border-bottom: 1px solid var(--line); }
.bar > * { order: 2; }
.brand { order: 0; margin-right: 1.25rem; font: 700 1.4rem/1 var(--signage); letter-spacing: .01em; color: var(--text);
         text-decoration: none; }
.bar nav { order: 1; display: flex; align-self: stretch; gap: .15rem; margin: -.4rem 0; }
.bar nav a { position: relative; display: flex; align-items: center; gap: .4rem; padding: 0 .75rem; color: var(--muted);
             font-weight: 600; text-decoration: none; }
.bar nav a:hover, .bar nav a[aria-current] { color: var(--text); }
.bar nav a:focus-visible { outline-offset: -.5rem; border-radius: 12px; }
.bar nav a[aria-current]::after { content: ''; position: absolute; left: .75rem; right: .75rem; bottom: 0; height: 3px;
                                  border-radius: 3px 3px 0 0; background: var(--accent); }
.tabs .icon { display: none; }
.bar .zones { margin-left: auto; }
.bar > .import { min-height: 2.25rem; margin: 0 .35rem 0 .65rem; padding: .35rem .9rem; }
.icon-button { position: relative; display: inline-grid; place-items: center; width: 2.4rem; height: 2.4rem; min-height: 0;
               padding: 0; border: 0; border-radius: 50%; background: none; color: var(--muted); }
.icon-button:hover { background: var(--well); color: var(--text); }
.icon-button.account .icon { display: none; }
.icon-button .initial { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%;
                        background: color-mix(in srgb, var(--accent) 14%, var(--card)); color: var(--accent);
                        font-weight: 700; }
.unread { display: inline-block; min-width: 1.15rem; margin-left: .3rem; padding: 0 .3rem; border-radius: 999px;
          background: var(--accent); color: var(--on-accent); font-size: .72rem; font-weight: 700; line-height: 1.15rem;
          text-align: center; vertical-align: .1em; }
.unread:empty { display: none; }
.icon-button .unread { position: absolute; top: 0; right: -.15rem; margin: 0; border: 2px solid var(--card);
                       line-height: 1rem; }
/* The account menu: over the page under its button; a tap outside or Escape closes it. */
.menu { position: fixed; inset: 3.35rem max(1rem, env(safe-area-inset-right)) auto auto; margin: 0; min-width: 14rem;
        padding: .35rem; background: var(--card); color: var(--text); border: 1px solid var(--line); border-radius: 12px;
        box-shadow: 0 12px 32px rgb(0 0 0 / .18); }
.menu p { margin: .35rem .65rem .4rem; overflow: hidden; text-overflow: ellipsis; }
.menu a, .menu button { display: block; width: 100%; min-height: 0; padding: .55rem .65rem; border: 0; border-radius: 8px;
                        background: none; color: var(--text); font: 600 .95rem/1.3 var(--sans); text-align: left;
                        text-decoration: none; }
.menu a:hover, .menu button:hover { background: var(--well); }
.menu form { margin: .3rem 0 0; padding-top: .3rem; border-top: 1px solid var(--line); }
.menu .import { display: none; }
/* Narrower than the full header (a small window, a tablet upright): Import schedule moves into the menu, under the
   menu icon, and the rest draws in a little. The tabs stay up here until a phone's width. */
@media (max-width: 880px) {
  .bar { padding-left: max(.9rem, env(safe-area-inset-left)); padding-right: max(.6rem, env(safe-area-inset-right)); }
  .brand { margin-right: .5rem; }
  .bar nav a { padding: 0 .55rem; }
  .bar nav a[aria-current]::after { left: .55rem; right: .55rem; }
  .bar > .import, .icon-button.account .initial { display: none; }
  .icon-button.account .icon, .menu .import { display: block; }
  .menu { inset: 3.35rem max(.5rem, env(safe-area-inset-right)) auto auto; }
}
@media (max-width: 640px) {
  body:has(.tabs) { padding-bottom: calc(4.4rem + env(safe-area-inset-bottom)); }
  .bar { flex-wrap: nowrap; gap: .2rem; }
  .brand { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }   /* a long name on a shared page */
  .bar .zones { flex: none; }
  .bar .tabs { position: fixed; z-index: 10; inset: auto 0 0; display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; margin: 0;
               padding: .3rem max(.5rem, env(safe-area-inset-right)) calc(.3rem + env(safe-area-inset-bottom)) max(.5rem, env(safe-area-inset-left));
               background: var(--card); border-top: 1px solid var(--line); }
  .bar .tabs a { flex-direction: column; justify-content: center; gap: .15rem; padding: .3rem 0; font-size: .75rem; }
  .bar .tabs .icon { display: block; width: 1.5rem; height: 1.5rem; }
  .bar .tabs a[aria-current] { color: var(--accent); }
  .bar .tabs a[aria-current] .icon { stroke-width: 2.1; }
  .bar .tabs a[aria-current]::after { display: none; }
}

main { max-width: 860px; margin: 0 auto; padding: 1.25rem max(.75rem, env(safe-area-inset-right)) 1.5rem max(.75rem, env(safe-area-inset-left)); }
footer.site { max-width: 860px; margin: 0 auto; padding: .5rem .75rem 2rem; text-align: center; font-size: .85rem; color: var(--muted); }
footer.site a, footer.site .linklike { color: inherit; text-decoration: none; }
footer.site a:hover, footer.site .linklike:hover { color: var(--text); text-decoration: underline; }
.prose { max-width: 680px; margin: 0 auto .75rem; }
.prose h2 { margin-top: 1.25rem; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin: .3rem 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 1.25rem; margin-bottom: .9rem; }
.card.narrow { max-width: 30rem; margin: 2rem auto; }
.heading { display: flex; justify-content: space-between; align-items: baseline; gap: .5rem; }
@media (max-width: 560px) { main { padding-top: .9rem; } .card { padding: 1rem; border-radius: 12px; } h1 { font-size: 1.75rem; } }

form label { display: block; margin: .5rem 0; }
form.stacked input, form.stacked select, .card.narrow input { display: block; width: 100%; margin-top: .3rem; font: inherit; }
form.stacked input[type=checkbox] { display: inline-block; width: 1rem; margin: 0 0 0 .3rem; }
form.stacked .muted { display: block; margin: -.25rem 0 .6rem; font-size: .88rem; }
form.stacked > div { margin-bottom: .35rem; }
form.stacked > button { margin-top: .75rem; }
/* Profile (profile.html): sections parted by a line, each a grid of labelled fields; Flying's and Imports' switches
   at the right of their headings; Commuting a table of airports, home first; Miscellaneous's switch, 24-hour time,
   at the right of its heading too, the loyalty numbers folded under it; Save at the foot. */
.settings .group { padding: 1.1rem 0 1.3rem; border-top: 1px solid var(--line); }
.settings .group:first-of-type { padding-top: .4rem; border-top: 0; }
.settings h2 { margin: 0 0 .85rem; font-size: 1.05rem; }
.settings .heading { position: relative; align-items: center; margin-bottom: .85rem; }   /* the AI switch's tip under it */
.settings .heading h2 { margin: 0; }
/* Nothing shown under it: Imports' heading, and Flying's while "I am aircrew" is off. */
.settings .heading:last-child, .settings .heading:has(+ [hidden]:last-child) { margin-bottom: 0; }
.settings .fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: .9rem 1rem; }
.settings .fields.crew-only { grid-template-columns: repeat(auto-fill, minmax(10rem, 1fr)); }   /* Flying's four in a row */
/* FX Calendar: its two switches side by side, each after its words, then its events, folded, a switch at each one's
   right, in the owner's order down one column, or down two where there's room. */
.settings .fx-switches { display: flex; flex-wrap: wrap; gap: .75rem 2.5rem; }
.settings .fx-events { margin-top: 1rem; }
.settings .fx-events > summary { font-weight: 600; }
.settings .fx-event-list { columns: 15rem 2; column-gap: 2.5rem; padding-top: .25rem; }
.settings .fx-event-list .toggle { display: flex; justify-content: space-between; margin-bottom: .65rem; font-weight: 500;
  break-inside: avoid; }
.setting { display: flex; flex-direction: column; gap: .3rem; min-width: 0; }
.setting label, .commute .column { margin: 0; font-size: .88rem; font-weight: 600; }
.setting input, .setting select { width: 100%; }
.setting.short input, .commute input[name$="-code"] { max-width: 7rem; text-transform: uppercase; }
.setting .errorlist, .commute .errorlist, .settings .group > .errorlist { margin: 0; padding: 0; list-style: none; font-size: .88rem; }
.toggle { display: inline-flex; align-items: center; gap: .6rem; margin: 0; font-size: .93rem; font-weight: 600; cursor: pointer; }
.toggle input[type=checkbox] { appearance: none; flex: none; width: 2.5rem; height: 1.45rem; margin: 0; border-radius: 999px;
  background: var(--edge) no-repeat 0 0 / 1.45rem 1.45rem radial-gradient(circle, #fff 0 .5rem, transparent .55rem);
  cursor: pointer; transition: background-color .15s, background-position .15s; }
.toggle input[type=checkbox]:checked { background-color: var(--accent); background-position: 1.05rem 0; }
@media (prefers-reduced-motion: reduce) { .toggle input[type=checkbox] { transition: none; } }
/* Profile's AI switch: its words, a "?" whose text opens under the heading, at its right, on hover, focus or a tap,
   then the switch. */
.settings .ai-switch { display: flex; cursor: default; }
.ai-switch label { margin: 0; cursor: pointer; }
.ai-switch .hint { flex: none; width: 1.4rem; height: 1.4rem; min-height: 0; padding: 0; border: 1px solid var(--edge); border-radius: 50%;
  background: var(--well); color: var(--muted); font: inherit; font-size: .8rem; font-weight: 700; line-height: 1; cursor: help; }
.ai-switch .tip { display: none; position: absolute; top: calc(100% + .45rem); right: 0; z-index: 2; width: min(32rem, 100%);
  padding: .75rem .9rem; border: 1px solid var(--edge); border-radius: 10px; background: var(--card); color: var(--text);
  box-shadow: 0 6px 20px rgb(0 0 0 / .14); font-size: .88rem; font-weight: 400; line-height: 1.45; }
.ai-switch .hint:hover ~ .tip, .ai-switch .hint:focus-visible ~ .tip, .ai-switch .hint[aria-expanded=true] ~ .tip { display: block; }
.commute { display: grid; grid-template-columns: minmax(4.5rem, 7rem) minmax(5rem, 8rem) minmax(5rem, 8rem) auto; gap: .55rem .75rem;
           align-items: center; margin-bottom: .9rem; }
.commute .row { display: contents; }
.commute .home { font-weight: 600; }
.commute input { width: 100%; min-width: 0; }
.commute .errorlist { grid-column: 1 / -1; }
.commute .remove { justify-self: start; color: var(--muted); font-size: .9rem; }
.commute .remove:hover { color: var(--block); }
.settings .save { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .75rem;
                  padding-top: 1.1rem; border-top: 1px solid var(--line); }
/* Profile's loyalty numbers: the name beside the alliance's airline, the number under it. */
details.loyalty-numbers h3 { font-size: .95rem; margin: .9rem 0 .2rem; }
.loyalty-row { display: grid; grid-template-columns: minmax(6rem, 8.5rem) minmax(0, 22rem); gap: .3rem .5rem; align-items: center; margin: .4rem 0; }
.loyalty-row > input, .loyalty-row > select { grid-column: 2; width: 100%; min-width: 0; }
.loyalty-row .errorlist { grid-column: 1 / -1; }
.errorlist { color: var(--block); margin: .25rem 0; padding-left: 1.1rem; }
.helptext { color: var(--muted); font-size: .85rem; }
.upload { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; align-items: center; }
.actions form { margin: 0; }
.actions p { margin: 0; flex-basis: 100%; }

table.list { width: 100%; border-collapse: collapse; }
table.list th, table.list td { text-align: left; padding: .55rem .5rem; border-bottom: 1px solid var(--line); vertical-align: top; }
table.list th { font-size: .8rem; color: var(--muted); font-weight: 600; border-bottom-color: var(--edge); }
table.list tbody tr:last-child td { border-bottom: 0; }
table.list td a { font-weight: 600; text-decoration: none; }
table.list td a:hover { text-decoration: underline; }
table.list .tick { width: 1.5rem; }
table.list + .actions { margin-top: .75rem; }
ul.doomed li { margin-bottom: .35rem; }

.message { padding: .65rem .9rem; border-radius: 10px; margin: 0 0 .9rem; background: var(--warn-bg); }
.message.error, .message.block { background: var(--block-bg); color: var(--block); }
.message.review { background: var(--review-bg); }
.message.success, .message.info { background: var(--ok-bg); }
/* The bar after a change saved at once, with Undo (trip-changes-plan.md, T2): kept in sight at the foot of the screen,
   above the tabs on a phone, until the next page or dismissed. */
.message.undo { position: fixed; z-index: 11; left: 50%; bottom: calc(1rem + env(safe-area-inset-bottom)); transform: translateX(-50%);
                width: max-content; max-width: min(36rem, calc(100% - 1.5rem)); margin: 0; display: flex; align-items: baseline;
                gap: .3rem .9rem; box-shadow: 0 6px 24px rgb(0 0 0 / .18); }
.message.undo form { margin: 0; }
.message.undo button.linklike { font-weight: 700; }
.message.undo .close { margin-left: auto; padding: 0 .1rem; color: var(--muted); font-size: 1.15rem; line-height: 1; }
@media (max-width: 640px) { body:has(.tabs) .message.undo { bottom: calc(5rem + env(safe-area-inset-bottom)); } }

.badge { display: inline-block; font-size: .78rem; font-weight: 700; padding: .15rem .65rem; border-radius: 999px;
         background: var(--ok-bg); color: var(--ok); white-space: nowrap; }
.badge.warn { background: var(--warn-bg); color: var(--warn); }
.badge.review { background: var(--review-bg); color: var(--review); }
.badge.block { background: var(--block-bg); color: var(--block); }
.state { color: var(--muted); margin-right: .3rem; }
.counts { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; }
.counts a { margin-left: auto; }

dl.facts { display: grid; grid-template-columns: max-content 1fr; gap: .2rem 1rem; margin: .5rem 0; }
dl.facts dt { color: var(--muted); }
dl.facts dd { margin: 0; }

/* Sections that fold: a chevron that turns as they open. */
details.more > summary, details.feedback > summary { display: flex; align-items: center; gap: .55rem; cursor: pointer;
                                                     font-weight: 700; list-style: none; }
details.more > summary::-webkit-details-marker, details.feedback > summary::-webkit-details-marker { display: none; }
details.more > summary::before, details.feedback > summary::before {
  content: ''; flex: none; width: .45rem; height: .45rem; margin: 0 .1rem 0 .15rem; border: solid currentColor;
  border-width: 0 2px 2px 0; transform: rotate(-45deg); }
details.more[open] > summary::before, details.feedback[open] > summary::before { transform: rotate(45deg) translate(-.1rem, -.1rem); }

.items { display: flex; flex-direction: column; gap: .4rem; margin-bottom: .75rem; }
.item { background: var(--card); border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: 10px; }
.item.flight { border-left-color: var(--accent); }
.item.warn { border-left-color: var(--warn); }
.item.review { border-left-color: var(--review); }
.item.block { border-left-color: var(--block); }
/* A row: what it is on the left, its start on the right, its labels below (_item.html). */
.item summary, .dropped-row { display: grid; grid-template-columns: 1fr auto; gap: .25rem .6rem; align-items: baseline;
                              padding: .6rem .8rem; }
.item summary { cursor: pointer; list-style: none; }
.item .tags, .dropped-row .tags { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: .3rem .5rem; align-items: baseline; }
.item .tags form { margin: 0; }
.item summary::-webkit-details-marker { display: none; }
.item .kind { display: inline-block; font-size: .78rem; color: var(--muted); min-width: 7.5rem; }
.item .title { font-weight: 700; }
.item .when { color: var(--muted); font-variant-numeric: tabular-nums; text-align: right; }
.label { font-size: .75rem; font-weight: 600; padding: .1rem .45rem; border-radius: 6px; background: var(--warn-bg); color: var(--warn); }
.item details > :not(summary) { margin-left: .8rem; margin-right: .8rem; }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
@media (max-width: 560px) { .compare { grid-template-columns: 1fr; } .item .kind { min-width: 0; } }
.compare dl { display: grid; grid-template-columns: max-content 1fr; gap: .1rem .6rem; margin: 0 0 .5rem; font-variant-numeric: tabular-nums; }
.compare dt { color: var(--muted); }
.compare dd { margin: 0; }
.crop { display: block; width: auto; margin-bottom: .75rem !important; border: 1px solid var(--line); border-radius: 8px;
        background-size: 100% auto; background-repeat: no-repeat; }
.original { display: block; max-width: 100%; height: auto; border: 1px solid var(--line); border-radius: 8px; }

.waiting p { margin: .4rem 0; }
.spinner { display: inline-block; width: .9em; height: .9em; border: 2px solid var(--line); border-top-color: var(--accent);
           border-radius: 50%; animation: spin 1s linear infinite; vertical-align: -.1em; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Local / UTC / Home: every time is rendered three ways; the checked switch decides which shows. */
.zones { display: flex; gap: 2px; margin: 0; padding: 3px; border: 0; border-radius: 999px; background: var(--well); }
.zones label { margin: 0; padding: .2rem .7rem; border-radius: 999px; color: var(--muted); font-size: .82rem; font-weight: 600;
               cursor: pointer; }
.zones label:hover { color: var(--text); }
.zones input { position: absolute; opacity: 0; pointer-events: none; }
.zones label:has(input:checked) { background: var(--thumb); color: var(--text);
                                  box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgb(0 0 0 / .12); }
.zones label:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 1px; }
.zones label:has(input:disabled) { opacity: .45; color: var(--muted); cursor: default; }
@media (max-width: 380px) { .zones label { padding: .2rem .5rem; } }
.moment .z-utc, .moment .z-home { display: none; }
body:has(#zone-utc:checked) .moment .z-local, body:has(#zone-home:checked) .moment .z-local { display: none; }
body:has(#zone-utc:checked) .moment .z-utc, body:has(#zone-home:checked) .moment .z-home { display: inline; }
.moment small, small.code { color: var(--muted); font-size: .75em; }

/* Owner view: the trip in signage type, then what's next in a well of its own, the countdown largest; Home, last in
   the list, comes second in size. */
.now .heading { align-items: center; }
/* The time now (_clock.html) in signage type at the size of the cards' times (Pickup time 02:55 IND), its letter or
   zone grey as theirs is. On the owner's page it sits on the trip number's baseline under the duty, the two at the
   card's right edge (the bottoms meet before Safari 16.2); on a shared page, on the status badge's line at the right. */
.now > .heading { align-items: flex-end; align-items: last baseline; }
.now .duty { display: flex; flex-direction: column; align-items: flex-end; gap: .45rem; }
.clock { font: 600 1.35rem/1 var(--signage); letter-spacing: .01em; font-variant-numeric: tabular-nums; white-space: nowrap; }
.clock .mark { color: var(--muted); }
.shared .headline { display: flex; flex-wrap: wrap; align-items: baseline; gap: .5rem; }
.shared .headline .clock { margin-left: auto; }
@media (max-width: 560px) { .clock { font-size: 1.2rem; } }
.now h1 { margin: 0; font-size: 2.25rem; line-height: 1; }
.headline { font-size: 1.12rem; line-height: 1.4; margin: .4rem 0 1rem; }
/* With no line under the duty (now.snapshot(), headline), the cards, or the stale note, sit as far under the trip
   number as they would under the line. */
.now > .heading + :not(.headline) { margin-top: 1rem; }
.answers { display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.answer { display: flex; flex-direction: column; gap: .15rem; min-width: 0; padding: .75rem .9rem; border-radius: 10px;
          background: var(--well); }
.answer.wide { grid-column: 1 / -1; }
.answer.checkins { display: grid; grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr)); gap: .6rem 1rem; }
.answer.checkins > div { display: flex; flex-direction: column; gap: .15rem; }
.answer.checkins strong { color: var(--ok); }                 /* as the departure: green, red under an hour */
.answer.checkins .soon strong { color: var(--block); }
.answer.checkins form { margin-top: .35rem; }
.answer.checkins label.checked-in { display: inline-flex; align-items: center; gap: .45rem; margin: 0; font-size: .88rem; cursor: pointer; }
.answer.checkins label.checked-in input { width: 1.1rem; height: 1.1rem; margin: 0; }
.hotel { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: .5rem; }
.hotel .answer > strong { font: 600 1.35rem/1.15 var(--signage); letter-spacing: .01em; }
/* The owner's loyalty number for a flight or hotel (loyalty.py), kept whole; small and grey, like a time's zone. */
.loyalty { color: var(--muted); font-size: .75em; font-weight: normal; white-space: nowrap; font-variant-numeric: tabular-nums; }
.answer > .loyalty { color: inherit; font-size: inherit; }        /* the hotel's own card: its number is the answer */
.answer.cancelled strong, .answer.cancelled .route, .answer.cancelled .when { text-decoration: line-through; }
.answer .q { font-size: .82rem; font-weight: 600; color: var(--muted); }
.answer .big { margin: .05rem 0 .15rem; font: 600 2.5rem/1.05 var(--signage); letter-spacing: .005em; }
.answers > .answer.wide:last-child:not(:first-child) .big { font-size: 1.75rem; }
@media (max-width: 560px) {
  .now h1, .next-trip h2 { font-size: 2rem; }
  .answers { grid-template-columns: 1fr 1fr; }
  .answer .big { font-size: 2rem; }
  .hotel { gap: .4rem; }                                       /* three across, on a phone too */
  .hotel .answer { padding: .55rem .6rem; }
  .hotel .answer .q { font-size: .75rem; }
  .hotel .answer > strong { font-size: 1.2rem; }
}
.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { padding: .6rem .5rem .6rem .9rem; border-left: 3px solid var(--line); }
.timeline li.flight { border-left-color: var(--accent); }
.timeline li.mine { border-left-color: var(--mine); }
.timeline li.mine > .line:first-child .kind { color: var(--mine); font-weight: 600; }
/* the legs a deviation replaces, one row each stretch, opening to show them (views._instead()) */
.timeline li.instead { border-left: 3px dashed var(--edge); padding-top: .4rem; padding-bottom: .4rem; font-size: .9rem; }
.timeline li.instead summary { color: var(--muted); }
.timeline li.instead details[open] > summary { margin-bottom: .3rem; }
/* on one line, cut short with an ellipsis, until opened (owner, 6 Nov) */
.timeline li.instead summary .gist { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.timeline li.instead details[open] .gist { white-space: normal; }
.timeline li.current { background: color-mix(in srgb, var(--ok-bg) 75%, var(--card)); border-left-color: var(--ok); border-radius: 0 8px 8px 0; }
.timeline li.past { opacity: .55; }
.timeline li.cancelled .title { text-decoration: line-through; }
.timeline li.break { border-left-style: dashed; font-size: .82rem; font-weight: 600; color: var(--muted); }
.timeline .line { display: flex; flex-wrap: wrap; gap: .2rem .6rem; align-items: baseline; }
.timeline .kind { font-size: .78rem; color: var(--muted); min-width: 7.5rem; }
.timeline .title { font-weight: 700; }
.timeline .times { font-variant-numeric: tabular-nums; }
.timeline .then, .answer .then, a[href^="tel:"] { white-space: nowrap; }      /* an arrival keeps its arrow; a number stays whole */
/* Day headings, by the zone switch's zone (views._days); folding the trip heads the rows left showing among themselves. */
.timeline li.day { border-left: 0; margin: 1rem 0 .3rem; padding: 0; font-size: .88rem; font-weight: 700; color: var(--text); }
.timeline li.day:first-child { margin-top: .25rem; }
.items .day { margin: .8rem 0 0; font-size: .88rem; font-weight: 700; }
body:not(:has(#zone-utc:checked)) .day.z-utc, body:not(:has(#zone-home:checked)) .day.z-home,
body:has(#zone-utc:checked) .day.z-local, body:has(#zone-home:checked) .day.z-local { display: none; }
.card:has(#events:not([open])) .timeline li.open-only, .card:has(#events[open]) .timeline li.shut-only { display: none; }
.timeline .line.tags { gap: .3rem; margin-top: .15rem; }
.timeline .tag { margin-left: auto; }                       /* a row's labels, at the right of its first line */
.timeline .label.revised { padding: 0; background: none; font-size: .75rem; }   /* which revision changed the row: quiet */
@media (max-width: 560px) { .timeline .kind { min-width: 0; } }
/* The owner's trip and the shared pages open on their next events, a summary that unfolds them all (trip.html,
   share.html); a list with nothing folded is headed the same, without the arrow. A trip that's over is folded whole
   (views._timeline()), so shut, nothing is under its summary, and it sits as Pay's and Trip History's do. */
details.unfold summary { margin-bottom: .5rem; }
details.unfold.over:not([open]) summary { margin-bottom: 0; }
details.unfold[open] .shut, details.unfold:not([open]) .opened { display: none; }
.card:has(#events:not([open])) .timeline li.folded { display: none; }
h2.events { font-size: inherit; font-weight: 700; }
.small { font-size: .85rem; }
/* The Travel page's toggle: a link to the page with the extra travel in or out, drawn as a switch; and the Pay card's
   "I was awarded the trip after rev 1", a button posting the other way. */
a.switch, button.switch { position: relative; padding-left: 2.6rem; color: inherit; text-decoration: none; font-size: .9rem; white-space: nowrap; }
button.switch { background: none; border: 0; padding-top: .3rem; padding-bottom: .3rem; padding-right: 0; font-family: inherit; cursor: pointer; text-align: left; }
a.switch::before, button.switch::before { content: ''; position: absolute; left: 0; top: 50%; width: 2.1rem; height: 1.2rem; margin-top: -.6rem;
                   border-radius: 999px; background: var(--edge); }
a.switch::after, button.switch::after { content: ''; position: absolute; left: .15rem; top: 50%; width: .9rem; height: .9rem; margin-top: -.45rem;
                  border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgb(0 0 0 / .2); }
a.switch[aria-checked="true"]::before, button.switch[aria-checked="true"]::before { background: var(--accent); }
a.switch[aria-checked="true"]::after, button.switch[aria-checked="true"]::after { left: 1.05rem; }

/* Corrections in review */
form.edit { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: .4rem .8rem; margin: .5rem 0; }
form.edit label { margin: 0; font-size: .85rem; color: var(--muted); display: flex; flex-direction: column; gap: .15rem; }
form.edit input, form.edit select { padding: .4rem .5rem; }
form.edit .error { color: var(--block); }
form.edit .buttons { grid-column: 1 / -1; display: flex; gap: .8rem; align-items: center; }
.item-actions { display: flex; gap: 1rem; align-items: center; margin: 0 .8rem .6rem; font-size: .9rem; }
.item-actions form { margin: 0; }
.changes { list-style: none; padding: 0; margin: .3rem 0; font-size: .9rem; }
.label.corrected { background: var(--ok-bg); color: var(--ok); }
.label.revised { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
/* What a revision changed: underlined in orange, as a border so a struck-through title keeps both lines. */
.timeline .changed { border-bottom: 2px solid var(--review); }
.timeline .changed a { text-decoration: none; }
.message .item-actions { margin: .4rem 0 0; }
.item.dropped { opacity: .7; }
.item.new { border-left-color: var(--ok); }

/* Pending assignments: highlight unknown pickup times and unassigned rides or hotels. */
.answer.pending { background: var(--warn-bg); box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--warn) 40%, transparent); }
.answer.pending .big { color: var(--warn); font-size: 2.1rem; }
.next-trip .heading { align-items: center; }               /* between trips: whole days to the next, and where */
.next-trip h2 { margin: 0; font: 700 2.25rem/1 var(--signage); letter-spacing: .005em; }   /* as the trip's number below */
/* A shared page's head before the trip (share.html, sharing._coming()): the owner's Next trip card's words, the badge and clock at the right. */
.coming h2 { margin: 0; font: 700 2.25rem/1 var(--signage); letter-spacing: .005em; }
.scene h2 { text-shadow: 0 1px 3px color-mix(in srgb, var(--night) 70%, transparent); }
/* At Home (at_home.html, and Next trip's card between trips): the words on the progress panel's night sky, over a
   picture of where the owner lives if there is one (_city_picture.html), the sky drawn up over its foot so they read
   on any picture; the city under them, and who made the picture at the right, small, as its licence asks. */
.at-home { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: .3rem;
           background: var(--night); border-color: var(--night); color: #fff; }
.at-home.pictured { min-height: 11.5rem; }
.at-home .city, .scene .city { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.at-home.pictured::after, .scene::after { content: ''; position: absolute; inset: 0;
                           background: linear-gradient(to top, color-mix(in srgb, var(--night) 92%, transparent) 0%, color-mix(in srgb, var(--night) 62%, transparent) 34%,
                                                       color-mix(in srgb, var(--night) 28%, transparent) 100%); }
.at-home .heading { position: relative; z-index: 1; align-items: flex-end; align-items: last baseline; }
.at-home h1 { margin: 0; font-size: 2.5rem; line-height: 1; }
.at-home.pictured h1, .at-home.pictured h2, .at-home.pictured .where { text-shadow: 0 1px 3px color-mix(in srgb, var(--night) 70%, transparent); }
.at-home .clock .mark, .at-home .clock small, .scene .clock .mark, .scene .clock small { color: rgb(255 255 255 / .72); }
.at-home .where { font-size: 1.05rem; font-weight: 600; }
.at-home .credit, .scene .credit { margin-left: auto; font-size: .7rem; line-height: 1.3; text-align: right; color: rgb(255 255 255 / .72);
                   text-decoration: none; overflow-wrap: anywhere; }
.at-home .credit:hover, .scene .credit:hover { color: #fff; text-decoration: underline; }
.at-home :focus-visible, .scene :focus-visible { outline-color: #fff; }
.next-trip.at-home.pictured { min-height: 9rem; }
/* The Now card's head over a city's picture (.scene: trip.html at the hotel, share.html at the hotel and At Home), the
   picture out to the card's edges at the top and the sky drawn up over it as on At Home; the cards below stay on the
   card's own ground. */
.scene { position: relative; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: .35rem;
         min-height: 11.5rem; margin: -1.25rem -1.25rem 1rem; padding: 1.25rem 1.25rem .7rem; border-radius: 13px 13px 0 0;
         background: var(--night); color: #fff; }
.scene > :not(.city) { position: relative; z-index: 1; }
.now .scene > .heading:first-of-type { align-items: flex-end; align-items: last baseline; }
.scene h1, .scene .headline { text-shadow: 0 1px 3px color-mix(in srgb, var(--night) 70%, transparent); }
.scene .headline { margin: 0; }
.scene .badge { text-shadow: none; }
.scene small { color: rgb(255 255 255 / .72); }
.shared .scene { min-height: 9.5rem; }
@media (prefers-color-scheme: dark) { .at-home { border-color: color-mix(in srgb, var(--route) 20%, var(--night)); } }
@media (max-width: 560px) { .scene { min-height: 10rem; margin: -1rem -1rem .9rem; padding: 1rem 1rem .6rem; border-radius: 11px 11px 0 0; } .shared .scene { min-height: 8.5rem; }
                            .at-home.pictured { min-height: 10rem; } .next-trip.at-home.pictured { min-height: 8rem; } .at-home h1 { font-size: 2.1rem; }
                            .next-trip.at-home h2, .coming h2 { font-size: 1.75rem; }
                            .at-home .credit, .scene .credit { font-size: .6rem; } }   /* the credit smaller on a phone (owner, 17 Nov) */
.answer.departure .big { color: var(--ok); }                 /* the duty badge's green, red from 15 minutes out */
.answer.departure.soon .big { color: var(--block); }
/* Live status (live-status-plan.md): the ETA green when early or on time and red when late, the scheduled arrival
   struck through beside it; on the owner's page its tags beside the duty badge, which wrap under it on a phone. */
.eta { font-weight: 700; }
.eta.on-time { color: var(--ok); }
.eta.late { color: var(--block); }
s.scheduled { color: var(--muted); }
.badges { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: .3rem; }
.timeline li.pending { background: color-mix(in srgb, var(--warn-bg) 80%, var(--card)); border-left-color: var(--warn); border-radius: 0 8px 8px 0; }
/* A leg of the owner's own that doesn't fit the trip (rows.warnings(): it leaves before the trip's last flight lands,
   from another airport, ...): red, as theirs to fix, where orange is for what the company has still to settle
   (owner, 24 Nov). */
.timeline li.warned { background: color-mix(in srgb, var(--block-bg) 80%, var(--card)); border-left-color: var(--block); border-radius: 0 8px 8px 0; }

/* Sharing */
form.groups label { display: flex; flex-wrap: wrap; gap: .1rem .4rem; align-items: baseline; margin: .5rem 0; }
form.groups .muted { flex-basis: 100%; padding-left: 1.3rem; font-size: .88rem; }
form.groups label.name .muted { padding-left: 0; }
form.groups label.name input { flex: 1; min-width: 8rem; padding: .4rem .6rem; }
form.groups > button { margin-top: .4rem; }
form + h3 { margin-top: 1.25rem; }
.additional { margin-top: 1rem; padding-top: .25rem; border-top: 1px solid var(--line); }
.share-link { display: flex; flex-direction: column; gap: .35rem; padding: .6rem 0; border-top: 1px solid var(--line); }
.share-link .copy { display: flex; gap: .4rem; }
.share-link input { flex: 1; min-width: 0; padding: .45rem .6rem; background-color: var(--well); }
/* Share (_share_button.html): the phone's share sheet, only where the browser has one (pwa.js marks the page). */
html:not(.can-share) .share-sheet { display: none; }
p > .share-sheet { min-height: 0; margin-left: .4rem; padding: .2rem .75rem; font-size: .85rem; }
details.more[open] > summary { margin-bottom: .5rem; }
details.more p { display: flex; flex-direction: column; gap: .1rem; margin: .4rem 0; }
details.more .q { font-size: .82rem; font-weight: 600; color: var(--muted); }
.tracking { margin: .75rem 0 0; }
ul.plain { list-style: none; padding: 0; margin: 0; }
ul.plain li { padding: .15rem 0; }

/* The trip's progress above the globe (_progress.html, travel.progress()), on a night-sky panel in the 3D globe's
   colours: a node for each flight on a line, spaced by the ground time between them and filled in blue to where the
   schedule puts the traveller, marked by a plane over any node it reaches. In the air the plane is green, as the
   globe's dot is, and the flight has its own line above, from its origin to its destination, filled in green as far
   as the plane. The rails are inset by half the largest mark, so the first and last sit wholly in the card. */
.progress { background: var(--night); border-color: var(--night); color: #dde6f5; }
@media (prefers-color-scheme: dark) { .progress { border-color: color-mix(in srgb, var(--route) 20%, var(--night)); } }
.progress .count, .progress .leg { margin: 0 0 .8rem; font: 600 1.35rem/1.2 var(--signage); letter-spacing: .01em; color: #fff; }
.progress .flight + .count { margin-top: 1.5rem; }
.progress .rail { position: relative; height: 26px; margin: 0 13px; }
.progress .rail::before, .progress .fill { content: ''; position: absolute; left: 0; top: 50%; height: 6px; margin-top: -3px;
                                           border-radius: 999px; }
.progress .rail::before { right: 0; background: rgb(255 255 255 / .16); }
.progress .fill { width: var(--at); background: var(--route); box-shadow: 0 0 12px rgb(122 167 255 / .5); }
.progress .node, .progress .head { position: absolute; left: var(--at); top: 50%; border-radius: 50%; transform: translate(-50%, -50%); }
.progress .node { z-index: 1; width: 12px; height: 12px; background: var(--night); border: 2px solid rgb(255 255 255 / .55); }
.progress .node.flown { width: 14px; height: 14px; background: var(--route); border: 3px solid var(--night); }   /* a bead on the fill */
.progress .flight .fill, .progress .flight .node.flown { background: var(--flying); }
.progress .flight .fill { box-shadow: 0 0 12px rgb(111 207 151 / .45); }
.progress .head { z-index: 2; width: 26px; height: 26px; background: var(--night); pointer-events: none;   /* a node's title shows through */
                  box-shadow: 0 0 0 2px var(--route), 0 0 14px 2px rgb(122 167 255 / .6); }
.progress .head::after { content: ''; position: absolute; inset: 4px; background: #fff;
                         --plane: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath transform='rotate(90 12 12)' d='M12 2c.9 0 1.3.9 1.3 1.8V9l7.7 4.6v2l-7.7-2.4v5l2.3 1.7v1.6L12 20.5l-3.6 1v-1.6l2.3-1.7v-5L3 15.6v-2L10.7 9V3.8c0-.9.4-1.8 1.3-1.8z'/%3E%3C/svg%3E");
                         -webkit-mask: var(--plane) center / contain no-repeat; mask: var(--plane) center / contain no-repeat; }
.progress .head.flying { box-shadow: 0 0 0 2px var(--flying), 0 0 14px 2px rgb(111 207 151 / .5); }
.progress .head.flying::after { background: var(--flying); }
.progress .stations { position: relative; height: 1.2rem; margin: .45rem 13px 0; font: 600 .95rem/1.2 var(--signage);
                      letter-spacing: .04em; color: rgb(255 255 255 / .7); }
.progress .stations span { position: absolute; left: var(--at); transform: translateX(-50%); white-space: nowrap; }
.progress .stations span:first-child, .progress .stations span:last-child { color: #fff; }
@media (max-width: 560px) { .progress .count, .progress .leg { font-size: 1.2rem; } .progress .stations { font-size: .85rem; letter-spacing: .02em; } }

/* Route globe: globe-loader.js draws the 3D globe (globe-gl.js) or the simple map (globe.js) into the figure,
   from the JSON beside it, and puts the Simple map toggle by the zoom buttons. */
.globe { margin: 0 0 .9rem; --sea: color-mix(in srgb, var(--accent) 7%, var(--card)); }
.globe .view { margin: 0 0 .5rem; }
/* As wide as the card and square until 360px high (560px on the Travel page); wider frames show more east and west. */
.globe svg, .globe.gl .stage { display: block; width: 100%; aspect-ratio: 1; max-height: 360px; border-radius: 10px; }
.globe.large svg, .globe.large.gl .stage { max-height: 560px; }
.globe svg { touch-action: pan-y; cursor: grab; user-select: none; }
.globe svg.engaged { touch-action: none; }                    /* zoomed by hand: the globe takes every gesture */
.globe svg:active { cursor: grabbing; }
.globe .zoom { display: flex; justify-content: center; gap: .4rem; margin-top: .6rem; }   /* below, never over a route */
.globe .zoom button { min-width: 2.4rem; height: 2.2rem; min-height: 0; padding: 0 .75rem; line-height: 1;
                      touch-action: manipulation; }     /* tapping + twice quickly zooms the globe, not the page */
.globe .zoom .choice { margin-left: .6rem; }
.globe .zoom .choice[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.globe path, .globe circle { vector-effect: non-scaling-stroke; }
.globe .sea { fill: var(--sea); stroke: var(--line); }
.globe .graticule { fill: none; stroke: var(--line); stroke-width: .5; }
.globe .land { fill: color-mix(in srgb, var(--muted) 26%, var(--card)); }
.globe .lakes { fill: var(--sea); }
.globe .states, .globe .borders { fill: none; stroke: color-mix(in srgb, var(--muted) 45%, var(--card)); stroke-width: .5; }
.globe .borders { stroke: color-mix(in srgb, var(--muted) 75%, var(--card)); stroke-width: .9; }
.globe .route { fill: none; stroke: var(--accent); stroke-linecap: round; }
.globe .route.planned { stroke-dasharray: 2 5; }
.globe .route.flying { stroke: var(--ok); }
.globe .airport circle { fill: var(--card); stroke: var(--text); stroke-width: 1.5; }
.globe .airport.base circle { fill: var(--accent); stroke: var(--card); }
.globe .airport text { font-size: 12px; font-weight: 600; fill: var(--muted); stroke: var(--card); stroke-width: 3px;
                       stroke-linejoin: round; paint-order: stroke; }
.globe.large .airport text { font-size: 9.5px; }             /* drawn larger, so about the same size on screen */
.globe .plane { fill: var(--ok); stroke: var(--card); stroke-width: 2; }
.globe figcaption { display: flex; flex-wrap: wrap; justify-content: center; gap: .2rem 1rem; margin-top: .4rem; font-size: .85rem; color: var(--muted); }
.globe figcaption .tracking { flex-basis: 100%; margin: .5rem 0 0; font-size: 1rem; text-align: center; }   /* a line of its own */
.globe .key::before { content: ''; display: inline-block; width: 1.5rem; border-top: 2px solid var(--accent); vertical-align: middle; margin-right: .35rem; }
.globe .key.planned::before { border-top-style: dotted; }
.globe .key.flying::before { width: .6rem; height: .6rem; border: 0; border-radius: 50%; background: var(--ok); }

/* The 3D globe (.gl while it shows): globe-gl.js puts a WebGL canvas in .stage and the airport codes over it.
   globe.gl gives each code a z-index of its own, from 1 up to how many there are, the nearest highest; the stage keeps
   them among themselves (isolation), or with ten codes or more the nearest painted over the phone's tab bar (z-index
   10), as DFW, MEM and IAH did with 14 (owner, 7 Nov). */
.globe.gl { --route: #7aa7ff; --flying: #6fcf97; }           /* the dark theme's colours: the imagery is dark */
.globe.gl .key::before { border-top-color: var(--route); }
.globe.gl .key.flying::before { background: var(--flying); }
.globe.gl .stage { overflow: hidden; isolation: isolate; }
.globe.gl .code, .globe.gl .aircraft { width: 0; height: 0; pointer-events: none; }
.globe.gl .aircraft span { position: absolute; left: -6px; top: -6px; width: 12px; height: 12px; box-sizing: border-box;
                           border-radius: 50%; background: var(--flying); border: 2px solid #fff; }
.globe.gl .code span { position: absolute; left: 5px; bottom: 3px; font: 600 13px/1 var(--signage); letter-spacing: .03em; color: #fff;
                       text-shadow: 0 0 3px #000, 0 0 2px #000; white-space: nowrap; }
form.edit label.check { flex-direction: row; align-items: baseline; gap: .5rem; grid-column: 1 / -1; color: var(--text); font-size: .95rem; }
.timeline li.deviated .title { text-decoration: line-through; }
/* FX Calendar's events in a trip (views._with_fx()), the company's calendar, not the trip, so quiet: its bid month in
   grey. Those during a row are inside it, under its times, in a panel of their own; those between rows are a row of
   their own holding the same panel alone, on the timeline's line: each the calendar's icon, its time, its name, its
   bid month at the right; one already past greyed. */
.timeline li.fx { padding-top: .1rem; padding-bottom: .5rem; }
/* The panel a table: the icon, the times in a column, the names beside them, wrapping there on a phone, and the bid
   month at the right of each name's first line. */
.timeline .fx-during { display: grid; grid-template-columns: 1rem auto minmax(0, 1fr) auto; gap: .35rem .5rem;
  align-items: baseline; margin: .5rem 0 .1rem; padding: .45rem .6rem; border-radius: 8px; font-size: .9rem;
  background: color-mix(in srgb, var(--card) 70%, transparent); box-shadow: inset 0 0 0 1px var(--line); }
.timeline .fx-event { display: contents; }
.timeline .fx-event .icon { align-self: start; width: 1rem; height: 1rem; margin-top: .12rem; color: var(--muted); }
.timeline .fx-event .when { font-variant-numeric: tabular-nums; }
.timeline .fx-event .name { font-weight: 600; }
.timeline .fx-event .label { justify-self: end; background: var(--card); color: var(--muted); box-shadow: inset 0 0 0 1px var(--line);
  white-space: nowrap; }
.timeline .fx-event.past { color: var(--muted); }
/* Pay: one folded card, its working folded within (_pay.html); each duty period a row: day, route, time on duty, and
   its credit with the part that is it. */
.pay > details { margin: .5rem 0 0; padding-top: .5rem; border-top: 1px solid var(--line); }
.pay > details > summary { font-weight: 600; }
.pay-duties { display: grid; grid-template-columns: max-content max-content 1fr max-content; gap: .2rem .8rem; margin: .5rem 0;
              padding: 0; list-style: none; font-variant-numeric: tabular-nums; }
.pay-duties li { display: contents; }
.pay-duties li > :last-child { text-align: right; }
.pay-switch p { margin: .3rem 0; }
/* Its sections, "As flown" and, in the working, "Trip guarantee" and "As flown" again: headed in the signage face of the
   trip numbers and clocks, in the accent blue, the working's two parted by a hairline (owner, 27 Nov: "they just kind of
   run together ... a blue heading that matches the site"). */
.pay .pay-heading { margin: 1rem 0 .4rem; font: 700 1.15rem/1.2 var(--signage); letter-spacing: .01em; color: var(--accent); }
.pay-working > .pay-heading { margin-top: .35rem; }
.pay-working + .pay-working { margin-top: .9rem; padding-top: .35rem; border-top: 1px solid var(--line); }
.pay-working > p:first-of-type { margin-top: 0; }
/* Trip history: one folded card, a folded section for each version's changes (_history.html). */
.history > details { margin: .5rem 0 0; padding-top: .5rem; border-top: 1px solid var(--line); }
.history > details > summary { font-weight: 600; }
/* The Calendar page (calendar.html): each week a grid, its dates in the first row and each trip a bar in a lane below
   them. A bar spans the week's grid area and sits in it by the time of day (calendar.month()): --start and --end are
   minutes into the week, of 10080, so its margin and width are shares of the week. It is never too narrow to tap, and
   one that runs on from the week before or into the next is squared off on that side. */
.month .heading { align-items: center; }
.month .heading a { font-weight: 700; text-decoration: none; white-space: nowrap; }
.month .heading h1 { margin: 0; text-align: center; }
.month .today-link { margin: .2rem 0 .7rem; text-align: center; font-size: .9rem; }
.month .all-trips { margin: .6rem 0 0; font-weight: 700; }
.month .weekdays, .month .week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); }
.month .weekdays span { padding-bottom: .3rem; font-size: .78rem; font-weight: 600; color: var(--muted); text-align: center; }
.month .week { grid-template-rows: 1.7rem; grid-auto-rows: 1.5rem; row-gap: 3px; min-height: 5.2rem; padding: .25rem 0 .45rem;
               border-top: 1px solid var(--line); }
.month .date { grid-column: var(--col); grid-row: 1; justify-self: center; width: 1.6rem; height: 1.6rem; border-radius: 50%;
               font-size: .85rem; font-weight: 600; line-height: 1.6rem; text-align: center; }
.month .date.outside { color: var(--muted); font-weight: 400; }
.month .date.today { background: var(--accent); color: var(--on-accent); }
.month .trip { grid-column: 1 / -1; grid-row: var(--row); justify-self: start; display: flex; min-width: 0;
               margin-left: min(var(--start) * 100% / 10080, 100% - 1.5rem);
               width: max((var(--end) - var(--start)) * 100% / 10080, 1.5rem);
               container-type: inline-size;
               padding: 0 .45rem; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: .8rem;
               font-weight: 600; line-height: 1.5rem; white-space: nowrap; text-decoration: none; overflow: hidden; }
.month .trip.kind-reserve { background: var(--reserve); color: var(--on-reserve); }
.month .trip.kind-training { background: var(--training); color: var(--on-training); }
.month .trip.kind-personal { background: var(--personal); color: var(--on-personal); }
.month .trip.before { border-top-left-radius: 0; border-bottom-left-radius: 0; }
.month .trip.after { border-top-right-radius: 0; border-bottom-right-radius: 0; }
.month .trip.past { background: var(--well); color: var(--muted); box-shadow: inset 0 0 0 1px var(--line); }
.month .trip .number { flex: none; font: 700 .9rem/1.5rem var(--signage); letter-spacing: .02em; }
.month .trip .codes { min-width: 0; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
@container (max-width: 6.5rem) { .month .trip .codes { display: none; } }     /* too short a bar: the number alone */
@container (max-width: 1.5rem) { .month .trip .number { display: none; } }    /* and shorter still: the title alone */
/* FX Calendar's events (calendar.fx_marks()): each a small tag in its day's column, under the bars, its short name
   alone, a lane high; on a phone, in narrow letters, two lanes high for a name that takes two lines. Tapped, a popover
   in the middle of the screen with all of it. */
.month .fx { grid-column: var(--col); grid-row: var(--row); display: block; min-width: 0; min-height: 0; margin: 0 2px;
             padding: 0 .35rem; border: 1px solid var(--line); border-radius: 5px; background: var(--well); color: var(--text);
             font-size: .72rem; font-weight: 600; line-height: calc(1.5rem - 2px); text-align: left; white-space: nowrap;
             overflow: hidden; text-overflow: ellipsis; }
.month .fx:hover { background: var(--tint); }
.month .fx.past { color: var(--muted); }
@media (max-width: 560px) {
  .month .fx { grid-row: var(--narrow) / span 2; display: flex; align-items: center; margin: 0 1px; padding: .1rem .2rem;
               font: 600 .74rem/1.05 var(--signage); white-space: normal; overflow-wrap: anywhere; }
}
.fx-detail { margin: auto; padding: .8rem 1rem; display: none; flex-direction: column; gap: .2rem; max-width: min(22rem, 90vw);
             border: 1px solid var(--line); border-radius: 12px; background: var(--card); color: var(--text);
             box-shadow: 0 12px 32px rgb(0 0 0 / .22); font-size: .93rem; }
.fx-detail:popover-open { display: flex; }
.fx-detail::backdrop { background: rgb(0 0 0 / .15); }
/* Reserve days (reserve.html): the month's days to tick, by tap or drag (days.js), a day on reserve showing its code,
   and the codes to choose from. The grid takes the touch, so a drag picks days rather than scrolling the page. */
.days-pick .heading h2 { margin: 0; text-align: center; }
.days-pick .days { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 4px; touch-action: none;
                   user-select: none; -webkit-user-select: none; }
.days-pick .day { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
                  min-height: 3.1rem; border-radius: 10px; background: var(--well); cursor: pointer; }
.days-pick .day input { position: absolute; inset: 0; margin: 0; opacity: 0; pointer-events: none; }
.days-pick .day .n { font-weight: 600; line-height: 1.4; }
.days-pick .day .code { min-height: 1em; font-size: .72rem; font-weight: 700; line-height: 1; color: var(--reserve); }
.days-pick .day.outside .n { color: var(--muted); font-weight: 400; }
.days-pick .day.today .n { text-decoration: underline 2px; text-underline-offset: .2em; }
.days-pick .day:has(input:checked) { background: var(--reserve); }
.days-pick .day input:checked ~ span { color: var(--on-reserve); }
.days-pick .day:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.days-pick .codes { display: flex; flex-wrap: wrap; gap: .5rem 1.1rem; margin: 1rem 0 0; padding: 0; border: 0; }
.days-pick .codes legend { margin-bottom: .4rem; padding: 0; font-weight: 600; }
.days-pick .codes label { display: flex; align-items: baseline; gap: .35rem; white-space: nowrap; }
.timeline .day-acts form { display: inline; }
/* Training (training.html, T1): the grid in training's colour, a day's codes cut short to fit its cell, and what's
   known of the days ticked (codes, times, place), which a training day's Change form on its stretch's page has too. */
.days-pick .day .code { max-width: 100%; padding: 0 .2rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.days-pick.kind-training .day .code { color: var(--training); }
.days-pick.kind-training .day:has(input:checked) { background: var(--training); }
.days-pick.kind-training .day input:checked ~ span { color: var(--on-training); }
.training-fields { display: flex; flex-wrap: wrap; align-items: baseline; gap: .5rem 1rem; margin: 1rem 0 0; padding: 0; border: 0; }
.training-fields legend { margin-bottom: .4rem; padding: 0; font-weight: 600; }
.training-fields label { display: flex; align-items: baseline; gap: .35rem; margin: 0; }
.training-fields input[name=codes] { width: 9rem; }
.training-fields input[name=place] { width: 3.6rem; }
.training-fields p { flex-basis: 100%; margin: 0; }

/* What's new (web/whatsnew): the header's panel, the highlight banner, and the entries by day, in the panel and on
   the fallback page (as cards). The unread count is with the header, above. */
.message.whats-new { background: color-mix(in srgb, var(--accent) 12%, var(--card)); }
.message.whats-new form { display: inline; margin: 0; }
.news h3 { margin: 1rem 0 .4rem; }
.entry h4 { font-size: 1rem; margin: 0; }
.entry h4 .label { vertical-align: .1em; margin-right: .2rem; }
.entry p { margin: .4rem 0 0; }
.entry ul { margin: .4rem 0 0; padding-left: 1.2rem; }
.entry li + li { margin-top: .2rem; }
.entry.unseen { border-left: 3px solid var(--accent); }
.entry .badge { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
.label.new { background: var(--ok-bg); color: var(--ok); }
.label.improved { background: color-mix(in srgb, var(--accent) 14%, transparent); color: var(--accent); }
.label.fixed { background: var(--line); color: var(--muted); }
.label.beta { background: var(--review-bg); color: var(--review); }
/* A popover: over the page at the top right, the whole width on a phone; a tap outside or Escape closes it. */
.whats-new-panel { position: fixed; inset: 3.35rem max(1rem, env(safe-area-inset-right)) auto auto; margin: 0;
                   width: min(28rem, calc(100vw - 1.5rem));
                   max-height: calc(100dvh - 4.5rem); overflow-y: auto; overscroll-behavior: contain;
                   padding: 0 1.1rem 1rem; background: var(--card);
                   color: var(--text); border: 1px solid var(--line); border-radius: 14px;
                   box-shadow: 0 12px 32px rgb(0 0 0 / .22); }
.whats-new-panel::backdrop { background: rgb(0 0 0 / .15); }
.whats-new-panel > .heading { position: sticky; top: 0; z-index: 1; background: var(--card); padding: .85rem 0 .5rem;
                              border-bottom: 1px solid var(--line); align-items: center; }
.whats-new-panel h2 { margin: 0; font: 700 1.5rem/1.1 var(--signage); }
.whats-new-panel .close { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: 50%; font-size: 1rem;
                          line-height: 1; color: var(--muted); }
.whats-new-panel .close:hover { background: var(--well); color: var(--text); text-decoration: none; }
.whats-new-panel > p { margin: .75rem 0 0; }
.whats-new-panel .news h3 { margin: 1rem 0 .1rem; }
.whats-new-panel .entry { padding: .6rem 0 .65rem; }
.whats-new-panel .entry + .entry { border-top: 1px solid var(--line); }
.whats-new-panel .entry.unseen { padding-left: .7rem; }
@media (max-width: 560px) { .whats-new-panel { inset: .5rem .5rem auto; width: auto; max-height: calc(100dvh - 1rem); } }
/* Send feedback, first in the panel and on the page: a bar tinted as an action is, set apart from the entries, that
   opens into the form. Its chevron is at the end, down while folded and up once open. */
.feedback-slot { margin: .9rem 0 1.5rem; }
.feedback-slot .message { margin: 0; }
details.feedback { border-radius: 12px; background: var(--tint); }
details.feedback > summary { gap: .6rem; min-height: 3rem; padding: .55rem .95rem .55rem .85rem; border-radius: 12px;
                             color: var(--accent); }
details.feedback > summary:hover { background: var(--tint-strong); }
details.feedback > summary::before { order: 1; margin: 0 .15rem 0 auto; transform: translateY(-.12rem) rotate(45deg); }
details.feedback[open] > summary::before { transform: translateY(.12rem) rotate(-135deg); }
details.feedback form { margin: 0; padding: .15rem .95rem .95rem; }
.feedback .kinds { display: flex; flex-wrap: wrap; gap: .25rem 1.1rem; border: 0; padding: 0; margin: 0 0 .5rem; }
.feedback .kinds label { display: inline-flex; gap: .35rem; align-items: center; margin: 0; }
.feedback .kinds input { margin: 0; }
.feedback textarea { display: block; width: 100%; resize: vertical; }
.feedback .actions { margin-top: .5rem; }

/* The Your travel sheet (trip-changes-plan.md, T3; _travel.html): over the trip page, rising from the foot of a phone
   and centred on a wider screen. The owner's legs sit on --mine's rail, as in the events list, with the time on the
   ground between them; From and To are typed in signage type, as the board would show them. One action leads at a
   time: the leg form's while it's open, Save once it's shut. With a phone's keyboard up, it stands on the keyboard
   and fits what's left above it (--covered, the keyboard's height: sheet.js). */
dialog.sheet { position: fixed; inset: auto 0 var(--covered, 0px); width: min(100%, 36rem); max-width: 100%;
  max-height: min(92dvh, calc(100% - var(--covered, 0px)));
  margin: 0 auto; padding: 0; border: 0; border-radius: 18px 18px 0 0; background: var(--card); color: var(--text);
  box-shadow: 0 -10px 34px rgba(8, 14, 24, .22); overflow: auto; overscroll-behavior: contain; }
dialog.sheet::backdrop { background: color-mix(in srgb, #08101c 48%, transparent); }
dialog.sheet[open] { animation: sheet-rise .2s ease-out; }
@keyframes sheet-rise { from { transform: translateY(1.5rem); opacity: .5; } }
@media (min-width: 641px) { dialog.sheet { inset: 0 0 var(--covered, 0px); margin: auto;
  max-height: min(88vh, calc(100% - var(--covered, 0px))); border-radius: 16px; } }
@media (prefers-reduced-motion: reduce) { dialog.sheet[open] { animation: none; } }
.travel { display: grid; gap: 1rem; padding: .55rem 1.1rem 0; }
.travel .sheet-head { display: grid; gap: .1rem; }
.travel .grab { width: 2.4rem; height: .26rem; margin: 0 auto .45rem; border-radius: 9px; background: var(--edge); }
@media (min-width: 641px) { .travel .grab { display: none; } .travel { padding-top: 1.1rem; } }
.travel h2 { margin: 0; font: 700 1.6rem/1.1 var(--signage); letter-spacing: .005em; }
.travel .sheet-head p, .travel .hint { margin: 0; font-size: .85rem; }
.travel .hint { color: var(--muted); }
.travel h3, .travel legend { margin: 0 0 .35rem; padding: 0; font-size: .82rem; font-weight: 700; color: var(--muted); }
.travel fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.travel fieldset .hint { margin-bottom: .35rem; }
.travel label.tick { display: grid; grid-template-columns: 1.1rem 1fr; gap: .6rem; align-items: start; margin: 0;
  padding: .5rem 0; border-top: 1px solid var(--line); cursor: pointer; }
.travel label.tick input { width: 1.1rem; height: 1.1rem; margin: .15rem 0 0; }
.travel label.tick .what { font-weight: 600; }
.travel label.tick .muted { display: block; font-size: .82rem; }
.travel label.tick:has(input:checked) .what { text-decoration: line-through; text-decoration-color: var(--muted); }
.travel label.tick.beside { color: var(--muted); }
.travel ol.legs { display: grid; gap: 0; margin: 0; padding: 0; list-style: none; }
.travel li.leg { display: grid; grid-template-columns: 1fr auto; gap: .1rem .75rem; padding: .6rem .75rem;
  border-left: 3px solid var(--mine); border-radius: 0 10px 10px 0; background: color-mix(in srgb, var(--mine) 7%, var(--card)); }
.travel li.leg.hotel { border-left-style: dashed; }
.travel li.leg + li.leg { margin-top: .4rem; }
.travel li.leg .kind { font-size: .78rem; font-weight: 600; color: var(--mine); }
.travel li.leg .when { grid-column: 1; font-size: .88rem; font-variant-numeric: tabular-nums; }
.travel li.leg .actions { grid-column: 2; grid-row: 1 / span 2; display: flex; gap: .8rem; align-self: center; font-size: .88rem; }
.travel li.leg .warning { grid-column: 1 / -1; font-size: .84rem; color: var(--block); }   /* the trip page's red */
.travel li.leg:has(.leg-form) { display: block; padding: 0; border: 0; background: none; }
.travel li.ground { margin: 0; padding: .3rem 0 .3rem .95rem; border-left: 3px dotted color-mix(in srgb, var(--mine) 55%, var(--card));
  font-size: .82rem; color: var(--muted); }
.travel li.ground.end { margin-top: .4rem; border-left-style: solid; color: var(--text); }
.travel .adds { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .7rem; }
.leg-form { display: grid; gap: .65rem; margin-top: .7rem; padding: .85rem; border: 1px solid var(--edge); border-radius: 12px; }
.leg-form h4 { margin: 0; font-size: 1rem; }
.leg-form > p { margin: -.4rem 0 0; font-size: .85rem; }
/* Flight / Train / Drive atop a new leg's form (owner, 7 Nov): the time switch's well and thumb (.zones), across the
   form and taller for a thumb, as the first choice the form asks for. */
.leg-form .modes { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 2px; padding: 3px;
  border-radius: 999px; background: var(--well); }
.leg-form .modes button { min-height: 2.3rem; padding: .3rem .7rem; border-radius: 999px; background: none;
  color: var(--muted); font: 600 .9rem/1.2 var(--sans); }
.leg-form .modes button:hover { background: none; color: var(--text); }
.leg-form .modes button[aria-pressed=true] { background: var(--thumb); color: var(--text); cursor: default;
  box-shadow: 0 0 0 1px var(--line), 0 1px 2px rgb(0 0 0 / .12); }
.leg-form .modes button:focus-visible { outline-offset: 1px; }
.leg-form > .modes + p { margin-top: 0; }
.leg-form label { display: grid; gap: .2rem; margin: 0; font-size: .82rem; font-weight: 600; color: var(--muted); }
.leg-form input:not([type=checkbox]), .leg-form select { width: 100%; font-weight: 600; color: var(--text); }
.leg-form input[type=date] { font: inherit; font-weight: 600; color: var(--text); background: var(--card);
  border: 1px solid var(--edge); border-radius: 8px; padding: .45rem .6rem; min-height: 2.5rem; }
.leg-form input.code { font: 700 1.35rem/1.1 var(--signage); letter-spacing: .06em; text-transform: uppercase; }
/* A pair's two boxes stay level on one subgrid, its words above and an error below either one. */
.leg-form .pair { display: grid; grid-template-columns: 1fr 1.1rem 1fr; grid-template-rows: auto auto auto;
  gap: .2rem .45rem; align-items: start; }
.leg-form .pair > label { grid-column: 1; grid-row: 1 / span 3; grid-template-rows: subgrid; }
.leg-form .pair > .arrow + label { grid-column: 3; }
.leg-form .pair > label > :first-child { align-self: end; }
.leg-form .pair .arrow { grid-column: 2; grid-row: 2; align-self: center; text-align: center; color: var(--muted); }
.leg-form .error { font-weight: 400; color: var(--block); }
.leg-form .looked-up { font-weight: 400; color: var(--accent); }
.leg-form .hint { font-size: .85rem; color: var(--muted); }
.leg-form .buttons { display: flex; flex-wrap: wrap; gap: .8rem; align-items: center; }
.leg-form .manual { display: grid; gap: .65rem; }
.leg-form details.manual[open] { padding-top: .1rem; }
.leg-form details.manual > summary { font-size: .88rem; color: var(--accent); cursor: pointer; }
.leg-form details.manual > summary + * { margin-top: .65rem; }
.leg-form .manual label.toggle { display: inline-flex; margin-top: .65rem; font-size: .88rem; color: var(--text); }
.leg-form .lookup p { margin: 0 0 .3rem; font-size: .88rem; }
.leg-form ul.results { margin: 0; padding: 0; list-style: none; }
.leg-form ul.results li { display: flex; justify-content: space-between; align-items: center; gap: .6rem; padding: .45rem 0;
  border-top: 1px solid var(--line); font-size: .9rem; font-variant-numeric: tabular-nums; }
.travel .sheet-foot { position: sticky; bottom: 0; display: grid; gap: .55rem; margin: 0 -1.1rem; padding: .8rem 1.1rem
  calc(1rem + env(safe-area-inset-bottom)); border-top: 1px solid var(--line); background: var(--card); }
.travel .sheet-foot p { margin: 0; font-size: .88rem; }
.travel .sheet-foot .message { margin: 0; }
.travel .sheet-foot .family { color: var(--muted); }
.travel .sheet-foot .buttons { display: flex; gap: .6rem; align-items: center; }
.travel > :last-child:not(.sheet-foot) { margin-bottom: 1.1rem; }

/* On the trip page: where the owner's own travel can go, and the row's way into the sheet. */
.timeline li.your-travel { display: flex; flex-wrap: wrap; gap: .2rem .6rem; align-items: baseline;
  border-left: 3px dashed color-mix(in srgb, var(--mine) 60%, var(--card)); }
.timeline li.your-travel .kind { color: var(--mine); font-weight: 600; }
.timeline [id^="item-"], .timeline [id^="drive-"] { scroll-margin-top: 5rem; }   /* below the header, after a save */

/* A row of the owner's events list opens in place when tapped, with what can be done to it (_acts.html, rows.js),
   standing out as a box on its own rail. Its summary is only for the keyboard, which rings the row. What's off the
   trip stays struck through in its place, with Restore at the right; and an Instead of row's Restore too. */
.timeline li:has(> details.acts) { cursor: pointer; }
.timeline li:has(> details.acts[open]) { cursor: auto; box-shadow: 0 0 0 1px var(--line); border-radius: 0 10px 10px 0; opacity: 1; }
.timeline li:has(> details.acts > summary:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (hover: hover) { .timeline li:has(> details.acts:not([open])):hover { background: color-mix(in srgb, var(--accent) 5%, var(--card)); } }
.timeline details.acts > .line, .timeline details.acts > form.drive-time { margin-top: .5rem; padding-top: .5rem;
  border-top: 1px solid var(--line); gap: .4rem 1.1rem; font-size: .9rem; }
.timeline details.acts > .line a, .timeline details.acts button.linklike { font-weight: 600; text-decoration: none; }
.timeline details.acts > .line form { display: inline; margin: 0; }
.timeline form.drive-time label { display: inline-flex; align-items: baseline; gap: .5rem; margin: 0; color: var(--muted); }
.timeline form.drive-time input { width: 5.5rem; padding: .35rem .5rem; }
.timeline form.drive-time .muted { flex-basis: 100%; font-size: .82rem; }
.timeline form.correct { margin-top: .6rem; }
.timeline form.correct .crop, .timeline form.correct > p { grid-column: 1 / -1; margin: 0; }
.timeline li.removed .title { text-decoration: line-through; color: var(--muted); }
.timeline .label.mine { background: color-mix(in srgb, var(--mine) 12%, var(--card)); color: var(--mine); }
.timeline form.restore { display: inline; margin: 0 0 0 auto; }
.timeline li.instead { display: flex; align-items: baseline; gap: .6rem; }
.timeline li.instead > details { flex: 1; min-width: 0; }
.timeline .warning { margin: .25rem 0 0; color: var(--block); font-size: .88rem; font-weight: 600; }
.timeline .settle { margin: .5rem 0 0; padding: .6rem .75rem; border-radius: 8px; background: var(--warn-bg); font-size: .92rem; }
.timeline .settle p { margin: 0 0 .5rem; }
.timeline .settle .buttons { display: flex; flex-wrap: wrap; gap: .5rem; margin: 0; }
.message.revision-notice ul { margin: .4rem 0 0; padding-left: 1.2rem; }
/* Correct trip details and Add an event, open under the trip page's last line (_fixing.html). A flight has
   the Your travel sheet's leg form, the card its box. */
form.fixing { margin-top: .5rem; }
form.fixing h2, form.fixing > p { grid-column: 1 / -1; margin: 0; }
form.fixing .leg-form { margin: 0; padding: 0; border: 0; }

/* The installed app (pwa-plan.md, Native feel). A page crossfades into the next where the browser can (Chrome 126,
   Safari 18.2), the tab bar holding still; installed, there is no rubber band past the top, as there is no
   pull-to-refresh to give it to (refresh.js keeps a page current). Install, on Profile (pwa.js). The header itself
   has no view-transition-name: one makes it a stacking context, and the tab bar inside it, fixed along the bottom on a
   phone, went under the 3D globe's canvas and couldn't be tapped (owner, 7 Nov). It looks the same on every page, so
   its crossfade doesn't show. */
@media (prefers-reduced-motion: no-preference) { @view-transition { navigation: auto; } }
.bar .tabs { view-transition-name: tabs; }
@media (display-mode: standalone) { html { overscroll-behavior-y: none; } }
.install { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .6rem 1rem; }
.install p { margin: 0; flex: 1 1 18rem; }
/* Install shows where pwa.js finds the browser offers it (its prompt) or it's an iPhone's Safari (how to): by a class
   on the root, as a share page's <main> is put in anew each minute (refresh.js). */
html:not(.install-prompt):not(.install-ios) .install, html:not(.install-prompt) .install [data-how="prompt"],
html:not(.install-ios) .install [data-how="ios"] { display: none; }

/* A Crew Calendar's page (calendar_review.html): the reading on the weeks the screenshot shows, read-only but for the
   days with a change, each a label for its tick in the list under it. It scrolls like any page: nothing to drag. */
.calendar-read .days { touch-action: auto; user-select: auto; -webkit-user-select: auto; }
.calendar-read .day { cursor: default; }
.calendar-read label.day { cursor: pointer; }
.calendar-read .day.change-add, .calendar-read .day.change-change { box-shadow: inset 0 0 0 2px var(--reserve); }
.calendar-read .day.change-remove { outline: 2px dashed var(--muted); outline-offset: -2px; }
.calendar-read .day.change-remove .code { color: var(--muted); }
.calendar-read .day .code.training { color: var(--training); }
.calendar-read .day.change-training.change-add, .calendar-read .day.change-training.change-change { box-shadow: inset 0 0 0 2px var(--training); }
.calendar-read h2 { margin: 1.1rem 0 .4rem; }
.calendar-changes { list-style: none; margin: 0 0 .8rem; padding: 0; }
/* A Training Schedule's days as read, each with its activities under it (T3). */
.training-read h2 { margin: 1.1rem 0 .4rem; }
.read-days { list-style: none; margin: .6rem 0; padding: 0; }
.read-days li { padding: .3rem 0; border-top: 1px solid var(--line); }
.read-days li:first-child { border-top: 0; }
.read-days .muted { font-size: .9em; }
/* A training day's facility, where the crew go on the day, in the text's own colour on its muted activity line, as the
   title above it is (owner, 26 Nov: "make the facilities the same white as the event on top"). */
.timeline .activities .facility, .read-days .facility { color: var(--text); }
.calendar-changes li { padding: .3rem 0; }
.calendar-changes label { display: grid; grid-template-columns: auto 1fr; align-items: baseline; gap: .5rem; margin: 0; }

/* Getting started, on Now before the first trip (start.html, onboarding-plan.md): the trip progress rail with a
   station for each step, named in words and spread to the rail's ends; then the first import, with the screens
   FeetWet reads drawn above its button (_screens.html), whose file field is the button itself. */
.progress.start .stations { display: grid; grid-template-columns: 1fr 1fr 1fr; height: auto; margin-inline: 0; padding: 0; list-style: none; }
.progress.start .stations li { text-align: center; color: rgb(255 255 255 / .6); }
.progress.start .stations li:first-child { text-align: left; }
.progress.start .stations li:last-child { text-align: right; }
.progress.start .stations li.next { color: #fff; }
.first > p, .explain > p { max-width: 34rem; }
.screens { display: grid; grid-template-columns: repeat(3, minmax(0, 9.5rem)); gap: .75rem; margin: 1rem 0 1.1rem; padding: 0; list-style: none; }
.screens li { display: flex; flex-direction: column; gap: .1rem; font-size: .88rem; color: var(--muted); }
.screens svg { width: 100%; height: auto; margin-bottom: .35rem; border-radius: 8px; background: var(--well); }
.screens small { font-size: .85em; opacity: .8; }
.screens strong { font: 600 1.05rem/1.2 var(--signage); letter-spacing: .01em; color: var(--text); }
.screens .ink { fill: var(--edge); }
.screens .key { fill: var(--accent); }
.screens .page { fill: var(--card); stroke: var(--edge); }
.first .upload label { position: relative; cursor: pointer; }
.first .upload label:focus-within { outline: 2px solid var(--accent); outline-offset: 2px; }
.first .upload input[type=file] { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.first .otherwise { margin: 1.1rem 0 0; padding-top: .9rem; border-top: 1px solid var(--line); }
.hide-start { margin: -.2rem 0 1rem; text-align: center; font-size: .85rem; }
.hide-start .linklike { color: var(--muted); }
@media (max-width: 560px) { .screens { gap: .5rem; } .screens li { font-size: .8rem; } .first .upload label { width: 100%; } }
.first .otherwise { max-width: none; }
/* Help (onboarding-plan.md, O3). A page's line of help at its foot ({% help %}): quiet, the footer's look, each topic
   a link that opens it in the panel (#help, the What's new panel's shape). */
.page-help { margin: 1.25rem 0 0; text-align: center; font-size: .85rem; color: var(--muted); }
.page-help a { color: inherit; }
.page-help a:hover, .page-help a:focus-visible { color: var(--accent); }
.page-help .mark { display: inline-grid; place-items: center; width: 1.15rem; height: 1.15rem; margin-right: .2rem; border: 1px solid var(--edge);
                   border-radius: 50%; font: 700 .7rem/1 var(--sans); }
.help-contents nav { line-height: 1.9; }
.help-topic { scroll-margin-top: 4.5rem; }
.help-topic:target { background: color-mix(in srgb, var(--accent) 7%, var(--card)); }
.help-topic h3 { margin: 1.1rem 0 .25rem; font-size: 1rem; color: var(--text); }
.help-topic p, .help-topic li, .help-topic dd { max-width: 38rem; }
.help-topic p { margin: 0 0 .6rem; }
.help-topic ul, .help-topic ol { margin: 0 0 .6rem; padding-left: 1.2rem; }
.help-topic li { margin-bottom: .3rem; }
.help-topic .screens { padding: 0; }
.help-topic .screens li { margin: 0; }
.help-topic li p { margin: .1rem 0 .5rem; }
.help-topic .badge { margin-right: .25rem; }
.help-switches { margin: 0 0 .6rem; }
.help-switches dt { font-weight: 600; }
.help-switches dd { margin: 0 0 .5rem; color: var(--muted); }
.help-ask { text-align: center; margin: .25rem 0 1rem; }
.help-panel .help-topic { padding-top: .5rem; }
.help-panel .screens { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.help-panel .help-foot { margin: .9rem 0 0; padding-top: .7rem; border-top: 1px solid var(--line); }
/* The prompts on Now (onboarding-plan.md, O4): a line above the trip. Install's only where the browser can install
   (pwa.js sets the root's class), and the prompt after it where it can't. */
.message.prompt { background: color-mix(in srgb, var(--accent) 12%, var(--card)); }
.message.prompt form { display: inline; margin: 0; }
.needs-install { display: none; }
.install-prompt .message.needs-install, .install-ios .message.needs-install { display: block; }
.install-prompt li.needs-install, .install-ios li.needs-install { display: list-item; }
.install-prompt .unless-install, .install-ios .unless-install { display: none; }
/* A shared page's About this page (onboarding-plan.md, O6). */
.about p, .about li { max-width: 38rem; font-size: .93rem; }
.about ul { margin: .4rem 0 .6rem; padding-left: 1.2rem; }
.about .hours { display: inline-flex; vertical-align: middle; margin-left: .3rem; }
