/* Chatbot Widget Styles */
#chatbot-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 9999;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
}

#chatbot-toggle {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    border-radius: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    padding: 12px 20px;
    color: white;
    font-weight: 600;
    font-size: 15px;
}

#chatbot-toggle svg {
    flex-shrink: 0;
}

#chatbot-toggle span {
    white-space: nowrap;
}

#chatbot-toggle:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

#chatbot-container {
    position: absolute;
    bottom: 80px;
    right: 0;
    width: 380px;
    max-width: calc(100vw - 40px);
    height: 600px;
    max-height: calc(100vh - 120px);
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#chatbot-header {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

#chatbot-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

#chatbot-close {
    background: none;
    border: none;
    color: white;
    font-size: 28px;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    line-height: 1;
    opacity: 0.8;
    transition: opacity 0.2s;
}

#chatbot-close:hover {
    opacity: 1;
}

#chatbot-messages {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    background: #f7f8fa;
}

.chatbot-message {
    margin-bottom: 16px;
    display: flex;
    flex-direction: column;
}

.chatbot-message.user {
    align-items: flex-end;
}

.chatbot-message.bot {
    align-items: flex-start;
}

.message-bubble {
    max-width: 75%;
    padding: 12px 16px;
    border-radius: 18px;
    word-wrap: break-word;
    animation: fadeIn 0.3s ease;
}

.chatbot-message.user .message-bubble {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border-bottom-right-radius: 4px;
}

.chatbot-message.bot .message-bubble {
    background: white;
    color: #333;
    border-bottom-left-radius: 4px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

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

.message-time {
    font-size: 11px;
    color: #999;
    margin-top: 4px;
    padding: 0 4px;
}

.message-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 4px;
}

.feedback-btn {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    opacity: 0.5;
    transition: opacity 0.2s, transform 0.2s;
    padding: 2px 6px;
}

.feedback-btn:hover {
    opacity: 1;
    transform: scale(1.2);
}

.feedback-btn.disabled {
    cursor: not-allowed;
    opacity: 0.3;
}

.feedback-btn.selected-up {
    opacity: 1;
    animation: pulse 0.5s;
}

.feedback-btn.selected-down {
    opacity: 1;
    animation: pulse 0.5s;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.3); }
}

#chatbot-input-area {
    display: flex;
    padding: 15px;
    background: white;
    border-top: 1px solid #e5e7eb;
}

#chatbot-input {
    flex: 1;
    border: 1px solid #e5e7eb;
    border-radius: 24px;
    padding: 12px 16px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s;
}

#chatbot-input:focus {
    border-color: #f59e0b;
}

#chatbot-send {
    margin-left: 8px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border: none;
    border-radius: 24px;
    padding: 12px 24px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.2s, box-shadow 0.2s;
}

#chatbot-send:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(245, 158, 11, 0.3);
}

#chatbot-send:active {
    transform: translateY(0);
}

#chatbot-actions {
    padding: 12px 15px;
    background: white;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 8px;
}

.chatbot-action-btn {
    flex: 1;
    background: #276b04;
    color: white;
    border: 1px solid #1f5503;
    border-radius: 8px;
    padding: 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, border-color 0.2s, transform 0.2s;
}

.chatbot-action-btn:hover {
    background: #1f5503;
    border-color: #174102;
    transform: translateY(-1px);
}

.chatbot-action-btn:active {
    transform: translateY(0);
}

/* Booking Form and Contact Form Styles */
.booking-form,
.contact-form {
    padding: 16px;
    background: white;
    border-radius: 8px;
    margin-top: 8px;
}

.booking-form input,
.booking-form select,
.booking-form textarea,
.contact-form input,
.contact-form select,
.contact-form textarea {
    width: 100%;
    padding: 10px;
    margin: 8px 0;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    font-size: 14px;
    box-sizing: border-box;
}

.booking-form input[type="checkbox"],
.contact-form input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.booking-form label,
.contact-form label {
    display: block;
    margin-top: 8px;
    font-weight: 500;
    color: #374151;
    font-size: 13px;
}

.booking-form button,
.contact-form button {
    width: 100%;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px;
    margin-top: 12px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.2s;
}

.booking-form button:hover,
.contact-form button:hover {
    transform: translateY(-1px);
}

/* Typing indicator */
.typing-indicator {
    display: flex;
    gap: 4px;
    padding: 12px 16px;
}

.typing-indicator span {
    width: 8px;
    height: 8px;
    background: #999;
    border-radius: 50%;
    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% {
        transform: translateY(0);
        opacity: 0.7;
    }
    30% {
        transform: translateY(-10px);
        opacity: 1;
    }
}

/* Mobile responsive */
@media (max-width: 768px) {
    #chatbot-widget {
        bottom: 10px;
        right: 10px;
    }
    
    #chatbot-toggle {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    #chatbot-container {
        width: calc(100vw - 20px);
        height: calc(100vh - 80px);
        bottom: 70px;
        right: -10px;
        max-width: none;
        max-height: none;
        border-radius: 12px 12px 0 0;
    }
    
    #chatbot-messages {
        padding: 15px;
    }
    
    .chatbot-action-btn {
        font-size: 12px;
        padding: 8px;
    }
}

@media (max-width: 480px) {
    #chatbot-toggle {
        padding: 10px 14px;
        font-size: 13px;
        gap: 6px;
    }
    
    #chatbot-toggle svg {
        width: 20px;
        height: 20px;
    }
    
    #chatbot-container {
        width: 100vw;
        height: calc(100vh - 60px);
        bottom: 60px;
        right: 0;
        border-radius: 12px 12px 0 0;
    }
    
    #chatbot-header {
        padding: 15px;
    }
    
    #chatbot-header h3 {
        font-size: 16px;
    }
    
    #chatbot-messages {
        padding: 12px;
    }
    
    .message-bubble {
        max-width: 85%;
        font-size: 14px;
    }
    
    #chatbot-input-area {
        padding: 10px;
    }
    
    #chatbot-input {
        font-size: 16px; /* Prevents zoom on iOS */
        padding: 10px 14px;
    }
    
    #chatbot-send {
        padding: 10px 18px;
        font-size: 14px;
    }
    
    #chatbot-actions {
        padding: 8px 10px;
        gap: 6px;
    }
    
    .chatbot-action-btn {
        font-size: 11px;
        padding: 8px 6px;
    }
    
    .booking-form,
    .contact-form {
        padding: 12px;
    }
    
    .booking-form input,
    .booking-form select,
    .booking-form textarea,
    .contact-form input,
    .contact-form select,
    .contact-form textarea {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    .booking-form input[type="checkbox"],
    .contact-form input[type="checkbox"] {
        width: auto;
        transform: scale(1.2); /* Make checkboxes easier to tap on mobile */
    }
}