:root {
    --zalo-blue: #0068ff;
    --zalo-blue-hover: #0054d1;
    --zalo-blue-soft: #e5efff;
    --zalo-blue-border: #c7ddff;
    --zalo-bg-chat: #eef0f1;
    --zalo-border: #dfe2e7;
    --zalo-text: #081c36;
    --zalo-muted: #7589a3;
}

* {
    box-sizing: border-box;
}

html, body {
    height: 100%;
    margin: 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--zalo-text);
}

/* ================= AUTH PAGES (LOGIN / REGISTER) ================= */
.auth-body {
    min-height: 100vh;
    background: linear-gradient(145deg, #e3f0ff 0%, #cce2ff 50%, #dbeafe 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 16px;
}

.auth-wrapper {
    width: 100%;
    max-width: 430px;
}

.zalo-logo-badge {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    background: var(--zalo-blue);
    color: #fff;
    font-weight: 800;
    font-size: 22px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 24px rgba(0, 104, 255, 0.28);
}

.auth-title {
    font-size: 26px;
    font-weight: 700;
    color: var(--zalo-blue);
    margin-bottom: 4px;
}

.auth-subtitle {
    color: #475569;
    font-size: 14px;
    margin-bottom: 0;
}

.auth-card {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 12px 36px rgba(15, 23, 42, 0.1);
    overflow: hidden;
}

.auth-tabs {
    display: flex;
    border-bottom: 1px solid #e2e8f0;
}

.auth-tab {
    flex: 1;
    text-align: center;
    padding: 14px 10px;
    font-weight: 600;
    font-size: 14px;
    color: #64748b;
    text-decoration: none;
    border-bottom: 2px solid transparent;
    transition: all 0.15s ease;
}

.auth-tab:hover {
    color: var(--zalo-blue);
}

.auth-tab.active {
    color: var(--zalo-blue);
    border-bottom-color: var(--zalo-blue);
}

.auth-card-body {
    padding: 26px 28px;
}

.input-icon-group {
    position: relative;
}

.input-icon {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #94a3b8;
    display: flex;
}

.auth-input {
    padding-left: 40px;
    height: 44px;
    border-radius: 8px;
    border-color: #cbd5e1;
    font-size: 14px;
}

.auth-input-plain {
    height: 42px;
    border-radius: 8px;
    border-color: #cbd5e1;
    font-size: 14px;
}

.btn-zalo {
    background-color: var(--zalo-blue);
    border-color: var(--zalo-blue);
    color: #fff;
    border-radius: 8px;
    transition: background-color 0.15s ease;
}

.btn-zalo:hover, .btn-zalo:focus {
    background-color: var(--zalo-blue-hover);
    border-color: var(--zalo-blue-hover);
    color: #fff;
}

.btn-google-auth {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
    cursor: pointer;
    transition: background-color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.05);
}

.btn-google-auth:hover:not(:disabled) {
    background: #f8fafc;
    border-color: #94a3b8;
}

.btn-google-auth:disabled {
    opacity: 0.75;
    cursor: not-allowed;
}

.auth-divider {
    display: flex;
    align-items: center;
    margin: 18px 0;
    color: #94a3b8;
    font-size: 12px;
    font-weight: 500;
}

.auth-divider::before,
.auth-divider::after {
    content: "";
    flex: 1;
    border-top: 1px solid #e2e8f0;
}

.auth-divider span {
    padding: 0 10px;
}

.demo-pill {
    border: 1px solid #bfdbfe;
    background: #eff6ff;
    color: #1d4ed8;
    border-radius: 999px;
    padding: 4px 12px;
    font-size: 12.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
}

.demo-pill:hover {
    background: var(--zalo-blue);
    border-color: var(--zalo-blue);
    color: #fff;
}

/* ================= MAIN ZALO WEB LAYOUT ================= */
.zalo-app-body {
    overflow: hidden;
    background: #fff;
}

