/* TripDeck — light, soft, travel-app warm.
   Canvas: warm off-white. Cards: white, big radius, whisper shadows.
   Anchor: deep pine (nav, primary actions). Accent: warm orange (progress, pins).
   Data (times, temps, counts): bold mono, airport-board style. */

:root {
  --bg: #f3f3ef;
  --card: #ffffff;
  --tint: #e9f1ed;          /* pale sage rows */
  --tint-warm: #faeede;     /* pale amber */
  --tint-blue: #e8eef7;
  --tint-lav: #efeaf7;
  --line: #e5e5df;
  --text: #1b2420;
  --muted: #666d68;
  --pine: #20423a;
  --pine-soft: #2e5449;
  --accent: #f08a3c;
  --ok: #2e9e6b;
  --danger: #d9553f;
  --radius: 18px;
  --shadow: 0 8px 24px rgba(27, 36, 32, 0.06);
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--pine); text-decoration: none; font-weight: 600; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- layout: floating pill nav on mobile, white rail on desktop ---------- */
.shell { display: flex; flex-direction: column; min-height: 100dvh; }
main { flex: 1; padding: 14px 18px 110px; max-width: 980px; width: 100%; margin: 0 auto; }

.topbar {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: blur(12px);
}
.wordmark { font-weight: 800; letter-spacing: 0.01em; font-size: 16px; display: flex; align-items: center; gap: 8px; }
.wordmark .tape {
  background: var(--pine); color: #fff;
  width: 30px; height: 30px; border-radius: 10px;
  display: inline-flex; align-items: center; justify-content: center;
  font-size: 12px; font-weight: 800; letter-spacing: 0;
}
.project-name {
  color: var(--pine); font-size: 13px; font-weight: 600;
  background: var(--tint); border-radius: 999px; padding: 6px 14px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.topbar .spacer { flex: 1; }
.icon-btn {
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  color: var(--muted); padding: 7px 14px; cursor: pointer; font-size: 13px; font-weight: 600;
}
.icon-btn:hover { color: var(--text); border-color: var(--muted); }

nav.tabs {
  position: fixed; bottom: 14px; left: 50%; transform: translateX(-50%); z-index: 20;
  display: flex; gap: 4px;
  background: var(--pine);
  border-radius: 999px;
  padding: 8px;
  box-shadow: 0 12px 32px rgba(27, 36, 32, 0.28);
  max-width: calc(100vw - 24px);
}
nav.tabs button {
  background: none; border: none; cursor: pointer;
  color: rgba(255, 255, 255, 0.66);
  width: 48px; height: 48px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0;   /* icon-only everywhere; title attributes provide tooltips */
  flex-shrink: 0; position: relative;
}
.nav-badge {
  position: absolute; top: 4px; right: 4px;
  background: var(--accent); color: #fff;
  font-size: 10px; font-weight: 800; line-height: 1;
  border-radius: 999px; padding: 3px 5px; min-width: 16px; text-align: center;
}
nav.tabs button .glyph { font-size: 20px; line-height: 1; }
nav.tabs button.active { background: #fff; color: var(--pine); }

@media (min-width: 900px) {
  .shell { flex-direction: row; }
  nav.tabs {
    position: sticky; top: 0; bottom: auto; left: 0; transform: none;
    height: 100dvh; width: 84px;
    flex-direction: column; justify-content: flex-start; gap: 8px; align-items: center;
    background: var(--card); border-right: 1px solid var(--line);
    border-radius: 0; box-shadow: none; padding: 84px 0 14px; max-width: none;
  }
  nav.tabs button { width: 52px; height: 52px; border-radius: 16px; color: var(--muted); position: relative; }
  nav.tabs button.active { background: var(--pine); color: #fff; }
  main { padding: 26px 36px 56px; }
  .topbar { position: fixed; left: 0; right: 0; }
  .content-col { padding-top: 58px; flex: 1; }
}
.content-col { display: flex; flex-direction: column; flex: 1; min-width: 0; }

/* ---------- primitives ---------- */
.card {
  background: var(--card); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 16px 18px; margin-bottom: 14px;
}
h1 { font-size: 26px; margin: 6px 0 4px; letter-spacing: -0.02em; line-height: 1.15; }
.hero { font-size: 30px; margin: 2px 0 6px; }
.eyebrow { font-size: 13px; font-weight: 700; color: var(--muted); }
h2 { font-size: 15px; color: var(--text); margin: 20px 0 10px; font-weight: 700; letter-spacing: -0.01em; }
.muted { color: var(--muted); font-size: 13px; }
.mono { font-family: var(--mono); font-variant-numeric: tabular-nums; font-weight: 700; }

.btn {
  background: var(--pine); color: #fff; border: none;
  border-radius: 999px; padding: 12px 22px; font-weight: 700; cursor: pointer;
}
.btn:hover { background: var(--pine-soft); }
.btn.ghost { background: var(--card); color: var(--pine); border: 1px solid var(--line); }
.btn.ghost:hover { border-color: var(--pine); background: var(--card); }
.btn.small { padding: 7px 14px; font-size: 13px; }
.btn.danger-ghost { background: none; border: none; color: var(--muted); font-size: 13px; cursor: pointer; font-weight: 600; }
.btn.danger-ghost:hover { color: var(--danger); }
.btn:disabled { opacity: 0.5; cursor: default; }

input[type="text"], input[type="password"], input[type="date"], input[type="time"], select, textarea {
  width: 100%; background: var(--bg); border: 1px solid var(--line);
  border-radius: 12px; padding: 11px 14px; color: var(--text);
}
input:focus, select:focus, textarea:focus { border-color: var(--pine); }
input::placeholder, textarea::placeholder { color: #a9aea9; }
label { display: block; font-size: 13px; color: var(--muted); font-weight: 600; margin: 12px 0 5px; }
.row { display: flex; gap: 10px; }
.row > * { flex: 1; min-width: 0; }

.error-text { color: var(--danger); font-size: 14px; min-height: 20px; margin-top: 8px; }
.empty { color: var(--muted); text-align: center; padding: 30px 12px; font-size: 14px; }

/* ---------- login ---------- */
.login-wrap { min-height: 100dvh; display: grid; place-items: center; padding: 20px; background: var(--bg); }
.login-card { width: 100%; max-width: 400px; }
.login-card .card { padding: 28px 26px; border-radius: 24px; }
.login-brand { text-align: center; margin-bottom: 20px; }
.login-brand .tape {
  background: var(--pine); color: #fff; font-weight: 800;
  padding: 8px 18px; border-radius: 14px; display: inline-block;
  font-size: 17px; letter-spacing: 0.04em;
}
.login-brand p { color: var(--muted); font-size: 13.5px; margin: 12px 0 0; }
.step-hint { font-size: 13px; color: var(--accent); font-weight: 700; margin: 0 0 4px; text-transform: uppercase; letter-spacing: 0.06em; }
.sso-divider { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 12px; margin: 14px 0; }
.sso-divider::before, .sso-divider::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.linklike { background: none; border: none; color: var(--pine); cursor: pointer; padding: 0; font-size: 14px; font-weight: 700; }

/* ---------- dashboard ---------- */
.day-count { font-family: var(--mono); color: var(--muted); font-size: 12.5px; font-weight: 600; letter-spacing: 0.02em; }
.today-item { display: flex; gap: 14px; background: var(--tint); border-radius: 14px; padding: 12px 14px; }
.today-item + .today-item { margin-top: 8px; }
.time-block { font-family: var(--mono); font-size: 15px; font-weight: 800; color: var(--pine); min-width: 54px; padding-top: 1px; }
.time-block .muted { font-size: 11px; font-weight: 600; }
.progress-track { height: 10px; border-radius: 999px; background: var(--tint); overflow: hidden; margin: 10px 0 4px; }
.progress-fill { height: 100%; background: var(--accent); border-radius: 999px; transition: width 0.4s ease; }
.wx-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; }
.wx-day { min-width: 76px; text-align: center; background: var(--tint); border-radius: 14px; padding: 10px 6px; }
.wx-day .d { font-size: 11px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; }
.wx-day .t { font-family: var(--mono); font-weight: 700; font-size: 14px; margin-top: 3px; }
.wx-day .r { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* ---------- editorial headers + attention chips ---------- */
.eyebrow-accent { color: var(--accent); text-transform: uppercase; letter-spacing: 0.08em; font-size: 11.5px; }
.screen-sub { max-width: 560px; margin: 2px 0 14px; }
.chip-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 12px 0 2px; }
.att-chip {
  display: inline-flex; align-items: center; gap: 7px;
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  padding: 8px 14px; font-size: 13px; font-weight: 700; color: var(--text); cursor: pointer;
}
.att-chip:hover { border-color: var(--pine); }
.att-chip.att-suggest { background: var(--tint-warm); border-color: transparent; color: #8a4d13; }
.att-chip .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }

/* ---------- dashboard grid ---------- */
.dash-grid { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); margin-top: 14px; }
@media (min-width: 1100px) { .dash-grid { grid-template-columns: 280px minmax(0, 1fr) 320px; align-items: start; } }
.dash-summary .dash-proj-name { font-size: 18px; font-weight: 800; text-align: center; margin-top: 4px; }
.avatar-cluster { display: flex; justify-content: center; margin: 10px 0 4px; }
.avatar-cluster .avatar, .avatar-cluster .avatar-init { margin: 0 -4px; border: 2px solid var(--card); }
.stat-row {
  display: flex; justify-content: space-between; padding: 9px 0;
  border-bottom: 1px solid var(--line); font-size: 13.5px; color: var(--muted); font-weight: 600;
}
.stat-row .mono { color: var(--text); }
.dash-center { display: flex; flex-direction: column; }
.rail-item { display: flex; gap: 10px; align-items: flex-start; padding: 9px 0; border-bottom: 1px solid var(--line); }
.rail-item:last-of-type { border-bottom: none; }
.rail-time { color: var(--pine); font-size: 13px; min-width: 44px; padding-top: 1px; }
.rail-body { flex: 1; min-width: 0; font-size: 13.5px; }
.rail-body .muted { display: block; font-size: 12px; }
.waiting-chip {
  background: var(--tint-warm); color: #8a4d13; font-size: 12px; font-weight: 700;
  border-radius: 999px; padding: 7px 12px; margin: 8px 0;
}
.hero-chip {
  position: absolute; top: 12px; right: 12px; z-index: 1;
  background: rgba(255, 255, 255, 0.94); color: var(--text);
  border-radius: 12px; padding: 8px 12px; font-size: 12px; font-weight: 700;
}
.hero-chip .mono { color: var(--accent); font-size: 15px; }

/* ---------- schedule cards ---------- */
.sched-card {
  display: flex; gap: 14px; align-items: flex-start;
  background: var(--tint); border-radius: 16px; padding: 14px 16px; margin-bottom: 10px;
}
.sched-card.suggested { background: var(--tint-warm); }
.sched-card .time-block { font-size: 16px; }
.sched-loc { margin-top: 2px; }
.chiplets { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 8px; }
.chiplets .kind-chip { margin-left: 0; }
.mono-chip { font-family: var(--mono); background: var(--card); color: var(--muted); }

/* ---------- shots: segmented tabs + big tiles ---------- */
.seg-tabs {
  display: flex; gap: 4px; background: var(--card); border-radius: 999px;
  padding: 5px; box-shadow: var(--shadow); overflow-x: auto; scrollbar-width: none;
}
.seg-tabs::-webkit-scrollbar { display: none; }
.seg-tab {
  background: none; border: none; cursor: pointer; white-space: nowrap;
  border-radius: 999px; padding: 9px 16px; font-size: 14px; font-weight: 700; color: var(--muted);
}
.seg-tab .mono { font-size: 12px; }
.seg-tab.active { background: var(--pine); color: #fff; }
.shot-tile {
  display: flex; gap: 12px; align-items: flex-start; cursor: pointer;
  background: var(--card); border-radius: 16px; padding: 13px 14px; margin-bottom: 8px;
  box-shadow: var(--shadow); font-weight: 600; color: var(--text);
}
.shot-tile.done { background: var(--tint); box-shadow: none; }
.shot-tile input { position: absolute; opacity: 0; pointer-events: none; }
.shot-box {
  width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
  border: 2px solid #c9cec8; color: transparent;
  display: flex; align-items: center; justify-content: center; font-size: 18px; font-weight: 800;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.shot-tile.done .shot-box { background: var(--pine); border-color: var(--pine); color: #fff; }
.shot-txt { flex: 1; min-width: 0; padding-top: 2px; }
.shot-tile.done .shot-txt { color: var(--muted); text-decoration: line-through; }
.shot-att {
  display: flex; align-items: center; gap: 6px; margin-top: 5px;
  font-size: 12px; font-weight: 700; color: var(--ok); text-decoration: none;
}

/* ---------- hero photo + map links ---------- */
.hero-photo {
  display: block; position: relative; height: 158px; border-radius: var(--radius);
  background-size: cover; background-position: center;
  margin: 12px 0 4px; overflow: hidden; box-shadow: var(--shadow);
}
.hero-photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(27, 36, 32, 0.45), rgba(27, 36, 32, 0) 55%);
}
.hero-loc {
  position: absolute; left: 12px; bottom: 12px; z-index: 1;
  background: #fff; color: var(--pine); font-size: 12.5px; font-weight: 700;
  border-radius: 999px; padding: 6px 14px;
}
.hero-loc::before { content: "⌖ "; color: var(--accent); }
.hero-credit {
  position: absolute; right: 10px; bottom: 10px; z-index: 1;
  color: rgba(255, 255, 255, 0.85); font-size: 10.5px; font-weight: 600;
}
.loc-link { font-size: inherit; color: var(--pine); font-weight: 600; }
.loc-link::after { content: " ↗"; color: var(--accent); font-size: 0.85em; }

/* ---------- schedule: the day strip ---------- */
.day-strip { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 12px; scrollbar-width: none; }
.day-strip::-webkit-scrollbar { display: none; }
.day-strip button {
  background: var(--card); border: 1px solid var(--line); border-radius: 16px;
  color: var(--muted); cursor: pointer; padding: 9px 0; min-width: 62px; flex-shrink: 0;
  text-align: center;
}
.day-strip .dow { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.07em; }
.day-strip .dom { font-family: var(--mono); font-size: 17px; font-weight: 800; margin-top: 1px; }
.day-strip button.active { background: var(--pine); border-color: var(--pine); color: #fff; }
.sched-item { display: flex; gap: 14px; align-items: flex-start; }
.sched-body { flex: 1; min-width: 0; }
.kind-chip {
  display: inline-block; font-size: 10.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.06em; border-radius: 999px; padding: 3px 9px; margin-left: 6px;
  background: var(--bg); color: var(--muted);
}
.kind-shoot { background: var(--tint-warm); color: #a35a17; }
.kind-meeting { background: var(--tint-blue); color: #2f5a96; }
.kind-travel { background: var(--tint-lav); color: #6a4fa3; }
.kind-event { background: var(--tint); color: var(--pine); }
.kind-meal { background: var(--tint-warm); color: #a35a17; }

/* ---------- checklists ---------- */
.check-item { display: flex; align-items: flex-start; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); }
.check-item:last-child { border-bottom: none; }
.check-item input[type="checkbox"] { width: 21px; height: 21px; accent-color: var(--ok); margin-top: 1px; flex-shrink: 0; }
.check-item .txt { flex: 1; min-width: 0; }
.check-item.done .txt { color: var(--muted); text-decoration: line-through; }
.check-meta { font-size: 12px; color: var(--ok); font-weight: 600; }
.cat-tag { font-size: 11px; color: var(--accent); font-weight: 700; margin-right: 6px; text-transform: uppercase; letter-spacing: 0.04em; }

/* ---------- files ---------- */
.file-row { display: flex; align-items: center; gap: 12px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.file-row:last-child { border-bottom: none; }
.file-glyph {
  font-size: 16px; width: 40px; height: 40px; border-radius: 12px; flex-shrink: 0;
  background: var(--tint); color: var(--pine);
  display: flex; align-items: center; justify-content: center;
}
.file-main { flex: 1; min-width: 0; }
.file-name { font-weight: 700; font-size: 14.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.digest-table-wrap { overflow-x: auto; margin-top: 10px; border: 1px solid var(--line); border-radius: 14px; }
.digest-table { border-collapse: collapse; width: 100%; font-size: 13px; }
.digest-table th {
  background: var(--tint); text-align: left; padding: 8px 12px; position: sticky; top: 0;
  font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--pine);
}
.digest-table td { padding: 7px 12px; border-top: 1px solid var(--line); font-family: var(--mono); font-size: 12.5px; white-space: nowrap; }
.drop-zone {
  border: 1.5px dashed #c9cec8; background: var(--card); border-radius: var(--radius);
  padding: 24px; text-align: center; color: var(--muted); cursor: pointer; margin-bottom: 14px;
}
.drop-zone.drag { border-color: var(--accent); color: var(--accent); }

/* ---------- sources: kind chips, badges, import preview ---------- */
.src-kind-hotel { background: var(--tint-lav); color: #6a4fa3; }
.src-kind-schedule { background: var(--tint-blue); color: #2f5a96; }
.src-kind-shotlist { background: var(--tint-warm); color: #a35a17; }
.src-kind-credentials { background: var(--tint); color: var(--pine); }
.src-kind-budget { background: var(--tint); color: var(--pine); }
.badge-updated {
  display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: 0.05em;
  text-transform: uppercase; background: var(--accent); color: #fff;
  border-radius: 999px; padding: 3px 9px; margin-left: 4px;
}
.update-banner {
  background: var(--tint-warm); color: #a35a17; font-weight: 700; font-size: 13.5px;
  border-radius: 14px; padding: 12px 16px; margin: 10px 0 2px; cursor: pointer;
}
.preview-list { max-height: 42vh; overflow: auto; border: 1px solid var(--line); border-radius: 14px; padding: 4px 12px; margin-top: 10px; }
.preview-item { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; cursor: pointer; margin: 0; color: var(--text); font-weight: 400; }
.preview-item:last-child { border-bottom: none; }
.preview-item input { width: 18px; height: 18px; accent-color: var(--pine); margin-top: 2px; flex-shrink: 0; }
.preview-note { background: var(--tint-warm); border-radius: 14px; padding: 12px 14px; white-space: pre-wrap; font-size: 14px; margin-top: 10px; max-height: 42vh; overflow: auto; }

/* ---------- notes ---------- */
.note-card.pinned { background: var(--tint-warm); box-shadow: none; }
.note-card.pinned::before { content: "Pinned"; display: block; font-size: 10.5px; font-weight: 800; letter-spacing: 0.07em; text-transform: uppercase; color: var(--accent); margin-bottom: 4px; }
.note-body { white-space: pre-wrap; word-wrap: break-word; margin: 0 0 6px; }
.note-actions { display: flex; gap: 12px; }

/* ---------- team / invite ---------- */
.member-row { display: flex; justify-content: space-between; align-items: center; padding: 9px 0; border-bottom: 1px solid var(--line); }
.member-row:last-child { border-bottom: none; }
.role-chip { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.05em; color: var(--pine); background: var(--tint); border-radius: 999px; padding: 4px 10px; }
.code-reveal {
  font-family: var(--mono); font-size: 21px; text-align: center;
  background: var(--pine); color: #fff; font-weight: 700;
  border-radius: 16px; padding: 16px; margin: 12px 0; letter-spacing: 0.04em;
}

dialog {
  background: var(--card); color: var(--text);
  border: none; border-radius: 22px; box-shadow: 0 24px 64px rgba(27, 36, 32, 0.22);
  width: min(440px, calc(100vw - 32px)); padding: 22px;
}
dialog::backdrop { background: rgba(27, 36, 32, 0.4); }
.dialog-actions { display: flex; justify-content: flex-end; align-items: center; gap: 10px; margin-top: 16px; }

/* ---------- avatars ---------- */
.avatar { border-radius: 50%; object-fit: cover; display: inline-block; flex-shrink: 0; background: var(--tint); }
.avatar-init { display: inline-flex; align-items: center; justify-content: center; background: var(--pine); color: #fff; font-weight: 700; border-radius: 50%; }
.avatar-btn { background: none; border: none; padding: 0; cursor: pointer; border-radius: 50%; line-height: 0; }
.avatar-btn:hover { box-shadow: 0 0 0 3px var(--tint); }
.avatar-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(48px, 1fr)); gap: 8px; margin-top: 6px; }
.avatar-pick { background: var(--bg); border: 2px solid transparent; border-radius: 14px; padding: 3px; cursor: pointer; line-height: 0; transition: border-color 0.15s ease, transform 0.15s ease; }
.avatar-pick img { width: 100%; border-radius: 10px; }
.avatar-pick:hover { transform: scale(1.06); }
.avatar-pick.picked { border-color: var(--pine); }
.avatar-upload { font-size: 20px; color: var(--muted); line-height: 42px; }
.check-inline { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--text); margin-top: 12px; }
.check-inline input { width: 18px; height: 18px; accent-color: var(--pine); }
.tour-item { background: var(--tint); border-radius: 14px; padding: 12px 14px; margin-bottom: 10px; font-size: 14px; }

/* ---------- suggestions ---------- */
.sched-item.suggested { background: var(--tint-warm); }
.badge-suggested { display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; background: var(--accent); color: #fff; border-radius: 999px; padding: 3px 9px; margin-left: 6px; }
.suggest-banner { background: var(--tint-lav); color: #6a4fa3; }

/* ---------- chat ---------- */
.chat-card { display: flex; flex-direction: column; padding: 12px; }
.chat-scroll { max-height: 56vh; min-height: 200px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 4px 2px; }
.chat-msg { display: flex; gap: 8px; align-items: flex-end; max-width: 86%; }
.chat-msg.mine { flex-direction: row-reverse; align-self: flex-end; }
.chat-bubble { background: var(--tint); border-radius: 16px 16px 16px 4px; padding: 8px 12px; font-size: 14px; word-break: break-word; }
.chat-msg.mine .chat-bubble { background: var(--pine); color: #fff; border-radius: 16px 16px 4px 16px; }
.chat-msg.mine .chat-meta { color: rgba(255, 255, 255, 0.7); }
.chat-meta { font-size: 10.5px; color: var(--muted); font-weight: 600; margin-bottom: 2px; }
.chat-input-row { display: flex; gap: 8px; margin-top: 10px; }

/* ---------- motion (all skipped under prefers-reduced-motion) ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
#view > * { animation: rise 0.32s ease both; }
#view > :nth-child(2) { animation-delay: 0.04s; }
#view > :nth-child(3) { animation-delay: 0.08s; }
#view > :nth-child(4) { animation-delay: 0.12s; }
#view > :nth-child(5) { animation-delay: 0.16s; }
#view > :nth-child(6) { animation-delay: 0.2s; }
@keyframes morphIn { from { opacity: 0; transform: translateY(14px) scale(0.98); } }
.panel { animation: morphIn 0.35s cubic-bezier(0.2, 0.7, 0.3, 1) both; }
dialog[open] { animation: morphIn 0.28s cubic-bezier(0.2, 0.7, 0.3, 1); }
.btn { transition: transform 0.12s ease, background 0.15s ease, filter 0.15s ease; }
.btn:active { transform: scale(0.96); }
nav.tabs button { transition: background 0.2s ease, color 0.2s ease; }
.progress-fill { transition: width 0.6s cubic-bezier(0.2, 0.7, 0.3, 1); }

.toast {
  position: fixed; bottom: 88px; left: 50%; transform: translateX(-50%);
  background: var(--pine); color: #fff;
  padding: 11px 20px; border-radius: 999px; font-size: 14px; font-weight: 600; z-index: 50;
  box-shadow: 0 12px 32px rgba(27, 36, 32, 0.25);
  animation: toast-in 0.2s ease;
}
@keyframes toast-in { from { opacity: 0; transform: translate(-50%, 8px); } }
@media (min-width: 900px) { /* ---------- avatars ---------- */
.avatar { border-radius: 50%; object-fit: cover; display: inline-block; flex-shrink: 0; background: var(--tint); }
.avatar-init { display: inline-flex; align-items: center; justify-content: center; background: var(--pine); color: #fff; font-weight: 700; border-radius: 50%; }
.avatar-btn { background: none; border: none; padding: 0; cursor: pointer; border-radius: 50%; line-height: 0; }
.avatar-btn:hover { box-shadow: 0 0 0 3px var(--tint); }
.avatar-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(48px, 1fr)); gap: 8px; margin-top: 6px; }
.avatar-pick { background: var(--bg); border: 2px solid transparent; border-radius: 14px; padding: 3px; cursor: pointer; line-height: 0; transition: border-color 0.15s ease, transform 0.15s ease; }
.avatar-pick img { width: 100%; border-radius: 10px; }
.avatar-pick:hover { transform: scale(1.06); }
.avatar-pick.picked { border-color: var(--pine); }
.avatar-upload { font-size: 20px; color: var(--muted); line-height: 42px; }
.check-inline { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--text); margin-top: 12px; }
.check-inline input { width: 18px; height: 18px; accent-color: var(--pine); }
.tour-item { background: var(--tint); border-radius: 14px; padding: 12px 14px; margin-bottom: 10px; font-size: 14px; }

/* ---------- suggestions ---------- */
.sched-item.suggested { background: var(--tint-warm); }
.badge-suggested { display: inline-block; font-size: 10px; font-weight: 800; letter-spacing: 0.05em; text-transform: uppercase; background: var(--accent); color: #fff; border-radius: 999px; padding: 3px 9px; margin-left: 6px; }
.suggest-banner { background: var(--tint-lav); color: #6a4fa3; }

/* ---------- chat ---------- */
.chat-card { display: flex; flex-direction: column; padding: 12px; }
.chat-scroll { max-height: 56vh; min-height: 200px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 4px 2px; }
.chat-msg { display: flex; gap: 8px; align-items: flex-end; max-width: 86%; }
.chat-msg.mine { flex-direction: row-reverse; align-self: flex-end; }
.chat-bubble { background: var(--tint); border-radius: 16px 16px 16px 4px; padding: 8px 12px; font-size: 14px; word-break: break-word; }
.chat-msg.mine .chat-bubble { background: var(--pine); color: #fff; border-radius: 16px 16px 4px 16px; }
.chat-msg.mine .chat-meta { color: rgba(255, 255, 255, 0.7); }
.chat-meta { font-size: 10.5px; color: var(--muted); font-weight: 600; margin-bottom: 2px; }
.chat-input-row { display: flex; gap: 8px; margin-top: 10px; }

/* ---------- motion (all skipped under prefers-reduced-motion) ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(10px); } }
#view > * { animation: rise 0.32s ease both; }
#view > :nth-child(2) { animation-delay: 0.04s; }
#view > :nth-child(3) { animation-delay: 0.08s; }
#view > :nth-child(4) { animation-delay: 0.12s; }
#view > :nth-child(5) { animation-delay: 0.16s; }
#view > :nth-child(6) { animation-delay: 0.2s; }
@keyframes morphIn { from { opacity: 0; transform: translateY(14px) scale(0.98); } }
.panel { animation: morphIn 0.35s cubic-bezier(0.2, 0.7, 0.3, 1) both; }
dialog[open] { animation: morphIn 0.28s cubic-bezier(0.2, 0.7, 0.3, 1); }
.btn { transition: transform 0.12s ease, background 0.15s ease, filter 0.15s ease; }
.btn:active { transform: scale(0.96); }
nav.tabs button { transition: background 0.2s ease, color 0.2s ease; }
.progress-fill { transition: width 0.6s cubic-bezier(0.2, 0.7, 0.3, 1); }

.toast { bottom: 28px; } }
