/* ─── CHATBOX COMPONENT ─────────────────────────────── */

.wa-floating {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-decoration: none;
    z-index: 9998;
    box-shadow: 0 10px 30px rgba(238, 0, 0, 0.4);
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.wa-floating:hover {
    transform: scale(1.1) rotate(8deg);
    box-shadow: 0 15px 40px rgba(238, 0, 0, 0.6);
}

.wa-floating i {
    width: 28px;
    height: 28px;
}

.chatbox-container {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 350px;
    height: 500px;
    background: rgba(10, 10, 10, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: 24px;
    display: none;
    flex-direction: column;
    z-index: 9999;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.8);
    overflow: hidden;
    transform: translateY(30px);
    opacity: 0;
    transition: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.chatbox-container.show {
    display: flex;
    transform: translateY(0);
    opacity: 1;
}

.chatbox-header {
    background: linear-gradient(135deg, var(--primary), #880000);
    padding: 20px 25px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #fff;
}

.chatbox-header-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chatbox-header h4 {
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 0.5px;
}

.chatbox-header small {
    font-size: 11px;
    opacity: 0.8;
    display: block;
}

.status-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    background: #00ff66;
    border-radius: 50%;
    margin-right: 6px;
    box-shadow: 0 0 10px #00ff66;
}

.chatbox-close {
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: #fff;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

.chatbox-close:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: rotate(90deg);
}

.chatbox-messages {
    flex: 1;
    padding: 25px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background-image: radial-gradient(var(--border) 1px, transparent 1px);
    background-size: 20px 20px;
}

.chat-msg {
    max-width: 85%;
    padding: 12px 18px;
    border-radius: 16px;
    font-size: 13px;
    line-height: 1.6;
    animation: slideInChat 0.3s ease forwards;
}

@keyframes slideInChat {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-msg.user {
    align-self: flex-end;
    background: var(--primary);
    color: #fff;
    border-bottom-right-radius: 4px;
    box-shadow: 0 5px 15px rgba(238, 0, 0, 0.2);
}

.chat-msg.admin {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    border-bottom-left-radius: 4px;
    border: 1px solid var(--border);
}

.chatbox-input {
    padding: 20px;
    background: rgba(0, 0, 0, 0.3);
    border-top: 1px solid var(--border);
    display: flex;
    gap: 12px;
}

.chatbox-input input {
    flex: 1;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 12px 18px;
    color: #fff;
    font-size: 14px;
    outline: none;
    transition: 0.3s;
}

.chatbox-input input:focus {
    border-color: var(--primary);
    background: rgba(255, 255, 255, 0.05);
}

.chatbox-input button {
    background: var(--primary);
    color: #fff;
    border: none;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
    box-shadow: 0 5px 15px rgba(238, 0, 0, 0.3);
}

.chatbox-input button:hover {
    background: #cc0000;
    transform: scale(1.05);
}
