:root {
    --primary-color: #d32f2f;
    --secondary-color: #1976d2;
    --dark-color: #212121;
    --light-color: #f5f5f5;
    --white: #ffffff;
    --shadow: 0 2px 5px rgba(0,0,0,0.1);
    --container-width: 1400px;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    background-color: var(--light-color);
    color: var(--dark-color);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.top-bar {
    background-color: var(--dark-color);
    color: var(--white);
    padding: 8px 20px;
    font-size: 0.8rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.main-nav {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    max-width: var(--container-width);
    margin: 0 auto;
    flex-wrap: nowrap;
    gap: 30px;
}

.logo {
    font-size: 1.8rem;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo span {
    color: var(--dark-color);
}

.search-container {
    flex-grow: 1;
    display: flex;
    max-width: 600px;
}

.search-container input {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ccc;
    border-radius: 4px 0 0 4px;
    outline: none;
}

.search-container button {
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 0 4px 4px 0;
    cursor: pointer;
}

.nav-links {
    display: flex;
    gap: 25px;
    align-items: center;
    flex-shrink: 0;
}

.nav-links a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 500;
    transition: color 0.3s;
    white-space: nowrap;
}

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

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

main {
    flex-grow: 1;
    margin: 20px 0;
    width: 100%;
}

footer {
    background-color: var(--dark-color);
    color: var(--white);
    padding: 40px 20px 20px;
    margin-top: 40px;
}

.footer-content {
    max-width: var(--container-width);
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.footer-section h4 {
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section a {
    color: #bbb;
    text-decoration: none;
}

.footer-section a:hover {
    color: var(--white);
}

.bottom-footer {
    text-align: center;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 1px solid #444;
    font-size: 0.9rem;
    color: #888;
}

/* Utility Classes */
.btn { padding: 10px 20px; border-radius: 4px; text-decoration: none; display: inline-block; cursor: pointer; border: none; font-weight: 600; transition: background-color 0.2s, opacity 0.2s; text-align: center; }
.btn:hover { opacity: 0.9; }
.btn-primary { background-color: var(--primary-color); color: white; }
.btn-secondary { background-color: var(--dark-color); color: white; }
.btn-outline { border: 1px solid var(--primary-color); color: var(--primary-color); background: transparent; }
.btn-outline:hover { background: var(--primary-color); color: white; }

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

.product-card {
    background: white;
    border-radius: 8px;
    box-shadow: var(--shadow);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: transform 0.2s;
}

.product-card:hover {
    transform: translateY(-5px);
}

/* Responsive Layouts */
.listing-layout {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 40px;
}

.detail-layout {
    display: flex;
    gap: 50px;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    background: white;
    padding: 40px;
    border-radius: 8px;
    box-shadow: var(--shadow);
}

/* Media Queries */
@media (max-width: 1200px) {
    .listing-layout {
        gap: 20px;
        grid-template-columns: 240px 1fr;
    }
}

@media (max-width: 992px) {
    .main-nav {
        flex-wrap: wrap;
        gap: 15px;
    }
    
    .listing-layout {
        grid-template-columns: 1fr;
    }
    
    .detail-layout {
        flex-direction: column;
        padding: 30px;
    }
    
    .contact-layout {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .main-nav {
        justify-content: center;
    }
    
    .search-container {
        order: 3;
        width: 100%;
        max-width: none;
    }
    
    .top-bar {
        justify-content: center;
        text-align: center;
    }
}
/* Product Image Carousel */
.image-carousel {
    position: relative;
    width: 100%;
    height: 100%;
}

.carousel-container {
    display: flex;
    transition: transform 0.3s ease-in-out;
    height: 100%;
}

.carousel-image {
    min-width: 100%;
    height: 100%;
    object-fit: cover;
}

.carousel-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.7);
    border: none;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: background 0.2s;
}

.carousel-btn:hover {
    background: rgba(255, 255, 255, 0.9);
}

.carousel-prev {
    left: 5px;
}

.carousel-next {
    right: 5px;
}

@media (max-width: 480px) {
    .nav-links {
...
        gap: 10px;
        font-size: 0.85rem;
    }
    
    .product-grid {
        grid-template-columns: 1fr;
    }
    
    .detail-layout {
        padding: 20px;
    }
}
