/* Reset và thiết lập cơ bản */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f5f5f5;
    padding: 20px;
}

/* ============ MENU ĐIỀU HƯỚNG - MỚI THÊM ============ */
.menu {
    background-color: #0099FF;
    padding: 15px 20px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.menu ul {
    list-style: none;
    display: flex;
    gap: 30px;
    align-items: center;
    flex-wrap: wrap;
}

.menu li {
    display: inline;
}

.menu a {
    color: white;
    text-decoration: none;
    font-size: 16px;
    padding: 8px 15px;
    border-radius: 4px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.menu a:hover {
    background-color: #FFA726;
}

/* Link đang active - màu đỏ */
.menu a.active {
    background-color: #FF3333;
}
/* ============ KẾT THÚC MENU ĐIỀU HƯỚNG ============ */

/* ============ TIÊU ĐỀ CHÍNH - THAY ĐỔI MÀU ============ */
h1 {
    text-align: center;
    color: #0099FF; /* Màu xanh HUTECH */
    margin: 30px 0;
    font-size: 32px;
    font-weight: bold;
}
/* ============ KẾT THÚC TIÊU ĐỀ ============ */

/* ============ LAYOUT CHÍNH: SIDEBAR + CONTENT - MỚI THÊM ============ */
.main-layout {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    gap: 20px;
    padding: 0 20px;
}

.content {
    flex: 1;
}

/* ============ SIDEBAR (THANH BÊN TRÁI) - MỚI THÊM ============ */
.sidebar {
    width: 250px;
    background-color: white;
    border-radius: 8px;
    padding: 20px;
    height: fit-content;
    position: sticky;
    top: 20px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); /* Thêm bóng nhẹ */
}

.sidebar h3 {
    color: #333;
    font-size: 18px;
    font-weight: bold;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
}

.sidebar ul {
    list-style: none;
}

.sidebar li {
    margin-bottom: 12px;
}

.sidebar a {
    color: #0099FF; /* Màu xanh HUTECH */
    text-decoration: none;
    font-size: 16px;
    display: block;
    padding: 8px 10px;
    border-radius: 4px;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.sidebar a:hover {
    background-color: #e3f2fd;
    color: #0077CC;
}
/* ============ KẾT THÚC SIDEBAR ============ */

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* Product List Layout */
.product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    padding: 20px;
}

/* Product Item Card */
.product-item {
    background-color: white;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

/* Product Image */
.product-image {
    width: 100%;
    height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #fafafa;
    padding: 20px;
}

.product-image img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* ============ PRODUCT INFO - THAY ĐỔI LAYOUT ============ */
.product-info {
    padding: 20px;
    text-align: center; /* Căn giữa nội dung */
}

.product-info h2 {
    color: #333;
    font-size: 18px;
    margin-bottom: 12px;
    font-weight: 600;
}

/* Giá sản phẩm - màu đỏ */
.product-price {
    color: #FF3333;
    font-weight: bold;
    font-size: 20px;
    margin: 12px 0;
}

/* Mô tả sản phẩm */
.product-description {
    color: #999;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 15px;
}

/* Nút mua hàng - màu xanh HUTECH */
.buy-button {
    display: inline-block;
    background-color: #0099FF;
    color: white;
    padding: 10px 30px;
    border-radius: 5px;
    text-decoration: none;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.buy-button:hover {
    background-color: #0077CC;
    transform: scale(1.05);
}
/* ============ KẾT THÚC PRODUCT INFO ============ */

/* ============ CHÂN TRANG (FOOTER) - MỚI THÊM ============ */
.footer {
    background-color: #4267B2; /* Màu xanh dương đậm */
    color: white;
    padding: 30px 20px;
    margin-top: 50px;
    text-align: center;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
}

.footer-copyright {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 10px;
}

.footer-contact {
    font-size: 14px;
    margin-bottom: 10px;
}

.footer-contact a {
    color: #FDB714; /* Màu vàng cam HUTECH */
    text-decoration: none;
}

.footer-contact a:hover {
    text-decoration: underline;
}

.footer-social {
    font-size: 14px;
    margin-top: 10px;
}

.footer-social a {
    color: #FDB714; /* Màu vàng cam HUTECH */
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.footer-social a:hover {
    color: #FFA726;
    text-decoration: underline;
}
/* ============ KẾT THÚC CHÂN TRANG ============ */

/* ============ RESPONSIVE DESIGN - MỚI THÊM ============ */

/* Tablet và nhỏ hơn (≤768px) */
@media (max-width: 768px) {
    .main-layout {
        flex-direction: column;
        padding: 0 10px;
    }

    .sidebar {
        width: 100%;
        position: static;
    }

    .menu ul {
        gap: 10px;
    }

    .product-list {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
        padding: 15px 10px;
    }
}

/* Mobile (≤480px) */
@media (max-width: 480px) {
    .menu a {
        font-size: 14px;
        padding: 6px 10px;
    }

    h1 {
        font-size: 24px;
    }

    .product-list {
        grid-template-columns: 1fr;
    }

    .product-info h2 {
        font-size: 16px;
    }

    .product-price {
        font-size: 18px;
    }
}

/* ============ KẾT THÚC RESPONSIVE DESIGN ============ */
/* Danh mục đang được chọn */
.sidebar a.cat-active {
    background-color: #e3f2fd;
    color: #0077CC;
    font-weight: 600;
}
/* ============ GIỎ HÀNG (POPUP) ============ */
.cart-modal {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.45);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.cart-modal.open {
    display: flex;
}

.cart-panel {
    width: min(520px, 92vw);
    max-height: 85vh;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    display: flex;
    flex-direction: column;
}

.cart-header {
    padding: 14px 16px;
    background: #0099FF;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.cart-header h3 {
    font-size: 18px;
    margin: 0;
}

.cart-close {
    border: 0;
    background: transparent;
    color: #fff;
    font-size: 26px;
    cursor: pointer;
    line-height: 1;
}

.cart-items {
    padding: 12px 16px;
    overflow: auto;
}

.cart-item {
    display: grid;
    grid-template-columns: 64px 1fr auto;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}

.cart-thumb {
    width: 64px;
    height: 64px;
    object-fit: contain;
    background: #fafafa;
    border-radius: 8px;
    padding: 6px;
}

.cart-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 4px;
}

.cart-price {
    color: #FF3333;
    font-weight: 700;
    margin-bottom: 8px;
}

.cart-qty {
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

.qty-btn {
    width: 28px;
    height: 28px;
    border-radius: 6px;
    border: 1px solid #ddd;
    background: #fff;
    cursor: pointer;
}

.qty-num {
    min-width: 18px;
    text-align: center;
    font-weight: 600;
}

.remove-btn {
    border: 0;
    background: #ffecec;
    color: #c62828;
    font-weight: 600;
    padding: 6px 10px;
    border-radius: 8px;
    cursor: pointer;
}

.cart-footer {
    padding: 12px 16px;
    border-top: 1px solid #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.cart-total {
    font-weight: 700;
    color: #333;
}

.cart-actions {
    display: flex;
    gap: 10px;
}

.cart-clear {
    border: 1px solid #ddd;
    background: #fff;
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 600;
}

.cart-checkout {
    border: 0;
    background: #0099FF;
    color: #fff;
    padding: 8px 12px;
    border-radius: 10px;
    cursor: pointer;
    font-weight: 700;
}
/* ============ KẾT THÚC GIỎ HÀNG ============ */


