/* Tin nhắn dạng danh sách chat (0.10.0, chủ đề 6), dùng chung web app và plugin. Bản giống hệt ở ui/ và xuong/.
   Màu lấy theo biến của trang, có màu dự phòng. Viết cho Chromium cũ của SketchUp 2021: không dùng flex gap, :has. */
.hpanel > .tn, .tnhost > .tn { flex: 1; }
.tn { display: flex; height: 100%; min-height: 0; background: var(--surface, #fff); color: var(--ink, #0F172A); font-size: 13.5px; }
.tn-side { width: 320px; max-width: 100%; flex: none; display: flex; flex-direction: column; min-height: 0; border-right: 1px solid var(--line, #E2E8F0); }
.tn-main { flex: 1; min-width: 0; display: flex; flex-direction: column; min-height: 0; }
.tn.narrow .tn-side { width: 100%; border-right: 0; }
.tn.narrow.open .tn-side { display: none; }
.tn.narrow:not(.open) .tn-main { display: none; }
.tn-top { display: flex; align-items: center; padding: 8px 10px; border-bottom: 1px solid var(--line, #E2E8F0); }
.tn-top input { flex: 1; min-width: 0; padding: 7px 12px; border: 1px solid var(--pill, #CBD5E1); border-radius: 999px; background: var(--surface, #fff); color: inherit; font-size: 13px; }
.tn-ib { flex: none; width: 32px; height: 32px; margin-left: 4px; border: 0; border-radius: 50%; background: none; color: var(--muted, #5B6B7F); font-size: 16px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.tn-ib:hover { background: var(--surface-2, #F8FAFC); }
.tn-ib.on { color: var(--accent, #1A9BE6); }
.tn-ib svg { width: 18px; height: 18px; }
.tn-chips { display: flex; padding: 6px 10px; border-bottom: 1px solid var(--line, #E2E8F0); }
.tn-chips button { margin-right: 6px; padding: 4px 12px; border: 1px solid var(--pill, #CBD5E1); border-radius: 999px; background: none; color: var(--ink, #0F172A); font-size: 12.5px; cursor: pointer; }
.tn-chips button.on { background: var(--accent-soft, #E0F2FE); border-color: var(--accent, #1A9BE6); color: #0369A1; font-weight: 600; }
.tn-list { flex: 1; min-height: 0; overflow: auto; }
.tn-row { position: relative; display: flex; align-items: center; width: 100%; padding: 9px 10px; border: 0; border-bottom: 1px solid var(--line, #E2E8F0); background: none; color: inherit; text-align: left; cursor: pointer; }
.tn-row:hover { background: var(--surface-2, #F8FAFC); }
.tn-row.sel { background: var(--accent-soft, #E0F2FE); }
.tn-row > .tn-mid { flex: 1; min-width: 0; margin: 0 8px 0 10px; }
.tn-row b, .tn-row small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tn-row small { color: var(--muted, #5B6B7F); font-size: 12px; margin-top: 2px; }
.tn-row.unread b, .tn-row.unread small { color: var(--ink, #0F172A); font-weight: 700; }
.tn-rt { flex: none; display: flex; flex-direction: column; align-items: flex-end; font-size: 11px; color: var(--muted, #5B6B7F); }
.tn-rt i { font-style: normal; }
.tn-bd { display: inline-block; min-width: 18px; height: 18px; margin-top: 4px; padding: 0 5px; border-radius: 999px; background: #DC2626; color: #fff; font-size: 10.5px; line-height: 18px; text-align: center; font-weight: 700; }
.tn-bd.mute { background: #a8a8a8; }
/* Chủ đề 20: ô số tấm nền trắng viền xám, số đỏ; chấm nhóm xanh rêu (bảng thiết kế). */
.tn-n { flex: none; position: relative; width: 38px; height: 38px; border: 1px solid var(--line, #E2E8F0); border-radius: 10px; background: var(--surface, #fff); color: #DC2626; font-weight: 700; font-size: 13px; display: inline-flex; align-items: center; justify-content: center; }
.tn-n s { position: absolute; right: -4px; bottom: -4px; width: 17px; height: 17px; border: 2px solid var(--surface, #fff); border-radius: 50%; background: var(--accent, #1A9BE6); color: #fff; text-decoration: none; display: inline-flex; align-items: center; justify-content: center; }
.tn-n s svg { width: 9px; height: 9px; }
.tn-tag { display: inline-block; margin-left: 4px; padding: 0 8px; border-radius: 999px; font-size: 10.5px; font-weight: 600; line-height: 18px; vertical-align: 1px; }
.tn-tag.loi { background: #FEE2E2; color: #DC2626; }
.tn-rt i svg { width: 12px; height: 12px; margin-right: 3px; vertical-align: -2px; }
.tn-tag.xuong { background: var(--accent-soft, #E0F2FE); color: var(--accent, #1A9BE6); }
.tn-tag.het { background: var(--surface-2, #F8FAFC); color: var(--muted, #5B6B7F); }
.tn-more { position: absolute; right: 6px; top: 8px; display: none; }
.tn-row:hover .tn-more, .tn-row:focus-within .tn-more { display: inline-flex; }
.tn.narrow .tn-more { display: inline-flex; }
.tn-menu { position: fixed; z-index: 65; min-width: 190px; padding: 6px; background: var(--surface, #fff); border: 1px solid var(--pill, #CBD5E1); border-radius: 12px; box-shadow: 0 10px 26px rgba(0, 0, 0, .18); }
.tn-menu button { display: block; width: 100%; padding: 8px 10px; border: 0; border-radius: 8px; background: none; color: var(--ink, #0F172A); text-align: left; font-size: 13px; cursor: pointer; }
.tn-menu button:hover { background: var(--surface-2, #F8FAFC); }
.tn-empty { padding: 30px 16px; color: var(--muted, #5B6B7F); text-align: center; font-size: 13px; }
.tn-head { display: flex; align-items: center; padding: 8px 10px; border-bottom: 1px solid var(--line, #E2E8F0); min-height: 52px; }
.tn-head .tn-mid { flex: 1; min-width: 0; margin-left: 10px; cursor: pointer; }
.tn-head b, .tn-head small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tn-head small { color: var(--muted, #5B6B7F); font-size: 12px; }
.tn-back { display: none; }
.tn.narrow .tn-back { display: inline-flex; }
.tn-body { flex: 1; min-height: 0; }
.tn-card { align-self: stretch; margin: 2px 0 8px; padding: 10px 12px; border: 1px solid var(--line, #E2E8F0); border-radius: 12px; background: var(--surface, #fff); box-shadow: 0 1px 3px rgba(15, 23, 42, 0.06); }
.tn-card .tn-cl { display: flex; align-items: center; }
.tn-card .tn-cl > div { margin-left: 10px; min-width: 0; }
.tn-card p { margin: 8px 0 0; color: var(--muted, #5B6B7F); font-size: 12px; }
.tn-card .tk-btn { margin-top: 8px; }
.tn-model { min-width: 220px; }
.tn-model b { display: block; }
.tn-model small { display: block; color: #5B6B7F; font-size: 12px; margin-top: 2px; }
.tn-model .tn-mb { margin-top: 8px; }
.tn-model .tn-mb button { margin-right: 6px; padding: 5px 12px; border: 1px solid #CBD5E1; border-radius: 999px; background: #FFFFFF; color: #0F172A; font-size: 12.5px; cursor: pointer; }
.tn-model .tn-mb button.pri { background: #1A9BE6; border-color: #1A9BE6; color: #FFFFFF; }
.tn-model b svg { width: 16px; height: 16px; margin-right: 5px; vertical-align: -3px; }
.tn-model .tn-dead { display: inline-block; margin-top: 6px; color: #5B6B7F; font-size: 12px; }
/* Chủ đề 21: dấu @ (có người trả lời tin của mình). Chủ đề 19: dòng và màn "Tin nhắn từ người lạ", ô Trả lời / Chặn / Xoá. */
.tn-bds { display: flex; align-items: center; }
.tn-at { display: inline-block; width: 18px; height: 18px; margin: 4px 0 0 4px; border-radius: 50%; background: var(--accent, #1A9BE6); color: #fff; font-size: 11px; font-weight: 700; line-height: 18px; text-align: center; }
.tn-at.mute { background: #a8a8a8; }
.tn-bds .tn-bd { margin-left: 4px; }
.tn-laav { flex: none; width: 36px; height: 36px; border-radius: 50%; background: var(--surface-2, #F8FAFC); color: var(--muted, #5B6B7F); display: inline-flex; align-items: center; justify-content: center; }
.tn-laav svg { width: 22px; height: 22px; }
.tn-larow { background: var(--surface-3, #F8FAFC); }
.tn-lahead { display: flex; align-items: center; padding: 6px 8px; border-bottom: 1px solid var(--line, #E2E8F0); }
.tn-lahead .tn-ib { margin: 0 6px 0 0; font-size: 18px; }
.tn-lahead b { font-size: 15px; }
.tn-lanote { display: flex; align-items: flex-start; margin: 10px; padding: 10px 12px; border-radius: 12px; background: var(--surface-2, #F8FAFC); color: var(--muted, #4a4a4a); font-size: 12.5px; line-height: 1.5; }
.tn-lanote svg { flex: none; width: 18px; height: 18px; margin: 1px 8px 0 0; }
.tn-la { padding: 10px 12px; border-top: 1px solid var(--line, #E2E8F0); background: var(--surface, #fff); text-align: center; }
.tn-la p { margin: 0 0 8px; font-size: 13px; color: var(--muted, #4a4a4a); }
.tn-la p b { color: var(--ink, #0F172A); }
.tn-lab { display: flex; justify-content: center; }
.tn-lab button { flex: 1; max-width: 140px; margin: 0 4px; padding: 8px 10px; border: 1px solid var(--pill, #CBD5E1); border-radius: 999px; background: var(--surface, #fff); color: var(--ink, #0F172A); font-size: 13px; font-weight: 500; cursor: pointer; }
.tn-lab button.pri { background: var(--accent, #1A9BE6); border-color: var(--accent, #1A9BE6); color: #fff; font-weight: 600; }
.tn-lab button.dg { color: #DC2626; }
.tn-la small { display: block; margin-top: 8px; color: var(--muted, #5B6B7F); font-size: 11.5px; }
/* Chủ đề 38 (0.11.9): chat với Quản trị viên, Hộp hỗ trợ của quản trị viên chat, khung Gửi cho tất cả. */
.tn-qav { flex: none; width: 38px; height: 38px; border-radius: 50%; background: #1A9BE6; color: #fff; display: inline-flex; align-items: center; justify-content: center; }
.tn-qav svg { width: 21px; height: 21px; }
.tn-qav.sm { width: 34px; height: 34px; }
.tn-qav.sm svg { width: 18px; height: 18px; }
.tn-qrow { background: #f5faff; }
.tn-qrow:hover { background: #edf6fd; }
.tn-qrow.sel { background: #E0F2FE; }
.tn-off, .tn-qtag { display: inline-block; margin-left: 4px; padding: 0 7px; border-radius: 999px; font-size: 10.5px; font-weight: 600; line-height: 18px; vertical-align: 1px; }
.tn-qrow .tn-mid b, .tn-qmid b { display: flex; align-items: center; }
.tn-qn { min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.tn-qrow .tn-off, .tn-qrow .tn-qtag, .tn-qmid .tn-off { flex: none; margin-left: 6px; }
.tn-off { background: #E0F2FE; color: #0369A1; }
.tn-qtag { background: #1A9BE6; color: #fff; }
.tn-fix { color: #1A9BE6; }
.tn-chao { display: flex; align-items: flex-start; }
.tn-chao > div { margin-left: 10px; min-width: 0; }
.tn-chao p { margin: 0; color: #4a4a4a; font-size: 13px; line-height: 1.5; }
.tn-chao p b { color: var(--ink, #0F172A); }
.tn-chao p.tn-warn { margin-top: 4px; color: #8a5200; }
.tn.hopmode .tn-top, .tn.hopmode .tn-side > .tn-chips, .tn.hopmode .tn-uh { display: none; }
.tn-lahead .tn-bcb { margin-left: auto; padding: 5px 12px; border: 1px solid #1A9BE6; border-radius: 999px; background: var(--surface, #fff); color: #0369A1; font-size: 12.5px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; white-space: nowrap; }
.tn-bcb svg { width: 15px; height: 15px; margin-right: 5px; }
.tn-hnote { margin: 8px 10px 0; color: var(--muted, #5B6B7F); font-size: 12px; line-height: 1.5; }
.tn-hnote b { color: var(--ink, #0F172A); }
.tn-hsearch { padding: 8px 10px 0; }
.tn-hsearch input { width: 100%; box-sizing: border-box; padding: 7px 12px; border: 1px solid var(--pill, #CBD5E1); border-radius: 999px; background: var(--surface, #fff); color: inherit; font-size: 13px; }
.tn-hchips { flex-wrap: wrap; padding: 8px 10px 3px; }
.tn-hchips button { flex: none; white-space: nowrap; margin-bottom: 5px; padding: 4px 11px; font-size: 12px; }
.tn-hrow { align-items: flex-start; }
.tn-hst { display: block; margin-top: 4px; }
.tn-st, .tn-vip { display: inline-block; margin-right: 5px; padding: 0 8px; border-radius: 999px; font-size: 10.5px; font-weight: 600; line-height: 18px; white-space: nowrap; }
.tn-st.cho { background: #FEE2E2; color: #DC2626; }
.tn-st.dang { background: #E0F2FE; color: #0369A1; }
.tn-st.xong { background: #F8FAFC; color: #5B6B7F; }
.tn-vip { background: #fff1dc; color: #8a5200; }
.tn-vip svg { width: 10px; height: 10px; margin-right: 3px; vertical-align: -1px; }
.tn-shead { flex-wrap: wrap; }
.tn-shead .tn-mid { min-width: 120px; }
.tn-sact { display: flex; align-items: center; flex: none; margin-left: 6px; }
.tn-pt, .tn-done { margin-left: 6px; padding: 6px 12px; border: 1px solid var(--pill, #CBD5E1); border-radius: 999px; background: var(--surface, #fff); color: var(--ink, #0F172A); font-size: 12.5px; cursor: pointer; white-space: nowrap; }
.tn-pt:disabled { cursor: default; color: var(--muted, #5B6B7F); }
.tn-done { font-weight: 600; }
.tn-done.pri { background: #1A9BE6; border-color: #1A9BE6; color: #fff; }
.tn-cols { flex: 1; min-height: 0; display: flex; }
.tn-cols > .tn-body { flex: 1; min-width: 0; }
.tn-info { width: 240px; flex: none; box-sizing: border-box; padding: 16px; border-left: 1px solid var(--line, #E2E8F0); font-size: 12.5px; overflow: auto; }
.tn-info[hidden] { display: none; }
.tn-info.pop { width: auto; border-left: 0; padding: 4px 16px 16px; }
.tn-ic { display: flex; flex-direction: column; align-items: center; text-align: center; }
.tn-ic b { margin-top: 6px; font-size: 14px; }
.tn-ic span { color: var(--muted, #5B6B7F); }
.tn-ig { display: flex; flex-direction: column; margin-top: 14px; }
.tn-ig > span { margin-top: 8px; overflow-wrap: break-word; word-wrap: break-word; }
.tn-ig > span:first-child { margin-top: 0; }
.tn-ig i { font-style: normal; color: var(--muted, #5B6B7F); }
.tn-ih { color: var(--muted, #5B6B7F); font-size: 11px; font-weight: 600; letter-spacing: .04em; }
.tk-card.tn-bcard { width: 560px; max-width: calc(100% - 24px); }
.tn-bc h3 { margin: 12px 0 6px; }
.tn-bct button { margin: 0 6px 6px 0; padding: 6px 12px; border: 1px solid var(--pill, #CBD5E1); border-radius: 999px; background: var(--surface, #fff); color: var(--ink, #0F172A); font-size: 12.5px; cursor: pointer; }
.tn-bct button.on { border-color: #1A9BE6; background: #E0F2FE; color: #0369A1; font-weight: 600; }
.tn-bi { display: block; width: 100%; box-sizing: border-box; padding: 9px 14px; border: 1px solid var(--pill, #CBD5E1); border-radius: 12px; background: var(--surface, #fff); color: inherit; font: inherit; font-size: 13px; resize: vertical; }
.tn-bck { display: flex; align-items: center; margin-top: 10px; font-size: 13px; }
.tn-bck input { margin: 0 8px 0 0; }
.tn-bact { display: flex; justify-content: flex-end; margin-top: 14px; }
.tn-bact .tk-btn { margin-left: 8px; }
.tn-np { display: inline-block; max-width: 340px; padding: 10px 12px; border: 1px solid #b9dcf4; border-radius: 12px; background: var(--surface, #fff); }
.tn-np .k { display: flex; align-items: center; color: #0369A1; font-size: 11px; font-weight: 700; }
.tn-np .k svg { width: 14px; height: 14px; margin-right: 6px; }
.tn-np b { display: block; margin-top: 4px; font-size: 15px; }
.tn-np .ph { font-style: normal; font-weight: 400; color: var(--muted, #9a9a98); }
.tn-np p { margin: 2px 0 0; color: #4a4a4a; line-height: 1.45; white-space: pre-wrap; }
.tn-np .nb { display: inline-block; margin-top: 8px; padding: 8px 16px; border-radius: 999px; background: #1A9BE6; color: #fff; font-size: 13px; font-weight: 600; }
.tn-mc { flex: none; width: 34px; height: 34px; border-radius: 10px; background: var(--surface-2, #F8FAFC); color: #1A9BE6; display: inline-flex; align-items: center; justify-content: center; }
.tn-mc svg { width: 18px; height: 18px; }
