.was-validated .group-input .input-element:has(input:valid) {
    border: solid 1px #439f6e !important;
}

.was-validated .group-input .input-element:has(input:invalid) {
    border: solid 1px #f93232 !important;
}

.border-red-700 {
    border: solid 1px #f93232 !important;
}

.border-gray-200 {
    border-color: var(--color-gray-200) !important;
}

.border-green-500 {
    border-color: #10b981 !important;
}

.checkmark-container {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 1.5rem;
    height: 1.5rem;
    background-color: #10b981;
    /* Tailwind green-500 */
    border-radius: 9999px;
    /* Fully rounded */
    display: flex;
    align-items: center;
    justify-content: center;
}

.checkmark {
    color: white;
    font-size: 1rem;
    line-height: 1;
}

.relative-container {
    position: relative;
    display: inline-block;
}

.modal-backdrop {
    background-color: rgba(51, 50, 50, 0.8);
    /* Thay đổi màu nền và độ trong suốt */
}

.bg-yellow-600\/10 {
    background-color: color-mix(in oklab, var(--color-yellow-600) 10%, transparent)
}

.gradient-bg {
    background: linear-gradient(to right, #059669, #0d9488);
}

/* CSS cho hình ảnh */
.vps-image {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    object-fit: cover;
    /* Đảm bảo ảnh không bị méo */
}

.vps-image:hover {
    transform: scale(1.05);
    /* Phóng to nhẹ khi hover */
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    /* Tăng shadow khi hover */
}

.banner-image {
    border-radius: 12px;
    /* Bo góc nhẹ */
    border: 2px solid rgba(255, 255, 255, 0.2);
    /* Viền trắng mờ */
    padding: 8px;
    /* Khoảng cách viền */
    background: rgba(255, 255, 255, 0.1);
    /* Nền mờ nhẹ */
}

.benefits-image {
    border-radius: 16px;
    /* Bo góc lớn hơn cho phần lợi ích */
    border: 3px solid #059669;
    /* Viền xanh green-600 */
}

/* Gradient background (nếu không dùng Tailwind) */
.gradient-bg {
    background: linear-gradient(to right, #059669, #0d9488);
}

.gradient-bg {
    background: linear-gradient(to right, #059669, #0d9488);
    position: relative;
    overflow: hidden;
    border-radius: 0.5rem;
    box-shadow: 0 10px 15px rgba(0, 0, 0, 0.1);
}

/* Slider container */
.slider-container {
    position: relative;
    width: 100%;
    height: 200px;
    /* Đặt chiều cao cố định 300px */
    overflow: hidden;
}

/* Slide styles */
.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 0.5s ease-in-out;
    padding: 1.5rem;
    /* Padding vừa phải để nội dung không sát mép */
    display: flex;
    /* Sử dụng flex để căn chỉnh nội dung */
    align-items: center;
    /* Căn giữa theo chiều dọc */
}

.slide.active {
    opacity: 1;
}

/* Hiệu ứng vòng tròn trang trí */
.gradient-bg::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -10%;
    width: 250px;
    height: 250px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2), transparent);
    border-radius: 50%;
    opacity: 0.5;
    z-index: 0;
}

.gradient-bg::after {
    content: '';
    position: absolute;
    bottom: -20%;
    left: -5%;
    width: 180px;
    height: 180px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15), transparent);
    border-radius: 50%;
    opacity: 0.4;
    z-index: 0;
}

.slider-container>* {
    position: relative;
    z-index: 1;
}

/* Nút điều hướng */
.slider-nav {
    position: absolute;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 2;
}

.slider-dot {
    width: 12px;
    height: 12px;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s;
}

.slider-dot.active {
    background: white;
}

/* Button hover effect */
.btn-custom {
    transition: all 0.3s ease;
}

.btn-custom:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

/* Styles cho danh sách chuyên mục */
.category-item {
    margin-top: 1rem;
    /* mt-4 */
}

.category-icon {
    width: 150px;
    /* Cố định chiều rộng ảnh thành 64px (h-16) */
    height: auto;
    /* Giữ chiều cao tự động để giữ tỷ lệ */
    border-radius: 0.375rem;
    /* rounded-md */
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    /* shadow-sm */
    object-fit: cover;
    /* Đảm bảo hình ảnh không bị méo, cắt gọn nếu cần */
}

