/* 
   MODERN THEME CSS - Applied to all pages
   Created: 2024
   Beautiful, professional design for buynoks website
*/

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;500;600;700&display=swap');

/* GLOBAL STYLES */
body { 
    font-family: 'Poppins', sans-serif !important;
    background: linear-gradient(to bottom, #f5f7fa 0%, #c3cfe2 100%) !important;
    min-height: 100vh;
}

/* MODERN PRODUCT CARD */
.product-card {
    border: none !important;
    border-radius: 20px !important;
    overflow: hidden;
    background: white;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08) !important;
    transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1) !important;
    position: relative;
}

.product-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
    opacity: 0;
    transition: opacity 0.4s;
    z-index: 0;
}

.product-card:hover {
    transform: translateY(-10px) scale(1.02) !important;
    box-shadow: 0 20px 60px rgba(102, 126, 234, 0.3) !important;
}

.product-card:hover::before {
    opacity: 1;
}

/* PRODUCT IMAGE WITH ZOOM */
.product-image-wrapper {
    position: relative;
    overflow: hidden;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    height: 280px;
    border-radius: 20px 20px 0 0;
}

.product-image {
    height: 100%;
    width: 100%;
    object-fit: contain;
    padding: 20px;
    transition: transform 0.5s ease !important;
}

.product-card:hover .product-image {
    transform: scale(1.1) !important;
}

/* BADGES */
.product-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    padding: 6px 15px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(245, 87, 108, 0.4);
    animation: pulse 2s infinite;
}

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

.discount-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background: linear-gradient(135deg, #FFD93D 0%, #FF6B6B 100%);
    color: white;
    padding: 8px 16px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 700;
    z-index: 10;
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.4);
}

/* CARD CONTENT */
.product-card .card-body {
    padding: 25px;
    position: relative;
    z-index: 1;
}

.product-card .card-title {
    font-weight: 600 !important;
    font-size: 1.1rem !important;
    color: #2d3748 !important;
    margin-bottom: 12px;
    height: 50px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* PRICE DISPLAY */
.price-section {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 15px 0;
}

.price-current {
    font-size: 1.8rem !important;
    font-weight: 700 !important;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.price-original {
    font-size: 1.1rem;
    color: #a0aec0;
    text-decoration: line-through;
}

/* RATING STARS */
.rating-section {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 10px 0;
}

.stars {
    color: #FFD700;
    font-size: 18px;
    text-shadow: 0 2px 4px rgba(255, 215, 0, 0.3);
}

.rating-count {
    color: #718096;
    font-size: 14px;
}

/* BUTTONS */
.btn-cart {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    border: none !important;
    color: white !important;
    padding: 12px 24px;
    border-radius: 12px !important;
    font-weight: 600;
    transition: all 0.3s !important;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4) !important;
}

.btn-cart:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.6) !important;
    color: white !important;
}

.btn-details {
    background: white !important;
    border: 2px solid #667eea !important;
    color: #667eea !important;
    padding: 12px 24px;
    border-radius: 12px !important;
    font-weight: 600;
    transition: all 0.3s !important;
}

.btn-details:hover {
    background: #667eea !important;
    color: white !important;
    transform: translateY(-2px) !important;
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    border: none !important;
    border-radius: 12px !important;
    padding: 12px 24px !important;
    font-weight: 600 !important;
    transition: all 0.3s !important;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4) !important;
}

.btn-primary:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.6) !important;
}

.btn-outline-primary {
    border: 2px solid #667eea !important;
    color: #667eea !important;
    border-radius: 12px !important;
    padding: 12px 24px !important;
    font-weight: 600 !important;
    transition: all 0.3s !important;
}

.btn-outline-primary:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    transform: translateY(-2px) !important;
    border-color: transparent !important;
}

/* CART BADGE */
.cart-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 12px rgba(245, 87, 108, 0.5);
    animation: bounce 1s infinite;
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-5px); }
}

/* HERO SECTION */
.hero-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    padding: 80px 0 !important;
    margin-bottom: 50px;
    position: relative;
    overflow: hidden;
}

.hero-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 1440 320"><path fill="rgba(255,255,255,0.1)" d="M0,96L48,112C96,128,192,160,288,186.7C384,213,480,235,576,213.3C672,192,768,128,864,128C960,128,1056,192,1152,197.3C1248,203,1344,149,1392,122.7L1440,96L1440,320L1392,320C1344,320,1248,320,1152,320C1056,320,960,320,864,320C768,320,672,320,576,320C480,320,384,320,288,320C192,320,96,320,48,320L0,320Z"></path></svg>');
    background-size: cover;
    background-position: bottom;
}

.hero-section h1 {
    font-weight: 700 !important;
    text-shadow: 0 4px 20px rgba(0,0,0,0.2) !important;
}

/* FILTER SECTION */
.category-filter {
    background: white !important;
    border-radius: 20px !important;
    padding: 30px !important;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1) !important;
    margin-bottom: 40px;
    border: 1px solid rgba(102, 126, 234, 0.1) !important;
}

