/* Global Styles */
body {
    font-family: 'Arial', sans-serif;
    margin: 0;
    padding: 0;
    background-color: #FEFFF2;
    color: #333;
}

header {
    background-color: #333;
    color: white;
    text-align: center;
    position: center;
    height: 100%

    border-bottom: 3px solid #333;
    max-width: auto;
}

h1 {
    margin: 0;
    font-size: 55px;
}

.cart-icon {
    position: absolute;
    top: 5px;
    right: 5px;
    font-size: 2em;
    cursor: pointer;
}

.cart-badge {
    position: absolute;
    top: 40px;
    right: 12px;
    background-color: #FFD60B;
    color: black;
    border-radius: 30%;
    padding: 3px;
    font-size: 1em;
}

/* Frame Layout */
.frame-container {
    height:50%;
    width:100%;
    display: flex;
    margin-color: black;
    background-color:#333;
}

.left-frame {
    background-color: #333;
    color: white;
    width: 20%;
    height: 100%;
    min-width: 20%;
    padding: 20px;
    display: flex;
    flex-direction: column;          %
    flex: 0 0 20%; /* Ensures the left pane takes up 20% */
    transition: padding 0.3s ease, flex-direction 0.3s ease;
}

.right-frame {
    flex-wrap: wrap;
    display: flex !important;
    height: 100%;
    flex: 1; /* Ensures the right pane takes up the remaining space */
    width: 80%;
    background-color: #FEFFF2;
/*    align-items: center;
    max-width: max-content;
    min-height: 100vh;      */
    justify-content: space-evenly;
    margin-bottom: 5%;
    padding: 0.2%;
    margin: 1% 0.5%;
    transition: padding 0.3s ease, flex-direction 0.3s ease;
}

.product-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    flex-direction:row;
    width: 100%;
    height: 100%;
}

.product-button-container {
    width:100%;
}

.product-item-category{
    display: flow;
    min-width:100%;
    min-height: 50px;
    max-height: 50px;
    flex-direction: row; /* Change to row to align image and content side by side */
    margin: 2%;
    font-size: Auto;
    align-items: flex-start; /* Align items to the top */
    background-color: #E4C590;
    border-radius: 12px;
    padding: 5px;
    box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-align: center; /* Align text to the left */
    overflow: visible;
    height: auto; /* Allow the height to adjust based on content */
}


  .product-item-category:hover {
    background-color: #FEFFF2;
    position: right;
    transform: scale(1.05);

}


.product-item {
        display: flex;
        flex-direction: column; /* Change to row to align image and content side by side */
        margin: 1% 0.5%;
        min-height: 300px;
        max-width:180px;
        max-height:180px;
        min-width:190px;
        font-size: 1em;
        align-items: center; /* Align items to the top */
        background-color: #E4C590;
        border-radius: 10px;
        padding: 15px;
        box-shadow: 0 8px 15px rgba(0, 0, 0, 0.1);
        transition: transform 0.3s ease, box-shadow 0.3s ease;
        text-align: left; /* Align text to the left */
        overflow: hidden;
    }

.product-item img {
    width: 140px; /* Adjust width of image */
    height: 140px; /* Adjust height of image */
    object-fit: cover; /* Ensure the image covers the area properly */
    border-radius: 2px;
    transition: transform 0.3s ease;
}

.product-item img:hover {
    transform: scale(1.4);
}

.product-item .details {
    display: flex;
    flex-direction: column;
    justify-content: space-between; /* Space out the content */
    width: 100%; /* Allow content to take up the remaining space */
}

.product-item h4 {
    font-size: 1em;
    margin: 10px 0;
    align-text:
    color: black;
}

.product-item p {
    font-size: 1em;
    color: black;
    margin: 5px 0;
}

