/* WYD — "paper and ink" retro theme: cream paper, black ink outlines, one pink main colour and a mint
   highlight. Pink = buttons, your messages, the selected tab. Mint = good news ("It's on!", plans on the
   map). Red only for safety and errors. Dark mode flips paper to navy and ink to cream (see the bottom
   of this block); it follows the phone unless My Profile says otherwise (data-theme on <html>). */

@import url("https://fonts.googleapis.com/css2?family=Nunito:wght@500;700;800;900&family=VT323&display=swap");

:root, [data-theme="light"] {
  --bg: #fbf6ea;           /* the paper */
  --card: #ffffff;         /* raised things: inputs, cards, popups */
  --sunk: #f3ecda;         /* tinted strips, the map before it loads */
  --hover: #f1e9d4;
  --ink: #1b1b1b;          /* outlines + strong text */
  --text: #1b1b1b;
  --muted: #7a7366;
  --line: #d8ceb6;         /* soft lines inside a screen */
  --accent: #ff5fa2;       /* pink: main buttons, your bubbles, selection */
  --accent-hover: #ff7cb3;
  --on-accent: #1b1b1b;
  --accent-soft: #ffe3ef;
  --accent-line: #f5a9c9;
  --accent-text: #c2185b;  /* pink that reads as text on paper */
  --hi: #3ddc97;           /* mint: good news */
  --on-hi: #1b1b1b;
  --hi-soft: #d8f6e8;
  --hi-line: #8fe3bd;
  --hi-text: #0f7a4c;
  --danger: #e0303a;
  --danger-soft: #ffe3e3;
  --danger-line: #f3b4b6;
  --shadow: rgba(27, 27, 27, .14);
  --scrim: rgba(27, 27, 27, .35);
  --attr-bg: rgba(251, 246, 234, .8);
  --icon-ink: #1b1b1b;
  --tiles-filter: saturate(.6) brightness(1.04) contrast(.94);

  /* older names, kept so every rule keeps working */
  --title: var(--bg); --title-fg: var(--ink); --face: var(--bg); --face-2: var(--sunk); --paper: var(--card);
  --navy: var(--accent); --yellow: var(--accent); --yellow-dark: var(--accent-text); --green: var(--hi); --red: var(--danger);
  --select: var(--accent); --link: var(--accent-text); --sn-me: var(--accent-text); --sn-them: var(--hi-text);
  --desk: var(--bg); --page: var(--bg); --frame: var(--sunk);

  --r-lg: 14px;
  --r-md: 10px;
  --r-sm: 7px;
  --font: "Nunito", "Varela Round", "Arial Rounded MT Bold", "Helvetica Rounded", system-ui, sans-serif;
  --pixel: "VT323", ui-monospace, monospace;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  --pop: 0 3px 0 var(--ink);  /* chunky sticker drop */
  color-scheme: light;
}
/* Dark: navy paper, cream ink. On any element, so the mockups page can show a screen in dark. */
[data-theme="dark"] {
  --bg: #14161f; --card: #1d2030; --sunk: #191c28; --hover: #262a3d;
  --ink: #f1ead8; --text: #f1ead8; --muted: #9a9686; --line: #343a52;
  --accent-soft: #3f2233; --accent-line: #8a3a62; --accent-text: #ff8cbf;
  --hi-soft: #16352a; --hi-line: #2b7a59; --hi-text: #6ff0b8;
  --danger: #ff5a5f; --danger-soft: #45212a; --danger-line: #8a3a42;
  --shadow: rgba(0, 0, 0, .45); --scrim: rgba(0, 0, 0, .55); --attr-bg: rgba(20, 22, 31, .8);
  --icon-ink: #f1ead8; --tiles-filter: none;
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #14161f; --card: #1d2030; --sunk: #191c28; --hover: #262a3d;
    --ink: #f1ead8; --text: #f1ead8; --muted: #9a9686; --line: #343a52;
    --accent-soft: #3f2233; --accent-line: #8a3a62; --accent-text: #ff8cbf;
    --hi-soft: #16352a; --hi-line: #2b7a59; --hi-text: #6ff0b8;
    --danger: #ff5a5f; --danger-soft: #45212a; --danger-line: #8a3a42;
    --shadow: rgba(0, 0, 0, .45); --scrim: rgba(0, 0, 0, .55); --attr-bg: rgba(20, 22, 31, .8);
    --icon-ink: #f1ead8; --tiles-filter: none;
    color-scheme: dark;
  }
}
/* Light forced inside a dark page (mockups). */
[data-theme="light"] { color-scheme: light; }

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--page); font: 500 13px/1.4 var(--font); color: var(--text); }

