:root {
    /* IKEA-Inspired Premium Palette */
    --ikea-blue: #0051ba;
    --ikea-yellow: #ffda1a;
    --primary: #0051ba;
    --primary-hover: #003e8f;
    --accent: #ffda1a;
    
    /* Neutrals */
    --text-main: #111111;
    --text-muted: #555555;
    --bg-white: #ffffff;
    --bg-gray: #f5f5f5;
    --border-color: #dfdfdf;
    
    /* System Tokens */
    --container-width: 1280px;
    --header-height: 80px;
    --border-radius: 4px;
    --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans', 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.5;
    color: var(--text-main);
    background-color: var(--bg-white);
    -webkit-font-smoothing: antialiased;
}

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

ul {
    list-style: none;
}

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

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
}

/* Typography */
h1, h2, h3, h4 {
    font-weight: 700;
    line-height: 1.2;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    font-weight: 700;
    border-radius: 64px;
    cursor: pointer;
    border: none;
    transition: var(--transition);
    font-size: 0.938rem;
}

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

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

.btn-secondary {
    background-color: var(--bg-gray);
    color: var(--text-main);
}

.btn-secondary:hover {
    background-color: var(--border-color);
}

/* Header */
header {
    height: var(--header-height);
    border-bottom: 1px solid var(--border-color);
    background: white;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-inner {
    height: 100%;
    display: flex;
    align-items: center;
    gap: 40px;
}

.main-nav {
    display: flex;
    gap: 24px;
}

.nav-link {
    font-weight: 500;
    font-size: 0.938rem;
    color: var(--text-main);
    padding: 8px 0;
    position: relative;
}

.nav-link:hover {
    color: var(--ikea-blue);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--ikea-blue);
    transition: var(--transition);
}

.nav-link:hover::after {
    width: 100%;
}

.logo svg {
    height: 40px;
}

.search-bar {
    flex: 1;
    max-width: 600px;
    margin: 0 40px;
    position: relative;
}

.search-bar input {
    width: 100%;
    padding: 12px 20px 12px 48px;
    border-radius: 64px;
    border: 1px solid var(--border-color);
    background: var(--bg-gray);
    font-size: 0.938rem;
    outline: none;
}

.search-bar i {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 12px;
}

.mobile-menu-toggle {
    display: none;
    background: transparent;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    width: 44px;
    height: 44px;
    border-radius: 50%;
}

.mobile-menu-toggle:hover {
    background: var(--bg-gray);
}

.icon-link {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    position: relative;
    font-size: 1.25rem;
}

.icon-link:hover {
    background-color: var(--bg-gray);
}

.badge {
    position: absolute;
    top: 4px;
    right: 4px;
    background: var(--ikea-blue);
    color: white;
    font-size: 0.688rem;
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: 700;
}

/* Main Content */
main {
    padding-top: 40px;
}

/* Grid System */
.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 32px;
}

/* Product Card */
.product-card {
    transition: var(--transition);
}

.product-image {
    position: relative;
    aspect-ratio: 1;
    background-color: var(--bg-gray);
    overflow: hidden;
    margin-bottom: 12px;
}

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

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

.wishlist-toggle {
    position: absolute;
    top: 12px;
    right: 12px;
    background: white;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow);
    cursor: pointer;
    border: none;
    z-index: 10;
    transition: var(--transition);
}

.wishlist-toggle.active i {
    color: #e00707;
    font-weight: 900;
}

.add-to-cart-btn {
    position: absolute;
    bottom: 12px;
    right: 12px;
    background: var(--ikea-blue);
    color: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: none;
    opacity: 0;
    transform: translateY(10px);
    transition: var(--transition);
}

.product-card:hover .add-to-cart-btn {
    opacity: 1;
    transform: translateY(0);
}

.product-info h3 {
    font-size: 1rem;
    margin-bottom: 4px;
}

.product-type {
    color: var(--text-muted);
    font-size: 0.813rem;
    margin-bottom: 8px;
}

.product-price {
    font-weight: 700;
    font-size: 1.25rem;
}

/* Footer */
footer {
    background-color: var(--bg-gray);
    padding: 64px 0 32px;
    margin-top: 80px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 48px;
}

.footer-col h4 {
    margin-bottom: 20px;
}

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

.footer-links a:hover {
    text-decoration: underline;
}

.footer-bottom {
    padding-top: 32px;
    border-top: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.813rem;
    color: var(--text-muted);
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
    .main-nav {
        display: none;
    }
    
    .mobile-menu-toggle {
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .search-bar {
        margin: 0 20px;
    }
}

@media (max-width: 768px) {
    .search-bar {
        display: none;
    }
    
    .footer-bottom {
        flex-direction: column;
        gap: 20px;
        text-align: center;
    }
}

/* Mobile Menu Drawer */
.mobile-drawer {
    position: fixed;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: white;
    z-index: 2000;
    transition: left 0.3s ease;
    padding: 80px 24px 40px;
}

.mobile-drawer.active {
    left: 0;
}

.drawer-close {
    position: absolute;
    top: 20px;
    right: 24px;
    font-size: 1.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
}

.drawer-nav {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.drawer-link {
    font-size: 1.5rem;
    font-weight: 700;
}
