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

:root {
    --brand: #6C5CE7;
    --brand-dark: #5A4BD1;
    --brand-light: #A29BFE;
    --accent: #00CEC9;
    --accent-dark: #00B5B0;
    --surface: #FFFFFF;
    --bg: #F7F8FC;
    --bg-dark: #1A1A2E;
    --text: #2D3436;
    --text-secondary: #636E72;
    --text-light: #B2BEC3;
    --border: #E8ECF1;
    --danger: #FF6B6B;
    --success: #00B894;
    --warning: #FDCB6E;
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 20px;
    --radius-pill: 9999px;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 16px rgba(0,0,0,0.06);
    --shadow-lg: 0 12px 32px rgba(0,0,0,0.08);
    --shadow-glow: 0 4px 15px rgba(108,92,231,0.3);
    --ease: cubic-bezier(0.4,0,0.2,1);
}

*,*::before,*::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }
body { font-family:'Inter',system-ui,-apple-system,sans-serif; background:var(--bg); color:var(--text); line-height:1.6; overflow-x:hidden; -webkit-font-smoothing:antialiased; }
a { text-decoration:none; color:inherit; }
img { max-width:100%; display:block; }
button { font-family:inherit; cursor:pointer; }
ul { list-style:none; }

.container { max-width:1300px; margin:0 auto; padding:0 24px; }

