/* Make the body take full height and use flexbox */
body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Full viewport height */
    overflow: auto;  /* No scroll at all */
    margin: 0;
}

.flex-grow-1 {
    overflow: hidden;
}

.card-img-top {
    height: 150px;
    object-fit: cover;
}

.carousel {
    overflow: visible; /* So controls can sit outside */
}

.custom-prev,
.custom-next {
    width: 50px;
    height: 50px;
    background-color: black;
    border-radius: 50%;
    top: 50%;
    transform: translateY(-50%);
    opacity: 1;
}

.custom-prev {
    left: -60px; /* sit outside left */
}

.custom-next {
    right: -60px; /* sit outside right */
}

.custom-prev .carousel-control-prev-icon,
.custom-next .carousel-control-next-icon {
    filter: invert(1); /* make icon white over black background */
}

.carousel-inner {
    /* disable auto slide if needed */
}

#productCarousel + .d-flex button {
    width: 100px;
    height: 40px;
    font-weight: bold;
    font-size: 1rem;
}

/* Main content grows to fill available space */
main, .container.flex-grow-1 {
    flex: 1 0 auto;
}

/* Footer styling */
footer {
    flex-shrink: 0;            /* Prevent shrinking */
    background-color: black;    /* Footer background */
    color: #ffffff !important;  /* Footer text color */
    padding: 20px 0;           /* Optional spacing */
}

/* Footer links */
footer a {
    color: #ffffff !important;
    text-decoration: underline;
}

footer a:hover {
    color: #cce5ff !important; /* lighter blue on hover */
    text-decoration: none;
}

/* Navbar */
.mm-navbar {
    background-color: black;
}

.mm-navbar .nav-link {
    color: #ffffff !important;
    font-weight: 500;
    transition: color 0.2s;
}

.mm-navbar .nav-link:hover,
.mm-navbar .nav-link:focus {
    color: #ffc107 !important; /* Hover color */
}

.mm-navbar .dropdown-menu {
    background-color: #0d6efd; /* Same as navbar */
}

.mm-navbar .dropdown-item {
    color: #ffffff !important;
}

.mm-navbar .dropdown-item:hover,
.mm-navbar .dropdown-item:focus {
    background-color: #0056b3; /* Darker blue hover */
    color: #ffc107 !important;
}

/* Brand styling */
.mm-brand {
    color: #ffffff !important;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.5px;
}

/* Toggler icon color for dark navbar */
.navbar-toggler-icon {
    filter: invert(1); /* Makes it visible on dark background */
}

/* Shop page background */
.shop-background {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    width: 100%;
    min-height: 100vh; /* full viewport height */
    padding-top: 80px; /* optional, to avoid navbar overlap */
}

.shop-content {
    background-color: rgba(255, 255, 255, 0.9); /* white overlay */
    padding: 20px;
    border-radius: 10px;
}

/* Product image wrapper */
.product-img-wrapper {
    width: 100%;
    max-width: 300px;   /* Prevents oversized images */
    margin: 0 auto;     /* Center on narrow cards */
    overflow: hidden;
    background: #f8f8f8;
    display: flex;
    align-items: center;
    justify-content: center;
}

.product-img-wrapper img.product-img {
    width: 100%;
    height: auto;       /* Maintain natural aspect ratio */
    object-fit: cover;  /* Prevent distortion */
    display: block;
}

.card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Ensure the entire card body uses flexbox */
.card-body {
    display: flex;
    flex-direction: column;
    height: 100%; /* Take full height */
}

/* Scrollable content area (cart items and totals) */
.scrollable-content {
    flex-grow: 1; /* Take available space */
    overflow-y: auto; /* Vertical scroll */
    max-height: 300px; /* Adjust the height before scroll starts */
}

/* Optional: Style for the scrollbar */
#sidebarItems::-webkit-scrollbar {
    width: 8px; /* Width of the scrollbar */
}

#sidebarItems::-webkit-scrollbar-thumb {
    background-color: rgba(0, 0, 0, 0.5);
    border-radius: 10px;
}

#sidebarItems::-webkit-scrollbar-track {
    background-color: #f1f1f1;
}

/* Make sure the button stays at the bottom of the card body */
.card-body button {
    margin-top: auto; /* Pushes the button to the bottom */
}

/* Other general styling */
.card-img-top {
    height: 150px;
    object-fit: cover;
}

.card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

/* Scrollable area for cart items */
#sidebarItems {
    overflow-y: auto;
    max-height: 200px; /* Adjust the height as needed */
}

#sidebarItems li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px; /* Space between items */
}

/* Style the quantity input to make it more compact */
.sidebar-qty {
    width: 60px; /* Limit width for better alignment */
    margin-right: 10px;
}
.item-total {
    margin-right: 10px;
}

/* Styling for the remove button */
.sidebar-remove {
    margin-left: 10px;
}

/* Center the modal text */
.modal-dialog-centered {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Fade-in effect */
.fade-in-text {
    opacity: 0;
    animation: fadeIn 2s forwards;
}

@keyframes fadeIn {
    0% {
        opacity: 0;
    }
    100% {
        opacity: 1;
    }
}

/* Increase the font size of the modal content */
.modal-body, .modal-footer {
    font-size: 1.1em; /* Increase font size by 1.1em */
}

.modal-body ul {
    padding-left: 20px;
}

.modal-footer .btn-danger {
    background-color: red;
    border: none;
}

.modal-footer .btn-success {
    background-color: green;
    border: none;
}

.meat-intro {
    font-family: Arial, sans-serif;
    color: #333;
    line-height: 1.6;
    max-width: 700px;
    margin: 0 auto;
    padding: 1rem;
    height: 600px; /* You can adjust this value as needed */
    overflow-y: auto; /* Adds a scrollbar if content exceeds height */
}
