:root {
  --bg: #f6fafb;
  --surface: #ffffff;
  --text: #15233f;
  --muted: #5b6b82;
  --line: #dbe6ea;
  --navy: #1b3f8a;
  --teal: #2bb3a3;
  --orange: #f58a2b;
  --button-text: #ffffff;
  --radius: 22px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111113;          /* the app's own dark greys, so the illustrations sit on the same tone */
    --surface: #1c1c1e;
    --text: #f2f4f8;
    --muted: #a5adba;
    --line: #2c2c2e;
    --navy: #8fb3ff;
    --teal: #5fd6c6;
    --button-text: #111113;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--navy); }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .5em; }
h1 { font-size: clamp(2.4rem, 6vw, 4rem); font-weight: 800; }
h2 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); font-weight: 750; }
h3 { font-size: 1.15rem; font-weight: 700; }
p { margin: 0 0 1em; }

.top, main > section, footer { width: min(1120px, 100% - 32px); margin-inline: auto; }

/* Header */
.top { display: flex; align-items: center; justify-content: space-between; padding: 20px 0; }
.lockup { width: 150px; }
.pill {
  font-weight: 600; font-size: .95rem; text-decoration: none;
  padding: 9px 16px; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface);
}

/* Hero */
.hero { display: grid; gap: 24px; padding: 40px 0 72px; text-align: center; }
.eyebrow { color: var(--teal); font-weight: 700; font-size: .9rem; text-transform: uppercase; letter-spacing: .08em; margin-bottom: .8em; }
.lede { font-size: 1.2rem; color: var(--muted); max-width: 34em; margin: 0 auto 1.6em; }
.hero-art img { border-radius: var(--radius); margin: 0 auto; }

.button {
  display: inline-block; border: 0; cursor: pointer; text-decoration: none;
  background: var(--navy); color: var(--button-text);
  font: inherit; font-weight: 700; padding: 14px 26px; border-radius: 999px;
  transition: transform .15s ease, box-shadow .15s ease;
}
.button:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgb(27 63 138 / .25); }
.button:focus-visible, input:focus-visible, .pill:focus-visible { outline: 3px solid var(--teal); outline-offset: 2px; }

/* Features */
.features { padding: 24px 0 72px; text-align: center; }
.grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); margin-top: 28px; text-align: left; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; }
.card .icon { width: 56px; margin-bottom: 14px; }
.card p { color: var(--muted); margin: 0; }

