/* Talkies — visual system (dark only)
   Neutral grays, one violet accent, Inter + Noto Sans Georgian, 1px borders, soft shadows. */
:root {
  --bg: #09090B;
  --bg-2: #0D0D10;
  --surface: #121216;
  --surface-2: #19191E;
  --surface-3: #222229;
  --border: #232329;
  --border-2: #303039;
  --text: #EDEDF0;
  --text-2: #A3A3AE;
  --muted: #6F6F7B;
  --accent: #7C6CFF;
  --accent-hover: #8F81FF;
  --accent-soft: rgba(124, 108, 255, .15);
  --accent-ring: rgba(124, 108, 255, .4);
  --me-1: #7A6BFF;
  --me-2: #5847E8;
  --success: #3DD68C;
  --success-soft: rgba(61, 214, 140, .12);
  --danger: #E5484D;
  --shadow-xs: 0 1px 2px rgba(0, 0, 0, .4);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .4), 0 4px 12px -4px rgba(0, 0, 0, .5);
  --shadow-lg: 0 1px 2px rgba(0, 0, 0, .5), 0 28px 70px -28px rgba(0, 0, 0, .8);
  --font: 'Inter', 'Noto Sans Georgian', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
html { overscroll-behavior: none; }
/* The page always covers exactly the visible area (see fitViewport in app.js), so a phone's
   keyboard pushes the composer up instead of sliding the whole page out of view. */
body { position: fixed; left: 0; top: var(--vt, 0px); width: 100%; height: var(--vh, 100%); }
body {
  display: flex; flex-direction: column;
  background: var(--bg); color: var(--text);
  font-family: var(--font); font-size: 15px; line-height: 1.5;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
  overflow: hidden;
}
button, input { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; touch-action: manipulation; }
button:focus-visible, input:focus-visible, a:focus-visible { outline: 2px solid var(--accent-ring); outline-offset: 2px; }
[hidden] { display: none !important; }
p { margin: 0; }
.muted { color: var(--muted); }
.ico { display: inline-grid; place-items: center; width: 18px; height: 18px; flex: none; }
.ico svg { width: 100%; height: 100%; }

.glow {
  position: fixed; inset: -20vh -10vw auto; height: 70vh; pointer-events: none; z-index: 0;
  background: radial-gradient(50% 60% at 50% 0%, var(--accent-soft), transparent 70%);
  opacity: .35; transition: opacity .6s;
}
body[data-screen="landing"] .glow { opacity: 1; }

/* ---------- nav */
.nav { position: relative; z-index: 2; flex: none; display: flex; align-items: center; justify-content: space-between; height: 64px; padding: 0 24px; max-width: 1240px; width: 100%; margin: 0 auto; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); text-decoration: none; font-weight: 700; font-size: 17px; letter-spacing: -.02em; }
.mark { width: 28px; height: 28px; display: block; }
.nav-right { display: flex; align-items: center; gap: 14px; }
.online { display: inline-flex; align-items: center; gap: 8px; color: var(--text-2); font-size: 13px; }
.online::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 3px var(--success-soft); }
.lang { height: 32px; padding: 0 12px; border-radius: 8px; font-size: 13px; font-weight: 500; color: var(--text-2); border: 1px solid var(--border); background: var(--surface); }
.lang:hover { color: var(--text); border-color: var(--border-2); }
.me-btn { display: inline-flex; align-items: center; gap: 8px; height: 32px; max-width: 180px; padding: 0 12px 0 3px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--text-2); border: 1px solid var(--border); background: var(--surface); }
.me-btn:hover { color: var(--text); border-color: var(--border-2); }
.me-btn .ava { width: 24px; height: 24px; }
.me-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---------- buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 16px; border-radius: 10px; font-weight: 600; font-size: 14px; white-space: nowrap;
  transition: background .15s, border-color .15s, box-shadow .15s, transform .15s var(--ease), color .15s;
}
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--accent); color: #fff; box-shadow: 0 1px 2px rgba(16, 16, 20, .1), 0 8px 24px -8px var(--accent-ring), inset 0 1px 0 rgba(255, 255, 255, .15); }
.btn.primary:hover { background: var(--accent-hover); }
.btn.secondary { background: var(--surface); color: var(--text); border: 1px solid var(--border); box-shadow: var(--shadow-xs); }
.btn.secondary:hover { border-color: var(--border-2); background: var(--surface-2); }
.btn.ghost { color: var(--text-2); }
.btn.ghost:hover { color: var(--text); background: var(--surface-2); }
.btn.lg { height: 48px; padding: 0 22px; font-size: 15px; border-radius: 12px; }
.btn.sm { height: 34px; padding: 0 12px; font-size: 13px; border-radius: 9px; }
.btn.block { width: 100%; }

/* ---------- screens */
#app { position: relative; z-index: 1; flex: 1; min-height: 0; }
.screen { position: absolute; inset: 0; display: flex; flex-direction: column; padding: 0 24px 24px; }

/* ---------- landing */
#landing { overflow-y: auto; }
.hero { width: 100%; max-width: 1120px; margin: auto; display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 72px; align-items: center; padding: 24px 0 48px; }
.hero-copy { animation: rise .7s var(--ease) both; }
.headline { margin: 0 0 20px; font-size: clamp(42px, 5.6vw, 76px); line-height: 1.02; font-weight: 700; letter-spacing: -.045em; text-wrap: balance;
  background: linear-gradient(180deg, var(--text) 30%, color-mix(in srgb, var(--text) 62%, var(--accent))); -webkit-background-clip: text; background-clip: text; color: transparent; }
.lead { font-size: 20px; line-height: 1.5; color: var(--text-2); max-width: 30ch; }
.cta-row { display: flex; align-items: center; gap: 20px; margin-top: 36px; flex-wrap: wrap; }
.cta-row .btn { height: 54px; padding: 0 26px; font-size: 16px; border-radius: 14px; }

.demo { position: relative; height: 460px; display: flex; flex-direction: column; padding: 16px; border-radius: 24px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-lg); animation: rise .8s .12s var(--ease) both; }
.demo::before { content: ''; position: absolute; inset: -60px; z-index: -1; border-radius: 50%; background: radial-gradient(closest-side, var(--accent-soft), transparent); filter: blur(10px); }
.demo-head { display: flex; align-items: center; justify-content: space-between; padding: 2px 4px 14px; border-bottom: 1px solid var(--border); }
.demo-avas { display: flex; }
.demo-avas .ava { width: 28px; height: 28px; box-shadow: 0 0 0 2px var(--surface); }
.demo-avas .ava + .ava { margin-left: -8px; }
.demo-bar { display: grid; grid-template-columns: repeat(6, 16px); gap: 4px; }
.demo-bar i { height: 4px; border-radius: 999px; background: var(--surface-3); position: relative; overflow: hidden; }
.demo-bar i::after { content: ''; position: absolute; inset: 0; background: var(--accent); transform-origin: left; transform: scaleX(0); transition: transform .6s var(--ease); }
.demo-bar i.on::after { transform: scaleX(1); }
.demo-feed { flex: 1; min-height: 0; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: 10px; padding: 14px 4px 2px;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 22%); mask-image: linear-gradient(to bottom, transparent, #000 22%); transition: opacity .5s; }
.demo-feed > * { flex-shrink: 0; }
.demo-feed.fade { opacity: 0; }
.demo .row.them .bubble { cursor: default; }
.demo .bubble { font-size: 14px; }
.demo .bubble.big { font-size: 32px; }
.demo-unlock { align-self: center; display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent-ring); animation: pop .4s var(--ease); }
.demo-unlock .ico { width: 14px; height: 14px; }
.demo-typing { display: inline-flex; gap: 4px; padding: 12px 14px; }
.demo-typing i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); animation: blink 1s infinite; }
.demo-typing i:nth-child(2) { animation-delay: .15s; }
.demo-typing i:nth-child(3) { animation-delay: .3s; }

/* ---------- searching */
#search, #invite, #join { align-items: center; justify-content: center; }
.center-card { display: flex; flex-direction: column; align-items: center; gap: 10px; text-align: center; padding: 40px 48px; border-radius: 24px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-lg); min-width: min(420px, 100%); animation: rise .5s var(--ease) both; }
.radar { position: relative; width: 88px; height: 88px; display: grid; place-items: center; font-size: 34px; border-radius: 50%; background: var(--surface-2); border: 1px solid var(--border); margin-bottom: 18px; }
.radar::before, .radar::after { content: ''; position: absolute; inset: -1px; border-radius: 50%; border: 1px solid var(--accent-ring); animation: ring 2.4s var(--ease) infinite; }
.radar::after { animation-delay: 1.2s; }
.radar.small { width: 64px; height: 64px; font-size: 26px; margin-bottom: 4px; }
.h2 { margin: 0; font-size: 22px; font-weight: 600; letter-spacing: -.02em; }
#quiet { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-top: 10px; }
#cancelBtn { margin-top: 8px; }

