/* ======= 全局样式 ======= */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}
body {
  font-family: Arial, sans-serif;
  background-color: #f5f5f5;
}
a {
  text-decoration: none;
  color: inherit;
}

/* ======= 顶部搜索栏 ======= */
.header {
  width: 100%;
  background-color: #fff;
  padding: 10px;
  box-shadow: 0 1px 5px rgba(0,0,0,0.1);
  display: flex;
  justify-content: center;
}
.search-bar {
  width: 80%;
  max-width: 500px;
  padding: 6px 12px;
  border: 1px solid #ccc;
  border-radius: 4px;
}

.icp-footer {
  text-align: center;
  padding: 10px 0;
  font-size: 14px;
  color: #666;
  margin-top: 20px;
}


/* ======= Banner 区域 ======= */
/* Banner 容器 */
.banner-swiper-container {
  background: #fff;
  max-width: 600px;
  margin: 0 auto;
  overflow: hidden;
  position: relative;
}

/* 横向滚动容器 */
.banner-swiper {
  white-space: nowrap;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 10px;
  scrollbar-width: none; /* Firefox */
  scroll-behavior: smooth; /* 平滑滚动 */
}

.banner-preview {
  display: flex;
  gap: 10px;
  overflow-x: auto;
  padding: 10px 0 15px;
}

.banner-preview-img {
  height: 120px;
  border-radius: 4px;
  flex-shrink: 0;
}

.banner-swiper::-webkit-scrollbar {
  display: none; /* Chrome, Safari, Opera */
}

/* 幻灯片 */
.banner-slide {
  display: inline-block;
  width: calc(100% / 2.2); /* 约2.2张图片可见 */
  scroll-snap-align: start;
  margin-right: 10px;
  border-radius: 8px;
  overflow: hidden;
  vertical-align: top;
}

.banner-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ======= 内容区域：分类 + 产品 ======= */
.container,
.content-container {
  max-width: 600px;
  margin: 0 auto;
  background: #fff;
  padding-bottom: 30px;
}
.content-container {
  display: flex;
  flex-direction: row;
}
.sidebar {
  width: 30%;
  border-right: 1px solid #eee;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.category-list {
  list-style: none;
  padding: 0;
}
.category-item {
  padding: 10px;
  text-align: center;
  background: #eee;
  font-size: 14px;
  color: #333;
  cursor: pointer;
}
.category-item button {
  border: none;
  border-radius: 4px;
  cursor: pointer;
  padding: 4px 8px;
}
.category-item.active {
  background: #fff;
  font-weight: bold;
}
.main {
  width: 70%;
  padding: 10px;
}
.category-title {
  margin: 15px 0 8px;
  font-size: 16px;
  font-weight: bold;
  color: #333;
  border-left: 4px solid #FF7F00; /* 橙色标识 */
  padding-left: 6px;
}

