/* ==========================================================================
   Mouse Ears & Strollers — mobile app shell
   A premium, iOS-inspired presentation layer over the Data Fusion planner.
   Mobile-first; on desktop the app sits centred as a phone-width column.
   ========================================================================== */

:root {
  --pink: #d4537e; --pinkd: #993556; --pink50: #fbeaf0; --pink100: #f4c0d1;
  --blue: #378add; --blue50: #e6f1fb; --blue800: #0c447c;
  --grn: #4e8a1f; --grn50: #eaf3de; --grn800: #27500a;
  --amb: #ba7517; --amb50: #faeeda;
  --ink: #1f2c3a; --ink2: #5a616b; --ink3: #8b929b;
  --line: #ececf2; --bg: #f4f5f8; --card: #fff;
  --radius: 14px;
  --tab-h: 62px;
  --wrap: 480px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--ink);
  background: #e9ebf1;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
/* The [hidden] attribute must always win — class rules like `.btn{display:flex}`
   or `.field{display:flex}` otherwise override the browser default and leave
   "hidden" elements visible (e.g. the wizard's Build button on every step). */
[hidden] { display: none !important; }

/* ---- app shell ---- */
.app {
  max-width: var(--wrap);
  margin: 0 auto;
  min-height: 100vh;
  min-height: 100dvh;
  background: var(--bg);
  position: relative;
  display: flex;
  flex-direction: column;
  box-shadow: 0 0 60px rgba(20, 28, 45, 0.1);
}
.views { flex: 1; padding-bottom: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px)); }
.view { display: none; }
.app[data-view="build"] #view-build,
.app[data-view="day"] #view-day,
.app[data-view="map"] #view-map,
.app[data-view="optimise"] #view-optimise,
.app[data-view="board"] #view-board,
.app[data-view="tracker"] #view-tracker,
.app[data-view="plans"] #view-plans { display: block; }

/* ---- brand header (build view) ---- */
.appbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: calc(12px + env(safe-area-inset-top, 0px)) 18px 12px;
  background: var(--card);
  position: sticky; top: 0; z-index: 20;
  border-bottom: 1px solid var(--line);
}
.brand { display: flex; align-items: center; gap: 9px; font-size: 16px; font-weight: 600; }
.appbar-help { margin-left: auto; margin-right: 12px; display: inline-flex; align-items: center; gap: 5px;
  font-size: 12.5px; font-weight: 600; color: var(--pinkd); text-decoration: none;
  background: var(--pink50); padding: 6px 11px; border-radius: 999px; }
.appbar-help i { font-size: 15px; }
.appbar-help:hover { background: var(--pink100); }
.brand b { color: var(--pink); font-weight: 600; }
.logo { width: 30px; height: 30px; border-radius: 9px; background: var(--pink50); color: var(--pink);
  display: flex; align-items: center; justify-content: center; font-size: 19px; }
.logo img { width: 22px; height: 22px; display: block; }
.gdot { width: 10px; height: 10px; border-radius: 50%; background: var(--grn); box-shadow: 0 0 0 3px var(--grn50); }
.gdot.stale { background: var(--amb); box-shadow: 0 0 0 3px var(--amb50); }
.gdot.off { background: #c9ccd3; box-shadow: 0 0 0 3px #eceef2; }
.gdot.checking { background: var(--pink); box-shadow: 0 0 0 3px var(--pink50); animation: rt-pulse 1.1s ease-in-out infinite; }

.labban { background: var(--pink50); color: var(--pinkd); font-size: 12.5px; padding: 8px 18px; }
.labban b { font-weight: 600; }

/* ---- hero (your header artwork behind the intro copy) ---- */
.hero { margin: 14px; border-radius: 18px; overflow: hidden; position: relative;
  min-height: 280px; display: flex; align-items: flex-end; }
.hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  object-position: center 30%; z-index: 0; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(180deg, rgba(244,246,250,0) 34%, rgba(244,246,250,0.84) 70%, rgba(244,246,250,0.98) 100%); }
.hero-ov { position: relative; z-index: 2; padding: 14px 16px 16px; width: 100%; }
.chip { display: inline-block; background: #fff; color: var(--blue800); font-size: 11.5px; font-weight: 600;
  padding: 4px 11px; border-radius: 999px; letter-spacing: 0.02em; }
.h1 { font-size: 21px; font-weight: 600; line-height: 1.25; margin: 10px 0 6px; letter-spacing: -0.01em; }
.h1 em { color: var(--pink); font-style: normal; }
.hsub { font-size: 13.5px; color: var(--ink2); margin: 0 0 14px; line-height: 1.5; }

/* ---- buttons ---- */
.btn { width: 100%; border: none; border-radius: 14px; padding: 14px; font-size: 15px; font-weight: 600;
  display: flex; align-items: center; justify-content: center; gap: 7px; cursor: pointer;
  font-family: inherit; transition: transform 0.08s, box-shadow 0.15s; }