/* ---------- invite */
.invite-card { max-width: 480px; width: 100%; }
.invite-sub { max-width: 34ch; margin-bottom: 8px; }
.big-ico { width: 30px; height: 30px; color: var(--accent); }
.link-box { display: flex; align-items: center; gap: 8px; width: 100%; padding: 6px 6px 6px 12px; margin-top: 4px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--border-2); }
.link-input { flex: 1; min-width: 0; border: 0; background: transparent; color: var(--text); font-size: 14px; font-family: ui-monospace, Menlo, monospace; text-overflow: ellipsis; outline: none; }
.invite-wait { display: inline-flex; align-items: center; gap: 10px; margin-top: 10px; color: var(--text-2); font-size: 14px; }
.live-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.live-dot::after { content: ''; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid var(--accent); animation: ring 1.6s var(--ease) infinite; }
#invite .btn.ghost, #join .btn.ghost { margin-top: 4px; }

/* ---------- match */
#match { padding: 0 16px 16px; }
body[data-screen="match"] .nav { max-width: 1792px; height: 56px; padding: 0 16px; }
.frame { flex: 1; min-height: 0; width: 100%; max-width: 1760px; margin: 0 auto; display: grid; grid-template-columns: 300px minmax(0, 1fr); background: var(--surface); border: 1px solid var(--border); border-radius: 20px; box-shadow: var(--shadow-lg); overflow: hidden; }
@media (min-width: 1280px) { .frame { grid-template-columns: 320px minmax(0, 1fr); } }

.side { display: flex; flex-direction: column; gap: 14px; padding: 18px; background: var(--bg-2); border-right: 1px solid var(--border); overflow-y: auto; min-height: 0; }
.side-block { padding: 14px; border-radius: 14px; background: var(--surface); border: 1px solid var(--border); }
.stranger { display: flex; align-items: center; gap: 12px; }
.stranger-info { min-width: 0; }
.label { font-size: 12px; font-weight: 500; color: var(--muted); }
.label.named { font-size: 15px; font-weight: 600; line-height: 1.35; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.them-info { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; font-size: 14px; font-weight: 500; color: var(--text); }
.them-info .sep { color: var(--border-2); }
.them-info .time { color: var(--text-2); font-weight: 400; }
.row-between { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 10px; }
.fuse-secs { font-size: 13px; font-weight: 600; font-variant-numeric: tabular-nums; }
.fuse { position: relative; height: 6px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.fuse-fill { position: absolute; inset: 0; border-radius: inherit; transform-origin: left center; background: linear-gradient(90deg, var(--me-1), var(--me-2)); }
.fuse.low .fuse-fill { background: var(--danger); animation: blink .8s infinite; }
.fuse-secs.low { color: var(--danger); }

.ava { display: block; flex: none; width: 30px; height: 30px; border-radius: 50%; overflow: hidden; background: var(--surface-3); }
.ava svg, .ava img { display: block; width: 100%; height: 100%; }
.ava img { object-fit: cover; }
.ava .eyes { transform-box: fill-box; transform-origin: center; animation: avaBlink 5s infinite; }
.ava.hop, .stranger .ava.lg.hop { animation: avaHop .55s var(--ease); }
@keyframes avaBlink { 0%, 92%, 100% { transform: none; } 95% { transform: scaleY(.1); } }
@keyframes avaHop { 0%, 100% { transform: none; } 35% { transform: translateY(-4px) scale(1.06); } 65% { transform: translateY(1px) scale(.98); } }
.ava.lg { width: 44px; height: 44px; }

.ladder { list-style: none; margin: 0; padding: 4px 2px; display: flex; flex-direction: column; }
.step-row { position: relative; display: grid; grid-template-columns: 32px 1fr; gap: 12px; padding: 8px 0 14px; }
.step-row:not(:last-child)::before { content: ''; position: absolute; left: 15.5px; top: 42px; bottom: 0; width: 1px; background: var(--border-2); }
.step-row.done:not(:last-child)::before { background: var(--success); opacity: .5; }
.dot { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; border: 1px solid var(--border-2); background: var(--surface); color: var(--muted); }
.dot .ico { width: 15px; height: 15px; }
.step-row.done .dot { background: var(--success-soft); border-color: transparent; color: var(--success); }
.step-row.now .dot { background: var(--accent); border-color: transparent; color: #fff; box-shadow: 0 0 0 4px var(--accent-soft); }
.step-row .name { font-size: 14px; font-weight: 600; line-height: 1.3; }
.step-row.locked .name { color: var(--text-2); font-weight: 500; }
.step-row .desc { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.mini-bar { height: 4px; border-radius: 999px; background: var(--surface-3); margin-top: 8px; overflow: hidden; }
.mini-bar i { display: block; height: 100%; border-radius: inherit; background: var(--accent); transform-origin: left; transition: transform .5s var(--ease); }
.next-btn.block { margin-top: auto; }

.chat { display: flex; flex-direction: column; min-width: 0; min-height: 0; }
.chat-head { flex: none; padding: 16px 24px; border-bottom: 1px solid var(--border); display: flex; flex-direction: column; gap: 10px; }
.mobile-top, .mobile-only, .ladder-mini { display: none; }
.stage-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.stage-title { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: 15px; }
.stage-title .ico { color: var(--accent); }
.stage-title .of { color: var(--muted); font-weight: 500; }
.hint { font-size: 13px; color: var(--muted); margin-top: 2px; }

.feed { flex: 1; min-height: 0; overflow-y: auto; display: flex; flex-direction: column; gap: 12px; padding: 24px; overscroll-behavior: contain; }
/* Never let messages shrink: without this, Safari squeezes older rows until they disappear. */
.feed > * { flex-shrink: 0; }
.row { display: flex; align-items: flex-end; gap: 10px; max-width: 100%; flex-wrap: wrap; }
.row.me { justify-content: flex-end; }
.row .ava { width: 28px; height: 28px; }
.bubble {
  position: relative; max-width: min(560px, 74%); display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  padding: 10px 14px; border-radius: 18px; font-size: 15px; line-height: 1.45;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text);
  overflow-wrap: anywhere; animation: in .22s var(--ease);
}
.row.them .bubble { border-bottom-left-radius: 6px; cursor: pointer; }
.row.them .bubble:hover { border-color: var(--border-2); }
.row.them .bubble:focus-visible { outline: 2px solid var(--accent-ring); outline-offset: 2px; }
.row.me .bubble { background: linear-gradient(135deg, var(--me-1), var(--me-2)); color: #fff; border-color: transparent; border-bottom-right-radius: 6px; box-shadow: 0 6px 18px -10px var(--accent-ring); }
.bubble.big, .row.me .bubble.big { font-size: 40px; line-height: 1.2; padding: 0 2px; background: none; border-color: transparent; box-shadow: none; color: var(--text); }
.bubble.has-gif { padding: 4px; }
.bubble .e { display: inline-block; }
.card { display: inline-flex; align-items: baseline; gap: 5px; font-weight: 500; }
.card sup { font-size: 10px; opacity: .6; }
.gif-msg { display: block; height: auto; max-width: 220px; max-height: 220px; border-radius: 14px; background: var(--surface-3); object-fit: cover; }
.bubble.sent::after { content: ''; width: 12px; height: 12px; align-self: flex-end; margin: 0 -6px -3px 0; opacity: .7; background: currentColor;
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center / contain no-repeat; }
.bubble.big.sent::after, .bubble.has-gif.sent::after { color: var(--muted); margin: 0 0 2px; }
.react { position: absolute; bottom: -12px; display: flex; align-items: center; height: 26px; padding: 0 5px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-xs); animation: in .2s var(--ease); }
.react.me { right: -4px; }
.react.them { left: -4px; }
.react-pop { flex-basis: 100%; display: flex; gap: 2px; margin-left: 38px; padding: 4px; max-width: max-content; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-sm); animation: in .18s var(--ease); }
.react img { display: block; width: 18px; height: 18px; }
.react-pop button { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 50%; transition: background .12s, transform .12s; }
.react-pop img { display: block; width: 26px; height: 26px; pointer-events: none; }
.react-burst { position: absolute; left: 50%; top: 50%; z-index: 2; width: 76px; height: 76px; margin: -38px 0 0 -38px; pointer-events: none; animation: burst 1.15s var(--ease) forwards; }
.react-burst img { display: block; width: 100%; height: 100%; filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .45)); }
@keyframes burst { 0% { opacity: 0; transform: scale(.3); } 22% { opacity: 1; transform: scale(1.15); } 60% { opacity: 1; transform: translateY(-14px) scale(1); } 100% { opacity: 0; transform: translateY(-46px) scale(.9); } }
.react-pop button:hover { background: var(--surface-2); transform: scale(1.12); }
.react-pop button.on { background: var(--accent-soft); box-shadow: inset 0 0 0 1px var(--accent-ring); }

