#galaxy-chat-widget {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 9999;
    font-family: Tahoma, sans-serif;
    direction: rtl;
}

#galaxy-chat-toggle {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    background: linear-gradient(135deg, #1a0533, #6a0dad);
    border: none;
    cursor: pointer;
    font-size: 24px;
    box-shadow: 0 0 15px rgba(138, 43, 226, 0.7);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 15px rgba(138, 43, 226, 0.7); }
    50%       { box-shadow: 0 0 30px rgba(138, 43, 226, 1); }
}

#galaxy-chat-box {
    width: 320px;
    height: 420px;
    background: linear-gradient(180deg, #0d0020 0%, #1a0533 100%);
    border: 1px solid #6a0dad;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 0 25px rgba(138, 43, 226, 0.5);
    position: relative;
}

#galaxy-chat-box::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(1px 1px at 20% 30%, white, transparent),
        radial-gradient(1px 1px at 60% 70%, white, transparent),
        radial-gradient(1px 1px at 80% 20%, white, transparent),
        radial-gradient(1px 1px at 40% 80%, white, transparent),
        radial-gradient(1px 1px at 90% 50%, white, transparent);
    opacity: 0.3;
    pointer-events: none;
}

#galaxy-chat-header {
    background: linear-gradient(90deg, #2d0057, #6a0dad);
    color: #e0b3ff;
    padding: 12px 16px;
    font-weight: bold;
    font-size: 14px;
    text-align: center;
}

#galaxy-chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

#galaxy-chat-messages::-webkit-scrollbar { width: 4px; }
#galaxy-chat-messages::-webkit-scrollbar-track { background: transparent; }
#galaxy-chat-messages::-webkit-scrollbar-thumb { background: #6a0dad; border-radius: 2px; }

.galaxy-msg {
    max-width: 80%;
    padding: 8px 12px;
    border-radius: 10px;
    font-size: 13px;
    line-height: 1.5;
    word-break: break-word;
}

.galaxy-msg.user {
    background: #3d0080;
    color: #f0d9ff;
    align-self: flex-end;border-bottom-right-radius: 2px;
}

.galaxy-msg.bot {
    background: rgba(255,255,255,0.08);
    color: #ddd;
    align-self: flex-start;
    border: 1px solid rgba(138,43,226,0.3);border-bottom-left-radius: 2px;
}

#galaxy-chat-input-area {
    display: flex;
    padding: 10px;
    gap: 6px;
    border-top: 1px solid rgba(106,13,173,0.4);
    background: rgba(0,0,0,0.3);
}

#galaxy-chat-input {
    flex: 1;
    background: rgba(255,255,255,0.07);
    border: 1px solid #6a0dad;
    border-radius: 6px;
    color: #fff;
    padding: 7px 10px;
    font-size: 13px;
    outline: none;
    direction: rtl;
}

#galaxy-chat-input::placeholder { color: #9b6fc7; }

#galaxy-chat-send {
    background: linear-gradient(135deg, #4a0090, #8a2be2);
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 7px 14px;
    cursor: pointer;
    font-size: 13px;
    transition: opacity 0.2s;
}

#galaxy-chat-send:hover { opacity: 0.85; }

@media (max-width: 400px) {
    #galaxy-chat-box { width: 280px; height: 380px; }
}
