body {
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: #ff0000;
    /* Red */
    color: #fff;
    position: sticky;
    top: 0;
    z-index: 1000;
    border-radius: 30px;
}

.logo img {
    height: 40px;
    width: auto;
}

.nav-items {
    display: flex;
    gap: 10px;
    margin-left: 20px;
    /* Adjusted for left alignment */
}

.nav-items button {
    background-color: #ffeb3b;
    /* Yellow */
    border: 2px solid #ffeb3b;
    /* Yellow border */
    color: #ff0000;
    /* Red */
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    padding: 10px 20px;
    border-radius: 20px;
    transition: background-color 0.3s, color 0.3s;
}

.nav-items button:hover {
    background-color: #ff0000;
    /* Red */
    color: #ffeb3b;
    /* Yellow */
}

.nav-items button.active {
    background-color: #ff0000;
    /* Red */
    color: #ffeb3b;
    /* Yellow */
}

.search-container {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-left: auto;
    /* Push search container to the right */
}

.search-bar {
    flex-grow: 1;
    padding: 10px 20px;
    border: 2px solid #ffeb3b;
    border-radius: 20px;
    width: 200px;
    font-size: 16px;
}

.search-button {
    background-color: #ffeb3b;
    border: 2px solid #ffeb3b;
    color: #ff0000;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    padding: 10px 20px;
    border-radius: 20px;
    transition: background-color 0.3s, color 0.3s;
}

.search-button:hover {
    background-color: #ff0000;
    color: #ffeb3b;
}

.search-button img {
    width: 20px;
    height: 20px;
}

.carousel {
    overflow: hidden;
    position: relative;
    width: calc(100% - 40px);
    /* Adjust for padding or margin */
    height: 400px;
    border-radius: 30px;
    /* Increased border-radius */
    margin: 20px auto;
    /* Center align */
}

.carousel img {
    width: 100%;
    height: 100%;
    display: none;
    border-radius: 30px;
}

.carousel img.active {
    display: block;
}

.content {
    display: flex;
    flex: 1;
    margin: 20px;
    gap: 30px;
    /* Increased gap */
}

.menu {
    flex: 2;
    padding: 20px;
    background-color: #fff;
    border-radius: 30px;
}

.menu-title {
    font-size: 24px;
    margin-bottom: 20px;
}

.product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
}

.product-item {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    background-color: #fff;
    border-radius: 30px;
    /* Increased border-radius */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    padding: 10px;
    text-align: center;
}

.product-image {
    width: 100%;
    height: auto;
    max-height: 150px;
    /* Ensure the image doesn't cover the entire container */
    object-fit: cover;
}

.product-info {
    padding: 10px;
    width: 100%;
}

.product-title {
    font-size: 18px;
    margin: 10px 0;
}

.product-price {
    font-size: 20px;
    color: #a30101;
    margin: 10px 0;
}

.add-button {
    background-color: #ff0000;
    /* Red */
    color: #fff;
    border: none;
    padding: 10px;
    border-radius: 30px;
    /* Increased border-radius */
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
}

.add-button:hover {
    background-color: #cc0000;
}

.shopping-cart {
    flex: 1;
    padding: 20px;
    background-color: #fff;
    border-radius: 30px;
    /* Increased border-radius */
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 100px;
    overflow-y: auto;
    max-height: calc(100vh - 250px);
}


.cart-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.cart-header h2 {
    font-size: 24px;
    margin: 0;
}

.cart-header .cart-count {
    font-size: 16px;
    color: #888;
}

.cart-items {
    margin-bottom: 20px;
}

.cart-item {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.cart-item img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 10px;
    margin-right: 20px;
}

.cart-item-info {
    display: flex;
    flex: 1;
    justify-content: space-between;
    align-items: center;
}

.cart-item-title {
    font-size: 18px;
    margin: 0 0 10px 0;
}