.composer { flex: none; display: flex; flex-direction: column; gap: 10px; padding: 14px 24px 18px; border-top: 1px solid var(--border); background: var(--surface); }

.tray { display: flex; align-items: center; gap: 8px; min-height: 52px; padding: 6px 6px 6px 14px; border-radius: 14px; background: var(--bg); border: 1px solid var(--border-2); transition: border-color .15s, box-shadow .15s; }
.tray:focus-within { border-color: var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); }
.tokens { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; flex: 1; min-width: 0; }
.tokens:empty::before { content: attr(data-hint); color: var(--muted); font-size: 14px; }
.tray.has-text .tokens { flex: 0 1 auto; }
.tray.has-text .tokens:empty { display: none; }
.tok { display: inline-flex; align-items: center; font-size: 22px; line-height: 1; padding: 3px; border-radius: 8px; animation: in .18s var(--ease); }
.tok:hover { background: var(--surface-2); }
.tok-p { font-size: 13px; font-weight: 500; padding: 6px 10px; border-radius: 8px; background: var(--surface); border: 1px solid var(--border); }
.tok-g img { height: 36px; width: auto; border-radius: 6px; display: block; }
.text-in { flex: 1; min-width: 0; border: 0; background: transparent; font-size: 15px; padding: 8px 2px; outline: none; }
.text-in::placeholder { color: var(--muted); }
.send { flex: none; width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; background: var(--accent); color: #fff; transition: background .15s, transform .15s var(--ease); }
.send:hover:not(:disabled) { background: var(--accent-hover); }
.send:disabled { background: var(--surface-3); color: var(--muted); cursor: default; }
.send:not(:disabled):active { transform: scale(.94); }

.tabs { display: inline-flex; align-self: flex-start; gap: 2px; padding: 3px; border-radius: 11px; background: var(--surface-2); border: 1px solid var(--border); }
.tab { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 8px; font-size: 13px; font-weight: 500; color: var(--text-2); white-space: nowrap; transition: background .15s, color .15s; }
.tab:hover { color: var(--text); }
.tab.on { background: var(--surface); color: var(--text); box-shadow: var(--shadow-xs); }
.tab.locked { color: var(--muted); cursor: not-allowed; }
.tab .ico { width: 14px; height: 14px; }

.panel { height: 158px; overflow-y: auto; padding: 8px; border-radius: 14px; background: var(--bg); border: 1px solid var(--border); overscroll-behavior: contain; }
.emoji-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(44px, 1fr)); gap: 2px; }
.key { position: relative; aspect-ratio: 1; display: grid; place-items: center; font-size: 24px; border-radius: 10px; transition: background .12s, transform .12s; }
.key:hover { background: var(--surface-2); }
.key:active { transform: scale(.9); }
.gif-key::after { content: 'GIF'; position: absolute; right: 3px; bottom: 3px; font-size: 8px; font-weight: 700; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-btn { height: 34px; padding: 0 12px; border-radius: 9px; font-size: 14px; font-weight: 500; background: var(--surface); border: 1px solid var(--border); color: var(--text); transition: border-color .12s, background .12s; }
.chip-btn:hover { border-color: var(--accent-ring); background: var(--accent-soft); }
.gif-search { width: 100%; height: 38px; padding: 0 12px; border-radius: 10px; border: 1px solid var(--border); background: var(--surface); font-size: 14px; margin-bottom: 8px; outline: none; }
.gif-search:focus { border-color: var(--accent-ring); }
.gif-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 6px; }
.gif img { width: 100%; height: 92px; object-fit: cover; border-radius: 10px; display: block; background: var(--surface-3); }
.gif:hover img { outline: 2px solid var(--accent-ring); outline-offset: -2px; }
.giphy { font-size: 11px; color: var(--muted); text-align: right; margin-top: 6px; }

.overlay { position: fixed; inset: 0; z-index: 20; display: grid; place-items: center; background: color-mix(in srgb, var(--bg) 55%, transparent); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); pointer-events: none; }
.overlay.play { animation: fadeInOut 1.9s var(--ease) forwards; }
.lv-card { text-align: center; padding: 28px 40px; border-radius: 22px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-lg); animation: pop .45s var(--ease); }
.lv-ico { width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 16px; display: grid; place-items: center; background: linear-gradient(135deg, var(--me-1), var(--me-2)); color: #fff; box-shadow: 0 10px 26px -10px var(--accent-ring); }
.lv-ico .ico { width: 26px; height: 26px; }
.lv-kicker { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); }
.lv-name { margin: 4px 0; font-size: 28px; font-weight: 700; letter-spacing: -.02em; }
.lv-desc { color: var(--text-2); }

.connecting { position: absolute; inset: 0; z-index: 10; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--text-2); font-weight: 500; background: var(--bg); }

/* ---------- end */
#end { align-items: center; justify-content: flex-start; overflow-y: auto; }
#end .end-wrap { margin: auto 0; padding: 16px 0; }
.end-wrap { width: 100%; max-width: 520px; display: flex; flex-direction: column; gap: 16px; animation: rise .5s var(--ease) both; }
.postcard { padding: 28px; border-radius: 22px; background: var(--surface); border: 1px solid var(--border); box-shadow: var(--shadow-lg); text-align: center; }
.pc-kicker { font-size: 12px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.pc-end { margin: 6px 0 4px; font-size: 30px; font-weight: 700; letter-spacing: -.03em; }
.pc-why { color: var(--text-2); }
.pc-pair { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 22px 0; }
.pc-pair .ava { width: 44px; height: 44px; }
.pc-amp { color: var(--muted); }
.pc-flag { font-size: 22px; }
.pc-stage { display: flex; align-items: center; justify-content: center; gap: 12px; padding: 14px; border-radius: 14px; background: var(--accent-soft); margin-bottom: 18px; text-align: left; }
.pc-stage .lv-ico { width: 40px; height: 40px; margin: 0; border-radius: 12px; }
.pc-stage .lv-ico .ico { width: 20px; height: 20px; }
.pc-stage-name { font-size: 18px; font-weight: 700; letter-spacing: -.01em; }
.pc-stats { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--border); border-radius: 14px; margin-bottom: 18px; }
.stat { padding: 14px 8px; display: flex; flex-direction: column; gap: 2px; }
.stat + .stat { border-left: 1px solid var(--border); }
.stat b { font-size: 22px; font-weight: 700; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat span { font-size: 12px; color: var(--muted); }
.pc-story { padding: 14px; border-radius: 14px; background: var(--surface-2); }
.pc-story .pc-kicker { margin-bottom: 8px; }
.pc-strip { font-size: 22px; letter-spacing: .08em; line-height: 1.5; word-break: break-all; }
.end-actions { display: flex; gap: 10px; }
.end-actions .btn { flex: 1; }

/* ---------- fx */
.confetti { position: fixed; inset: 0; pointer-events: none; z-index: 50; overflow: hidden; }
.bit { position: absolute; bottom: 30%; width: 7px; height: 11px; border-radius: 2px; animation: fly 1.5s cubic-bezier(.15, .7, .3, 1) forwards; }
.toast { position: fixed; left: 50%; top: 76px; transform: translateX(-50%); z-index: 60; max-width: calc(100vw - 32px); padding: 10px 16px; border-radius: 12px; background: var(--text); color: var(--bg); font-size: 14px; font-weight: 500; box-shadow: var(--shadow-lg); animation: in .2s var(--ease); }
.bump { animation: shake .35s; }
.debug { position: fixed; left: 8px; bottom: 8px; z-index: 70; margin: 0; padding: 8px 10px; max-width: 46vw; font: 10px/1.35 ui-monospace, Menlo, monospace; color: #fff; background: rgba(0, 0, 0, .75); border-radius: 8px; pointer-events: none; white-space: pre-wrap; }

@keyframes in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(.95); } to { opacity: 1; transform: none; } }
@keyframes ring { 0% { transform: scale(1); opacity: 1; } 100% { transform: scale(1.8); opacity: 0; } }
@keyframes shake { 0%, 100% { transform: none; } 25% { transform: translateX(-3px); } 75% { transform: translateX(3px); } }
@keyframes blink { 50% { opacity: .45; } }
@keyframes fadeInOut { 0% { opacity: 0; } 12% { opacity: 1; } 80% { opacity: 1; } 100% { opacity: 0; } }
@keyframes fly { 0% { transform: translate(0, 0) rotate(0); opacity: 1; } 100% { transform: translate(var(--x), var(--y)) rotate(var(--r)); opacity: 0; } }

/* ---------- match: livelier details */
.chat { background: linear-gradient(180deg, color-mix(in srgb, var(--accent) 6%, var(--surface)), var(--surface) 240px); }
.feed { background:
  radial-gradient(70% 240px at 50% 0%, var(--accent-soft), transparent 72%),
  radial-gradient(rgba(255, 255, 255, .05) 1px, transparent 1.3px) 0 0 / 22px 22px; }
