/* A Modern CSS Reset */
*, *::before, *::after {
    box-sizing: border-box; /* Ensures padding and borders are included in the element's total width/height */
    margin: 0;            /* Removes default outer spacing (margins) */
    padding: 0;           /* Removes default inner spacing (padding) */
}



body {
    font-family: sans-serif;
    /*margin: 10px;*/
    height: 100%;
    
  
}



h2{
    margin: 0;
    padding: 0;
    align-items: center;
    position: relative;
}
.product-grid {
    display: flex;
    gap: 10px;
    position: relative;
    align-items: center;
    place-items: center;
    justify-content: center;

}

.product-card img {
    /* Set a fixed size for all product images */
    width: 150px; 
    height: 150px; 
    /* Ensures the image covers the entire box without stretching */
    object-fit: cover; 
    /* Optional: Add some space below the image */
    margin-bottom: 1px; 
    /* Optional: Make images slightly rounded */
    border-radius: 5px; 
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
 
}

    /* Pop-up effect on hover */
    .product-card img:hover {
        /* Make the image big (e.g., 3x its size) */
        transform: scale(3.0);
        /* Bring the image above other elements on the page */
        z-index: 10;
        /* Position it absolutely within its cell to break free from the cell's overflow rules */
        position: absolute;
        /* Center it over its original cell location */
        top: auto;
        left: auto;
        /* Add a subtle shadow for the "pop out" effect */
        box-shadow: 0px 10px 30px rgba(0,0,0,0.5);
        /* Ensure the transformation origin is centered */
        transform-origin: center center;
    }
.product-card {
    border: 1px solid #ccc;
    padding: 10px;
    text-align: center;
    width: 180px;
    margin: 0;
    place-items: center;
}

.add-to-cart {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
}

table {
    width: 50%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

th, td {
    border: 1px solid #ccc;
    padding: 10px;
    text-align: left;
}

.cart-total {
    text-align: bottom;
    font-size: 1.2em;
}

.remove-item {
    color: red;
    cursor: pointer;
}

/*--------collextio new--------*/
/* Container spacing */
.product-grid-containery {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

/* THE MAGIC GRID: 1 column on iPhone, 2 on Tablets, 3 on Desktop */
.product-layout-gridy {
    display: grid;
    grid-template-columns: repeat(1, 1fr); /* 1 column for iPhone */
    gap: 20px;
    margin-top: 20px;
}

/* Responsive adjustment for larger screens */
@media (min-width: 600px) {
    .product-layout-gridy { grid-template-columns: repeat(2, 1fr); } /* 2 columns */
}

@media (min-width: 1024px) {
    .product-layout-gridy { grid-template-columns: repeat(3, 1fr); } /* 3 columns */
}
@media (max-width: 480px) {
    .product-layout-gridy {
        display: grid;
        grid-template-columns: repeat(2, 1fr); /* Two items per row on iPhone */
        gap: 10px;
    }
  .product-cardy img {
        width: 120px; /* Slightly smaller for 2-column mobile layout */
        height: 120px;
    }
}
/* Product Card Styling */
.product-cardy {
    min-width: 160px;       /* Ensures the card is slightly wider than the image */
    padding: 15px;
    text-align: center;
}

.product-cardy:hover {
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.product-cardy img {
    width: 150px;           /* Fixed width */
    height: 150px;          /* Fixed height to keep it square */
    object-fit: cover;      /* This prevents the image from looking "stretched" */
    border-radius: 10px;    /* Optional: adds nice rounded corners */
    display: block;         /* Centers the image */
    margin: 0 auto 10px;    /* Centers image and adds space below */
}

/* Modern Button */
.add-to-carty {
    background-color: #333;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
    font-weight: bold;
}

.add-to-carty:hover {
    background-color: #555;
}

/* Table Title Formatting */
.tabletitley {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 2px solid #eee;
    padding-bottom: 10px;
}


