/* Chatbot Modal Stilleri */
#chatbotModal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99999;
    backdrop-filter: blur(5px);
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

#chatbotModal.show {
    display: flex !important;
    align-items: center;
    justify-content: center;
}

.chatbot-modal-content {
    background: #fff;
    width: 95%;
    max-width: 900px;
    height: 85vh;
    max-height: 700px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    animation: slideUp 0.4s ease;
    position: relative;
    overflow: hidden;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chatbot-header {
    background: url(../bot.jpg) no-repeat center center;
    background-size: cover;
    color: #fff;
    padding: 20px 25px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-radius: 20px 20px 0 0;
}

.chatbot-header-content {
    display: flex;
    align-items: center;
    gap: 15px;
}

.chatbot-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.chatbot-avatar img {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

.chatbot-title h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.chatbot-title p {
    margin: 0;
    font-size: 13px;
    opacity: 0.9;
}

.chatbot-close {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    width: 35px;
    height: 35px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-size: 20px;
}

.chatbot-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.chatbot-body {
    flex: 1;
    overflow-y: auto;
    padding: 25px;
    background: #f8f9fa;
    display: flex;
    flex-direction: column;
}

.chatbot-messages {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.chatbot-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    text-align: center;
    color: #6c757d;
    padding: 40px 20px;
}

.chatbot-empty-state .icon {
    font-size: 60px;
    margin-bottom: 20px;
    opacity: 0.3;
}

.chatbot-empty-state h4 {
    font-size: 20px;
    margin-bottom: 10px;
    color: #495057;
}

.chatbot-empty-state p {
    font-size: 14px;
    opacity: 0.7;
    max-width: 400px;
}

.chatbot-message {
    display: flex;
    gap: 12px;
    max-width: 80%;
    animation: messageSlide 0.3s ease;
}

@keyframes messageSlide {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chatbot-message.user {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.chatbot-message-avatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.chatbot-message.bot .chatbot-message-avatar {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
}

.chatbot-message.user .chatbot-message-avatar {
    background: #28a745;
    color: #fff;
}

.chatbot-message-content {
    flex: 1;
}

.chatbot-message-bubble {
    padding: 12px 16px;
    border-radius: 15px;
    font-size: 14px;
    line-height: 1.6;
    word-wrap: break-word;
}

.chatbot-message.bot .chatbot-message-bubble {
    background: #fff;
    color: #333;
    border: 1px solid #e9ecef;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
}

.chatbot-message.user .chatbot-message-bubble {
    background: #1aaf85;
    color: #fff;
}

.chatbot-message-time {
    font-size: 11px;
    color: #6c757d;
    margin-top: 5px;
    opacity: 0.7;
}

.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 12px 16px;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6c757d;
    animation: typing 1.4s infinite;
}

.typing-indicator span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typing {
    0%, 60%, 100% {
        opacity: 0.3;
        transform: translateY(0);
    }
    30% {
        opacity: 1;
        transform: translateY(-8px);
    }
}

.chatbot-footer {
    padding: 20px 25px;
    background: #fff;
    border-top: 1px solid #e9ecef;
    border-radius: 0 0 20px 20px;
}

.chatbot-input-container {
    display: flex;
    gap: 10px;
    align-items: flex-end;
}

.chatbot-textarea-wrapper {
    flex: 1;
    position: relative;
}

.chatbot-textarea {
    width: 100%;
    min-height: 45px;
    max-height: 120px;
    padding: 12px 45px 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    font-size: 14px;
    font-family: inherit;
    resize: none;
    transition: all 0.3s ease;
    overflow-y: auto;
}

.chatbot-textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.chatbot-char-count {
    position: absolute;
    bottom: 8px;
    right: 12px;
    font-size: 11px;
    color: #6c757d;
    pointer-events: none;
}

.chatbot-char-count.warning {
    color: #ffc107;
}

.chatbot-char-count.error {
    color: #dc3545;
}

.chatbot-send-btn {
    background: #1aaf85;
    border: none;
    color: #fff;
    width: 45px;
    height: 45px;
    border-radius: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.chatbot-send-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.chatbot-send-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.chatbot-send-btn i {
    font-size: 20px;
}

.chatbot-error {
    padding: 15px;
    background: #fff3cd;
    border: 1px solid #ffc107;
    border-radius: 10px;
    color: #856404;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.chatbot-error i {
    font-size: 20px;
}

.chatbot-body::-webkit-scrollbar,
.chatbot-textarea::-webkit-scrollbar {
    width: 6px;
}

.chatbot-body::-webkit-scrollbar-track,
.chatbot-textarea::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.chatbot-body::-webkit-scrollbar-thumb,
.chatbot-textarea::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 10px;
}

.chatbot-body::-webkit-scrollbar-thumb:hover,
.chatbot-textarea::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

@media (max-width: 768px) {
    .chatbot-modal-content {
        width: 100%;
        height: 100%;
        max-height: 100vh;
        border-radius: 0;
    }

    .chatbot-header {
        border-radius: 0;
    }

    .chatbot-footer {
        border-radius: 0;
    }

    .chatbot-message {
        max-width: 90%;
    }
}


