@import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
    --primary: #4f46e5;
    --primary-hover: #4338ca;
    --secondary: #ec4899;
    --bg-color: #f8fafc;
    --text-main: #0f172a;
    --text-muted: #64748b;
    --card-bg: rgba(255, 255, 255, 0.85);
    --border-light: rgba(255, 255, 255, 0.5);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

body {
    background-color: var(--bg-color);
    background-image:
        radial-gradient(at 0% 0%, hsla(253, 16%, 7%, 0.03) 0, transparent 50%),
        radial-gradient(at 50% 0%, hsla(225, 39%, 30%, 0.03) 0, transparent 50%),
        radial-gradient(at 100% 0%, hsla(339, 49%, 30%, 0.03) 0, transparent 50%);
    background-attachment: fixed;
    font-family: 'Plus Jakarta Sans', sans-serif;
    color: var(--text-main);
    padding-top: 80px;
    /* Space for fixed navbar */
}

/* ===== MODERN GLASS NAVBAR ===== */
.navbar-modern {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.03);
    padding: 10px 0;
    transition: all 0.3s ease;
}

.navbar-brand-modern {
    font-weight: 800;
    font-size: 24px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: flex;
    align-items: center;
    gap: 8px;
}

.navbar-brand-modern i {
    -webkit-text-fill-color: var(--primary);
}

.nav-link-modern {
    color: var(--text-main) !important;
    font-weight: 600;
    font-size: 14px;
    padding: 10px 12px !important;
    border-radius: 8px;
    transition: all 0.2s ease;
    margin: 0 2px;
    white-space: nowrap;
}

.nav-link-modern:hover {
    background: rgba(79, 70, 229, 0.08);
    color: var(--primary) !important;
}

.nav-badge {
    background: var(--secondary);
    color: white;
    font-size: 11px;
    padding: 3px 8px;
    border-radius: 20px;
    margin-left: 6px;
    font-weight: bold;
    box-shadow: 0 2px 4px rgba(236, 72, 153, 0.3);
}

/* ===== LOGIN/SIGNUP BUTTONS ===== */
.btn-login {
    border: 2px solid var(--primary);
    color: var(--primary) !important;
    border-radius: 20px !important;
    padding: 6px 16px !important;
    font-weight: 600;
    margin: 6px 4px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-login:hover {
    background: var(--primary);
    color: white !important;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.2);
}

.btn-signup {
    background: var(--primary);
    color: white !important;
    border-radius: 20px !important;
    padding: 8px 16px !important;
    font-weight: 600;
    margin: 6px 4px;
    transition: all 0.3s ease;
    border: none;
    white-space: nowrap;
}

.btn-signup:hover {
    background: var(--primary-hover);
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
    transform: translateY(-1px);
}

/* ===== GLASS SIDEBAR CARDS ===== */
.sidebar-card {
    background: #eff6ff;
    /* Màu xanh nhạt khác biệt hoàn toàn với hình nền */
    backdrop-filter: blur(10px);
    border: 1px solid #bfdbfe;
    border-radius: var(--radius-lg);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    margin-bottom: 24px;
    overflow: hidden;
}

.sidebar-header {
    background: transparent;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}

.sidebar-header h4 {
    margin: 0;
    font-size: 14px;
    font-weight: 800;
    color: var(--text-muted);
    letter-spacing: 1px;
    text-transform: uppercase;
}

.sidebar-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-item {
    padding: 12px 20px;
    display: block;
    color: var(--text-main);
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    border-left: 3px solid transparent;
}

.sidebar-item:hover,
.sidebar-item.active {
    background: rgba(79, 70, 229, 0.04);
    color: var(--primary);
    border-left-color: var(--primary);
    text-decoration: none;
    padding-left: 25px;
}

/* KẾT HỢP NHIỀU MÀU SẮC CHO SIDEBAR */
.sidebar-list li:nth-child(6n+1) .sidebar-item:hover {
    color: #ef4444;
    border-left-color: #ef4444;
    background: rgba(239, 68, 68, 0.05);
}

.sidebar-list li:nth-child(6n+2) .sidebar-item:hover {
    color: #f59e0b;
    border-left-color: #f59e0b;
    background: rgba(245, 158, 11, 0.05);
}

.sidebar-list li:nth-child(6n+3) .sidebar-item:hover {
    color: #10b981;
    border-left-color: #10b981;
    background: rgba(16, 185, 129, 0.05);
}

.sidebar-list li:nth-child(6n+4) .sidebar-item:hover {
    color: #3b82f6;
    border-left-color: #3b82f6;
    background: rgba(59, 130, 246, 0.05);
}

.sidebar-list li:nth-child(6n+5) .sidebar-item:hover {
    color: #8b5cf6;
    border-left-color: #8b5cf6;
    background: rgba(139, 92, 246, 0.05);
}

.sidebar-list li:nth-child(6n+6) .sidebar-item:hover {
    color: #ec4899;
    border-left-color: #ec4899;
    background: rgba(236, 72, 153, 0.05);
}

