/* ============================================
    CHAT ZELO - VISUAL PREMIUM + CORREÇÃO TECLADO
    CORRIGIDO: Mensagens com mais espaço acima da input
    Tema fixo (escuro)
    © 2026 LITE STUDIO
    ============================================ */
.st-chat-container {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: #000000;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 2;
    transition: background 0.4s ease;
    height: 100dvh;
    height: -webkit-fill-available;
}
@media (min-width: 600px) {
    .st-chat-container {
        left: 50%;
        transform: translateX(-50%);
        max-width: 480px;
        border-left: 1px solid rgba(255,255,255,0.06);
        border-right: 1px solid rgba(255,255,255,0.06);
    }
}
.st-chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 18px;
    background: #0a0a0a;
    border-bottom: 2px solid rgba(255,255,255,0.08);
    flex-shrink: 0;
    min-height: 52px;
    z-index: 10;
    position: relative;
    transition: all 0.4s ease;
    gap: 12px;
}
.st-chat-header::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 20%;
    right: 20%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    pointer-events: none;
}
.st-chat-title {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.25em;
    text-transform: uppercase;
    text-shadow: 0 0 20px rgba(255,255,255,0.08);
    display: flex;
    align-items: center;
    gap: 8px;
    transition: color 0.4s ease;
    flex: 1;
    text-align: center;
    justify-content: center;
}
.st-chat-title span {
    color: rgba(255,255,255,0.3);
    font-weight: 400;
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    transition: color 0.4s ease;
}
.st-chat-back-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 8px 14px;
    background: linear-gradient(135deg, rgba(255,255,255,0.08) 0%, rgba(255,255,255,0.04) 100%);
    border: 1.5px solid rgba(255,255,255,0.15);
    border-radius: 12px;
    color: rgba(255,255,255,0.9);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    overflow: hidden;
    font-family: var(--font-display);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.1);
    flex-shrink: 0;
}
.st-chat-back-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s ease;
}
.st-chat-back-btn:hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.12) 0%, rgba(255,255,255,0.06) 100%);
    border-color: rgba(255,255,255,0.25);
    transform: translateX(-2px) scale(1.05);
    box-shadow: 0 4px 16px rgba(0,0,0,0.4), inset 0 1px 0 rgba(255,255,255,0.15), 0 0 20px rgba(255,255,255,0.05);
}
.st-chat-back-btn:hover::before {
    left: 100%;
}
.st-chat-back-btn:active {
    transform: translateX(-2px) scale(0.98);
    box-shadow: 0 2px 8px rgba(0,0,0,0.3), inset 0 2px 4px rgba(0,0,0,0.2);
}
.st-back-arrow {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: rgba(255,255,255,0.1);
    border-radius: 8px;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
.st-chat-back-btn:hover .st-back-arrow {
    transform: translateX(-4px) scale(1.1);
    background: rgba(255,255,255,0.15);
    box-shadow: 0 0 12px rgba(255,255,255,0.2);
}
.st-back-arrow svg {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.st-chat-back-btn:hover .st-back-arrow svg {
    transform: scale(1.15);
}
.st-back-text {
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
    font-weight: 700;
}
/* ============================================
    MESSAGES WRAPPER - Mais espaço para mensagens
    ============================================ */
.st-chat-messages-wrapper {
    flex: 1;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 0;
    background: #000000;
    transition: padding-bottom 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    padding-bottom: 0px;
}
.st-chat-messages-wrapper::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 30%, rgba(229,229,229,0.015) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 70%, rgba(201,169,97,0.01) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}
.st-chat-messages-wrapper::after {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(0deg, rgba(0,0,0,0.08) 0px, rgba(0,0,0,0.08) 1px, transparent 1px, transparent 3px);
    pointer-events: none;
    z-index: 0;
    opacity: 0.3;
}
/* ============================================
    ✅ MENSAGENS - Padding aumentado
    Mais espaço embaixo para não ficar atrás da input
    ============================================ */
.st-chat-messages {
    flex: 1;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    -webkit-overflow-scrolling: touch;
    padding: 12px 16px 80px 16px !important;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-height: 0;
    position: relative;
    z-index: 1;
    scroll-behavior: smooth;
}
.st-chat-messages::-webkit-scrollbar {
    width: 4px;
}
.st-chat-messages::-webkit-scrollbar-track {
    background: transparent;
}
.st-chat-messages::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.1);
    border-radius: 2px;
}
.st-chat-messages::-webkit-scrollbar-thumb:hover {
    background: rgba(255,255,255,0.2);
}
.st-chat-date-separator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin: 20px 0 16px;
    padding: 0 8px;
    animation: dateSlideIn 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes dateSlideIn {
    from { opacity: 0; transform: translateY(8px) scale(0.96); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.st-chat-date-line {
    flex: 1;
    max-width: 40px;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transition: background 0.4s ease;
}
.st-chat-date-text {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: rgba(255,255,255,0.6);
    letter-spacing: 0.15em;
    text-transform: uppercase;
    padding: 5px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 20px;
    white-space: nowrap;
    font-weight: 600;
    transition: all 0.4s ease;
}
.st-chat-msg {
    display: flex;
    gap: 10px;
    align-items: flex-start;
    max-width: 100%;
    padding: 3px 0;
    position: relative;
    animation: msgSlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    touch-action: pan-y;
    transition: transform 0.2s ease;
}
@keyframes msgSlideIn {
    from { opacity: 0; transform: translateY(12px) scale(0.94); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}
.st-chat-msg.st-chat-msg-new {
    animation: msgNew 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes msgNew {
    0% { opacity: 0; transform: translateY(20px) scale(0.9) rotate(-1deg); }
    60% { opacity: 1; transform: translateY(-2px) scale(1.02) rotate(0.5deg); }
    100% { opacity: 1; transform: translateY(0) scale(1) rotate(0); }
}
.st-chat-msg.st-chat-msg-fade-out {
    animation: msgFadeOut 0.3s ease forwards;
}
@keyframes msgFadeOut {
    to { opacity: 0; transform: translateX(-20px) scale(0.9); max-height: 0; margin: 0; padding: 0; }
}
.st-chat-msg.swiping {
    z-index: 5;
}
.st-chat-swipe-reply {
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%) scale(0);
    width: 44px;
    height: 44px;
    background: rgba(229, 229, 229, 0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000000;
    opacity: 0;
    transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.2s ease;
    z-index: -1;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
}
.st-chat-swipe-reply svg {
    width: 20px;
    height: 20px;
}
.st-chat-msg.swiping .st-chat-swipe-reply {
    opacity: 1;
}
.st-chat-msg.swipe-ready .st-chat-swipe-reply {
    transform: translateY(-50%) scale(1.1);
    background: #ffffff;
    box-shadow: 0 0 20px rgba(255,255,255,0.5);
}
.st-chat-msg-own {
    flex-direction: row-reverse;
}
.st-chat-msg-own .st-chat-swipe-reply {
    left: auto;
    right: 0;
}
.st-chat-msg-own .st-chat-msg-content {
    align-items: flex-end;
}
.st-chat-msg-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    overflow: hidden;
    border: 2px solid rgba(255,255,255,0.1);
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    color: #ffffff;
    margin-top: 2px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: rgba(255,255,255,0.04);
}
.st-chat-msg-avatar:hover {
    transform: scale(1.08);
    border-color: rgba(255,255,255,0.3);
}
.st-chat-msg-avatar:active {
    transform: scale(0.95);
}
.st-chat-msg-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.st-chat-msg-avatar-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}
.st-chat-msg-content {
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
    flex: 0 1 auto;
    max-width: 78%;
}
.st-chat-msg-header {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
    padding: 0 4px 2px;
}
.st-chat-msg-name {
    font-family: var(--font-display);
    font-size: 0.82rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    transition: color 0.4s ease;
}
.st-chat-msg-time {
    font-family: var(--font-mono);
    font-size: 0.62rem;
    color: rgba(255,255,255,0.45);
    letter-spacing: 0.05em;
    transition: color 0.4s ease;
}
.st-chat-msg-bubble {
    padding: 10px 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 14px;
    font-family: var(--font-main);
    font-size: 0.95rem;
    color: #e8eaed;
    line-height: 1.5;
    word-wrap: break-word;
    overflow-wrap: break-word;
    word-break: break-word;
    display: inline-block;
    max-width: 100%;
    position: relative;
    transition: all 0.3s ease;
}
.st-chat-msg-bubble:hover {
    background: rgba(255,255,255,0.06);
}
.st-chat-msg-own .st-chat-msg-bubble {
    background: linear-gradient(135deg, rgba(229,229,229,0.12) 0%, rgba(229,229,229,0.06) 100%);
    border-color: rgba(229,229,229,0.2);
    color: #ffffff;
    box-shadow: 0 2px 12px rgba(229,229,229,0.05);
}
.st-chat-msg-own .st-chat-msg-bubble:hover {
    background: linear-gradient(135deg, rgba(229,229,229,0.16) 0%, rgba(229,229,229,0.08) 100%);
}
.st-chat-msg-bubble::before {
    content: '';
    position: absolute;
    inset: 0;
    background: repeating-linear-gradient(0deg, rgba(255,255,255,0.015) 0px, rgba(255,255,255,0.015) 1px, transparent 1px, transparent 3px);
    pointer-events: none;
    border-radius: 14px;
    opacity: 0.6;
    z-index: 1;
}
.st-chat-msg-bubble:has(.st-chat-msg-reply-ref)::before {
    display: none !important;
}
.st-chat-msg-reply-ref {
    position: relative !important;
    z-index: 100 !important;
    display: block;
    padding: 10px 14px;
    margin-bottom: 8px;
    background: linear-gradient(135deg, #1e40af 0%, #2563eb 50%, #3b82f6 100%) !important;
    border-left: 4px solid #60a5fa !important;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.1), 0 0 0 1px rgba(96, 165, 250, 0.3) !important;
    transition: all 0.3s ease;
    overflow: hidden;
    transform: translateZ(0);
}
.st-chat-msg-reply-ref::before {
    content: '↩ RESPOSTA';
    display: block;
    font-family: var(--font-mono);
    font-size: 0.55rem;
    color: #93c5fd !important;
    letter-spacing: 0.2em;
    text-transform: uppercase;
    margin-bottom: 6px;
    padding-bottom: 6px;
    border-bottom: 1px solid rgba(147, 197, 253, 0.3);
    position: relative;
    z-index: 101;
    font-weight: 700;
}
.st-chat-msg-reply-ref-name {
    position: relative;
    z-index: 101;
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: var(--font-display);
    font-weight: 700;
    color: #ffffff !important;
    font-size: 0.82rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 4px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}
.st-chat-msg-reply-ref-name::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #60a5fa;
    border-radius: 50%;
    box-shadow: 0 0 10px rgba(96, 165, 250, 0.8), 0 0 20px rgba(96, 165, 250, 0.4);
    flex-shrink: 0;
    animation: replyDotPulse 2s ease-in-out infinite;
}
@keyframes replyDotPulse {
    0%, 100% { box-shadow: 0 0 10px rgba(96, 165, 250, 0.6), 0 0 20px rgba(96, 165, 250, 0.3); transform: scale(1); }
    50% { box-shadow: 0 0 15px rgba(96, 165, 250, 0.9), 0 0 30px rgba(96, 165, 250, 0.5); transform: scale(1.2); }
}
.st-chat-msg-reply-ref-text {
    position: relative;
    z-index: 101;
    display: block;
    font-family: var(--font-main);
    font-size: 0.88rem;
    color: #e0e7ff !important;
    line-height: 1.4;
    max-height: 3.6em;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    word-break: break-word;
    white-space: normal;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.st-chat-msg-reply-ref:hover {
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%) !important;
    border-left-color: #93c5fd !important;
    transform: translateX(2px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.2), 0 0 0 1px rgba(96, 165, 250, 0.4) !important;
}
.st-chat-msg-new .st-chat-msg-reply-ref {
    animation: replySlideIn 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes replySlideIn {
    from { opacity: 0; transform: translateY(-10px) translateX(-5px); }
    to { opacity: 1; transform: translateY(0) translateX(0); }
}
.st-chat-msg-own .st-chat-msg-reply-ref {
    background: linear-gradient(135deg, #1e3a8a 0%, #1e40af 50%, #2563eb 100%) !important;
    border-left: 4px solid #60a5fa !important;
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.15), 0 0 0 1px rgba(96, 165, 250, 0.4) !important;
}
.st-chat-msg-own .st-chat-msg-reply-ref::before {
    color: #93c5fd !important;
    border-bottom-color: rgba(147, 197, 253, 0.3);
}
.st-chat-msg-own .st-chat-msg-reply-ref-name {
    color: #ffffff !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}
.st-chat-msg-own .st-chat-msg-reply-ref-name::before {
    background: #60a5fa;
    box-shadow: 0 0 12px rgba(96, 165, 250, 0.8), 0 0 24px rgba(96, 165, 250, 0.4);
}
.st-chat-msg-own .st-chat-msg-reply-ref-text {
    color: #e0e7ff !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
.st-chat-msg-own .st-chat-msg-reply-ref:hover {
    background: linear-gradient(135deg, #1e40af 0%, #2563eb 50%, #3b82f6 100%) !important;
    border-left-color: #93c5fd !important;
}
.st-chat-link {
    color: #8ab4f8;
    text-decoration: underline;
    word-break: break-all;
    transition: color 0.2s ease;
    position: relative;
    z-index: 2;
}
.st-chat-link:hover {
    color: #aecbfa;
}
.st-chat-msg-own .st-chat-link {
    color: #ffffff;
    text-decoration: underline;
    text-decoration-color: rgba(255,255,255,0.5);
}
/* ============================================
    ✅ INPUT AREA - Mais compacta
    Menos espaço ocupado = mais espaço para mensagens
    ============================================ */
.st-chat-input-area {
    background: #0a0a0a;
    border-top: 1px solid rgba(255,255,255,0.08);
    flex-shrink: 0;
    position: relative;
    z-index: 20;
    display: flex;
    flex-direction: column;
    width: 100%;
    transform: translateY(0);
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    will-change: transform;
    padding-bottom: 0;
}
.st-chat-input-area.input-active {
    background: #0d0d0d;
}
.st-chat-reply-preview {
    display: none;
    position: relative;
    z-index: 100;
    padding: 10px 50px 10px 16px;
    margin: 0;
    background: linear-gradient(135deg, rgba(30, 64, 175, 0.95) 0%, rgba(37, 99, 235, 0.95) 100%);
    border-left: 5px solid #60a5fa;
    border-bottom: 1px solid rgba(96, 165, 250, 0.3);
    border-top: none;
    border-right: none;
    border-radius: 0;
    animation: replyPreviewIn 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.3);
    flex-shrink: 0;
    transform: translateZ(0);
}
.st-chat-reply-preview.active {
    display: block !important;
    visibility: visible !important;
}
@keyframes replyPreviewIn {
    from { opacity: 0; max-height: 0; padding-top: 0; padding-bottom: 0; }
    to { opacity: 1; max-height: 120px; padding-top: 10px; padding-bottom: 10px; }
}
.st-chat-reply-preview-close {
    position: absolute;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
    width: 30px;
    height: 30px;
    background: rgba(255, 255, 255, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #ffffff;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    font-weight: 700;
    transition: all 0.2s ease;
    z-index: 101;
    line-height: 1;
}
.st-chat-reply-preview-close:hover {
    background: rgba(239, 68, 68, 0.3);
    border-color: rgba(239, 68, 68, 0.5);
    color: #ef4444;
    transform: translateY(-50%) scale(1.1) rotate(90deg);
}
.st-chat-reply-content {
    padding-right: 40px;
    position: relative;
    z-index: 100;
}
.st-chat-reply-content-label {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: #93c5fd;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    margin-bottom: 4px;
    font-weight: 600;
}
.st-chat-reply-content-name {
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 700;
    color: #ffffff;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    margin-bottom: 4px;
    transition: color 0.3s ease;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
}
.st-chat-reply-content-text {
    font-size: 0.9rem;
    color: #e0e7ff;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 100%;
    line-height: 1.5;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}
/* ============================================
    ✅ INPUT WRAPPER - Mais compacto
    Margin reduzida = input menor = mais espaço pra mensagens
    ============================================ */
.st-chat-input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 22px;
    padding: 6px 6px 6px 16px;
    margin: 6px 10px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
    cursor: text;
    min-height: 40px;
    -webkit-tap-highlight-color: rgba(229, 229, 229, 0.1);
}
.st-chat-input-wrapper.focused,
.st-chat-input-wrapper:focus-within {
    border-color: rgba(229,229,229,0.5);
    background: rgba(255,255,255,0.08);
    box-shadow: 0 0 0 3px rgba(229,229,229,0.1), 0 0 16px rgba(229,229,229,0.1);
}
.st-chat-input {
    flex: 1;
    background: transparent;
    border: none;
    outline: none;
    color: #e8eaed;
    font-family: var(--font-main);
    font-size: 16px !important;
    resize: none;
    max-height: 100px;
    min-height: 26px;
    padding: 6px 0;
    line-height: 1.4;
    overflow-y: auto;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    -webkit-tap-highlight-color: rgba(229, 229, 229, 0.1);
    -webkit-user-select: text !important;
    -moz-user-select: text !important;
    -ms-user-select: text !important;
    user-select: text !important;
    touch-action: manipulation;
    cursor: text;
    caret-color: #E5E5E5;
    z-index: 2;
    position: relative;
}
.st-chat-input:focus {
    outline: none;
}
.st-chat-input::placeholder {
    color: rgba(255,255,255,0.3);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}
.st-chat-counter {
    font-family: var(--font-mono);
    font-size: 0.6rem;
    color: rgba(255,255,255,0.3);
    padding: 0 6px 6px 0;
    letter-spacing: 0.05em;
    flex-shrink: 0;
    transition: color 0.3s ease;
    align-self: flex-end;
}
.st-chat-counter.warning {
    color: rgba(251, 191, 36, 0.7);
}
.st-chat-counter.danger {
    color: rgba(239, 68, 68, 0.8);
    font-weight: 700;
}
/* ============================================
    ✅ SEND BUTTON - Um pouco menor
    ============================================ */
.st-chat-send-btn {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    background: rgba(229,229,229,0.95);
    border: none;
    border-radius: 50%;
    color: #000000;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(229,229,229,0.2);
}
.st-chat-send-btn:disabled {
    background: rgba(255,255,255,0.08);
    color: rgba(255,255,255,0.3);
    cursor: not-allowed;
    box-shadow: none;
}
.st-chat-send-btn:not(:disabled):hover {
    background: #ffffff;
    transform: scale(1.08);
    box-shadow: 0 4px 16px rgba(229,229,229,0.3);
}
.st-chat-send-btn:not(:disabled):active {
    transform: scale(0.92);
}
.st-chat-typing {
    padding: 6px 16px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    color: rgba(255,255,255,0.6);
    font-style: italic;
    background: transparent;
    display: flex;
    align-items: center;
    gap: 8px;
    border-top: 1px solid rgba(255,255,255,0.05);
    transition: all 0.4s ease;
    flex-shrink: 0;
}
.st-typing-dots {
    display: flex;
    gap: 4px;
}
.st-typing-dots span {
    width: 5px;
    height: 5px;
    background: rgba(255,255,255,0.6);
    border-radius: 50%;
    animation: typingDot 1.4s ease-in-out infinite;
}
.st-typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}
.st-typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}
@keyframes typingDot {
    0%, 60%, 100% { transform: translateY(0); opacity: 0.3; }
    30% { transform: translateY(-5px); opacity: 1; }
}
.st-chat-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 14px;
    text-align: center;
    padding: 40px 20px;
    animation: emptyFadeIn 0.6s ease;
}
@keyframes emptyFadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}
.st-chat-empty-icon {
    width: 70px;
    height: 70px;
    background: rgba(229,229,229,0.05);
    border: 2px solid rgba(229,229,229,0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    color: rgba(229,229,229,0.6);
    transition: all 0.4s ease;
    animation: emptyPulse 3s ease-in-out infinite;
}
@keyframes emptyPulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(229,229,229,0.1); }
    50% { transform: scale(1.05); box-shadow: 0 0 30px rgba(229,229,229,0.1); }
}
.st-chat-empty-title {
    font-family: var(--font-display);
    font-size: 1.1rem;
    color: #ffffff;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    font-weight: 600;
    transition: color 0.4s ease;
}
.st-chat-empty-desc {
    font-family: var(--font-main);
    font-size: 0.85rem;
    color: rgba(255,255,255,0.4);
    max-width: 260px;
    line-height: 1.5;
    transition: color 0.4s ease;
}
.st-chat-loading {
    color: rgba(255,255,255,0.2);
    text-align: center;
    padding: 40px;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
}
.st-chat-loading-spinner {
    width: 32px;
    height: 32px;
    border: 2px solid rgba(255,255,255,0.08);
    border-top-color: rgba(229,229,229,0.6);
    border-radius: 50%;
    animation: loadingSpin 0.8s linear infinite;
}
@keyframes loadingSpin {
    to { transform: rotate(360deg); }
}
.st-chat-error {
    color: rgba(239,68,68,0.7);
    text-align: center;
    padding: 40px 20px;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    letter-spacing: 0.1em;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}
