@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.5.1/css/all.min.css');
@import url('https://cdn.jsdelivr.net/npm/bootstrap@5.3.2/dist/css/bootstrap.min.css');
@import url('https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/assets/owl.carousel.min.css');
@import url('https://cdnjs.cloudflare.com/ajax/libs/OwlCarousel2/2.3.4/assets/owl.theme.default.min.css');

:root {
    --primary: #e74c3c;
    --primary-dark: #c0392b;
    --secondary: #2c3e50;
    --accent: #f39c12;
    --bg-light: #f8f9fa;
    --bg-dark: #1a1a2e;
    --text-dark: #2c3e50;
    --text-light: #7f8c8d;
    --success: #27ae60;
    --danger: #e74c3c;
    --whatsapp: #25d366;
    --shadow: 0 2px 15px rgba(0,0,0,0.08);
    --shadow-hover: 0 5px 25px rgba(0,0,0,0.15);
    --radius: 10px;
    --transition: all 0.3s ease;
}

* { box-sizing: border-box; }

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color: var(--text-dark);
    background: #fff;
    line-height: 1.6;
    overflow-x: hidden;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }

/* Top Bar */
.top-bar {
    background: var(--secondary);
    color: #fff;
    font-size: 13px;
    padding: 6px 0;
}
.top-bar a { color: rgba(255,255,255,0.85); }
.top-bar a:hover { color: #fff; }
.top-bar .social-links a {
    display: inline-block;
    width: 26px; height: 26px;
    line-height: 26px;
    text-align: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    margin-left: 4px;
    font-size: 12px;
    transition: var(--transition);
}
.top-bar .social-links a:hover { background: var(--primary); color: #fff; }

/* Header */
.header {
    background: #fff;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-inner {
    display: flex;
    align-items: center;
    padding: 12px 0;
    gap: 20px;
}
.logo img { height: 50px; width: auto; }
.logo h1 { font-size: 24px; font-weight: 800; color: var(--secondary); margin: 0; }
.logo h1 span { color: var(--primary); }

.search-box {
    flex: 1;
    max-width: 500px;
    position: relative;
}
.search-box input {
    width: 100%;
    padding: 10px 45px 10px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 50px;
    font-size: 14px;
    transition: var(--transition);
}
.search-box input:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 3px rgba(231,76,60,0.1);
}
.search-box button {
    position: absolute;
    right: 4px; top: 4px;
    border: none;
    background: var(--primary);
    color: #fff;
    width: 36px; height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: var(--transition);
}
.search-box button:hover { background: var(--primary-dark); }

.header-contact {
    display: flex;
    align-items: center;
    gap: 20px;
}
.header-contact-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-light);
}
.header-contact-item i { font-size: 20px; color: var(--primary); }
.header-contact-item b { display: block; color: var(--text-dark); font-size: 14px; }