.product-item button {
    padding: 12px 25px;
    margin-top: 15px;
    width: 100%; /* Make the button take up full width of container */
    text-align: center;
    background-color: #333;
    color: #FCDD61;
    font-size: 1.1em;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.product-item button:hover {
    background-color: #333;
    color: 'CORNSILK';
    font-size: 1.2em;
    transform: scale(1.15);
}





/* Media Queries for Responsive Layout */
@media (max-width: 1200px) {
    .product-list {
        grid-template-columns: repeat(4, 1fr); /* 4 items per row */
        bottom:5%;
    }
}

@media (max-width: 1024px) {
    .product-list {
        grid-template-columns: repeat(3, 1fr); /* 3 items per row */
                bottom:5%;

    }
}

@media (max-width: 768px) {
    .product-list {
        grid-template-columns: repeat(2, 1fr); /* 2 items per row */
                bottom:5%;

    }
}

@media (max-width: 480px) {
    .product-list {
        grid-template-columns: 1fr; /* 1 item per row */
                bottom:5%;

    }

    .product-item img {
        width: 80px;
        height: 80px;

    }

    .product-item button {
        width: auto;
    }
}

/* Footer Section */
footer {
    height: 10%;
    background-color: #E4C590;
    padding: 2px ;
    width: 100%;
    display: flex;
    justify-content: center; /* Enable flexbox */
}



footer button {
    padding: 12px;
    margin: 5px;
    min-width: max-content;
    max-width: max-content;
    width: 15%; /* Make the button take up full width of container */
    text-align: center;
    background-color: #333;
    color: white;
    font-size: 0.9em;
    border-color:#white;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

footer button:hover {
    background-color: #FEFFF2;
    position: center;
}




/* Cart Styles */
/* Cart Styles */
.cart-container {
    position: fixed;
    top: 0;
    right: 0;
    width: 90%;
    max-width:350px;
    height: 95%;
    background-color: #E4C590;
    overflow-y: auto;  /* Enable vertical scrolling */

    padding: 3%;
    box-shadow: -2px 0px 10px rgba(0, 0, 0, 0.1);
    transform: translateX(100%); /* Starts offscreen */
    transition: transform 0.3s ease; /* Smooth slide-in */
}

.cart-container.show {
    transform: translateX(0);
}

.cart-header {
    font-size: 1.8em;
    font-weight: bold;
    margin-bottom: 20px;
    color: #333;
}

.cart-item {
    display: flex;
    align-items: anchor-center;
    justify-content: stretch    ;
    padding: 2px;
    border-bottom: 1px solid #333;
}

.cart-item img {
    width: 70px;
    height: 70px;
    object-fit: cover;
    margin: 5px;
}

.cart-item-info {
    display: list-item inline;
    flex-direction: column;
    align-items: flex-end;
    font-size: 1.2em;
}

.cart-item-info h5 {
    font-weight: bold;
    margin: 5px 0;
}

.cart-item-info p {
    margin: 5px 0;
    font-size: 0.9em;
    color: #555;
}

.cart-summary {
    margin-top: 20px;
    padding: 20px;
    background-color: cornsilk;
    border-radius: 5px;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
}

.cart-summary h3 {
    font-size: auto;
    text-align=center;
    color: #333;
}

.cart-summary p {
    font-size: 1.2em;
    color: #333;
}

.cart-summary .total-price {
    font-size: 1.4em;
    font-weight: bold;
    color: #d9534f;
    margin: 10px 0;
}

/* Customer Info Section */
.cart-summary input {
    width: 95%;
    padding: 10px;
    font-size: 1em;
    margin-bottom: 15px;
    border: 1px solid #FEFFF2;
    border-radius: 5px;
    color: #333;
}

.cart-summary button {
    padding: 10px 20px;
    background-color: #2c2c2c;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 100%;
}

.cart-summary button:hover {
    background-color: #c9302c;
    transform: scale(1.2);

}

/* Cart Close Button */
#closeCartButton {
    padding: 10px 20px;
    background-color: #2c2c2c;
    color: #fff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
    transition: background-color 0.3s ease;
    margin-top: 10px;
}

#closeCartButton:hover {
    background-color: #c9302c;
    transform: scale(1.2);

}

/* Mobile View Adjustments */
@media (max-width: 768px) {
    .left-frame {
        width: 20%;  /* Left pane remains at 20% width on medium screens */
        height:auto;
    }

    .right-frame {
        padding: 5%;
    }

    .product-item img {
        width: 90px;
        height: 90px;
    }
}

@media (max-width: 480px) {
        .left-frame {
                width: 20%;  /* Left frame stays at 20% width on smaller screens */
                                height:auto;

        }

        .order-status-form {
        display: flex;
        flex-direction: auto;
        gap: 5%; /* Adds space between each field */
        width: 100%;
        max-width: 400px; /* Limits the form width */
        margin: 0 auto; /* Centers the form */
        padding: 20px;
        background-color: #fff;
        border-radius: 8px;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Styling for each form group */
.form-group {
        display: flex;
        flex-direction: column;
        gap: 10px; /* Adds space between label and input */
}


    .add-to-cart-message {
        position: fixed;  /* Position it relative to the viewport */
        top: 50%;  /* Center it vertically */
        left: 50%;  /* Center it horizontally */
        transform: translate(-50%, -50%);  /* Adjust positioning by half of the element's width and height */
        background-color: rgba(0, 128, 0, 0.8);
        color: white;
        padding: 15px 30px;
        border-radius: 5px;
        font-size: 18px;
        z-index: 9999;
        display: none;  /* Initially hide the message */
}

