/* ===== CSS Variables ===== */
:root {
    --primary: #ff6b8b;
    --primary-dark: #e84a6f;
    --secondary: #ffd166;
    --dark: #2d3142;
    --light: #f8f9fa;
    --white: #ffffff;
    --gray: #6c757d;
    --light-gray: #e9ecef;
    --success: #2ed573;
    --danger: #ff4757;
    --shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 10px 40px rgba(0, 0, 0, 0.12);
    --transition: all 0.3s ease;
    --radius: 16px;
    --radius-sm: 12px;
    --header-height: 64px;
}

/* ===== Reset & Base ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--header-height);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    color: var(--dark);
    background-color: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-tap-highlight-color: transparent;
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

button {
    cursor: pointer;
    border: none;
    outline: none;
    font-family: inherit;
}

input, textarea, select {
    font-family: inherit;
    outline: none;
}

/* ===== Container ===== */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 16px;
}

/* ===== Header ===== */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--header-height);
    background: var(--white);
    box-shadow: var(--shadow);
    z-index: 1000;
    display: flex;
    align-items: center;
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--dark);
}

.logo-img {
    width: 36px;
    height: 36px;
    object-fit: contain;
}

.navbar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 85%;
    max-width: 320px;
    height: 100vh;
    height: 100dvh;
    background: var(--white);
    padding: calc(var(--header-height) + 20px) 20px 20px;
    transition: var(--transition);
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.1);
    z-index: 999;
    overflow-y: auto;
}

.navbar.active {
    right: 0;
}

.navbar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 998;
}

.navbar-overlay.active {
    opacity: 1;
    visibility: visible;
}

.nav-links {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.nav-links li {
    border-bottom: 1px solid var(--light-gray);
}

.nav-links a {
    display: block;
    padding: 16px 0;
    font-size: 1.05rem;
    font-weight: 500;
    color: var(--dark);
    position: relative;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
    padding-left: 8px;
}

.nav-icons {
    display: flex;
    align-items: center;
    gap: 4px;
}

.icon-btn {
    width: 44px;
    height: 44px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--dark);
    font-size: 1.1rem;
    transition: var(--transition);
    position: relative;
}

.icon-btn:hover {
    background: var(--light);
    color: var(--primary);
}

.cart-btn .cart-count {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 18px;
    height: 18px;
    background: var(--primary);
    color: white;
    border-radius: 50%;
    font-size: 0.7rem;
    font-weight: 700;
    display: grid;
    place-items: center;
}

.hamburger {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 44px;
    height: 44px;
    gap: 5px;
    cursor: pointer;
    background: none;
    padding: 0;
}

.hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--dark);
    transition: var(--transition);
    border-radius: 2px;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* ===== Hero Section ===== */
.hero {
    position: relative;
    min-height: 100vh;
    min-height: 100dvh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: url('https://images.pexels.com/photos/1912868/pexels-photo-1912868.jpeg?auto=compress&cs=tinysrgb&w=1200&q=80') center/cover no-repeat;
    overflow: hidden;
    padding-top: var(--header-height);
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(45, 49, 66, 0.75) 0%, rgba(255, 107, 139, 0.65) 50%, rgba(255, 209, 102, 0.55) 100%);
    backdrop-filter: blur(3px);
    -webkit-backdrop-filter: blur(3px);
}

.hero-content {
    position: relative;
    z-index: 1;
    text-align: center;
    padding: 20px;
    max-width: 600px;
}

.hero h1 {
    font-size: clamp(2rem, 7vw, 3.5rem);
    font-weight: 800;
    color: var(--dark);
    margin-bottom: 16px;
    line-height: 1.15;
    letter-spacing: -0.5px;
}

.hero p {
    font-size: clamp(1rem, 3vw, 1.25rem);
    color: var(--dark);
    opacity: 0.85;
    margin-bottom: 28px;
    line-height: 1.6;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 16px 36px;
    background: var(--primary);
    color: white;
    border-radius: 50px;
    font-weight: 600;
    font-size: 1rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: var(--transition);
    border: 2px solid var(--primary);
    min-height: 52px;
    gap: 8px;
}

.btn:hover {
    background: transparent;
    color: var(--primary);
    transform: translateY(-2px);
}