/* ======= 产品卡片 ======= */
.product-card {
  display: flex;
  /* 如果需要两列布局，左右各占一半 */
  flex-direction: row;
  align-items: center;
  padding: 8px;
  border: 1px solid #eee;
  border-radius: 6px;
  margin-bottom: 8px;
  background: #fff;
}
.product-card:hover {
  background: #fafafa;
}
.product-image {
  /* 设置图片区域占 50% 宽度 */
  flex: 1;
  max-width: 50%;
  height: auto; /* 高度自适应 */
  object-fit: cover; /* 或使用 contain，根据图片展示需求选择 */
  border-radius: 4px;
  margin-right: 8px;
}
.product-info {
  /* 信息区域占 50% 宽度 */
  flex: 1;
  max-width: 50%;
  display: flex;
  flex-direction: column;
  /* 可根据需要添加内边距 */
  padding: 5px;
}
.product-name {
  font-size: 16px;
  font-weight: bold;
  color: #333;
  margin-bottom: 4px;
}
.product-tags {
  margin-bottom: 4px;
}
.product-tags span {
  display: inline-block;
  background: #fff;
  border: 1px solid #000;
  color: #000;
  padding: 2px 6px;
  border-radius: 4px;
  margin-right: 4px;
  font-size: 12px;
}
.product-desc {
  font-size: 13px;
  color: #666;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  }
.product-price {
  font-size: 14px;
  color: #e74c3c;
  font-weight: bold;
  margin-bottom: 4px;
}
.spec-btn {
  align-self: flex-end;
  background: #FF7F00;
  color: #fff;
  border: none;
  padding: 4px 8px;
  border-radius: 9999px; /* 圆滑胶囊 */
  font-size: 14px;
  cursor: pointer;
}
.spec-btn:hover {
  opacity: 0.9;
}

/* ======= 弹窗 (选规格) ======= */
.modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  justify-content: center;
  align-items: center;
}
.modal-content {
  display: flex;
  flex-direction: column;
  width: 90%;
  max-width: 400px;
  max-height: 90vh;  /* 限制弹窗高度 */
  background: #fff;
  border-radius: 8px;
  overflow: hidden;
  position: relative;
}
/* 滚动区域 */
.modal-body.scrollable {
  flex: 1;               /* 占满剩余空间 */
  overflow-y: auto;      /* 超出时滚动 */
  padding: 10px;
}
/* 固定底部区域 */
.modal-footer.fixed-footer {
  background: #f7f7f7;
  padding: 10px 0;
  /* 这里不设 flex:1; 让其保持固定高度 */
  border-top: 1px solid #eee;
}
.modal-header {
  position: relative;
  width: 100%;
  height: 260px;
  overflow: hidden;
}
.detail-image {
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #fff;
}
.close-btn {
  position: absolute;
  right: 10px;
  top: 10px;
  background: rgba(0,0,0,0.4);
  color: #fff;
  width: 30px;
  height: 30px;
  border: none;
  border-radius: 9999px;
  font-size: 18px;
  cursor: pointer;
}
.modal-body {
  padding: 10px 12px;
}
.detail-name {
  font-size: 26px;
  font-weight: bold;
  margin-bottom: 6px;
}
.detail-tags {
  margin-bottom: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 4px;
}
.detail-tags .tag {
  display: inline-block;
  background: #fff;
  border: 1px solid #000;
  color: #000;
  padding: 2px 6px;
  border-radius: 4px;
  margin-right: 4px;
  font-size: 12px;
}
.detail-desc {
  font-size: 12px;
  color: #666;
  margin-bottom: 10px;
  line-height: 1.5;
  padding: 4px;
}

/* 分割线 */
.divider {
  margin-top: 12px;
  border-top: 1px solid #666;  /* 黑色分割线 */
  margin-bottom: 12px;
  display: block;
}

/* ===== 规格选项 ===== */
.flavor-group {
  margin-bottom: 12px;
}
.flavor-group h4 {
  font-size: 14px;
  margin-bottom: 6px;
}
.options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.option {
  position: relative;
  background: #eaeaea;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 14px;
  color: #666;
  cursor: pointer;
}
.option:hover {
  opacity: 0.9;
}
.option.active {
  background: #FF7F00;
  color: #fff;
  border: 1px solid #FF7F00;
  box-shadow: 0 0 8px rgba(255,127,0,0.3);
}

