/* Chatbot Styles for Vishal's Portfolio - Enhanced Professional Look */

@keyframes pulse {
    0% { transform: scale(1); box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); }
    50% { transform: scale(1.05); box-shadow: 0 6px 12px rgba(0, 0, 0, 0.3); }
    100% { transform: scale(1); box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.chatbot-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    font-family: 'Poppins', sans-serif;
    transition: all 0.3s ease;
}

.chatbot-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(145deg, #0078d4, #00a2ff); /* Gradient background */
    color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 120, 212, 0.4);
    transition: all 0.3s ease;
    animation: pulse 2s infinite ease-in-out;
}

.chatbot-toggle i {
    font-size: 24px;
    filter: drop-shadow(0 2px 3px rgba(0, 0, 0, 0.2));
}

.chatbot-toggle:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 20px rgba(0, 120, 212, 0.5);
}

.chatbot-box {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 350px;
    height: 500px;
    background-color: white;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.25);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    border: 1px solid rgba(0, 120, 212, 0.2);
}

.chatbot-container.active .chatbot-box {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    animation: fadeIn 0.5s ease-out;
}

.chatbot-header {
    background: linear-gradient(145deg, #0078d4, #00a2ff); /* Matching gradient */
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.chatbot-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 500;
}

.chatbot-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.chatbot-lang-toggle {
    background-color: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    border-radius: 4px;
    padding: 4px 8px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.chatbot-lang-toggle:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.chatbot-close {
    font-size: 24px;
    cursor: pointer;
}

.chatbot-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background-color: #f8f9fa;
    background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI1IiBoZWlnaHQ9IjUiPgo8cmVjdCB3aWR0aD0iNSIgaGVpZ2h0PSI1IiBmaWxsPSIjZmZmIj48L3JlY3Q+CjxyZWN0IHdpZHRoPSIxIiBoZWlnaHQ9IjEiIGZpbGw9IiNmMGYwZjAiPjwvcmVjdD4KPC9zdmc+');
}

.chatbot-message {
    margin-bottom: 15px;
    display: flex;
    flex-direction: column;
}

.chatbot-message.user {
    align-items: flex-end;
}

.chatbot-message.bot {
    align-items: flex-start;
}

.message-content {
    max-width: 80%;
    padding: 10px 15px;
    border-radius: 18px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
    word-wrap: break-word;
    line-height: 1.4;
}

.chatbot-message.user .message-content {
    background: linear-gradient(145deg, #0078d4, #00a2ff); /* Gradient matching toggle button */
    color: white;
    border-bottom-right-radius: 5px;
    font-size: 14px;
    box-shadow: 0 2px 5px rgba(0, 120, 212, 0.3);
    transform: translateX(0);
    transition: transform 0.3s ease;
}

.chatbot-message.user .message-content:hover {
    transform: translateX(-5px);
}

.chatbot-message.bot .message-content {
    background: linear-gradient(145deg, #f8f9fa, #ffffff); /* Subtle gradient for bot messages */
    color: #333;
    border-bottom-left-radius: 5px;
    font-size: 14px;
    border-left: 3px solid #0078d4; /* Blue accent border */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transform: translateX(0);
    transition: transform 0.3s ease;
}

.chatbot-message.bot .message-content:hover {
    transform: translateX(5px);
}

.chatbot-suggestions {
    padding: 10px 15px;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    background-color: #f0f0f0;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.suggestion-btn {
    background-color: white;
    color: #0078d4; /* Microsoft blue */
    border: 1px solid #0078d4;
    border-radius: 20px; /* Rounded for modern look */
    padding: 8px 15px;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.suggestion-btn:hover {
    background: linear-gradient(145deg, #0078d4, #00a2ff);
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 120, 212, 0.3);
}

.chatbot-input-container {
    display: flex;
    padding: 10px;
    background-color: white;
    border-top: 1px solid #eee;
}

.chatbot-input {
    flex: 1;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 20px;
    outline: none;
    font-family: 'Poppins', sans-serif;
}

.chatbot-input:focus {
    border-color: var(--primary-color);
}

.chatbot-send {
    width: 40px;
    height: 40px;
    border-radius: 50%; /* Circular for modern look */
    background: linear-gradient(145deg, #0078d4, #00a2ff); /* Gradient background */
    color: white;
    border: none;
    margin-left: 10px;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 120, 212, 0.3);
}

.chatbot-send:hover {
    transform: rotate(15deg) scale(1.1);
    box-shadow: 0 4px 12px rgba(0, 120, 212, 0.4);
}

/* Responsive Styles */
@media screen and (max-width: 480px) {
    .chatbot-box {
        width: 300px;
        height: 450px;
        bottom: 70px;
    }
    
    .chatbot-toggle {
        width: 50px;
        height: 50px;
    }
    
    .chatbot-toggle i {
        font-size: 20px;
    }
}