.btn-outline {
    background: transparent;
    color: var(--primary);
    border: 2px solid var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

/* ===== Section Titles ===== */
.section-title {
    text-align: center;
    font-size: clamp(1.6rem, 5vw, 2.2rem);
    font-weight: 700;
    margin-bottom: 2.5rem;
    color: var(--dark);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--primary);
    margin: 12px auto 0;
    border-radius: 2px;
}

/* ===== Categories Section ===== */
.categories {
    padding: 60px 0;
    background: var(--white);
}

.category-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.category-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    cursor: pointer;
    border: 1px solid var(--light-gray);
}

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

.category-img {
    position: relative;
    height: 220px;
    overflow: hidden;
}

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

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

.category-info {
    padding: 20px;
    text-align: center;
}

.category-info h3 {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--dark);
}

.category-info p {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 8px;
}

.category-info .price {
    font-weight: 700;
    color: var(--primary);
    font-size: 1.05rem;
}

/* ===== Products Section ===== */
.products {
    padding: 60px 0;
    background: var(--light);
}

.product-filters {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    padding: 0 0 20px;
    margin-bottom: 10px;
    scrollbar-width: none;
    -ms-overflow-style: none;
    scroll-snap-type: x mandatory;
}

.product-filters::-webkit-scrollbar {
    display: none;
}

.filter-btn {
    flex-shrink: 0;
    padding: 10px 22px;
    border: 2px solid var(--light-gray);
    border-radius: 50px;
    background: var(--white);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
    scroll-snap-align: start;
    color: var(--dark);
}

.filter-btn:hover,
.filter-btn.active {
    background: var(--primary);
    color: white;
    border-color: var(--primary);
}

.product-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.product-card {
    background: var(--white);
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border: 1px solid var(--light-gray);
}

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

.product-img {
    position: relative;
    height: 240px;
    overflow: hidden;
}

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

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

.badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 5px 14px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge.sale {
    background: var(--danger);
    color: white;
}

.badge.new {
    background: var(--secondary);
    color: var(--dark);
}

.product-info {
    padding: 18px;
}

.product-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--dark);
}

.product-desc {
    color: var(--gray);
    font-size: 0.85rem;
    margin-bottom: 12px;
    line-height: 1.5;
}

.product-price {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    flex-wrap: wrap;
}

.sale-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--primary);
}

.original-price {
    font-size: 0.95rem;
    color: var(--gray);
    text-decoration: line-through;
}

.add-to-cart {
    width: 100%;
    padding: 14px;
    background: var(--dark);
    color: white;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 0.95rem;
    transition: var(--transition);
    min-height: 48px;
}

.add-to-cart:hover {
    background: var(--primary);
}

.add-to-cart.added {
    background: var(--success);
}

/* ===== Features Section ===== */
.features {
    padding: 60px 0;
    background: var(--dark);
    color: white;
}

.feature-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.feature-item {
    text-align: center;
    padding: 28px 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius);
    transition: var(--transition);
}

.feature-item:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-4px);
}

.feature-item i {
    font-size: 2.5rem;
    color: var(--secondary);
    margin-bottom: 16px;
}

.feature-item h3 {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.feature-item p {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* ===== About Section ===== */
.about {
    padding: 60px 0;
    background: var(--white);
}

.about-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.about-card {
    text-align: center;
    padding: 30px 20px;
    border-radius: var(--radius);
    border: 1px solid var(--light-gray);
    transition: var(--transition);
}

.about-card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-4px);
}

.about-icon {
    width: 70px;
    height: 70px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 50%;
    display: grid;
    place-items: center;
    margin: 0 auto 20px;
}

.about-icon i {
    font-size: 1.8rem;
    color: white;
}

.about-card h3 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--dark);
}

.about-card p {
    color: var(--gray);
    font-size: 0.9rem;
    line-height: 1.6;
}

/* ===== Newsletter ===== */
.newsletter {
    padding: 60px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
}

.newsletter-content h2 {
    font-size: clamp(1.5rem, 5vw, 2rem);
    font-weight: 700;
    margin-bottom: 10px;
}

.newsletter p {
    margin-bottom: 24px;
    opacity: 0.9;
    font-size: 1rem;
}