.composer { background: var(--surface); }
.tray, .panel { background: var(--surface-2); }

.intro { align-self: center; text-align: center; padding: 10px 24px 8px; animation: in .45s var(--ease); }
.intro-orbs { display: flex; align-items: center; justify-content: center; margin-bottom: 16px; }
.intro-orbs .ava { width: 54px; height: 54px; box-shadow: 0 0 0 4px var(--surface), 0 0 34px -4px color-mix(in srgb, var(--glow, var(--accent)) 65%, transparent); animation: orbL .7s var(--ease) both; }
.intro-orbs .ava:last-child { animation-name: orbR; }
.intro-link { width: 54px; height: 2px; border-radius: 2px; background: linear-gradient(90deg, var(--me-1), #FF7AD9); animation: linkPulse 1.8s ease-in-out .6s infinite both; }
.intro-title { font-size: 21px; font-weight: 700; letter-spacing: -.02em; }
.intro-sub { color: var(--text-2); margin-top: 4px; font-size: 14px; }
.intro-hint { display: inline-flex; margin-top: 14px; padding: 6px 14px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--accent); background: var(--accent-soft); border: 1px solid var(--accent-ring); }

.spark { display: flex; align-items: center; gap: 12px; height: 34px; padding: 0 14px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); font-size: 13px; color: var(--text-2); white-space: nowrap; flex: none; }
.spark b { color: var(--text); font-weight: 600; }
.spark-dots { display: inline-flex; gap: 6px; }
.spark-dots i { width: 9px; height: 9px; border-radius: 50%; background: var(--surface-3); box-shadow: inset 0 0 0 1px var(--border-2); transition: background .3s, box-shadow .3s, transform .3s var(--ease); }
.spark-dots i.on { background: var(--accent); box-shadow: 0 0 12px var(--accent); transform: scale(1.15); }
.spark-label.done { display: inline-flex; align-items: center; gap: 6px; color: var(--success); font-weight: 500; }
.spark-label.done .ico { width: 14px; height: 14px; }

.stranger .ava.lg { animation: breathe 3.2s ease-in-out infinite; box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px color-mix(in srgb, var(--glow, var(--accent)) 45%, transparent), 0 0 26px -2px color-mix(in srgb, var(--glow, var(--accent)) 50%, transparent); }
.fuse-secs { font-size: 18px; font-weight: 700; letter-spacing: -.01em; }
.side .fuse { height: 8px; }
.side .fuse-fill { box-shadow: 0 0 16px var(--accent); }
.step-row.now .dot { box-shadow: 0 0 0 4px var(--accent-soft), 0 0 20px var(--accent-ring); }

.tab.on { background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent-ring); }
.key { transition: background .12s, transform .15s var(--ease); }
.key:hover { background: var(--accent-soft); transform: translateY(-2px) scale(1.08); }
.send:not(:disabled) { background: linear-gradient(135deg, var(--me-1), var(--me-2)); box-shadow: 0 8px 22px -8px var(--accent-ring); }

@keyframes orbL { from { opacity: 0; transform: translateX(-22px); } to { opacity: 1; transform: none; } }
@keyframes orbR { from { opacity: 0; transform: translateX(22px); } to { opacity: 1; transform: none; } }
@keyframes linkPulse { 0%, 100% { opacity: .45; transform: scaleX(.8); } 50% { opacity: 1; transform: scaleX(1); } }
@keyframes breathe { 50% { box-shadow: 0 0 0 3px var(--surface), 0 0 0 6px color-mix(in srgb, var(--glow, var(--accent)) 30%, transparent), 0 0 38px 0 color-mix(in srgb, var(--glow, var(--accent)) 60%, transparent); } }

/* ---------- word budget */
.word-count { flex: none; min-width: 44px; height: 28px; padding: 0 10px; border-radius: 999px; display: grid; place-items: center; font-size: 12.5px; font-weight: 600; font-variant-numeric: tabular-nums; color: var(--text-2); background: var(--surface-3); }
.word-count.over { color: #fff; background: var(--danger); }
.text-in { font-size: 16px; }
.tray { min-height: 58px; }
.pc-strip { font-size: 15px; letter-spacing: 0; line-height: 1.6; word-break: normal; color: var(--text-2); }
.row .bubble .w { font-size: 15.5px; }

/* ---------- GIFs first, then text */
.gif-panel { display: flex; flex-direction: column; gap: 10px; padding: 12px; border-radius: 16px; background: var(--surface-2); border: 1px solid var(--border); }
.gif-panel[hidden] { display: none; }
.gif-search-box { display: flex; align-items: center; gap: 8px; height: 40px; padding: 0 12px; border-radius: 11px; background: var(--bg); border: 1px solid var(--border-2); color: var(--muted); transition: border-color .15s, box-shadow .15s; }
.gif-search-box:focus-within { border-color: var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); }
.gif-search-box .ico { width: 16px; height: 16px; }
.gif-search { flex: 1; min-width: 0; height: 100%; margin: 0; padding: 0; border: 0; background: transparent; color: var(--text); font: inherit; font-size: 14.5px; outline: none; }
.gif-search::-webkit-search-cancel-button { -webkit-appearance: none; }
.gif-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -2px; padding: 0 2px; }
.gif-chips::-webkit-scrollbar { display: none; }
.gif-chip { flex: none; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 500; color: var(--text-2); background: var(--surface); border: 1px solid var(--border); transition: color .12s, border-color .12s, background .12s; }
.gif-chip:hover { color: var(--text); border-color: var(--border-2); }
.gif-chip.on { color: #fff; background: var(--accent); border-color: transparent; }
.gif-panel .gif-grid { height: 168px; overflow-y: auto; overscroll-behavior: contain; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 6px; align-content: start; grid-auto-rows: 94px; transition: opacity .2s; }
.gif-grid.loading { opacity: .5; }
.gif { padding: 0; border-radius: 10px; overflow: hidden; transition: transform .15s var(--ease); }
.gif img { height: 94px; }
.gif:hover { transform: scale(1.03); }
.gif:active { transform: scale(.97); }
.gif-empty { grid-column: 1 / -1; padding: 24px 0; text-align: center; font-size: 14px; }
.gif-panel .giphy { margin: -2px 0 0; }
.gif-btn { flex: none; height: 32px; padding: 0 10px; border-radius: 9px; font-size: 12px; font-weight: 800; letter-spacing: .04em; color: var(--text-2); background: var(--surface-3); border: 1px solid var(--border-2); transition: color .12s, background .12s; }
.gif-btn:hover { color: var(--text); }
.gif-btn.on { color: #fff; background: var(--accent); border-color: transparent; }
.tray[hidden] { display: none; }
.gif-need { display: flex; align-items: center; gap: 14px; flex: none; }
.gif-need[hidden] { display: none; }
.need { display: inline-flex; align-items: center; gap: 7px; height: 30px; padding: 0 12px; border-radius: 999px; font-size: 12.5px; color: var(--text-2); background: var(--surface-2); border: 1px solid var(--border); }
.need-dots { display: inline-flex; gap: 4px; }
.need-dots i { width: 8px; height: 8px; border-radius: 50%; background: var(--surface-3); box-shadow: inset 0 0 0 1px var(--border-2); transition: background .25s, box-shadow .25s; }
.need-dots i.on { background: var(--accent); box-shadow: 0 0 10px var(--accent); }
.need.done { color: var(--success); border-color: color-mix(in srgb, var(--success) 35%, transparent); }
.need.done .need-dots i { background: var(--success); box-shadow: none; }
/* The delivered tick sits on the GIF instead of widening the bubble. */
.bubble.has-gif.sent::after, .bubble.photo.sent::after { position: absolute; right: 10px; bottom: 10px; margin: 0; color: #fff; opacity: .9; filter: drop-shadow(0 1px 2px rgba(0, 0, 0, .8)); }
.text-in:focus-visible, .gif-search:focus-visible { outline: none; }
.tray { padding-left: 8px; }
.consent-ico { flex: none; width: 34px; height: 34px; display: grid; place-items: center; border-radius: 10px; color: #fff; background: linear-gradient(135deg, var(--me-1), #FF7AD9); }
.intro-hint { align-items: center; gap: 8px; }
.intro-hint .ico { width: 18px; height: 18px; }
#match.ready .side .fuse-fill, #match.ready .fuse.mobile-only .fuse-fill { background: linear-gradient(90deg, var(--me-1), #FF7AD9); }
#match.ready .fuse-secs { color: var(--success); }
.pc-gifs { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pc-gifs img { width: 100%; height: 72px; object-fit: cover; border-radius: 10px; background: var(--surface-3); display: block; }

/* ---------- four steps: the ladder card, voice messages, contact swap */
.step-body { min-width: 0; }
.step-row.locked .desc { color: var(--muted); }
.need-card { display: flex; flex-direction: column; gap: 7px; margin-top: 10px; padding: 11px 12px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.need-card.ready { background: var(--accent-soft); border-color: var(--accent-ring); }
.need-title { font-size: 12.5px; font-weight: 500; color: var(--text); line-height: 1.4; }
.need-row { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--text-2); }
.need-row.done { color: var(--success); }
.need-row.done .need-dots i { background: var(--success); box-shadow: none; }
.need-bar { height: 4px; border-radius: 999px; background: var(--surface-3); overflow: hidden; margin-top: 2px; }
.need-bar i { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--me-1), var(--me-2)); transform-origin: left; transform: scaleX(0); }
.need-time { font-weight: 600; color: var(--text); font-variant-numeric: tabular-nums; }
.need-time.done { color: var(--success); }
@media (min-width: 861px) { .gif-need { display: none; } }

.mic-btn { flex: none; width: 34px; height: 32px; border-radius: 9px; display: grid; place-items: center; color: var(--text-2); background: var(--surface-3); border: 1px solid var(--border-2); transition: color .12s, background .12s; }
.mic-btn:hover { color: var(--text); }
.mic-btn .ico { width: 16px; height: 16px; }
.mic-btn[hidden] { display: none; }

.bubble.voice { flex-wrap: nowrap; gap: 10px; min-width: 210px; padding: 7px 14px 7px 7px; }
.vplay { flex: none; width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); color: var(--text); transition: transform .12s var(--ease); }
.vplay .ico { width: 14px; height: 14px; }
.row.me .vplay { background: rgba(255, 255, 255, .2); color: #fff; }
.vwave { flex: 1; min-width: 0; height: 28px; display: flex; align-items: center; gap: 2px; overflow: hidden; }
.vwave i { flex: none; width: 3px; border-radius: 2px; background: currentColor; opacity: .4; }
.vtime { flex: none; font-size: 12px; font-variant-numeric: tabular-nums; opacity: .8; }
.vwave i.on { opacity: 1; }
/* Recording a voice message: the bar that takes the text field's place */
.rec { gap: 10px; border-color: color-mix(in srgb, var(--danger) 50%, transparent); animation: in .18s var(--ease); }
.rec[hidden] { display: none; }
.rec-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--danger); animation: blink 1s infinite; }
.rec-time { flex: none; min-width: 36px; font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.rec-wave { flex: 1; min-width: 0; height: 28px; display: flex; align-items: center; justify-content: flex-end; gap: 2px; overflow: hidden; }
.rec-wave i { flex: none; width: 3px; border-radius: 2px; background: var(--text-2); }

.swap { display: flex; flex-direction: column; gap: 10px; padding: 12px 14px; border-radius: 14px; background: var(--accent-soft); border: 1px solid var(--accent-ring); animation: pop .3s var(--ease); }
.swap[hidden] { display: none; }
.swap-head { display: flex; align-items: center; gap: 10px; }
.swap-head p { font-size: 14px; font-weight: 500; }
.swap-head .swap-status { font-size: 12.5px; font-weight: 400; color: var(--text-2); margin-top: 1px; }
.swap-head .swap-status.them-in { color: var(--success); }
.swap-form { display: flex; gap: 8px; }
.swap-in { flex: 1; min-width: 0; height: 42px; padding: 0 12px; border-radius: 10px; background: var(--bg); border: 1px solid var(--border-2); color: var(--text); font: inherit; font-size: 15px; outline: none; transition: border-color .15s, box-shadow .15s; }
.swap-in:focus { border-color: var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); }
.swap-in::placeholder { color: var(--muted); }
.swap-form .btn { flex: none; height: 42px; padding: 0 16px; border-radius: 10px; font-size: 14px; background: var(--accent); color: #fff; }
.swap-card { align-self: center; width: min(380px, 100%); display: flex; flex-direction: column; gap: 8px; padding: 16px; border-radius: 18px; background: var(--surface-2); border: 1px solid var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); animation: pop .4s var(--ease); }
.swap-card-title { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 4px; font-size: 14px; font-weight: 600; color: var(--accent); }
.swap-card-title .ico { width: 18px; height: 18px; }
.swap-line { display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 6px 6px 6px 8px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border); }
.swap-line .ava { width: 26px; height: 26px; }
.swap-line .who { flex: none; min-width: 52px; font-size: 12px; color: var(--muted); }
.swap-line b { flex: 1; min-width: 0; font-weight: 600; font-size: 15px; overflow-wrap: anywhere; }
.swap-line .copy { flex: none; height: 30px; padding: 0 10px; border-radius: 8px; font-size: 12.5px; font-weight: 500; color: var(--text); background: var(--surface-3); border: 1px solid var(--border-2); }
.demo .bubble.voice { min-width: 190px; }