/* ---- TOP HEADER ---- */
.top-header {
    background: linear-gradient(90deg, var(--bg-dark), #16213E);
    color:#fff; padding:10px 0; font-size:13px; font-weight:500; letter-spacing:0.3px;
}
.top-header .container { display:flex; justify-content:space-between; align-items:center; }
.top-header-text,.top-header-links { display:inline-block; }
.top-header-links a { color:rgba(255,255,255,0.8); margin-left:20px; transition:color 0.2s; font-size:13px; }
.top-header-links a:hover { color:#fff; }
.top-header-links i { margin-right:4px; }

/* ---- MAIN HEADER ---- */
header {
    background:rgba(255,255,255,0.95); backdrop-filter:blur(20px); -webkit-backdrop-filter:blur(20px);
    border-bottom:1px solid var(--border); position:sticky; top:0; z-index:1000; box-shadow:var(--shadow-sm);
}
.header-content { display:flex; align-items:center; justify-content:space-between; padding:16px 0; gap:20px; }
.logo { font-size:24px; font-weight:800; color:var(--text); display:flex; align-items:center; gap:10px; letter-spacing:-0.5px; flex-shrink:0; }
.logo i { color:var(--brand); font-size:26px; }

.search-bar {
    display:flex; align-items:center; background:var(--bg); border:1.5px solid var(--border);
    border-radius:var(--radius-pill); padding:4px 4px 4px 18px; flex:0 1 480px; transition:all 0.25s var(--ease);
}
.search-bar:focus-within { border-color:var(--brand); box-shadow:0 0 0 4px rgba(108,92,231,0.08); background:#fff; }
.search-bar input { border:none; background:transparent; outline:none; padding:10px 8px; width:100%; font-size:14px; color:var(--text); }
.search-bar input::placeholder { color:var(--text-light); }
.search-bar button {
    background:var(--brand); color:#fff; border:none; border-radius:50%; width:38px; height:38px;
    display:flex; align-items:center; justify-content:center; flex-shrink:0; transition:all 0.2s;
}
.search-bar button:hover { background:var(--brand-dark); transform:scale(1.05); }

.header-actions { display:flex; align-items:center; gap:8px; flex-shrink:0; }
.header-action {
    display:flex; align-items:center; gap:8px; color:var(--text-secondary); font-weight:600;
    font-size:14px; position:relative; padding:8px 12px; border-radius:var(--radius-sm); transition:all 0.2s;
}
.header-action:hover { color:var(--brand); background:rgba(108,92,231,0.04); }
.header-action i { font-size:18px; }

.badge {
    position:absolute; top:2px; right:0; background:var(--danger); color:#fff;
    border-radius:var(--radius-pill); min-width:18px; height:18px; font-size:11px;
    font-weight:800; display:flex; align-items:center; justify-content:center; padding:0 5px;
}

.user-avatar {
    width:34px; height:34px; border-radius:50%;
    background:linear-gradient(135deg,var(--brand),var(--brand-light));
    color:#fff; display:flex; align-items:center; justify-content:center; font-weight:700; font-size:13px;
}

/* Mobile Menu Toggle */
.mobile-menu-toggle {
    display:none; background:none; border:none; font-size:22px; color:var(--text);
    padding:8px; border-radius:var(--radius-sm);
}

/* ---- NAV ---- */
nav { border-top:1px solid var(--border); background:#fff; }
.nav-links { display:flex; gap:4px; padding:0; margin:0; overflow-x:auto; -webkit-overflow-scrolling:touch; }
.nav-links li a {
    color:var(--text-secondary); font-weight:600; font-size:14px; padding:14px 16px;
    display:block; position:relative; transition:color 0.2s; white-space:nowrap;
}
.nav-links li a:hover { color:var(--brand); }
.nav-links li a::after {
    content:''; position:absolute; bottom:0; left:16px; right:16px; height:2px;
    background:var(--brand); border-radius:2px; transform:scaleX(0); transition:transform 0.25s var(--ease);
}
.nav-links li a:hover::after { transform:scaleX(1); }

/* ---- HERO ---- */
.hero { margin:24px auto 0; max-width:1300px; padding:0 24px; }
.hero-banner {
    position:relative; border-radius:var(--radius-lg); overflow:hidden;
    background:linear-gradient(135deg, #1A1A2E 0%, #16213E 50%, #0F3460 100%);
    min-height:460px; display:flex; align-items:center; box-shadow:var(--shadow-lg);
}
.hero-banner::before {
    content:''; position:absolute; top:-40%; left:-15%; width:60%; height:140%;
    background:radial-gradient(circle,rgba(108,92,231,0.35) 0%,transparent 70%); z-index:1; border-radius:50%;
}
.hero-banner::after {
    content:''; position:absolute; bottom:-25%; right:-8%; width:45%; height:90%;
    background:radial-gradient(circle,rgba(0,206,201,0.25) 0%,transparent 70%); z-index:1; border-radius:50%;
}
.hero-content { position:relative; z-index:2; padding:56px; max-width:580px; }
.hero-tag {
    display:inline-block; padding:6px 16px; background:rgba(255,255,255,0.08);
    backdrop-filter:blur(8px); border:1px solid rgba(255,255,255,0.15);
    border-radius:var(--radius-pill); color:var(--accent); font-weight:700;
    font-size:12px; margin-bottom:20px; text-transform:uppercase; letter-spacing:1.5px;
}
.hero-title { font-size:3.2rem; font-weight:900; color:#fff; line-height:1.08; margin-bottom:20px; letter-spacing:-1px; }
.hero-title span { background:linear-gradient(135deg,var(--accent),#55EFC4); -webkit-background-clip:text; -webkit-text-fill-color:transparent; }
.hero-subtitle { font-size:1.05rem; color:rgba(255,255,255,0.75); margin-bottom:32px; line-height:1.7; max-width:440px; }
.hero-actions { display:flex; gap:12px; flex-wrap:wrap; }

.btn { padding:13px 28px; border-radius:12px; font-weight:700; font-size:15px; cursor:pointer; transition:all 0.25s var(--ease); display:inline-flex; align-items:center; justify-content:center; gap:8px; border:none; }
.btn-primary { background:linear-gradient(135deg,var(--brand),var(--brand-dark)); color:#fff; box-shadow:var(--shadow-glow); }
.btn-primary:hover { transform:translateY(-2px); box-shadow:0 8px 25px rgba(108,92,231,0.4); }
.btn-glass { background:rgba(255,255,255,0.08); backdrop-filter:blur(12px); border:1px solid rgba(255,255,255,0.15); color:#fff; }
.btn-glass:hover { background:rgba(255,255,255,0.15); transform:translateY(-2px); }

.hero-image {
    position:absolute; right:4%; bottom:0; z-index:2; width:42%; max-width:520px;
    filter:drop-shadow(0 20px 40px rgba(0,0,0,0.4)); animation:heroFloat 8s ease-in-out infinite;
}
@keyframes heroFloat { 0%,100%{transform:translateY(0)} 50%{transform:translateY(-16px)} }

/* ---- TRUST BADGES ---- */
.trust-badges { display:grid; grid-template-columns:repeat(4,1fr); gap:16px; margin:48px 0 0; }
.trust-badge {
    background:#fff; padding:22px 20px; border-radius:var(--radius-md); border:1px solid var(--border);
    display:flex; align-items:center; gap:14px; transition:all 0.25s var(--ease);
}
.trust-badge:hover { transform:translateY(-3px); box-shadow:var(--shadow-md); border-color:var(--brand-light); }
.trust-icon {
    width:46px; height:46px; background:linear-gradient(135deg,rgba(108,92,231,0.1),rgba(162,155,254,0.1));
    color:var(--brand); border-radius:12px; display:flex; align-items:center; justify-content:center; font-size:20px; flex-shrink:0;
}
.trust-text h4 { font-size:14px; font-weight:700; color:var(--text); margin-bottom:2px; }
.trust-text p { font-size:12px; color:var(--text-secondary); }

/* ---- SECTION TITLES ---- */
.section-title {
    font-size:1.8rem; font-weight:800; color:var(--text); text-align:center; margin-bottom:2rem; letter-spacing:-0.5px;
}

/* ---- CATEGORIES ---- */
.categories-section { padding:56px 0 0; }
.category-grid { display:flex; flex-wrap:wrap; gap:10px; justify-content:center; }
.category-card {
    background:#fff; padding:12px 24px; border-radius:var(--radius-pill); font-weight:600; font-size:14px;
    color:var(--text-secondary); border:1.5px solid var(--border); transition:all 0.25s var(--ease);
    display:flex; align-items:center; gap:8px;
}
.category-card:hover,.category-card.active {
    background:var(--brand); color:#fff; border-color:var(--brand);
    transform:translateY(-2px); box-shadow:var(--shadow-glow);
}

/* ---- PRODUCTS ---- */
.products-section { padding:56px 0 40px; }
.section-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:32px; flex-wrap:wrap; gap:16px; }
.section-header .section-title { margin-bottom:0; text-align:left; }

.product-filters {
    display:flex; gap:4px; background:#fff; padding:4px; border-radius:var(--radius-pill);
    border:1.5px solid var(--border);
}
.filter-tab {
    padding:9px 20px; border-radius:var(--radius-pill); background:transparent; border:none;
    font-weight:600; color:var(--text-secondary); font-size:13px; transition:all 0.2s;
}
.filter-tab:hover { color:var(--brand); }
.filter-tab.active { background:var(--text); color:#fff; }

.product-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(260px,1fr)); gap:24px; }

.product-card {
    background:#fff; border-radius:var(--radius-md); overflow:hidden; border:1px solid var(--border);
    transition:all 0.3s var(--ease); position:relative; display:flex; flex-direction:column;
}
.product-card:hover { transform:translateY(-6px); box-shadow:var(--shadow-lg); border-color:transparent; }

.product-badge {
    position:absolute; top:14px; left:14px; padding:5px 12px; border-radius:var(--radius-pill);
    font-size:11px; font-weight:800; z-index:10; letter-spacing:0.5px; text-transform:uppercase;
}
.badge-sale { background:linear-gradient(135deg,var(--danger),#EE5A24); color:#fff; }
.badge-new { background:linear-gradient(135deg,var(--success),#55EFC4); color:#fff; }

.product-image-wrap { position:relative; padding-top:100%; overflow:hidden; background:var(--bg); }
.product-image { position:absolute; top:0; left:0; width:100%; height:100%; object-fit:cover; transition:transform 0.5s var(--ease); }
.product-card:hover .product-image { transform:scale(1.06); }

.product-quick-actions {
    position:absolute; bottom:14px; left:0; width:100%; display:flex; justify-content:center; gap:8px;
    opacity:0; transform:translateY(12px); transition:all 0.3s var(--ease); z-index:10;
}
.product-card:hover .product-quick-actions { opacity:1; transform:translateY(0); }

.btn-wishlist {
    width:40px; height:40px; border-radius:50%; background:rgba(255,255,255,0.9); backdrop-filter:blur(8px);
    border:none; color:var(--text); display:flex; align-items:center; justify-content:center;
    font-size:16px; cursor:pointer; box-shadow:var(--shadow-md); transition:all 0.2s;
}
.btn-wishlist:hover { background:#fff; color:var(--danger); transform:scale(1.1); }
.btn-wishlist.in-wishlist { color:var(--danger); }

.product-info { padding:20px; display:flex; flex-direction:column; flex:1; }
.product-category { color:var(--brand); font-size:12px; font-weight:700; text-transform:uppercase; letter-spacing:0.5px; margin-bottom:6px; }
.product-title { font-size:1rem; font-weight:700; color:var(--text); margin-bottom:8px; line-height:1.4; display:-webkit-box; -webkit-line-clamp:2; -webkit-box-orient:vertical; overflow:hidden; }

.product-rating { display:flex; align-items:center; gap:6px; margin-bottom:12px; }
.stars { color:var(--warning); font-size:13px; }
.rating-count { color:var(--text-secondary); font-size:12px; }

.product-price-wrap,.product-price { display:flex; align-items:baseline; gap:10px; margin-bottom:16px; margin-top:auto; }
.current-price { font-size:1.25rem; font-weight:800; color:var(--text); }
.original-price { font-size:0.9rem; color:var(--text-light); text-decoration:line-through; }

.btn-cart {
    width:100%; padding:12px; border-radius:10px; background:var(--bg); color:var(--text);
    border:1.5px solid var(--border); font-weight:700; font-size:14px; display:flex;
    justify-content:center; align-items:center; gap:6px; transition:all 0.25s var(--ease);
}
.product-card:hover .btn-cart { background:var(--brand); color:#fff; border-color:var(--brand); }
.btn-cart.disabled { opacity:0.4; cursor:not-allowed; background:var(--bg)!important; color:var(--text-secondary)!important; border-color:var(--border)!important; }

/* ---- NEWSLETTER ---- */
.newsletter {
    background:linear-gradient(135deg,var(--brand),#0F3460); padding:80px 0; position:relative; overflow:hidden; margin-top:40px;
}
.newsletter::before {
    content:''; position:absolute; top:-60px; left:-60px; width:300px; height:300px;
    background:radial-gradient(circle,rgba(255,255,255,0.06) 0%,transparent 70%); border-radius:50%;
}
.newsletter::after {
    content:''; position:absolute; bottom:-80px; right:-80px; width:350px; height:350px;
    background:radial-gradient(circle,rgba(0,206,201,0.12) 0%,transparent 70%); border-radius:50%;
}
.newsletter .container { position:relative; z-index:2; text-align:center; max-width:640px; }
.newsletter h2 { font-size:2.2rem; font-weight:800; color:#fff; margin-bottom:12px; letter-spacing:-0.5px; }
.newsletter p { font-size:1rem; color:rgba(255,255,255,0.75); margin-bottom:32px; }
.newsletter-form {
    display:flex; background:#fff; padding:6px; border-radius:var(--radius-pill);
    box-shadow:0 8px 32px rgba(0,0,0,0.15); max-width:480px; margin:0 auto;
}
.newsletter-form input { flex:1; border:none; padding:14px 20px; background:transparent; outline:none; font-size:15px; color:var(--text); font-family:inherit; }
.newsletter-form button {
    background:var(--text); color:#fff; border:none; padding:0 28px; border-radius:var(--radius-pill);
    font-weight:700; font-size:14px; transition:all 0.25s; white-space:nowrap;
}
.newsletter-form button:hover { background:var(--brand); }

/* ---- FOOTER ---- */
footer { background:var(--bg-dark); color:#fff; padding:64px 0 24px; }
.footer-content { display:grid; grid-template-columns:repeat(auto-fit,minmax(220px,1fr)); gap:40px; margin-bottom:48px; }
.footer-column h3 { font-size:16px; font-weight:700; margin-bottom:20px; position:relative; padding-bottom:12px; }
.footer-column h3::after { content:''; position:absolute; bottom:0; left:0; width:32px; height:2px; background:var(--brand); border-radius:2px; }
.footer-column p { color:var(--text-light); font-size:14px; line-height:1.7; margin-bottom:16px; }
.footer-column ul li { margin-bottom:10px; }
.footer-column ul li a,.footer-links li a { color:var(--text-light); font-size:14px; transition:all 0.2s; }
.footer-column ul li a:hover,.footer-links li a:hover { color:var(--brand-light); padding-left:4px; }
.footer-column ul li i { margin-right:8px; color:var(--brand-light); width:16px; }
.social-icons { display:flex; gap:10px; margin-top:16px; }
.social-icons a {
    width:38px; height:38px; border-radius:50%; background:rgba(255,255,255,0.06); color:rgba(255,255,255,0.7);
    display:flex; align-items:center; justify-content:center; transition:all 0.25s; font-size:14px;
}
.social-icons a:hover { background:var(--brand); color:#fff; transform:translateY(-2px); }
.footer-bottom { text-align:center; padding-top:24px; border-top:1px solid rgba(255,255,255,0.06); color:var(--text-secondary); font-size:13px; }

/* ---- LOADING / SPINNER ---- */
.loading { display:flex; justify-content:center; padding:40px; width:100%; }
.spinner { width:36px; height:36px; border:3px solid var(--border); border-left-color:var(--brand); border-radius:50%; animation:spin 0.8s linear infinite; }
@keyframes spin { to{transform:rotate(360deg)} }

/* ---- MODAL ---- */
.modal { display:none; position:fixed; top:0; left:0; width:100%; height:100%; background:rgba(26,26,46,0.6); backdrop-filter:blur(4px); z-index:2000; align-items:center; justify-content:center; }
.modal-content { background:#fff; padding:28px; border-radius:var(--radius-lg); position:relative; max-width:800px; width:90%; box-shadow:0 25px 60px rgba(0,0,0,0.2); }
.close-modal { position:absolute; top:16px; right:20px; font-size:28px; cursor:pointer; color:var(--text-secondary); transition:color 0.2s; background:none; border:none; }
.close-modal:hover { color:var(--danger); }

/* ---- PAGINATION ---- */
#pagination { display:flex; justify-content:center; gap:6px; margin-top:32px; flex-wrap:wrap; }

/* ---- EMPTY STATE ---- */
.empty-state {
    text-align:center; padding:48px 20px; color:var(--text-secondary);
}
.empty-state a { color:var(--brand); font-weight:600; }
.empty-state a:hover { text-decoration:underline; }

/* ---- TOAST (shared) ---- */
.toast-container { position:fixed; top:24px; right:24px; z-index:9999; display:flex; flex-direction:column; gap:8px; }

/* ---- RESPONSIVE ---- */
@media(max-width:1024px) {
    .hero-banner { min-height:400px; }
    .hero-title { font-size:2.6rem; }
    .hero-content { padding:40px; }
    .trust-badges { grid-template-columns:repeat(2,1fr); }
}

@media(max-width:768px) {
    .top-header .container { flex-direction:column; gap:6px; text-align:center; }
    .top-header-links { display:none; }
    .search-bar { display:none; }
    .header-actions .header-action span { display:none; }
    .mobile-menu-toggle { display:block; }
    .hero-banner { flex-direction:column; text-align:center; min-height:auto; padding:32px 20px; }
    .hero-content { padding:24px 0; max-width:100%; }
    .hero-title { font-size:2rem; }
    .hero-image { position:relative; width:70%; right:auto; bottom:auto; margin:20px auto 0; }
    .hero-actions { justify-content:center; }
    .trust-badges { grid-template-columns:1fr; gap:12px; }
    .section-header { flex-direction:column; align-items:stretch; }
    .product-filters { overflow-x:auto; white-space:nowrap; justify-content:flex-start; }
    .product-grid { grid-template-columns:repeat(auto-fill,minmax(220px,1fr)); gap:16px; }
    .newsletter h2 { font-size:1.6rem; }
    .newsletter-form { flex-direction:column; background:transparent; box-shadow:none; gap:10px; padding:0; }
    .newsletter-form input { background:#fff; border-radius:var(--radius-pill); padding:14px 20px; }
    .newsletter-form button { padding:14px 24px; border-radius:var(--radius-pill); }
    .footer-content { grid-template-columns:1fr; gap:32px; }
    .nav-links { padding:8px 0; gap:0; }
}

@media(max-width:480px) {
    .container { padding:0 16px; }
    .hero { padding:0 16px; margin-top:16px; }
    .hero-title { font-size:1.75rem; }
    .btn { padding:12px 20px; font-size:14px; }
    .section-title { font-size:1.4rem; }
    .product-grid { grid-template-columns:1fr; }
}