:root {
    --primary: #fb7701; /* Temu Orange */
    --dark: #333;
    --light: #f4f4f4;
    --white: #fff;
}

body {
    font-family: sans-serif;
    margin: 0;
    padding: 0;
    background: var(--light);
    color: var(--dark);
    padding-top: 100px; /* Space for sticky header */
}

/* Header */
.site-header {
    background: var(--white);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    max-width: 1200px;
    margin: 0 auto;
    gap: 20px;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary);
    text-decoration: none;
    min-width: 150px;
}

.search-bar {
    flex: 1;
    display: flex;
    border: 2px solid var(--primary);
    border-radius: 4px;
    overflow: hidden;
    max-width: 600px;
}

.search-bar input {
    flex: 1;
    border: none;
    padding: 10px;
    outline: none;
}

.search-bar button {
    background: var(--primary);
    border: none;
    padding: 0 15px;
    cursor: pointer;
    color: white;
}

.user-actions {
    display: flex;
    gap: 20px;
    min-width: 150px;
    justify-content: flex-end;
}

.icon-link {
    text-decoration: none;
    color: var(--dark);
    font-weight: 500;
    font-size: 0.9rem;
}

/* Categories */
.categories-nav {
    border-top: 1px solid #eee;
    background: var(--white);
}

.categories-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    justify-content: center;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

.categories-nav a {
    text-decoration: none;
    color: var(--dark);
    padding: 10px 0;
    display: block;
    font-size: 0.9rem;
}

.categories-nav a:hover {
    color: var(--primary);
}

/* Grid & Cards */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.card {
    background: var(--white);
    padding: 15px;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
}

.card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 4px;
    background: #eee;
}

.card h3 {
    margin: 10px 0 5px;
    font-size: 1rem;
}

.price {
    color: var(--primary);
    font-weight: bold;
    font-size: 1.2em;
    margin: 0 0 10px;
}

button {
    background: var(--dark);
    color: var(--white);
    border: none;
    padding: 10px;
    width: 100%;
    cursor: pointer;
    margin-top: auto;
    border-radius: 4px;
}

button:hover {
    background: #555;
}

/* Mobile */
@media (max-width: 768px) {
    .header-container {
        flex-wrap: wrap;
    }
    .search-bar {
        order: 3;
        max-width: 100%;
        width: 100%;
        margin-top: 10px;
    }
    .categories-nav ul {
        overflow-x: auto;
        justify-content: flex-start;
        padding: 0 20px;
    }
    body {
        padding-top: 140px;
    }
}
/* Banner */
.banner {
    width: 100%;
    max-width: 1200px;
    margin: 20px auto;
    padding: 0 20px;
}

.banner img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    display: block;
}

@media (max-width: 768px) {
    .banner {
        padding: 0 10px;
        margin: 10px auto;
    }
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal.active { display: flex; }

.modal-content {
    background: white;
    padding: 25px;
    border-radius: 8px;
    width: 90%;
    max-width: 400px;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 10px; right: 15px;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
}

.modal-close:hover { color: #000; }

.auth-tabs {
    display: flex;
    margin-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.tab-btn {
    flex: 1;
    padding: 10px;
    border: none;
    background: none;
    cursor: pointer;
    font-weight: 500;
    color: #666;
}

.tab-btn.active {
    color: var(--primary);
    border-bottom: 2px solid var(--primary);
}

.auth-form { display: flex; flex-direction: column; gap: 12px; }
.auth-form.hidden { display: none; }

.auth-form input {
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 1rem;
}

.auth-form button {
    background: var(--primary);
    color: white;
    padding: 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 1rem;
    margin-top: 5px;
}

.auth-form button:hover { opacity: 0.9; }
