@font-face { font-family: "Big Shoulders Display"; font-weight: 100 900; font-display: swap; src: url("/fonts/big-shoulders-display-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Big Shoulders Display"; font-weight: 100 900; font-display: swap; src: url("/fonts/big-shoulders-display-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Figtree"; font-weight: 300 900; font-display: swap; src: url("/fonts/figtree-latin.woff2") format("woff2"); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Figtree"; font-weight: 300 900; font-display: swap; src: url("/fonts/figtree-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --shell: #0E3B46;
  --shell-2: #155866;
  --shell-deep: #0A2E37;
  --split: #051C22;
  --on-shell: #FFFFFF;
  --on-shell-2: #B9D3D8;
  --ground: #E9EFF0;
  --card: #FFFFFF;
  --tint: #E1ECEE;
  --line: #DCE4E6;
  --line-2: #B8C7CB;
  --ink: #10252B;
  --ink-2: #2C434A;
  --ink-3: #4A5F66;
  --label: #F4B52E;
  --poppy: #D9462B;
  --poppy-ink: #A3321C;
  --poppy-soft: #FFE6DF;
  --rain: #1C5E83;
  --rain-soft: #EEF5FA;
  --cold: #3A4E8C;
  --cold-soft: #F0F1FA;
  --hot: #A64B12;
  --ok: #1E7A5A;
  --radius: 16px;
  --display: "Big Shoulders Display", "Figtree", sans-serif;
  --ui: "Figtree", system-ui, sans-serif;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--ink); font: 500 16px/1.45 var(--ui); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; }
::selection { background: var(--label); color: var(--ink); }
:focus-visible { outline: 3px solid var(--label); outline-offset: 2px; border-radius: 6px; }
input, textarea, select { caret-color: var(--shell-2); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--shell-2); text-underline-offset: 3px; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
* { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
[hidden] { display: none !important; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- app frame ---------- */
.app { min-height: 100dvh; display: flex; flex-direction: column; }
.main { flex: 1; display: flex; flex-direction: column; min-width: 0; padding-bottom: calc(76px + var(--safe-b)); }
.page { padding: calc(20px + var(--safe-t)) 16px 24px; display: flex; flex-direction: column; gap: 14px; max-width: 720px; width: 100%; margin: 0 auto; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.page-head h1 { font-size: 30px; font-weight: 800; letter-spacing: -.01em; line-height: 1.1; }
.sub { font-size: 14px; color: var(--ink-2); margin-top: 2px; }
.muted { color: var(--ink-3); }
.small { font-size: 13px; }
.section-title { font-size: 17px; font-weight: 800; margin-top: 10px; }

.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 20; height: calc(68px + var(--safe-b)); padding: 0 8px var(--safe-b); background: var(--card); border-top: 1px solid #D3DDE0; display: flex; }
.nav a { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; font-size: 12px; font-weight: 700; color: var(--ink-3); text-decoration: none; border-radius: 12px; }
.nav a[aria-current="page"] { color: var(--shell); }
.nav a[aria-current="page"] svg { stroke-width: 2.4; }

@media (min-width: 1000px) {
  .app { flex-direction: row; }
  .nav { position: sticky; top: 0; height: 100dvh; width: 92px; flex-direction: column; justify-content: flex-start; gap: 6px; padding: 20px 10px; border-top: 0; border-right: 1px solid #D3DDE0; }
  .nav a { flex: none; height: 64px; }
  .nav a:hover { background: var(--ground); }
  .main { padding-bottom: 0; }
}

/* ---------- surfaces ---------- */
.card { background: var(--card); border-radius: var(--radius); box-shadow: 0 1px 2px rgba(16, 37, 43, .06); }
.card-pad { padding: 14px 16px; }
.row { display: flex; align-items: center; gap: 10px; }
.list > * + * { border-top: 1px solid var(--line); }
.stack { display: flex; flex-direction: column; gap: 10px; }

/* ---------- buttons & fields ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 0 18px; border-radius: 14px; border: 0; background: var(--shell); color: #fff; font-weight: 800; font-size: 16px; text-decoration: none; transition: transform .15s var(--ease), background .15s; }
.btn:hover { background: var(--shell-2); }
.btn:active { transform: scale(.98); }
.btn:disabled { opacity: .5; cursor: default; transform: none; }
.btn.label { background: var(--label); color: var(--ink); }
.btn.label:hover { background: #F7C24F; }
.btn.ghost { background: transparent; color: var(--shell); box-shadow: inset 0 0 0 1.5px var(--line-2); }
.btn.ghost:hover { background: var(--tint); }
.btn.danger { background: transparent; color: var(--poppy-ink); box-shadow: inset 0 0 0 1.5px #F0B9AC; }
/* Google's own button colours (their sign-in brand rules), so it reads as the real thing. */
.btn.google { background: #fff; color: #1F1F1F; box-shadow: inset 0 0 0 1px #747775; gap: 12px; }
.btn.google:hover { background: #F2F2F2; }
/* Server-rendered sign-in problems (/auth/callback) */
.signin { min-height: 100dvh; background: var(--shell); display: grid; place-items: center; padding: 24px 16px; }
.signin-card { background: var(--ground); color: var(--ink); border-radius: 22px; padding: 26px 22px; max-width: 440px; width: 100%; }
.signin-card h1 { font-size: 26px; font-weight: 800; line-height: 1.15; }
.signin-card p { margin: 0; color: var(--ink-2); }
.btn.small { min-height: 40px; padding: 0 14px; font-size: 14px; border-radius: 11px; }
.btn.block { width: 100%; }
.btn.big { min-height: 56px; font-size: 17px; }
.icon-btn { width: 44px; height: 44px; border-radius: 12px; border: 0; background: transparent; display: inline-flex; align-items: center; justify-content: center; color: inherit; flex: none; }
.icon-btn:hover { background: rgba(14, 59, 70, .08); }
.link-btn { background: none; border: 0; padding: 6px 0; color: var(--shell-2); font-weight: 700; text-decoration: underline; text-underline-offset: 3px; }

.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 700; color: var(--ink-2); }
.input, .select, .textarea { width: 100%; min-height: 48px; padding: 0 14px; border-radius: 12px; border: 1.5px solid var(--line-2); background: #fff; font-size: 16px; font-weight: 500; color: var(--ink); }
.textarea { padding: 12px 14px; min-height: 90px; resize: vertical; }
.input::placeholder, .textarea::placeholder { color: #61757B; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--shell-2); box-shadow: 0 0 0 3px rgba(21, 88, 102, .18); }
.error-text { color: var(--poppy-ink); font-size: 14px; font-weight: 600; }

.seg { display: flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--tint); }
.seg button { flex: 1; min-height: 40px; border: 0; border-radius: 9px; background: transparent; font-weight: 700; font-size: 14px; color: var(--ink-2); }
.seg button[aria-pressed="true"] { background: #fff; color: var(--shell); box-shadow: 0 1px 3px rgba(16, 37, 43, .12); }

.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 32px; padding: 0 10px; border-radius: 8px; background: var(--tint); color: var(--shell); font-size: 14px; font-weight: 700; border: 0; }
.chip.add { background: transparent; border: 1.5px dashed #8FA5AB; color: var(--ink-3); font-weight: 600; }
.chip.toggle[aria-pressed="true"] { background: var(--shell); color: #fff; }
.chip .x { display: inline-flex; margin-right: -4px; opacity: .7; }

.switch { position: relative; width: 50px; height: 30px; border-radius: 15px; border: 0; background: #9FB2B7; flex: none; transition: background .2s; }
.switch::after { content: ""; position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 12px; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.2); transition: transform .25s var(--ease); }
.switch[aria-checked="true"] { background: var(--shell); }
.switch[aria-checked="true"]::after { transform: translateX(20px); }

/* ---------- person tags ---------- */
.dot { width: 22px; height: 22px; border-radius: 11px; display: inline-flex; align-items: center; justify-content: center; color: #fff; font-size: 11px; font-weight: 800; flex: none; }
.tag { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 9px 0 4px; border-radius: 13px; font-size: 13px; font-weight: 700; background: var(--tint); }

/* ---------- luggage label ---------- */
.lbl { position: relative; display: inline-block; background: var(--label); color: var(--ink); padding: 8px 16px 8px 26px; clip-path: polygon(12px 0, 100% 0, 100% 100%, 12px 100%, 0 calc(100% - 12px), 0 12px); transform: rotate(-3deg); box-shadow: 0 6px 14px rgba(5, 28, 34, .25); }
.lbl::before { content: ""; position: absolute; left: 8px; top: 50%; margin-top: -4.5px; width: 9px; height: 9px; border-radius: 5px; background: var(--shell); }
.lbl b { display: block; font-family: var(--display); font-weight: 900; font-size: 34px; line-height: .9; letter-spacing: .01em; text-transform: uppercase; }
.lbl small { display: block; font-size: 12px; font-weight: 800; margin-top: 3px; letter-spacing: .02em; }
.lbl.sm { padding: 5px 10px 5px 19px; clip-path: polygon(9px 0, 100% 0, 100% 100%, 9px 100%, 0 calc(100% - 9px), 0 9px); }
.lbl.sm::before { left: 6px; width: 7px; height: 7px; margin-top: -3.5px; }
.lbl.sm b { font-size: 20px; }

/* ---------- split-flap ---------- */
.flaps { display: flex; gap: 3px; perspective: 300px; }
.flap { position: relative; width: 30px; height: 42px; border-radius: 5px; background: var(--shell-deep); color: #F4F1E8; font: 800 32px/42px var(--display); text-align: center; overflow: hidden; box-shadow: inset 0 -1px 0 rgba(255,255,255,.05), 0 1px 2px rgba(0,0,0,.25); }
.flap::after { content: ""; position: absolute; left: 0; right: 0; top: calc(50% - .5px); height: 1px; background: var(--split); }
.flap.hot { color: #FFB4A3; }
.flap.go { color: var(--label); }
.flap.wide { width: auto; padding: 0 7px; }
.flap.sm { width: 24px; height: 34px; font-size: 26px; line-height: 34px; }
.flap span { display: block; transform-origin: 50% 50%; }
.flap.flip span { animation: flip .42s var(--ease); }
@keyframes flip { 0% { transform: rotateX(-88deg); filter: brightness(1.6); } 60% { transform: rotateX(12deg); } 100% { transform: rotateX(0); filter: none; } }
.flap-unit { font: 800 24px/1 var(--display); color: #F4F1E8; margin-left: 1px; align-self: flex-start; }
.counter { display: flex; flex-direction: column; gap: 5px; }
.counter > span { font-size: 11px; font-weight: 800; letter-spacing: .08em; color: var(--on-shell-2); text-transform: uppercase; }
@media (prefers-reduced-motion: reduce) { .flap.flip span { animation: none; } }

/* ---------- trip header ---------- */
.trip-top { position: relative; background: var(--shell); color: #fff; }
.photo { position: relative; height: 164px; background: var(--shell-2) center/cover no-repeat; }
.photo.none { height: 112px; background: linear-gradient(160deg, var(--shell-2), var(--shell)); }
.photo .scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(5,28,34,.45) 0%, rgba(5,28,34,0) 35%, rgba(5,28,34,0) 60%, rgba(5,28,34,.55) 100%); }
.photo .topbar { position: absolute; top: calc(10px + var(--safe-t)); left: 8px; right: 8px; display: flex; justify-content: space-between; align-items: center; }
.photo .topbar .icon-btn { background: rgba(10, 46, 55, .55); color: #fff; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.photo .credit { position: absolute; right: 10px; bottom: 8px; font-size: 11px; font-weight: 600; color: rgba(255,255,255,.92); text-shadow: 0 1px 2px rgba(0,0,0,.6); max-width: 55%; text-align: right; line-height: 1.3; }
.photo .credit a { color: inherit; }
@media (max-width: 999px) { .trip-top .photo .credit { right: auto; left: 12px; bottom: auto; top: calc(62px + var(--safe-t)); max-width: 70%; text-align: left; } }
.trip-top .photo > .lbl { position: absolute; left: 16px; bottom: -26px; z-index: 2; }
.live-pill { display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 12px 0 6px; border-radius: 16px; background: rgba(10, 46, 55, .7); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); font-size: 13px; font-weight: 700; max-width: 230px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.panel { padding: 36px 16px 12px; display: flex; flex-direction: column; gap: 12px; }
.counters { display: flex; gap: 18px; align-items: flex-end; flex-wrap: wrap; }
.wx-chips { display: flex; gap: 6px; flex-wrap: wrap; }
.wx-chip.extra { display: none; }
@media (min-width: 600px) { .wx-chip.extra { display: inline-flex; } }
.wx-chip { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 10px; border-radius: 8px; background: rgba(255,255,255,.1); color: #E4F0F2; font-size: 13px; font-weight: 700; }
.tabs { display: flex; gap: 4px; background: var(--shell-deep); border-radius: 12px; padding: 4px; }
.tabs a { flex: 1; height: 40px; display: flex; align-items: center; justify-content: center; border-radius: 9px; color: var(--on-shell-2); font-weight: 700; font-size: 15px; text-decoration: none; }
.tabs a[aria-current="page"] { background: #fff; color: var(--shell); font-weight: 800; }
.trip-top.compact { display: flex; align-items: center; gap: 12px; padding: calc(10px + var(--safe-t)) 16px 12px 8px; }
.trip-top.compact .icon-btn:hover { background: rgba(255,255,255,.1); }
.field { min-width: 0; }
.input[type="date"] { min-width: 0; -webkit-appearance: none; appearance: none; }
.trip-body { padding: 12px 12px 24px; display: flex; flex-direction: column; gap: 10px; }
.trip-cols { display: block; }
@media (min-width: 1000px) {
  .photo { height: 230px; }
  .trip-wrap { max-width: 1320px; margin: 0 auto; width: 100%; }
  .trip-top { border-radius: 0 0 20px 20px; overflow: hidden; }
  .trip-cols.both { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 20px; padding: 0 20px; }
  .trip-cols.both .tabs { display: none; }
  .tabs.wide-hide { display: none; }
}

/* ---------- pack list ---------- */
.groups { display: flex; flex-direction: column; }
.group { background: transparent; border-top: 1px solid #D3DDE0; border-radius: 0; overflow: hidden; transition: box-shadow .3s var(--ease), transform .3s var(--ease); }
.group.open { background: var(--card); border-radius: var(--radius); border-top-color: transparent; margin: 6px 0 10px; }
.group.open + .group { border-top-color: transparent; }
.group.open { box-shadow: 0 10px 28px rgba(14, 59, 70, .16), 0 2px 6px rgba(14, 59, 70, .08); }
.group-head { width: 100%; min-height: 58px; display: flex; align-items: center; gap: 10px; padding: 8px 14px; border: 0; background: transparent; text-align: left; }
.group-head h3 { font-size: 17px; font-weight: 800; flex: 1; min-width: 0; }
.group-count { font-size: 14px; font-weight: 700; color: var(--ink-3); }
.group-count.done { color: var(--ok); }
.chev { transition: transform .25s var(--ease); color: var(--ink-3); }
.group.open .chev { transform: rotate(180deg); }
.item { display: flex; align-items: center; gap: 4px; min-height: 56px; padding: 0 6px 0 4px; border-top: 1px solid var(--line); }
.item.packed .name { color: var(--ink-3); text-decoration: line-through; text-decoration-color: rgba(74,95,102,.5); }
.check { width: 52px; height: 52px; display: flex; align-items: center; justify-content: center; border: 0; background: transparent; flex: none; }
.box { width: 28px; height: 28px; border-radius: 8px; border: 2px solid var(--line-2); background: #fff; display: flex; align-items: center; justify-content: center; transition: background .15s, border-color .15s, transform .2s var(--ease); }
.check:active .box { transform: scale(.88); }
.packed .box { border-color: transparent; }
.item .body { flex: 1; min-width: 0; padding: 8px 0; }
.item .name { font-size: 16px; font-weight: 700; display: flex; align-items: baseline; gap: 6px; flex-wrap: wrap; }
.qty { font-family: var(--display); font-weight: 800; font-size: 18px; color: var(--shell-2); letter-spacing: .02em; }
.why { display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; color: var(--shell-2); background: var(--tint); border-radius: 6px; padding: 2px 7px; margin-top: 3px; line-height: 1.35; }
.who { display: block; font-size: 13px; color: var(--ink-3); font-weight: 600; }
.ptag { display: inline-flex; align-items: center; height: 28px; padding: 0 12px 0 18px; color: #fff; font-size: 16px; font-weight: 800; position: relative; clip-path: polygon(8px 0, 100% 0, 100% 100%, 8px 100%, 0 calc(100% - 8px), 0 8px); }
.ptag::before { content: ""; position: absolute; left: 6px; top: 50%; margin-top: -3px; width: 6px; height: 6px; border-radius: 3px; background: rgba(255,255,255,.85); }
.ptag.sm { height: 22px; font-size: 13px; padding: 0 8px 0 14px; clip-path: polygon(6px 0, 100% 0, 100% 100%, 6px 100%, 0 calc(100% - 6px), 0 6px); }
.ptag.sm::before { left: 5px; width: 5px; height: 5px; margin-top: -2.5px; }
.must { display: inline-flex; align-items: center; height: 20px; padding: 0 6px; border-radius: 5px; background: var(--poppy-soft); color: var(--poppy-ink); font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; }
.claim { font-size: 12px; font-weight: 700; color: var(--ink-3); }
.add-row { display: flex; gap: 8px; padding: 10px 12px 12px; border-top: 1px solid var(--line); }
.add-row .input { min-height: 44px; }

.missing-head { background: var(--poppy-soft); color: var(--poppy-ink); border-radius: var(--radius); padding: 14px 16px; display: flex; align-items: center; gap: 12px; }
.missing-head b { font-family: var(--display); font-size: 40px; font-weight: 900; line-height: .9; }

/* ---------- plan ---------- */
.stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.stat { display: flex; flex-direction: column; gap: 6px; padding: 10px; border-radius: 12px; background: var(--shell-2); }
.stat.rain { background: #1C5E83; }
.stat.cold { background: #3A4E8C; }
.stat > span { font-size: 12px; font-weight: 700; color: #D6E8EC; }
.day { display: grid; grid-template-columns: 46px 74px minmax(0, 1fr); column-gap: 10px; align-items: start; padding: 12px 14px; }
.day.rain { background: var(--rain-soft); }
.day.cold { background: var(--cold-soft); }
.dn { font-size: 12px; font-weight: 800; color: var(--ink-3); letter-spacing: .06em; text-transform: uppercase; }
.dd { font-family: var(--display); font-weight: 900; font-size: 28px; line-height: .95; }
.wx { display: flex; flex-direction: column; gap: 1px; font-size: 14px; font-weight: 800; }
.wx .s { font-size: 13px; font-weight: 600; color: var(--ink-3); }
.day.rain .wx .s { color: var(--rain); font-weight: 700; }
.day.cold .wx .t { color: var(--cold); }
.acts { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.sticky-cta { position: sticky; bottom: calc(76px + var(--safe-b)); padding: 10px 0 4px; background: linear-gradient(180deg, rgba(233,239,240,0), var(--ground) 30%); z-index: 5; }
@media (min-width: 1000px) { .sticky-cta { bottom: 0; } }

/* ---------- suggestions ---------- */
.sugg { display: flex; gap: 10px; align-items: flex-start; padding: 12px 10px 12px 4px; }
.sugg .body { flex: 1; min-width: 0; }
.sugg .t { font-weight: 800; }
.sugg .r { font-size: 14px; color: var(--ink-2); margin-top: 2px; }

/* ---------- trips home ---------- */
.hero { position: relative; display: block; text-decoration: none; color: inherit; border-radius: 20px; overflow: visible; background: var(--shell); box-shadow: 0 12px 30px rgba(14, 59, 70, .22); }
.hero .photo { border-radius: 20px 20px 0 0; height: 200px; }
.hero .photo.none { height: 120px; }
.hero .lbl { position: absolute; left: 14px; top: 160px; }
.hero .photo .credit { top: 10px; bottom: auto; }
.hero .photo.none + .lbl { top: 80px; }
.hero .foot { padding: 44px 16px 16px; color: #fff; display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; }
.trip-row { display: flex; align-items: center; gap: 12px; padding: 10px; text-decoration: none; color: inherit; min-height: 72px; }
.thumb .lbl.sm b { font-size: 15px; max-width: 72px; overflow: hidden; white-space: nowrap; }
.thumb { width: 96px; height: 64px; border-radius: 10px; background: var(--shell-2) center/cover; flex: none; position: relative; overflow: hidden; }
.thumb.none { background: linear-gradient(160deg, var(--shell-2), var(--shell)); }
.progress { height: 6px; border-radius: 3px; background: rgba(255,255,255,.18); overflow: hidden; }
.progress i { display: block; height: 100%; background: var(--label); border-radius: 3px; transition: width .5s var(--ease); }
.progress.light { background: var(--tint); }
.progress.light i { background: var(--shell-2); }
.empty { text-align: center; padding: 36px 20px; display: flex; flex-direction: column; align-items: center; gap: 12px; }
.empty h2 { font-size: 22px; font-weight: 800; }
.empty p { margin: 0; color: var(--ink-2); max-width: 34ch; }

/* ---------- photos ---------- */
.photos { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
.ph { position: relative; padding: 0; border: 0; border-radius: 12px; overflow: hidden; background: var(--tint); aspect-ratio: 3 / 2; }
.ph img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ph[aria-pressed="true"] { box-shadow: 0 0 0 3px var(--label); }
.ph .cr { position: absolute; left: 6px; right: 6px; bottom: 6px; font-size: 11px; font-weight: 600; color: #fff; background: rgba(10,46,55,.8); border-radius: 5px; padding: 2px 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; text-align: left; }
.swatches { display: flex; gap: 10px; }
.swatch { width: 44px; height: 44px; border-radius: 12px; border: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,.08); }
.swatch[aria-pressed="true"] { box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--shell); }
@media (min-width: 700px) { .photos { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- history ---------- */
.ev { display: flex; gap: 10px; padding: 12px 14px; align-items: flex-start; font-size: 15px; line-height: 1.4; }
.ev .when { font-size: 12px; color: var(--ink-3); white-space: nowrap; }
.via { display: inline-block; font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase; color: var(--ink-3); background: var(--tint); border-radius: 4px; padding: 0 5px; margin-left: 4px; vertical-align: 1px; }
.lesson { display: flex; justify-content: space-between; gap: 10px; padding: 10px 14px; font-size: 15px; }

/* ---------- sheet & toast ---------- */
.scrim-full { position: fixed; inset: 0; background: rgba(5, 28, 34, .45); z-index: 40; animation: fade .2s ease-out; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 41; max-height: 88dvh; overflow: auto; background: var(--card); border-radius: 22px 22px 0 0; padding: 8px 16px calc(20px + var(--safe-b)); box-shadow: 0 -10px 40px rgba(5, 28, 34, .25); animation: rise .35s var(--ease); }
.sheet .grab { width: 40px; height: 5px; border-radius: 3px; background: var(--line-2); margin: 4px auto 12px; }
.sheet h2 { font-size: 20px; font-weight: 800; margin-bottom: 12px; }
@media (min-width: 700px) { .sheet { left: 50%; right: auto; bottom: auto; top: 50%; width: 480px; transform: translate(-50%, -50%); border-radius: 22px; animation: fade .2s ease-out; } .sheet .grab { display: none; } }
@keyframes rise { from { transform: translateY(40%); opacity: .4; } }
@keyframes fade { from { opacity: 0; } }
.toasts { position: fixed; left: 12px; right: 12px; bottom: calc(80px + var(--safe-b)); z-index: 50; display: flex; flex-direction: column; align-items: center; gap: 8px; pointer-events: none; }
.toast { pointer-events: auto; display: flex; align-items: center; gap: 10px; max-width: 460px; padding: 10px 14px; border-radius: 14px; background: var(--ink); color: #fff; font-size: 14px; font-weight: 600; box-shadow: 0 8px 24px rgba(5, 28, 34, .3); animation: rise .3s var(--ease); }
.toast.err { background: var(--poppy-ink); }
.toast button { background: none; border: 0; color: var(--label); font-weight: 800; padding: 4px; }
@media (min-width: 1000px) { .toasts { bottom: 20px; left: 112px; } }

.code { font-family: ui-monospace, "SF Mono", Menlo, monospace; font-size: 13px; background: var(--shell-deep); color: #DDEBEE; border-radius: 12px; padding: 12px 14px; white-space: pre; overflow-x: auto; line-height: 1.55; }
.spinner { width: 22px; height: 22px; border-radius: 50%; border: 3px solid var(--tint); border-top-color: var(--shell-2); animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.center { display: flex; align-items: center; justify-content: center; padding: 40px; }