/* 推荐标签：内联显示在选项文本前 */
.option-label {
  display: inline-block;
  background: #FF7F00;
  color: #fff;
  font-size: 12px;
  font-weight: bold;
  padding: 2px 8px;
  border-radius: 4px;
  margin-right: 8px;
  vertical-align: middle;
  box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* ===== 配料选项 ===== */
#toppingOptions {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}
.topping-row {
  display: flex;
  align-items: center;
  background: #eaeaea;
  padding: 4px 6px;
  position: relative;
  border-radius: 8px;
  transition: border-color 0.3s ease;
}

/* 配料项被选中时，背景变为橘色 */
.topping-row.active {
  border: 2px solid #FF7F00;  /* 橘色边框 */
}

/* 右上角数量标签 */
.topping-qty-tag {
  position: absolute;
  top: -8px;
  right: -13px;
  background: #FF7F00;  /* 橘色背景 */
  color: white;
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 9999px;
  display: none;
}

.topping-label {
  flex: 1;
  font-size: 13px;
  color: #333;
}
.topping-price {
  font-size: 12px;
  color: #FF7F00;
  margin-right: 6px;
}
.topping-btn {
  width: 24px;
  height: 24px;
  border: none;
  border-radius: 9999px;
  background: #ccc;
  color: #000;
  font-size: 16px;
  margin: 0 2px;
  cursor: pointer;
}
.topping-qty {
  width: 20px;
  text-align: center;
  font-size: 14px;
}

/* ===== 购买数量 ===== */
.quantity-group {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
  justify-content: flex-end;
}
.quantity-btn {
  width: 30px;
  height: 30px;
  background-color: #eaeaea;
  border: none;
  border-radius: 50%;
  font-size: 18px;
  color: #333;
  cursor: pointer;
}
.quantity-num {
  font-size: 16px;
  font-weight: bold;
  color: #333;
}

/* ===== 弹窗底部 ===== */
/* 金额文字样式 */
.detail-price {
  color: #FF7F00; /* 橙色文字 */
  font-size: 20px;
  font-weight: bold;
  margin-top: 10px; /* 增加顶部间距 */
  padding-left: 10px;
}

/* 小字说明（已选配料） */
.selected-info {
  background-color: #f0f0f0; /* 灰底 */
  color: #333; /* 黑字 */
  padding: 5px 0;
  font-size: 14px;
  margin-bottom: 15px; /* 给下方内容留出空间 */
  padding-left: 10px;
}
/* 小字说明（已选配料） */
.selected-info2 {
  background-color: #ffffff;
  color: #333; /* 黑字 */
  padding: 5px 0;
  font-size: 14px;
  margin-bottom: 15px; /* 给下方内容留出空间 */
}

/* 购买数量和金额一行 */
.price-and-quantity {
  display: flex;
  align-items: center;
  gap: 20px; /* 为金额和数量之间增加间距 */
  margin-bottom: 10px; /* 为下方内容（按钮）增加间距 */
}

/* 购买数量按钮样式 */
.quantity-group {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  flex: 1;
  padding-right: 10px;
}

.quantity-btn {
  border: none;
  padding: 10px;
  font-size: 18px;
  border-radius: 50%; /* 圆形按钮 */
  cursor: pointer;
  display: flex; /* 使内容居中 */
  justify-content: center;
  align-items: center;
}

/* 减号：白底，橙色文字 */
.quantity-btn:first-child {
  background-color: #ffffff;
  color: #FF7F00;
  border: 2px solid #FF7F00;
}

/* 加号：红底，白色文字 */
.quantity-btn:last-child {
  background-color: #E74C3C;
  color: white;
  border: 2px solid #E74C3C;
}

/* 立即购买按钮 */
.btn-buy {
  border: 2px solid #FF7F00; /* 橙色边框 */
  background-color: white; /* 白底 */
  color: #FF7F00; /* 橙色文字 */
  padding: 10px 20px;
  font-size: 16px;
  font-weight: bold;
  border-radius: 30px; /* 胶囊型 */
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px; /* 按钮与上方内容有更多间隙 */
}

.btn-buy:hover {
  background-color: #FF7F00; /* 橙色背景 */
  color: white; /* 白色文字 */
}

/* 添加至购物车按钮 */
.btn-add-cart {
  background-color: #E74C3C; /* 红底 */
  color: white; /* 白色文字 */
  border: none;
  padding: 10px 20px;
  font-size: 16px;
  font-weight: bold;
  border-radius: 30px; /* 胶囊型 */
  cursor: pointer;
  transition: all 0.3s ease;
  margin-top: 10px; /* 增加按钮的间距 */
}

.btn-add-cart:hover {
  background-color: #D44B3A; /* 红色背景变化 */
}

/* 按钮容器 */
.action-buttons {
  display: flex;
  gap: 10px; /* 按钮之间的间距 */
  justify-content: center; /* 按钮居中 */
}



/* ===== 底部购物车与结算栏 ===== */
/* ===== 底部购物栏（胶囊形浮窗） ===== */
.bottom-cart-bar {
  position: fixed;
  bottom: 50px;                /* 离底部留50px空隙 */
  left: 50%;
  transform: translateX(-50%);
  width: 80%;
  max-width: 500px;
  display: flex;
  align-items: center;
  border-radius: 9999px;       /* 胶囊形 */
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.2);
  z-index: 9999;               /* 确保置顶 */
}

/* 左侧：白色背景 */
.cart-left {
  flex: 1;
  background: #fff;            /* 左侧白色 */
  display: flex;
  align-items: center;
  padding: 8px 12px;
  gap: 8px;
}