.btn:active { transform: scale(0.985); }
.btn.pink { background: linear-gradient(180deg, #e0668f, #cf4174); color: #fff;
  box-shadow: 0 8px 18px rgba(207, 65, 116, 0.28); }
.btn.ghost { background: var(--card); color: var(--ink2); border: 1px solid var(--line); box-shadow: none; }
.btn.sm { padding: 11px; font-size: 13.5px; border-radius: 12px; }
.btn[disabled] { opacity: 0.5; pointer-events: none; }
.btn-row { display: flex; gap: 10px; }
.btn-row .btn { flex: 1; }

/* ---- step indicator ---- */
.steps { display: flex; justify-content: space-between; padding: 8px 18px 4px; }
.step { display: flex; flex-direction: column; align-items: center; gap: 5px; font-size: 11.5px;
  color: var(--ink3); flex: 1; }
.step span { width: 28px; height: 28px; border-radius: 50%; background: #e7e8ee; color: var(--ink3);
  display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 13px; }
.step.on { color: var(--pink); font-weight: 600; }
.step.on span { background: var(--pink); color: #fff; }
.step.done span { background: var(--grn50); color: var(--grn800); }

/* ---- cards & form ---- */
.card { background: var(--card); border-radius: 18px; margin: 14px; padding: 16px 16px 18px;
  box-shadow: 0 2px 14px rgba(30, 40, 60, 0.05); }
.card.flush { margin: 14px; }
.ctitle { font-size: 17px; font-weight: 600; }
.ctitle.sm { font-size: 15px; }
.cstep { font-size: 12px; color: var(--ink3); margin-top: 2px; }
.pbar { height: 6px; border-radius: 999px; background: #eceef3; margin: 11px 0 16px; overflow: hidden; }
.pbar i { display: block; height: 100%; background: var(--pink); border-radius: 999px; transition: width 0.25s; }

.wizard-step { display: none; }
.wizard-step.on { display: block; }

.fl { font-size: 12px; color: var(--ink3); font-weight: 600; display: block; margin: 12px 0 5px; }
.fl:first-child { margin-top: 0; }
.field { display: flex; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 12px;
  padding: 12px; font-size: 14px; background: #fcfcfe; }
/* `.field` beats the UA [hidden] rule, so hidden fields (e.g. the custom
   end-time picker under "Park close") would stay visible without this. */
.field[hidden] { display: none; }
.field .c { margin-left: auto; color: var(--ink3); }
.field > i:first-child { color: var(--pink); font-size: 17px; }
.field input, .field select { border: none; background: transparent; font-size: 14px; font-family: inherit;
  color: var(--ink); width: 100%; outline: none; padding: 0; }
.field select { appearance: none; -webkit-appearance: none; }

/* ---- custom dropdown (replaces native <select> so the option list matches) ---- */
.dd-native { display: none !important; }
.dd-anchor { position: relative; }
.dd-clickable { cursor: pointer; } /* whole field is the click target, not just the label */
.dd-host { flex: 1; min-width: 0; display: flex; }
.dd-value { display: flex; align-items: center; gap: 8px; width: 100%; background: none; border: none;
  font-family: inherit; font-size: 14px; color: var(--ink); cursor: pointer; padding: 0; text-align: left; }
.dd-value .dd-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field .dd-value .dd-chev { display: none; } /* the .field already carries its own chevron */
.dd-menu { position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 60;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 6px;
  box-shadow: 0 14px 34px rgba(20, 28, 45, 0.18); max-height: 264px; overflow-y: auto; }
.dd-opt { padding: 10px 12px; border-radius: 9px; font-size: 14px; color: var(--ink); cursor: pointer; white-space: nowrap; }
.dd-opt:hover { background: var(--pink50); color: var(--pinkd); }
.dd-opt.on { font-weight: 600; color: var(--pinkd); background: var(--pink50); }
.field.dd-anchor.open .c { transform: rotate(180deg); }
.dd-value[aria-expanded="true"] .dd-chev { transform: rotate(180deg); }
/* compact pill form inside a checkrow (meal times, snack count) */
.checkrow .dd-host { flex: 0 0 auto; }
.checkrow .dd-value { border: 1px solid var(--line); border-radius: 9px; padding: 6px 10px; font-size: 13px;
  background: #fff; gap: 6px; min-width: 96px; }
.checkrow .dd-value .dd-chev { font-size: 15px; color: var(--ink3); transition: transform 0.15s; }
.checkrow .dd-menu { left: auto; right: 0; min-width: 130px; }

/* ---- custom calendar (replaces the native date picker popup) ---- */
.dd-cal { padding: 10px; max-height: 360px; } /* fits a 6-week month without scrolling */
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.cal-title { font-weight: 600; font-size: 14px; color: var(--ink); }
.cal-nav { background: none; border: none; cursor: pointer; color: var(--ink2); padding: 6px; border-radius: 8px; line-height: 0; }
.cal-nav:hover { background: var(--pink50); color: var(--pinkd); }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.cal-dow { margin-bottom: 2px; }
.cal-cell { display: flex; align-items: center; justify-content: center; height: 34px; border: none; background: none;
  font-family: inherit; font-size: 13px; color: var(--ink); border-radius: 8px; cursor: pointer; }
.cal-cell.dow { color: var(--ink3); font-size: 11px; font-weight: 600; height: 22px; cursor: default; }
.cal-cell.cal-empty { visibility: hidden; }
.cal-cell:not(.dow):not(.cal-empty):not(:disabled):hover { background: var(--pink50); color: var(--pinkd); }
.cal-cell.sel { background: var(--pink); color: #fff; font-weight: 600; }
.cal-cell:disabled { color: #cfd3db; cursor: not-allowed; }

/* ---- number stepper (replaces the native <input type=number> spinner) ---- */
.num-native { text-align: center; width: 2.2ch !important; flex: 0 0 auto !important; -moz-appearance: textfield; }
.num-native::-webkit-outer-spin-button, .num-native::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.stepbtn { width: 26px; height: 26px; flex: 0 0 auto; border-radius: 8px; border: 1px solid var(--line); background: #fff;
  color: var(--pink); font-size: 17px; line-height: 1; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.stepbtn:hover { background: var(--pink50); }
.stepbtn:active { transform: scale(0.92); }
/* Guests: a label-grows row (icon · label · − value +) that stacks on narrow
   phones and sits two-up when there's room — so the steppers never overflow. */
.guests { display: flex; gap: 10px; flex-wrap: wrap; }
.guests .field { flex: 1 1 100%; }
.guest-lbl { flex: 1; min-width: 0; color: var(--ink2); font-size: 14px; }
@media (min-width: 520px) { .guests .field { flex: 1 1 0; } }

/* Must-do rides typeahead: chips + a search input inside one .field */
.mustdo { flex-wrap: wrap; align-items: center; row-gap: 7px; }
.mustdo .chips { display: contents; }
.chip { display: inline-flex; align-items: center; gap: 4px; background: var(--pink50); color: var(--pinkd);
  border-radius: 999px; padding: 4px 5px 4px 11px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.chip-x { background: none; border: none; color: var(--pinkd); cursor: pointer; font-size: 16px; line-height: 0;
  width: 18px; height: 18px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; }
.chip-x:hover { background: rgba(207, 65, 116, 0.16); }
.mustdo input { flex: 1; min-width: 90px; }
.hint { font-size: 11.5px; color: var(--ink3); margin: 10px 0 0; }

.seg { display: flex; flex-wrap: wrap; gap: 8px; }
.seg button { border: 1px solid var(--line); background: #fcfcfe; color: var(--ink2); border-radius: 999px;
  padding: 9px 14px; font-size: 13px; font-weight: 500; font-family: inherit; cursor: pointer; }
.seg button.on { background: var(--pink); color: #fff; border-color: var(--pink); }
.checkrow { display: flex; align-items: center; gap: 10px; padding: 11px 0; border-top: 1px solid var(--line); font-size: 14px; }
.checkrow:first-of-type { border-top: none; }
.checkrow input[type="checkbox"] { width: 20px; height: 20px; accent-color: var(--pink); }
.checkrow .grow { flex: 1; }
.checkrow input[type="time"], .checkrow select.timesel { border: 1px solid var(--line); border-radius: 9px; padding: 6px 8px; font-family: inherit; font-size: 13px; background: #fff; color: var(--ink); }

.rev { display: flex; justify-content: space-between; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; }
.rev:first-child { border-top: none; }
.rev .k { color: var(--ink2); }
.rev .v { font-weight: 600; text-align: right; }

/* ---- data freshness ---- */
.frow { display: flex; align-items: center; justify-content: space-between; padding: 10px 0;
  border-top: 1px solid var(--line); font-size: 13.5px; color: var(--ink2); }
.frow:first-of-type { border-top: none; }
.fresh { font-size: 11px; font-weight: 600; padding: 4px 10px; border-radius: 999px; }
.fresh.ok { color: var(--grn800); background: var(--grn50); }
.fresh.stale { color: var(--amb); background: var(--amb50); }
.fresh.off { color: var(--pinkd); background: var(--pink50); }
.fresh.checking { color: var(--pinkd); background: var(--pink50); }

/* ---- day: top bar + stats + tabs ---- */
.daybar { padding: calc(12px + env(safe-area-inset-top, 0px)) 18px 6px; background: var(--card);
  position: sticky; top: 0; z-index: 20; }
.daybar-top { display: flex; align-items: center; justify-content: space-between; color: var(--ink2); font-size: 20px; }
.daybar-title { font-size: 17px; font-weight: 600; color: var(--ink); }
.daymeta { display: flex; gap: 16px; padding: 8px 0 2px; font-size: 12.5px; color: var(--ink2); }
.daymeta i { color: var(--pink); font-size: 14px; vertical-align: -2px; margin-right: 3px; }
.stats { display: flex; gap: 9px; padding: 10px 14px 6px; background: var(--card); }
.st { flex: 1; background: #f7f8fb; border-radius: 14px; padding: 11px 6px; text-align: center; }
.st b { display: block; font-size: 17px; font-weight: 600; }
.st b.g { color: var(--grn); } .st b.b { color: var(--blue); } .st b.a { color: var(--amb); }
.st span { font-size: 11px; color: var(--ink3); }
.tabs { display: flex; gap: 8px; padding: 12px 14px 6px; background: var(--card); position: sticky;
  top: 0; z-index: 15; border-bottom: 1px solid var(--line); }
.tabs button { font-size: 13.5px; color: var(--ink3); padding: 8px 16px; border-radius: 999px; background: #f2f3f7;
  font-weight: 500; border: none; font-family: inherit; cursor: pointer; }
.tabs button.on { background: var(--pink); color: #fff; }

.lbl { font-size: 11px; font-weight: 600; letter-spacing: 0.06em; color: var(--ink3); padding: 14px 16px 6px; }

/* ---- timeline ---- */
.tl { padding: 0 14px 8px; }
.itrow { margin-bottom: 10px; }
.it-time { display: flex; align-items: center; gap: 4px; font-size: 11.5px; color: var(--ink3); font-weight: 600; margin-bottom: 3px; }
.it-time i { font-size: 13px; }
.it { background: var(--card); border-radius: 15px; padding: 11px 12px; display: flex; gap: 11px;
  align-items: flex-start; box-shadow: 0 2px 10px rgba(30, 40, 60, 0.05); border: 1.5px solid transparent;
  cursor: pointer; transition: transform 0.08s; }
.it:active { transform: scale(0.99); }
.it.next { border-color: var(--blue); background: var(--blue50); }
.it.meal { background: var(--pink50); cursor: default; }
.it.brk { background: #f6f7fa; cursor: default; box-shadow: none; }
.it.meal[data-idx], .it.brk[data-idx] { cursor: pointer; }
.thumb { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 12px; display: flex; align-items: center;
  justify-content: center; font-size: 20px; }
.t-pink { background: var(--pink100); color: var(--pinkd); }
.t-blue { background: #c9e0f7; color: var(--blue800); }
.t-grn { background: #cfe6ad; color: var(--grn800); }
.t-amb { background: #f6dca6; color: var(--amb); }
.t-gray { background: #e4e6ec; color: var(--ink2); }
.itbody { flex: 1; min-width: 0; }
.itname { font-size: 14px; font-weight: 600; line-height: 1.25; }
.itsub { font-size: 12px; color: var(--ink2); margin: 2px 0 5px; }
.bdg { display: inline-block; font-size: 11px; font-weight: 600; padding: 3px 9px; border-radius: 999px; }
.bdg.g { background: var(--grn50); color: var(--grn800); }
.bdg.b { background: #dcebfb; color: var(--blue800); }
.bdg.p { background: #f4c9d8; color: var(--pinkd); }
.itmeta { font-size: 11.5px; color: var(--ink3); margin-top: 6px; }
.itmeta i { font-size: 13px; vertical-align: -2px; margin-right: 3px; }
.itend { display: flex; flex-direction: column; align-items: center; gap: 6px; padding-top: 2px; }
.donebtn { background: none; border: none; padding: 9px; margin: -6px -6px 0 0; cursor: pointer; color: inherit; line-height: 0; border-radius: 50%; }
.donebtn:active { transform: scale(0.88); }
.infobtn { background: none; border: none; padding: 7px; margin: 0 -6px; cursor: pointer; color: var(--ink3); line-height: 0; border-radius: 50%; }
.infobtn i { font-size: 20px; }
.infobtn:active { transform: scale(0.88); }
.chk { color: var(--grn); font-size: 26px; }
.chk.todo { color: #cfd3db; }
.star { color: var(--amb); font-size: 17px; }
.it.done { opacity: 0.58; }
.it.done .itname { text-decoration: line-through; text-decoration-color: rgba(31, 44, 58, 0.3); }
.it.done .bdg { display: none; }
.donebar { padding: 8px 14px 2px; }
.donetoggle { background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 8px 15px;
  font-size: 13px; font-weight: 600; color: var(--ink2); font-family: inherit; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; box-shadow: 0 2px 8px rgba(30, 40, 60, 0.05); }
.donetoggle i { font-size: 16px; }

.viewall { margin: 2px 14px 14px; background: var(--card); border-radius: 14px; padding: 13px; text-align: center;
  font-size: 13.5px; font-weight: 600; color: var(--ink2); box-shadow: 0 2px 10px rgba(30, 40, 60, 0.05); cursor: pointer; }

/* ---- notices ---- */
.notice { margin: 14px; border-radius: 14px; padding: 14px 16px; font-size: 13px; }
.notice.warn { background: var(--amb50); color: #7a4e08; }
.notice.err { background: var(--pink50); color: var(--pinkd); }
.notice h4 { margin: 0 0 6px; font-size: 14px; }
.notice ul { margin: 6px 0 0; padding-left: 18px; }

/* ---- floating action button ---- */
.fab { position: fixed; right: 18px; bottom: calc(var(--tab-h) + 16px + env(safe-area-inset-bottom, 0px));
  width: 56px; height: 56px; border-radius: 50%; background: linear-gradient(180deg, #e0668f, #cf4174);
  color: #fff; display: flex; align-items: center; justify-content: center; font-size: 26px; border: none;
  box-shadow: 0 10px 22px rgba(207, 65, 116, 0.42); cursor: pointer; z-index: 30; }
/* The Adapt FAB belongs to the Day view; the plans FAB to the My Plans view.
   Each FAB lives inside its own view section, so only its view shows it. */
.app:not([data-view="day"]) .fab-adapt { display: none; }
.app:not([data-view="plans"]) .fab-plan { display: none; }

/* ---- bottom tab bar ---- */
.tabbar { position: sticky; bottom: 0; z-index: 40; display: flex; justify-content: space-around; align-items: center;
  padding: 8px 8px calc(8px + env(safe-area-inset-bottom, 0px)); background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(1.6) blur(12px); -webkit-backdrop-filter: saturate(1.6) blur(12px);
  border-top: 1px solid var(--line); height: calc(var(--tab-h) + env(safe-area-inset-bottom, 0px)); }
.ni { display: flex; flex-direction: column; align-items: center; gap: 3px; font-size: 10.5px; color: var(--ink3);
  background: none; border: none; font-family: inherit; cursor: pointer; padding: 4px 8px; white-space: nowrap; }
.ni i { font-size: 22px; }
.ni.on { color: var(--pink); }
.ni[disabled] { opacity: 0.4; pointer-events: none; }

/* ---- bottom sheet ---- */
.scrim { position: fixed; inset: 0; background: rgba(18, 24, 38, 0.42); opacity: 0; pointer-events: none;
  transition: opacity 0.25s; z-index: 50; }
.scrim.on { opacity: 1; pointer-events: auto; }
.sheet { position: fixed; left: 50%; transform: translateX(-50%) translateY(100%);
  width: 100%; max-width: var(--wrap); bottom: 0; background: var(--card); border-radius: 24px 24px 0 0;
  padding: 10px 18px calc(20px + env(safe-area-inset-bottom, 0px)); z-index: 60;
  box-shadow: 0 -12px 34px rgba(18, 24, 38, 0.18);
  transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
  max-height: 88vh; overflow-y: auto;
  /* A closed sheet must be FULLY inert — hidden AND non-interactive — so it can
     never sit behind another view (e.g. the create-plan form behind the wizard)
     and steal clicks, regardless of any transform quirk. Hidden instantly on close. */
  visibility: hidden; pointer-events: none; }
.sheet.on { transform: translateX(-50%) translateY(0); visibility: visible; pointer-events: auto; }
.grab { width: 40px; height: 5px; border-radius: 999px; background: #d9dbe2; margin: 2px auto 12px; }
.shhd { display: flex; justify-content: space-between; font-size: 12px; color: var(--ink3); }
.shname { font-size: 20px; font-weight: 600; margin: 6px 0 8px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.shrow { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }
.sect { font-size: 12px; font-weight: 600; color: var(--ink3); letter-spacing: 0.03em; margin: 16px 0 4px; }
.whyt { font-size: 16px; font-weight: 600; margin: 16px 0 4px; }
.whyp { font-size: 13px; color: var(--ink2); margin: 0; line-height: 1.55; }
.chart svg { display: block; width: 100%; height: 120px; }
.xax { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--ink3); margin-top: 3px; }
.pk { text-align: center; font-size: 12px; color: var(--ink2); margin: 8px 0 12px; }
.drow { display: flex; align-items: center; justify-content: space-between; padding: 11px 0; border-top: 1px solid var(--line); font-size: 14px; }
.drow .k { color: var(--ink2); display: flex; align-items: center; gap: 9px; }
.drow .k i { color: var(--pink); font-size: 18px; }
.drow .v { font-weight: 600; }
.llchip { display: inline-flex; align-items: center; gap: 6px; background: var(--blue50); color: var(--blue800);
  font-size: 12px; font-weight: 600; padding: 7px 12px; border-radius: 999px; margin: 12px 0; }

/* ---- generic route / optimise ---- */
.rlist { list-style: none; margin: 0; padding: 0 14px; }
.rlist li { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.rpin { width: 30px; height: 30px; flex: 0 0 30px; border-radius: 50%; background: var(--pink); color: #fff;
  display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 600; }
.rpin.alt { background: var(--blue50); color: var(--blue800); }
.rname { font-size: 14px; font-weight: 500; }
.rsub { font-size: 12px; color: var(--ink3); }
.conf { display: inline-block; font-size: 12px; font-weight: 600; padding: 5px 12px; border-radius: 999px; }
.conf.high { background: var(--grn50); color: var(--grn800); }
.conf.medium { background: var(--amb50); color: var(--amb); }
.conf.low { background: var(--pink50); color: var(--pinkd); }

.empty { text-align: center; color: var(--ink3); font-size: 14px; padding: 60px 24px; }
.empty i { font-size: 40px; color: #d7dae1; display: block; margin-bottom: 12px; }

/* ---- Adapt My Day ---- */
/* Icon-only circular FAB, fixed to the viewport so it's reachable anywhere in the day. */
.fab-adapt i { line-height: 0; }

.sheet-head { margin-bottom: 8px; }
.sheet-kicker { font-size: 12px; font-weight: 600; color: var(--pink); display: inline-flex; align-items: center; gap: 5px; }
.sheet-title { font-size: 20px; font-weight: 600; margin: 6px 0 2px; }
.linkbtn { background: none; border: none; color: var(--ink2); font-family: inherit; font-size: 13px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 3px; padding: 4px 0; }

.adapt-cats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 6px; }
.adapt-cat { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; padding: 18px 10px;
  border: 1px solid var(--line); border-radius: 16px; background: #fcfcfe; color: var(--ink); font-family: inherit; font-size: 14px; font-weight: 600; cursor: pointer; }
.adapt-cat i { font-size: 26px; color: var(--pink); }
.adapt-cat:active { transform: scale(0.98); }
.adapt-cat:last-child:nth-child(odd) { grid-column: 1 / -1; }

.adapt-actions { display: flex; flex-direction: column; gap: 8px; margin-top: 4px; }
.adapt-conflict-txt { font-size: 14px; color: var(--ink2); margin: 4px 2px 12px; line-height: 1.45; }
.adapt-conflict-txt b { color: var(--ink); }
.adapt-action { display: flex; align-items: center; gap: 12px; padding: 13px 14px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--card); font-family: inherit; font-size: 14.5px; font-weight: 500; color: var(--ink); cursor: pointer; text-align: left; }
.adapt-action .ico { width: 36px; height: 36px; flex: 0 0 36px; border-radius: 10px; background: var(--pink50); color: var(--pink);
  display: flex; align-items: center; justify-content: center; font-size: 19px; }
.adapt-action .lbl { flex: 1; }
.adapt-action .c { color: var(--ink3); }
.adapt-action:active { transform: scale(0.99); }

.adapt-cards { display: flex; flex-direction: column; gap: 10px; }
.adapt-card { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.ac-body { flex: 1; min-width: 0; }
.ac-name { font-size: 14.5px; font-weight: 600; }
.ac-meta { font-size: 12px; color: var(--ink2); margin-top: 3px; }
.ac-tags { margin-top: 6px; }
.btn.sm { width: auto; padding: 9px 16px; font-size: 13px; flex: 0 0 auto; }
.spot-chip { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 600;
  color: var(--pink); background: var(--pink50, #fdf0f5); border-radius: 20px; padding: 1px 8px; margin-left: 4px; }
.spot-chip .ti { font-size: 12px; }
.ac-actions { display: flex; flex-direction: column; gap: 6px; flex: 0 0 auto; align-items: stretch; }
.ac-actions .btn.sm { width: 100%; text-align: center; }

/* "Add a ride" affordance at the foot of the itinerary. */
.addride-btn { display: flex; align-items: center; justify-content: center; gap: 7px; width: calc(100% - 28px);
  margin: 2px 14px 16px; padding: 13px; border: 1.5px dashed var(--line); border-radius: 14px;
  background: transparent; color: var(--ink2); font-size: 14px; font-weight: 600; cursor: pointer; }
.addride-btn:hover { border-color: var(--pink); color: var(--pink); background: var(--card); }
@media (min-width: 640px) { .addride-btn { max-width: 360px; margin-left: 24px; } }
/* Two add-stop buttons side by side at the foot of the itinerary. */
.addstops { display: flex; gap: 8px; margin: 2px 14px 16px; }
.addstops .addride-btn { flex: 1; width: auto; margin: 0; max-width: none; }
@media (min-width: 640px) { .addstops { max-width: 728px; margin-left: 24px; } }

.adapt-note { background: var(--blue50) !important; color: var(--blue800) !important; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.adapt-note span { display: flex; align-items: center; gap: 7px; }
.notice-x { background: none; border: none; font-size: 22px; line-height: 1; color: inherit; cursor: pointer; opacity: 0.7; padding: 0 2px; }

/* ---- Magic Suggestions ---- */
#suggestions { padding: 8px 14px 0; display: flex; flex-direction: column; gap: 8px; }
.sugg { display: flex; align-items: center; gap: 10px; padding: 11px 12px; border-radius: 14px; background: #fff7fb; border: 1px solid var(--pink100); }
.sugg-ic { width: 34px; height: 34px; flex: 0 0 34px; border-radius: 10px; background: var(--pink50); color: var(--pink); display: flex; align-items: center; justify-content: center; font-size: 18px; }
.sugg-txt { flex: 1; min-width: 0; font-size: 13px; color: var(--ink); line-height: 1.35; }
.sugg-x { opacity: 0.6; }

/* completed/current state cues */
.it.done .thumb { filter: grayscale(0.5); }

/* ---- sidebar brand (desktop only) ---- */
.side-brand { display: none; }
/* Guide link lives in the header (.appbar-help) on mobile; on desktop it moves into
   the sidebar (the appbar is hidden there), pinned to the bottom. */
.side-help { display: none; text-decoration: none; }

/* ==========================================================================
   Desktop — full screen, same app style & flow. The bottom tab bar becomes a
   left sidebar, content fills the width, the timeline tiles into columns, the
   hero is a full-bleed banner, and the detail sheet becomes a centred modal.
   The mobile layout above is untouched below 960px.
   ========================================================================== */
@media (min-width: 960px) {
  body { background: var(--bg); }
  .app { max-width: none; min-height: 100vh; box-shadow: none;
    display: grid; grid-template-columns: 248px minmax(0, 1fr); grid-template-areas: "nav main"; }
  .views { grid-area: main; padding-bottom: 0; min-width: 0; }

  /* left sidebar navigation */
  .tabbar { grid-area: nav; position: sticky; top: 0; align-self: start; height: 100vh;
    flex-direction: column; justify-content: flex-start; align-items: stretch; gap: 4px;
    padding: 20px 14px; background: var(--card); border-top: none; border-right: 1px solid var(--line);
    backdrop-filter: none; -webkit-backdrop-filter: none; }
  .side-brand { display: flex; align-items: center; gap: 9px; font-size: 15px; font-weight: 600;
    padding: 6px 10px 16px; }
  .side-brand b { color: var(--pink); font-weight: 600; }
  /* Guide link: styled like a nav item, pushed to the bottom of the sidebar. */
  .side-help { display: flex; margin-top: auto; color: var(--pinkd); }
  .side-help.on { background: transparent; }
  .ni { flex-direction: row; justify-content: flex-start; gap: 13px; padding: 12px 14px; font-size: 14.5px;
    border-radius: 12px; }
  .ni i { font-size: 22px; }
  .ni.on { background: var(--pink50); color: var(--pink); }

  /* build: full-bleed hero, comfortably-centred form */
  .appbar { display: none; }
  .labban { text-align: center; font-size: 13px; }
  .hero { margin: 0; border-radius: 0; min-height: 360px; }
  .hero-ov { max-width: 1100px; margin: 0 auto; padding: 22px 40px 30px; }
  .h1 { font-size: 30px; max-width: 640px; }
  .hsub { font-size: 15px; max-width: 560px; }
  #wizard-steps { max-width: 720px; margin: 8px auto 0; }
  #planner-form, #freshness-card { max-width: 720px; margin-left: auto; margin-right: auto; }

  /* day: sticky header full width, timeline tiles across the screen */
  .daybar, .stats, .tabs { padding-left: 24px; padding-right: 24px; }
  .daybar-title { font-size: 19px; }
  .stats { max-width: 640px; }
  .tl { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 14px;
    align-items: start; padding: 6px 24px 12px; }
  .itrow { margin: 0; }
  .tl .lbl { grid-column: 1 / -1; padding: 6px 2px 0; }
  .donebar { padding-left: 24px; }
  .viewall { max-width: 360px; margin: 4px 24px 16px; }
  .notice, .empty { max-width: 760px; }

  /* route + optimise centred */
  #map-content, #optimise-content { max-width: 780px; margin: 0 auto; }

  /* Adapt My Day stays reachable on desktop; anchor it to the day column */
  .fab-adapt { right: 32px; bottom: 28px; }

  /* detail becomes a centred modal card */
  .sheet { top: 50%; bottom: auto; left: 50%; max-width: 460px; max-height: 84vh; border-radius: 22px;
    transform: translate(-50%, -46%); opacity: 0; box-shadow: 0 24px 60px rgba(18, 24, 38, 0.28); }
  .sheet.on { transform: translate(-50%, -50%); opacity: 1; }
  .grab { display: none; }
}

/* ===== Live Companion & Opportunity Intelligence ===== */
#companion, #live-feed { padding: 0 14px; }
.companion { background: linear-gradient(180deg, #fff, #fdf6f9); border: 1px solid var(--line); border-radius: 16px;
  padding: 14px 15px; margin-bottom: 10px; box-shadow: 0 3px 14px rgba(30,40,60,.05); }
.comp-top { display: flex; justify-content: space-between; align-items: flex-start; }
.comp-hi { font-size: 17px; font-weight: 700; color: var(--ink); }
.comp-park { font-size: 13px; color: var(--ink2); margin-top: 1px; }
.comp-cond { display: flex; gap: 10px; font-size: 12.5px; color: var(--ink2); font-weight: 600; }
.comp-cond i { font-size: 14px; vertical-align: -2px; margin-right: 2px; color: var(--pink); }
.comp-pace { margin-top: 8px; font-size: 13px; font-weight: 600; color: var(--ink2); }
.comp-pace.ahead { color: var(--grn800); } .comp-pace.behind { color: var(--amb); }
.comp-next { margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--line); }
.comp-next-lbl { font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); }
.comp-next-name { font-size: 15px; font-weight: 600; color: var(--ink); margin-top: 2px; }
.comp-next-sub { font-size: 12.5px; color: var(--ink2); margin-top: 1px; }
.comp-tips { margin-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.comp-tip { display: flex; align-items: center; gap: 8px; font-size: 12.5px; color: var(--ink2); cursor: pointer; }
.comp-tip i { font-size: 16px; color: var(--pink); flex: 0 0 auto; }
.comp-tip:hover { color: var(--ink); }

.feed { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 8px 10px; margin-bottom: 10px; }
.feed-head { font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); padding: 4px 4px 6px; display: flex; align-items: center; gap: 6px; }
.feed-head i { color: var(--pink); font-size: 15px; }
.feed-row { display: flex; align-items: center; gap: 9px; padding: 7px 4px; border-top: 1px solid var(--line); font-size: 13px; color: var(--ink); }
.feed-row > i { font-size: 17px; color: var(--pink); flex: 0 0 auto; }
.feed-sum { flex: 1; min-width: 0; }
.feed-t { font-size: 11px; color: var(--ink3); flex: 0 0 auto; }
.feed-x { background: none; border: none; color: var(--ink3); font-size: 16px; cursor: pointer; line-height: 0; padding: 4px; }

.opp-kicker.critical, .opp-kicker.exceptional { color: var(--pink); }
.opp-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 4px 0 12px; }
.opp-cell { background: var(--pink50); border-radius: 12px; padding: 10px 8px; text-align: center; }
.opp-cell b { display: block; font-size: 16px; color: var(--pinkd); }
.opp-cell span { font-size: 11px; color: var(--ink2); }
.opp-why { background: #fafbfc; border: 1px solid var(--line); border-radius: 12px; padding: 11px 12px; margin-bottom: 4px; }
.opp-why b { font-size: 12.5px; color: var(--ink); } .opp-why p { margin: 4px 0 0; font-size: 13px; color: var(--ink2); line-height: 1.45; }

@keyframes fabpulse { 0%,100% { box-shadow: 0 10px 22px rgba(207,65,116,.42); } 50% { box-shadow: 0 0 0 10px rgba(207,65,116,.16), 0 10px 22px rgba(207,65,116,.42); } }
.fab-adapt.pulse { animation: fabpulse 1.6s ease-in-out infinite; }

/* ===== In-plan overflow menu + closure + favourites ===== */
.morebtn { background: none; border: none; padding: 7px; margin: 0 -6px; cursor: pointer; color: var(--ink3); line-height: 0; border-radius: 50%; }
.morebtn i { font-size: 19px; }
.morebtn:active { transform: scale(0.88); }
.favstar { color: var(--amb); font-size: 13px; margin-right: 4px; vertical-align: -1px; }
.it.fav { border-color: #f0d9a8; }
.it.closed { background: #fdf0f0; border-color: #f4cccc; }
.closed-tag { color: #b23b3b; font-weight: 600; font-size: 12px; }
.repl-score { margin-left: auto; font-weight: 700; color: var(--pinkd); font-size: 14px; flex: 0 0 auto; }
.linkbtn { background: none; border: none; color: var(--pink); font-weight: 600; font-size: 13px; font-family: inherit; cursor: pointer; padding: 2px 0; display: inline-flex; align-items: center; gap: 2px; }

/* ===== Progress intelligence ===== */
.progress { background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px 14px; margin: 0 14px 10px; }
.progress-head { font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); margin-bottom: 8px; }
.progress-bar { height: 7px; border-radius: 999px; background: #eceef3; overflow: hidden; margin-bottom: 10px; }
.progress-bar > span { display: block; height: 100%; background: linear-gradient(90deg, var(--pink), var(--pinkd)); }
.progress-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.progress-cell b { display: block; font-size: 15px; color: var(--ink); }
.progress-cell span { font-size: 11px; color: var(--ink2); }

/* ===== Itinerary-first refinement: compact Now card / pills ===== */
#companion { padding: 8px 14px 0; }
.stats { padding: 8px 14px 6px; background: transparent; }

/* Compact "Now" card (Dynamic-Island style) */
.now { width: 100%; display: flex; align-items: center; gap: 10px; text-align: left; cursor: pointer;
  background: linear-gradient(180deg, #fff, #fdf6f9); border: 1px solid var(--line); border-radius: 15px;
  padding: 11px 14px; box-shadow: 0 2px 10px rgba(30,40,60,.05); font-family: inherit; }
.now-body { flex: 1; min-width: 0; }
.now-cond { font-size: 12px; color: var(--ink2); font-weight: 600; }
.now-next { margin-top: 3px; font-size: 15px; line-height: 1.2; }
.now-lbl { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--ink3); }
.now-name { font-weight: 600; color: var(--ink); }
.now-sub { font-size: 12.5px; color: var(--ink2); margin-top: 2px; }
.now-sub b.ahead { color: var(--grn800); } .now-sub b.behind { color: var(--amb); }
.now-go { color: var(--ink3); font-size: 20px; flex: 0 0 auto; }
.now:active { transform: scale(0.995); }

.btn.sm { padding: 9px 12px; font-size: 13px; border-radius: 11px; }

/* Compact stat pills */
.pills { display: flex; gap: 7px; flex-wrap: wrap; }
.pill { display: inline-flex; align-items: center; gap: 5px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px; font-size: 12.5px; font-weight: 600; color: var(--ink2); }
.pill i { font-size: 14px; color: var(--pink); }

/* ===== AI Companion (floating button) ===== */
/* Notification badge on the FAB — count of active opportunities. */
.fab-badge { position: absolute; top: -3px; right: -3px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 999px;
  background: #fff; color: var(--pinkd); font-size: 12px; font-weight: 800; line-height: 20px; text-align: center;
  box-shadow: 0 2px 6px rgba(30,40,60,.28); border: 1.5px solid var(--pink); }
.fab-badge[hidden] { display: none; }

/* Companion sheet: ranked opportunities as review-style cards. */
.comp-sub { font-size: 13px; color: var(--ink2); margin: 6px 0 2px; line-height: 1.4; }
.comp-list { display: flex; flex-direction: column; gap: 12px; margin-top: 8px; }
.comp-opp { border: 1px solid var(--line); border-radius: 15px; padding: 13px 14px; background: linear-gradient(180deg, #fff, #fdf7fa); box-shadow: 0 2px 10px rgba(30,40,60,.05); }
.comp-opp-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.comp-opp-name { font-size: 15.5px; font-weight: 700; color: var(--ink); display: inline-flex; align-items: center; gap: 7px; line-height: 1.25; }
.comp-opp-name i { color: var(--pink); font-size: 18px; flex: 0 0 auto; }
.comp-stars { flex: 0 0 auto; color: var(--amb); font-size: 13px; letter-spacing: 1px; white-space: nowrap; }
.comp-opp-why { margin: 10px 0 12px; font-size: 13px; color: var(--ink2); line-height: 1.45; }
.comp-opp-acts { display: flex; gap: 8px; }
.comp-opp-acts .btn { flex: 1; }

/* Quiet live-activity list at the foot of the Companion. */
.comp-activity { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 12px; }
.comp-activity-head { font-size: 11px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink3); display: flex; align-items: center; gap: 7px; margin-bottom: 8px; }
.comp-act { display: flex; align-items: center; gap: 9px; padding: 6px 0; font-size: 13px; color: var(--ink); }
.comp-act > i { font-size: 16px; color: var(--pink); flex: 0 0 auto; }
.comp-act-sum { flex: 1; min-width: 0; }
.comp-act-t { font-size: 11px; color: var(--ink3); flex: 0 0 auto; }
.live-dot { flex: 0 0 auto; font-size: 10px; font-weight: 800; letter-spacing: .06em; color: #d0342c; display: inline-flex; align-items: center; gap: 5px; }
.live-dot::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: #d0342c; box-shadow: 0 0 0 0 rgba(208,52,44,.5); animation: livedot 1.6s infinite; }
@keyframes livedot { 0% { box-shadow: 0 0 0 0 rgba(208,52,44,.5); } 70% { box-shadow: 0 0 0 6px rgba(208,52,44,0); } 100% { box-shadow: 0 0 0 0 rgba(208,52,44,0); } }

/* ============ Live Park Board ============ */
.itsub .posted { color: var(--ink3); font-weight: 500; }
/* Stroller-parking rain advisory (weather + time aware). */
.advisory { display: inline-flex; align-items: center; gap: 5px; margin: 4px 0 2px; font-size: 11.5px; font-weight: 600;
  color: var(--amb); background: var(--amb50); border-radius: 999px; padding: 3px 10px; line-height: 1.3; }
.advisory i { font-size: 14px; flex: 0 0 auto; }

/* ============ save-state indicator + day plan switcher ============ */
.save-state { font-size: 11px; font-weight: 600; color: var(--ink3); white-space: nowrap; }
.save-state.saving { color: var(--amb); }
.save-state.saved { color: var(--grn800); }
.save-state.failed { color: var(--pinkd); }
.save-state.pending { color: var(--amb); }
#day-switch { display: flex; align-items: center; gap: 8px; padding: 8px 0 2px; }
.day-switch-btn { flex: 0 0 auto; background: #f2f3f7; border: none; border-radius: 999px; width: 30px; height: 30px; display: flex; align-items: center; justify-content: center; color: var(--ink2); cursor: pointer; }
.day-switch-btn[disabled] { opacity: .4; pointer-events: none; }
.day-switch-btn i { font-size: 17px; }
.day-switch-mid { flex: 1; min-width: 0; text-align: center; font-size: 12px; color: var(--ink2); font-weight: 600; }

/* ============ My Plans ============ */
.plans-tabs { position: static; border-bottom: none; padding: 10px 0 2px; }
.plans-tabs.tabs button { font-size: 13px; }
.fab-plan { background: linear-gradient(180deg, #e0668f, #cf4174); }
.plans-empty { text-align: center; color: var(--ink2); padding: 46px 24px; }
.plans-empty i.big { font-size: 46px; color: var(--pink100); display: block; margin-bottom: 14px; }
.plans-empty h3 { font-size: 19px; font-weight: 700; margin: 0 0 6px; color: var(--ink); }
.plans-empty p { font-size: 13px; color: var(--ink3); margin: 0 0 16px; }
.plans-empty .btn { max-width: 260px; margin: 8px auto 0; }
.plans-actions { display: flex; gap: 8px; padding: 6px 14px 2px; }
.plans-actions .btn { flex: 1; }
.plans-search { margin: 10px 14px 2px; }
.plans-sorts { display: flex; gap: 7px; overflow-x: auto; scrollbar-width: none; padding: 6px 14px 2px; }
.plans-sorts::-webkit-scrollbar { display: none; }
.plans-sorts button { flex: 0 0 auto; font-size: 12px; color: var(--ink3); padding: 5px 12px; border-radius: 999px; background: #f2f3f7; border: none; font-family: inherit; cursor: pointer; white-space: nowrap; }
.plans-sorts button.on { background: var(--pink); color: #fff; }

/* trip group */
.trip-card { margin: 12px 14px; border: 1px solid var(--line); border-radius: 16px; overflow: hidden; background: var(--card); }
.trip-head { display: flex; align-items: center; gap: 10px; padding: 13px 14px; cursor: pointer; }
.trip-head .tt { flex: 1; min-width: 0; }
.trip-name { font-size: 15px; font-weight: 700; color: var(--ink); }
.trip-dates { font-size: 12px; color: var(--ink3); margin-top: 2px; }
.trip-chev { color: var(--ink3); transition: transform .2s; }
.trip-card.collapsed .trip-chev { transform: rotate(-90deg); }
.trip-card.collapsed .trip-body { display: none; }
.trip-body { padding: 0 10px 8px; }
.trip-menu-btn { background: none; border: none; color: var(--ink3); cursor: pointer; padding: 6px; line-height: 0; }
.trip-menu-btn i { font-size: 18px; }

/* plan card (date-based) */
.plan-card { display: flex; align-items: center; gap: 11px; padding: 11px 10px; border-radius: 12px; cursor: pointer; }
.plan-card:hover { background: #fafbfd; }
.plan-card + .plan-card { border-top: 1px solid var(--line); }
.plan-date { flex: 0 0 auto; width: 46px; text-align: center; }
.plan-date b { display: block; font-size: 18px; font-weight: 700; color: var(--ink); line-height: 1; }
.plan-date span { font-size: 10.5px; color: var(--ink3); text-transform: uppercase; }
.plan-date.nodate b { font-size: 20px; color: var(--ink3); }
.plan-ico { flex: 0 0 auto; width: 38px; height: 38px; border-radius: 11px; display: flex; align-items: center; justify-content: center; background: var(--pink50); color: var(--pinkd); }
.plan-ico i { font-size: 20px; }
.plan-main { flex: 1; min-width: 0; }
.plan-name { font-size: 14px; font-weight: 600; color: var(--ink); }
.plan-sub { font-size: 11.5px; color: var(--ink3); margin-top: 2px; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.plan-status { font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 999px; text-transform: uppercase; letter-spacing: .03em; }
.plan-status.draft { background: #eef0f4; color: var(--ink2); }
.plan-status.generated { background: var(--grn50); color: var(--grn800); }
.plan-status.in_progress { background: var(--blue50); color: var(--blue800); }
.plan-status.completed { background: var(--pink50); color: var(--pinkd); }
.plan-status.archived { background: #eceef2; color: var(--ink3); }
.plan-status.ready_to_generate { background: var(--amb50); color: var(--amb); }
.plan-warn { color: var(--amb); font-size: 11px; }
.plan-menu-btn { flex: 0 0 auto; background: none; border: none; color: var(--ink3); cursor: pointer; padding: 8px; line-height: 0; border-radius: 50%; }
.plan-menu-btn i { font-size: 19px; }
.plans-section-lbl { font-size: 11px; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--ink3); padding: 16px 16px 2px; }

.board-head { padding-bottom: 12px; }
.board-refresh.spin i { animation: bspin 0.8s linear infinite; }
@keyframes bspin { to { transform: rotate(360deg); } }
.board-desc { font-size: 12.5px; color: var(--ink2); margin: 6px 0 8px; line-height: 1.4; }
.board-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 12px; }
.board-updated { font-size: 11.5px; color: var(--ink3); }
.board-parks { margin-top: 2px; }
.board-parks button { flex: 1 1 auto; }
.board-warn { margin: 10px 14px 0; background: var(--amb50); color: var(--amb); border-radius: 12px; padding: 9px 12px; font-size: 12.5px; display: flex; align-items: center; gap: 7px; }
.board-warn i { font-size: 15px; flex: 0 0 auto; }
.board-warn.calm { background: #eef1f7; color: #56617a; }

/* summary strip */
.board-summary { display: flex; gap: 8px; padding: 12px 14px 2px; overflow-x: auto; scrollbar-width: none; }
.board-summary::-webkit-scrollbar { display: none; }
.bsum { flex: 1 0 auto; min-width: 76px; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 9px 11px; text-align: center; }
.bsum b { display: block; font-size: 17px; font-weight: 700; color: var(--ink); line-height: 1.1; }
.bsum b.g { color: var(--grn800); } .bsum b.a { color: var(--amb); } .bsum b.p { color: var(--pinkd); }
.bsum span { font-size: 10.5px; color: var(--ink3); }

/* section headers */
.board-sec { display: flex; align-items: center; justify-content: space-between; padding: 18px 16px 8px; }
.board-sec h3 { font-size: 14px; font-weight: 700; margin: 0; color: var(--ink); }
.board-sec .cnt { font-size: 11.5px; color: var(--ink3); font-weight: 600; }
.board-linkbtn { background: none; border: none; color: var(--pink); font-weight: 600; font-size: 12.5px; font-family: inherit; cursor: pointer; display: inline-flex; align-items: center; gap: 3px; padding: 2px 0; }

/* selected rides — prominent grid */
.pin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; padding: 0 14px; }
.pin-card { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 13px 14px; box-shadow: 0 2px 10px rgba(30,40,60,.05); position: relative; display: flex; flex-direction: column; gap: 4px; }
.pin-card.closed { background: #fbf3f3; border-color: #f1cccc; }
.pin-top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.pin-wait { font-size: 34px; font-weight: 800; line-height: 1; color: var(--ink); letter-spacing: -0.02em; }
.pin-wait small { font-size: 13px; font-weight: 600; color: var(--ink3); margin-left: 2px; letter-spacing: 0; }
.pin-wait.closed { font-size: 20px; color: #b23b3b; }
.pin-wait.nowait { font-size: 19px; color: var(--ink2); }
.pin-name { font-size: 14.5px; font-weight: 700; color: var(--ink); line-height: 1.2; }
.pin-land { font-size: 11.5px; color: var(--ink3); }
.pin-tags { display: flex; flex-wrap: wrap; gap: 5px; margin-top: 4px; }
.pin-sub { font-size: 11px; color: var(--ink3); margin-top: 4px; }
.pin-acts { position: absolute; top: 8px; right: 8px; display: flex; gap: 2px; }
.pin-btn { background: none; border: none; color: var(--ink3); cursor: pointer; padding: 5px; line-height: 0; border-radius: 8px; }
.pin-btn:hover { background: var(--line); }
.pin-btn i { font-size: 16px; }
.pin-btn.unpin i { font-size: 18px; }

/* trend + delta chips */
.trend { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; }
.trend.up { background: var(--pink50); color: var(--pinkd); }
.trend.down { background: var(--grn50); color: var(--grn800); }
.trend.flat { background: #eef0f4; color: var(--ink2); }
.trend i { font-size: 13px; }

/* other rides — compact rows */
.board-controls { display: flex; flex-direction: column; gap: 8px; padding: 0 14px 4px; }
.board-sorts { display: flex; gap: 7px; overflow-x: auto; scrollbar-width: none; padding-bottom: 2px; }
.board-sorts::-webkit-scrollbar { display: none; }
.board-sorts button { flex: 0 0 auto; font-size: 12.5px; color: var(--ink3); padding: 6px 13px; border-radius: 999px; background: #f2f3f7; font-weight: 500; border: none; font-family: inherit; cursor: pointer; white-space: nowrap; }
.board-sorts button.on { background: var(--pink); color: #fff; }
.board-filters { display: flex; gap: 7px; flex-wrap: wrap; }
.board-filters button { font-size: 12px; color: var(--ink2); padding: 6px 11px; border-radius: 999px; background: #fcfcfe; border: 1px solid var(--line); font-family: inherit; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; }
.board-filters button.on { background: var(--pink); color: #fff; border-color: var(--pink); }
.ride-list { padding: 4px 14px 0; }
.ride-row { display: flex; align-items: center; gap: 11px; padding: 11px 0; border-top: 1px solid var(--line); }
.ride-row:first-child { border-top: none; }
.ride-row.closed { opacity: 0.62; }
.ride-main { flex: 1; min-width: 0; }
.ride-name { font-size: 14px; font-weight: 600; color: var(--ink); }
.ride-meta { font-size: 11.5px; color: var(--ink3); margin-top: 2px; display: flex; align-items: center; gap: 7px; flex-wrap: wrap; }
.ride-num { flex: 0 0 auto; text-align: right; min-width: 52px; }
.ride-num b { font-size: 19px; font-weight: 700; color: var(--ink); }
.ride-num b.g { color: var(--grn800); }
.ride-num .rs { display: block; font-size: 10px; color: var(--ink3); }
.ride-num .closed-tag { color: #b23b3b; font-weight: 600; font-size: 11.5px; }
.pin-add { flex: 0 0 auto; background: none; border: 1px solid var(--line); color: var(--pink); border-radius: 50%; width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.pin-add:active { transform: scale(0.92); }
.pin-add i { font-size: 18px; }

/* empty state */
.board-empty { text-align: center; color: var(--ink3); font-size: 13.5px; padding: 26px 20px; margin: 0 14px; background: var(--card); border: 1px dashed var(--line); border-radius: 16px; }
.board-empty i { font-size: 30px; color: #d7dae1; display: block; margin-bottom: 10px; }
.board-empty .btn { margin-top: 12px; display: inline-flex; width: auto; }

/* next showtimes */
.show-card { background: var(--card); border: 1px solid var(--line); border-radius: 15px; padding: 12px 14px; margin: 0 14px 10px; }
.show-card.nighttime { background: linear-gradient(180deg, #f3f1fb, #fff); border-color: #ddd8f1; }
.show-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.show-name { font-size: 14.5px; font-weight: 700; color: var(--ink); line-height: 1.2; }
.show-land { font-size: 11.5px; color: var(--ink3); margin-top: 2px; }
.show-next { text-align: right; flex: 0 0 auto; }
.show-next b { font-size: 16px; font-weight: 700; color: var(--pinkd); }
.show-next span { display: block; font-size: 10.5px; color: var(--ink3); }
.show-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 9px; }
.show-chip { font-size: 11.5px; font-weight: 600; color: var(--ink2); background: #f2f3f7; border-radius: 999px; padding: 4px 10px; }
.show-grp { font-size: 11px; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; color: var(--ink3); padding: 6px 16px 4px; }
.show-untimed { display: flex; flex-wrap: wrap; gap: 6px; padding: 2px 14px 0; }
.show-untimed .chip { background: #eef0f4; color: var(--ink2); }

/* add-rides sheet list */
.addr-search { margin-bottom: 10px; }
.addr-list { max-height: 60vh; overflow-y: auto; margin: 0 -4px; }
.addr-row { display: flex; align-items: center; gap: 10px; padding: 11px 4px; border-top: 1px solid var(--line); cursor: pointer; }
.addr-row:first-child { border-top: none; }
.addr-row .ride-main { flex: 1; }
.addr-check { flex: 0 0 auto; width: 24px; height: 24px; border-radius: 50%; border: 2px solid var(--line); display: flex; align-items: center; justify-content: center; color: #fff; }
.addr-row.on .addr-check { background: var(--pink); border-color: var(--pink); }
.addr-row.on .addr-check i { font-size: 15px; }

/* ============ Ride Tracker ============ */
#trk-content { padding-bottom: 24px; }
.trk-summary { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 16px; margin: 12px 14px; }
.trk-head-row { display: flex; align-items: center; justify-content: space-between; }
.trk-big { font-size: 34px; font-weight: 700; line-height: 1; color: var(--ink); }
.trk-big .trk-slash { font-size: 20px; font-weight: 600; color: var(--ink3); }
.trk-sub { font-size: 13px; color: var(--ink2); margin-top: 4px; }
.trk-sub b { color: var(--pink); }
.trk-bar { height: 8px; border-radius: 6px; background: var(--line); overflow: hidden; margin-top: 12px; }
.trk-bar-fill { height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--pink), #f5a0c0); transition: width .3s ease; }

.trk-parkgrid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin: 0 14px 12px; }
.trk-parkcard { text-align: left; background: var(--card); border: 1px solid var(--line); border-radius: 14px; padding: 12px; cursor: pointer; font-family: inherit; }
.trk-parkcard:hover { border-color: var(--pink); }
.trk-pc-top { display: flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--ink2); }
.trk-pc-top i { font-size: 16px; color: var(--pink); }
.trk-pc-count { font-size: 22px; font-weight: 700; margin: 6px 0 2px; }
.trk-pc-count small { font-size: 13px; font-weight: 600; color: var(--ink3); }
.trk-pc-rem { font-size: 11.5px; color: var(--ink3); margin-top: 6px; }

.trk-controls { flex-direction: column; align-items: stretch; gap: 10px; }
.trk-search { margin: 0; }
.trk-park-head { margin-top: 14px; }
.trk-park-head h3 { display: flex; align-items: center; gap: 7px; }
.trk-park-head h3 i { color: var(--pink); }

.trk-row { align-items: center; gap: 11px; cursor: pointer; }
.trk-row.locked { cursor: default; }
.trk-check { flex: 0 0 auto; display: flex; align-items: center; color: var(--line); }
.trk-check i { font-size: 24px; }
.trk-row.done .trk-check { color: var(--pink); }
.trk-row .ride-main { flex: 1; min-width: 0; }
.trk-row.done .ride-name { color: var(--ink2); }
.trk-when { flex: 0 0 auto; text-align: right; display: flex; flex-direction: column; align-items: flex-end; }
.trk-when-date { font-size: 13px; font-weight: 600; color: var(--ink); }
.trk-src { font-size: 10.5px; color: var(--ink3); }
.trk-when.todo { font-size: 12px; color: var(--ink3); font-weight: 500; }

/* ============ Reservations (wizard + day view) ============ */
.res-empty { font-size: 12.5px; color: var(--ink3); background: var(--card); border: 1px dashed var(--line); border-radius: 12px; padding: 12px; margin: 6px 0 10px; }
.res-cards { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
.res-add { width: 100%; }
.res-card { display: flex; align-items: center; gap: 11px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 13px; background: var(--card); }
.res-card.ll { border-left: 3px solid #7b61ff; }
.res-card.dine { border-left: 3px solid var(--pink); }
.res-ico { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 9px; display: flex; align-items: center; justify-content: center; font-size: 18px; }
.res-card.ll .res-ico { background: #efeaff; color: #6a4bff; }
.res-card.dine .res-ico { background: #fdf0f5; color: var(--pink); }
.res-main { flex: 1; min-width: 0; }
.res-type { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .02em; color: var(--ink3); display: flex; align-items: center; gap: 6px; }
.res-title { font-size: 14px; font-weight: 600; margin-top: 1px; }
.res-sub { font-size: 12px; color: var(--ink2); margin-top: 2px; }
.res-acts { display: flex; gap: 4px; flex: 0 0 auto; }
.res-btn { width: 32px; height: 32px; border-radius: 8px; border: 1px solid var(--line); background: #fff; color: var(--ink2); cursor: pointer; display: flex; align-items: center; justify-content: center; }
.res-btn:hover { border-color: var(--pink); color: var(--pink); }
.res-review { background: #fef3c7 !important; color: #92610b !important; font-size: 10px; padding: 0 6px; border-radius: 10px; }
.res-errors .notice.err ul { margin: 6px 0 0; padding-left: 18px; }

/* editor sheet */
.res-typeseg { margin-bottom: 12px; }
.res-typeseg button i { margin-right: 5px; }
.res-form { display: flex; flex-direction: column; gap: 12px; }
.res-field { display: flex; flex-direction: column; gap: 5px; flex: 1; min-width: 0; }
.res-field label { font-size: 12px; font-weight: 600; color: var(--ink2); }
.res-field input, .res-field select { border: 1px solid var(--line); border-radius: 9px; padding: 9px 10px; font-family: inherit; font-size: 14px; background: #fff; width: 100%; }
.res-row { display: flex; gap: 10px; }
.res-static { font-size: 13px; color: var(--ink2); padding: 9px 0; }
.res-note { font-size: 11.5px; color: var(--ink3); display: flex; align-items: center; gap: 6px; margin-top: 12px; }
.res-err { color: #c0392b; font-size: 12.5px; font-weight: 600; margin: 2px 0 0; }
/* Ride + dining pickers: stack the name over its meta line so long venue names and
   category/area labels wrap instead of running together and overflowing sideways. */
#res-ride-results .dd-opt, #res-name-results .dd-opt {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  white-space: normal; line-height: 1.3; overflow-wrap: anywhere;
}
#res-ride-results .dd-land, #res-name-results .dd-land {
  display: block; color: var(--ink3); font-size: 11.5px; font-weight: 400;
}
#res-ride-results, #res-name-results { overflow-x: hidden; }

/* protected reservation itinerary cards */
.res-item.ll { border-left: 3px solid #7b61ff; }
.res-item.dine { border-left: 3px solid var(--pink); }
.res-thumb.ll { background: #efeaff; color: #6a4bff; }
.res-thumb.dine { background: #fdf0f5; color: var(--pink); }
.res-line { font-size: 12px; color: var(--ink2); margin-top: 3px; }
.bdg.res-protected { background: #eef1f6; color: var(--ink2); display: inline-flex; align-items: center; gap: 4px; margin-top: 6px; }
.bdg.res-protected i { font-size: 12px; }

/* ============ Account & cloud-sync ============ */
.acct-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 6px 11px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--card); color: var(--ink2); cursor: pointer; max-width: 62vw; }
.acct-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct-chip i { font-size: 15px; }
.acct-chip.saved { color: #1a7f52; border-color: #bfe6d0; background: #f0faf4; }
.acct-chip.saving, .acct-chip.syncing { color: var(--pink); }
.acct-chip.offline { color: #92610b; border-color: #f2e2b8; background: #fdf7e6; }
.acct-chip.conflict, .acct-chip.error { color: #b23b3b; border-color: #f0cccc; background: #fdf2f2; }
.acct-chip .ti-refresh, .acct-chip.syncing .ti { animation: acct-spin 1s linear infinite; }
@keyframes acct-spin { to { transform: rotate(360deg); } }

.acct-lead { font-size: 13.5px; color: var(--ink2); margin: 2px 0 12px; }
.acct-hint { font-size: 11.5px; color: var(--ink3); margin: 6px 0 0; }
.acct-form { display: flex; flex-direction: column; gap: 10px; }
.acct-form label { display: flex; flex-direction: column; gap: 5px; font-size: 12.5px; font-weight: 600; color: var(--ink2); }
.acct-form input { border: 1px solid var(--line); border-radius: 9px; padding: 10px 11px; font-family: inherit; font-size: 15px; }
.acct-links { display: flex; justify-content: space-between; gap: 8px; margin: 12px 0; flex-wrap: wrap; }
.acct-guest { border-top: 1px solid var(--line); margin-top: 8px; padding-top: 12px; }
.acct-guest .btn { width: 100%; }
.acct-err { background: #fdf2f2; color: #b23b3b; border-radius: 10px; padding: 9px 11px; font-size: 13px; margin-bottom: 10px; }
.acct-ok { background: #f0faf4; color: #1a7f52; border-radius: 10px; padding: 9px 11px; font-size: 13px; margin-bottom: 10px; }
.acct-actions { display: flex; flex-direction: column; gap: 8px; margin: 14px 0; }
.acct-status { display: flex; align-items: center; gap: 11px; background: var(--card); border: 1px solid var(--line); border-radius: 13px; padding: 12px; margin: 4px 0 12px; }
.acct-status i { font-size: 22px; color: var(--pink); }
.acct-status.saved i { color: #1a7f52; }
.acct-status.offline i { color: #92610b; }
.acct-status.conflict i, .acct-status.error i { color: #b23b3b; }
.acct-status > div { flex: 1; min-width: 0; }
.acct-status-main { font-weight: 600; font-size: 14px; }
.acct-status-sub { font-size: 11.5px; color: var(--ink3); margin-top: 2px; }
.acct-conflict { background: #fdf7e6; color: #92610b; border-radius: 11px; padding: 10px 12px; font-size: 12.5px; margin-bottom: 12px; }
.acct-rows { display: flex; flex-direction: column; gap: 12px; }
.acct-field label { font-size: 12px; font-weight: 600; color: var(--ink2); display: block; margin-bottom: 4px; }
.acct-static { font-size: 14px; color: var(--ink); }
.acct-inline { display: flex; gap: 8px; }
.acct-inline input { flex: 1; border: 1px solid var(--line); border-radius: 9px; padding: 9px 10px; font-family: inherit; font-size: 14px; }
.acct-sec { margin-top: 16px; }
.acct-sec h4 { font-size: 12px; text-transform: uppercase; letter-spacing: .03em; color: var(--ink3); margin: 0 0 8px; }
.acct-devices { display: flex; flex-direction: column; gap: 6px; }
.acct-device { display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 8px 0; border-bottom: 1px solid var(--line); }
.acct-device span:first-child { flex: 1; }
.acct-device em { color: var(--ink3); font-style: normal; font-size: 11px; }
.acct-device-time { font-size: 11px; color: var(--ink3); }
.acct-buttons { display: flex; flex-direction: column; gap: 8px; }
.acct-buttons .btn { justify-content: flex-start; }
.btn.ghost.danger { color: #b23b3b; border-color: #f0cccc; }

/* ---- Family Mode / Shared Trips ---- */
.plan-status.shared { background: var(--pink50); color: var(--pinkd); text-transform: none; letter-spacing: 0; }
.plan-status.shared i { font-size: 11px; vertical-align: -1px; margin-right: 2px; }
.share-badge { position: absolute; top: -6px; right: -7px; min-width: 16px; height: 16px; padding: 0 4px; border-radius: 999px; background: var(--pink); color: #fff; font-size: 10px; font-weight: 800; line-height: 16px; text-align: center; box-shadow: 0 0 0 2px #fff; }
.share-chip { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; color: var(--pinkd); background: var(--pink50); padding: 2px 9px; border-radius: 999px; }
.trip-sugg-pill { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; color: #fff; background: var(--pink); padding: 3px 9px; border-radius: 999px; margin-left: 6px; border: none; font-family: inherit; cursor: pointer; transition: filter .12s; }
.trip-sugg-pill:hover { filter: brightness(1.06); }
.trip-sugg-pill i { font-size: 12px; }
.share-chip i { color: var(--pink); font-size: 13px; margin-right: 0; }
.acct-device .bdg { font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #eef0f4; color: var(--ink2); }

/* Sheet form controls (invite email + role, reservation privacy, member role) — a
   soft, on-brand field with a custom chevron instead of the raw browser dropdown. */
.acct-field input,
.acct-field select,
.acct-device select.acct-static {
  width: 100%; font-family: inherit; font-size: 14px; color: var(--ink);
  background: #fff; border: 1px solid var(--line); border-radius: 10px;
  padding: 10px 12px; outline: none; box-shadow: 0 1px 2px rgba(20, 28, 45, 0.04);
  transition: border-color .15s, box-shadow .15s;
}
.acct-field select,
.acct-device select.acct-static {
  appearance: none; -webkit-appearance: none; -moz-appearance: none;
  padding-right: 34px; cursor: pointer;
  background-image: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23c05a86' stroke-width='2.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 11px center; background-size: 15px;
}
.acct-field input:hover,
.acct-field select:hover,
.acct-device select.acct-static:hover { border-color: var(--pink); }
.acct-field input:focus,
.acct-field select:focus,
.acct-device select.acct-static:focus { border-color: var(--pink); box-shadow: 0 0 0 3px var(--pink50); }
.acct-field select option { color: var(--ink); }
/* The compact in-row member-role select stays smaller than the full-width fields. */
.acct-device select.acct-static { width: auto; min-width: 118px; padding: 7px 30px 7px 11px; font-size: 12.5px; }

/* Suggest picker (participant) — Adapt-My-Day-style kind chips + searchable results. */
.sg-types { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 10px; }
.sg-type { display: inline-flex; align-items: center; gap: 5px; padding: 7px 12px; border: 1px solid var(--line); border-radius: 999px; background: #fff; font-family: inherit; font-size: 13px; color: var(--ink2); cursor: pointer; transition: all .12s; }
.sg-type i { font-size: 15px; }
.sg-type:hover { border-color: var(--pink); color: var(--pinkd); }
.sg-type.on { background: var(--pink); border-color: var(--pink); color: #fff; }
.sg-results { display: flex; flex-direction: column; gap: 4px; margin-top: 8px; max-height: 220px; overflow-y: auto; }
.sg-result { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; text-align: left; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; font-family: inherit; font-size: 13.5px; color: var(--ink); cursor: pointer; transition: all .12s; }
.sg-result:hover { border-color: var(--pink); background: var(--pink50); }
.sg-result .sg-meta { font-size: 11.5px; color: var(--ink3); flex: 0 0 auto; }
.sg-chosen { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border: 1px solid var(--pink); border-radius: 10px; background: var(--pink50); font-size: 13.5px; color: var(--pinkd); }
.sg-chosen i { margin-right: 4px; }

/* ============ Page-resume refresh: toast + freshness pill ============ */
/* Compact bottom toast — never a big banner over the itinerary; never steals focus. */
.refresh-toast { position: fixed; left: 50%; transform: translateX(-50%) translateY(12px);
  bottom: calc(var(--tab-h, 60px) + 14px + env(safe-area-inset-bottom, 0px)); z-index: 70;
  display: flex; align-items: center; gap: 10px; max-width: min(92vw, 440px);
  background: var(--card); color: var(--ink); border: 1px solid var(--line); border-radius: 14px;
  padding: 11px 13px; box-shadow: 0 8px 26px rgba(20, 20, 40, 0.14); opacity: 0; pointer-events: none;
  transition: opacity .28s ease, transform .28s ease; }
.refresh-toast.on { opacity: 1; transform: translateX(-50%) translateY(0); pointer-events: auto; }
.refresh-toast.warn { border-color: #f2e2b8; background: #fdf9ee; }
.refresh-toast.done { border-color: #bfe6d0; }
.refresh-toast .rt-ico { flex: 0 0 auto; width: 26px; height: 26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 15px; background: var(--pink50); color: var(--pink); }
.refresh-toast .rt-ico.ok { background: #e7f7ee; color: #1a7f52; }
.refresh-toast .rt-ico.warn { background: #fbeecb; color: #92610b; }
.refresh-toast .rt-ico.static { font-size: 16px; font-weight: 700; }
.refresh-toast .rt-ico.spin i { display: inline-block; animation: rt-spin 0.9s linear infinite; }
.refresh-toast .rt-body { display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.refresh-toast .rt-body b { font-size: 13.5px; }
.refresh-toast .rt-body span { font-size: 12px; color: var(--ink2); }
.refresh-toast .rt-x { margin-left: auto; background: none; border: none; font-size: 20px; color: var(--ink3); cursor: pointer; line-height: 1; padding: 0 2px; }
@keyframes rt-spin { to { transform: rotate(360deg); } }

/* Compact, persistent freshness pill (tap for details + manual refresh). */
.refresh-pill { position: fixed; left: 12px; bottom: calc(var(--tab-h, 60px) + 12px + env(safe-area-inset-bottom, 0px));
  z-index: 55; display: inline-flex; align-items: center; gap: 6px; max-width: 60vw;
  background: var(--card); border: 1px solid var(--line); border-radius: 999px; padding: 5px 11px;
  font-size: 11.5px; font-weight: 600; color: var(--ink2); cursor: pointer; box-shadow: 0 2px 8px rgba(20,20,40,.08); }
.refresh-pill .rp-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.refresh-pill .rp-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--ink3); flex: 0 0 auto; }
.refresh-pill.fresh .rp-dot { background: #1a7f52; }
.refresh-pill.stale .rp-dot { background: #d99a24; }
.refresh-pill.offline .rp-dot { background: #b23b3b; }
/* Parks closed (by design — live waits paused until near opening): calm, not alarming. */
.refresh-pill.closed .rp-dot { background: #6b7fa8; }
.refresh-pill.updating .rp-dot { background: var(--pink); animation: rt-pulse 1.1s ease-in-out infinite; }
@keyframes rt-pulse { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
/* Brief "just updated" glow — the calm alternative to a routine toast. */
.refresh-pill.glow { animation: rp-glow 2.2s ease-out 1; border-color: var(--pink); }
@keyframes rp-glow {
  0% { box-shadow: 0 2px 8px rgba(20,20,40,.08); }
  16% { box-shadow: 0 0 0 4px rgba(176,52,122,.28), 0 3px 16px rgba(176,52,122,.42); }
  100% { box-shadow: 0 2px 8px rgba(20,20,40,.08); }
}
.refresh-pop { position: fixed; left: 12px; bottom: calc(var(--tab-h, 60px) + 46px + env(safe-area-inset-bottom, 0px));
  z-index: 56; width: min(88vw, 300px); background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 12px; box-shadow: 0 10px 30px rgba(20,20,40,.16); }
.rpop-row { display: flex; justify-content: space-between; gap: 10px; font-size: 12.5px; padding: 6px 0; border-bottom: 1px solid var(--line); }
.rpop-row span { color: var(--ink2); } .rpop-row b { color: var(--ink); text-align: right; }
.rpop-refresh { width: 100%; margin-top: 10px; display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  background: var(--pink); color: #fff; border: none; border-radius: 10px; padding: 9px; font-family: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
@media (min-width: 640px) { .refresh-pill, .refresh-pop { left: auto; right: 16px; } .refresh-pill { bottom: 16px; } .refresh-pop { bottom: 50px; } }

/* Respect reduced motion: no spinners/pulses. */
@media (prefers-reduced-motion: reduce) {
  .refresh-toast { transition: none; }
  .refresh-toast .rt-ico.spin i, .refresh-pill.updating .rp-dot, .refresh-pill.glow { animation: none; }
}

/* account: legal acceptance + privacy controls */
.acct-check { display: flex; gap: 9px; align-items: flex-start; font-size: 13.5px; line-height: 1.4; margin: 10px 0 2px; cursor: pointer; }
.acct-check input { margin-top: 2px; flex: 0 0 auto; width: 18px; height: 18px; }
.acct-check a { color: var(--pink, #d4537e); }
.acct-check-opt { color: #55606f; }
.acct-note { display: flex; gap: 7px; align-items: flex-start; font-size: 12.5px; color: #55606f; background: #f3f6fb; border-radius: 10px; padding: 9px 11px; margin: 8px 0 2px; }
.acct-note .ti { color: #378add; margin-top: 1px; }
.acct-reaccept { background: #faeeda; border: 1px solid #f0d9b0; border-radius: 12px; padding: 12px 14px; margin: 4px 0 12px; }
.acct-reaccept strong { display: flex; align-items: center; gap: 6px; color: #7a4c0a; }
.acct-reaccept p { margin: 6px 0 10px; font-size: 13px; color: #6b5a3a; }
.acct-legal-links { display: flex; flex-wrap: wrap; gap: 6px 16px; }
.acct-legal-links a { font-size: 13.5px; color: var(--pink, #d4537e); text-decoration: none; }
.acct-legal-links a:hover { text-decoration: underline; }
.res-note-hint { font-size: 11.5px; color: #8b929b; margin: 4px 2px 0; line-height: 1.35; }

/* =============================================================================
   Park Hopper — wizard route cards, timeline segment dividers + transfer card
   ============================================================================= */
.hop-routes { display: flex; flex-direction: column; gap: 8px; margin: 8px 0 2px; }
.hop-route { text-align: left; width: 100%; background: var(--card); border: 1.5px solid var(--line); border-radius: 12px; padding: 10px 12px; cursor: pointer; font: inherit; transition: border-color .15s ease, box-shadow .15s ease; }
.hop-route:hover { border-color: var(--pink100); }
.hop-route.is-sel { border-color: var(--pink); box-shadow: 0 0 0 2px var(--pink50); }
.hop-route-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.hop-route-name { font-weight: 700; font-size: 14px; color: var(--ink); display: inline-flex; align-items: center; gap: 6px; }
.hop-rec { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; background: var(--pink50); color: var(--pinkd); border-radius: 999px; padding: 2px 8px; }
.hop-route-meta { font-size: 12.5px; color: var(--ink2); margin-top: 3px; }
.hop-route-sub { font-size: 12px; color: var(--ink3); margin-top: 2px; }
.hop-route-why { font-size: 12px; color: var(--pinkd); margin-top: 5px; }

.seg-divider { display: flex; align-items: center; gap: 8px; padding: 16px 4px 6px; font-weight: 800; color: var(--ink); }
.seg-divider .seg-ico { width: 26px; height: 26px; border-radius: 8px; background: var(--pink50); color: var(--pink); display: inline-flex; align-items: center; justify-content: center; font-size: 15px; }
.seg-divider .seg-name { font-size: 14px; }
.seg-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); margin-left: 4px; }

.transfer-card { background: linear-gradient(180deg, #eef4fb, #f7fafd); border: 1.5px dashed var(--blue); border-radius: 14px; padding: 11px 13px; margin: 4px 0; }
.transfer-top { display: flex; align-items: center; gap: 10px; }
.transfer-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--blue50); color: var(--blue800); display: inline-flex; align-items: center; justify-content: center; font-size: 18px; flex: 0 0 auto; }
.transfer-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.transfer-main strong { font-size: 14px; color: var(--ink); }
.transfer-sub { font-size: 12px; color: var(--ink2); margin-top: 1px; }
.transfer-badge { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; background: #dfe9f4; color: var(--blue800); border-radius: 999px; padding: 2px 7px; align-self: flex-start; }
.transfer-badge.warn { background: var(--amb50); color: var(--amb); }
.transfer-legs { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 5px; margin-top: 8px; font-size: 11px; color: var(--ink3); }
.transfer-legs .ti { font-size: 12px; color: var(--ink3); }

/* Park Hopper — in-transit banner + legacy-repair notice */
.transit-banner { background: linear-gradient(180deg, #fff6e9, #fffdf8); border: 1.5px solid var(--amb); border-radius: 14px; padding: 13px 14px; margin: 4px 0 10px; }
.transit-head { display: flex; align-items: center; gap: 10px; }
.transit-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--amb50); color: var(--amb); display: inline-flex; align-items: center; justify-content: center; font-size: 18px; flex: 0 0 auto; }
.transit-head strong { font-size: 14.5px; color: var(--ink); display: block; }
.transit-sub { font-size: 12.5px; color: var(--ink2); }
.transit-actions { display: flex; gap: 8px; margin-top: 11px; flex-wrap: wrap; }
.transit-btn { flex: 1 1 auto; border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 999px; padding: 9px 14px; font: inherit; font-size: 13px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.transit-btn.primary { background: var(--pink); border-color: var(--pink); color: #fff; }
.transit-btn.primary:hover { background: var(--pinkd); }
.transit-btn:not(.primary):hover { border-color: var(--amb); }
.transit-note { font-size: 11.5px; color: var(--ink3); margin-top: 8px; }

.hop-repair { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.hop-repair .repair-save { flex: 0 0 auto; border: 1px solid currentColor; background: transparent; color: inherit; border-radius: 999px; padding: 6px 12px; font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; }

/* ---------------- Download Backup Plan ---------------- */
.btn.sm { padding: 8px 14px; font-size: 13px; border-radius: 10px; }
.bk-lead { font-size: 13px; color: var(--ink2); margin: 4px 0 12px; line-height: 1.45; }
.bk-group { display: flex; flex-direction: column; gap: 8px; }
.bk-opt { text-align: left; border: 1.5px solid var(--line); background: var(--card); border-radius: 14px; padding: 12px 14px; cursor: pointer; display: flex; flex-direction: column; gap: 3px; font: inherit; transition: border-color .15s, background .15s; }
.bk-opt:hover { border-color: var(--pink100); }
.bk-opt.on { border-color: var(--pink); background: var(--pink50); }
.bk-opt-t { font-weight: 700; font-size: 14px; color: var(--ink); display: flex; align-items: center; gap: 7px; }
.bk-opt-t i { color: var(--pink); }
.bk-opt-d { font-size: 12px; color: var(--ink3); line-height: 1.4; }
.bk-paper { display: flex; align-items: center; justify-content: space-between; margin-top: 12px; font-size: 13px; color: var(--ink2); font-weight: 600; }
.bk-seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.bk-seg button { border: 0; background: var(--card); color: var(--ink2); font: inherit; font-size: 13px; padding: 7px 14px; cursor: pointer; }
.bk-seg button.on { background: var(--pink); color: #fff; font-weight: 700; }
.bk-warn { display: flex; gap: 8px; align-items: flex-start; background: #fff4e6; border: 1px solid #f4d7ad; color: #8a5a12; border-radius: 12px; padding: 10px 12px; font-size: 12.5px; line-height: 1.4; margin-top: 12px; }
.bk-warn i { margin-top: 1px; }

.backup-note { display: flex; align-items: center; gap: 10px; border-radius: 14px; padding: 12px 14px; margin: 0 0 12px; }
.backup-note.changed { background: var(--pink50); border: 1px solid var(--pink100); }
.backup-note.prompt { background: #eef3fb; border: 1px solid #d5e2f5; }
.backup-note .bn-body { flex: 1; display: flex; flex-direction: column; gap: 2px; font-size: 12.5px; color: var(--ink2); line-height: 1.4; }
.backup-note .bn-body b { color: var(--ink); font-size: 13px; }
.backup-note .bn-actions { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.bn-x { border: 0; background: transparent; color: var(--ink3); font-size: 20px; line-height: 1; cursor: pointer; padding: 2px 4px; }
.bn-x:hover { color: var(--ink); }

.planner-toast { position: fixed; left: 50%; bottom: 84px; transform: translateX(-50%) translateY(12px); background: var(--ink); color: #fff; padding: 11px 18px; border-radius: 999px; font-size: 13px; font-weight: 600; box-shadow: 0 8px 24px rgba(0,0,0,.22); opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; z-index: 60; max-width: 88vw; text-align: center; }
.planner-toast.on { opacity: 1; transform: translateX(-50%) translateY(0); }
@media (prefers-reduced-motion: reduce) { .planner-toast { transition: opacity .2s; } }
