/* ─── APP SHELL ──────────────────────────────── */
.app-shell {
  display: flex;
  width: 100%;
  height: 100vh;
  height: 100dvh;
  max-width: 900px;
  margin: 0 auto;
  background: var(--bg-app);
  overflow: hidden;
  position: relative;
}

/* ─── SIDEBAR (redesign: Companion List) ─────── */
.sidebar {
  width: var(--sidebar-w);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  border-right: 1px solid var(--border);
  height: 100%;
}

.sidebar-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 16px 10px 22px;
  padding-top: calc(10px + env(safe-area-inset-top));
}

.sidebar-title {
  font-family: var(--font-display);
  font-size: 27px;
  font-weight: 700;
  letter-spacing: -0.025em;
  color: var(--text);
}

.sidebar-edit-btn {
  background: var(--accent);
  border: none;
  border-radius: 50%;
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  color: var(--on-accent); cursor: pointer;
  transition: filter 0.15s, transform 0.12s;
}
.sidebar-edit-btn:hover { filter: brightness(1.08); }
.sidebar-edit-btn:active { transform: scale(0.94); }

.sidebar-search-wrap { padding: 0 16px 10px; }

.sidebar-search {
  width: 100%;
  background: var(--surface-2);
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 11px 14px;
  color: var(--text);
  font-size: 14.5px;
  outline: none;
  transition: border-color 0.15s;
}
.sidebar-search:focus { border-color: var(--accent); }
.sidebar-search::placeholder { color: var(--text-3); }

/* ─── SEGMENT TABS ───────────────────────────── */
.segment-tabs { display: flex; gap: 6px; padding: 0 16px 10px; overflow-x: auto; scrollbar-width: none; }
.segment-tabs::-webkit-scrollbar { display: none; }
.segment-tab { flex-shrink: 0; border: 1px solid var(--border); background: var(--surface); color: var(--text-3); font-size: 12px; font-weight: 600; padding: 5px 12px; border-radius: 999px; cursor: pointer; transition: background 0.15s, color 0.15s, border-color 0.15s; white-space: nowrap; }
.segment-tab:hover { background: var(--surface-2); color: var(--text); }
.segment-tab.active { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.companions-empty { padding: 28px 16px; text-align: center; font-size: 13px; color: var(--text-3); }

.companions-list { flex: 1; overflow-y: auto; padding: 0 8px; }
.companions-list::-webkit-scrollbar { width: 3px; }
.companions-list::-webkit-scrollbar-thumb { background: var(--border-2); border-radius: 10px; }

.companion-item {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 11px 12px;
  cursor: pointer;
  border-radius: var(--radius);
  transition: background 0.15s;
}
.companion-item:hover { background: var(--surface-2); }
.companion-item.active { background: var(--accent-soft); }

/* .companion-avatar defined in profile-modal.css (with story ring system) */

.companion-info { flex: 1; min-width: 0; }
.companion-row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.companion-name-group { display: flex; align-items: center; gap: 5px; min-width: 0; flex: 1; }
.companion-name { font-weight: 600; font-size: 15.5px; letter-spacing: -0.01em; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.companion-time { font-size: 12px; color: var(--text-3); flex-shrink: 0; font-variant-numeric: tabular-nums; }
.companion-bottom { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-top: 3px; }
.companion-preview { flex: 1; min-width: 0; font-size: 13.5px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.row-rel { flex-shrink: 0; font-size: 11px; font-weight: 600; color: var(--accent-ink); background: var(--accent-soft); padding: 2px 8px; border-radius: 999px; }
.companion-default-badge { font-size: 10px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase; color: var(--text-3); background: var(--surface-2); border: 1px solid var(--border); padding: 1px 6px; border-radius: 999px; margin-left: 5px; flex-shrink: 0; }
.unread-badge { flex-shrink: 0; min-width: 19px; height: 19px; padding: 0 6px; border-radius: 999px; background: var(--accent); color: var(--on-accent); font-size: 11px; font-weight: 700; line-height: 19px; text-align: center; font-variant-numeric: tabular-nums; }
.companion-item.has-unread .companion-name { font-weight: 700; }
.companion-item.has-unread .companion-preview { color: var(--text); font-weight: 600; }

/* ─── PROACTIVE TOGGLE (profile → Messages) ──── */
.proactive-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 4px 0 2px; }
.proactive-label { display: flex; flex-direction: column; gap: 2px; }
.proactive-label span { font-size: 14px; color: var(--text); font-weight: 600; }
.proactive-label small { font-size: 11.5px; color: var(--text-3); }
.proactive-toggle { flex-shrink: 0; width: 46px; height: 27px; border-radius: 999px; border: none; background: var(--surface-2); position: relative; cursor: pointer; transition: background 0.18s; padding: 0; }
.proactive-toggle .proactive-knob { position: absolute; top: 3px; left: 3px; width: 21px; height: 21px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.3); transition: transform 0.18s; }
.proactive-toggle.on { background: var(--accent); }
.proactive-toggle.on .proactive-knob { transform: translateX(19px); }

/* ─── CHAT PANEL ─────────────────────────────── */
.chat-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  height: 100%;
}