/* Cart Button */
.cart-btn {
    position: relative;
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: var(--primary);
    color: #fff;
    border-radius: 50px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: var(--transition);
}
.cart-btn:hover { background: var(--primary-dark); color: #fff; }
.cart-btn i { font-size: 18px; }
.cart-count {
    position: absolute;
    top: -8px; right: -8px;
    background: var(--accent);
    color: #fff;
    width: 22px; height: 22px;
    border-radius: 50%;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

/* Navigation */
.navbar {
    background: var(--secondary);
    padding: 0;
}
.navbar .nav-link {
    color: rgba(255,255,255,0.9);
    padding: 12px 18px;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
}
.navbar .nav-link:hover,
.navbar .nav-link.active {
    background: var(--primary);
    color: #fff;
}
.navbar .nav-link i { margin-right: 6px; }
.navbar-toggler { color: #fff; border: none; font-size: 24px; padding: 8px 16px; }
.navbar-toggler:focus { box-shadow: none; }

/* Mega Menu */
.megamenu-li { position: static !important; }
.megamenu-li > .nav-link { cursor: pointer; }
.megamenu {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: #fff;
    box-shadow: 0 10px 40px rgba(0,0,0,0.15);
    border-radius: 0 0 12px 12px;
    padding: 24px;
    z-index: 1000;
    max-height: 500px;
    overflow-y: auto;
}
.megamenu-li:hover .megamenu { display: block; }
.megamenu-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 16px;
    margin-bottom: 16px;
    border-bottom: 1px solid #eee;
}
.megamenu-title span {
    font-size: 18px;
    font-weight: 700;
    color: var(--secondary);
}
.megamenu-title span i { color: var(--primary); margin-right: 8px; }
.megamenu-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}
.megamenu-col { min-width: 0; }
.megamenu-header {
    display: block;
    font-size: 14px;
    font-weight: 700;
    color: var(--secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 8px 0;
    margin-bottom: 6px;
    border-bottom: 2px solid var(--primary);
    transition: var(--transition);
}
.megamenu-header:hover { color: var(--primary); }
.megamenu-subs {
    list-style: none;
    padding: 0;
    margin: 0;
}
.megamenu-subs li { margin: 0; }
.megamenu-subs li a {
    display: block;
    padding: 6px 0;
    font-size: 13px;
    color: var(--text-light);
    transition: var(--transition);
}
.megamenu-subs li a:hover {
    color: var(--primary);
    padding-left: 4px;
}
@media (max-width: 991.98px) {
    .megamenu-row { grid-template-columns: repeat(2, 1fr); }
    .megamenu-li { position: relative !important; }
    .megamenu { position: static; box-shadow: none; padding: 12px; max-height: none; display: none; }
    .megamenu-li:hover .megamenu { display: none; }
    .megamenu-li.open .megamenu { display: block; }
}
@media (max-width: 575.98px) {
    .megamenu-row { grid-template-columns: 1fr; }
}

/* Hero Slider */
.hero-slider { margin: 0; }
.hero-slider .owl-item .item { position: relative; height: 450px; overflow: hidden; }
.hero-slider .owl-item .item img { width: 100%; height: 100%; object-fit: cover; }
.hero-slider .owl-item .item .slide-content {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    display: flex;
    align-items: center;
    background: linear-gradient(135deg, rgba(0,0,0,0.6) 0%, rgba(0,0,0,0.2) 100%);
    padding: 60px;
}
.hero-slider .slide-text { color: #fff; max-width: 500px; }
.hero-slider .slide-text h2 { font-size: 42px; font-weight: 800; margin-bottom: 12px; }
.hero-slider .slide-text p { font-size: 18px; opacity: 0.9; margin-bottom: 20px; }
.hero-slider .slide-text .btn { padding: 12px 30px; font-size: 16px; border-radius: 50px; }
.hero-slider .owl-dots { position: absolute; bottom: 20px; left: 50%; transform: translateX(-50%); }
.hero-slider .owl-dots .owl-dot span { background: rgba(255,255,255,0.5); width: 12px; height: 12px; }
.hero-slider .owl-dots .owl-dot.active span { background: var(--primary); }

/* Section */
.section { padding: 60px 0; }
.section-title {
    text-align: center;
    margin-bottom: 40px;
}
.section-title h2 {
    font-size: 32px;
    font-weight: 800;
    color: var(--secondary);
    margin-bottom: 8px;
}
.section-title h2 span { color: var(--primary); }
.section-title p { color: var(--text-light); font-size: 16px; max-width: 600px; margin: 0 auto; }

/* Category Cards */
.cat-card {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    margin-bottom: 24px;
    cursor: pointer;
}
.cat-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-hover); }
.cat-card img { width: 100%; height: 200px; object-fit: cover; transition: var(--transition); }
.cat-card:hover img { transform: scale(1.05); }
.cat-card .cat-overlay {
    position: absolute;
    bottom: 0; left: 0; right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    padding: 20px;
    color: #fff;
}
.cat-card .cat-overlay h4 { font-size: 16px; font-weight: 700; margin: 0; }

/* Product Card */
.product-card {
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    overflow: hidden;
    transition: var(--transition);
    margin-bottom: 24px;
    position: relative;
}
.product-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-hover); }
.product-card .product-image {
    height: 220px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    background: #fafafa;
    overflow: hidden;
}
.product-card .product-image img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: var(--transition);
}
.product-card:hover .product-image img { transform: scale(1.08); }
.product-card .product-body {
    padding: 16px;
}
.product-card .product-category {
    font-size: 12px;
    color: var(--primary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}
.product-card .product-title {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 8px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 44px;
}
.product-card .product-title a { color: var(--text-dark); }
.product-card .product-title a:hover { color: var(--primary); }
.product-card .product-price {
    font-size: 18px;
    font-weight: 700;
    color: var(--primary);
}
.product-card .product-price .no-price { font-size: 14px; color: var(--accent); font-weight: 600; }
.product-card .product-actions {
    display: flex;
    gap: 8px;
    padding: 12px 16px;
    border-top: 1px solid #f0f0f0;
}
.product-card .product-actions .btn { flex: 1; font-size: 13px; padding: 8px; border-radius: 8px; }

/* Product Detail */
.product-detail { padding: 40px 0; }
.product-detail .main-image {
    border-radius: var(--radius);
    background: #fafafa;
    padding: 30px;
    text-align: center;
    margin-bottom: 16px;
}
.product-detail .main-image img { max-height: 400px; object-fit: contain; }
.product-detail .thumb-images { display: flex; gap: 8px; }
.product-detail .thumb-images .thumb {
    width: 80px; height: 80px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 4px;
    cursor: pointer;
    transition: var(--transition);
}
.product-detail .thumb-images .thumb:hover,
.product-detail .thumb-images .thumb.active { border-color: var(--primary); }
.product-detail .thumb-images .thumb img { width: 100%; height: 100%; object-fit: contain; }

.product-info h1 { font-size: 28px; font-weight: 700; margin-bottom: 8px; }
.product-info .product-code { color: var(--text-light); font-size: 14px; margin-bottom: 12px; }
.product-info .product-price-lg { font-size: 32px; font-weight: 800; color: var(--primary); margin-bottom: 16px; }

.product-info .action-buttons { display: flex; gap: 12px; margin-top: 20px; flex-wrap: wrap; }
.product-info .action-buttons .btn { padding: 12px 24px; border-radius: 8px; font-weight: 600; font-size: 15px; }
.product-info .qty-input {
    display: flex;
    align-items: center;
    gap: 0;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
}
.product-info .qty-input button {
    width: 40px; height: 44px;
    border: none;
    background: var(--bg-light);
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}
.product-info .qty-input button:hover { background: #e0e0e0; }
.product-info .qty-input input {
    width: 60px;
    height: 44px;
    border: none;
    border-left: 2px solid #e0e0e0;
    border-right: 2px solid #e0e0e0;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
}

.product-description { margin-top: 40px; }
.product-description h3 { font-size: 22px; font-weight: 700; margin-bottom: 16px; }
.product-description .content { line-height: 1.8; color: var(--text-dark); }
.product-description .content ul { padding-left: 20px; }
.product-description .content ul li { margin-bottom: 6px; }

/* Breadcrumb */
.breadcrumb-wrap {
    background: var(--bg-light);
    padding: 12px 0;
    margin-bottom: 0;
}
.breadcrumb {
    background: transparent;
    padding: 0;
    margin: 0;
    font-size: 14px;
}
.breadcrumb-item a { color: var(--text-light); }
.breadcrumb-item.active { color: var(--text-dark); font-weight: 600; }

/* Cart Page */
.cart-page { padding: 40px 0; }
.cart-table { width: 100%; }
.cart-table th {
    background: var(--bg-light);
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.cart-table td { padding: 16px; vertical-align: middle; border-bottom: 1px solid #f0f0f0; }
.cart-table .cart-product { display: flex; align-items: center; gap: 12px; }
.cart-table .cart-product img { width: 80px; height: 80px; object-fit: contain; border-radius: 8px; background: #fafafa; }
.cart-table .cart-product-info h6 { font-size: 15px; font-weight: 600; margin: 0; }
.cart-table .cart-product-info small { color: var(--text-light); }
.cart-table .qty-control { display: flex; align-items: center; gap: 0; border: 1px solid #e0e0e0; border-radius: 6px; width: fit-content; }
.cart-table .qty-control button { width: 32px; height: 32px; border: none; background: var(--bg-light); cursor: pointer; }
.cart-table .qty-control input { width: 48px; height: 32px; border: none; border-left: 1px solid #e0e0e0; border-right: 1px solid #e0e0e0; text-align: center; font-weight: 600; font-size: 14px; }
.cart-table .remove-btn { width: 32px; height: 32px; border-radius: 50%; border: none; background: #fee; color: var(--danger); cursor: pointer; transition: var(--transition); }
.cart-table .remove-btn:hover { background: var(--danger); color: #fff; }

.cart-summary { background: var(--bg-light); border-radius: var(--radius); padding: 24px; position: sticky; top: 100px; }
.cart-summary h5 { font-size: 20px; font-weight: 700; margin-bottom: 20px; }
.cart-summary .summary-row { display: flex; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid #e0e0e0; }
.cart-summary .summary-total { font-size: 22px; font-weight: 800; color: var(--primary); }

/* Checkout Form */
.checkout-form .form-control {
    padding: 12px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 14px;
    transition: var(--transition);
}
.checkout-form .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(231,76,60,0.1);
}
.checkout-form label { font-weight: 600; font-size: 14px; margin-bottom: 6px; color: var(--text-dark); }

/* Footer */
.footer {
    background: var(--secondary);
    color: rgba(255,255,255,0.8);
    padding: 60px 0 0;
}
.footer h5 {
    color: #fff;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 12px;
}
.footer h5::after {
    content: '';
    position: absolute;
    bottom: 0; left: 0;
    width: 40px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
}
.footer ul { list-style: none; padding: 0; margin: 0; }
.footer ul li { margin-bottom: 10px; }
.footer ul li a { color: rgba(255,255,255,0.7); }
.footer ul li a:hover { color: var(--primary); padding-left: 4px; }
.footer ul li i { width: 20px; margin-right: 8px; color: var(--primary); }
.footer .contact-info li { margin-bottom: 14px; display: flex; align-items: flex-start; gap: 10px; }
.footer .contact-info li i { margin-top: 4px; }

.footer-bottom {
    margin-top: 40px;
    padding: 20px 0;
    border-top: 1px solid rgba(255,255,255,0.1);
    text-align: center;
    font-size: 14px;
}
.footer-bottom a { color: var(--primary); }

/* WhatsApp Float */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
    width: 56px;
    height: 56px;
    background: var(--whatsapp);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    box-shadow: 0 4px 15px rgba(37,211,102,0.4);
    transition: var(--transition);
    animation: pulse 2s infinite;
}
.whatsapp-float:hover { transform: scale(1.1); color: #fff; }
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(37,211,102,0.4); }
    70% { box-shadow: 0 0 0 15px rgba(37,211,102,0); }
    100% { box-shadow: 0 0 0 0 rgba(37,211,102,0); }
}

/* Page Content */
.page-content { padding: 40px 0; min-height: 400px; }
.page-content h1 { font-size: 32px; font-weight: 800; margin-bottom: 24px; }
.page-content .content { line-height: 1.8; }
.page-content .content h2 { font-size: 24px; font-weight: 700; margin-top: 24px; margin-bottom: 12px; }

/* Contact Form */
.contact-info-box { padding: 24px; background: var(--bg-light); border-radius: var(--radius); margin-bottom: 24px; }
.contact-info-box i { font-size: 28px; color: var(--primary); margin-bottom: 12px; }
.contact-info-box h6 { font-weight: 700; }
.contact-info-box p { color: var(--text-light); margin: 0; }

/* Pagination */
.pagination .page-link {
    border: none;
    padding: 10px 18px;
    margin: 0 3px;
    border-radius: 8px;
    color: var(--text-dark);
    font-weight: 500;
    transition: var(--transition);
}
.pagination .page-link:hover { background: var(--bg-light); color: var(--primary); }
.pagination .page-item.active .page-link { background: var(--primary); color: #fff; }

/* Categories page specific */
.categories-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; }

/* Empty state */
.empty-state { text-align: center; padding: 60px 20px; }
.empty-state i { font-size: 64px; color: #ddd; margin-bottom: 16px; }
.empty-state h4 { color: var(--text-light); }

/* Toast notification */
.toast-container { position: fixed; top: 80px; right: 20px; z-index: 9999; }
.toast-message {
    padding: 14px 20px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.15);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 500;
    animation: slideInRight 0.3s ease;
    border-left: 4px solid var(--success);
}
.toast-message.error { border-left-color: var(--danger); }
.toast-message i { font-size: 20px; }
.toast-message .fa-check-circle { color: var(--success); }
.toast-message .fa-times-circle { color: var(--danger); }
@keyframes slideInRight { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }

/* Responsive */
@media (max-width: 991.98px) {
    .hero-slider .owl-item .item { height: 300px; }
    .hero-slider .slide-text h2 { font-size: 28px; }
    .header-contact { display: none; }
    .header-inner { flex-wrap: wrap; }
    .search-box { order: 3; max-width: 100%; flex-basis: 100%; }
}
@media (max-width: 767.98px) {
    .hero-slider .owl-item .item { height: 220px; }
    .hero-slider .owl-item .item .slide-content { padding: 24px; }
    .hero-slider .slide-text h2 { font-size: 22px; }
    .hero-slider .slide-text p { font-size: 14px; }
    .section { padding: 40px 0; }
    .section-title h2 { font-size: 24px; }
    .product-info h1 { font-size: 22px; }
    .cart-table thead { display: none; }
    .cart-table td { display: block; text-align: right; padding: 12px; }
    .cart-table td::before { content: attr(data-label); float: left; font-weight: 600; }
    .cart-table .cart-product { justify-content: flex-end; }
    .cart-table tr { display: block; margin-bottom: 16px; border: 1px solid #e0e0e0; border-radius: 8px; }
    .categories-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); }
}

/* Loading Spinner */
.spinner { display: inline-block; width: 20px; height: 20px; border: 2px solid rgba(255,255,255,0.3); border-radius: 50%; border-top-color: #fff; animation: spin 0.6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* Brands */
.brand-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #fff;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    min-height: 100px;
    transition: var(--transition);
}
.brand-item:hover { box-shadow: var(--shadow-hover); }
.brand-item img { max-height: 60px; max-width: 100%; opacity: 0.7; transition: var(--transition); }
.brand-item:hover img { opacity: 1; }

/* WhatsApp order button in cart */
.btn-whatsapp {
    background: var(--whatsapp);
    color: #fff;
}
.btn-whatsapp:hover { background: #1ebe57; color: #fff; }