.newsletter-form {
    display: flex;
    flex-direction: column;
    gap: 12px;
    max-width: 480px;
    margin: 0 auto;
}

.newsletter-form input {
    flex: 1;
    padding: 16px 20px;
    border: none;
    border-radius: 50px;
    outline: none;
    font-size: 1rem;
    min-height: 52px;
}

.newsletter-form button {
    padding: 16px 32px;
    background: var(--secondary);
    color: var(--dark);
    border: none;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition);
    min-height: 52px;
}

.newsletter-form button:hover {
    background: white;
    transform: translateY(-2px);
}

/* ===== Footer ===== */
.footer {
    background: #1a1a2e;
    color: white;
    padding: 50px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.footer-col h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 3px;
    background: var(--primary);
    border-radius: 2px;
}

.footer-col ul li {
    margin-bottom: 12px;
}

.footer-col ul li a {
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.95rem;
    transition: var(--transition);
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.footer-col ul li a:hover {
    color: white;
    padding-left: 5px;
}

.footer-col ul li a i {
    width: 16px;
    color: var(--primary);
}

.footer .logo {
    margin-bottom: 15px;
}

.footer .logo-img {
    width: 40px;
    height: 40px;
}

.social-links {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.social-links a {
    width: 44px;
    height: 44px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: white;
    transition: var(--transition);
    font-size: 1.1rem;
}

.social-links a:hover {
    background: var(--primary);
    transform: translateY(-3px);
}

.copyright {
    text-align: center;
    padding-top: 24px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.9rem;
}

/* ===== Cart Sidebar ===== */
.cart-sidebar {
    position: fixed;
    top: 0;
    right: -100%;
    width: 100%;
    max-width: 400px;
    height: 100vh;
    height: 100dvh;
    background: var(--white);
    box-shadow: -5px 0 30px rgba(0, 0, 0, 0.15);
    z-index: 1001;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
}

.cart-sidebar.active {
    right: 0;
}

.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--light-gray);
}

.cart-header h3 {
    font-size: 1.2rem;
    font-weight: 700;
}

.cart-close {
    width: 40px;
    height: 40px;
    display: grid;
    place-items: center;
    background: none;
    font-size: 1.5rem;
    color: var(--dark);
    border-radius: 50%;
    transition: var(--transition);
}

.cart-close:hover {
    background: var(--light);
    color: var(--primary);
}

.cart-items {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
}

.empty-cart {
    text-align: center;
    color: var(--gray);
    padding: 40px 0;
    font-size: 1rem;
}

.cart-item {
    display: flex;
    gap: 14px;
    padding: 14px 0;
    border-bottom: 1px solid var(--light-gray);
}

.cart-item-img {
    width: 70px;
    height: 70px;
    border-radius: var(--radius-sm);
    overflow: hidden;
    flex-shrink: 0;
}

.cart-item-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-details {
    flex: 1;
    min-width: 0;
}

.cart-item-details h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 4px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.cart-item-details .cart-item-price {
    color: var(--primary);
    font-weight: 700;
    font-size: 0.95rem;
    margin-bottom: 8px;
}

.cart-item-controls {
    display: flex;
    align-items: center;
    gap: 10px;
}

.qty-btn {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    background: var(--light);
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--dark);
    transition: var(--transition);
}

.qty-btn:hover {
    background: var(--primary);
    color: white;
}

.qty-value {
    font-weight: 600;
    min-width: 20px;
    text-align: center;
}

.cart-item-remove {
    margin-left: auto;
    background: none;
    color: var(--gray);
    font-size: 0.9rem;
    padding: 4px;
    transition: var(--transition);
}

.cart-item-remove:hover {
    color: var(--danger);
}

.cart-footer {
    padding: 20px;
    border-top: 1px solid var(--light-gray);
}

.cart-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    font-size: 1.1rem;
    font-weight: 700;
}

.checkout-btn {
    width: 100%;
    padding: 16px;
    background: var(--primary);
    color: white;
    border-radius: var(--radius-sm);
    font-weight: 700;
    font-size: 1rem;
    transition: var(--transition);
    min-height: 52px;
}

.checkout-btn:hover {
    background: var(--primary-dark);
}