/* ─── TOPBAR (redesign: chat-top) ────────────── */
.topbar {
  position: relative; z-index: 10;
  padding: 8px 12px 11px;
  padding-top: calc(8px + env(safe-area-inset-top));
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
  gap: 10px;
}

.back-to-sidebar { display: none; background: none; border: none; color: var(--text-2); cursor: pointer; width: 32px; height: 32px; align-items: center; justify-content: center; }

.status { display: flex; align-items: center; gap: 10px; flex: 1; }

/* ─── STORY RING (Snapchat/TikTok avatar border) ─ */
.avatar-story-ring {
  width: 46px; height: 46px;
  border-radius: 50%;
  padding: 2.5px;
  background: var(--story-ring);
  flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.4s;
}
.avatar {
  width: 100%; height: 100%;
  background: linear-gradient(135deg, var(--blue), #0055cc);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  outline: 2px solid #0a0a0f;
  outline-offset: -1px;
}
.avatar-emoji { font-size: 18px; }

/* ─── TOPBAR NAME + STREAK ROW ───────────────── */
.name-streak-row { display: flex; align-items: center; gap: 7px; }
.status-info .name { font-weight: 600; font-size: 16px; letter-spacing: -0.01em; color: var(--text); }
.ct-bond { font-size: 10.5px; font-weight: 700; color: var(--accent-ink); background: var(--accent-soft); padding: 1.5px 7px; border-radius: 999px; letter-spacing: 0.01em; white-space: nowrap; }
.ct-bond:empty { display: none; }
.topbar-streak {
  font-size: 11px; font-weight: 800;
  color: #FF9F0A;
  background: rgba(255,159,10,0.15);
  border: 1px solid rgba(255,159,10,0.3);
  padding: 1px 7px;
  border-radius: 10px;
  letter-spacing: 0.02em;
  display: none;
}
.topbar-streak.visible { display: inline-block; }

.online { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--text-2); }
.dot { width: 6px; height: 6px; background: var(--presence); border-radius: 50%; }
.topbar-actions { display: flex; gap: 2px; align-items: center; }
.topbar-coins { display: flex; align-items: center; gap: 3px; font-size: 12px; font-weight: 700; color: #f5c518; padding: 3px 8px; border-radius: 20px; background: rgba(245,197,24,0.12); margin-right: 2px; cursor: default; user-select: none; }

/* ─── ICON BUTTONS (redesign: iconbtn) ───────── */
.icon-btn { background: transparent; border: 1px solid transparent; color: var(--text-2); width: 38px; height: 38px; border-radius: 50%; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.15s; flex-shrink: 0; }
.icon-btn:hover { background: var(--surface-2); color: var(--text); }
.icon-btn:active { transform: scale(0.93); }
.icon-btn.recording { background: rgba(255,45,85,0.2); border-color: rgba(255,45,85,0.5); color: #ff2d55; animation: pulseRec 0.8s infinite; }
@keyframes pulseRec { 0%,100%{box-shadow:0 0 0 0 rgba(255,45,85,0.4)} 50%{box-shadow:0 0 0 8px rgba(255,45,85,0)} }

/* ─── CHAT ───────────────────────────────────── */
.chat { flex: 1; padding: 14px 14px 8px; overflow-y: scroll; -webkit-overflow-scrolling: touch; display: flex; flex-direction: column; gap: 6px; scroll-behavior: smooth; }
.chat::-webkit-scrollbar { width: 3px; }
.chat::-webkit-scrollbar-thumb { background: rgba(255,255,255,0.08); border-radius: 10px; }

/* ─── MESSAGES (redesign: .b bubbles) ────────── */
.msg { max-width: 78%; border-radius: var(--bubble); font-size: 14.5px; line-height: 1.45; animation: msgIn 0.3s cubic-bezier(0.22,1,0.36,1) forwards; word-break: break-word; position: relative; }
@keyframes msgIn { from{opacity:0;transform:translateY(7px)} to{opacity:1;transform:translateY(0)} }
.msg-text-inner { padding: 10px 14px; }
.msg.user { align-self: flex-end; background: var(--accent); color: var(--on-accent); border-bottom-right-radius: var(--bubble-tail); }
.msg.ai { align-self: flex-start; background: var(--surface); color: var(--text); border: 1px solid var(--border); border-bottom-left-radius: var(--bubble-tail); box-shadow: var(--shadow-card); width: fit-content; max-width: 78%; }
.msg.ai.msg-emoji-react { background: none!important; border: none!important; box-shadow: none!important; font-size: 30px; padding: 0!important; }
.msg.user + .msg.ai, .msg.ai + .msg.user { margin-top: 8px; }
.msg-row.user + .msg-row.ai, .msg-row.ai + .msg-row.user { margin-top: 8px; }
.msg-image { background: transparent!important; border: none!important; padding: 0!important; }
.msg-image img { border-radius: 16px; display: block; box-shadow: 0 4px 18px rgba(0,0,0,0.4); }
.gif-media-wrap { position: relative; display: inline-block; flex-shrink: 0; }
.gif-credit-watermark {
  position: absolute;
  right: 8px;
  bottom: 8px;
  padding: 2px 6px;
  border-radius: 999px;
  background: rgba(0,0,0,0.58);
  color: rgba(255,255,255,0.86);
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.02em;
  pointer-events: none;
}

/* ─── VOICE ──────────────────────────────────── */
.msg-voice-wrap { display: inline-block; max-width: 100%; }
.msg-voice { display: flex; align-items: center; gap: 10px; min-width: 190px; padding: 10px 14px; }
.msg.user, .msg.ai { padding: 0; }
.msg.user .msg-voice { background: var(--accent); border-radius: var(--bubble); border-bottom-right-radius: var(--bubble-tail); }
.msg.ai .msg-voice { background: var(--surface); border: 1px solid var(--border); border-radius: var(--bubble); border-bottom-left-radius: var(--bubble-tail); box-shadow: var(--shadow-card); }
.voice-play { width: 34px; height: 34px; background: color-mix(in srgb, var(--on-accent) 26%, transparent); border-radius: 50%; display: flex; align-items: center; justify-content: center; cursor: pointer; border: none; color: var(--on-accent); flex-shrink: 0; transition: transform 0.15s; }
.msg.ai .voice-play { background: var(--accent); color: var(--on-accent); }
.voice-play svg { width: 13px; height: 13px; fill: currentColor; margin-left: 2px; }
.voice-play:hover { transform: scale(1.1); }
.voice-play.loading { pointer-events: none; opacity: 0.6; animation: voice-spin 0.8s linear infinite; }
@keyframes voice-spin { to { transform: rotate(360deg); } }
.voice-waves { display: flex; gap: 3px; align-items: center; height: 22px; flex: 1; }
.wave-bar { width: 3px; height: 6px; background: color-mix(in srgb, var(--on-accent) 35%, transparent); border-radius: 2px; transition: height 0.1s; }
.wave-bar.active { height: 18px; background: var(--on-accent); }
.msg.ai .wave-bar { background: var(--border-2); }
.msg.ai .wave-bar.active { background: var(--accent); }
.voice-duration { font-size: 11.5px; color: color-mix(in srgb, var(--on-accent) 70%, transparent); font-variant-numeric: tabular-nums; white-space: nowrap; flex-shrink: 0; }
.msg.ai .voice-duration { color: var(--text-3); }
.voice-text { display: none !important; } /* data-only span — never shown inline; transcript shows via .voice-transcript on Aa click */
.voice-transcript-btn { background: none; border: none; color: var(--text-3); font-size: 12px; font-weight: 600; cursor: pointer; padding: 2px 4px; border-radius: 4px; }
.voice-transcript-btn.active, .voice-transcript-btn:hover { color: var(--accent); }
.voice-mp3-btn { background: none; border: none; color: var(--text-3); cursor: pointer; padding: 2px 4px; border-radius: 4px; display: flex; align-items: center; }
.voice-mp3-btn:hover { color: var(--accent); }
.voice-mp3-btn:disabled { opacity: 0.5; cursor: default; }
.voice-transcript { padding: 6px 14px; font-size: 13px; color: var(--text-2); line-height: 1.5; font-style: normal; border-left: none; box-sizing: border-box; }
.voice-transcript .translate-content { font-style: normal; border-left: none; }

/* ─── INPUT BAR (redesign: composer) ─────────── */
.inputbar { z-index: 10; display: flex; align-items: center; gap: 7px; padding: 10px 14px; padding-bottom: calc(16px + env(safe-area-inset-bottom)); background: var(--bg); border-top: 1px solid var(--border); }
.input-icon { width: 38px; height: 38px; color: var(--text-2); background: transparent; border: none; }
.input-icon:hover { background: var(--surface-2); color: var(--text); border-color: transparent; }
.gif-btn { color: var(--accent-ink)!important; }
#input { flex: 1; height: 40px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--border); outline: none; background: var(--surface-2); color: var(--text); font-size: 14.5px; font-family: inherit; transition: all 0.2s; min-width: 0; }
#input::placeholder { color: var(--text-3); }
#input:focus { border-color: var(--accent); }
.send-btn { width: 40px; height: 40px; border-radius: 50%; border: none; background: var(--accent); color: var(--on-accent); cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.15s; flex-shrink: 0; box-shadow: var(--shadow-card); }
.send-btn:hover { filter: brightness(1.08); transform: scale(1.06); }
.send-btn svg { fill: currentColor; }

/* ─── GIF PICKER ─────────────────────────────── */
.gif-picker { display: none; flex-direction: column; background: var(--surface); border-top: 1px solid var(--border); height: 260px; }
.gif-picker.active { display: flex; }
.gif-picker-tabs { display: flex; border-bottom: 1px solid var(--border); }
.gif-tab { flex: 1; padding: 9px 8px; background: none; border: none; border-bottom: 2px solid transparent; color: var(--text-2); font-size: 13px; font-weight: 500; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 5px; transition: all 0.15s; }
.gif-tab svg { opacity: 0.6; }
.gif-tab.active { color: var(--accent-ink); border-bottom-color: var(--accent); }
.gif-tab.active svg { opacity: 1; }
.gif-picker-header { padding: 7px 10px; border-bottom: 1px solid var(--border); }
.gif-search-input { width: 100%; background: var(--surface-2); border: 1px solid var(--border); border-radius: 999px; padding: 8px 14px; color: var(--text); font-size: 14px; outline: none; }
.gif-search-input:focus { border-color: var(--accent); }
.gif-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 3px; padding: 6px; overflow-y: auto; flex: 1; }
.gif-thumb { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: 8px; cursor: pointer; transition: transform 0.15s; }
.gif-thumb:hover { transform: scale(1.04); }
.gif-loading { grid-column: 1/-1; text-align: center; color: var(--text-muted); padding: 20px; font-size: 14px; }
.gif-delete-btn { position: absolute; top: 3px; right: 3px; background: rgba(0,0,0,0.6); border: none; border-radius: 50%; width: 20px; height: 20px; font-size: 10px; color: #fff; cursor: pointer; display: flex; align-items: center; justify-content: center; }

/* ─── TIKTOK ACTIONS ─────────────────────────── */
.gif-actions-tiktok { display: flex; flex-direction: column; gap: 8px; align-items: center; padding: 4px 2px; justify-content: flex-end; opacity: 0; transition: opacity 0.15s; pointer-events: none; }
.gif-msg-wrap:hover .gif-actions-tiktok { opacity: 1; pointer-events: auto; }
.tik-btn { display: flex; flex-direction: column; align-items: center; background: none; border: none; cursor: pointer; padding: 0; transition: transform 0.15s; position: relative; }
.tik-btn:active { transform: scale(0.9); }
.tik-icon { width: 28px; height: 28px; background: rgba(255,255,255,0.1); backdrop-filter: blur(8px); border: 1px solid rgba(255,255,255,0.15); border-radius: 50%; display: flex; align-items: center; justify-content: center; transition: all 0.2s; }
.tik-icon svg { transition: transform 0.2s; color: rgba(255,255,255,0.85); }
.tik-btn:hover .tik-icon { background: rgba(255,255,255,0.18); }
.tik-btn.liked .tik-icon { background: rgba(255,45,85,0.2); border-color: rgba(255,45,85,0.4); }
.tik-label { display: none; }
.tik-btn::after { content: attr(title); position: absolute; right: calc(100% + 6px); top: 50%; transform: translateY(-50%); background: rgba(0,0,0,0.75); color: #fff; font-size: 11px; padding: 3px 7px; border-radius: 6px; white-space: nowrap; opacity: 0; pointer-events: none; transition: opacity 0.2s; transition-delay: 0.6s; }
.tik-btn:hover::after { opacity: 1; }

/* ─── REPLY ──────────────────────────────────── */
.reply-bar { display: none; align-items: center; gap: 8px; padding: 7px 14px; background: var(--accent-soft); border-top: 1px solid var(--border); font-size: 13px; }
.reply-bar.active { display: flex; }
.reply-bar-text { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--accent-ink); }
.reply-bar-cancel { background: none; border: none; color: var(--text-2); cursor: pointer; font-size: 17px; padding: 0 3px; }
.reply-quote { border-left: 3px solid var(--border-2); padding: 4px 8px; margin-bottom: 6px; border-radius: 4px; font-size: 12px; color: var(--text-2); background: var(--surface-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.msg.user .reply-quote { border-left-color: color-mix(in srgb, var(--on-accent) 55%, transparent); color: color-mix(in srgb, var(--on-accent) 80%, transparent); background: color-mix(in srgb, var(--on-accent) 12%, transparent); }

/* ─── MSG ROW / ACTIONS ──────────────────────── */
.msg-row { display: flex; align-items: flex-end; gap: 4px; width: 100%; position: relative; min-height: fit-content; }
.msg-row.user { flex-direction: row-reverse; }
/* width:0 + overflow:hidden keeps the hidden toolbar out of the row's flex
   sizing entirely — otherwise even at opacity:0 it still reserves real space
   as a flex sibling, pushing whatever comes after it (the bubble's own
   timestamp, or the bubble itself on a reversed user row) away from where it
   belongs. It only needs to occupy space once actually visible on hover. */
.msg-actions { opacity: 0; display: flex; gap: 3px; align-self: center; transition: opacity 0.15s; pointer-events: none; width: 0; overflow: hidden; }
.msg-row:hover .msg-actions { opacity: 1; pointer-events: auto; width: auto; overflow: visible; }
.msg-action-btn { background: var(--surface-2); border: none; border-radius: 50%; width: 26px; height: 26px; display: flex; align-items: center; justify-content: center; cursor: pointer; font-size: 12px; color: var(--text-3); transition: background 0.15s; }
.msg-action-btn:hover { background: var(--accent-soft); color: var(--accent-ink); }

/* ─── TIMESTAMPS & DAY DIVIDERS ──────────────── */
.msg-time { font-size: 10px; color: var(--text-3); align-self: flex-end; padding-bottom: 3px; flex-shrink: 0; white-space: nowrap; opacity: 0.75; }
.day-divider { display: flex; align-items: center; justify-content: center; width: 100%; margin: 14px 0 6px; }
.day-divider span { font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--text-3); background: var(--surface-2); border: 1px solid var(--border); padding: 3px 12px; border-radius: 999px; }

/* ─── REACTIONS ──────────────────────────────── */
.reactions { position: absolute; bottom: -24px; left: 0; display: flex; flex-wrap: wrap; gap: 4px; max-width: 200px; z-index: 10; }
.reaction-bubble { background: var(--surface); border: 1px solid var(--border); border-radius: 999px; padding: 2px 8px; font-size: 13px; cursor: pointer; display: flex; align-items: center; gap: 3px; box-shadow: var(--shadow-card); transition: all 0.15s; }
.reaction-bubble:hover { background: var(--accent-soft); transform: scale(1.1); }
.reaction-count { font-size: 11px; color: var(--text-3); }
.reaction-pop { animation: reactPop 0.3s cubic-bezier(0.34,1.56,0.64,1); }
@keyframes reactPop { 0%{transform:scale(0.5)} 100%{transform:scale(1)} }
.reaction-picker { position: absolute; background: var(--elev); border: 1px solid var(--border); border-radius: 28px; padding: 6px 10px; display: flex; gap: 6px; box-shadow: var(--shadow-pop); z-index: 100; bottom: 36px; animation: msgIn 0.2s cubic-bezier(0.34,1.56,0.64,1); }
.reaction-option { background: none; border: none; font-size: 22px; cursor: pointer; transition: transform 0.15s; line-height: 1; }
.reaction-option:hover { transform: scale(1.4) translateY(-4px); }

/* ─── EMOJI BAR ──────────────────────────────── */
.emoji-bar { display: none; overflow-x: auto; padding: 6px 10px; background: var(--bg); border-top: 1px solid var(--border); scrollbar-width: none; gap: 3px; }
.emoji-bar.active { display: flex; }
.emoji-bar::-webkit-scrollbar { display: none; }
.emoji-pill { flex-shrink: 0; background: transparent; border: 1px solid transparent; border-radius: 10px; font-size: 21px; width: 38px; height: 38px; cursor: pointer; display: flex; align-items: center; justify-content: center; transition: transform 0.12s, background 0.12s; padding: 0; }
.emoji-pill:hover { background: var(--surface-2); transform: scale(1.25); }
.emoji-pill:active { transform: scale(0.9); }

/* ─── ATTACHMENT PREVIEW BAR ─────────────────── */
.attach-bar { display: none; align-items: center; gap: 8px; padding: 8px 14px; background: var(--accent-soft); border-top: 1px solid var(--border); font-size: 13px; }
.attach-bar.active { display: flex; }
.attach-bar-icon { font-size: 16px; flex-shrink: 0; }
.attach-bar-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; color: var(--accent-ink); }
.attach-bar-remove { background: none; border: none; color: var(--text-2); cursor: pointer; font-size: 17px; padding: 0 3px; line-height: 1; }

/* ─── PRIVACY & DATA SCREEN ──────────────────── */
.priv-section { margin-bottom: 20px; }
.priv-section-title { display: flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-3); margin-bottom: 10px; }
.priv-stat-row { display: flex; gap: 12px; justify-content: center; margin-bottom: 4px; }
.priv-stat { flex: 1; background: var(--surface-2); border-radius: 14px; padding: 14px 8px; text-align: center; }
.priv-stat .priv-stat-num { display: block; font-size: 26px; font-weight: 800; color: var(--text); letter-spacing: -0.03em; }
.priv-stat label { font-size: 11px; color: var(--text-3); font-weight: 600; }
.priv-note { font-size: 12px; color: var(--text-3); line-height: 1.55; margin: 6px 0 10px; }
.priv-facts-list { display: flex; flex-direction: column; gap: 6px; }
.priv-fact-row { display: flex; align-items: center; gap: 8px; background: var(--surface-2); border-radius: 10px; padding: 9px 12px; }
.priv-fact-text { flex: 1; font-size: 13.5px; color: var(--text); }
.priv-fact-del { background: none; border: none; color: var(--text-3); cursor: pointer; font-size: 15px; padding: 0 2px; line-height: 1; flex-shrink: 0; transition: color 0.15s; }
.priv-fact-del:hover { color: #ff6b6b; }
.priv-empty { font-size: 13px; color: var(--text-3); padding: 10px 0; text-align: center; }
.priv-bullet-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.priv-bullet-list li { font-size: 13px; color: var(--text-2); line-height: 1.5; padding-left: 18px; position: relative; }
.priv-bullet-list li::before { content: '✓'; position: absolute; left: 0; color: var(--accent-ink); font-weight: 700; }
.priv-delete-btn { width: 100%; padding: 13px; background: rgba(255,59,48,0.1); color: #ff6b6b; border: 1px solid rgba(255,59,48,0.25); border-radius: 12px; font-size: 15px; font-weight: 700; cursor: pointer; transition: background 0.15s; margin-bottom: 8px; }
.priv-delete-btn:hover { background: rgba(255,59,48,0.18); }

/* ─── TYPING ─────────────────────────────────── */
.typing-indicator { display: flex; align-items: center; gap: 5px; padding: 12px 15px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--bubble); border-bottom-left-radius: var(--bubble-tail); box-shadow: var(--shadow-card); width: fit-content; animation: msgIn 0.22s forwards; margin: 4px 0; }
.typing-dot { width: 7px; height: 7px; background: var(--text-3); border-radius: 50%; animation: typingBounce 1.2s infinite; }
.typing-dot:nth-child(2) { animation-delay: 0.2s; }
.typing-dot:nth-child(3) { animation-delay: 0.4s; }
@keyframes typingBounce { 0%,60%,100%{transform:translateY(0);opacity:0.4} 30%{transform:translateY(-6px);opacity:1} }
