.chat-widget {
    position: fixed;
    bottom: 100px;
    right: 30px;
    width: 350px;
    height: 500px;
    background: var(--white);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transform: translateY(20px);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.chat-widget.open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
}

.chat-header {
    background: linear-gradient(135deg, var(--secondary-color) 0%, #2c6a83 100%);
    color: var(--white);
    padding: 1.2rem;
    border-radius: 15px 15px 0 0;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.chat-avatar {
    width: 40px;
    height: 40px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
}

.chat-info h4 {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
}

.status {
    font-size: 0.8rem;
    opacity: 0.9;
}

.status.online::before {
    content: '';
    display: inline-block;
    width: 8px;
    height: 8px;
    background: var(--success-color);
    border-radius: 50%;
    margin-right: 5px;
}

.chat-toggle {
    background: none;
    border: none;
    color: var(--white);
    cursor: pointer;
    margin-left: auto;
    font-size: 1.1rem;
}

.chat-body {
    flex: 1;
    padding: 1rem;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.chat-message {
    max-width: 80%;
    padding: 0.8rem 1rem;
    border-radius: 15px;
    position: relative;
    animation: messageAppear 0.3s ease;
}

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

.bot-message {
    background: var(--light-color);
    align-self: flex-start;
    border-bottom-left-radius: 5px;
}

.user-message {
    background: var(--primary-color);
    color: var(--white);
    align-self: flex-end;
    border-bottom-right-radius: 5px;
}

.message-time {
    font-size: 0.7rem;
    opacity: 0.7;
    margin-top: 5px;
    display: block;
}

.chat-footer {
    padding: 1rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
}

.chat-input-container {
    display: flex;
    gap: 0.5rem;
}

.chat-input {
    flex: 1;
    padding: 0.8rem 1rem;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 25px;
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.3s ease;
}

.chat-input:focus {
    border-color: var(--primary-color);
}

.chat-send {
    background: var(--primary-color);
    color: var(--white);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.chat-send:hover {
    background: var(--secondary-color);
    transform: scale(1.05);
}

.chat-launcher {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color) 0%, #ff7b4a 100%);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 5px 20px rgba(238, 94, 49, 0.4);
    z-index: 999;
    transition: all 0.3s ease;
    animation: pulse 2s infinite;
}

.chat-launcher:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 25px rgba(238, 94, 49, 0.6);
}

@media (max-width: 768px) {
    .chat-widget {
        width: calc(100vw - 40px);
        height: 70vh;
        right: 20px;
        bottom: 80px;
    }
    
    .chat-launcher {
        bottom: 20px;
        right: 20px;
        width: 50px;
        height: 50px;
        font-size: 1.3rem;
    }
}