/* Reset and Global Styles */
body, html {
    margin: 0;
    padding: 0;
    font-family: Arial, sans-serif;
    overflow-x: hidden;
    background-color: #1c1c1c;
    color: #fff;
    min-height: 100vh;

    /* Added: Flexbox for sticky footer */
    display: flex;
    flex-direction: column;
}

main {
    flex-grow: 1; /* Pushes footer down when content is short */
    min-height: 100px;
}

* {
    box-sizing: border-box;
}

img {
    max-width: 100%;
}


/* Products and Brands Styles */
#products-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    margin: 0 auto;
    padding: 20px;
    width: 100%;
}

#products-container h2,
#products-container h3 {
    margin: 0;
    line-height: 1.1;
}

#products-container h3 {
    font-size: 1rem; /* or smaller */
    color: #ccc;     /* optional: visually differentiate */
}

.product_image_wrapper {
    width: 100%;
    height: 180px; /* Desktop height */
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    background-color: #222; /* Optional background */
    margin-bottom: 10px;
    border-radius: 6px; /* Optional: for visual consistency */
}

.productimage {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.variant-options {
    list-style: none;
    padding: 0;
    margin-top: 8px;
    font-size: 0.9rem;
    color: #ccc;
    display: none; /* hidden until shown */
}

.variant-options li {
    display: flex;
    flex-direction: row;       /* 🧠 Ensure side-by-side layout */
    justify-content: space-between;
    align-items: center;
    padding: 6px 8px;
    border-bottom: 1px dashed #555;
    gap: 10px;
    width: 100%;               /* Prevent wrapping due to container limits */
    box-sizing: border-box;    /* Prevent overflow */
}

.variant-thumb {
    width: 40px;
    height: 40px;
    object-fit: contain;
    background-color: #222;
    border-radius: 4px;
    flex-shrink: 0;
}

/* Optional: tighten on large screens */
@media screen and (min-width: 1100px) {
    .product_image_wrapper {
        height: 200px;
    }
}


.brandslist {
    list-style: none;
    padding: 10px 0 0 0;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;       /* ✅ ALLOWS wrapping */
    gap: 10px;             /* ✅ Optional: adds space between logos */
    margin: 0 auto;        /* ✅ Keeps it centered */
    max-width: 100%;       /* ✅ Prevents overflow */
}

.brandslist li {
    width: 83px;
    height: 83px; /* 👈 makes it square */
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: white;
    padding: 5px;
    box-sizing: border-box;
    margin: 5px 5px;
}

.brandslist li img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

ul.productList {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
}

ul.productList {
    display: grid;
    grid-template-columns: 1fr;
    gap: 16px;
    padding: 0;
    margin: auto;
    list-style: none;
    width: 100%;
    max-width: 1200px;
}

ul.productList li {
    background-color: #444;
    padding: 10px;
    border-radius: 6px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

/* Tablet: 3 columns */
@media screen and (min-width: 768px) {
    ul.productList {
        grid-template-columns: repeat(3, 1fr);
    }
}

/* Large screen: 4 columns */
@media screen and (min-width: 1100px) {
    ul.productList {
        grid-template-columns: repeat(4, 1fr);
    }
}

/* Category Styles */
.category-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.category-box {
    flex-grow: 1;
    margin: 10px;
    padding: 20px;
    background-color: #f0f0f0;
    border: 1px solid #ccc;
    color: black;
}

.category-box h2 {
    margin-top: 0;
}

.category-box hr {
    margin: 10px 0;
}

.category-box ul {
    list-style-type: none;
    padding: 0;
}

.category-box ul li {
    margin-bottom: 5px;
}

.category-box a {
    text-decoration: none;
    color: inherit;
    cursor: pointer;
}

.show-description .variant-options {
    display: block;
}

/* Media Query for Wide Screens */
@media screen and (min-width: 768px) {

    .main-list {
        display: flex;
        justify-content: space-around;
        flex-wrap: wrap;
    }

    .category-container {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
    }

    .category-box {
        flex-grow: 1;
        padding: 20px;
        background-color: #f0f0f0;
        border: 1px solid #ccc;
        color: black;
    }


}

/* Inside each product li — mobile-only tweaks */
@media screen and (max-width: 600px) {
    .product_info {
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 10px;
        justify-content: space-between;
        width: 100%;
        text-align: left;
        cursor: pointer; /* Add for tap feedback */
        flex-wrap: wrap; /* ✅ Allow new lines */
    }

    .product_info img {
        width: 50px;
        height: auto;
        flex-shrink: 0;
    }

    .product_info strong {
        font-size: 1rem;
        display: block;
    }

    .product_info .variant-count,
    .product_info .product_description {
        display: none;
    }

    .product_info.show-description .product_description {
        display: block;
        width: 100%; /* ✅ Take full row */
        padding-top: 5px;
        font-size: 0.85rem;
    }

        .product_info.show-description img.product-thumb {
        width: 85%;
        height: auto;
        max-width: 85%;
        margin: 0 auto;
        display: block;
    }

}

.product.fake-product .product_info {
    background-color: #2a2a2a;
    border: 1px dashed #666;
    color: #ccc;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    min-height: 160px;
    width: 100%;
    box-sizing: border-box;
    transition: background-color 0.3s;
}

.product.fake-product .product_info:hover {
    background-color: #333;
}

.coming-soon-content {
    margin: 0 auto;
    max-width: 90%;
}

.product.fake-product .product_title {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 6px;
    color: #fff;
}

.product.fake-product .product_description {
    font-size: 0.88rem;
    color: #aaa;
    line-height: 1.4;
}