/* 购物车图标区域 */
.cart-icon {
  position: relative;
  width: 28px;
  height: 28px;
  background: #fff;
  border-radius: 9999px;
  color: #333;
  font-size: 14px;
  text-align: center;
  line-height: 28px;
  border: 1px solid #ddd;      /* 细边框，可选 */
}

/* 购物车数量（右上角小圆点） */
.cart-count {
  position: absolute;
  top: -6px;
  right: -6px;
  background: #E74C3C;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  color: #fff;
  font-size: 12px;
  text-align: center;
  line-height: 18px;
}

/* 显示价格 */
.cart-price {
  font-size: 16px;
  color: #333;
  font-weight: bold;
}

/* 右侧：橘色背景，点击去结算 */
.cart-right {
  background: #FF7F00;         /* 右侧橘色 */
  color: #fff;
  padding: 10px 20px;
  font-size: 16px;
  cursor: pointer;
  white-space: nowrap;         /* 避免自动换行 */
}
.cart-right:hover {
  opacity: 0.9;
}

.btn-checkout {
  background: #FF7F00;
  color: #fff;
  border: none;
  border-radius: 9999px;
  padding: 8px 12px;
  font-size: 14px;
  cursor: pointer;
}

/* ===== 结算浮窗 ===== */
/* 结算浮窗容器 */
.checkout-container {
  display: flex;
  flex-direction: column;
  width: 90%;
  max-width: 500px;
  max-height: 90vh;  /* 限制弹窗高度 */
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}
/* 滚动的订单详情区域 */
.checkout-details.scrollable {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

/* 固定底部按钮区域 */
.checkout-footer {
  padding: 10px 20px;
  border-top: 1px solid #eee;
  background: #f7f7f7;
  text-align: center;
}

/* 标题 */
.checkout-details h3 {
  font-size: 24px;
  margin-bottom: 15px;
  color: #333;
}

/* 商品详情部分 */
.checkout-details p {
  font-size: 16px;
  color: #555;
  margin: 10px 0;
}

/* 按钮容器 */
.checkout-button {
  margin-top: 20px;
  width: 100%;
  display: flex;
  justify-content: center;
  gap: 10px;
}

/* 备注栏 */
.checkout-remark {
  margin-top: 12px;
  width: 100%;
}
.checkout-remark label {
  font-size: 14px;
  color: #333;
}
.checkout-remark textarea {
  width: 100%;
  height: 60px;
  font-size: 14px;
  margin-top: 4px;
  padding: 4px;
  border: 1px solid #ccc;
  border-radius: 4px;
  resize: none;
}

/* 取餐方式按钮 */
.pickup-type {
  display: flex;
  gap: 10px;
  margin-top: 12px;
  justify-content: center;
}
.pickup-btn {
  flex: 1;
  background: #eee;
  border: none;
  border-radius: 9999px;
  padding: 8px 12px;
  font-size: 14px;
  cursor: pointer;
}
.pickup-btn.active {
  background: #FF7F00;
  color: #fff;
}

/* 时间段选择区域 */
/* 时间类别标签 */
.time-category-tabs {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-bottom: 10px;
}
.time-category-btn {
  padding: 6px 12px;
  border: none;
  border-radius: 20px;
  background-color: #eee;
  font-size: 14px;
  cursor: pointer;
}
.time-category-btn.active {
  background-color: #FF7F00;
  color: #fff;
}

/* 时间段按钮 */
.time-slot-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
}
.time-btn {
  background: #f0f0f0;
  border: none;
  border-radius: 8px;
  padding: 6px 10px;
  font-size: 14px;
  cursor: pointer;
}
.time-btn:hover {
  background: #ddd;
}
.time-btn.disabled {
  background: #ccc;
  cursor: not-allowed;
  opacity: 0.6;
}
.time-btn.active {
  background: #FF7F00;
  color: #fff;
}