.category-icon.lazyload {
    opacity: 0;
    /* Ẩn ảnh khi chưa load xong */
    transition: opacity 0.3s ease-in-out;
    /* Hiệu ứng fade khi load */
}

.category-icon.lazyload.loaded {
    opacity: 1;
    /* Hiển thị khi đã load */
}

/* Dark mode */
.dark .category-icon {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.3);
    /* dark:shadow-gray-800 */
}

/* Styles cho phần discount */
.discount-badge {
    top: 0.5rem;
    left: 0.5rem;
    background: #e0f2fe;
    /* bg-sky-100 */
    color: #0284c7;
    /* text-sky-600 */
    padding: 0.25rem 0.5rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    /* text-xs */
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    border: 1px solid #bae6fd;
    /* border-sky-200 */
}

.discount-badge span.save {
    font-weight: bold;
}

.discount-badge span.amount {
    text-decoration: line-through;
    color: #4a5568;
    /* text-gray-600 */
}

.discount-badge:hover {
    background: #bfdbfe;
    /* sky-200 */
    color: #075985;
    /* sky-700 */
}

.bg-gray-100 {
    background-color: #f3f4f6;
}

.bg-white {
    background-color: #ffffff;
}

.text-gray-700 {
    color: #374151;
}

.text-green-600 {
    color: #16a34a;
}

.hover:bg-green-100:hover {
    background-color: #d1fae5;
}

.hover:text-green-600:hover {
    color: #16a34a;
}

.rounded-lg {
    border-radius: 0.5rem;
}