/* ---------- page layout (index.html) ---------- */
.page { min-height: 100%; display: flex; gap: 28px; align-items: flex-start; justify-content: center; padding: 28px 16px; flex-wrap: wrap; }
#dev { width: 270px; }
@media (max-width: 700px) {
  .page { padding: 0; gap: 0; }
  .page > #root { width: 100%; }
  .page > #root .screen { width: 100%; height: 100dvh; border: 0; border-radius: 0; box-shadow: none; }
  /* Installed on a phone: keep the title bar clear of the notch and the taskbar clear of the home bar. */
  .page > #root .main-window > .title-bar { padding-top: max(10px, env(safe-area-inset-top)); }
  .page > #root .taskbar { height: auto; padding-bottom: max(10px, env(safe-area-inset-bottom)); }
  #dev { width: 100%; padding: 12px 16px 24px; }
  /* Hosted on Netlify's free plan: its badge gets its own strip below the taskbar (see app.js). */
  .host-badge .page > #root .screen { height: calc(100dvh - 60px); }
  .host-badge .page > #root .taskbar { padding-bottom: 10px; }
}
/* The dev panel is for the demo in a desktop browser, not the installed app. */
@media (display-mode: standalone) { #dev { display: none; } }

/* ---------- the "phone" ---------- */
.screen {
  width: 390px; height: 780px; position: relative; overflow: hidden;
  display: flex; flex-direction: column; background: var(--desk);
  border: 2px solid var(--ink); border-radius: 26px; box-shadow: 0 18px 40px var(--shadow);
}
.desktop { position: relative; flex: 1; min-height: 0; display: flex; flex-direction: column; }

/* ---------- windows ---------- */
/* Floating windows (dialogs, start menu, dev panel) get a frame; the main window fills the phone. */
.window {
  background: var(--card); border: 2px solid var(--ink); border-radius: var(--r-lg);
  box-shadow: 0 10px 30px var(--shadow); overflow: hidden;
}
.main-window { flex: 1; min-height: 0; display: flex; flex-direction: column; border: 0; border-radius: 0; box-shadow: none; }
.title-bar {
  padding: 10px 12px 10px 14px; background: var(--title); border-bottom: 2px solid var(--ink);
  display: flex; align-items: center; justify-content: space-between; gap: 6px; flex: none;
}
.title-extra { flex: none; }
.title-bar-text { color: var(--title-fg); font: 400 21px/1 var(--pixel); display: flex; align-items: center; gap: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.menu-bar { display: flex; gap: 4px; padding: 6px 8px; border-bottom: 1.5px solid var(--line); flex: none; }
.menu-bar a { color: var(--ink); font-weight: 800; text-decoration: none; padding: 2px 9px; border-radius: 999px; }
.menu-bar a:hover { background: var(--accent); color: var(--on-accent); }
.window-body {
  background: var(--face); padding: 12px; flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 12px;
}
.status-bar { display: flex; gap: 4px; padding: 5px 12px 6px; border-top: 1.5px solid var(--line); flex: none; }
.status-bar-field {
  margin: 0; flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  font-size: 11px; font-weight: 700; color: var(--muted);
}

/* ---------- controls ---------- */
/* Secondary buttons: thin pale outline. The yellow .default button is the one chunky sticker per screen. */
button, .btn {
  font: 800 13px var(--font); color: var(--ink); background: var(--card);
  border: 1.5px solid var(--line); border-radius: var(--r-md); box-shadow: none;
  min-height: 32px; padding: 4px 12px; display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  text-decoration: none; cursor: pointer; white-space: nowrap; transition: transform .05s, box-shadow .05s, background .1s;
}
button:hover:not(:disabled), .btn:hover { background: var(--hover); border-color: var(--ink); }
button:active:not(:disabled), .btn:active { transform: translateY(1px); }
button.default:active:not(:disabled), .btn.default:active { transform: translateY(2px); box-shadow: 0 0 0 var(--ink); }
button:focus-visible, .btn:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--hi); outline-offset: 1px; }
button.default, .btn.default { background: var(--yellow); border: 2px solid var(--ink); box-shadow: 0 2px 0 var(--ink); }
button.default:hover:not(:disabled), .btn.default:hover { background: var(--accent-hover); }
button.default, .btn.default { color: var(--on-accent); }
.btn.default { color: var(--on-accent) !important; }
button:disabled { color: var(--muted); border-color: var(--line); box-shadow: none; background: var(--face-2); cursor: default; }
button.danger { color: var(--red); }
button.default.danger { background: var(--red); color: #fff; }
button.danger:not(.default) { border-color: var(--danger-line); }
input, select, textarea {
  font: 600 13px var(--font); background: var(--paper); color: var(--text);
  border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 5px 9px; min-height: 34px; max-width: 100%;
}
input:focus, select:focus, textarea:focus { border-color: var(--ink); }
input::placeholder { color: var(--muted); }
input:disabled, select:disabled { background: var(--face); color: var(--muted); }
input[type="file"] { background: transparent; border: 0; padding: 0; min-height: 0; }
input[type="radio"], input[type="checkbox"] { min-height: 0; margin: 0 4px 0 0; accent-color: var(--accent); width: 15px; height: 15px; }
a { color: var(--link); font-weight: 700; }
/* Form sections read as headings, not boxes. Fieldsets that are meant to be a box opt in with .boxed. */
fieldset { border: 0; padding: 0; margin: 0; min-width: 0; }
legend { padding: 0 0 5px; font-weight: 900; font-size: 12px; color: var(--ink); }
fieldset.boxed { border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 8px 10px 10px; }
fieldset.boxed > legend { padding: 0 5px; }
.sunken { background: var(--paper); border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 3px; }
hr { border: 0; border-top: 1.5px solid var(--face-2); margin: 4px 6px; }

.field { display: flex; flex-direction: column; gap: 3px; font-weight: 700; }
.field + .field { margin-top: 8px; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.toolbar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.toolbar.big > * { flex: 1; min-height: 38px; }
.toolbar.wrap { flex-wrap: wrap; }
.check, .radio { display: flex; align-items: center; gap: 5px; padding: 3px 0; font-weight: 600; }
.checks { max-height: 190px; overflow-y: auto; padding: 4px 8px; }
.muted { color: var(--muted); }
.pad { padding: 8px; }
.fine { font-size: 11.5px; color: var(--muted); margin: 0; }
.right-link { text-align: right; margin-top: 4px; }
small { font-size: 11.5px; }
.big { font-size: 17px; font-weight: 900; }
h2 { font-size: 16px; font-weight: 900; color: var(--ink); margin: 0 0 6px; }
p { margin: 0 0 6px; }

.icon { flex: none; vertical-align: -3px; overflow: visible; }
.avatar { display: inline-block; flex: none; border: 1.5px solid var(--ink); border-radius: 50%; overflow: hidden; background: var(--card); line-height: 0; }
.avatar svg, .avatar img { width: 100%; height: 100%; display: block; object-fit: cover; }
.avatar.blank { background: var(--face-2); border-color: var(--line); }

/* ---------- taskbar + start menu ---------- */
.taskbar {
  flex: none; height: 56px; background: var(--bg); border-top: 2px solid var(--ink);
  display: flex; align-items: center; gap: 4px; padding: 8px 8px 10px;
}
.start-btn { min-width: 0; width: 36px; padding: 0; height: 36px; flex: none; background: var(--yellow); border: 2px solid var(--ink); box-shadow: 0 2px 0 var(--ink); border-radius: 50%; }
.start-btn b { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); } /* icon-only, label kept for screen readers */
.start-btn.active { transform: translateY(2px); box-shadow: none; }
.task-btn {
  position: relative; flex: 1; min-width: 0; height: 40px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1px; padding: 2px 4px;
  background: none; border-radius: 999px; color: var(--muted); font-weight: 800; font-size: 11px; line-height: 1.1; text-decoration: none;
}
.task-btn:hover { color: var(--ink); }
.task-btn .count { position: absolute; top: -3px; right: 10%; font-style: normal; font-size: 10px; line-height: 15px; min-width: 17px; padding: 0 4px; text-align: center; color: #fff; background: var(--red); border-radius: 999px; }
.task-btn span { max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.task-btn.active { background: var(--accent); color: var(--on-accent); border: 1.5px solid var(--ink); }
.tray { flex: none; height: 30px; display: flex; align-items: center; gap: 4px; padding: 0 8px; font: 400 17px/1 var(--pixel); color: var(--muted); background: none; border-radius: 999px; border: 0; }
.tray .icon { display: none; }
.start-menu { position: absolute; left: 8px; bottom: 6px; z-index: 30; display: flex; width: 240px; padding: 5px; overflow: hidden; }
.start-side { background: var(--navy); width: 30px; display: flex; align-items: flex-end; justify-content: center; padding: 8px 0; border-radius: var(--r-md); }
.start-side span { writing-mode: vertical-rl; transform: rotate(180deg); color: var(--on-accent); font-size: 16px; font-weight: 900; letter-spacing: .5px; }
.start-side b { color: var(--card); }
.start-items { flex: 1; display: flex; flex-direction: column; padding: 2px 0 2px 4px; background: var(--face); margin-left: 4px; }
.start-item { display: flex; align-items: center; gap: 9px; padding: 6px 8px; color: var(--text); font: 700 13px var(--font); text-decoration: none; background: none; border: 0; box-shadow: none; justify-content: flex-start; min-height: 0; width: 100%; text-align: left; border-radius: var(--r-sm); }
.start-item:hover:not(.disabled) { background: var(--select); color: var(--on-accent); }
.start-item.disabled { color: var(--muted); }
button.start-item:active { transform: none; }

/* ---------- dialogs + balloons ---------- */
.overlay { position: absolute; inset: 0; z-index: 40; display: flex; align-items: center; justify-content: center; padding: 16px; background: var(--scrim); }
.dialog { width: 100%; max-width: 330px; max-height: 100%; display: flex; flex-direction: column; }
.dialog .window-body { padding: 14px; }
.dialog-content { display: flex; gap: 12px; align-items: flex-start; }
.dialog-buttons { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 8px; }
.balloon {
  position: absolute; right: 12px; bottom: 12px; z-index: 35; width: 260px; background: var(--card); border: 2px solid var(--ink);
  border-radius: var(--r-lg); padding: 9px 11px; box-shadow: 0 10px 30px var(--shadow); display: flex; flex-direction: column; gap: 4px;
}
.balloon-title { font-weight: 900; color: var(--ink); display: flex; align-items: center; gap: 5px; }
.balloon-x { margin-left: auto; min-width: 0; min-height: 0; padding: 0 6px; background: none; border: 0; box-shadow: none; font-size: 15px; }
.balloon-push { background: var(--danger-soft); border-color: var(--red); }
.balloon-push .balloon-title { color: var(--red); }

/* ---------- buddy list ---------- */
.me-card {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; color: var(--on-accent);
  background: var(--navy); border: 2px solid var(--ink); border-radius: var(--r-lg); box-shadow: 0 2px 0 var(--ink);
}
.me-card small { color: var(--on-accent); }
.logo-small { margin-left: auto; font: 400 30px/1 var(--pixel); color: var(--on-accent); }
.notice { display: flex; align-items: center; gap: 7px; padding: 8px 10px; background: var(--accent-soft); border: 1.5px solid var(--accent-line); border-radius: var(--r-md); color: var(--text); text-decoration: none; font-weight: 600; }
.tree { flex: 1; min-height: 140px; overflow-y: auto; padding: 6px; }
.tree summary { font-weight: 900; color: var(--ink); cursor: pointer; padding: 3px 4px; list-style: none; }
.tree summary::-webkit-details-marker { display: none; }
.tree summary::before { content: "▸ "; font-size: 11px; }
.tree details[open] summary::before { content: "▾ "; }
.tree-row { display: flex; align-items: center; gap: 7px; padding: 4px 6px 4px 18px; margin: 1px 0; color: var(--text); font-weight: 700; text-decoration: none; border-radius: var(--r-sm); }
.tree-row:hover { background: var(--hover); }
.tree-row.selected { background: var(--select); color: var(--on-accent); }
.tree-row.selected small { color: var(--on-accent); }
.tree-empty { padding: 3px 18px; color: var(--muted); }

/* ---------- compose + plan ---------- */
.to-row { display: flex; align-items: center; gap: 5px; flex-wrap: wrap; }
.to-row .lbl { font-weight: 900; color: var(--ink); margin-right: 2px; }
.im-preview { padding: 10px 12px; font-size: 14px; }
.im-msg { font-weight: 800; color: var(--text); }
.sn { font-weight: 900; }
.sn-me { color: var(--sn-me); }
.sn-them { color: var(--sn-them); }
.when-row { display: flex; gap: 8px; }
.when-row select { flex: 1; }
.listbox { overflow-y: auto; max-height: 230px; padding: 0; }
.listbox.tall { max-height: none; flex: 1; }
.list-heading { background: var(--face-2); color: var(--ink); padding: 4px 10px; font-weight: 900; font-size: 12px; position: sticky; top: 0; z-index: 1; }
.place-opt { display: flex; align-items: flex-start; gap: 4px; padding: 7px 8px; margin: 3px; cursor: pointer; border-radius: var(--r-sm); }
.place-opt:hover { background: var(--hover); }
.place-opt:has(input:checked) { background: var(--select); color: var(--on-accent); }
.place-opt:has(input:checked) small, .place-opt:has(input:checked) .badge { color: var(--on-accent); border-color: var(--on-accent); background: transparent; }
.place-opt input { margin-top: 2px; }
.place-opt-main { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 6px; }
.place-opt-main small { flex-basis: 100%; padding-left: 20px; }
.badge { display: inline-flex; align-items: center; gap: 3px; font-size: 10.5px; font-weight: 800; border: 1px solid var(--line); border-radius: 999px; padding: 0 7px; background: var(--card); white-space: nowrap; }
.badge-spot, .badge-age { color: var(--accent-text); border-color: var(--accent-line); background: var(--accent-soft); }
.badge-deal { color: var(--hi-text); border-color: var(--hi-line); background: var(--hi-soft); }

.roster { display: flex; flex-wrap: wrap; gap: 4px; }
.chip { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px 1px 1px; background: var(--card); border: 1px solid var(--line); border-radius: 999px; font-weight: 700; font-size: 11.5px; }
.chip-in { background: var(--hi-soft); border-color: var(--hi-line); }
.current { display: flex; flex-direction: column; gap: 4px; background: var(--paper); border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 8px 10px 10px; }
.current > legend { padding: 0 5px; }
.current-when, .current-where { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.current-when b { font-size: 16px; font-weight: 900; color: var(--ink); }
.current.expired, .current.cancelled, .current.declined, .current.superseded { opacity: .6; }
.banner { padding: 8px 10px; display: flex; align-items: center; gap: 7px; border: 1.5px solid var(--accent-line); background: var(--accent-soft); border-radius: var(--r-md); font-weight: 600; }
.banner-on { background: var(--hi-soft); border-color: var(--hi-line); }
.banner-expired, .banner-cancelled, .banner-declined, .banner-superseded { background: var(--face-2); border-color: var(--line); }
.status-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.status-grid button { min-width: 0; padding-left: 4px; padding-right: 4px; }
.wearing-row { display: flex; gap: 8px; align-items: center; font-weight: 700; }
.wearing-row input { flex: 1; min-width: 0; }
.limit { background: var(--accent-soft); border: 1.5px solid var(--accent-line); border-radius: var(--r-md); padding: 8px 10px 10px; }
.limit > legend { padding: 0 5px; }
/* Forms whose place list should soak up the spare height (compose). */
.fill { flex: 1; min-height: 0; }
.fill .grow { flex: 1; min-height: 120px; display: flex; flex-direction: column; }
.fill .grow .listbox { max-height: none; flex: 1; }

/* ---------- lists ---------- */
.plan-row { display: flex; align-items: center; gap: 9px; padding: 8px; margin: 3px; color: var(--text); text-decoration: none; border-radius: var(--r-sm); }
.plan-row + .plan-row { margin-top: 0; }
.plan-row:hover { background: var(--hover); }
.plan-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.plan-main b { font-weight: 800; }
.plan-main small { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pill { font-size: 10.5px; font-weight: 800; padding: 1px 8px; border: 1px solid var(--line); border-radius: 999px; background: var(--card); color: var(--ink); white-space: nowrap; }
.pill-on { background: var(--hi); border-color: var(--hi); color: var(--on-hi); }
.pill-pending { background: var(--accent-soft); border-color: var(--accent-line); }
.pill-expired, .pill-cancelled, .pill-declined, .pill-superseded { background: var(--face-2); border-color: var(--line); color: var(--muted); }
.person-row { display: flex; align-items: center; gap: 9px; padding: 7px 8px; border-bottom: 1.5px solid var(--face); }
.person-row:last-child { border-bottom: 0; }
.person-row > span:not(.avatar) { flex: 1; min-width: 0; }

/* ---------- tabs ---------- */
.tabs { display: flex; gap: 4px; padding-left: 8px; margin-bottom: -12px; position: relative; z-index: 1; }
.tab { padding: 5px 14px 6px; color: var(--muted); font-weight: 800; text-decoration: none; background: var(--face-2); border: 1.5px solid var(--line); border-bottom: 0; border-radius: var(--r-md) var(--r-md) 0 0; margin-top: 3px; }
.tab.active { margin-top: 0; padding-bottom: 9px; background: var(--paper); color: var(--ink); position: relative; z-index: 2; }
.tab-panel { background: var(--paper); border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 12px 10px; display: flex; flex-direction: column; gap: 10px; }
.search-row { display: flex; gap: 8px; }
.search-row input { flex: 1; min-width: 0; }
.qr-wrap { display: flex; gap: 12px; align-items: center; }
.qr { padding: 6px; line-height: 0; }
code { font-family: var(--mono); background: var(--face); padding: 1px 5px; border-radius: 4px; }

/* ---------- profile ---------- */
.profile-head { display: flex; gap: 12px; align-items: center; }

/* ---------- signup wizard ---------- */
.wizard { display: flex; flex-direction: column; gap: 10px; }
.wizard-art {
  background: var(--navy); color: var(--on-accent); border: 2px solid var(--ink); box-shadow: 0 2px 0 var(--ink); padding: 14px 16px; display: flex; align-items: center; gap: 14px;
  border-radius: var(--r-lg);
}
.logo-big { font: 400 52px/1 var(--pixel); color: var(--card); -webkit-text-stroke: 1.5px var(--ink); text-shadow: 0 3px 0 var(--ink); }
.logo-sub { font: 900 15px var(--font); line-height: 1.1; }
.logo-sub small { color: var(--on-accent); }
.wizard-buttons { display: flex; justify-content: flex-end; gap: 8px; padding-top: 4px; }

/* ---------- dev panel ---------- */
.dev-window .title-bar { background: var(--navy); }
.dev-window .window-body { flex: none; }
.dev-window .toolbar button, .dev-window .toolbar .btn { min-width: 0; padding: 3px 9px; }

/* ---------- mockups gallery ---------- */
.gallery-head { color: var(--ink); padding: 20px 24px 0; max-width: 1400px; margin: 0 auto; }
.gallery-head h1 { font: 900 24px var(--font); margin: 0 0 6px; }
.gallery-head a { color: var(--link); }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(390px, 1fr)); gap: 32px; padding: 20px 24px 48px; max-width: 1400px; margin: 0 auto; justify-items: center; }
.mock { display: flex; flex-direction: column; gap: 10px; }
.mock-label { background: var(--card); border: 1.5px solid var(--line); border-radius: var(--r-md); padding: 6px 10px; font-weight: 900; color: var(--ink); }
.mock-label small { font-weight: 600; color: var(--muted); display: block; }
.mock .screen { pointer-events: none; }
@media (max-width: 440px) {
  .gallery { grid-template-columns: 1fr; padding: 16px 0; }
  .mock .screen { width: 100vw; }
}

/* ---------- map (home screen) ---------- */
.window-body.flush { padding: 0; overflow: hidden; }
.map-wrap { position: relative; flex: 1; min-height: 0; display: flex; overflow: hidden; }
.map-host, .map-slot { flex: 1; min-height: 0; background: var(--sunk); }
.map-host .leaflet-tile-pane, .pick-map .leaflet-tile-pane { filter: var(--tiles-filter); } /* calm the tiles down */
.map-host.picking { cursor: crosshair; }
.map-host.picking .leaflet-grab { cursor: crosshair; }
.map-top { position: absolute; top: 8px; left: 8px; right: 8px; z-index: 500; display: flex; flex-direction: column; gap: 6px; pointer-events: none; }
.map-top > * { pointer-events: auto; }
.map-card {
  display: flex; align-items: center; gap: 8px; padding: 7px 10px; background: var(--accent-soft); color: var(--text); font-weight: 600;
  border: 1.5px solid var(--ink); border-radius: var(--r-md); box-shadow: 0 2px 0 var(--ink); text-decoration: none;
}
.map-card span { flex: 1; min-width: 0; }
.map-card.on { background: var(--hi-soft); }
.map-card.pick { background: var(--card); }
.map-card .btn { min-height: 26px; padding: 2px 10px; }
.map-bottom { position: absolute; left: 8px; right: 8px; bottom: 20px; z-index: 500; display: flex; align-items: flex-end; justify-content: space-between; gap: 6px; pointer-events: none; }
.map-bottom > * { pointer-events: auto; }
.layer-chips { display: flex; flex-wrap: wrap; gap: 4px; }
.layer-chip { min-height: 28px; padding: 2px 9px 2px 6px; border-radius: 999px; font-size: 12px; background: var(--card); color: var(--muted); border-color: var(--line); }
.layer-chip.on { color: var(--ink); border-color: var(--ink); background: var(--card); }
.layer-chip:not(.on) .icon { opacity: .4; }
.map-actions { display: flex; flex-direction: column; align-items: flex-end; gap: 6px; }
button.round { width: 38px; height: 38px; min-width: 0; padding: 0; border-radius: 50%; background: var(--card); }
.map-offline { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; color: var(--muted); height: 100%; }
.map-offline p { margin-top: 8px; }

/* Leaflet chrome, re-skinned to match */
.leaflet-container { font: 500 13px var(--font); background: var(--sunk); }
.leaflet-bottom.leaflet-right { margin-bottom: 104px; }
.leaflet-bar { border: 1.5px solid var(--ink) !important; border-radius: var(--r-md) !important; box-shadow: none !important; overflow: hidden; }
.leaflet-bar a { color: var(--ink) !important; background: var(--card) !important; border-color: var(--line) !important; font-weight: 900; }
.leaflet-control-attribution { font-size: 9px; line-height: 14px; background: var(--attr-bg) !important; color: var(--muted); border-radius: 0 6px 0 0; }
.leaflet-control-attribution a { font-weight: 600; }
.mk-wrap { background: none; border: 0; }
.mk { position: absolute; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; cursor: pointer; }
.mk .avatar { border-radius: 50%; border-width: 2.5px; box-shadow: 0 2px 0 var(--ink); }
.mk-me .avatar { outline: 3px solid var(--yellow); outline-offset: 1px; }
.mk-me::before { content: ""; position: absolute; top: 50%; left: 50%; width: 64px; height: 64px; margin: -50px 0 0 -32px; border-radius: 50%; background: color-mix(in srgb, var(--accent) 30%, transparent); animation: qq-pulse 2.2s ease-out infinite; z-index: -1; }
@keyframes qq-pulse { from { transform: scale(.4); opacity: 1; } to { transform: scale(1.2); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .mk-me::before { animation: none; } }
.mk-label { margin-top: 2px; padding: 0 6px; font-size: 11px; font-weight: 800; color: var(--ink); background: var(--card); border: 1.5px solid var(--ink); border-radius: 999px; white-space: nowrap; }
.mk-me .mk-label { background: var(--accent); color: var(--on-accent); border-color: #1b1b1b; }
.mk-spot, .mk-saved { width: 32px; height: 32px; justify-content: center; border: 2.5px solid #1b1b1b; border-radius: 50%; box-shadow: 0 2px 0 #1b1b1b; }
.mk-spot { background: var(--navy); }
.mk-saved { background: #fff; }
.mk-has-plan { outline: 3px solid var(--green); outline-offset: 1px; }
.mk-plan { position: absolute; top: 100%; margin-top: 4px; padding: 0 6px; font-size: 10.5px; font-weight: 900; color: var(--on-hi); background: var(--hi); border: 1.5px solid #1b1b1b; border-radius: 999px; white-space: nowrap; }
.qq-popup .leaflet-popup-content-wrapper { background: var(--card); color: var(--text); border: 1.5px solid var(--ink); border-radius: var(--r-lg); box-shadow: 0 8px 24px var(--shadow); }
.qq-popup .leaflet-popup-tip { background: var(--card); border: 1.5px solid var(--ink); box-shadow: none; }
.qq-popup .leaflet-popup-content { margin: 10px 12px; font: 500 13px/1.4 var(--font); color: var(--text); }
.qq-popup .leaflet-popup-content p { margin: 4px 0 0; }
.pop-head { display: flex; gap: 8px; align-items: center; }
.pop-head .avatar { border-radius: 50%; }
.pop-badges { display: flex; flex-wrap: wrap; gap: 3px; margin-top: 4px; }
.pop-plan { display: flex; align-items: center; gap: 4px; margin-top: 6px; padding: 4px 8px; background: var(--hi-soft); border: 1.5px solid var(--hi); border-radius: var(--r-sm); color: var(--text); text-decoration: none; font-size: 12px; }
.pop-actions { display: flex; gap: 6px; margin-top: 8px; }
.pop-actions .btn { min-height: 28px; padding: 2px 10px; font-size: 12px; }
.qq-popup a.btn { color: var(--ink); }
.listbox.short { max-height: 150px; }

/* ---------- discover mode ---------- */
.mode-toggle { align-self: center; display: inline-flex; padding: 2px; gap: 2px; background: var(--card); border: 1.5px solid var(--ink); border-radius: 999px; box-shadow: 0 2px 0 var(--ink); }
.mode-toggle a { display: inline-flex; align-items: center; gap: 5px; padding: 3px 12px; border-radius: 999px; color: var(--ink); font-weight: 800; text-decoration: none; }
.mode-toggle a.on { background: var(--accent); color: var(--on-accent); }
.mode-toggle a:not(.on):hover { background: var(--face-2); }

/* activity pills: display, filter links, and radio/checkbox choices */
.act { display: inline-flex; align-items: center; gap: 4px; padding: 1px 9px 1px 5px; font-size: 12px; font-weight: 800; color: var(--ink); background: var(--card); border: 1.5px solid var(--line); border-radius: 999px; white-space: nowrap; text-decoration: none; }
.act-strong { border-color: var(--ink); background: var(--accent-soft); }
a.act:hover { border-color: var(--ink); }
a.act.act-on { background: var(--accent); color: var(--on-accent); border-color: var(--ink); }
.act-filter { display: flex; flex-wrap: wrap; gap: 5px; flex: none; }
.act-row { display: flex; flex-wrap: wrap; gap: 4px; }
.act-choices { display: flex; flex-wrap: wrap; gap: 6px; }
.act-opt { display: inline-flex; align-items: center; gap: 5px; padding: 4px 11px 4px 7px; font-weight: 800; color: var(--ink); background: var(--card); border: 1.5px solid var(--line); border-radius: 999px; cursor: pointer; }
.act-opt input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.act-opt:hover { border-color: var(--ink); }
.act-opt:has(input:checked) { background: var(--select); color: var(--on-accent); border-color: var(--ink); }
.act-opt:has(input:focus-visible) { outline: 3px solid var(--hi); outline-offset: 1px; }
.act-match span::after { content: " ★"; color: var(--yellow-dark); }
.act-opt:has(input:checked).act-match span::after { color: var(--on-accent); }

/* reliability badge */
.rel { color: var(--ink); }
.rel-great { color: var(--hi-text); border-color: var(--hi-line); background: var(--hi-soft); }
.rel-ok { color: var(--accent-text); border-color: var(--accent-line); background: var(--accent-soft); }
.rel-low { color: var(--danger); border-color: var(--danger); background: var(--danger-soft); }
.rel-new { color: var(--muted); border-color: var(--line); background: var(--face-2); }

.person-card { display: flex; gap: 10px; align-items: center; padding: 8px 10px; background: var(--paper); border: 2px solid var(--line); border-radius: var(--r-md); flex: none; }
.person-card .avatar { border-radius: 50%; }
.person-card .badge { margin-top: 2px; }
.free-line { display: flex; align-items: center; gap: 5px; font-size: 12px; margin-top: 3px; }
.banner-hidden { background: var(--face-2); border-color: var(--line); }
.banner > span { flex: 1; }
.banner > button { margin-left: auto; min-height: 26px; padding: 2px 10px; }
.weekly-row { margin-top: 8px; }
.weekly-row { gap: 6px; }
.weekly-row select { flex: none; width: 66px; }
.weekly-row input { flex: 1; min-width: 92px; padding: 5px 4px; }
.weekly-row button { flex: none; padding: 4px 10px; }
.stack.tight { gap: 6px; }
.pill-open { background: var(--accent-soft); border-color: var(--accent-line); }
.pill-full { background: var(--face-2); border-color: var(--line); color: var(--muted); }
.after { background: var(--accent-soft); border: 1.5px solid var(--accent-line); border-radius: var(--r-md); padding: 8px 10px 10px; }
.after > legend { padding: 0 5px; }
.after-row { display: flex; gap: 9px; align-items: flex-start; padding: 4px 0; }
.after-row .avatar { border-radius: 50%; margin-top: 2px; }
.after-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.after-q { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.after-q button { min-height: 26px; padding: 2px 10px; font-size: 12px; }
.after-q .q { font-weight: 800; margin-right: auto; }

/* discover map markers */
.mk-person .avatar { box-shadow: 0 2px 0 #1b1b1b, 0 0 0 3px #fff, 0 0 0 5px var(--hi); }
.mk-hidden .avatar { filter: grayscale(1); opacity: .75; }
.mk-hidden.mk-me::before { display: none; }
.mk-open, .mk-event { width: 32px; height: 32px; justify-content: center; border: 2.5px solid #1b1b1b; border-radius: 50%; box-shadow: 0 2px 0 #1b1b1b; }
.mk-open { background: var(--hi); }
.mk-event { background: #fff; border-radius: 9px; }
.mk-count { position: absolute; top: -9px; right: -14px; padding: 0 5px; font-size: 10.5px; font-weight: 900; color: #1b1b1b; background: #fff; border: 1.5px solid #1b1b1b; border-radius: 999px; white-space: nowrap; }
.mk-when { background: var(--hi); color: var(--on-hi); border-color: #1b1b1b; }
.map-actions .btn { min-height: 32px; }
.map-card span.btn { flex: none; }
/* Never squeeze the "Where" map below a usable size; the window scrolls instead. */
.fill .grow { min-height: auto; } /* as tall as its contents need (map ≥ 170px) */
.pill-done { background: var(--hi-soft); border-color: var(--hi); color: var(--hi-text); }
.map-wrap.discover .leaflet-bottom.leaflet-right { margin-bottom: 150px; }

/* ---------- "Where" picker: search + map ---------- */
.place-picker { display: flex; flex-direction: column; gap: 6px; }
.fill .grow .place-picker { flex: 1; min-height: 0; }
.pick-search { position: relative; flex: none; }
.place-search { width: 100%; }
.place-results {
  position: absolute; top: calc(100% + 3px); left: 0; right: 0; z-index: 600; max-height: 210px; overflow-y: auto;
  background: var(--card); border: 1.5px solid var(--ink); border-radius: var(--r-md); box-shadow: 0 8px 24px var(--shadow); padding: 3px;
}
.place-result {
  display: flex; align-items: flex-start; justify-content: flex-start; gap: 7px; width: 100%; padding: 6px 8px; min-height: 0;
  text-align: left; white-space: normal; background: none; border: 0; box-shadow: none; border-radius: var(--r-sm); font-weight: 600;
}
.place-result span { display: flex; flex-direction: column; min-width: 0; }
.place-result small { color: var(--muted); }
button.place-result:hover, button.place-result:focus-visible { background: var(--hover); }
button.place-result:active { transform: none; }
.pick-map { height: 190px; flex: none; border: 2px solid var(--ink); border-radius: var(--r-md); overflow: hidden; background: var(--sunk); }
.fill .grow .pick-map { flex: 1; height: auto; min-height: 170px; }
.pick-map-slot { height: 190px; }
.pick-map .leaflet-bottom.leaflet-right { margin-bottom: 0; }
.pick-map .mk-spot, .pick-map .mk-saved { width: 28px; height: 28px; }
.mk-saved .icon { margin-top: 1px; }
.mk-picked { outline: 3px solid var(--accent); outline-offset: 2px; }
.mk-picked .mk-label { position: absolute; top: 100%; margin-top: 5px; background: var(--accent); color: var(--on-accent); border-color: #1b1b1b; }
.pick-chosen { display: flex; align-items: flex-start; gap: 6px; flex: none; padding: 6px 8px; background: var(--paper); border: 2px solid var(--line); border-radius: var(--r-md); min-height: 66px; }
.pick-chosen:has(b) { border-color: var(--ink); background: var(--accent-soft); }
.pick-chosen-main { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; min-width: 0; }
.pick-chosen-main small { flex-basis: 100%; color: var(--muted); }
.pick-chosen .icon { margin-top: 1px; }

/* Leaflet's panes and controls use z-index 400–1000. Contain them in the map so the start menu,
   balloons and dialogs (z-index 30–40) always draw on top. */
.map-wrap, .pick-map { isolation: isolate; }

/* ---------- plan screen: an IM chat ---------- */
.title-pill { display: inline-flex; align-items: center; gap: 3px; font-size: 10.5px; font-weight: 800; padding: 1px 8px; border-radius: 999px; background: var(--card); border: 1px solid var(--ink); color: var(--ink); white-space: nowrap; }
.title-pill.rel-great { background: var(--hi-soft); color: var(--hi-text); }
.title-pill.rel-ok { background: var(--accent-soft); color: var(--accent-text); }
.title-pill.rel-low { background: var(--danger-soft); color: var(--danger); }
.title-pill .icon path { stroke: currentColor; }
.window-body.chat-body { padding: 0; gap: 0; overflow: hidden; }
.plan-strip { flex: none; display: flex; flex-direction: column; gap: 4px; padding: 8px 12px; background: var(--bg); border-bottom: 1.5px dashed var(--ink); }
.plan-strip.expired, .plan-strip.cancelled, .plan-strip.declined, .plan-strip.superseded { opacity: .6; }
.strip-row { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.strip-when { font-size: 15px; font-weight: 900; color: var(--ink); }
.strip-link { font-size: 12px; }
.chat { flex: 1; min-height: 90px; overflow-y: auto; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; }
.chat-ts { align-self: center; font-size: 10.5px; font-weight: 700; color: var(--muted); margin: 4px 0 2px; }
.msg { display: flex; align-items: flex-end; gap: 6px; max-width: 88%; }
.msg.mine { align-self: flex-end; }
.bub { background: var(--card); border: 1.5px solid var(--ink); border-radius: 14px 14px 14px 4px; padding: 7px 10px; line-height: 1.35; min-width: 0; }
.msg.mine .bub { background: var(--accent); color: var(--on-accent); border-radius: 14px 14px 4px 14px; }
.msg.mine .bub .sn-me, .msg.mine .bub .im-msg { color: var(--on-accent); }
.msg.mine .bub .bub-meta { color: var(--on-accent); opacity: .75; }
.bub-short { padding: 5px 10px; }
.bub-cancel { background: var(--danger-soft) !important; color: var(--text) !important; }
.bub-cancel b { color: var(--red); }
.bub-pills { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 5px; }
.bub-pills .pill { display: inline-flex; align-items: center; gap: 3px; background: #fff; color: #1b1b1b; border-color: #1b1b1b; }
.bub-pills .pill-new { background: var(--hi); }
.bub-meta { display: block; margin-top: 3px; color: var(--muted); font-size: 10.5px; }
.sys { align-self: center; display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; padding: 2px 10px; border-radius: 999px; background: var(--face-2); color: var(--ink); text-align: center; }
.sys-on { background: var(--hi); color: var(--on-hi); border: 1.5px solid var(--ink); font: 400 17px/1 var(--pixel); }
.sys-wait { background: var(--accent-soft); color: var(--accent-text); }
.sys-off { background: var(--face-2); color: var(--muted); }
.chat-actions { flex: none; display: flex; flex-direction: column; gap: 8px; padding: 10px 12px; border-top: 1.5px dashed var(--ink); background: var(--bg); max-height: 62%; overflow-y: auto; }
.chat-meta { margin: 0; text-align: center; font-size: 11px; color: var(--muted); }

/* ---------- sign in (live mode) ---------- */
.code-input { font: 900 22px var(--mono); letter-spacing: 6px; text-align: center; }
button.link-btn { display: inline; min-height: 0; padding: 0; border: 0; background: none; color: var(--link); font: inherit; font-weight: 700; text-decoration: underline; }
button.link-btn:hover:not(:disabled) { background: none; }
.loading { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; }
.loading .logo-big { color: var(--red); text-shadow: none; }

/* ---------- buddy requests ---------- */
.request-row { display: flex; align-items: center; gap: 7px; padding: 4px 6px 4px 18px; font-weight: 700; }
.request-row > a, .request-row > span:not(.avatar) { flex: 1; min-width: 0; color: var(--text); text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.request-row small { color: var(--muted); font-weight: 600; }
.request-row button { min-height: 26px; padding: 2px 9px; font-size: 12px; }
.tree details.requests summary { color: var(--red); }

/* ---------- QR code + scanner ---------- */
.qr svg { display: block; }
.scan-btn { align-self: flex-start; }
.notice.scanned { gap: 8px; }
.notice.scanned span { flex: 1; }
.scan-frame { position: relative; aspect-ratio: 1; border-radius: var(--r-md); overflow: hidden; background: #111; }
.scan-video { width: 100%; height: 100%; object-fit: cover; display: block; }
.scan-target { position: absolute; inset: 18%; border: 3px solid var(--yellow); border-radius: 14px; box-shadow: 0 0 0 999px rgba(0, 0, 0, .35); }

/* ---------- notifications ---------- */
.push-status { margin-bottom: 8px; }
.push-on { color: var(--hi-text); }
.map-card.nudge { background: var(--card); }
.map-card .nudge-x { min-width: 0; min-height: 0; padding: 0 6px; border: 0; background: none; font-size: 16px; color: var(--muted); }

/* ---------- safety + legal ---------- */
.doc-body { gap: 10px; }
.doc { line-height: 1.5; }
.doc h2 { font-size: 18px; }
.doc h3 { font-size: 13.5px; font-weight: 900; color: var(--ink); margin: 14px 0 4px; }
.doc ul, .doc ol { margin: 0 0 8px; padding-left: 20px; }
.doc li { margin-bottom: 5px; }
.doc .tips li { margin-bottom: 8px; }
.draft-note { display: flex; align-items: center; gap: 6px; padding: 6px 10px; background: var(--accent-soft); border: 1.5px solid var(--accent-line); border-radius: var(--r-md); font-weight: 700; }
mark.placeholder { background: var(--danger-soft); color: var(--red); border-radius: 4px; padding: 0 3px; font-weight: 700; }
.emergency { display: flex; align-items: center; gap: 7px; padding: 8px 10px; background: var(--danger-soft); border: 1.5px solid var(--danger-line); border-radius: var(--r-md); }
.consent { align-items: flex-start; font-size: 12.5px; }
.consent input { margin-top: 2px; }
.btn.danger-link { color: var(--red); border-color: var(--danger-line); }
.toolbar-note { margin-left: auto; font-size: 12px; }
.strip-safety { font-size: 11.5px; color: var(--muted); }
a.chip { color: var(--text); text-decoration: none; }
a.chip:hover { border-color: var(--ink); }

/* ---------- any place on the map (venues.js) + "you pick the place" ---------- */
.place-results-head { padding: 6px 8px 2px; font-size: 10.5px; font-weight: 900; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); border-top: 1px solid var(--line); }
.place-results-head:first-child { border-top: 0; }
.pop-venues { display: flex; flex-direction: column; gap: 2px; min-width: 190px; }
.pop-venues .place-result { padding: 5px 4px; }
.pop-venues .btn { margin-top: 6px; min-height: 28px; font-size: 12px; }
.map-card.pick { flex-wrap: wrap; }
.map-card.pick .pick-search { flex: 1; min-width: 0; }
.map-card.pick .place-results { z-index: 700; }
.map-card.pick .pick-hint { flex-basis: 100%; color: var(--muted); }
.you-pick { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; padding: 6px 8px; margin-bottom: 6px; border: 1.5px solid var(--line); border-radius: var(--r-md); background: var(--card); cursor: pointer; }
.you-pick small { flex-basis: 100%; padding-left: 22px; }
.you-pick:has(input:checked) { border-color: var(--ink); background: var(--accent-soft); }
.where-set:has(.you-pick input:checked) .place-picker,
.where-set:has(.you-pick input:checked) ~ .right-link,
.where-set:has(.you-pick input:checked) .right-link { display: none; }
.pill-open { border: 1px dashed var(--ink) !important; }

/* ---------- segmented control (Look: Auto / Light / Dark) ---------- */
.segmented { display: flex; padding: 2px; gap: 2px; border: 1.5px solid var(--ink); border-radius: 999px; background: var(--card); margin-bottom: 4px; }
.segmented .seg { flex: 1; min-height: 30px; border: 0; border-radius: 999px; background: none; color: var(--muted); }
.segmented .seg.on { background: var(--accent); color: var(--on-accent); }
/* Icons on things that stay light or pink in dark mode keep black outlines. */
.mk, .bub-pills .pill, .msg.mine .bub, button.default, .btn.default, .start-btn, .task-btn.active, .me-card, .wizard-art,
.segmented .seg.on, .act-opt:has(input:checked), a.act.act-on, .mode-toggle a.on, .pill-on, .sys-on, .tree-row.selected,
.place-opt:has(input:checked), .start-item:hover { --icon-ink: #1b1b1b; }

/* ---------- send / cancel on the "wanna hang?" forms: bigger, centred ---------- */
.toolbar.send-row { justify-content: center; gap: 12px; padding-top: 2px; }
.toolbar.send-row > button, .toolbar.send-row > .btn { min-height: 44px; min-width: 128px; padding: 6px 20px; font-size: 15px; border-radius: var(--r-lg, 14px); }
.toolbar.send-row .toolbar-note { flex-basis: 100%; margin-left: 0; text-align: center; }

/* ---------- Plan | Wildcard ---------- */
.kind-toggle { align-self: center; }
.bub-title { font-weight: 800; }
.strip-title b { font-size: 15px; font-weight: 900; color: var(--ink); }

/* ---------- discover map: bigger layer chips ---------- */
.map-wrap.discover .layer-chips { gap: 6px; }
.map-wrap.discover .layer-chip { min-height: 34px; padding: 4px 12px 4px 8px; font-size: 13.5px; gap: 6px; }
.map-wrap.discover .layer-chip .icon { width: 17px; height: 17px; }

/* ---------- activities: "More" ---------- */
.act-filter { position: relative; }
.act-more > summary { list-style: none; cursor: pointer; }
.act-more > summary::-webkit-details-marker { display: none; }
.act-more > summary::after { content: "▾"; margin-left: 2px; }
.act-more[open] > summary { border-color: var(--ink); background: var(--accent-soft); }
.act-menu { position: absolute; left: 0; right: 0; top: calc(100% + 4px); z-index: 50; max-height: min(60vh, 420px); overflow-y: auto; padding: 4px; border-radius: var(--r-md); }
.act-menu-head { padding: 4px 8px 6px; font-size: 11px; font-weight: 800; color: var(--muted); }
.act-menu-row { display: flex; align-items: center; border-radius: var(--r-sm); }
.act-menu-row:hover, .act-menu-row.on { background: var(--hover); }
.act-menu-row a { flex: 1; display: flex; align-items: center; gap: 8px; padding: 7px 8px; color: var(--text); text-decoration: none; font-weight: 700; }
.act-menu-row .star-btn { min-height: 34px; min-width: 40px; padding: 0; border: 0; background: none; font-size: 20px; color: var(--muted); }
.act-menu-row .star-btn.on { color: var(--accent-text); }
.act-more-inline { margin-top: 6px; }
.act-more-inline > summary { cursor: pointer; font-weight: 800; font-size: 12.5px; color: var(--link); padding: 2px 0 6px; }

/* ---------- My Plans: edit mode ---------- */
.plan-edit-row { display: flex; align-items: center; gap: 4px; padding-right: 6px; }
.plan-edit-row .plan-row { flex: 1; min-width: 0; }
.btn.plan-del { min-height: 30px; padding: 2px 10px; font-size: 12px; color: var(--red); border-color: var(--danger-line); }

/* Neighbourhood picker (sign-up, profile): search the map's neighbourhoods and postcodes. */
.area-chosen { margin: 4px 0 0; }
.area-results { max-height: 220px; overflow: auto; margin-top: 6px; }
.area-results .place-opt { width: calc(100% - 6px); justify-content: flex-start; text-align: left; background: none; border: 0; box-shadow: none; min-height: 0; font: inherit; color: inherit; }

/* Contacts: your invite link. */
.invite-link { padding: 8px 10px; overflow-wrap: anywhere; font-size: 13px; }

/* "Repeats: every week / 2 weeks / month…" under a time picker. */
.repeat-opt { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
.repeat-opt select { flex: 1; min-width: 0; }
.invite-via { display: flex; gap: 4px; flex-shrink: 0; margin-left: auto; }
.invite-via button { min-width: 0; padding: 4px 9px; }
.person-row:has(.invite-via) > span:not(.invite-via):not(.avatar) { min-width: 0; overflow-wrap: anywhere; }

/* "Heads up: you're already in …" (conflicting plans). */
.conflict-note { display: flex; gap: 6px; align-items: flex-start; margin-top: 8px; padding: 7px 10px; border-radius: var(--r-sm); background: var(--select-soft, rgba(240, 180, 60, .16)); font-size: 13px; }
.conflict-note[hidden] { display: none; }
.place-results-credit { padding: 4px 10px 6px; font-size: 11px; color: var(--muted, #888); text-align: right; }
.place-results-tip { padding: 6px 10px 8px; font-size: 12px; color: var(--muted, #888); border-top: 1px dashed var(--line, rgba(0,0,0,.12)); }
.name-venue { padding: 8px 10px 10px; display: grid; gap: 6px; }

/* Profile picture: pick from your phone, then fit it into the circle. */
.photo-pick { display: flex; align-items: center; gap: 12px; font-weight: 400; }
.crop-overlay .dialog { max-width: calc(100vw - 32px); }
.crop-stage { position: relative; margin: 0 auto; overflow: hidden; border-radius: var(--r-sm); background: #111; touch-action: none; cursor: grab; user-select: none; }
.crop-stage img { position: absolute; left: 0; top: 0; max-width: none; transform-origin: 0 0; pointer-events: none; }
.crop-ring { position: absolute; inset: 0; border-radius: 50%; box-shadow: 0 0 0 999px rgba(0, 0, 0, .55); border: 2px solid #fff; pointer-events: none; }
.crop-zoom { display: flex; align-items: center; gap: 8px; margin: 12px auto 0; max-width: 260px; }
.crop-zoom input { flex: 1; }

/* "Make a rez?" on a plan that's on: tap to change who books. */
.rez-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 8px 0; }
.rez-label { font-weight: 800; font-size: 13px; }
.act-opt.picked { background: var(--select); color: var(--on-accent); border-color: var(--ink); }
.reserve-set[hidden] { display: none; }