.cart-item-quantity {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

.quantity-increase {
    background-color: #ff0000;
    color: #fff;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 5px;
    cursor: pointer;
    margin-left: 10px;
    /* Add gap between quantity and increase button */
}

.quantity-decrease {
    background-color: #ff0000;
    color: #fff;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 5px;
    cursor: pointer;
}

.cart-item-quantity .quantity {
    margin: 0 10px;
}

.cart-item-price {
    font-size: 20px;
    /* Increased font-size */
    font-weight: bold;
    /* Made the font bold */
    color: #5b1d1d;
    /* Red color to make it stand out */
    margin-right: 20px;
    /* Align to the right */
    padding: 5px 10px;
    /* Padding for better spacing */
    border-radius: 5px;
    /* Rounded corners for a smooth look */
}

.cart-item-remove {
    background-color: #333;
    /* Deep gray color */
    color: #fff;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 5px;
    /* Similar to add button */
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    margin-left: 10px;
    /* Add gap between increase and remove button */
}

.cart-item-remove:hover {
    background-color: #555;
    /* Slightly lighter gray on hover */
}

.cart-item-remove img {
    width: 16px;
    height: 16px;
}

.cart-summary {
    border-top: 1px solid #ccc;
    padding-top: 20px;
}

.cart-summary .subtotal,
.cart-summary .tax,
.cart-summary .total {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.cart-summary .total {
    font-size: 18px;
    font-weight: bold;
}

.checkout {
    margin-top: 20px;
    padding: 15px;
    background-color: #ff0000;
    color: #fff;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    width: 100%;
    font-size: 16px;
}

.footer {
    background-color: #ff0000;
    /* Red */
    color: #fff;
    text-align: center;
    padding: 10px 0;
    position: relative;
    bottom: 0;
    width: 100%;
}

/* 弹窗的整体样式 */
/* 弹窗的整体样式 */
.modal {
    display: none;
    /* 默认隐藏 */
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
    justify-content: center;
    align-items: center;
}

/* 弹窗的整体样式 */
.modal {
    display: none;
    /* 默认隐藏 */
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.4);
    justify-content: center;
    align-items: center;
}

/* 弹窗内容的样式 */
.modal-content {
    background-color: red;
    color: yellow;
    border: 5px solid yellow;
    margin: 15% auto;
    padding: 20px;
    width: 80%;
    max-width: 400px;
    text-align: center;
    box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
    border-radius: 10px;
    font-size: 1.5em;
    font-weight: bold;
}

/* 关闭按钮的样式 */
.close-button {
    color: yellow;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.close-button:hover,
.close-button:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}


/* Dark mode styles */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

body.dark-mode .navbar {
    background-color: #333;
}

body.dark-mode .footer {
    background-color: #333;
}

.language-switch,
.dark-mode-switch {
    background-color: #ffeb3b;
    /* Yellow */
    border: 2px solid #ffeb3b;
    /* Yellow border */
    color: #ff0000;
    /* Red */
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    padding: 10px 20px;
    border-radius: 20px;
    transition: background-color 0.3s, color 0.3s;
    margin-left: 10px;
    /* Ensure some space between buttons */
}

.language-switch:hover,
.dark-mode-switch:hover {
    background-color: #ff0000;
    /* Red */
    color: #ffeb3b;
    /* Yellow */
}

.language-switch.active,
.dark-mode-switch.active {
    background-color: #ff0000;
    /* Red */
    color: #ffeb3b;
    /* Yellow */
}

.language-switch-container {
    position: relative;
    display: inline-block;
}

.language-dropdown {
    display: none;
    position: absolute;
    background-color: #fff;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    z-index: 1;
    border-radius: 10px;
    border: 2px solid #ffeb3b;
    /* Yellow border */
    top: 100%;
    left: 0;
}

.language-dropdown a {
    color: black;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    transition: background-color 0.3s, color 0.3s;
}

.language-dropdown a:hover {
    background-color: #ffeb3b;
    /* Yellow background on hover */
    color: #ff0000;
    /* Red text on hover */
}

.language-switch-container:hover .language-dropdown {
    display: block;
}

.language-switch {
    background-color: #ffeb3b;
    /* Yellow */
    border: 2px solid #ffeb3b;
    /* Yellow border */
    color: #ff0000;
    /* Red */
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    padding: 10px 20px;
    border-radius: 20px;
    transition: background-color 0.3s, color 0.3s;
}

/* General Title Styles */
h2,


h2::after,


.menu-title,
.cart-header h2 {
    font-size: 24px;
    font-weight: bolder;
    border: #cc0000;
    font-style: italic;
    text-shadow: #121212 ;
    text-wrap: wrap;
    margin-bottom: 20px;
    color: #ecec00;
    /* Red color */
    text-transform: uppercase;
    /* Uppercase for emphasis */
}

.menu-title::after,
.cart-header h2::after {
    content: '';
    display: block;
    width: 50px;
    height: 4px;
    background-color: #ffeb3b;
    /* Yellow underline */
    margin-top: 5px;
}

.product-title {
    font-size: 18px;
    margin: 10px 0;
    color: #302222;
    /* Red color for product titles */
    font-weight: bold;
}

.carousel {
    overflow: hidden;
    position: relative;
    width: calc(100% - 40px);
    height: 400px;
    border-radius: 30px;
    margin: 20px auto;
}

.carousel img {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 100%;
    transition: transform 1s ease-in-out, left 1s ease-in-out;
    border-radius: 30px;
}

.carousel img.active {
    left: 0;
    transform: translateX(0);
}

.carousel img.previous {
    left: -100%;
    transform: translateX(-100%);
}

.carousel-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.indicator {
    width: 10px;
    height: 10px;
    background-color: #ffeb3b;
    /* Yellow */
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.3s;
}

.indicator.active {
    background-color: #ff0000;
    /* Red */
}


/* General styles */
body {
    transition: background-color 0.3s, color 0.3s;
}

.navbar,
.footer {
    transition: background-color 0.3s, color 0.3s;
}

.modal-content {
    transition: background-color 0.3s, color 0.3s;
}

/* Dark Mode styles */
/* General styles */
body {
    transition: background-color 0.3s, color 0.3s;
}

/* Navbar and Footer */
.navbar,
.footer {
    transition: background-color 0.3s, color 0.3s;
}

/* Modal content */
.modal-content {
    transition: background-color 0.3s, color 0.3s;
}

/* Dark Mode styles */
body.dark-mode {
    background-color: #121212;
    color: #ffffff;
}

.navbar.dark-mode,
.footer.dark-mode,
.menu.dark-mode,
.shopping-cart.dark-mode {
    background-color: #1e1e1e;
    color: #ffffff;
}

.search-container input.dark-mode {
    background-color: #333333;
    color: #ffffff;
    border: 1px solid #555555;
}

.language-switch-container.dark-mode {
    background-color: #1e1e1e;
    color: #ffffff;
}

.language-dropdown.dark-mode a {
    color: #ffffff;
    background-color: #1e1e1e;
}

.language-dropdown.dark-mode a:hover {
    background-color: #333333;
}

.dark-mode .modal-content {
    background-color: #1e1e1e;
    color: #ffffff;
}

.dark-mode .cart-item {
    background-color: #1e1e1e;
    border: 1px solid #333333;
}

.dark-mode .cart-item img {
    border: 1px solid #333333;
}

.dark-mode .cart-item-info h3,
.dark-mode .cart-item-info .cart-item-price,
.dark-mode .cart-item-info .cart-item-quantity button,
.dark-mode .subtotal span,
.dark-mode .tax span,
.dark-mode .total span {
    color: #ffffff;
}

.dark-mode .quantity-decrease,
.dark-mode .quantity-increase,
.dark-mode .cart-item-remove {
    background-color: #333333;
    color: #ffffff;
    border: 1px solid #555555;
}

.dark-mode .quantity-decrease:hover,
.dark-mode .quantity-increase:hover,
.dark-mode .cart-item-remove:hover {
    background-color: #555555;
}

.dark-mode .checkout {
    background-color: #5d2525;
    color: #ffffff;
    border: 1px solid #555555;
}

.dark-mode .checkout:hover {
    background-color: #555555;
}

/* Specific elements in main content */
.dark-mode .menu-title,
.dark-mode .product-title,
.dark-mode .product-price,
.dark-mode .add-button {
    color: #ffffff;
}

.dark-mode .product-item {
    background-color: #1e1e1e;
    border: 1px solid #333333;
}

.dark-mode .add-button {
    background-color: #5d2525;
    color: #ffffff;
    border: 1px solid #555555;
}

.dark-mode .add-button:hover {
    background-color: #555555;
}