/*
 * The trip planner's stylesheet. One file, no build step.
 *
 * TOKENS. The names are the ones a brand theme sets (markets/brands.php -> /plan/theme.css, loaded AFTER this file):
 * --bg --panel --line --ink --soft --muted --accent --accent2 --deep --display --radius. The structure matches
 * Theme::css(): dark on :root, light under prefers-color-scheme:light, and an explicit data-theme wins either way. What a
 * brand does not set falls back to the neutral values here, so an unknown site still gets a coherent planner.
 *
 * The three tokens a brand cannot know (on-accent, the day colours, the focus ring) are defined here for both modes.
 */

:root {
  color-scheme: light dark;
  --bg: #0d0b1f; --panel: #17143a; --line: #2b2660; --ink: #f4f1ff; --soft: #d6d1f2; --muted: #b0abd6;
  --accent: #ff8a73; --accent2: #f4c06a; --deep: #0a0818;
  --on-accent: #1a0d0a;
  --control: #8a86b8;
  --ok: #7fd49a; --bad: #f09a9a; --warn: #e8bd68;
  --focus: #ffd166;
  --d0: #d9603a; --d1: #2f8fc4; --d2: #8d6bdc; --d3: #3c9a68; --d4: #c4458f; --d5: #b58b1d;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: var(--font);
  --radius: 14px;
  --shadow: 0 6px 24px rgb(0 0 0 / .35);
  --top: 56px;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme=dark]) {
    --bg: #fdf8ef; --panel: #ffffff; --line: #e6dcc6; --ink: #1d1948; --soft: #3a3566; --muted: #5d5a85;
    --accent: #b8442f; --accent2: #c98a16; --deep: #2b2563;
    --on-accent: #ffffff; --control: #7a7699;
    --ok: #1f6b3a; --bad: #9b1c1c; --warn: #8a5a00; --focus: #1d4ed8;
    --d0: #b8442f; --d1: #1d6a96; --d2: #5b3fa0; --d3: #2f7d4f; --d4: #a2267a; --d5: #8a6a00;
    --shadow: 0 6px 24px rgb(40 30 10 / .16);
  }
}
:root[data-theme=light] {
  --bg: #fdf8ef; --panel: #ffffff; --line: #e6dcc6; --ink: #1d1948; --soft: #3a3566; --muted: #5d5a85;
  --accent: #b8442f; --accent2: #c98a16; --deep: #2b2563;
  --on-accent: #ffffff; --control: #7a7699;
  --ok: #1f6b3a; --bad: #9b1c1c; --warn: #8a5a00; --focus: #1d4ed8;
  --d0: #b8442f; --d1: #1d6a96; --d2: #5b3fa0; --d3: #2f7d4f; --d4: #a2267a; --d5: #8a6a00;
  --shadow: 0 6px 24px rgb(40 30 10 / .16);
}
/* A brand's light accent can be a pale tone in dark mode; its own on-accent is the dark ink above. */