.shadow-md {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.transition {
    transition-property: background-color, color;
    transition-duration: 300ms;
}

.px-4 {
    padding-left: 1rem;
    padding-right: 1rem;
}

.py-2 {
    padding-top: 0.5rem;
    padding-bottom: 0.5rem;
}

.gradient-bg {
    background: linear-gradient(to right, #9333ea, #a855f7);
}

.layout-specing {
    padding: 20px 0;
}

.bg-gray-100 {
    background-color: #f3f4f6;
}

.text-green-600 {
    color: #16a34a;
}

.bg-purple-500 {
    background-color: #9333ea;
}

.bg-purple-600 {
    background-color: #7e22ce;
}

.shadow-md {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.w-12 {
    width: 2rem;
    /* 48px */
}

.h-12 {
    height: 2rem;
    /* 48px */
}

/* Tùy chỉnh thêm nếu cần */
.layout-specing {
    padding: 20px 0;
}

.bg-gray-100 {
    background-color: #f3f4f6;
}

.text-green-500 {
    color: #22c55e;
}

.text-yellow-500 {
    color: #f59e0b;
}

.bg-blue-600 {
    background-color: #2563eb;
}

.bg-blue-700 {
    background-color: #1d4ed8;
}

.hover:bg-blue-700:hover {
    background-color: #1d4ed8;
}

.hover:bg-gray-200:hover {
    background-color: #e5e7eb;
}

.shadow-md {
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

#loading-spinner {
    z-index: 10;
}

.animate-pulse {
    animation: pulse 1.5s infinite;
}

.animate-spin {
    animation: spin 0.8s linear infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }

    50% {
        transform: scale(1.1);
        opacity: 0.7;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.category-link {
    flex: 1 1 auto;
    /* Allow items to grow and shrink as needed */
    text-align: center;
    /* Center the text inside the button */
    white-space: nowrap;
    /* Prevent text from wrapping */
    overflow: hidden;
    /* Hide overflow text */
    text-overflow: ellipsis;
    /* Add ellipsis for long text */
}

@media (max-width: 640px) {
    .category-link {
        min-width: 150px;
        /* Smaller min-width for mobile screens */
    }
}

/* Active category styling */
.category-link.active {
    background-color: var(--bg-primary);
    /* Green background (Tailwind's green-500) */
    color: #ffffff;
    /* White text */
    font-weight: bold;
}

.category-link.active:hover {
    background-color: #059669;
    /* Darker green on hover (Tailwind's green-600) */
    color: #ffffff;
}

input[type="checkbox"] {
    width: 18px;
    /* Kích thước lớn hơn một chút */
    height: 18px;
    cursor: pointer;
    vertical-align: middle;
}

input[type="checkbox"]:checked {
    accent-color: #16a34a;
    /* Màu xanh lá (green-600) khi được chọn */
}

.form-input:focus {
    border-color: #10b981;
    box-shadow: 0 0 0 3px rgba(16, 185, 129, 0.2);
}

.form-input.dark {
    background: #059669;
    /* dark:bg-slate-900 */
    color: #d1d5db;
    /* dark:text-slate-200 */
    border-color: #4b5563;
    /* dark:!border-gray-800 */
}

.dropdown-menu-search {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 0.375rem;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-height: 200px;
    overflow-y: auto;
    display: none;
    z-index: 10;
}

.dropdown-menu-search.dark {
    background: #1f2937;
    border-color: #4b5563;
    color: #d1d5db;
}

.dropdown-item {
    padding: 0.5rem 0.75rem;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.dropdown-item:hover {
    background-color: #f1f3f5;
}

.dropdown-item.dark:hover {
    color: #fff;
    background-color: #059669;
}

.container-fluid {
    width: 100%;
    padding: 0 15px;
    margin: 0 auto;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    /* Chia hai bên */
    align-items: center;
    flex-wrap: wrap;
    /* Responsive cho mobile */
}

.copyright,
.version {
    color: #9ca3af;
    /* text-slate-400 */
    margin: 0;
    font-size: 0.875rem;
    /* Nhỏ gọn hơn */
}

.copyright a {
    color: inherit;
    /* text-reset */
    text-decoration: none;
}

.copyright a:hover {
    color: #10b981;
    /* Màu xanh lá khi hover */
}

.mdi-heart {
    color: #dc2626;
    /* text-red-600 */
}

@media (max-width: 640px) {

    /* sm: breakpoint */
    .footer-content {
        flex-direction: column;
        text-align: center;
        gap: 0.5rem;
        /* Khoảng cách giữa hai phần trên mobile */
    }
}

.border-left {
    border-left: 3px solid #e6ebf4 !important;
}

.border-primary {
    border-color: var(--bg-primary) !important;
}

.backtop {
    top: 80%;
}

.backtop-button {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    line-height: 4px;
}

.right-20 {
    right: 0.5rem;
    /* 80px nếu 1rem = 16px */
}

.product-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    /* Ensure the card takes full height if in a grid */
    min-height: 300px;
    /* Optional: Set a minimum height for consistency */
}

.product-content {
    flex-grow: 1;
    /* Allows content to take up available space */
}

.text-center {
    margin-top: auto;
    /* Pushes the button to the bottom */
}

/* Ensure the info div and button stay together at the bottom */
.product-card>.flex,
.product-card>.text-center {
    flex-shrink: 0;
    /* Prevent shrinking */
}

/* Container chính */
.flex.items-center {
    display: flex;
    align-items: center;
    /* Căn giữa theo chiều dọc */
    gap: 12px;
    /* Khoảng cách giữa avatar và thông tin */
}

/* Avatar */
.avatar-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    /* Kích thước 32x32px (size-8) */
    height: 40px;
    overflow: hidden;
}

.avatar-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
}

/* Thông tin người dùng */
.user-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    /* Căn giữa theo chiều dọc trong cột */
    align-items: flex-start;
    /* Căn trái cho username và money */
}

/* Username */
.username {
    font-size: 16px;
    font-weight: 500;
    color: #1f2937;
    /* text-slate-900 */
    margin-bottom: 2px;
    /* Khoảng cách nhỏ giữa username và money */
}

/* Money */
.money {
    font-size: 14px;
    color: #ef4444;
    /* Màu đỏ giống trong hình */
}

/* Nút Google Login */
.google-login-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    /* Khoảng cách giữa icon và text */
    transition: background-color 0.3s ease;
}

.google-login-btn:hover {
    background-color: #f1f3f4;
    /* Màu hover nhẹ */
    text-decoration: none;
}

.google-login-btn img {
    width: 20px;
    height: 20px;
}

/* Đảm bảo nút không bị méo khi hover */
.google-login-btn:focus,
.google-login-btn:active {
    outline: none;
    box-shadow: none;
}
 /* CSS cho widget chatbot */