.zalo-app {
    display: flex;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

/* 1. Left Blue Rail */
.zalo-rail {
    width: 64px;
    flex-shrink: 0;
    background: var(--zalo-blue);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    z-index: 20;
}

.rail-top, .rail-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    width: 100%;
}

.rail-avatar-btn {
    position: relative;
    background: none;
    border: 2px solid rgba(255, 255, 255, 0.85);
    border-radius: 50%;
    padding: 0;
    margin-bottom: 10px;
    cursor: pointer;
}

.rail-nav-btn {
    position: relative;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.rail-nav-btn:hover {
    background: rgba(255, 255, 255, 0.16);
    color: #fff;
}

.rail-nav-btn.active {
    background: rgba(0, 67, 168, 0.72);
    color: #fff;
}

.rail-badge {
    position: absolute;
    top: 5px;
    right: 5px;
    min-width: 18px;
    height: 18px;
    padding: 0 5px;
    border-radius: 999px;
    background: #ef4444;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid var(--zalo-blue);
}

/* Avatars & Presence */
.avatar {
    border-radius: 50%;
    color: #fff;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    user-select: none;
    flex-shrink: 0;
}

.avatar-img {
    object-fit: cover;
    background: #e2e8f0;
}

.avatar-sm {
    width: 34px;
    height: 34px;
    font-size: 13px;
}

.avatar-md {
    width: 44px;
    height: 44px;
    font-size: 16px;
}

.avatar-lg {
    width: 64px;
    height: 64px;
    font-size: 24px;
}

.presence-dot {
    position: absolute;
    bottom: 1px;
    right: 1px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: #94a3b8;
}

.presence-dot.online {
    background: #22c55e;
}

.group-badge-dot {
    position: absolute;
    bottom: -1px;
    right: -2px;
    background: #e0edff;
    color: var(--zalo-blue);
    border: 1.5px solid #fff;
    font-size: 10px;
    font-weight: 700;
    border-radius: 999px;
    padding: 0 4px;
    line-height: 14px;
}

/* 2. Conversation / Contacts Sidebar */
.zalo-sidebar {
    width: 340px;
    flex-shrink: 0;
    border-right: 1px solid var(--zalo-border);
    background: #fff;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.sidebar-top {
    height: 64px;
    padding: 0 12px 0 16px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid #eef1f5;
    flex-shrink: 0;
}

.search-box {
    flex: 1;
    position: relative;
    display: flex;
    align-items: center;
    background: #ebedf0;
    border-radius: 20px;
    padding: 0 10px;
    height: 34px;
    border: 1px solid transparent;
}

.search-box:focus-within {
    background: #fff;
    border-color: var(--zalo-blue);
}

.search-icon {
    color: #64748b;
    flex-shrink: 0;
}

.search-box input {
    border: none;
    background: transparent;
    outline: none;
    width: 100%;
    padding: 0 8px;
    font-size: 13.5px;
    color: var(--zalo-text);
}

.search-clear {
    border: none;
    background: none;
    color: #64748b;
    font-size: 18px;
    line-height: 1;
    padding: 0 2px;
    cursor: pointer;
}

.icon-action-btn {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    border: none;
    background: transparent;
    color: #334155;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    transition: background 0.12s ease, color 0.12s ease;
}

.icon-action-btn:hover {
    background: #eef2f6;
    color: var(--zalo-blue);
}

.icon-action-btn.active {
    background: #e5efff;
    color: var(--zalo-blue);
}

.sidebar-pane {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-height: 0;
}

.filter-bar {
    display: flex;
    gap: 4px;
    padding: 6px 14px 0;
    border-bottom: 1px solid #eef1f5;
    flex-shrink: 0;
}

.filter-chip {
    border: none;
    background: none;
    padding: 6px 8px 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--zalo-muted);
    border-bottom: 2px solid transparent;
    cursor: pointer;
}

.filter-chip:hover {
    color: var(--zalo-blue);
}