/* ---------- calls: voice, and video once a camera is on */
.video { position: relative; flex: none; height: min(40vh, 440px); margin: 14px 24px 0; border-radius: 16px; overflow: hidden; background: #000; border: 1px solid var(--border); animation: pop .3s var(--ease); }
.video[hidden] { display: none; }
.video.audio { height: min(30vh, 260px); }   /* nobody's camera is on */
/* The whole picture in the middle; a blurred copy of it fills the rest of the box. */
.v-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; filter: blur(28px) brightness(.5) saturate(1.2); transform: scale(1.2); pointer-events: none; }
.v-remote { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; transition: filter .35s var(--ease), transform .35s var(--ease); }
.video.blurred .v-remote { filter: blur(38px) saturate(.7); transform: scale(1.25); }
.video.blurred .v-bg { filter: blur(44px) brightness(.4); }
.v-off { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 16px 16px 68px; text-align: center; font-size: 14px; color: var(--text-2); background: var(--bg-2); }
.v-off[hidden] { display: none; }
.v-off .ava { width: 72px; height: 72px; }
.v-off p { font-variant-numeric: tabular-nums; }
/* Both on the call: their face pulses softly, like someone on the line */
.v-off.live .ava { animation: onLine 1.8s ease-out infinite; }
@keyframes onLine { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--glow, var(--accent)) 55%, transparent); } 80%, 100% { box-shadow: 0 0 0 16px transparent; } }
.v-reveal { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 8px; height: 44px; padding: 0 18px; border-radius: 999px; font-size: 14px; font-weight: 600; color: #fff; background: rgba(9, 9, 11, .6); border: 1px solid rgba(255, 255, 255, .22); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.v-reveal[hidden] { display: none; }
.v-reveal .ico { width: 18px; height: 18px; }
.v-muted { position: absolute; left: 12px; top: 12px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(9, 9, 11, .6); }
.v-muted[hidden] { display: none; }
.v-muted .ico { width: 15px; height: 15px; }
.v-local { position: absolute; right: 12px; top: 12px; width: 136px; max-height: 62%; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: #111; border: 1px solid rgba(255, 255, 255, .2); box-shadow: var(--shadow-sm); }
.v-local[hidden] { display: none; }
.v-local.tall { width: 96px; }
.v-local video { display: block; width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); }
.v-local.rear video { transform: none; }   /* the back camera isn't a mirror */
.v-bar { position: absolute; left: 0; right: 0; bottom: 12px; display: flex; justify-content: center; gap: 10px; pointer-events: none; }
.v-btn { pointer-events: auto; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(9, 9, 11, .55); border: 1px solid rgba(255, 255, 255, .2); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); transition: background .15s, transform .12s var(--ease); }
.v-btn:active { transform: scale(.94); }
.v-btn:disabled { opacity: .5; }
.v-btn[hidden] { display: none; }
.v-btn .ico { width: 19px; height: 19px; }
.v-btn.off { color: #111; background: #fff; }
.v-btn.end { background: var(--danger); border-color: transparent; }
.v-btn.start { width: auto; display: inline-flex; align-items: center; gap: 8px; padding: 0 18px; border-radius: 999px; font-size: 14px; font-weight: 600; background: var(--accent); border-color: transparent; }
#camBtn.on { color: #fff; background: var(--danger); border-color: transparent; }
.feed-note { align-self: center; display: flex; align-items: center; gap: 10px; max-width: 480px; padding: 10px 14px; border-radius: 14px; font-size: 13.5px; line-height: 1.45; color: var(--text-2); background: var(--surface-2); border: 1px solid var(--border); animation: in .3s var(--ease); }
.feed-note .ico { flex: none; width: 18px; height: 18px; color: var(--accent); }
.age { margin-top: 8px; font-size: 12.5px; color: var(--muted); }

/* ---------- Georgian: no letter case (uppercase would turn into Mtavruli), calmer tracking */
html[lang="ka"] * { text-transform: none !important; }
html[lang="ka"] .headline { font-size: clamp(30px, 3.3vw, 48px); letter-spacing: -.01em; line-height: 1.18; }
html[lang="ka"] .lead { font-size: 18px; }
html[lang="ka"] .lv-kicker, html[lang="ka"] .pc-kicker { letter-spacing: .01em; }
html[lang="ka"] .lv-name, html[lang="ka"] .pc-end { letter-spacing: 0; }

/* ---------- leaving a chat */
.btn.danger { background: var(--danger); color: #fff; }
.btn.danger:hover { filter: brightness(1.08); }
.leave { width: min(360px, calc(100vw - 32px)); }
.leave-sub { margin-top: -8px; font-size: 14px; line-height: 1.5; color: var(--text-2); }
.leave-btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.leave-btns .btn { height: 44px; justify-content: center; }

/* ---------- the "?" step: what comes next stays hidden, it only moves when it's close */
.step-row.now:not(:last-child)::before { background: repeating-linear-gradient(to bottom, var(--border-2) 0 3px, transparent 3px 7px); }
.step-row.next .dot { border-style: dashed; color: var(--muted); }
.step-row.next .name { color: var(--text-2); font-weight: 500; }
.step-row .q, .tk .q { display: inline-block; font-size: 14px; font-weight: 700; line-height: 1; }
.step-row.next.soon .dot, .step-row.next.ready .dot { border: 1px solid var(--accent); color: var(--accent); background: var(--accent-soft); animation: soonPulse 1.4s ease-out infinite; }
.step-row.next.ready .dot { background: var(--accent); color: #fff; }
.step-row.next.soon .desc, .step-row.next.ready .desc { color: var(--accent); }
.step-row.next.soon .q, .step-row.next.ready .q, .tk.next.soon .q, .tk.next.ready .q { animation: soonWiggle 1.4s ease-in-out infinite; }
@keyframes soonPulse { 0% { box-shadow: 0 0 0 0 var(--accent-ring); } 70%, 100% { box-shadow: 0 0 0 10px rgba(124, 108, 255, 0); } }
@keyframes soonWiggle { 0%, 100% { transform: none; } 20% { transform: rotate(-14deg) scale(1.15); } 40% { transform: rotate(12deg) scale(1.15); } 60% { transform: rotate(-6deg) scale(1.05); } 80% { transform: none; } }
.track-row, .brand-mini { display: none; }
.chat.drop { outline: 2px dashed var(--accent); outline-offset: -10px; }

/* ---------- photos in the chat */
.bubble.photo { padding: 4px; }
.photo-frame { position: relative; display: block; overflow: hidden; border-radius: 14px; background: var(--surface-3); }
.photo-img { display: block; max-width: min(240px, 60vw); max-height: 320px; width: auto; height: auto; object-fit: cover; transition: filter .3s var(--ease), transform .3s var(--ease); }
.row.me .photo-img { cursor: zoom-in; }
.bubble.photo.veiled .photo-img { filter: blur(24px) saturate(.6); transform: scale(1.15); }
.photo-show { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 999px; font-size: 13px; font-weight: 600; white-space: nowrap; color: #fff; background: rgba(9, 9, 11, .6); border: 1px solid rgba(255, 255, 255, .22); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.photo-show .ico { width: 16px; height: 16px; }
.photo-open { position: absolute; right: 6px; top: 6px; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; color: #fff; background: rgba(9, 9, 11, .55); opacity: 0; transition: opacity .15s; }
.photo-open .ico { width: 14px; height: 14px; }
.bubble.photo:hover .photo-open, .photo-open:focus-visible { opacity: 1; }
.bubble.photo.veiled .photo-open { display: none; }
@media (hover: none) { .photo-open { opacity: 1; } }
.viewer { max-width: 100vw; max-height: 100dvh; padding: 0; border: 0; background: transparent; overflow: visible; }
.viewer::backdrop { background: rgba(0, 0, 0, .86); }
.viewer img { display: block; max-width: calc(100vw - 32px); max-height: calc(100dvh - 32px); border-radius: 12px; cursor: zoom-out; }

/* ---------- my profile */
.profile { width: min(400px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 20px; border-radius: 18px; border: 1px solid var(--border-2); background: var(--surface); color: var(--text); box-shadow: var(--shadow-lg); overflow-y: auto; }
.profile[open] { display: flex; flex-direction: column; gap: 16px; animation: pop .25s var(--ease); }
.profile::backdrop { background: rgba(9, 9, 11, .6); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.pf-head { display: flex; align-items: center; justify-content: space-between; margin: -4px -6px -4px 0; }
.pf-title { font-size: 17px; font-weight: 600; }
.pf-x { width: 34px; height: 34px; border-radius: 9px; display: grid; place-items: center; color: var(--text-2); }
.pf-x:hover { color: var(--text); background: var(--surface-2); }
.pf-photo { display: flex; align-items: center; gap: 16px; }
.pf-ava { width: 72px; height: 72px; box-shadow: 0 0 0 3px var(--surface), 0 0 0 4px var(--border-2); }
.pf-photo-btns { display: flex; flex-wrap: wrap; gap: 6px; }
.pf-err { margin-top: -6px; font-size: 13px; color: var(--danger); }
.pf-field { display: flex; flex-direction: column; gap: 6px; }
.pf-label { font-size: 13px; font-weight: 500; color: var(--text-2); }
.pf-input { height: 42px; padding: 0 12px; border-radius: 10px; background: var(--bg); border: 1px solid var(--border-2); color: var(--text); font-size: 15px; outline: none; transition: border-color .15s, box-shadow .15s; }
.pf-input:focus { border-color: var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); }
.pf-input::placeholder { color: var(--muted); }
.pf-seg { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.pf-seg button { height: 40px; border-radius: 10px; font-size: 14px; font-weight: 500; color: var(--text-2); background: var(--bg); border: 1px solid var(--border-2); transition: color .12s, background .12s, border-color .12s; }
.pf-seg button:hover { color: var(--text); border-color: var(--muted); }
.pf-seg button[aria-pressed="true"] { color: var(--text); background: var(--accent-soft); border-color: var(--accent); }
.pf-note { font-size: 13px; line-height: 1.45; color: var(--muted); }

/* ---------- the steps: the gate bar, the cards of a round, the stranger coming into view */
.gate { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; padding: 12px 14px; border-radius: 14px; background: var(--accent-soft); border: 1px solid var(--accent-ring); animation: pop .3s var(--ease); }
.gate[hidden] { display: none; }
.gate-text { flex: 1 1 240px; min-width: 0; }
.gate-title { font-size: 14.5px; font-weight: 600; }
.gate-sub { margin-top: 1px; font-size: 12.5px; line-height: 1.4; color: var(--text-2); }
.gate-sub.them-in { color: var(--success); font-weight: 500; }
.gate-acts { flex: none; display: flex; align-items: center; gap: 8px; }
.gate .btn .ico { width: 16px; height: 16px; }
.gate .btn.ghost:hover { background: rgba(255, 255, 255, .06); }
.gate-thumb { flex: none; width: 44px; height: 44px; border-radius: 10px; object-fit: cover; border: 1px solid var(--accent-ring); }
.hello-rec, .hello-review { flex: 1 1 280px; }
.hello-rec .rec-wave { justify-content: flex-start; }
.hello-review .bubble.voice { flex: 1; min-width: 0; max-width: none; background: var(--surface); animation: none; }

.rit { align-self: center; width: min(420px, 100%); padding: 16px; border-radius: 18px; text-align: center; background: var(--surface-2); border: 1px solid var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); animation: pop .4s var(--ease); }
.rit-title { display: flex; align-items: center; justify-content: center; gap: 8px; margin-bottom: 12px; font-size: 13.5px; font-weight: 600; color: var(--accent); }
.rit-title .ico { width: 16px; height: 16px; }
.snap-pair { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.snap-tile { position: relative; display: block; aspect-ratio: 4 / 5; border-radius: 12px; overflow: hidden; background: var(--surface-3); cursor: zoom-in; }
.snap-tile > img { display: block; width: 100%; height: 100%; object-fit: cover; transition: filter .3s var(--ease), transform .3s var(--ease); }
.snap-tile.veiled { cursor: pointer; }
.snap-tile.veiled > img { filter: blur(24px) saturate(.6); transform: scale(1.15); }
.snap-who { position: absolute; left: 8px; bottom: 8px; width: 26px; height: 26px; box-shadow: 0 0 0 2px rgba(9, 9, 11, .6); }
.snap-tile.fake { display: grid; place-items: center; aspect-ratio: 4 / 3; font-size: 40px; cursor: default; background: linear-gradient(135deg, var(--surface-3), var(--surface)); }
.hello-card { display: flex; flex-direction: column; gap: 8px; }
.hello-card .rit-title { margin-bottom: 4px; }
.hello-card .row { flex-wrap: nowrap; }
.hello-card .bubble.voice { flex: 0 1 270px; min-width: 0; max-width: 88%; animation: none; }
.hello-card .row.them .bubble { cursor: default; }
.demo .rit { padding: 12px 14px; }
.demo .rit-title { margin-bottom: 8px; }

.reveal { align-self: center; display: flex; align-items: center; gap: 12px; max-width: 100%; padding: 10px 20px 10px 10px; border-radius: 999px; text-align: left; background: var(--surface-2); border: 1px solid var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft); animation: pop .4s var(--ease); }
.reveal .ava { width: 40px; height: 40px; }
.reveal-k { font-size: 11.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.reveal-v { font-size: 16px; font-weight: 700; letter-spacing: -.01em; overflow-wrap: anywhere; }
.reveal.photo { flex-direction: column; gap: 10px; padding: 18px 26px 14px; border-radius: 22px; text-align: center; }
.reveal-pic { border-radius: 50%; cursor: zoom-in; }
.reveal-pic .ava { width: 112px; height: 112px; box-shadow: 0 0 0 3px var(--surface-2), 0 0 0 4px var(--accent-ring); }
html[lang="ka"] .reveal-k { letter-spacing: .01em; }
.note-btn { flex: none; height: 30px; padding: 0 12px; border-radius: 8px; font-size: 12.5px; font-weight: 600; white-space: nowrap; color: #fff; background: var(--accent); }
.note-btn:hover { background: var(--accent-hover); }

/* The meter under the "?": how far the talking has filled the way to the next step */
.step-row.next .mini-bar { max-width: 160px; }
.mini-bar i { transform: scaleX(0); background: linear-gradient(90deg, var(--me-1), #FF7AD9); }
.mini-bar.kick { animation: kick .45s var(--ease); }
@keyframes kick { 30% { transform: scaleY(2.4); filter: brightness(1.5); } }
@keyframes tkKick { 30% { transform: scale(1.25); border-color: var(--accent); color: var(--accent); } }

/* 3, 2, 1 before both cameras come on */
.lv-card.count { min-width: 230px; }
.count-n { margin-bottom: 6px; font-size: 88px; font-weight: 800; line-height: 1; letter-spacing: -.04em; font-variant-numeric: tabular-nums; background: linear-gradient(135deg, var(--me-1), #FF7AD9); -webkit-background-clip: text; background-clip: text; color: transparent; animation: pop .35s var(--ease); }

/* ---------- people I kept: the list on the first page, someone asking to talk */
.people { margin-top: 28px; max-width: 420px; }
.people-title { margin-bottom: 8px; font-size: 12.5px; font-weight: 600; color: var(--muted); }
.people-list { display: flex; flex-direction: column; gap: 6px; }
.person { display: flex; align-items: center; gap: 12px; min-height: 56px; padding: 8px 6px 8px 10px; border-radius: 14px; text-align: left; background: var(--surface); border: 1px solid var(--border); }
.person.on { border-color: var(--border-2); }
.person-face { position: relative; flex: none; }
.person-face .ava { width: 38px; height: 38px; }
.person-dot { position: absolute; right: -1px; bottom: -1px; width: 11px; height: 11px; border-radius: 50%; background: var(--muted); box-shadow: 0 0 0 2px var(--surface); }
.person.on .person-dot { background: var(--success); }
.person:not(.on) .person-face .ava { opacity: .55; }
.person-text { flex: 1; min-width: 0; }
.person-name { font-size: 14.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person-state { font-size: 12.5px; color: var(--muted); }
.person.on .person-state { color: var(--success); }
.person-x { flex: none; width: 30px; height: 30px; border-radius: 8px; display: grid; place-items: center; color: var(--muted); }
.person-x:hover { color: var(--text); background: var(--surface-2); }
.person-x .ico { width: 14px; height: 14px; }
.ring { position: fixed; left: 12px; right: 12px; top: 14px; z-index: 65; display: flex; align-items: center; gap: 10px; width: max-content; max-width: calc(100vw - 24px); margin: 0 auto; padding: 10px 10px 10px 12px; border-radius: 16px; background: var(--surface-2); border: 1px solid var(--accent-ring); box-shadow: 0 0 0 4px var(--accent-soft), var(--shadow-lg); animation: in .25s var(--ease); }
.ring .ava { width: 36px; height: 36px; animation: avaHop .9s var(--ease) infinite; }
.ring-text { flex: 1; min-width: 0; margin-right: 4px; font-size: 14px; font-weight: 600; }
.kept-card { text-align: center; }
.kept-sub { font-size: 13.5px; line-height: 1.45; color: var(--text-2); }
.pc-kept { display: flex; align-items: center; justify-content: center; gap: 8px; margin-top: 16px; font-size: 13.5px; color: var(--text-2); }
.pc-kept .ico { color: var(--accent); }
.gate.keep { animation: none; }

/* ---------- room for the chat at the top step and on a call
   The contact box and Keep sit side by side where there's width for both. On a computer the call
   box gives way before the messages do, so nothing pushes the text field off the screen. */
.top-bars { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 10px; }
.chat.gifs .top-bars { display: none; }   /* choosing a GIF: the picker has their place for a moment */
.video { container-type: size; }
@container (max-height: 210px) {
  .v-off { gap: 6px; padding-bottom: 60px; }
  .v-off .ava { width: 44px; height: 44px; }
}
@container (max-height: 150px) { .v-off .ava { display: none; } }
@media (min-width: 861px) {
  .video { flex: 0 1 auto; min-height: 120px; }
  .feed { min-height: 160px; }
  .chat.gifs .feed { min-height: 96px; }
  body.in-call .gif-panel .gif-grid { height: 112px; }
}
@media (min-width: 861px) and (max-width: 1179px) { .top-bars { grid-auto-flow: row; } }
@media (min-width: 861px) and (max-height: 720px) {
  body.in-call .chat-head { display: none; }
  .feed { min-height: 120px; }
  .chat.gifs .feed { min-height: 80px; }
}
.pc-contact { margin-bottom: 18px; text-align: left; }
.pc-contact .pc-kicker { margin-bottom: 8px; text-align: center; }
.gif-note { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin: -2px 2px; font-size: 12.5px; line-height: 1.35; color: var(--text-2); }
.gif-retry { flex: none; height: 28px; padding: 0 10px; border-radius: 8px; font-size: 12.5px; font-weight: 600; color: var(--accent); background: var(--accent-soft); }

/* ---------- signs of life: someone is looking right now, and the stranger busy with their next message */
.online.seeking { color: var(--text); font-weight: 500; }
.online.seeking::before { background: var(--accent); box-shadow: none; animation: soonPulse 1.4s ease-out infinite; }
#findBtn.seeking { animation: seekGlow 1.6s ease-in-out infinite; }
@keyframes seekGlow { 50% { box-shadow: 0 0 0 6px var(--accent-soft), 0 10px 34px -6px var(--accent); } }
.row.them .bubble.busy { gap: 4px; padding: 12px 14px; cursor: default; }
.row.them .bubble.busy:hover { border-color: var(--border); }
.bubble.busy i { width: 6px; height: 6px; border-radius: 50%; background: var(--muted); animation: blink 1s infinite; }
.bubble.busy i:nth-of-type(2) { animation-delay: .15s; }
.bubble.busy i:nth-of-type(3) { animation-delay: .3s; }
.bubble.busy .ico { width: 15px; height: 15px; margin-right: 3px; color: var(--text-2); }

/* ---------- something to say: ready-made questions after a silence */
.starters { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; margin: 0 -2px; padding: 0 2px; animation: in .25s var(--ease); }
.starters::-webkit-scrollbar { display: none; }
.starter { flex: none; height: 32px; padding: 0 12px; border-radius: 999px; font-size: 13px; font-weight: 500; white-space: nowrap; color: var(--text); background: var(--accent-soft); border: 1px solid var(--accent-ring); transition: background .12s, transform .12s var(--ease); }
.starter:hover { background: color-mix(in srgb, var(--accent) 26%, transparent); }
.starter:active { transform: scale(.97); }

/* ---------- tablet and phone */
@media (max-width: 860px) {
  .nav { height: 56px; padding: 0 16px; }
  .hero { grid-template-columns: 1fr; gap: 36px; padding: 16px 0 32px; text-align: center; }
  .headline { font-size: clamp(36px, 10vw, 48px); }
  .lead { font-size: 17px; margin: 0 auto; }
  .cta-row { flex-direction: column; gap: 14px; margin-top: 28px; }
  .cta-row .btn { width: 100%; max-width: 360px; }
  .demo { height: 360px; max-width: 420px; width: 100%; margin: 0 auto; }
  .screen { padding: 0 16px 16px; }

  #match { padding: 0; }
  .frame { grid-template-columns: 1fr; border: 0; border-radius: 0; box-shadow: none; background: var(--bg); }
  .side { display: none; }
  .chat-head { padding: 8px 12px 10px; gap: 8px; background: var(--bg); }
  .mobile-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
  .chip { display: flex; align-items: center; gap: 8px; min-width: 0; height: 36px; padding: 0 12px 0 4px; border-radius: 999px; background: var(--surface); border: 1px solid var(--border); }
  .chip .them-info { flex-wrap: nowrap; font-size: 13px; white-space: nowrap; overflow: hidden; }
  .chip .them-info .nm { font-weight: 600; max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
  .me-btn { max-width: 150px; }
  .mobile-only { display: block; }
  .fuse.mobile-only { height: 4px; }
  .stage-title { font-size: 14px; }
  .hint { font-size: 12px; }
  .spark { display: none; }
  .ladder-mini { display: grid; grid-template-columns: repeat(5, 22px); gap: 4px; flex: none; }
  .ladder-mini i { height: 4px; border-radius: 999px; background: var(--surface-3); position: relative; overflow: hidden; }
  .ladder-mini i::after { content: ''; position: absolute; inset: 0; background: var(--accent); transform-origin: left; transform: scaleX(var(--f, 0)); transition: transform .5s var(--ease); }
  .feed { padding: 14px 12px; }
  .bubble { max-width: 82%; }
  .composer { padding: 10px 12px calc(10px + env(safe-area-inset-bottom)); background: var(--bg); }
  .tabs { display: grid; grid-template-columns: repeat(4, 1fr); align-self: stretch; }
  .tab { justify-content: center; padding: 0 6px; }
  .panel { height: 176px; }
  .emoji-grid { grid-template-columns: repeat(8, 1fr); }
  .key { font-size: 23px; }
  .gif-grid { grid-template-columns: repeat(3, 1fr); }
  .gif img { height: 80px; }
  .center-card { padding: 32px 24px; border-radius: 20px; }
  .end-actions { flex-direction: column; }
  .end-actions .btn { flex: none; }
  .postcard { padding: 22px; }
  .gif-panel { padding: 10px; }
  .gif-panel .gif-grid { height: 150px; grid-template-columns: repeat(3, 1fr); }
  .stage-head { flex-wrap: wrap; gap: 8px; }
  .gif-need { gap: 6px; }
  .need { height: 26px; padding: 0 9px; font-size: 12px; }
  .gif-panel .gif-grid { grid-auto-rows: 72px; }
  .gif-msg { max-width: 168px; max-height: 168px; }
  .photo-img { max-width: min(200px, 56vw); max-height: 260px; }
  .gif-panel .gif img { height: 72px; }
  .bubble.voice { min-width: 0; width: 240px; max-width: 82%; }
  .react-pop { gap: 0; margin-left: 30px; }
  .react-pop button { width: 34px; height: 34px; }
  .react-pop img { width: 24px; height: 24px; }
  .swap-form .btn { padding: 0 12px; }
  .pc-stats .stat b { font-size: 19px; }
  .video { margin: 8px 12px 0; height: 36vh; border-radius: 14px; }
  .v-local { width: 100px; right: 10px; top: 10px; }
  .v-local.tall { width: 72px; }
  .age { margin-top: 4px; }

  /* The chat on a phone: no site header, everything the chat needs in two short rows. */
  body[data-screen="match"] .nav { display: none; }
  .chat-head { padding: 8px 12px; gap: 8px; }
  .brand-mini { flex: none; display: grid; place-items: center; width: 34px; height: 36px; margin-right: -2px; }
  .brand-mini .mark { width: 28px; height: 28px; }
  .chip { flex: 0 1 auto; margin-right: auto; }
  .stage-head { display: none; }
  .track-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 26px; }
  .track { display: flex; align-items: center; min-width: 0; }
  .tk { position: relative; flex: none; display: inline-grid; place-items: center; width: 24px; height: 24px; border-radius: 50%; border: 1px solid var(--border-2); color: var(--muted); background: var(--surface); }
  .tk:not(:first-child) { margin-left: 10px; }
  .tk:not(:first-child)::before { content: ''; position: absolute; right: 100%; top: 50%; width: 10px; height: 1px; background: var(--border-2); }
  .tk .ico { width: 12px; height: 12px; }
  .tk .q { font-size: 12px; }
  .tk.done { background: var(--success-soft); border-color: transparent; color: var(--success); }
  .tk.now { display: inline-flex; align-items: center; gap: 6px; width: auto; padding: 0 10px 0 7px; border-radius: 999px; border-color: transparent; color: #fff; background: var(--accent); font-size: 12.5px; }
  .tk.now b { font-weight: 600; white-space: nowrap; }
  .tk.next { border-style: dashed; }
  .tk.next.soon, .tk.next.ready { border: 1px solid var(--accent); color: var(--accent); background: var(--accent-soft); animation: soonPulse 1.4s ease-out infinite; }
  .tk.next.ready { color: #fff; background: var(--accent); }
  .track-time { flex: none; font-size: 12px; color: var(--muted); white-space: nowrap; }
  .composer { gap: 8px; padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); }
  body.kb .composer { padding-bottom: 8px; }
  .swap { gap: 8px; padding: 10px; }
  .swap-head .consent-ico, .swap-status.plain { display: none; }
  .swap-head p { font-size: 13px; }
  .swap-in, .swap-form .btn { height: 40px; }
  .video { height: calc(var(--vh, 100vh) * .34); }
  .video.audio { height: calc(var(--vh, 100vh) * .27); }
  .top-bars { display: contents; }   /* one under the other, each a row of the composer */
  /* While typing, only what the typing needs: the steps row and the contact box (unless that's
     where you type) step aside, and the video shrinks. The contact box and Keep stay, as a
     single line each, once the stranger has done their part and is waiting for mine (.attn). */
  body.kb .track-row, body.kb[data-focus="textIn"] #swap:not(.attn), body.kb #keep:not(.attn) { display: none; }
  body.kb[data-focus="textIn"] #swap.attn { cursor: pointer; }
  body.kb[data-focus="textIn"] #swap.attn .swap-form, body.kb #keep.attn .gate-title { display: none; }
  body.kb #keep.attn .gate-sub { display: block; margin: 0; }
  body.kb .video { height: calc(var(--vh, 100vh) * .26); margin-top: 6px; }
  body.kb .v-local { width: 64px; }
  body.kb .v-local.tall { width: 48px; }
  body.kb .v-bar { bottom: 6px; }
  body.kb .v-btn { width: 36px; height: 36px; }
  body.kb .gif-chips { display: none; }
  body.kb .gif-panel .gif-grid { height: 112px; }
  .text-in { font-size: 16px; }   /* 16px keeps iPhone Safari from zooming in on focus */
  .tray { gap: 6px; padding-left: 8px; }
  .tray .mic-btn { width: 34px; height: 34px; }
  .tray .gif-btn { padding: 0 8px; }
  .swap-in, .gif-search, .pf-input { font-size: 16px; }
  /* The steps row: finished ones shrink to dots once there are more than a
     few, and the line to the "?" fills as the two talk. */
  .track.many .tk.done { width: 8px; height: 8px; border: 0; background: var(--success); opacity: .75; }
  .track.many .tk.done .ico { display: none; }
  .track.many .tk:not(:first-child) { margin-left: 6px; }
  .track.many .tk:not(:first-child)::before { display: none; }
  .track.many .tk.now { margin-left: 8px; }
  .track .tk.next:not(:first-child) { margin-left: 36px; }
  .track .tk.next:not(:first-child)::before { display: block; right: calc(100% + 4px); width: 28px; height: 2px; margin-top: -1px; border-radius: 2px; background: linear-gradient(to right, var(--accent) calc(var(--p, 0) * 100%), var(--border-2) 0); }
  .tk.next.kick:not(.soon):not(.ready) { animation: tkKick .45s var(--ease); }
  .gate { gap: 8px 10px; padding: 10px; }
  .gate .consent-ico { display: none; }
  .gate-text { flex-basis: 200px; }
  .gate-title { font-size: 14px; }
  .gate-sub { font-size: 12px; }
  .gate-acts { flex: 1 1 100%; }
  .gate-acts .btn.primary { flex: 1; justify-content: center; }
  .hello-review { flex-wrap: wrap; }
  .hello-review .bubble.voice { flex-basis: 100%; }
  .hello-review .btn { flex: 1; }
  body.kb .gate-sub { display: none; }
  .rit { padding: 12px; }
  .reveal-pic .ava { width: 96px; height: 96px; }
  /* Once there's text in the field, the buttons beside it step aside to leave room for it. */
  .tray.typing .mic-btn { display: none; }
  .people { margin: 24px auto 0; width: 100%; max-width: 360px; }
  .today { margin: 20px auto 0; width: 100%; max-width: 360px; }
  .center-card .today { margin-top: 10px; }
  .people-title { text-align: left; }
  .ring { flex-wrap: wrap; width: auto; }
  .ring .btn { flex: 1; }
  .ring-text { flex: 1 1 calc(100% - 60px); margin-right: 0; }
  .gate.keep .gate-text { flex: 1 1 0; }
  .gate.keep .gate-acts { flex: none; }
}
@media (max-width: 380px) {
  .tab .ico { display: none; }
  .me-name { display: none; }
  .me-btn { padding: 0 3px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition: none !important; }
}
