/* --- NUEVA ESTÉTICA PREMIUM CHAT --- */
.card-chat {
    display: flex;
    flex-direction: column;
    padding: 0 !important;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.7) !important;
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 10px 30px rgba(0,0,0,0.1) !important;
}

body.night-mode .card-chat {
    background: rgba(30, 41, 59, 0.7) !important;
    border-color: rgba(255, 255, 255, 0.1);
}

.chat-header-modern {
    background: linear-gradient(135deg, #0066FF, #7B1FA2);
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
}

.chat-header-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 0.9rem;
    letter-spacing: 0.5px;
}

.chat-header-id {
    font-size: 0.7rem;
    opacity: 0.6;
    background: rgba(0,0,0,0.2);
    padding: 2px 8px;
    border-radius: 10px;
}

.chat-messages-container {
    height: 300px;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: rgba(255,255,255,0.3);
}

body.night-mode .chat-messages-container {
    background: rgba(0,0,0,0.1);
}

.chat-line {
    display: flex;
    gap: 12px;
    align-items: flex-end;
    animation: chatMsgPop 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) both;
}

@keyframes chatMsgPop {
    from { opacity: 0; transform: translateY(15px) scale(0.95); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.8rem;
    flex-shrink: 0;
    box-shadow: 0 3px 6px rgba(0,0,0,0.15);
}

.chat-bubble {
    background: var(--chat-color);
    padding: 10px 15px;
    border-radius: 18px 18px 18px 4px;
    border-left: 4px solid var(--chat-border);
    max-width: 85%;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.chat-text {
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 1.4;
    color: #1e293b;
}

body.night-mode .chat-text {
    color: #1e293b;
}

.chat-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #94a3b8;
    text-align: center;
}

.chat-empty-state i {
    font-size: 2.5rem;
    margin-bottom: 15px;
    opacity: 0.3;
}

.chat-input-modern {
    padding: 12px 15px;
    background: rgba(255,255,255,0.2);
    border-top: 1px solid rgba(0,0,0,0.05);
    box-sizing: border-box;
    width: 100%;
}

.input-wrapper {
    display: flex;
    gap: 10px;
    width: 100%;
    box-sizing: border-box;
    background: white;
    padding: 5px 5px 5px 15px;
    align-items: center;
    border-radius: 25px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.05);
    border: 1px solid rgba(0,0,0,0.05);
    transition: all 0.3s;
}

body.night-mode .input-wrapper {
    background: rgba(255, 255, 255, 0.9);
    border-color: rgba(255,255,255,0.1);
}

.input-wrapper:focus-within {
    box-shadow: 0 4px 15px rgba(0,102,255,0.15);
    border-color: #0066FF;
}

.input-wrapper input {
    flex-grow: 1;
    border: none;
    background: transparent;
    outline: none;
    font-family: inherit;
    font-size: 0.9rem;
    color: inherit;
    min-width: 0;
    width: 100%;
}

.btn-send-modern {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0066FF, #00CCFF);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s;
    box-shadow: 0 3px 8px rgba(0,102,255,0.3);
    flex-shrink: 0;
}

.btn-send-modern:hover {
    transform: scale(1.1) rotate(-10deg);
    box-shadow: 0 5px 12px rgba(0,102,255,0.4);
}

.btn-send-modern:active {
    transform: scale(0.95);
}