.filter-chip.active {
    color: var(--zalo-blue);
    border-bottom-color: var(--zalo-blue);
}

.contacts-header {
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 700;
    color: var(--zalo-muted);
    border-bottom: 1px solid #eef1f5;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.conv-list {
    flex: 1;
    overflow-y: auto;
}

.conv-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 11px 16px;
    cursor: pointer;
    transition: background 0.12s ease;
    border-bottom: 1px solid #f8fafc;
}

.conv-item:hover {
    background: #f3f5f8;
}

.conv-item.active {
    background: #e5efff;
}

.conv-content {
    flex: 1;
    min-width: 0;
}

.conv-top-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 2px;
}

.conv-name {
    font-size: 15px;
    font-weight: 600;
    color: var(--zalo-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.conv-item.unread .conv-name {
    font-weight: 700;
}

.conv-time {
    font-size: 12px;
    color: var(--zalo-muted);
    flex-shrink: 0;
}

.conv-bottom-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

.conv-preview {
    font-size: 13px;
    color: var(--zalo-muted);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.conv-item.unread .conv-preview {
    color: var(--zalo-text);
    font-weight: 600;
}

.unread-pill {
    min-width: 19px;
    height: 19px;
    padding: 0 6px;
    border-radius: 999px;
    background: #ef4444;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

/* 3. Main Chat Workspace */
.zalo-main {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    background: var(--zalo-bg-chat);
    height: 100%;
}

.welcome-state {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px;
    background: #f8fafc;
}

.welcome-card {
    max-width: 480px;
    text-align: center;
}

.welcome-logo {
    width: 72px;
    height: 72px;
    border-radius: 22px;
    background: linear-gradient(135deg, #0068ff, #38bdf8);
    color: #fff;
    font-size: 26px;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 12px 28px rgba(0, 104, 255, 0.25);
}

.welcome-card h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 10px;
}

.welcome-card h2 span {
    color: var(--zalo-blue);
}

.welcome-card p {
    color: #64748b;
    font-size: 14.5px;
    line-height: 1.6;
}

.chat-workspace {
    display: flex;
    flex-direction: column;
    height: 100%;
    min-height: 0;
}

.chat-header {
    height: 68px;
    padding: 0 18px;
    background: #fff;
    border-bottom: 1px solid var(--zalo-border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-shrink: 0;
}

.chat-header-title {
    font-size: 17px;
    font-weight: 700;
    color: var(--zalo-text);
}

.chat-header-sub {
    font-size: 12.5px;
    color: var(--zalo-muted);
}

.chat-body-split {
    flex: 1;
    display: flex;
    min-height: 0;
    overflow: hidden;
}

.chat-conversation-col {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
    min-height: 0;
}

.messages-viewport {
    flex: 1;
    overflow-y: auto;
    padding: 18px 20px;
}

.messages-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.date-divider {
    text-align: center;
    margin: 10px 0;
}

.date-divider span {
    display: inline-block;
    background: rgba(15, 23, 42, 0.12);
    color: #fff;
    font-size: 11.5px;
    padding: 3px 12px;
    border-radius: 999px;
}

.system-msg {
    text-align: center;
    margin: 6px 0;
}

.system-msg span {
    display: inline-block;
    background: rgba(255, 255, 255, 0.82);
    color: #475569;
    font-size: 12px;
    padding: 4px 14px;
    border-radius: 999px;
    border: 1px solid #e2e8f0;
}

.msg-row {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    max-width: 76%;
    position: relative;
}

.msg-row.has-reactions {
    margin-bottom: 10px;
}

.msg-row.mine {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.msg-row.theirs {
    align-self: flex-start;
}

.msg-avatar-slot {
    width: 34px;
    flex-shrink: 0;
}

.msg-bubble-wrap {
    position: relative;
    display: flex;
    flex-direction: column;
    max-width: 100%;
}

.msg-row.mine .msg-bubble-wrap {
    align-items: flex-end;
}

.msg-row.theirs .msg-bubble-wrap {
    align-items: flex-start;
}

.msg-bubble {
    padding: 9px 13px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.06);
    word-break: break-word;
}

.msg-row.theirs .msg-bubble {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-bottom-left-radius: 4px;
}

.msg-row.mine .msg-bubble {
    background: var(--zalo-blue-soft);
    border: 1px solid var(--zalo-blue-border);
    border-bottom-right-radius: 4px;
}

/* Jumbo Emoji Bubble & Animated Sticker Card */
.msg-bubble.msg-bubble-jumbo {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    padding: 2px 6px;
}

.msg-jumbo-emoji {
    font-size: 40px;
    line-height: 1.15;
    display: inline-block;
    animation: stickerPopIn 0.32s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.msg-sticker-card {
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 12px 18px 10px;
    border-radius: 18px;
    min-width: 124px;
    box-shadow: 0 6px 18px rgba(15, 23, 42, 0.08);
    border: 1.5px solid rgba(255, 255, 255, 0.9);
    animation: stickerPopIn 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: pointer;
    transition: transform 0.18s ease;
}

.msg-sticker-card:hover {
    transform: scale(1.05);
}

.msg-sticker-icon {
    font-size: 48px;
    line-height: 1.1;
    margin-bottom: 5px;
    display: inline-block;
}

.msg-sticker-label {
    font-size: 12.5px;
    font-weight: 700;
    padding: 2px 10px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.88);
    color: #0f172a;
    white-space: nowrap;
}

.anim-wave { animation: emoWave 1.8s ease-in-out infinite; transform-origin: 70% 70%; }
.anim-beat { animation: emoBeat 1.4s ease-in-out infinite; }
.anim-laugh { animation: emoShake 1.2s ease-in-out infinite; }
.anim-float { animation: emoFloat 2.2s ease-in-out infinite; }

@keyframes stickerPopIn {
    0% { transform: scale(0.5); opacity: 0; }
    100% { transform: scale(1); opacity: 1; }
}

@keyframes emoWave {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(16deg); }
    50% { transform: rotate(-10deg); }
    75% { transform: rotate(12deg); }
}

@keyframes emoBeat {
    0%, 100% { transform: scale(1); }
    30% { transform: scale(1.18); }
    60% { transform: scale(0.96); }
}

@keyframes emoShake {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25% { transform: translateY(-3px) rotate(-8deg); }
    75% { transform: translateY(-2px) rotate(8deg); }
}

@keyframes emoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* Zalo Message Reaction Picker & Summary Pills */
.msg-react-trigger-wrap {
    position: relative;
    align-self: center;
    opacity: 0;
    transition: opacity 0.15s ease;
}

.msg-row:hover .msg-react-trigger-wrap,
.msg-react-trigger-wrap:focus-within {
    opacity: 1;
}

.msg-react-btn {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #64748b;
    font-size: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.08);
    padding: 0;
}

.msg-react-btn:hover {
    background: #f8fafc;
    transform: scale(1.08);
}

.msg-react-palette {
    position: absolute;
    bottom: 30px;
    display: none;
    align-items: center;
    gap: 3px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    padding: 4px 8px;
    box-shadow: 0 8px 24px rgba(15, 23, 42, 0.16);
    z-index: 40;
    white-space: nowrap;
}

.msg-row.mine .msg-react-palette {
    right: 0;
}

.msg-row.theirs .msg-react-palette {
    left: 0;
}

.msg-react-trigger-wrap:hover .msg-react-palette,
.msg-react-trigger-wrap.open .msg-react-palette {
    display: flex;
    animation: stickerPopIn 0.18s ease-out;
}

.react-choice-btn {
    border: none;
    background: transparent;
    font-size: 19px;
    line-height: 1;
    padding: 4px;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.14s ease, background 0.14s ease;
}

.react-choice-btn:hover {
    transform: scale(1.35) translateY(-2px);
    background: #eff6ff;
}

.msg-reactions-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: -6px;
    z-index: 5;
    padding: 0 6px;
}

.reaction-chip {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    background: #ffffff;
    border: 1px solid #dbe3ee;
    border-radius: 999px;
    padding: 1px 7px;
    font-size: 12px;
    box-shadow: 0 2px 5px rgba(15, 23, 42, 0.07);
    cursor: pointer;
    transition: transform 0.12s ease, border-color 0.12s ease;
}

.reaction-chip:hover {
    transform: scale(1.07);
}

.reaction-chip.mine-reacted {
    background: #e5efff;
    border-color: #60a5fa;
    color: var(--zalo-blue);
    font-weight: 700;
}

.reaction-chip-count {
    font-size: 11px;
    color: #475569;
}

.msg-sender-name {
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 3px;
}

.msg-text {
    font-size: 14.5px;
    line-height: 1.45;
    white-space: pre-wrap;
    color: var(--zalo-text);
}

.msg-text a {
    color: var(--zalo-blue);
    text-decoration: underline;
}

.msg-time {
    font-size: 11px;
    color: #7c8da5;
    margin-top: 4px;
    text-align: right;
}

/* Typing indicator */
.typing-bar {
    padding: 4px 20px 6px;
    font-size: 12.5px;
    color: #475569;
    display: flex;
    align-items: center;
    gap: 6px;
}

.typing-dots {
    display: inline-flex;
    gap: 3px;
}

.typing-dots span {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--zalo-blue);
    animation: typingBounce 1.2s infinite ease-in-out;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingBounce {
    0%, 80%, 100% { transform: scale(0.6); opacity: 0.5; }
    40% { transform: scale(1); opacity: 1; }
}

/* Composer */
.chat-composer {
    background: #fff;
    border-top: 1px solid var(--zalo-border);
    flex-shrink: 0;
}

.composer-toolbar {
    height: 38px;
    padding: 0 14px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    align-items: center;
    gap: 6px;
}

.toolbar-btn {
    border: none;
    background: transparent;
    border-radius: 6px;
    padding: 4px 9px;
    font-size: 16px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: #334155;
    transition: background 0.12s ease, color 0.12s ease;
}

.toolbar-btn-label {
    font-size: 12.5px;
    font-weight: 600;
}

.toolbar-btn:hover,
.toolbar-btn.active {
    background: #e5efff;
    color: var(--zalo-blue);
}

/* Tabbed Emotion Picker (Stickers + Emoji Categories) */
.emotion-popover {
    position: absolute;
    bottom: 44px;
    left: 12px;
    width: 356px;
    max-width: calc(100vw - 90px);
    background: #ffffff;
    border: 1px solid #dbe3ee;
    border-radius: 14px;
    box-shadow: 0 14px 36px rgba(15, 23, 42, 0.18);
    overflow: hidden;
    z-index: 60;
    animation: stickerPopIn 0.16s ease-out;
}

.emotion-tabs {
    display: flex;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 4px 6px 0;
    gap: 2px;
}

.emotion-tab {
    flex: 1;
    border: none;
    background: transparent;
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    padding: 7px 4px;
    border-bottom: 2px solid transparent;
    cursor: pointer;
    white-space: nowrap;
}

.emotion-tab:hover {
    color: var(--zalo-blue);
}

.emotion-tab.active {
    color: var(--zalo-blue);
    border-bottom-color: var(--zalo-blue);
    background: #fff;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}

.emotion-body {
    max-height: 270px;
    overflow-y: auto;
    padding: 10px;
}

.sticker-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
}

.sticker-pick-item {
    border: 1px solid #eef2f6;
    border-radius: 12px;
    padding: 8px 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    cursor: pointer;
    transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.sticker-pick-item:hover {
    transform: translateY(-2px) scale(1.04);
    box-shadow: 0 6px 14px rgba(15, 23, 42, 0.1);
}

.sticker-pick-icon {
    font-size: 32px;
    line-height: 1.1;
}

.sticker-pick-text {
    font-size: 11px;
    font-weight: 700;
    color: #1e293b;
    text-align: center;
    line-height: 1.2;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 4px;
}

.emoji-item {
    border: none;
    background: transparent;
    font-size: 22px;
    padding: 5px 2px;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.12s ease, background 0.12s ease;
}

.emoji-item:hover {
    background: #eff6ff;
    transform: scale(1.22);
}

.btn-quick-heart {
    border: none;
    background: #fff1f2;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    font-size: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    flex-shrink: 0;
    transition: transform 0.15s ease, background 0.15s ease;
}

.btn-quick-heart:hover {
    background: #ffe4e6;
    transform: scale(1.16);
}

/* Floating Emotion Burst Particles */
.floating-emotion-layer {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: 9999;
}

.floating-emo-particle {
    position: absolute;
    font-size: 28px;
    will-change: transform, opacity;
    animation: floatUpBurst 1.5s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes floatUpBurst {
    0% {
        transform: translate(0, 0) scale(0.5) rotate(0deg);
        opacity: 1;
    }
    70% {
        opacity: 0.95;
    }
    100% {
        transform: translate(var(--dx, 20px), -180px) scale(1.35) rotate(var(--rot, 15deg));
        opacity: 0;
    }
}

.composer-input-row {
    display: flex;
    align-items: flex-end;
    gap: 10px;
    padding: 10px 14px;
}

.composer-input-row textarea {
    flex: 1;
    border: none;
    outline: none;
    resize: none;
    font-size: 14.5px;
    line-height: 1.45;
    max-height: 120px;
    color: var(--zalo-text);
}

.btn-send-zalo {
    border: none;
    background: transparent;
    color: var(--zalo-blue);
    font-weight: 700;
    font-size: 14px;
    padding: 6px 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.12s ease;
}

.btn-send-zalo:hover {
    background: #e5efff;
}

/* 4. Right Info Panel */
.chat-info-panel {
    width: 300px;
    flex-shrink: 0;
    background: #fff;
    border-left: 1px solid var(--zalo-border);
    display: flex;
    flex-direction: column;
    height: 100%;
}

.info-panel-header {
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 15px;
    border-bottom: 1px solid #eef1f5;
    flex-shrink: 0;
}

.info-panel-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 16px;
}

.member-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 6px;
    border-radius: 8px;
}

.member-row:hover {
    background: #f8fafc;
}

/* Modals */
.zalo-modal {
    border-radius: 12px;
    border: none;
    box-shadow: 0 16px 40px rgba(15, 23, 42, 0.18);
}

.modal-user-list {
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.modal-user-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 9px 12px;
    border-bottom: 1px solid #f1f5f9;
    cursor: pointer;
}

.modal-user-item:last-child {
    border-bottom: none;
}

.modal-user-item:hover {
    background: #f8fafc;
}

.selected-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.user-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: #e5efff;
    color: var(--zalo-blue);
    border-radius: 999px;
    padding: 3px 10px;
    font-size: 12.5px;
    font-weight: 600;
}

.user-chip button {
    border: none;
    background: none;
    color: var(--zalo-blue);
    font-weight: 700;
    padding: 0;
    line-height: 1;
    cursor: pointer;
}

/* Responsive Mobile View */
@media (max-width: 991.98px) {
    .chat-info-panel {
        display: none !important;
    }
}

@media (max-width: 767.98px) {
    .zalo-sidebar {
        width: calc(100vw - 64px);
    }

    .zalo-app.chat-open .zalo-sidebar {
        display: none;
    }

    .zalo-app:not(.chat-open) .zalo-main {
        display: none;
    }

    .msg-row {
        max-width: 88%;
    }
}