/* ===== Notification ===== */
.notification {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%) translateY(100px);
    background: var(--dark);
    color: white;
    padding: 14px 24px;
    border-radius: 50px;
    box-shadow: var(--shadow-lg);
    z-index: 2000;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.95rem;
    font-weight: 500;
    opacity: 0;
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    white-space: nowrap;
    max-width: 90vw;
}

.notification.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.notification i {
    color: var(--success);
    font-size: 1.2rem;
}

/* ===== Animations ===== */
@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-in {
    animation: fadeInUp 0.6s ease forwards;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: var(--light);
}

::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}

/* ===== Mobile Optimizations ===== */
@media (max-width: 767px) {
    .container {
        padding: 0 14px;
    }
    
    .header {
        height: 60px;
    }
    
    :root {
        --header-height: 60px;
    }
    
    .logo {
        font-size: 1.2rem;
        gap: 6px;
    }
    
    .logo-img {
        width: 32px;
        height: 32px;
    }
    
    .icon-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .cart-btn .cart-count {
        width: 16px;
        height: 16px;
        font-size: 0.65rem;
        top: 2px;
        right: 2px;
    }
    
    .hamburger {
        width: 40px;
        height: 40px;
    }
    
    .hamburger span {
        width: 20px;
        height: 2px;
    }
    
    .hamburger.active span:nth-child(1) {
        transform: rotate(45deg) translate(4px, 4px);
    }
    
    .hamburger.active span:nth-child(3) {
        transform: rotate(-45deg) translate(4px, -4px);
    }
    
    .hero {
        min-height: 100vh;
        min-height: 100dvh;
        padding-top: var(--header-height);
        padding-bottom: 40px;
    }
    
    .hero-content {
        padding: 16px;
        max-width: 100%;
    }
    
    .hero h1 {
        font-size: clamp(1.8rem, 8vw, 2.4rem);
        margin-bottom: 12px;
        line-height: 1.2;
    }
    
    .hero p {
        font-size: 1rem;
        margin-bottom: 24px;
        opacity: 0.9;
    }
    
    .btn {
        width: 100%;
        max-width: 280px;
        padding: 16px 28px;
        font-size: 0.95rem;
        min-height: 52px;
    }
    
    .categories {
        padding: 50px 0 40px;
    }
    
    .section-title {
        font-size: 1.6rem;
        margin-bottom: 1.8rem;
    }
    
    .section-title::after {
        width: 50px;
        height: 3px;
        margin: 10px auto 0;
    }
    
    .category-grid {
        gap: 16px;
    }
    
    .category-card {
        border-radius: var(--radius-sm);
    }
    
    .category-img {
        height: 180px;
    }
    
    .category-info {
        padding: 16px;
    }
    
    .category-info h3 {
        font-size: 1.2rem;
    }
    
    .category-info p {
        font-size: 0.85rem;
    }
    
    .category-info .price {
        font-size: 0.95rem;
    }
    
    .products {
        padding: 40px 0;
    }
    
    .product-filters {
        gap: 8px;
        padding-bottom: 16px;
        margin-bottom: 8px;
    }
    
    .filter-btn {
        padding: 10px 18px;
        font-size: 0.85rem;
    }
    
    .product-grid {
        gap: 16px;
    }
    
    .product-card {
        border-radius: var(--radius-sm);
    }
    
    .product-img {
        height: 220px;
    }
    
    .product-info {
        padding: 16px;
    }
    
    .product-info h3 {
        font-size: 1.05rem;
    }
    
    .product-desc {
        font-size: 0.8rem;
        margin-bottom: 10px;
    }
    
    .sale-price {
        font-size: 1.15rem;
    }
    
    .original-price {
        font-size: 0.85rem;
    }
    
    .add-to-cart {
        padding: 14px;
        font-size: 0.9rem;
        min-height: 48px;
        border-radius: var(--radius-sm);
    }
    
    .badge {
        top: 10px;
        left: 10px;
        padding: 4px 10px;
        font-size: 0.7rem;
    }
    
    .features {
        padding: 50px 0;
    }
    
    .feature-grid {
        gap: 12px;
    }
    
    .feature-item {
        padding: 24px 16px;
        border-radius: var(--radius-sm);
    }
    
    .feature-item i {
        font-size: 2rem;
        margin-bottom: 12px;
    }
    
    .feature-item h3 {
        font-size: 1rem;
    }
    
    .feature-item p {
        font-size: 0.85rem;
    }
    
    .about {
        padding: 50px 0;
    }
    
    .about-grid {
        gap: 16px;
    }
    
    .about-card {
        padding: 24px 16px;
        border-radius: var(--radius-sm);
    }
    
    .about-icon {
        width: 60px;
        height: 60px;
        margin-bottom: 16px;
    }
    
    .about-icon i {
        font-size: 1.5rem;
    }
    
    .about-card h3 {
        font-size: 1.05rem;
    }
    
    .about-card p {
        font-size: 0.85rem;
    }
    
    .newsletter {
        padding: 50px 0;
    }
    
    .newsletter-content h2 {
        font-size: 1.5rem;
    }
    
    .newsletter p {
        font-size: 0.9rem;
        margin-bottom: 20px;
    }
    
    .newsletter-form {
        gap: 10px;
    }
    
    .newsletter-form input {
        padding: 14px 18px;
        font-size: 0.95rem;
        min-height: 48px;
    }
    
    .newsletter-form button {
        padding: 14px 24px;
        font-size: 0.95rem;
        min-height: 48px;
    }
    
    .footer {
        padding: 40px 0 20px;
    }
    
    .footer-grid {
        gap: 28px;
        margin-bottom: 24px;
    }
    
    .footer-col h3 {
        font-size: 1.05rem;
        margin-bottom: 16px;
    }
    
    .footer-col ul li {
        margin-bottom: 10px;
    }
    
    .footer-col ul li a {
        font-size: 0.9rem;
    }
    
    .footer .logo {
        margin-bottom: 12px;
    }
    
    .footer .logo-img {
        width: 36px;
        height: 36px;
    }
    
    .social-links {
        gap: 10px;
        margin-top: 16px;
    }
    
    .social-links a {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .copyright {
        padding-top: 20px;
        font-size: 0.8rem;
    }
    
    .cart-sidebar {
        width: 100%;
        max-width: 100%;
    }
    
    .cart-header {
        padding: 16px;
    }
    
    .cart-header h3 {
        font-size: 1.1rem;
    }
    
    .cart-items {
        padding: 16px;
    }
    
    .cart-item {
        gap: 12px;
    }
    
    .cart-item-img {
        width: 60px;
        height: 60px;
    }
    
    .cart-item-details h4 {
        font-size: 0.9rem;
    }
    
    .cart-item-details .cart-item-price {
        font-size: 0.9rem;
    }
    
    .cart-footer {
        padding: 16px;
    }
    
    .cart-total {
        font-size: 1rem;
    }
    
    .checkout-btn {
        min-height: 48px;
    }
    
    .notification {
        bottom: 16px;
        left: 16px;
        right: 16px;
        transform: translateX(0) translateY(100px);
        max-width: none;
        justify-content: center;
        text-align: center;
        font-size: 0.9rem;
        padding: 12px 20px;
    }
    
    .notification.show {
        transform: translateX(0) translateY(0);
    }
    
    ::-webkit-scrollbar {
        width: 0;
        background: transparent;
    }
}

/* ===== Touch Optimizations ===== */
@media (hover: none) and (pointer: coarse) {
    .category-card:hover,
    .product-card:hover,
    .feature-item:hover,
    .about-card:hover {
        transform: none;
        box-shadow: var(--shadow);
    }
    
    .category-card:active,
    .product-card:active {
        transform: scale(0.98);
        transition: transform 0.15s ease;
    }
    
    .btn:active {
        transform: scale(0.97);
    }
    
    .add-to-cart:active {
        transform: scale(0.97);
    }
    
    .icon-btn:active {
        transform: scale(0.9);
    }
}

/* ===== Performance Optimizations ===== */
.hero,
.category-card,
.product-card,
.feature-item,
.about-card {
    will-change: transform;
    backface-visibility: hidden;
    -webkit-backface-visibility: hidden;
}

.product-img img,
.category-img img {
    will-change: transform;
}

/* ===== Reduced Motion ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
}

/* ===== High DPI Displays ===== */
@media (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi) {
    .logo-img {
        image-rendering: -webkit-optimize-contrast;
    }
}

/* ===== Small Mobile Devices ===== */
@media (max-width: 360px) {
    .container {
        padding: 0 10px;
    }
    
    .hero h1 {
        font-size: 1.6rem;
    }
    
    .hero p {
        font-size: 0.9rem;
    }
    
    .section-title {
        font-size: 1.4rem;
    }
    
    .category-img {
        height: 160px;
    }
    
    .product-img {
        height: 200px;
    }
    
    .filter-btn {
        padding: 8px 14px;
        font-size: 0.8rem;
    }
}

/* ===== Safe Area Insets ===== */
@supports (padding-top: env(safe-area-inset-top)) {
    .header {
        padding-top: env(safe-area-inset-top);
        height: calc(var(--header-height) + env(safe-area-inset-top));
    }
    
    .navbar {
        padding-top: calc(var(--header-height) + env(safe-area-inset-top) + 20px);
    }
    
    .hero {
        padding-top: calc(var(--header-height) + env(safe-area-inset-top));
    }
    
    .cart-sidebar {
        padding-top: env(safe-area-inset-top);
    }
}

/* ===== Tablet Styles ===== */
@media (min-width: 768px) {
    .container {
        padding: 0 24px;
    }

    .header {
        height: 72px;
    }

    :root {
        --header-height: 72px;
    }

    .logo {
        font-size: 1.6rem;
    }

    .logo-img {
        width: 42px;
        height: 42px;
    }

    .hamburger {
        display: none;
    }

    .navbar {
        position: static;
        width: auto;
        height: auto;
        background: transparent;
        padding: 0;
        box-shadow: none;
        transform: none;
        overflow: visible;
    }

    .navbar-overlay {
        display: none;
    }

    .nav-links {
        flex-direction: row;
        gap: 32px;
    }

    .nav-links li {
        border-bottom: none;
    }

    .nav-links a {
        padding: 0;
        font-size: 1rem;
    }

    .nav-links a:hover,
    .nav-links a.active {
        padding-left: 0;
    }

    .nav-links a::after {
        content: '';
        position: absolute;
        bottom: -4px;
        left: 0;
        width: 0;
        height: 2px;
        background: var(--primary);
        transition: var(--transition);
    }

    .nav-links a:hover::after,
    .nav-links a.active::after {
        width: 100%;
    }

    .hero {
        min-height: 90vh;
        min-height: 90dvh;
    }

    .hero h1 {
        font-size: clamp(2.5rem, 5vw, 3.5rem);
    }

    .hero p {
        font-size: 1.15rem;
    }

    .category-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 24px;
    }

    .category-img {
        height: 240px;
    }

    .product-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    .product-img {
        height: 260px;
    }

    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    .about-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 24px;
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 40px;
    }

    .newsletter-form {
        flex-direction: row;
    }
}