/* Chấm tròn đầu dòng với màu tương ứng */
.sidebar-list li {
    position: relative;
}

.sidebar-list li::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 6px;
    height: 6px;
    border-radius: 50%;
    opacity: 0.5;
    transition: all 0.3s ease;
}

.sidebar-list li:nth-child(6n+1)::before {
    background: #ef4444;
}

.sidebar-list li:nth-child(6n+2)::before {
    background: #f59e0b;
}

.sidebar-list li:nth-child(6n+3)::before {
    background: #10b981;
}

.sidebar-list li:nth-child(6n+4)::before {
    background: #3b82f6;
}

.sidebar-list li:nth-child(6n+5)::before {
    background: #8b5cf6;
}

.sidebar-list li:nth-child(6n+6)::before {
    background: #ec4899;
}

.sidebar-list li:hover::before {
    opacity: 1;
    transform: translateY(-50%) scale(1.5);
}

/* KẾT HỢP NHIỀU MÀU SẮC CHO SIDEBAR NHÀ XUẤT BẢN */
.sidebar-list-nxb li:nth-child(5n+1) .sidebar-item:hover {
    color: #0ea5e9;
    border-left-color: #0ea5e9;
    background: rgba(14, 165, 233, 0.05);
}

.sidebar-list-nxb li:nth-child(5n+2) .sidebar-item:hover {
    color: #14b8a6;
    border-left-color: #14b8a6;
    background: rgba(20, 184, 166, 0.05);
}

.sidebar-list-nxb li:nth-child(5n+3) .sidebar-item:hover {
    color: #f43f5e;
    border-left-color: #f43f5e;
    background: rgba(244, 63, 94, 0.05);
}

.sidebar-list-nxb li:nth-child(5n+4) .sidebar-item:hover {
    color: #6366f1;
    border-left-color: #6366f1;
    background: rgba(99, 102, 241, 0.05);
}

.sidebar-list-nxb li:nth-child(5n+5) .sidebar-item:hover {
    color: #d946ef;
    border-left-color: #d946ef;
    background: rgba(217, 70, 239, 0.05);
}

.sidebar-list-nxb li:nth-child(5n+1)::before {
    background: #0ea5e9;
}

.sidebar-list-nxb li:nth-child(5n+2)::before {
    background: #14b8a6;
}

.sidebar-list-nxb li:nth-child(5n+3)::before {
    background: #f43f5e;
}

.sidebar-list-nxb li:nth-child(5n+4)::before {
    background: #6366f1;
}

.sidebar-list-nxb li:nth-child(5n+5)::before {
    background: #d946ef;
}

/* ===== MODERN PRODUCT CARDS ===== */
.product-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 40px;
}

@media (max-width: 992px) {
    .product-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 576px) {
    .product-grid {
        grid-template-columns: 1fr;
    }
}

.product-card {
    background: var(--card-bg);
    border: 1px solid rgba(255, 255, 255, 0.6);
    border-radius: var(--radius-lg);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    box-shadow: var(--shadow-md);
    position: relative;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.product-img-wrapper {
    position: relative;
    overflow: hidden;
    aspect-ratio: 3/4;
    width: 100%;
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.product-card:hover .product-img {
    transform: scale(1.08);
}

.product-info {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-title {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 8px 0;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-decoration: none;
}

.product-title:hover {
    color: var(--primary);
    text-decoration: none;
}

.product-price {
    font-size: 18px;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 20px;
}

.product-actions {
    display: flex;
    gap: 10px;
    margin-top: auto;
}

.btn-modern {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 600;
    border-radius: 8px;
    transition: all 0.3s ease;
    text-decoration: none;
    cursor: pointer;
    border: none;
}

.btn-modern-outline {
    background: transparent;
    border: 1px solid #e2e8f0;
    color: var(--text-main);
}

.btn-modern-outline:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.btn-modern-primary {
    background: var(--primary);
    color: white;
    flex: 1;
}

.btn-modern-primary:hover {
    background: var(--primary-hover);
    color: white;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3);
}

/* ===== PAGINATION ===== */
.store-pagination {
    display: flex;
    justify-content: center;
    margin: 40px 0;
}

.store-pagination .pagination {
    background: var(--card-bg);
    padding: 8px;
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.store-pagination .pagination>li>a,
.store-pagination .pagination>li>span {
    border: none;
    background: transparent;
    color: var(--text-main);
    font-weight: 600;
    border-radius: 8px;
    margin: 0 4px;
    transition: all 0.2s;
}

.store-pagination .pagination>li>a:hover {
    background: rgba(79, 70, 229, 0.1);
    color: var(--primary);
}

.store-pagination .pagination>.active>a,
.store-pagination .pagination>.active>span {
    background: var(--primary);
    color: white;
    box-shadow: 0 2px 8px rgba(79, 70, 229, 0.4);
}

/* SECTION HEADER */
.section-title {
    font-size: 28px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 40px;
    position: relative;
    background: linear-gradient(135deg, var(--text-main), var(--primary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: -12px;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 4px;
    background: var(--primary);
    border-radius: 4px;
}