.form-select, .form-control {
    border-radius: 12px !important;
    border: 2px solid #e2e8f0 !important;
    padding: 12px 16px !important;
    transition: all 0.3s !important;
    background-color: white !important;
    color: #1a202c !important;
    font-weight: 500 !important;
}

.form-select option {
    background-color: white !important;
    color: #1a202c !important;
    padding: 10px !important;
    font-weight: 500 !important;
}

.form-select:focus, .form-control:focus {
    border-color: #667eea !important;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1) !important;
    background-color: white !important;
    color: #1a202c !important;
}

/* CARDS */
.card {
    border: none !important;
    border-radius: 20px !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08) !important;
    transition: all 0.3s !important;
    background: white !important;
}

.card:hover {
    transform: translateY(-5px) !important;
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.2) !important;
}

/* PAGINATION */
.pagination {
    gap: 10px;
}

.page-link {
    border-radius: 12px !important;
    border: none !important;
    padding: 12px 18px !important;
    color: #667eea !important;
    font-weight: 600 !important;
    margin: 0 4px !important;
    transition: all 0.3s !important;
    background: white !important;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1) !important;
}

.page-link:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4) !important;
}

.page-item.active .page-link {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
    color: white !important;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4) !important;
}

.page-item.disabled .page-link {
    background: #f7fafc !important;
    color: #cbd5e0 !important;
}

/* CATEGORY CARDS */
.category-card {
    border: none !important;
    border-radius: 16px !important;
    transition: all 0.4s !important;
    cursor: pointer;
    background: white !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08) !important;
    overflow: hidden;
}

.category-card:hover {
    transform: translateY(-8px) rotate(1deg) !important;
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.2) !important;
}

a:hover .category-card {
    transform: translateY(-8px) rotate(1deg) !important;
    box-shadow: 0 15px 40px rgba(102, 126, 234, 0.2) !important;
}

.subcategory-badge {
    background: #E8EAFF !important;
    color: #3730A3 !important;
    border: 3px solid #6366F1 !important;
    padding: 10px 18px !important;
    border-radius: 25px !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3) !important;
    transition: all 0.3s !important;
    display: inline-block !important;
}

.subcategory-badge:hover {
    background: #DDD6FE !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.5) !important;
}

.category-badge {
    background: #FFE5F1 !important;
    color: #C41E3A !important;
    border: 3px solid #FF6B9D !important;
    padding: 10px 18px !important;
    border-radius: 25px !important;
    font-weight: 700 !important;
    font-size: 15px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    box-shadow: 0 4px 12px rgba(255, 107, 157, 0.3) !important;
}

.category-badge:hover {
    background: #FFD1E3 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 6px 16px rgba(255, 107, 157, 0.5) !important;
}

/* STOCK BADGE */
.stock-badge {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
}

.stock-in {
    background: linear-gradient(135deg, #84fab0 0%, #8fd3f4 100%);
    color: #047857;
}

.stock-low {
    background: linear-gradient(135deg, #fa709a 0%, #fee140 100%);
    color: #c53030;
}

.stock-out {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
}

/* TABLES */
.table {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
}

.table thead {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.table thead th {
    border: none !important;
    padding: 16px !important;
    font-weight: 600 !important;
}

.table tbody tr {
    transition: all 0.3s;
}

.table tbody tr:hover {
    background: rgba(102, 126, 234, 0.05);
    transform: scale(1.01);
}

/* BADGES */
.badge {
    border-radius: 12px !important;
    padding: 6px 12px !important;
    font-weight: 600 !important;
}

/* ALERTS */
.alert {
    border-radius: 16px !important;
    border: none !important;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08) !important;
}

/* MODALS */
.modal-content {
    border-radius: 20px !important;
    border: none !important;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3) !important;
}

.modal-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 20px 20px 0 0 !important;
    border: none !important;
}

/* NAVBAR */
.navbar {
    box-shadow: 0 4px 20px rgba(0,0,0,0.08) !important;
    background: white !important;
}

.navbar-brand {
    font-weight: 700 !important;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* FOOTER */
footer {
    background: linear-gradient(135deg, #2d3748 0%, #1a202c 100%) !important;
    color: white !important;
    padding: 40px 0 !important;
    margin-top: 80px !important;
}

/* UTILITIES */
.shadow-custom {
    box-shadow: 0 10px 30px rgba(0,0,0,0.1) !important;
}

.rounded-custom {
    border-radius: 20px !important;
}

.gradient-text {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.gradient-bg {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

/* RESPONSIVE */
@media (max-width: 768px) {
    .product-card {
        margin-bottom: 20px;
    }
    
    .hero-section {
        padding: 60px 0 !important;
    }
    
    .category-filter {
        padding: 20px !important;
    }
}

/* SMOOTH SCROLLING */
html {
    scroll-behavior: smooth;
}

/* TEXT SELECTION */
::selection {
    background: rgba(102, 126, 234, 0.3);
    color: #2d3748;
}

::-moz-selection {
    background: rgba(102, 126, 234, 0.3);
    color: #2d3748;
}