/* Alternating sections */
/* Real app screens, in a simple device outline (light-mode screens read fine on the dark page inside it). */
.screens { padding: 24px 0 56px; text-align: center; }
.screens-row { display: flex; gap: 22px; align-items: flex-end; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 16px 4px 12px; margin: 12px 0 8px; -webkit-overflow-scrolling: touch; }
.screens figure { flex: 0 0 auto; margin: 0; scroll-snap-align: center; }
.screens .phone { width: 200px; }
.screens .watch { width: 150px; }
.screens img { width: 100%; border: 7px solid #111113; background: #111113; box-shadow: 0 12px 30px rgb(21 35 63 / .18); }
.screens .phone img { border-radius: 32px; }
.screens .watch img { border-radius: 40px; border-width: 9px; }
.screens figcaption { margin-top: 12px; font-weight: 600; font-size: .95rem; }
@media (prefers-color-scheme: dark) { .screens img { border-color: #3a3a3c; box-shadow: none; } }
@media (min-width: 1120px) { .screens-row { justify-content: center; overflow-x: visible; } }

.split { display: grid; gap: 28px; align-items: center; padding: 40px 0; }
.split img { width: min(420px, 100%); margin: 0 auto; }
.split p { color: var(--muted); font-size: 1.08rem; }

/* Launch: the App Store badge, and a QR code for visitors on a computer (hidden on phones and tablets) */
.get { display: flex; flex-direction: column; align-items: center; gap: 8px; margin-top: 4px; }
.get .fine { margin: 0; }
.badge-link { display: inline-block; border-radius: 10px; }
.badge-link img { height: 56px; width: auto; }
.badge-link:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }
.join .get { margin: 24px 0 8px; }
.qr { display: none; margin-top: 20px; }
.qr img { width: 132px; margin: 0 auto 6px; border-radius: 12px; border: 1px solid var(--line); }
.qr .fine { margin: 0; }
@media (hover: hover) and (pointer: fine) and (min-width: 860px) { .qr { display: block; } }

/* Free and Pro */
.plans { padding: 48px 0 24px; text-align: center; }
.plans-lede { color: var(--muted); max-width: 36em; margin: 0 auto 28px; font-size: 1.05rem; }
.plans-grid { display: grid; gap: 20px; text-align: left; }
.plan { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 24px 20px; }
.plan h3 { margin: 0 0 4px; font-size: 1.35rem; }
.plan-tagline { margin: 0 0 14px; color: var(--muted); }
.plan-price { margin: 0 0 14px; font-weight: 600; color: var(--teal); font-size: .95rem; }
.plan ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.plan li { position: relative; padding-left: 26px; line-height: 1.4; }
.plan li::before { content: ""; position: absolute; left: 0; top: .35em; width: 14px; height: 8px;
  border-left: 2.5px solid var(--teal); border-bottom: 2.5px solid var(--teal); transform: rotate(-45deg); }
.plan-pro { border: 2px solid var(--teal); }
@media (min-width: 760px) { .plans-grid { grid-template-columns: 1fr 1fr; } }

.join {
  text-align: center; background: var(--surface); border: 1px solid var(--line); border-radius: 30px;
  padding: 48px 24px; margin-block: 56px 40px;
}
.join .mark { width: 72px; margin: 0 auto 16px; }
.join > p { color: var(--muted); max-width: 32em; margin-inline: auto; }
.signup { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 24px auto 12px; max-width: 520px; }
.signup input[type=email], .signup input[type=password] {
  flex: 1 1 240px; font: inherit; color: var(--text); background: var(--bg);
  border: 1.5px solid var(--line); border-radius: 999px; padding: 13px 20px;
}
.status { font-weight: 600; border-radius: 14px; padding: 12px 16px; max-width: 32em; margin: 20px auto 0 !important; }
.status.ok { background: rgb(43 179 163 / .14); color: var(--text); }
.status.err { background: rgb(214 69 65 / .12); color: var(--text); }
.fine { font-size: .85rem; color: var(--muted); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

footer { text-align: center; color: var(--muted); padding: 8px 0 48px; font-size: .95rem; }
footer p { margin: .3em 0; }

@media (min-width: 860px) {
  .hero { padding-top: 56px; }
  .split { grid-template-columns: 1fr 1fr; gap: 56px; }
  .split.reverse > div:first-child { order: 2; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button { transition: none; }
}

/* Long-form pages (privacy policy): a readable column on a card, in the site's type and colours. */
.prose {
  max-width: 760px; margin: 16px auto 56px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 30px;
  padding: clamp(24px, 5vw, 48px);
}
.prose h1 { font-size: clamp(2rem, 5vw, 2.8rem); margin-bottom: .2em; }
.prose h2 { font-size: 1.3rem; color: var(--navy); margin: 1.8em 0 .5em; letter-spacing: -0.01em; }
.prose p, .prose li { color: var(--text); }
.prose .muted { color: var(--muted); font-size: .95rem; margin-bottom: 1.6em; }
.prose ul { padding-left: 1.2em; }
.prose li { margin: .35em 0; }
.prose table { border-collapse: collapse; width: 100%; font-size: .95rem; margin: .5em 0 1.2em; display: block; overflow-x: auto; }
.prose td, .prose th { border-bottom: 1px solid var(--line); padding: 10px 8px; text-align: left; vertical-align: top; }
.prose th { color: var(--muted); font-weight: 600; }

/* Waitlist admin */
.admin .signup { justify-content: flex-start; margin-left: 0; }
button.pill { cursor: pointer; font: inherit; font-weight: 600; font-size: .95rem; color: var(--navy); margin-top: 8px; }

/* Shared trip page (trip.php) */
.trip > section { width: min(760px, 100% - 32px); margin-inline: auto; }
.trip-hero { padding: 12px 0 28px; }
.trip-hero h1 { font-size: clamp(2rem, 6vw, 3rem); margin-bottom: .2em; }
.trip-hero .lede { margin: 0 0 1.2em; font-size: 1.1rem; }
.cover { margin: 0 0 24px; position: relative; }
.cover img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: var(--radius); }
.cover figcaption { position: absolute; right: 10px; bottom: 10px; font-size: .75rem; color: #fff; background: rgb(0 0 0 / .45); padding: 3px 8px; border-radius: 999px; }
.cover figcaption a { color: #fff; text-decoration: underline; }
.stops { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.stops li { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 6px 16px 6px 6px; }
.stops .num { width: 28px; height: 28px; border-radius: 50%; background: var(--navy); color: var(--button-text); display: grid; place-items: center; font-weight: 700; font-size: .85rem; }
.stops small { display: block; color: var(--muted); font-size: .8rem; line-height: 1.2; }
.days { display: grid; gap: 14px; padding-bottom: 24px; }
.day { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; }
.day header { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 10px; }
.day h2 { font-size: 1.25rem; margin: 0; }
.day h2 span { color: var(--muted); font-weight: 500; }
.day .place { margin: 0; color: var(--teal); font-weight: 700; font-size: .95rem; text-align: right; }
.day ul { list-style: none; margin: 0; padding: 0; }
.day li { display: grid; grid-template-columns: 84px 34px 1fr; gap: 10px; align-items: start; padding: 10px 0; border-top: 1px solid var(--line); }
.day li:first-child { border-top: 0; }
.day time { color: var(--muted); font-variant-numeric: tabular-nums; font-size: .95rem; text-align: right; padding-top: 4px; white-space: nowrap; }
.day .badge, .flight .badge { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: var(--k, #636366); flex: none; }
/* The app's category colours */
.kind-flight { --k: #0a5cd9; } .kind-hotel { --k: #6e3bc7; } .kind-activity { --k: #b8520d; } .kind-food { --k: #b32459; }
.kind-transport { --k: #0a7a61; } .kind-cruise { --k: #0d548c; } .kind-note, .kind-other { --k: #636366; }
@media (prefers-color-scheme: dark) {
  .kind-flight { --k: #4a8af0; } .kind-hotel { --k: #8f64e0; } .kind-activity { --k: #d97a33; } .kind-food { --k: #d9507f; }
  .kind-transport { --k: #2a9e80; } .kind-cruise { --k: #3b80c0; } .kind-note, .kind-other { --k: #8e8e93; }
}
/* A flight: live card */
.day li.is-flight { grid-template-columns: 84px 1fr; }
.flight { border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; background: var(--bg); }
.flight-head { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.flight-head .badge { width: 28px; height: 28px; }
.flight-head .badge svg { width: 15px; height: 15px; }
.flight-id { font-weight: 700; color: var(--muted); font-size: .92rem; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pill { font-size: .8rem; font-weight: 800; padding: 4px 10px; border-radius: 999px; white-space: nowrap; }
.pill.good { color: #0b7a3e; background: #def6e6; } .pill.warn { color: #9a5200; background: #fff0d6; }
.pill.bad { color: #b0182d; background: #fde2e5; } .pill.muted { color: var(--muted); background: var(--surface); border: 1px solid var(--line); }
@media (prefers-color-scheme: dark) {
  .pill.good { color: #5fe08f; background: #12301f; } .pill.warn { color: #ffb44d; background: #3a2a10; } .pill.bad { color: #ff7a8a; background: #3a1419; }
}
.flight-route { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center; }
.flight-route .end { display: flex; flex-direction: column; min-width: 0; }
.flight-route .end.right { text-align: right; align-items: flex-end; }
.flight-route .code { font-size: 1.9rem; font-weight: 900; letter-spacing: -.02em; line-height: 1.05; }
.flight-route .time { font-variant-numeric: tabular-nums; display: flex; flex-direction: column; white-space: nowrap; }
.flight-route .time .changed { color: #c25e00; }
@media (prefers-color-scheme: dark) { .flight-route .time .changed { color: #ffa04d; } }
.flight-route .time s { color: var(--muted); font-size: .85rem; }
.flight-route .apt { color: var(--muted); font-size: .8rem; max-width: 12em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.track { position: relative; height: 18px; }
.track .line { position: absolute; left: 0; right: 0; top: 8px; height: 2px; background: var(--line); border-radius: 2px; }
.track .flown { height: 100%; background: var(--k, #0a5cd9); border-radius: 2px; }
.track .plane { position: absolute; top: 0; color: var(--k, #0a5cd9); }
.flight-facts { display: flex; gap: 22px; margin-top: 12px; padding-top: 10px; border-top: 1px solid var(--line); }
.flight-facts span { font-weight: 800; font-size: 1.1rem; display: flex; flex-direction: column; }
.flight-facts small { font-weight: 600; font-size: .75rem; color: var(--muted); }
.flight-note { margin: 10px 0 0; font-size: .8rem; color: var(--muted); }
@media (max-width: 520px) {
  .day li.is-flight { grid-template-columns: 1fr; }
  .day li.is-flight > time { text-align: left; padding-top: 0; }
  .flight-route .code { font-size: 1.5rem; }
}
.day .what strong { display: block; line-height: 1.35; }
.day .what small { display: block; color: var(--muted); font-size: .9rem; }
.day .free { color: var(--muted); margin: 0; }
.day ol.schedule { list-style: none; margin: 8px 0 2px; padding: 0 0 0 12px; border-left: 2px solid var(--line); display: grid; gap: 4px; }
.day ol.schedule li { display: flex; gap: 10px; padding: 0; border: 0; font-size: .92rem; }
.day ol.schedule time { flex: 0 0 auto; min-width: 4.5em; text-align: left; padding: 0; font-size: .88rem; }
.day ol.schedule small { display: block; color: var(--muted); font-size: .85rem; }   /* the place, on its own line under the name */
.day .note { margin: 8px 0 0; padding: 8px 12px; background: var(--bg); border-radius: 10px; font-size: .92rem; color: var(--text, inherit); white-space: normal; }
.trip-foot { padding: 8px 0 32px; text-align: center; }
.trip-missing { text-align: center; padding: 48px 0 72px; }
.trip-missing .missing-art { margin: 0 auto 16px; width: 200px; }
.trip-missing .muted { color: var(--muted); max-width: 30em; margin: 0 auto 1.6em; }
@media (max-width: 520px) {
  .day { padding: 16px; }
  .day li { grid-template-columns: 70px 30px 1fr; gap: 8px; }
  .day time { font-size: .85rem; }
  .day .badge { width: 30px; height: 30px; }
}
