/* Chordmates — styles
   Mobile first: built like a phone app (top bar, bottom tabs, simple lists).
   On a wide screen the tabs move to a sidebar and the content stays in one readable column.
   All sizes are in rem, so "Larger text" scales the whole app. */

:root {
  --bg: #F6F6F2;
  --surface: #FFFFFF;
  --surface-2: #F0F0EA;
  --ink: #1B2140;
  --ink-2: #363C5A;
  --muted: #4E546E;
  --line: #DEDED6;
  --line-2: #EBEBE4;

  --brand: #2B45C9;
  --brand-hover: #2237A8;
  --brand-ink: #FFFFFF;
  --brand-soft: #E6EAFB;
  --brand-text: #2238B0;
  --plum: #8A3FA0; --plum-soft: #F3E6F7; --plum-text: #74308A;
  --coral: #E4572E; --coral-soft: #FDE8E1; --coral-text: #B23A16;
  --sun: #F2B01E; --sun-soft: #FDF1D2; --sun-text: #855600;
  --teal: #0F8C80; --teal-soft: #DDF3F0; --teal-text: #0B6B62;
  --star: #D99A00;

  --glass: rgba(255, 255, 255, .8);
  --glass-line: rgba(27, 33, 64, .09);
  --hl: rgba(255, 255, 255, .9);
  --scrim: rgba(17, 20, 38, .45);
  --shadow-sm: 0 1px 2px rgba(27, 33, 64, .06);
  --shadow: 0 1px 2px rgba(27, 33, 64, .05), 0 12px 30px rgba(27, 33, 64, .08);
  --shadow-lg: 0 30px 70px rgba(27, 33, 64, .25);

  --font: 'Atkinson Hyperlegible', 'Segoe UI', system-ui, -apple-system, sans-serif;
  --display: 'Bricolage Grotesque', 'Atkinson Hyperlegible', system-ui, sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --bar: 3.6rem;
  --tabs: 4.4rem;
  color-scheme: light;
  font-size: 17px;
}
:root.text-lg { font-size: 20px; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #111320; --surface: #1A1D2E; --surface-2: #23273B;
    --ink: #EEF0F8; --ink-2: #C9CDE0; --muted: #A9AEC6; --line: #2F344E; --line-2: #272B42;
    --brand: #4A63F0; --brand-hover: #6078FF; --brand-soft: #232B5C; --brand-text: #AEBBFF;
    --plum-soft: #33203B; --plum-text: #DDA8EE; --coral-soft: #3A2019; --coral-text: #FFA388;
    --sun-soft: #3A2E10; --sun-text: #FFD36E; --teal-soft: #0F2E2B; --teal-text: #62D8CA; --star: #FFC23D;
    --glass: rgba(20, 22, 36, .8); --glass-line: rgba(255, 255, 255, .07); --hl: rgba(255, 255, 255, .06); --scrim: rgba(0, 0, 0, .6);
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4); --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 30px rgba(0, 0, 0, .35); --shadow-lg: 0 30px 70px rgba(0, 0, 0, .6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #111320; --surface: #1A1D2E; --surface-2: #23273B;
  --ink: #EEF0F8; --ink-2: #C9CDE0; --muted: #A9AEC6; --line: #2F344E; --line-2: #272B42;
  --brand: #4A63F0; --brand-hover: #6078FF; --brand-soft: #232B5C; --brand-text: #AEBBFF;
  --plum-soft: #33203B; --plum-text: #DDA8EE; --coral-soft: #3A2019; --coral-text: #FFA388;
  --sun-soft: #3A2E10; --sun-text: #FFD36E; --teal-soft: #0F2E2B; --teal-text: #62D8CA; --star: #FFC23D;
  --glass: rgba(20, 22, 36, .8); --glass-line: rgba(255, 255, 255, .07); --hl: rgba(255, 255, 255, .06); --scrim: rgba(0, 0, 0, .6);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4); --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 12px 30px rgba(0, 0, 0, .35); --shadow-lg: 0 30px 70px rgba(0, 0, 0, .6);
  color-scheme: dark;
}
:root.text-bold body { font-weight: 700; }
:root.text-bold .muted, :root.text-bold .sub, :root.text-bold .hint { color: var(--ink-2); }

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html, body { min-height: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font); font-size: 1rem; line-height: 1.5; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
h1, h2, h3 { margin: 0; line-height: 1.2; text-wrap: balance; }
p { margin: 0; }
a { color: var(--brand-text); text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 10px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.tnum { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.small { font-size: .9rem; }
.stack { display: flex; flex-direction: column; gap: .75rem; }
.hstack { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }

.ic { width: 1.3rem; height: 1.3rem; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }
.ic.lg { width: 1.6rem; height: 1.6rem; }
.ic.sm { width: 1.05rem; height: 1.05rem; }
.ic.xs { width: .9rem; height: .9rem; }
.ic.fill { fill: currentColor; stroke: none; }

/* ---------- Logo ---------- */
.logo { display: inline-flex; align-items: center; gap: .55rem; color: var(--ink); }
.logo svg { flex-shrink: 0; border-radius: 22%; }
.word { font-family: var(--display); font-weight: 800; font-size: 1.4rem; letter-spacing: -.03em; line-height: 1; }
.word b { color: var(--brand-text); font-weight: 800; }
.mark.anim .stick-a { transform-origin: 15px 54px; animation: hitA .42s ease-in-out infinite alternate; }
.mark.anim .stick-b { transform-origin: 49px 54px; animation: hitB .42s .21s ease-in-out infinite alternate; }
.mark.anim .note { animation: bob .84s ease-in-out infinite alternate; }

/* ---------- Splash ---------- */
.splash { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; background: var(--bg); transition: opacity .5s var(--ease), visibility .5s; }
.splash.done { opacity: 0; visibility: hidden; }
.splash-in { display: flex; flex-direction: column; align-items: center; gap: 1.2rem; }
.splash-in svg { animation: pop .7s var(--ease) both; filter: drop-shadow(0 18px 30px rgba(43, 69, 201, .35)); }
.splash .word { font-size: 2.3rem; animation: up .6s .15s var(--ease) both; }
.splash-bar { width: 10rem; height: 5px; border-radius: 5px; background: var(--line); overflow: hidden; }
.splash-bar i { display: block; height: 100%; width: 0; border-radius: 5px; background: linear-gradient(90deg, var(--plum), var(--coral), var(--sun), var(--teal)); animation: load 1.3s .3s cubic-bezier(.6, 0, .2, 1) forwards; }
.splash-note { color: var(--muted); }

/* ---------- Buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .45rem; min-height: 2.9rem; padding: 0 1.1rem; border-radius: 999px; font-weight: 700; font-size: .95rem; line-height: 1.1; white-space: nowrap; border: 1.5px solid transparent; background: none; transition: transform .15s var(--ease), background .2s, box-shadow .2s, color .2s, border-color .2s; }
.btn:active { transform: scale(.97); }
.btn-primary { background: var(--brand); color: var(--brand-ink); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25), 0 6px 16px color-mix(in srgb, var(--brand) 28%, transparent); }
.btn-primary:hover { background: var(--brand-hover); color: var(--brand-ink); }
.btn-glass { background: color-mix(in srgb, var(--surface) 75%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border-color: var(--line); color: var(--ink); box-shadow: inset 0 1px 0 var(--hl), var(--shadow-sm); }
.btn-glass:hover { background: var(--surface-2); color: var(--ink); }
.btn-ghost { color: var(--ink-2); }
.btn-ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn.is-on { background: var(--teal-soft); color: var(--teal-text); border-color: transparent; box-shadow: none; }
.btn-danger { color: var(--coral-text); }
.btn-sm { min-height: 2.5rem; padding: 0 .95rem; font-size: .9rem; }
.btn-lg { min-height: 3.3rem; padding: 0 1.5rem; font-size: 1.05rem; }
.btn-block { width: 100%; }
.icon-btn { width: 2.9rem; min-height: 2.9rem; padding: 0; position: relative; border-radius: 50%; }
.btn-row { display: flex; gap: .5rem; }
.btn-row > * { flex: 1; }

/* ---------- App shell (phone first) ---------- */
.app { min-height: 100vh; }
.side { display: none; }
.main { min-width: 0; }
.desk-only { display: none; }
body.in-chat .tabs { display: none; }
.bar {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 40;
  height: var(--bar); display: flex; align-items: center; gap: .4rem; padding-inline: 12px;
  background: var(--glass); -webkit-backdrop-filter: saturate(180%) blur(18px); backdrop-filter: saturate(180%) blur(18px);
  border-bottom: 1px solid var(--glass-line);
}
.bar-title { flex: 1; min-width: 0; display: flex; align-items: center; gap: .5rem; padding-left: .3rem; }
.bar-title h1 { font-size: 1.2rem; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bar-actions { display: flex; align-items: center; gap: .1rem; }
.count { position: absolute; top: .25rem; right: .2rem; min-width: 1.2rem; height: 1.2rem; padding: 0 .3rem; border-radius: 999px; background: var(--coral); color: #fff; font-size: .7rem; font-weight: 700; display: grid; place-items: center; box-shadow: 0 0 0 2px var(--surface); line-height: 1; }

.page { padding-inline: 16px; padding-block: 1rem calc(var(--tabs) + 2rem + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 1.1rem; max-width: 40rem; margin-inline: auto; }
.page.flush { padding-block-start: 0; }

.tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
  display: grid; grid-template-columns: repeat(5, minmax(0, 1fr));
  padding: .3rem .4rem calc(.3rem + env(safe-area-inset-bottom, 0px));
  background: var(--glass); -webkit-backdrop-filter: saturate(180%) blur(18px); backdrop-filter: saturate(180%) blur(18px);
  border-top: 1px solid var(--glass-line);
}
.tabs button { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .15rem; min-height: 3.5rem; border: 0; background: none; color: var(--muted); font-size: .76rem; font-weight: 700; border-radius: 14px; }
.tabs button[aria-current="page"] { color: var(--brand-text); }
.tabs button[aria-current="page"] .ic { stroke-width: 2.4; }
.tabs .count { top: .2rem; right: calc(50% - 1.4rem); }

/* ---------- Wide screens ---------- */
@media (min-width: 960px) {
  .app { display: grid; grid-template-columns: 16.5rem minmax(0, 1fr); }
  .side { display: flex; flex-direction: column; gap: 1rem; position: sticky; top: 0; height: 100vh; padding: 1.2rem 1rem; border-right: 1px solid var(--line); background: var(--surface); overflow-y: auto; }
  .side .logo { padding: .3rem .6rem 1rem; }
  .tabs { display: none; }
  .bar .home-logo { display: none; }
  .desk-only { display: block; }
  .bar { padding-inline: 24px; }
  .page { padding-block: 1.5rem 3rem; }
}
.nav { display: flex; flex-direction: column; gap: .2rem; }
.nav button { position: relative; display: flex; align-items: center; gap: .85rem; min-height: 3.1rem; padding: 0 .9rem; border-radius: 14px; border: 0; background: none; color: var(--ink-2); font-weight: 700; text-align: left; transition: background .2s; }
.nav button:hover { background: var(--surface-2); color: var(--ink); }
.nav button[aria-current="page"] { background: var(--brand-soft); color: var(--brand-text); }
.nav .count { position: static; margin-left: auto; box-shadow: none; }
.side-foot { margin-top: auto; display: flex; flex-direction: column; gap: .2rem; border-top: 1px solid var(--line); padding-top: .8rem; }

/* ---------- Common pieces ---------- */
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-sm); }
.pad { padding: 1rem; }
.section { display: flex; flex-direction: column; gap: .6rem; }
.section-title { display: flex; align-items: baseline; justify-content: space-between; gap: .75rem; }
.section-title h2 { font-size: 1.1rem; }
.section-title button { border: 0; background: none; color: var(--brand-text); font-weight: 700; padding: .3rem 0; }
.page-intro { color: var(--muted); }

.av { --s: 2.8rem; width: var(--s); height: var(--s); border-radius: 50%; flex-shrink: 0; display: inline-grid; place-items: center; font-weight: 700; font-size: calc(var(--s) * .36); letter-spacing: .02em; }
.av.sq { border-radius: 28%; }
.av.c-plum { background: var(--plum); color: #fff; }
.av.c-coral { background: var(--coral); color: #fff; }
.av.c-sun { background: var(--sun); color: #1B2140; }
.av.c-teal { background: var(--teal); color: #fff; }
.av.c-brand { background: var(--brand); color: #fff; }

.chip { display: inline-flex; align-items: center; gap: .3rem; min-height: 1.8rem; padding: 0 .65rem; border-radius: 999px; background: var(--surface-2); font-size: .82rem; font-weight: 700; color: var(--ink-2); white-space: nowrap; border: 1px solid transparent; }
.t-brand { background: var(--brand-soft); color: var(--brand-text); }
.t-plum { background: var(--plum-soft); color: var(--plum-text); }
.t-coral { background: var(--coral-soft); color: var(--coral-text); }
.t-sun { background: var(--sun-soft); color: var(--sun-text); }
.t-teal { background: var(--teal-soft); color: var(--teal-text); }
.chips { display: flex; flex-wrap: wrap; gap: .4rem; }

/* horizontally scrolling filter chips, like most apps */
.scroller { display: flex; gap: .5rem; overflow-x: auto; margin-inline: -16px; padding: .1rem 16px .3rem; scrollbar-width: none; }
.scroller::-webkit-scrollbar { display: none; }
.pill { flex-shrink: 0; min-height: 2.5rem; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); font-weight: 700; font-size: .92rem; color: var(--ink-2); }
.pill[aria-pressed="true"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }

.seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: .25rem; padding: .25rem; border-radius: 14px; background: var(--surface-2); }
.seg button { min-height: 2.6rem; border: 0; border-radius: 11px; background: transparent; font-weight: 700; font-size: .95rem; color: var(--muted); padding: 0 .4rem; transition: background .25s var(--ease), color .2s; }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: var(--shadow-sm); }
.seg .n { font-variant-numeric: tabular-nums; opacity: .75; }

.stars { display: inline-flex; align-items: center; gap: .1rem; color: var(--star); }
.stars b { color: var(--ink); margin-left: .25rem; font-size: .9rem; }
.stars small { color: var(--muted); font-size: .85rem; margin-left: .15rem; }
.verified { display: inline-flex; align-items: center; gap: .3rem; font-size: .82rem; font-weight: 700; color: var(--teal-text); }
.pending { display: inline-flex; align-items: center; gap: .3rem; font-size: .82rem; font-weight: 700; color: var(--sun-text); }
.dot-live { width: .5rem; height: .5rem; border-radius: 50%; background: var(--teal); display: inline-block; }

/* ---------- Lists (like phone settings and contacts) ---------- */
.list { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; overflow: hidden; }
.row { display: flex; align-items: center; gap: .8rem; padding: .8rem 1rem; min-height: 3.6rem; width: 100%; text-align: left; border: 0; background: none; color: var(--ink); }
.list > * + * { border-top: 1px solid var(--line-2); }
button.row:hover, .row.tap:hover { background: var(--surface-2); }
.row-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .1rem; }
.row-main .t { font-weight: 700; display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; line-height: 1.3; }
.row-main .sub { color: var(--muted); font-size: .9rem; line-height: 1.35; }
.row-main .sub.clip { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-end { display: flex; align-items: center; gap: .4rem; flex-shrink: 0; }
.chev { color: var(--muted); }
.row .open { border: 0; background: none; padding: 0; flex: 1; min-width: 0; display: flex; align-items: center; gap: .8rem; text-align: left; color: inherit; }
.match { font-size: .78rem; font-weight: 700; padding: .15rem .55rem; border-radius: 999px; background: var(--plum-soft); color: var(--plum-text); white-space: nowrap; }
.row.ev { gap: .6rem; padding-inline: .8rem; }
.row.ev .open { gap: .7rem; }
.row.ev .row-main .t { font-size: .98rem; }
.row.ev .btn-sm { padding: 0 .75rem; }
.featured-row { background: linear-gradient(90deg, var(--sun-soft), transparent 70%); }

.date-tile { width: 3.3rem; min-height: 3.6rem; border-radius: 12px; flex-shrink: 0; overflow: hidden; display: flex; flex-direction: column; text-align: center; background: var(--surface); border: 1.5px solid var(--line); }
.date-tile b { display: block; background: var(--coral); color: #fff; font-size: .68rem; letter-spacing: .08em; padding: .12rem 0; }
.date-tile span { flex: 1; display: grid; place-items: center; font-weight: 700; font-size: 1.1rem; line-height: 1; }
.date-tile small { font-size: .66rem; color: var(--muted); padding-bottom: .2rem; font-weight: 700; }

/* ---------- Switches (settings) ---------- */
.switch { position: relative; width: 3.2rem; height: 1.9rem; border-radius: 999px; border: 0; background: var(--line); flex-shrink: 0; transition: background .2s; padding: 0; }
.switch::after { content: ""; position: absolute; top: .2rem; left: .2rem; width: 1.5rem; height: 1.5rem; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .25s var(--ease); }
.switch[aria-checked="true"] { background: var(--teal); }
.switch[aria-checked="true"]::after { transform: translateX(1.3rem); }
.group-label { font-size: .82rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 0 .3rem; }

/* ---------- Feed ---------- */
.people-row { display: flex; gap: .9rem; overflow-x: auto; margin-inline: -16px; padding: .2rem 16px .4rem; scrollbar-width: none; }
.people-row::-webkit-scrollbar { display: none; }
.person-bubble { display: flex; flex-direction: column; align-items: center; gap: .3rem; width: 4.4rem; flex-shrink: 0; border: 0; background: none; padding: 0; color: var(--ink-2); font-size: .8rem; font-weight: 700; }
.person-bubble .ring { padding: 3px; border-radius: 50%; background: conic-gradient(var(--plum), var(--coral), var(--sun), var(--teal), var(--plum)); }
.person-bubble .ring .av { box-shadow: 0 0 0 3px var(--bg); }
.person-bubble span:last-child { max-width: 4.4rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.share-row { display: flex; align-items: center; gap: .7rem; padding: .7rem .8rem; }
.share-row button.fake-input { flex: 1; min-height: 2.9rem; text-align: left; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface-2); color: var(--muted); }

.post { overflow: hidden; }
.post-head { display: flex; align-items: center; gap: .7rem; padding: .8rem 1rem; }
.post-head .who { flex: 1; min-width: 0; border: 0; background: none; padding: 0; text-align: left; color: var(--ink); display: flex; align-items: center; gap: .7rem; }
.post-head .who b { display: block; }
.post-head .who small { color: var(--muted); font-size: .85rem; }
.post-text { padding: 0 1rem .8rem; }
.post-actions { display: flex; align-items: center; gap: .1rem; padding: .3rem .5rem; }
.post-actions .btn { min-height: 2.75rem; padding: 0 .7rem; color: var(--ink-2); }
.post-actions .spacer { flex: 1; }
.like.on { color: var(--coral-text); }
.like.on .ic { fill: currentColor; animation: pop .35s var(--ease); }
.comments { display: flex; flex-direction: column; gap: .5rem; padding: 0 1rem 1rem; }
.comment { font-size: .95rem; }
.reply { display: flex; gap: .5rem; }
.reply input { flex: 1; min-width: 0; min-height: 2.75rem; padding: 0 .9rem; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface-2); color: var(--ink); outline: 0; }
.reply input:focus { border-color: var(--brand); }
.promo-label { font-size: .78rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .07em; }

.video { position: relative; overflow: hidden; aspect-ratio: 4 / 5; max-height: 34rem; width: 100%; background: var(--va); isolation: isolate; }
.video::before { content: ""; position: absolute; width: 80%; aspect-ratio: 1; border-radius: 50%; right: -22%; top: -18%; background: var(--vb); opacity: .9; }
.video::after { content: ""; position: absolute; width: 42%; aspect-ratio: 1; border-radius: 50%; left: -10%; bottom: -8%; background: #FFC23D; opacity: .85; }
.v-art { position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255, 255, 255, .22); z-index: 1; }
.v-art .ic { width: 38%; height: 38%; stroke-width: 1.1; }
.v-bars { position: absolute; left: 1rem; right: 1rem; bottom: 3.4rem; height: 3rem; display: flex; align-items: flex-end; gap: 3px; z-index: 2; }
.v-bars i { flex: 1; background: rgba(255, 255, 255, .8); border-radius: 2px; transform-origin: bottom; transform: scaleY(.2); }
.video.playing .v-bars i { animation: vbar .45s ease-in-out infinite alternate; }
.v-title { position: absolute; left: .9rem; top: .9rem; z-index: 2; color: #fff; font-weight: 700; background: rgba(17, 20, 38, .5); padding: .3rem .75rem; border-radius: 999px; font-size: .88rem; max-width: calc(100% - 1.8rem); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.v-play { position: absolute; left: 50%; top: 45%; transform: translate(-50%, -50%); z-index: 3; width: 4.6rem; height: 4.6rem; border-radius: 50%; border: 2px solid rgba(255, 255, 255, .75); background: rgba(255, 255, 255, .22); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); color: #fff; display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); transition: opacity .3s; }
.v-play .ic { width: 1.9rem; height: 1.9rem; }
.video.playing .v-play { opacity: 0; }
.video.playing:hover .v-play, .video.playing .v-play:focus-visible { opacity: 1; }
.v-foot { position: absolute; left: 0; right: 0; bottom: 0; z-index: 2; padding: .75rem 1rem; display: flex; align-items: center; gap: .7rem; color: #fff; background: linear-gradient(transparent, rgba(17, 20, 38, .6)); font-size: .85rem; font-weight: 700; }
.v-track { flex: 1; height: 5px; border-radius: 5px; background: rgba(255, 255, 255, .35); overflow: hidden; }
.v-track i { display: block; height: 100%; width: 0; background: #fff; border-radius: 5px; }
.media-real { width: 100%; background: #000; max-height: 34rem; display: block; object-fit: contain; }

/* ---------- Profile (like a social profile) ---------- */
.p-top { display: flex; align-items: center; gap: 1.1rem; }
.p-stats { flex: 1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); text-align: center; }
.p-stats b { display: block; font-size: 1.2rem; font-variant-numeric: tabular-nums; }
.p-stats span { font-size: .82rem; color: var(--muted); }
.p-name h2 { font-size: 1.25rem; display: flex; align-items: center; gap: .4rem; flex-wrap: wrap; }
.p-kind { font-size: .78rem; font-weight: 700; letter-spacing: .07em; text-transform: uppercase; }
.p-line { color: var(--muted); font-size: .95rem; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 3px; margin-inline: -16px; }
.tile { position: relative; aspect-ratio: 1; border: 0; padding: 0; overflow: hidden; background: var(--va, var(--surface-2)); color: #fff; display: block; width: 100%; }
.tile::before { content: ""; position: absolute; width: 90%; aspect-ratio: 1; border-radius: 50%; right: -30%; top: -30%; background: var(--vb, transparent); opacity: .9; }
.tile .ic { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 34%; height: 34%; color: rgba(255, 255, 255, .5); stroke-width: 1.3; }
.tile .dur { position: absolute; left: .4rem; bottom: .35rem; font-size: .75rem; font-weight: 700; display: inline-flex; align-items: center; gap: .2rem; text-shadow: 0 1px 3px rgba(0, 0, 0, .4); }
.tile.text { background: var(--surface-2); color: var(--ink-2); padding: .5rem; font-size: .78rem; text-align: left; line-height: 1.3; }
.tile.text span { display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.tile img, .tile video { width: 100%; height: 100%; object-fit: cover; }
.exp { display: flex; gap: .8rem; padding: .9rem 1rem; }
.exp > div { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .2rem; }
.exp-top { display: flex; justify-content: space-between; gap: .6rem; flex-wrap: wrap; align-items: baseline; }
.exp h3 { font-size: 1rem; }
.quote { font-size: .93rem; color: var(--ink-2); border-left: 3px solid var(--line); padding-left: .7rem; }
.trust { display: flex; align-items: center; gap: 1rem; padding: 1rem; border-radius: 16px; background: var(--teal-soft); }
.trust .big { font-family: var(--display); font-size: 2.3rem; font-weight: 800; line-height: 1; color: var(--ink); }
.trust p { color: var(--ink-2); font-size: .92rem; }
.bar-meter { height: .5rem; border-radius: 1rem; background: var(--line-2); overflow: hidden; }
.bar-meter i { display: block; height: 100%; border-radius: 1rem; background: var(--brand); }
.avail { display: grid; grid-template-columns: 3.6rem repeat(7, minmax(0, 1fr)); gap: .3rem; align-items: center; font-size: .8rem; color: var(--muted); }
.avail .d { text-align: center; font-weight: 700; color: var(--ink-2); }
.avail .c { height: 1.7rem; border-radius: 7px; background: var(--surface-2); display: grid; place-items: center; }
.avail .c.on { background: var(--teal-soft); color: var(--teal-text); }
.slots { display: flex; align-items: center; padding-left: .5rem; }
.slots .av, .slot { margin-left: -.5rem; box-shadow: 0 0 0 3px var(--surface); }
.slot { width: 2.2rem; height: 2.2rem; border-radius: 50%; display: grid; place-items: center; border: 2px dashed var(--sun); color: var(--sun-text); background: var(--sun-soft); }

/* ---------- Cards for acts (venue) ---------- */
.act { padding: 1rem; display: flex; flex-direction: column; gap: .7rem; }
.act-top { display: flex; align-items: center; gap: .8rem; }
.act-top .open { border: 0; background: none; padding: 0; flex: 1; min-width: 0; display: flex; align-items: center; gap: .8rem; text-align: left; color: inherit; }
.act-msg { background: var(--surface-2); border-radius: 14px; padding: .6rem .8rem; font-size: .95rem; }

/* ---------- Choice cards ---------- */
.choice { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.choice button { display: flex; flex-direction: column; align-items: flex-start; gap: .35rem; padding: 1rem; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); text-align: left; }
.choice button[aria-pressed="true"] { border-color: var(--sun); box-shadow: 0 0 0 4px var(--sun-soft); }
.choice b { font-size: 1rem; line-height: 1.25; }
.choice span:last-child { color: var(--muted); font-size: .85rem; line-height: 1.3; }
.badge { width: 2.2rem; height: 2.2rem; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; }

.banner { display: flex; gap: .8rem; align-items: center; padding: .9rem 1rem; }
.banner > div { flex: 1; min-width: 0; }
.banner.sun { background: linear-gradient(120deg, var(--sun-soft), var(--surface) 80%); }
.banner.brand { background: linear-gradient(120deg, var(--brand-soft), var(--surface) 80%); }

/* ---------- Messages ---------- */
.chat-page { display: flex; flex-direction: column; min-height: calc(100vh - var(--bar)); max-width: 40rem; margin-inline: auto; }
.msgs { flex: 1; padding: 1rem 16px; display: flex; flex-direction: column; gap: .55rem; }
.msg { max-width: 82%; padding: .6rem .9rem; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); align-self: flex-start; overflow-wrap: anywhere; }
.msg.me { align-self: flex-end; background: var(--brand); color: var(--brand-ink); border-color: transparent; }
.msg small { display: block; font-size: .72rem; opacity: .75; margin-top: .15rem; }
.msg.ai { background: var(--plum-soft); border-color: transparent; }
.msg.ai .ai-label { display: flex; align-items: center; gap: .3rem; font-size: .75rem; font-weight: 700; color: var(--plum-text); margin-bottom: .2rem; }
.msg.system { align-self: center; max-width: 94%; background: var(--teal-soft); color: var(--teal-text); border-color: transparent; font-weight: 700; font-size: .88rem; text-align: center; border-radius: 14px; }
.msg.system small { display: none; }
.msg.new { animation: up .35s var(--ease) both; }
.typing { align-self: flex-start; display: flex; gap: .25rem; align-items: center; padding: .7rem .9rem; border-radius: 20px; background: var(--surface); border: 1px solid var(--line); }
.typing i { width: .45rem; height: .45rem; border-radius: 50%; background: var(--muted); animation: bob .5s ease-in-out infinite alternate; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
.chat-form { position: sticky; bottom: 0; display: flex; gap: .5rem; padding: .7rem 16px calc(.7rem + env(safe-area-inset-bottom, 0px)); background: var(--glass); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); border-top: 1px solid var(--glass-line); }
.chat-form input { flex: 1; min-width: 0; min-height: 2.9rem; padding: 0 1rem; border-radius: 999px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); outline: 0; }
.chat-form input:focus { border-color: var(--brand); }
.chat-head { display: flex; align-items: center; gap: .5rem; flex: 1; min-width: 0; border: 0; background: none; padding: 0; color: var(--ink); text-align: left; }
.chat-head b { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chat-head small { display: block; color: var(--muted); font-size: .8rem; }
.unread-dot { width: .7rem; height: .7rem; border-radius: 50%; background: var(--coral); }

/* ---------- Sheets, fields, toast ---------- */
.scrim { position: fixed; inset: 0; z-index: 80; background: var(--scrim); display: grid; place-items: end center; animation: fade .2s ease both; overflow-y: auto; }
.sheet { width: 100%; max-width: 32rem; padding: 1.2rem 16px calc(1.3rem + env(safe-area-inset-bottom, 0px)); display: flex; flex-direction: column; gap: 1rem; border-radius: 24px 24px 0 0; border-bottom: 0; box-shadow: var(--shadow-lg); animation: sheetUp .35s var(--ease) both; max-height: 92vh; overflow-y: auto; }
.sheet::before { content: ""; width: 2.6rem; height: .3rem; border-radius: 1rem; background: var(--line); align-self: center; margin-top: -.4rem; }
@media (min-width: 700px) { .scrim { place-items: center; padding: 16px; } .sheet { border-radius: 24px; border-bottom: 1px solid var(--line); animation-name: sheet; } .sheet::before { display: none; } }
.sheet-head { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.sheet-head h2 { font-size: 1.25rem; }
.field { display: flex; flex-direction: column; gap: .35rem; }
.field label, .field .label { font-size: .92rem; font-weight: 700; color: var(--ink-2); }
.field input, .field select, .field textarea { min-height: 3.1rem; padding: 0 .9rem; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); outline: 0; width: 100%; }
.field textarea { min-height: 6rem; padding: .7rem .9rem; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.field input[aria-invalid="true"] { border-color: var(--coral); }
.err { color: var(--coral-text); font-size: .88rem; font-weight: 700; }
.hint { font-size: .85rem; color: var(--muted); }
.pw { position: relative; }
.pw input { padding-right: 4.8rem; }
.pw button { position: absolute; right: .35rem; top: 50%; transform: translateY(-50%); min-height: 2.4rem; padding: 0 .8rem; border-radius: 10px; border: 0; background: var(--surface-2); font-weight: 700; font-size: .85rem; color: var(--ink-2); }
.rules { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .3rem .8rem; font-size: .85rem; color: var(--muted); }
.rules li { display: flex; align-items: center; gap: .35rem; }
.rules li.ok { color: var(--teal-text); font-weight: 700; }
.strength { height: .4rem; border-radius: 1rem; background: var(--line-2); overflow: hidden; }
.strength i { display: block; height: 100%; width: 0; border-radius: 1rem; transition: width .3s var(--ease), background .3s; }
.options { display: flex; flex-direction: column; gap: .5rem; border: 0; padding: 0; margin: 0; }
.option { display: flex; align-items: center; gap: .8rem; padding: .8rem 1rem; border-radius: 14px; border: 2px solid var(--line); background: var(--surface); cursor: pointer; }
.option:has(input:checked) { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.option input { accent-color: var(--brand); width: 1.15rem; height: 1.15rem; margin: 0; flex-shrink: 0; }
.option > span { flex: 1; }
.option b { display: block; }
.option small { color: var(--muted); }
.option .price { font-weight: 800; font-variant-numeric: tabular-nums; }
.pay-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .5rem; }
.pay-row .option { justify-content: center; padding: .7rem .4rem; font-weight: 700; }
.slots-pick { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .5rem; }
.slots-pick .pill { min-height: 3rem; }
.toast { position: fixed; left: 50%; bottom: calc(var(--tabs) + 1rem + env(safe-area-inset-bottom, 0px)); z-index: 90; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; display: flex; align-items: center; gap: .6rem; padding: .8rem 1.2rem; border-radius: 18px; background: var(--ink); color: var(--bg); font-weight: 700; box-shadow: var(--shadow-lg); transition: transform .35s var(--ease), opacity .35s var(--ease); width: max-content; max-width: calc(100% - 32px); }
.toast.show { transform: translate(-50%, 0); opacity: 1; }
@media (min-width: 960px) { .toast { bottom: 1.5rem; left: calc(50% + 8.25rem); } }
.cal-btns { display: flex; flex-direction: column; gap: .5rem; }
.cal-btns .btn { justify-content: flex-start; }

/* ---------- Login ---------- */
.welcome { min-height: 100vh; display: grid; grid-template-columns: minmax(0, 1fr); }
.poster { position: relative; overflow: hidden; background: #2B45C9; color: #fff; padding: 1.4rem 16px 1.8rem; display: flex; flex-direction: column; gap: 1.2rem; }
.poster .word { color: #fff; }
.poster .word b { color: #FFC23D; }
.poster .logo svg { box-shadow: 0 0 0 3px rgba(255, 255, 255, .55); }
.poster h2 { font-family: var(--display); font-size: 2rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.05; max-width: 14ch; position: relative; z-index: 1; }
.poster p { max-width: 34ch; opacity: .92; position: relative; z-index: 1; }
.shape { position: absolute; border-radius: 50%; }
.shape.a { width: 12rem; height: 12rem; background: #FFC23D; right: -4rem; top: -4rem; }
.shape.b { width: 7rem; height: 7rem; background: #FF6B4A; right: 2rem; bottom: -3.5rem; }
.shape.c { width: 9rem; height: 9rem; background: #8A3FA0; left: -3rem; bottom: 6rem; display: none; }
.shape.d { width: 5rem; height: 5rem; background: #1FB3A5; right: 13rem; top: 11rem; display: none; }
.login { padding-block: 1.6rem 2.5rem; padding-inline: 16px; display: flex; justify-content: center; }
.login-in { width: 100%; max-width: 30rem; display: flex; flex-direction: column; gap: 1.1rem; }
.login-in h1 { font-family: var(--display); font-size: 1.8rem; font-weight: 800; letter-spacing: -.02em; }
.roles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .6rem; }
.role { display: flex; align-items: center; gap: .6rem; text-align: left; padding: .8rem; border-radius: 16px; border: 2px solid var(--line); background: var(--surface); font-weight: 700; }
.role[aria-checked="true"] { border-color: var(--brand); box-shadow: 0 0 0 4px var(--brand-soft); }
.link-btn { border: 0; background: none; padding: .3rem 0; color: var(--brand-text); font-weight: 700; align-self: flex-start; }
@media (min-width: 900px) {
  .welcome { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .poster { min-height: 100vh; padding: 2.5rem; justify-content: space-between; }
  .poster h2 { font-size: clamp(2.4rem, 4vw, 3.4rem); max-width: 12ch; }
  .shape.a { width: 22rem; height: 22rem; right: -7rem; top: -7rem; }
  .shape.b { width: 14rem; height: 14rem; right: 5rem; bottom: -5rem; }
  .shape.c, .shape.d { display: block; }
  .login { align-items: center; padding-block: 2.5rem; }
}

/* ---------- Skeleton & motion ---------- */
.sk { border-radius: 10px; background: linear-gradient(90deg, var(--surface-2) 0%, var(--line) 50%, var(--surface-2) 100%); background-size: 200% 100%; animation: shimmer 1.1s linear infinite; }
.enter { animation: up .45s var(--ease) both; animation-delay: calc(var(--i, 0) * 45ms); }
.no-anim .enter { animation: none; }
@keyframes up { from { opacity: 0; transform: translateY(10px); } }
@keyframes fade { from { opacity: 0; } }
@keyframes sheet { from { opacity: 0; transform: translateY(16px) scale(.97); } }
@keyframes sheetUp { from { transform: translateY(100%); } }
@keyframes pop { 0% { transform: scale(.6); } 60% { transform: scale(1.15); } 100% { transform: scale(1); } }
@keyframes load { to { width: 100%; } }
@keyframes shimmer { from { background-position: 200% 0; } to { background-position: -200% 0; } }
@keyframes hitA { to { transform: rotate(-8deg); } }
@keyframes hitB { to { transform: rotate(8deg); } }
@keyframes bob { to { transform: translateY(-2px); } }
@keyframes vbar { from { transform: scaleY(.2); } to { transform: scaleY(1); } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ---------- Live version additions ---------- */
@media (min-width: 900px) {
  .welcome .poster { position: sticky; top: 0; height: 100vh; }
  .login { align-items: flex-start; }
}
.avail button.c { border: 0; padding: 0; cursor: pointer; color: var(--muted); font: inherit; }
.avail button.c:hover { background: var(--line); }
.avail button.c[aria-pressed="true"] { background: var(--teal-soft); color: var(--teal-text); }
.check-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(11rem, 1fr)); gap: .5rem; }
.link-card { display: flex; align-items: center; gap: .7rem; margin: 0 1rem .8rem; padding: .75rem .9rem; border-radius: 14px; border: 1.5px solid var(--line); background: var(--surface-2); color: var(--ink); text-decoration: none; min-width: 0; }
.link-card:hover { border-color: var(--brand); }
.link-card span { min-width: 0; display: flex; flex-direction: column; }
.link-card b { font-size: .95rem; }
.link-card small { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.empty { align-items: center; text-align: center; }
.empty p { max-width: 36ch; }
.notice { display: flex; gap: .8rem; align-items: flex-start; padding: 1rem; border-radius: 16px; background: var(--sun-soft); color: var(--ink); }
.notice p { margin: 0; }

/* ---------- Added for the Supabase version: photos, videos and file fields ---------- */
.av.has-img { overflow: hidden; background: var(--surface-2); }
.av.has-img img { width: 100%; height: 100%; object-fit: cover; display: block; }
.post-media { display: block; width: calc(100% - 2rem); max-height: 34rem; margin: 0 1rem .8rem; border-radius: 14px; object-fit: contain; background: var(--surface-2); }
div.post-media { aspect-ratio: 16 / 9; }
video.post-media { background: #000; }
.field input[type="file"] { padding: .55rem .6rem; font-size: .92rem; cursor: pointer; }
.login-in .link-btn + .muted, .login-in .muted .link-btn { margin: 0; }
.login-in .muted .link-btn { display: inline; padding: 0; }
.rate { color: var(--star); }
.rate:hover { color: var(--star); background: var(--sun-soft); }
/* Text posts read like text; photo and video posts show the media full width */
.post-text.big { font-size: 1.08rem; line-height: 1.5; padding-bottom: .4rem; }
.post.photo .post-media { width: 100%; margin: 0; border-radius: 0; max-height: 75vh; object-fit: cover; }
.post.photo div.post-media { aspect-ratio: 1; }
.post.photo video.post-media { object-fit: contain; }
.post-text.caption { padding-top: 0; }
/* Map of people by neighbourhood */
.map-box { position: relative; z-index: 0; isolation: isolate; height: 60vh; min-height: 320px; border-radius: 18px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.map-pin span { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--brand); color: #fff; font-weight: 700; font-size: .95rem; box-shadow: 0 0 0 3px #fff, 0 2px 8px rgba(0, 0, 0, .3); cursor: pointer; }
.map-pin.on span { background: var(--coral); }
.wijk-results { display: flex; flex-direction: column; gap: .3rem; }
.wijk-results:empty { display: none; }
.wijk-results button { text-align: left; padding: .6rem .8rem; border-radius: 12px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); }
.wijk-results button:hover { background: var(--surface-2); }
