/* ============================================================
   FILE: css/pages/chatbot.css
   Mục đích: Styling cho Chatbot Lập kế hoạch Tuần
   ============================================================ */

/* Container chính */
.chatbot-weekly-container {
    max-width: 100%;
}

/* Header với gradient */
.chatbot-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%);
    border-radius: 16px;
    padding: 25px;
    margin-bottom: 20px;
    color: white;
}

.chatbot-header-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.chatbot-header-title span {
    font-size: 2rem;
}

.chatbot-header-title h2 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 700;
}

.chatbot-header-desc {
    opacity: 0.9;
    font-size: 0.9rem;
    margin: 0;
}

/* Input area */
.chatbot-input-area {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.chatbot-textarea {
    width: 100%;
    min-height: 200px;
    padding: 15px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    font-size: 1rem;
    line-height: 1.6;
    resize: vertical;
    transition: border-color 0.3s ease;
    font-family: inherit;
    box-sizing: border-box;
}

.chatbot-textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.chatbot-textarea::placeholder {
    color: #9ca3af;
}

/* Action buttons */
.chatbot-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.chatbot-btn {
    padding: 12px 24px;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chatbot-btn-primary {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.chatbot-btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.chatbot-btn-secondary {
    background: #f1f5f9;
    color: #64748b;
}

.chatbot-btn-secondary:hover {
    background: #e2e8f0;
}

.chatbot-btn-success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.chatbot-btn-success:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
}

.chatbot-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

/* Result container */
.chatbot-result-container {
    background: var(--card-bg);
    border-radius: 16px;
    padding: 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    display: none;
}

.chatbot-result-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.chatbot-result-header h3 {
    margin: 0;
    font-size: 1.1rem;
    color: #1e293b;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chatbot-selected-count {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

/* Result table */
.chatbot-result-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.chatbot-result-table thead {
    background: linear-gradient(135deg, #f8fafc, #f1f5f9);
}

.chatbot-result-table th {
    padding: 12px 10px;
    text-align: left;
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
    border-bottom: 2px solid #e2e8f0;
}

.chatbot-result-table td {
    padding: 12px 10px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: middle;
}

.chatbot-result-table tbody tr:hover {
    background: #fafafa;
}

.chatbot-result-table input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
    accent-color: #667eea;
}

/* Tips section */
.chatbot-tips {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border-radius: 12px;
    padding: 15px 20px;
    margin-top: 20px;
}

.chatbot-tips h4 {
    margin: 0 0 10px;
    color: #92400e;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.chatbot-tips ul {
    margin: 0;
    padding-left: 20px;
    color: #78350f;
    font-size: 0.9rem;
}

.chatbot-tips li {
    margin-bottom: 5px;
}

/* Responsive */
@media (max-width: 768px) {
    .chatbot-header {
        padding: 20px;
    }

    .chatbot-header-title h2 {
        font-size: 1.2rem;
    }

    .chatbot-textarea {
        min-height: 150px;
    }

    .chatbot-actions {
        flex-direction: column;
    }

    .chatbot-btn {
        width: 100%;
        justify-content: center;
    }

    .chatbot-result-table {
        font-size: 0.85rem;
    }

    .chatbot-result-table th,
    .chatbot-result-table td {
        padding: 8px 5px;
    }
}

/* ============================================================
   CONFLICT WARNING - Time Overlap Detection
   ============================================================ */

.conflict-warning {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 2px solid #f59e0b;
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 16px;
    animation: warningSlideIn 0.3s ease-out;
}

@keyframes warningSlideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.conflict-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.conflict-header span {
    font-weight: 700;
    color: #92400e;
    font-size: 0.95rem;
}

.conflict-dismiss {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #92400e;
    cursor: pointer;
    padding: 0 5px;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.conflict-dismiss:hover {
    opacity: 1;
}

.conflict-list {
    margin: 0;
    padding-left: 20px;
    color: #78350f;
    font-size: 0.85rem;
}

.conflict-list li {
    margin-bottom: 6px;
    line-height: 1.5;
}

.conflict-list strong {
    color: #92400e;
}