/* The chat with your person (chat.js): press-and-hold actions, replies, reactions, search,
   going to a day, and "Shared with each other". The chat's base styles are in app.css (.talk-*). */

.talk-view .doc-top { gap: 8px; }
.talk-view .v-when b, .talk-view .v-when span { display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.talk-tools { display: flex; gap: 6px; flex: none; }
.talk-tool {
  width: 38px; height: 38px; border-radius: 50%; border: 0; background: var(--chip); color: var(--fg);
  display: grid; place-items: center; padding: 9px; flex: none;
}
.talk-tool svg { width: 100%; height: 100%; display: block; }
.talk-view .chat-bar textarea { font-size: 16px; }   /* 16px: iPhones don't zoom in when you type */

.talk-body { flex: 1; min-height: 0; position: relative; display: flex; flex-direction: column; }
.talk-body .talk-thread { flex: 1; min-height: 0; }

/* press and hold a message (the phone's own text menu would get in the way) */
.talk-msg { -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; border-radius: 0 10px 10px 0; transition: background-color .4s; }
.talk-msg.talk-found { background: color-mix(in srgb, var(--accent) 30%, transparent); transition: none; }
.talk-msg mark, .talk-result mark { background: var(--accent); color: var(--accent-fg); border-radius: 3px; padding: 0 1px; }

/* a reply's quote */
.talk-quote {
  display: block; width: 100%; max-width: 420px; text-align: left; border: 0; border-left: 3px solid #0eadff;
  background: var(--chip); color: var(--fg); border-radius: 0 10px 10px 0; padding: 5px 10px; margin: 4px 0 3px; font-size: 13.5px;
}
.talk-quote.me { border-left-color: #f23c57; }
.talk-quote b { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase; color: #0eadff; }
.talk-quote.me b { color: #f23c57; }
.talk-quote span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; color: var(--muted); overflow-wrap: anywhere; }
.talk-replying { display: flex; align-items: center; gap: 8px; padding: 8px 12px 0; background: var(--bg); border-top: 1px solid var(--line); }
.talk-replying .talk-quote { margin: 0; flex: 1; min-width: 0; max-width: none; }
.talk-replying + .chat-bar { border-top: 0; }
.talk-x {
  width: 32px; height: 32px; border-radius: 50%; border: 0; background: var(--chip); color: var(--fg);
  display: grid; place-items: center; padding: 8px; flex: none;
}
.talk-x svg { width: 100%; height: 100%; display: block; }

/* reactions */
.talk-reacts { display: flex; flex-wrap: wrap; gap: 6px; margin: 3px 0 1px; }
.talk-react { display: inline-flex; align-items: center; gap: 4px; background: var(--chip); border-radius: 999px; padding: 1px 9px 1px 6px; font-size: 15px; line-height: 1.5; }
.talk-react small { font-size: 11px; font-weight: 800; color: var(--muted); }

/* the press-and-hold sheet */
.talk-react-row { display: flex; gap: 6px; margin: 2px 0 14px; }
.talk-react-pick { flex: 1; height: 56px; border: 0; border-radius: 16px; background: var(--chip); font-size: 28px; line-height: 1; padding: 0; }
.talk-react-pick[aria-pressed="true"] { background: var(--chip-on); box-shadow: 0 0 0 2px var(--accent) inset; }
.talk-react-pick:active { transform: scale(.92); }
.talk-preview { background: var(--chip); border-radius: 14px; border-left: 3px solid #0eadff; padding: 9px 12px; margin: 0 0 14px; font-size: 14.5px; overflow-wrap: anywhere; }
.talk-preview.me { border-left-color: #f23c57; }
.talk-preview b { display: block; font-size: 11.5px; font-weight: 800; text-transform: uppercase; color: var(--muted); }
.talk-preview span { display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.talk-actions { display: flex; gap: 8px; }
.talk-actions .btn { flex: 1; margin: 0; }
.talk-day-picks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }

/* search */
.talk-search { display: flex; gap: 6px; align-items: center; padding: 8px 12px; border-bottom: 1px solid var(--line); background: var(--bg); }
.talk-search input {
  flex: 1; min-width: 0; height: 38px; border-radius: 12px; border: 1.5px solid var(--line); background: var(--chip);
  color: var(--fg); padding: 0 12px; font-size: 16px;
}
.talk-count { font-size: 12.5px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.talk-step {
  width: 34px; height: 34px; border-radius: 50%; border: 0; background: var(--chip); color: var(--fg);
  display: grid; place-items: center; padding: 8px; flex: none;
}
.talk-step svg { width: 100%; height: 100%; display: block; }
.talk-step.up svg { transform: rotate(180deg); }
.talk-done { border: 0; background: none; color: var(--send); font-weight: 800; padding: 6px 2px 6px 4px; flex: none; min-height: 44px; }
.talk-results {
  position: absolute; left: 0; right: 0; top: 0; z-index: 3; max-height: 62%; overflow-y: auto; background: var(--bg);
  border-bottom: 1px solid var(--line); box-shadow: 0 12px 28px rgba(0,0,0,.2);
}
.talk-result { display: block; width: 100%; text-align: left; border: 0; border-top: 1px solid var(--line); background: none; color: var(--fg); padding: 9px 16px; }
.talk-result:first-child { border-top: 0; }
.talk-result-who { display: block; font-size: 12px; font-weight: 800; }
.talk-result-who small { font-weight: 600; color: var(--muted); font-size: 12px; }
.talk-result-text { display: block; font-size: 14px; overflow-wrap: anywhere; }
.talk-noresult { color: var(--muted); padding: 14px 16px; margin: 0; font-size: 14px; }

/* back down to the newest */
.talk-latest {
  position: absolute; right: 14px; bottom: 12px; z-index: 2; display: flex; align-items: center; gap: 4px;
  border: 0; border-radius: 999px; background: var(--chip-on); color: var(--chip-on-fg); padding: 8px 14px 8px 10px;
  font-weight: 800; font-size: 13.5px; box-shadow: 0 4px 14px rgba(0,0,0,.25);
}
.talk-latest span { width: 16px; height: 16px; display: block; }
.talk-latest svg { width: 100%; height: 100%; display: block; }

/* shared with each other */
.talk-gallery { position: absolute; inset: 0; z-index: 5; background: var(--bg); color: var(--fg); overflow-y: auto; overscroll-behavior: contain; }
.talk-g-month h3 { font-size: 15px; font-weight: 800; margin: 18px 14px 8px; }
.talk-g-month h3 span { color: var(--muted); font-size: 12.5px; font-weight: 600; }
.talk-g-grid { display: grid; grid-template-columns: repeat(var(--cols), 1fr); gap: 2px; padding: 0 2px; }
.talk-g-tile { position: relative; aspect-ratio: 3/4; border: 0; padding: 0; background: var(--tile); overflow: hidden; border-radius: 3px; display: block; width: 100%; }
.talk-g-tile img { width: 100%; height: 100%; object-fit: cover; display: block; }
.talk-g-tile img:not([src]) { visibility: hidden; }
.talk-g-tile.video { background: #1b1b22; }
.talk-g-tile.missing { background: repeating-linear-gradient(45deg, var(--tile), var(--tile) 8px, var(--chip) 8px, var(--chip) 16px); }
.talk-g-play { position: absolute; right: 6px; top: 6px; width: 20px; height: 20px; color: #fff; filter: drop-shadow(0 1px 2px rgba(0,0,0,.6)); }
.talk-g-play svg { width: 100%; height: 100%; display: block; }
.talk-g-from {
  position: absolute; left: 6px; bottom: 5px; font-size: 10.5px; font-weight: 800; color: #fff; text-transform: uppercase;
  letter-spacing: .03em; text-shadow: 0 1px 3px rgba(0,0,0,.7);
}
.talk-g-empty { text-align: center; color: var(--muted); padding: 60px 24px; max-width: 420px; margin: 0 auto; }
.talk-g-foot { height: calc(var(--safe-b) + 30px); }

/* photos and videos full screen */
.talk-lightbox.talk-lb { display: flex; flex-direction: column; align-items: stretch; color: #fff; background: #000; }
.talk-lb-top { display: flex; align-items: center; gap: 10px; padding: calc(var(--safe-t) + 10px) 14px 10px; flex: none; }
.talk-lb-cap { flex: 1; min-width: 0; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.talk-lb-cap span { opacity: .75; }
.talk-lb-media { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; position: relative; touch-action: pan-y; }
.talk-lb-frame { position: relative; line-height: 0; }
/* fitted to the space between the bars (a video's caption layer is fitted the same way, so it lines up) */
.talk-lightbox .talk-lb-frame img, .talk-lightbox .talk-lb-frame video {
  display: block; width: 100vw; height: calc(100vh - 140px - var(--safe-t) - var(--safe-b));
  height: calc(100dvh - 140px - var(--safe-t) - var(--safe-b)); max-width: none; max-height: none; object-fit: contain;
}
.talk-lightbox .talk-lb-frame .talk-lb-layer { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.talk-lb-bottom { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 14px calc(var(--safe-b) + 14px); flex: none; }
.talk-lb-btn {
  border: 0; background: rgba(255,255,255,.16); color: #fff; border-radius: 999px; height: 42px; min-width: 42px;
  padding: 0 16px; font-weight: 800; font-size: 15px; display: grid; place-items: center; line-height: 1;
}
.talk-lb-btn.round { width: 42px; padding: 10px; }
.talk-lb-btn.arrow { width: 42px; padding: 0 0 3px; font-size: 28px; font-weight: 400; }
.talk-lb-btn svg { width: 100%; height: 100%; display: block; }
.talk-lb-btn:disabled { opacity: .3; }
.talk-lb-note { color: #ddd; padding: 30px; text-align: center; font-size: 15px; }

/* ------------------------------------------------------------------ fingers, eyes and screen readers */

/* small round buttons keep their look, but answer a 44px tap (Apple's smallest comfortable target) */
.talk-tool, .talk-step, .talk-x, .talk-done { position: relative; }   /* (.talk-latest is placed already) */
.talk-tool::after, .talk-step::after, .talk-x::after, .talk-latest::after, .talk-done::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: max(100%, 44px); height: max(100%, 44px); transform: translate(-50%, -50%);
}
.talk-lb-btn { min-width: 44px; height: 44px; }
.talk-lb-btn.round, .talk-lb-btn.arrow { width: 44px; }

/* read out, not shown: a new message from them */
.talk-sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* light mode: the bright blue and red names, "Done" and "Couldn't send" are too faint on white to
   read (2.2–3.5:1), so they're a shade deeper there (4.8:1 and up); dark mode keeps the bright ones */
.talk-who, .talk-quote b, .talk-done { color: #006fb3; }
.talk-msg.me .talk-who, .talk-quote.me b, .talk-view .talk-status.bad { color: #c8102e; }
@media (prefers-color-scheme: dark) {
  .talk-who, .talk-quote b { color: #0eadff; }
  .talk-done { color: var(--send); }
  .talk-msg.me .talk-who, .talk-quote.me b { color: #f23c57; }
  .talk-view .talk-status.bad { color: var(--heart); }
}

/* ------------------------------------------------------------------ live: here, typing, pins, colour (chat-live.js) */

.talk-view .v-when { min-width: 0; flex: 1; }
.talk-view .v-when span.here { color: #1a8a4a; font-weight: 700; }
.talk-view .v-when span.here::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: #1fbf6a; margin-right: 5px; vertical-align: 1px; }
.talk-tools { gap: 4px; }

/* "Anna is here" / "Anna is typing…": her face at the bottom of the chat, like a Bitmoji */
.talk-presence {
  position: absolute; left: 12px; bottom: 10px; z-index: 2; display: flex; align-items: center; gap: 7px; pointer-events: none;
  background: color-mix(in srgb, var(--bg) 88%, transparent); border-radius: 999px; padding: 3px 12px 3px 3px; box-shadow: 0 2px 10px rgba(0,0,0,.12);
  font-size: 12.5px; font-weight: 700; color: var(--muted); animation: talk-pop .25s ease-out;
}
.talk-presence[hidden] { display: none; }
.talk-face { width: 30px; height: 30px; border-radius: 50%; background: #0eadff; color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 14px; }
.talk-typing { display: inline-flex; gap: 3px; }
.talk-typing i { width: 6px; height: 6px; border-radius: 50%; background: #0eadff; animation: talk-dot 1.1s infinite ease-in-out; }
.talk-typing i:nth-child(2) { animation-delay: .15s; }
.talk-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes talk-dot { 0%, 60%, 100% { transform: translateY(0); opacity: .45; } 30% { transform: translateY(-4px); opacity: 1; } }
@keyframes talk-pop { from { transform: translateY(8px) scale(.9); opacity: 0; } }
.talk-view.them-here .talk-thread { padding-bottom: 52px; }

/* the pinned bar */
.talk-pinned {
  display: flex; align-items: center; gap: 10px; width: 100%; border: 0; border-bottom: 1px solid var(--line); background: var(--bg); color: var(--fg);
  padding: 7px 14px; text-align: left; min-height: 44px;
}
.talk-pinned[hidden] { display: none; }
.talk-pinned-ico { width: 18px; height: 18px; flex: none; color: var(--muted); }
.talk-pinned-ico svg, .talk-menu-ico svg { width: 100%; height: 100%; display: block; }
.talk-pinned-text { min-width: 0; flex: 1; }
.talk-pinned-text b { display: block; font-size: 11px; font-weight: 800; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.talk-pinned-text span { display: block; font-size: 13.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.talk-msg.pinned > .talk-who::after { content: "📌"; font-size: 11px; margin-left: 6px; }

/* the chat's colour (both phones): the background behind the messages */
.talk-view[data-theme="midnight"] .talk-thread { background: linear-gradient(180deg, #e9ecff, #f6f2ff); }
.talk-view[data-theme="sunset"] .talk-thread { background: linear-gradient(180deg, #fff1e3, #ffe6ec); }
.talk-view[data-theme="ocean"] .talk-thread { background: linear-gradient(180deg, #e3f6ff, #e6fff8); }
.talk-view[data-theme="blush"] .talk-thread { background: linear-gradient(180deg, #ffeef4, #fff6f0); }
.talk-view[data-theme="forest"] .talk-thread { background: linear-gradient(180deg, #e9f7ec, #f3f8e6); }
.talk-view[data-theme="lavender"] .talk-thread { background: linear-gradient(180deg, #f2ecff, #fbeffd); }
.talk-view[data-theme="sand"] .talk-thread { background: linear-gradient(180deg, #fbf4e6, #f6efe2); }
@media (prefers-color-scheme: dark) {
  .talk-view[data-theme="midnight"] .talk-thread { background: linear-gradient(180deg, #121433, #1b1030); }
  .talk-view[data-theme="sunset"] .talk-thread { background: linear-gradient(180deg, #2a1610, #2a1020); }
  .talk-view[data-theme="ocean"] .talk-thread { background: linear-gradient(180deg, #0b2230, #0b2a24); }
  .talk-view[data-theme="blush"] .talk-thread { background: linear-gradient(180deg, #2a121c, #26160f); }
  .talk-view[data-theme="forest"] .talk-thread { background: linear-gradient(180deg, #102417, #1a2410); }
  .talk-view[data-theme="lavender"] .talk-thread { background: linear-gradient(180deg, #1d1530, #28142a); }
  .talk-view[data-theme="sand"] .talk-thread { background: linear-gradient(180deg, #26200f, #221d14); }
  .talk-view .v-when span.here { color: #4ade80; }
}
.talk-themes { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.talk-theme-pick {
  border: 0; background: var(--chip); color: var(--fg); border-radius: 14px; padding: 8px 4px; font-size: 12.5px; font-weight: 700;
  display: grid; gap: 6px; justify-items: center; min-height: 44px;
}
.talk-theme-pick i { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg); }
.talk-theme-pick[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--accent) inset; }
.th-midnight i { background: linear-gradient(135deg, #5b6cff, #a78bfa); }
.th-sunset i { background: linear-gradient(135deg, #ff9a3c, #ff5e8a); }
.th-ocean i { background: linear-gradient(135deg, #22b8f0, #2dd4bf); }
.th-blush i { background: linear-gradient(135deg, #ff8fb1, #ffc3a0); }
.th-forest i { background: linear-gradient(135deg, #3fae63, #a3c95a); }
.th-lavender i { background: linear-gradient(135deg, #b18cff, #f5a3e6); }
.th-sand i { background: linear-gradient(135deg, #e8c98f, #c9a978); }

/* the ⋯ menu */
.talk-menu { display: grid; gap: 6px; }
.talk-menu-row {
  display: flex; align-items: center; gap: 12px; width: 100%; border: 0; border-radius: 14px; background: var(--chip); color: var(--fg);
  padding: 11px 14px; text-align: left; font-size: 15px; font-weight: 700; min-height: 48px;
}
.talk-menu-row small { display: block; font-size: 12.5px; font-weight: 600; color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.talk-menu-row > span:last-child { min-width: 0; flex: 1; }
.talk-menu-ico { width: 22px; height: 22px; flex: none; }

/* the message bar: camera, words, sticker, photos, mic (or send) */
.talk-view .chat-bar { position: relative; gap: 6px; padding-left: 10px; padding-right: 10px; }
.talk-view .chat-bar textarea { min-width: 0; }
.talk-cam.talk-small { width: 34px; height: 42px; background: none; }
.talk-cam.talk-small svg { width: 24px; height: 24px; }
.talk-mic {
  width: 42px; height: 42px; border-radius: 50%; border: 0; background: var(--chip); color: var(--fg); display: grid; place-items: center; flex: none;
  padding: 10px; touch-action: none; -webkit-user-select: none; user-select: none; -webkit-touch-callout: none; transition: transform .15s;
}
.talk-mic svg { width: 100%; height: 100%; display: block; }
.talk-mic[hidden], .talk-view .chat-send[hidden] { display: none; }
.chat-bar.recording .talk-mic { background: #f23c57; color: #fff; transform: scale(1.18); }
.talk-chars { text-align: right; font-size: 12px; color: var(--muted); padding: 2px 16px 0; font-variant-numeric: tabular-nums; background: var(--bg); }
.talk-chars.near { color: var(--heart); font-weight: 700; }
.talk-chars[hidden] { display: none; }
.talk-quote.editing { border-left-color: var(--accent); }

/* stickers and big emoji */
.talk-sticker.emoji { font-size: 64px; line-height: 1.15; margin: 2px 0; }
.talk-sticker.word { margin: 4px 0; line-height: 0; }
.talk-text.big { font-size: 46px; line-height: 1.15; letter-spacing: 2px; }
.talk-text.big.n1 { font-size: 60px; }
.talk-text a { color: inherit; text-decoration: underline; text-underline-offset: 2px; overflow-wrap: anywhere; }
.talk-link { display: block; max-width: 320px; margin: 4px 0 2px; padding: 7px 10px; border-radius: 10px; background: var(--chip); color: var(--fg); text-decoration: none; font-size: 13px; }
.talk-link b { display: block; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.talk-link span { color: var(--muted); font-size: 12px; }
.talk-link[hidden] { display: none; }
.talk-edited { border: 0; background: none; color: var(--muted); font-size: 12px; font-weight: 700; padding: 2px 0; text-decoration: underline dotted; min-height: 24px; }
.talk-versions { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.talk-versions li { background: var(--chip); border-radius: 12px; padding: 9px 12px; }
.talk-versions b { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; }
.talk-versions small { color: var(--muted); font-size: 12px; }
.talk-versions p { margin: 4px 0 0; white-space: pre-wrap; overflow-wrap: anywhere; }
.talk-retry { border: 0; background: none; color: var(--send); font-weight: 800; font-size: 12px; margin-left: 8px; padding: 4px 2px; }
.talk-react-pick.more { font-size: 24px; font-weight: 700; color: var(--muted); }

/* a double tap: ❤️ */
.talk-msg { position: relative; }
.talk-heart { position: absolute; right: 12px; top: 50%; font-size: 42px; pointer-events: none; animation: talk-heart .7s ease-out forwards; }
@keyframes talk-heart {
  0% { transform: translateY(-50%) scale(.3); opacity: 0; }
  30% { transform: translateY(-50%) scale(1.25); opacity: 1; }
  100% { transform: translateY(-120%) scale(1); opacity: 0; }
}

/* a call in the log */
.talk-call { display: inline-flex; align-items: center; gap: 8px; background: var(--chip); border-radius: 12px; padding: 7px 8px 7px 11px; margin: 3px 0; font-size: 14px; font-weight: 700; flex-wrap: wrap; }
.talk-call.missed { color: #c8102e; }
.talk-call-ico { width: 18px; height: 18px; display: block; }
.talk-call-ico svg { width: 100%; height: 100%; display: block; }
.talk-call-again { border: 0; background: var(--bg); color: var(--fg); border-radius: 999px; padding: 5px 11px; font-size: 12.5px; font-weight: 800; min-height: 32px; }
@media (prefers-color-scheme: dark) { .talk-call.missed { color: var(--heart); } }

/* ------------------------------------------------------------------ voice notes (voicenotes.js) */
.vn { display: flex; align-items: center; gap: 8px; width: min(100%, 300px); background: var(--chip); border-radius: 18px; padding: 6px 8px 6px 6px; margin: 3px 0; }
.vn-play { width: 36px; height: 36px; border-radius: 50%; border: 0; background: #0a7fc0; color: #fff; display: grid; place-items: center; padding: 10px; flex: none; }
.vn.me .vn-play { background: #d42a45; }
.vn-play svg { width: 100%; height: 100%; display: block; }
.vn-wave { flex: 1; min-width: 0; height: 34px; display: flex; align-items: center; gap: 2px; cursor: pointer; touch-action: none; border-radius: 6px; }
.vn-wave i { flex: 1; min-width: 2px; border-radius: 2px; background: color-mix(in srgb, var(--muted) 55%, transparent); }
.vn-wave i.on { background: #0eadff; }
.vn.me .vn-wave i.on { background: #f23c57; }
.vn-wave:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.vn-time { font-size: 12px; font-weight: 700; color: var(--muted); font-variant-numeric: tabular-nums; min-width: 32px; text-align: right; }
.vn-speed { border: 0; background: var(--bg); color: var(--fg); border-radius: 999px; font-size: 12px; font-weight: 800; padding: 0 8px; height: 28px; min-width: 40px; position: relative; }
.vn-speed::after { content: ""; position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; transform: translate(-50%, -50%); }
.vn.loading .vn-play { opacity: .5; }

/* recording: the strip over the message bar */
.vn-rec {
  position: absolute; inset: 0 60px 0 0; z-index: 3; display: flex; align-items: center; gap: 10px; padding: 0 10px var(--safe-b) 12px;
  background: var(--bg); transform: translateX(var(--slide, 0)); font-weight: 700;
}
.vn-rec[hidden], .vn-lock[hidden] { display: none; }
.vn-dot { width: 10px; height: 10px; border-radius: 50%; background: #f23c57; animation: vn-blink 1s infinite; flex: none; }
@keyframes vn-blink { 50% { opacity: .25; } }
.vn-rec-time { font-variant-numeric: tabular-nums; min-width: 38px; }
.vn-live { flex: 1; min-width: 0; height: 28px; display: flex; align-items: center; gap: 2px; overflow: hidden; justify-content: flex-end; }
.vn-live i { width: 2px; flex: none; border-radius: 2px; background: #f23c57; }
.vn-hint { color: var(--muted); font-size: 13px; white-space: nowrap; }
.vn-cancel, .vn-send { display: none; width: 44px; height: 44px; border-radius: 50%; border: 0; place-items: center; padding: 10px; flex: none; }
.vn-cancel { background: var(--chip); color: var(--fg); }
.vn-send { background: #0eadff; color: #fff; }
.vn-cancel svg, .vn-send svg { width: 100%; height: 100%; display: block; }
.vn-rec.locked { inset: 0; padding-right: 10px; }
.vn-rec.locked .vn-cancel, .vn-rec.locked .vn-send { display: grid; }
.vn-rec.locked .vn-hint { display: none; }
.vn-lock {
  position: absolute; right: 11px; bottom: calc(100% + 8px); z-index: 3; width: 44px; padding: 8px 0; border-radius: 22px; background: var(--chip);
  display: grid; justify-items: center; gap: 2px; box-shadow: 0 4px 14px rgba(0,0,0,.18); font-size: 15px; animation: talk-pop .2s ease-out;
}
.vn-lock i { font-style: normal; color: var(--muted); font-weight: 800; animation: vn-up 1.2s infinite; }
@keyframes vn-up { 50% { transform: translateY(-4px); } }

/* ------------------------------------------------------------------ live location (chat-live.js) */
.lv-card { display: block; width: min(100%, 260px); background: var(--chip); border-radius: 16px; overflow: hidden; margin: 4px 0; }
.lv-card.live { box-shadow: 0 0 0 2px #1fbf6a inset; }
.lv-map { position: relative; overflow: hidden; background: #dde3e8; max-width: 100%; }
.lv-tile { position: absolute; width: 256px; height: 256px; max-width: none; user-select: none; }
.lv-map-wait { position: absolute; inset: 0; display: grid; place-items: center; color: #555; font-size: 13px; }
.lv-pin {
  position: absolute; width: 32px; height: 32px; margin: -38px 0 0 -16px; border-radius: 50% 50% 50% 0; transform: rotate(-45deg);
  background: #0eadff; border: 2px solid #fff; box-shadow: 0 2px 6px rgba(0,0,0,.35); display: grid; place-items: center;
}
.lv-pin.me { background: #f23c57; }
.lv-pin b { transform: rotate(45deg); color: #fff; font-size: 13px; }
.lv-card.live .lv-pin::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid #1fbf6a; animation: lv-pulse 1.8s infinite; }
@keyframes lv-pulse { from { transform: scale(.6); opacity: .9; } to { transform: scale(1.4); opacity: 0; } }
.lv-credit { position: absolute; right: 4px; bottom: 2px; font-size: 9px; color: #333; background: rgba(255,255,255,.75); padding: 0 3px; border-radius: 3px; }
.lv-info { padding: 8px 11px 4px; }
.lv-info b { display: block; font-size: 14px; }
.lv-info span { display: block; font-size: 12.5px; color: var(--muted); }
.lv-actions { display: flex; gap: 8px; padding: 4px 10px 10px; flex-wrap: wrap; }
.lv-open, .lv-stop { border: 0; border-radius: 999px; padding: 7px 12px; font-size: 13px; font-weight: 800; text-decoration: none; min-height: 36px; display: inline-flex; align-items: center; }
.lv-open { background: var(--bg); color: var(--fg); }
.lv-stop { background: #d42a45; color: #fff; }

@media (prefers-reduced-motion: reduce) {
  .talk-typing i, .vn-dot, .vn-lock i, .lv-card.live .lv-pin::after, .talk-heart, .talk-presence { animation: none; }
}