.st-chat-retry-btn {
    padding: 10px 24px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    font-family: var(--font-mono);
    font-size: 0.72rem;
    letter-spacing: 0.15em;
    text-transform: uppercase;
    border-radius: 8px;
    transition: all 0.3s ease;
}
.st-chat-retry-btn:hover {
    background: rgba(255,255,255,0.08);
    border-color: rgba(255,255,255,0.2);
    color: #ffffff;
}
/* ============================================
    RESPONSIVO
    ============================================ */
@media (max-width: 380px) {
    .st-chat-header { padding: 8px 12px; min-height: 48px; gap: 8px; }
    .st-chat-title { font-size: 1.15rem; letter-spacing: 0.2em; }
    .st-chat-messages { padding: 10px 12px 70px 12px !important; }
    .st-chat-msg-avatar { width: 30px; height: 30px; font-size: 0.8rem; }
    .st-chat-msg-bubble { font-size: 0.9rem; padding: 9px 12px; }
    .st-chat-msg-content { max-width: 82%; }
    .st-chat-input-wrapper { margin: 5px 8px; padding: 5px 5px 5px 12px; min-height: 38px; }
    .st-chat-send-btn { width: 32px; height: 32px; min-width: 32px; min-height: 32px; }
    .st-chat-date-text { font-size: 0.6rem; padding: 4px 12px; }
    .st-chat-back-btn { padding: 6px 10px; font-size: 0.75rem; }
    .st-back-arrow { width: 24px; height: 24px; }
    .st-back-text { display: none; }
    .st-chat-msg-reply-ref { padding: 8px 12px; }
    .st-chat-msg-reply-ref-name { font-size: 0.75rem; }
    .st-chat-msg-reply-ref-text { font-size: 0.82rem; }
    .st-chat-reply-preview { padding: 8px 44px 8px 14px; }
}
@media (max-width: 480px) and (orientation: landscape) {
    .st-chat-messages { padding: 8px 12px 60px 12px !important; }
    .st-chat-msg-avatar { width: 28px; height: 28px; font-size: 0.7rem; }
    .st-chat-msg-bubble { font-size: 0.85rem; padding: 7px 10px; }
    .st-chat-header { min-height: 44px; padding: 6px 12px; }
    .st-chat-input-wrapper { margin: 4px 8px; min-height: 36px; padding: 4px 4px 4px 12px; }
    .st-chat-send-btn { width: 30px; height: 30px; min-width: 30px; min-height: 30px; }
}
@media (min-width: 600px) {
    .st-chat-messages { padding: 16px 20px 90px 20px !important; }
    .st-chat-msg-avatar { width: 38px; height: 38px; font-size: 0.95rem; }
    .st-chat-msg-bubble { font-size: 1rem; padding: 11px 16px; }
    .st-chat-title { font-size: 1.5rem; }
    .st-chat-input { font-size: 1rem; }
    .st-chat-send-btn { width: 40px; height: 40px; min-width: 40px; min-height: 40px; }
    .st-chat-input-wrapper { margin: 8px 16px; }
    .st-chat-msg-reply-ref { padding: 12px 16px; }
    .st-chat-reply-preview { padding: 12px 56px 12px 18px; }
}
@supports (padding-bottom: env(safe-area-inset-bottom)) {
    .st-chat-input-area {
        padding-bottom: env(safe-area-inset-bottom);
    }
}
@media (prefers-reduced-motion: reduce) {
    .st-chat-msg,
    .st-chat-msg.st-chat-msg-new,
    .st-chat-date-separator,
    .st-chat-empty-icon,
    .st-chat-loading-spinner,
    .st-chat-msg-new .st-chat-msg-reply-ref,
    .st-chat-msg-reply-ref-name::before {
        animation: none !important;
    }
    .st-typing-dots span {
        animation: none !important;
        opacity: 0.6;
    }
    .st-chat-msg-reply-ref:hover {
        transform: none;
    }
}