/* ===== Desktop Styles ===== */
@media (min-width: 1024px) {
    .container {
        padding: 0 32px;
    }

    .header {
        height: 80px;
    }

    :root {
        --header-height: 80px;
    }

    .logo {
        font-size: 1.8rem;
    }

    .logo-img {
        width: 44px;
        height: 44px;
    }

    .nav-links {
        gap: 40px;
    }

    .hero {
        min-height: 100vh;
        min-height: 100dvh;
    }

    .hero h1 {
        font-size: clamp(3rem, 5vw, 4rem);
    }

    .categories {
        padding: 80px 0;
    }

    .products {
        padding: 80px 0;
    }

    .product-grid {
        grid-template-columns: repeat(3, 1fr);
        gap: 30px;
    }

    .product-img {
        height: 280px;
    }

    .feature-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .features {
        padding: 80px 0;
    }

    .about {
        padding: 80px 0;
    }

    .about-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .newsletter {
        padding: 80px 0;
    }

    .footer-grid {
        grid-template-columns: repeat(4, 1fr);
    }

    .footer {
        padding: 60px 0 24px;
    }

    .section-title {
        margin-bottom: 3rem;
    }
}

/* ===== Large Desktop ===== */
@media (min-width: 1200px) {
    .product-grid {
        gap: 32px;
    }
}