/* CSS cho widget chatbot */
.chatbot-container {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 400px;
    height: 600px;
    background: white;
    border-radius: 10px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    display: none;
}

.chat-header {
    background: #28a745; /* Xanh lá chính */
    color: white;
    padding: 10px;
    text-align: center;
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.chat-body {
    flex: 1;
    padding: 10px;
    overflow-y: auto;
    background: #f9f9f9; /* Giữ xám nhạt */
}

.message {
    margin: 5px 0;
    padding: 8px;
    border-radius: 5px;
    max-width: 70%;
    word-wrap: break-word;
}

.user-message {
    background: #d4edda; /* Xanh lá nhạt cho tin nhắn người dùng */
    color: #155724; /* Xanh đậm cho chữ */
    margin-left: auto;
}

.bot-message {
    background: #e9ecef; /* Giữ xám nhạt cho bot */
    color: black;
}

.message img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    margin-top: 5px;
    display: block;
}

/* Chat Input */
.chat-input {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 5px;
    padding: 10px;
    border-top: 1px solid #ddd;
    position: relative;
}

.chat-input input[type="text"] {
    flex: 1;
    padding: 5px;
    border: 1px solid #ced4da; /* Viền xám nhạt */
    border-radius: 5px;
    outline: none;
    min-width: 0;
    width: 100%;
    background: #f5f7fa; /* Nền nhạt */
    color: #333;
}

.chat-input input[type="text"]:focus {
    border-color: #28a745; /* Viền xanh lá khi focus */
    box-shadow: 0 0 5px rgba(40, 167, 69, 0.3);
}

.chat-input input[type="file"] {
    flex-shrink: 0;
    width: 100px;
    padding: 2px;
    border: none;
    font-size: 0.9em;
    cursor: pointer;
}

.chat-input input[type="file"]::-webkit-file-upload-button {
    background: #28a745; /* Xanh lá cho nút chọn file */
    color: white;
    border: none;
    padding: 5px 10px;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9em;
}

.chat-input input[type="file"]::-webkit-file-upload-button:hover {
    background: #218838; /* Xanh lá đậm khi hover */
}

.chat-input button {
    flex-shrink: 0;
    padding: 5px 10px;
    background: #28a745; /* Xanh lá cho nút Gửi */
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
}

.chat-input button:hover {
    background: #218838; /* Xanh lá đậm khi hover */
}

/* Nút emoji */
.emoji-btn {
    background: #e9ecef; /* Xám nhạt */
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 1.2em;
    cursor: pointer;
    padding: 5px 8px;
    transition: background 0.3s;
}

.emoji-btn:hover {
    background: #28a745; /* Xanh lá khi hover */
    color: white;
}

/* Bảng chọn emoji */
.emoji-picker {
    position: absolute;
    bottom: 50px;
    left: 10px;
    background: white;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    max-width: 200px;
    z-index: 10;
}

.emoji-picker .emoji {
    font-size: 1.5em;
    cursor: pointer;
    transition: transform 0.2s;
}

.emoji-picker .emoji:hover {
    transform: scale(1.2); /* Phóng to khi hover */
}

.chat-toggle-btn {
    position: fixed;
    bottom: 35px;
    right: 10px;
    padding: 10px 20px;
    background: #28a745; /* Xanh lá cho nút toggle */
    color: white;
    border: none;
    border-radius: 50px;
    cursor: pointer;
}

.chat-toggle-btn:hover {
    background: #218838; /* Xanh lá đậm khi hover */
}

.close-btn {
    background: none;
    border: none;
    color: white;
    font-size: 16px;
    cursor: pointer;
}

/* Responsive cho mobile */
@media (max-width: 480px) {
    .chatbot-container {
        width: 90%;
        height: 80vh;
        bottom: 10px;
        right: 10px;
    }

    .chat-input {
        flex-wrap: wrap;
        gap: 8px;
    }

    .chat-input input[type="text"],
    .chat-input input[type="file"],
    .chat-input button {
        width: 100%;
    }

    .emoji-picker {
        max-width: 100%;
        left: 0;
        bottom: 60px;
    }

    .message {
        max-width: 90%;
    }
}