/* 结算按钮 */
.btn-checkout {
  background: linear-gradient(90deg, #ff7f00, #ff6a00);
  color: white;
  border: none;
  padding: 12px 24px;
  font-size: 18px;
  border-radius: 50px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease;
}

.btn-checkout:hover {
  background: linear-gradient(90deg, #ff6a00, #ff7f00);
  transform: scale(1.05);
}

/* 关闭按钮 */
.btn-close {
  background: #ccc;
  color: #fff;
  border: none;
  padding: 8px 16px;
  font-size: 14px;
  border-radius: 9999px;
  cursor: pointer;
}

.btn-close:hover {
  background: #bbb;
}

/* 动画效果 */
@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

@keyframes slideIn {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* 结算浮窗定位：居中显示 */
.modal#checkoutModal {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  display: none;
  z-index: 10000;
  width: 100%;
  max-width: 500px;
}

.modal#checkoutModal.active {
  display: flex;
  transition: all 0.3s ease-in-out;
}

/* ===== 管理后台 ===== */
/* 现代管理界面样式 */
.management-section {
  background: white;
  border-radius: 12px;
  padding: 20px;
  margin-bottom: 25px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.section-title {
  color: #FF7F00;
  border-left: 4px solid #FF7F00;
  padding-left: 12px;
  margin: 15px 0;
}

.form-group {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.modern-input {
  flex: 1;
  padding: 10px;
  border: 1px solid #ddd;
  border-radius: 8px;
  transition: all 0.3s;
}

.modern-input:focus {
  border-color: #FF7F00;
  box-shadow: 0 0 8px rgba(255,127,0,0.2);
}

.primary-btn {
  background: #FF7F00;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.3s;
}

.primary-btn:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.category-grid, .product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 15px;
}

.category-card {
  display: flex;
  align-items: center;
  padding: 15px;
  background: #f8f8f8;
  border-radius: 8px;
}

.product-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.product-thumb {
  width: 100%;
  height: 180px;
  object-fit: cover;
}

.action-bar {
  display: flex;
  gap: 8px;
  margin-top: 10px;
}

.icon-btn {
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.delete-btn { background: #e74c3c; color: white; }
.edit-btn { background: #3498db; color: white; }

.modern-table {
  width: 100%;
  border-collapse: collapse;
  background: white;
  border-radius: 8px;
  overflow: hidden;
}

.modern-table th {
  background: #FF7F00;
  color: white;
  padding: 15px;
  text-align: left;
}

.modern-table td {
  padding: 12px;
  border-bottom: 1px solid #eee;
}

.status-select {
  padding: 6px 12px;
  border-radius: 20px;
  border: 1px solid #ddd;
  background: white;
}
/* 高级表单样式 */
.option-section {
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 15px;
  margin: 20px 0;
}

.option-group {
  margin-bottom: 25px;
}

.option-group h3 {
  color: #666;
  margin-bottom: 12px;
  padding-left: 8px;
  border-left: 3px solid #FF7F00;
}

.option-item {
  display: grid;
  grid-template-columns: 2fr 1fr auto auto;
  gap: 10px;
  align-items: center;
  margin-bottom: 10px;
  padding: 8px;
  background: #f8f8f8;
  border-radius: 6px;
}

.image-card {
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.thumbnail {
  width: 100%;
  height: 120px;
  object-fit: cover;
}

.image-meta {
  display: flex;
  justify-content: space-between;
  padding: 8px;
  background: rgba(0,0,0,0.7);
  color: white;
  position: absolute;
  bottom: 0;
  width: 100%;
}

.manage-link {
  color: #FF7F00;
  text-decoration: none;
  font-size: 0.9em;
  margin-left: 10px;
}

/* 订单成功弹窗样式 */
.order-success-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.order-success-content {
  background: white;
  padding: 30px;
  border-radius: 10px;
  text-align: center;
  max-width: 400px;
  width: 90%;
  box-shadow: 0 5px 15px rgba(0,0,0,0.3);
  animation: fadeIn 0.3s ease-out;
}

.order-success-content h3 {
  color: #4CAF50;
  margin-bottom: 20px;
}

.order-number {
  font-size: 18px;
  margin: 15px 0;
  padding: 10px;
  background: #f5f5f5;
  border-radius: 5px;
}

.order-number strong {
  color: #2196F3;
  font-size: 20px;
}

.confirm-btn {
  background: #4CAF50;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-size: 16px;
  margin-top: 20px;
}

.confirm-btn:hover {
  background: #45a049;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

/* 图片管理页面样式 */
.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  padding: 20px;
}

.image-card {
  border: 1px solid #eee;
  border-radius: 8px;
  overflow: hidden;
  transition: transform 0.3s;
}

.image-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.thumbnail {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.image-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px;
  background: #000;
}

.image-meta button {
  background: #e74c3c;
  color: white;
  border: none;
  padding: 5px 10px;
  border-radius: 4px;
  cursor: pointer;
}

/* 订单历史按钮 */
.order-history-btn {
  background-color: #FF7F00;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 4px;
  margin-left: 10px;
  cursor: pointer;
  white-space: nowrap;
  font-weight: bold;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  transition: all 0.3s ease;
}

.order-history-btn:hover {
  background-color: #e67300;
  transform: translateY(-1px);
}

/* 订单历史弹窗 */
#orderHistoryModal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.5);
  justify-content: center;
  align-items: center;
}

/* 订单历史弹窗内容 */
.modal-content {
  background: white;
  width: 90%;
  max-width: 500px;
  max-height: 80vh;
  border-radius: 8px;
  overflow: hidden;
}

.modal-header2 {
  padding: 15px;
  height: 70px;
  background: #FF7F00;
  color: white;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-header2 h3 {
  margin: 0;
}

.modal-body.scrollable2 {
  padding: 15px;
  overflow-y: auto;
}

/* 订单卡片 */
.order-card {
  border: 1px solid #eee;
  border-radius: 8px;
  padding: 15px;
  margin-bottom: 15px;
  background: white;
  box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.order-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.1);
  transform: translateY(-2px);
  transition: all 0.3s ease;
}
.order-thumbs {
  display: flex;
  gap: 4px;
}
.order-thumbs img {
  width: 40px;
  height: 40px;
  object-fit: cover;
  border-radius: 4px;
}
.order-time {
  font-size: 14px;
  color: #666;
  margin-bottom: 10px;
}

.order-content {
  display: flex;
  margin-bottom: 10px;
  align-items: center;
  gap: 15px;
}

.order-thumbnail {
  width: 80px;
  height: 80px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid #eee;
}

.order-price {
  font-weight: bold;
  color: #FF7F00;
  margin-left: auto;
}

.order-status {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed #eee;
}

.status-badge {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 12px;
}

.status-pending {
  background: #FFD700;
  color: #333;
}

.status-waiting {
  background: #9e34db;
  color: white;
}

.status-preparing {
  background: #3498db;
  color: white;
}

.status-completed {
  background: #2ecc71;
  color: white;
}

.status-cancelled {
  background: #111111;
  color: white;
}

.cancel-btn {
  background: #e74c3c;
  color: white;
  border: none;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.cancel-btn:hover {
  background: #c0392b;
  transform: translateY(-1px);
}

/* matchResult元素样式 */
#matchResult {
  display: none; /* 默认隐藏 */
  position: absolute;
  left: -9999px; /* 移出可视区域 */
}

/* 结算时临时显示 */
#matchResult.visible {
  display: block;
  position: static;
  left: auto;
}

/* 公共按钮样式 */
.action-btn {
  padding: 8px 16px;
  border: none;
  border-radius: 5px;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  margin: 0 5px;
  transition: background-color 0.3s, transform 0.2s;
}

.action-btn:hover {
  transform: translateY(-2px);
}

/* 详情按钮 */
.info-btn {
  background-color: #28a745;  /* 绿色背景 */
  color: #fff;
}

.info-btn:hover {
  background-color: #218838;
}

/* 删除按钮 */
.delete-btn {
  background-color: #dc3545;  /* 红色背景 */
  color: #fff;
}

.delete-btn:hover {
  background-color: #c82333;
}

.category-list2 {
  list-style: none;
  padding: 0;
}

.category-grid2 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);  /* 三列 */
  gap: 12px;
}

.category-item2 {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 10px;
  border: 1px solid #eee;
  border-radius: 6px;
  background: #fafafa;
}


/* 商品管理页面样式 */
.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: Arial, sans-serif;
}

.admin-section {
    margin-bottom: 30px;
    padding: 20px;
    background-color: #f5f5f5;
    border-radius: 8px;
}

.admin-section h2 {
    margin-top: 0;
    color: #333;
    border-bottom: 1px solid #ddd;
    padding-bottom: 10px;
}

/* 商品管理页面样式 */
.admin-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    font-family: Arial, sans-serif;
}