* { box-sizing: border-box; }
html, body { height: 100%; }
body.pl {
  margin: 0; display: flex; flex-direction: column; height: 100dvh; overflow: hidden;
  font: 16px/1.5 var(--font); background: var(--bg); color: var(--ink);
  -webkit-text-size-adjust: 100%;
}
a { color: var(--accent); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
[hidden] { display: none !important; }
.pl-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.pl-skip { position: absolute; left: .5rem; top: -4rem; z-index: 1000; background: var(--accent); color: var(--on-accent); padding: .6rem 1rem; border-radius: 8px; }
.pl-skip:focus { top: .5rem; }
.pl-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* ---- header ---- */
.pl-top {
  height: var(--top); flex: none; display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 0 max(1rem, env(safe-area-inset-left)); background: var(--deep); color: #f4f1ff; border-bottom: 1px solid var(--line);
}
.pl-brand { display: inline-flex; align-items: center; gap: .6rem; color: inherit; text-decoration: none; min-width: 0; }
.pl-brand-name { font: 800 1.15rem/1 var(--display); letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pl-brand-name em { font-style: normal; color: var(--accent2); }
.pl-nav { display: flex; align-items: center; gap: .25rem; }
.pl-nav a { color: #f4f1ff; text-decoration: none; padding: .55rem .8rem; border-radius: 999px; font-weight: 600; font-size: .95rem; }
.pl-nav a:hover { background: rgb(255 255 255 / .12); }
.pl-nav .pl-icon-btn { color: #f4f1ff; }
.pl-nav .pl-icon-btn:hover { background: rgb(255 255 255 / .12); }
.pl-main { flex: 1; min-height: 0; outline: none; }
.pl-app, .pl-layout { height: 100%; }
.pl-loading { padding: 2rem; color: var(--muted); }
.pl-noscript { max-width: 36rem; margin: 3rem auto; padding: 0 1.25rem; }

/* ---- layout ---- */
.pl-layout { position: relative; display: block; }
.pl-panel { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; z-index: 2; pointer-events: none; }
.pl-panel > * { pointer-events: auto; }
.pl-mapwrap { position: absolute; inset: 0 0 64px 0; z-index: 1; background: var(--bg); }
.pl-map { position: absolute; inset: 0; }
.pl-pane { flex: 1; min-height: 0; overflow-y: auto; overscroll-behavior: contain; background: var(--bg); padding: 1rem max(1rem, env(safe-area-inset-left)) 1.5rem; outline: none; }
.pl-tabs {
  order: 3; flex: none; height: 64px; display: flex; background: var(--panel); border-top: 1px solid var(--line);
  padding-bottom: env(safe-area-inset-bottom); box-sizing: content-box;
}
.pl-tab {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; position: relative;
  border: 0; background: none; color: var(--muted); font: 600 .75rem/1.2 var(--font); cursor: pointer; min-height: 44px;
}
.pl-tab[aria-selected=true] { color: var(--accent); }
.pl-tab[aria-selected=true]::before { content: ""; position: absolute; top: 0; left: 28%; right: 28%; height: 3px; border-radius: 0 0 3px 3px; background: var(--accent); }
.pl-badge { position: absolute; top: 6px; margin-left: 1.6rem; background: var(--accent); color: var(--on-accent); border-radius: 999px; min-width: 1.25rem; height: 1.25rem; padding: 0 .35rem; font-size: .7rem; line-height: 1.25rem; text-align: center; }

/* mobile: one pane at a time */
.pl-layout[data-tab=plan] .pl-pane-find, .pl-layout[data-tab=find] .pl-pane-plan, .pl-layout[data-tab=map] .pl-pane { display: none; }
.pl-layout:not([data-tab=map]) .pl-mapwrap { visibility: hidden; }

@media (min-width: 900px) {
  .pl-layout { display: grid; grid-template-columns: minmax(380px, 460px) 1fr; grid-template-rows: minmax(0, 1fr); }
  .pl-panel, .pl-mapwrap { min-height: 0; height: 100%; }
  .pl-panel { position: static; pointer-events: auto; grid-column: 1; border-right: 1px solid var(--line); background: var(--bg); }
  .pl-mapwrap { position: relative; inset: auto; grid-column: 2; visibility: visible !important; }
  .pl-tabs { order: 0; height: 52px; border-top: 0; border-bottom: 1px solid var(--line); padding-bottom: 0; box-sizing: border-box; }
  .pl-tab { flex-direction: row; gap: .5rem; font-size: .9rem; }
  .pl-tab[aria-selected=true]::before { top: auto; bottom: -1px; left: 12%; right: 12%; height: 3px; border-radius: 3px 3px 0 0; }
  .pl-tab-map { display: none; }
  .pl-badge { position: static; margin: 0; }
  .pl-layout[data-tab=map] .pl-pane-plan, .pl-layout[data-tab=plan] .pl-pane-plan { display: block; }
  .pl-layout[data-tab=map] .pl-pane-find { display: none; }
  .pl-layout[data-tab=find] .pl-pane-find { display: block; }
}

/* ---- text ---- */
.pl-h1 { font: 800 1.75rem/1.15 var(--display); letter-spacing: -.02em; margin: 0 0 .5rem; }
.pl-h2 { font: 700 1.1rem/1.25 var(--display); margin: 0; }
.pl-h3 { font: 700 1rem/1.3 var(--font); margin: 1.5rem 0 .5rem; display: flex; align-items: center; gap: .4rem; }
.pl-lede { color: var(--soft); margin: 0 0 1.25rem; }
.pl-eyebrow { text-transform: uppercase; letter-spacing: .12em; font-size: .75rem; font-weight: 800; color: var(--accent); margin: 0 0 .4rem; }
.pl-muted { color: var(--muted); }
.pl-small { font-size: .85rem; }
.pl-pad { padding: .75rem; }
.pl-quote { margin: .5rem 0; padding-left: .8rem; border-left: 3px solid var(--accent2); color: var(--soft); font-style: italic; }
.pl-ico { flex: none; vertical-align: middle; }

/* ---- buttons and inputs ---- */
.pl-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .4rem; min-height: 44px; padding: .5rem 1rem;
  border-radius: 999px; border: 1.5px solid var(--control); background: var(--panel); color: var(--ink);
  font: 700 .92rem/1.2 var(--font); cursor: pointer; text-decoration: none; transition: transform .12s, background .12s;
}
.pl-btn:hover:not(:disabled) { border-color: var(--accent); }
.pl-btn:active:not(:disabled) { transform: scale(.97); }
.pl-btn:disabled { opacity: .55; cursor: default; }
.pl-btn-primary { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.pl-btn-primary:hover:not(:disabled) { filter: brightness(1.06); }
.pl-btn-ghost { background: transparent; border-color: var(--line); }
.pl-btn-small { min-height: 36px; padding: .3rem .8rem; font-size: .85rem; }
.pl-btn-wide { width: 100%; justify-content: flex-start; }
.pl-btn-on { background: var(--accent2); border-color: var(--accent2); color: #1a1405; }
.pl-btn.is-on, .pl-like.is-on { border-color: var(--accent); color: var(--accent); }
.pl-like.is-on .pl-ico { color: var(--accent); }
.pl-icon-btn { width: 44px; height: 44px; display: inline-grid; place-items: center; border: 0; background: none; color: var(--muted); border-radius: 999px; cursor: pointer; font-size: 1.2rem; }
.pl-icon-btn:hover { background: var(--line); color: var(--ink); }
.pl-link { background: none; border: 0; padding: .25rem 0; color: var(--accent); text-decoration: underline; cursor: pointer; font: inherit; font-weight: 600; }
.pl-input {
  width: 100%; min-height: 44px; padding: .5rem .8rem; border-radius: 10px; border: 1.5px solid var(--control);
  background: var(--panel); color: var(--ink); font: 1rem/1.4 var(--font);
}
textarea.pl-input { resize: vertical; min-height: 72px; }
.pl-input-lg { min-height: 52px; font-size: 1.1rem; border-radius: 14px; padding-left: 1rem; }
.pl-input-narrow { width: auto; min-width: 8rem; }
.pl-label { display: block; font-size: .85rem; font-weight: 700; color: var(--soft); margin: .75rem 0 .25rem; }
.pl-actions { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .75rem; }
.pl-chips { display: flex; flex-wrap: wrap; gap: .4rem; margin: .75rem 0; }
.pl-chip {
  display: inline-flex; align-items: center; gap: .3rem; min-height: 36px; padding: .25rem .8rem; border-radius: 999px;
  border: 1.5px solid var(--line); background: var(--panel); color: var(--ink); font: 600 .85rem/1 var(--font); cursor: pointer;
}
span.pl-chip { cursor: default; }
.pl-chip.is-on, .pl-chip-check:has(input:checked) { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.pl-chip-check input { position: absolute; opacity: 0; pointer-events: none; }
.pl-chip-check:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.pl-fieldset { border: 0; padding: 0; margin: .75rem 0 0; }
.pl-row-between { display: flex; align-items: center; justify-content: space-between; gap: .5rem; margin-top: .5rem; }

.pl-note { background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--accent2); border-radius: 10px; padding: .6rem .8rem; margin: .75rem 0; font-size: .9rem; color: var(--soft); }
.pl-note p { margin: 0 0 .4rem; }
.pl-note-bad { border-left-color: var(--bad); }

/* ---- destination hero ---- */
.pl-hero { padding: 2rem 0 1rem; text-align: left; }
.pl-hero-art { width: 76px; height: 76px; display: grid; place-items: center; border-radius: 24px; background: var(--accent); color: var(--on-accent); margin-bottom: 1rem; transform: rotate(-6deg); box-shadow: var(--shadow); }
.pl-or { margin: 1.75rem 0 .5rem; color: var(--muted); font-size: .9rem; }

/* ---- results ---- */
.pl-results { list-style: none; margin: .5rem 0 0; padding: 0; display: grid; gap: .5rem; }
.pl-result { width: 100%; display: flex; align-items: center; gap: .75rem; text-align: left; min-height: 56px; padding: .6rem .9rem; border-radius: 12px; border: 1.5px solid var(--line); background: var(--panel); color: var(--ink); cursor: pointer; font: inherit; }
.pl-result:hover { border-color: var(--accent); }
.pl-result span { display: grid; }
.pl-result small, .pl-result-body small { color: var(--muted); font-size: .8rem; }
.pl-result-card { display: flex; align-items: center; gap: .75rem; justify-content: space-between; padding: .7rem .8rem; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.pl-result-body { display: grid; min-width: 0; }
.pl-result-body strong { overflow-wrap: anywhere; }
.pl-addto { display: flex; align-items: center; gap: .5rem; margin: .5rem 0; }
.pl-nearinfo { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.pl-empty-line { color: var(--muted); padding: .75rem .25rem; margin: 0; }
.pl-skel-card, .pl-skel span { display: block; border-radius: 10px; background: linear-gradient(90deg, var(--panel), var(--line), var(--panel)); background-size: 200% 100%; animation: pl-shimmer 1.4s linear infinite; }
.pl-skel-card { height: 64px; display: grid; gap: 8px; padding: 12px; }
.pl-skel-card span { height: 10px; width: 60%; } .pl-skel-card span + span { width: 35%; }
.pl-skel { display: grid; gap: .5rem; } .pl-skel span { height: 44px; }
@keyframes pl-shimmer { to { background-position: -200% 0; } }

/* ---- the plan ---- */
.pl-head { margin-bottom: 1rem; }
.pl-head-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.pl-title { flex: 1; min-width: 12rem; font: 800 1.45rem/1.2 var(--display); letter-spacing: -.01em; color: var(--ink); background: transparent; border: 0; border-bottom: 2px dashed transparent; padding: .25rem 0; }
.pl-title:hover, .pl-title:focus { border-bottom-color: var(--control); outline: none; }
.pl-title:focus-visible { outline: none; border-bottom-style: solid; border-bottom-color: var(--accent); }
.pl-title::placeholder { color: var(--soft); opacity: 1; }
.pl-sharerow { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .75rem; align-items: center; }
.pl-sharerow .pl-input { flex: 1; min-width: 10rem; }
.pl-modewrap { margin: 1rem 0; }
.pl-modes { display: grid; grid-template-columns: repeat(4, 1fr); gap: .35rem; padding: .3rem; background: var(--panel); border: 1px solid var(--line); border-radius: 16px; }
.pl-mode { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px; border: 0; border-radius: 12px; background: transparent; color: var(--muted); font: 700 .78rem/1.1 var(--font); cursor: pointer; }
.pl-mode.is-on { background: var(--accent); color: var(--on-accent); box-shadow: 0 2px 8px rgb(0 0 0 / .25); }
.pl-mode:hover:not(.is-on) { background: var(--line); color: var(--ink); }
.pl-empty { text-align: center; padding: 1.75rem 1rem; border: 2px dashed var(--line); border-radius: var(--radius); margin: 1rem 0; }
.pl-empty-art { width: 64px; height: 64px; margin: 0 auto .75rem; display: grid; place-items: center; border-radius: 50%; background: var(--accent); color: var(--on-accent); }
.pl-empty p { color: var(--soft); max-width: 28rem; margin: .5rem auto; }
.pl-empty .pl-actions { justify-content: center; }

.pl-days { display: grid; gap: 1rem; }
.pl-day { background: var(--panel); border: 1.5px solid var(--line); border-radius: var(--radius); padding: .75rem .75rem .5rem; position: relative; }
.pl-day.is-active { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent) inset; }
.pl-day-head { display: flex; align-items: center; gap: .65rem; margin-bottom: .5rem; }
.pl-day-title { flex: 1; min-width: 0; }
.pl-totals { margin: 0; font-size: .85rem; color: var(--muted); }
.pl-day-tools { display: flex; align-items: center; gap: .25rem; }
.pl-daydot, .pl-num { flex: none; display: inline-grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; color: #fff; font: 800 .95rem/1 var(--font); }
.pl-num { width: 30px; height: 30px; font-size: .85rem; }
.pl-day-0 .pl-daydot, .pl-num.pl-day-0, .pl-pin.pl-day-0 { background: var(--d0); }
.pl-day-1 .pl-daydot, .pl-num.pl-day-1, .pl-pin.pl-day-1 { background: var(--d1); }
.pl-day-2 .pl-daydot, .pl-num.pl-day-2, .pl-pin.pl-day-2 { background: var(--d2); }
.pl-day-3 .pl-daydot, .pl-num.pl-day-3, .pl-pin.pl-day-3 { background: var(--d3); }
.pl-day-4 .pl-daydot, .pl-num.pl-day-4, .pl-pin.pl-day-4 { background: var(--d4); }
.pl-day-5 .pl-daydot, .pl-num.pl-day-5, .pl-pin.pl-day-5 { background: var(--d5); }
.pl-est { display: inline-block; margin-left: .35rem; padding: 0 .4rem; border-radius: 6px; background: var(--line); color: var(--soft); font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.pl-stops { list-style: none; margin: 0; padding: 0; min-height: 8px; }
.pl-stop { position: relative; border-radius: 12px; }
.pl-stop-row { display: flex; align-items: center; gap: .4rem; padding: .25rem 0; }
.pl-handle { flex: none; width: 36px; height: 44px; display: grid; place-items: center; border: 0; background: none; color: var(--muted); cursor: grab; border-radius: 8px; touch-action: none; }
.pl-handle:hover { background: var(--line); color: var(--ink); }
.pl-handle:active { cursor: grabbing; }
.pl-stop-main { flex: 1; min-width: 0; }
.pl-stop-name { width: 100%; display: grid; text-align: left; gap: 1px; min-height: 44px; align-content: center; padding: .15rem .4rem; border: 0; background: none; color: var(--ink); font: inherit; cursor: pointer; border-radius: 8px; }
.pl-stop-name:hover { background: var(--line); }
.pl-stop-name strong { overflow-wrap: anywhere; }
.pl-stop-name small { color: var(--muted); font-size: .8rem; text-transform: capitalize; }
.pl-stop.is-dragging { opacity: .4; }
.pl-stop.is-open { background: color-mix(in srgb, var(--line) 45%, transparent); }
.pl-dropline { list-style: none; height: 4px; margin: 2px 0; border-radius: 2px; background: var(--accent); }
body.is-sorting { cursor: grabbing; user-select: none; }
.pl-details { padding: .25rem .5rem .75rem 3.1rem; }
.pl-details-row { display: flex; flex-wrap: wrap; gap: .75rem; align-items: flex-end; margin-top: .5rem; }
.pl-leg { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; margin: 0 0 .15rem 3.1rem; padding: .2rem .6rem; font-size: .82rem; color: var(--muted); border-left: 3px dotted var(--control); }
.pl-leg.is-missing { font-style: italic; }
.pl-adddayrow { margin: 1rem 0; }
.pl-foot { margin-top: 1.5rem; padding-top: .75rem; border-top: 1px solid var(--line); }
.pl-foot p { margin: 0 0 .4rem; }

/* ---- social ---- */
.pl-publicbar { margin: 1.25rem 0 .5rem; }
.pl-social { margin-top: 1rem; padding-top: .75rem; border-top: 1px solid var(--line); }
.pl-social-row { display: flex; flex-wrap: wrap; gap: .5rem; }
.pl-count { font-variant-numeric: tabular-nums; }
.pl-comments { list-style: none; margin: 0; padding: 0; display: grid; gap: .75rem; }
.pl-comment { padding: .7rem .8rem; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.pl-comment p { margin: .25rem 0; overflow-wrap: anywhere; }
.pl-comment-head { font-size: .9rem; }
.pl-comment-actions { font-size: .8rem; }
.pl-comment-form { margin-top: 1rem; }
.pl-collections { margin-top: .75rem; padding: .75rem; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.pl-collections-title { margin: 0 0 .5rem; font-weight: 700; }
.pl-plain-list { list-style: none; margin: 0 0 .5rem; padding: 0; display: grid; gap: .35rem; }
.pl-inline-form { display: flex; gap: .5rem; }

/* ---- map ---- */
.leaflet-container { font: inherit; background: var(--bg); }
html[data-scheme=dark] .leaflet-tile-pane { filter: invert(1) hue-rotate(180deg) brightness(.92) contrast(.88) saturate(.8); }
.leaflet-control-attribution { font-size: .7rem; }
.leaflet-bar a, .leaflet-bar a:hover { width: 40px; height: 40px; line-height: 40px; background: var(--panel); color: var(--ink); border-bottom-color: var(--line); }
.leaflet-bar a:hover { background: var(--line); }
.leaflet-bar { border: 1px solid var(--line); box-shadow: var(--shadow); }
.leaflet-control-attribution { background: color-mix(in srgb, var(--panel) 85%, transparent) !important; color: var(--soft); }
.leaflet-control-attribution a { color: var(--accent); }
.pl-pin-wrap { background: none; border: 0; }
.pl-pin { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 2px 8px rgb(0 0 0 / .5); color: #fff; font: 800 .9rem/1 var(--font); }
.pl-pin.is-focus { outline: 3px solid var(--focus); }
.pl-dot { display: block; width: 16px; height: 16px; border-radius: 50%; background: var(--panel); border: 3px solid var(--accent); box-shadow: 0 1px 4px rgb(0 0 0 / .5); }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { background: var(--panel); color: var(--ink); }
.pl-popup { display: grid; gap: .4rem; min-width: 9rem; }
.pl-popup-meta { color: var(--muted); font-size: .8rem; text-transform: capitalize; }
.pl-maphint { position: absolute; left: .75rem; right: .75rem; top: .75rem; z-index: 500; }

/* ---- dialog and toasts ---- */
.pl-dialog { border: 0; padding: 0; border-radius: 18px; background: var(--panel); color: var(--ink); width: min(30rem, calc(100vw - 1.5rem)); max-height: calc(100dvh - 2rem); box-shadow: var(--shadow); }
.pl-dialog::backdrop { background: rgb(8 6 20 / .65); }
.pl-dialog-in { padding: 1rem 1.25rem 1.25rem; }
.pl-dialog-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: .5rem; }
.pl-toasts { position: fixed; z-index: 3000; left: 50%; transform: translateX(-50%); bottom: calc(80px + env(safe-area-inset-bottom)); display: grid; gap: .5rem; width: min(26rem, calc(100vw - 1.5rem)); pointer-events: none; }
@media (min-width: 900px) { .pl-toasts { bottom: 1.5rem; left: calc(230px + 50%); transform: translateX(-50%); } }
.pl-toast { pointer-events: auto; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: .75rem 1rem; border-radius: 12px; background: var(--deep); color: #f4f1ff; border-left: 5px solid var(--accent2); box-shadow: var(--shadow); font-size: .92rem; animation: pl-pop .2s ease-out; }
.pl-toast .pl-link { color: var(--accent2); }
.pl-toast-ok { border-left-color: #7fd49a; } .pl-toast-bad { border-left-color: #f09a9a; }
@keyframes pl-pop { from { opacity: 0; transform: translateY(8px); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .pl-skel-card, .pl-skel span { animation: none; }
}
@media (forced-colors: active) {
  .pl-mode.is-on, .pl-btn-primary { outline: 2px solid CanvasText; }
}

/* Trips from travellers, on the opening screen. */
.pl-shared:empty { display: none; }
.pl-shared { margin: 1.5rem 0; text-align: left; width: 100%; }
.pl-shared-h { font: 800 1.05rem/1.2 var(--display); margin: 0 0 .6rem; }
.pl-shared-list { list-style: none; margin: 0; padding: 0; display: grid; gap: .5rem; }
.pl-shared-card { display: grid; gap: .15rem; padding: .7rem .9rem; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: inherit; }
.pl-shared-card:hover, .pl-shared-card:focus-visible { border-color: var(--accent); }
.pl-shared-card small { opacity: .75; }
.pl-signin { display: grid; gap: .4rem; }
.pl-signin p { margin: 0; }
.pl-signin .pl-actions { flex-wrap: wrap; }
.pl-look { display: grid; gap: .35rem; padding: .75rem 0; }
.pl-popup { display: grid; gap: .4rem; }

/* Phones: one line of header. Shorter link words, so the brand name is not cut and nothing wraps. */
.pl-nav a { white-space: nowrap; }
@media (max-width: 560px) {
  .pl-long { display: none; }
  .pl-nav { gap: 0; }
  .pl-nav a { padding: .5rem .45rem; font-size: .85rem; }
  .pl-brand { gap: .4rem; }
  .pl-brand-name { font-size: .98rem; }
}

@media (max-width: 430px) {
  /* The phone's own light or dark setting already applies; the room goes to the name. */
  .pl-nav .pl-icon-btn { display: none; }
}

.pl-install:empty { display: none; }
.pl-install { margin: 1.25rem 0; padding: .9rem 1rem; border: 1px solid var(--line); border-radius: 14px; display: grid; gap: .6rem; justify-items: start; text-align: left; }
.pl-install p { margin: 0; }
.pl-nav a[hidden] { display: none; }

/* Today: big targets, one thing next. */
.pl-today { display: grid; gap: .6rem; justify-items: start; }
.pl-today > * { margin: 0; }
.pl-today-list { list-style: none; margin: .4rem 0 0; padding: 0; display: grid; gap: .6rem; justify-self: stretch; }
.pl-today-stop { border: 1px solid var(--line); border-radius: 14px; padding: .8rem 1rem; display: grid; gap: .4rem; justify-items: start; }
.pl-today-stop > * { margin: 0; }
.pl-today-stop.is-next { border-color: var(--accent); border-width: 2px; }
.pl-today-stop.is-done { opacity: .55; }
.pl-today-stop.is-done strong { text-decoration: line-through; }
.pl-today-row { display: flex; gap: .75rem; align-items: center; }
.pl-today-row input { width: 1.5rem; height: 1.5rem; accent-color: var(--accent); }
.pl-today-row label { min-height: 44px; display: flex; align-items: center; cursor: pointer; }
.pl-daterow { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .75rem; margin: .75rem 0 0; }
.pl-daterow label { font-weight: 700; }
.pl-daterow input { min-height: 44px; width: auto; }
