/* ===========================
   萤火商城 - 主样式
   =========================== */

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { font-family: "Microsoft YaHei", "微软雅黑", Arial, sans-serif; color: #333; background: #f5f5f5; font-size: 14px; }
a { color: inherit; text-decoration: none; }
a:hover { color: #e07b00; }
ul { list-style: none; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 15px; }

/* ---- 顶部信息栏 ---- */
.top-bar {
  background: #fff;
  color: #666;
  font-size: 12px;
  padding: 8px 0;
  border-bottom: 1px solid #eee;
}
.top-bar .container { display: flex; justify-content: space-between; align-items: center; }
/* 左侧：公司名称 */
.top-company {
  color: #e07b00;
  font-size: 13px;
  font-weight: bold;
  letter-spacing: 0.5px;
}
/* 右侧：登录/注册按钮 + 其他链接 */
.top-right { display: flex; align-items: center; gap: 4px; }
.top-right a { color: #666; margin: 0 4px; font-size: 12px; }
.top-right a:hover { color: #e07b00; }
.top-right i { margin-right: 3px; }
.sep { color: #ddd; margin: 0 2px; }
.btn-login, .btn-reg, .btn-merchant-top {
  display: inline-block;
  color: #666 !important;
  background: transparent;
  border: 1px solid #ddd;
  padding: 3px 12px;
  border-radius: 3px;
  font-size: 12px;
  transition: all 0.15s;
  line-height: 1.4;
}
.btn-login:hover, .btn-reg:hover, .btn-merchant-top:hover {
  border-color: #e07b00;
  color: #e07b00 !important;
}

.form-agree {
  margin: 10px 0 4px;
  font-size: 13px;
  color: #555;
}
.form-agree a {
  color: #e07b00;
  text-decoration: none;
}
.form-agree a:hover {
  text-decoration: underline;
}
.agree-label {
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  line-height: 1.5;
}
.agree-label input[type="checkbox"] {
  flex-shrink: 0;
  width: 15px;
  height: 15px;
  accent-color: #e07b00;
}

/* ---- 主头部 ---- */
.main-header {
  background: #fff;
  padding: 14px 0;
  border-bottom: 1px solid #eee;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
/* Logo 左，搜索+购物车右 */
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.logo-area { flex: 0 0 auto; }
.logo-img {
  height: 70px;
  width: auto;
  display: block;
  padding: 4px 0;
}
.logo-text {
  font-size: 30px;
  font-weight: 900;
  color: #e07b00;
  letter-spacing: 2px;
  line-height: 1;
}
.logo-sub {
  font-size: 11px;
  color: #999;
  letter-spacing: 3px;
  text-transform: lowercase;
  margin-top: 3px;
}
/* 右侧区域：搜索框 + 购物车 */
.header-right { display: flex; align-items: center; gap: 16px; }
.search-area { display: flex; width: 300px; }
.search-area input {
  width: 220px;
  border: 1px solid #e07b00;
  border-right: none;
  padding: 7px 12px;
  font-size: 13px;
  outline: none;
  border-radius: 4px 0 0 4px;
  color: #333;
}
.search-area button {
  background: #e07b00;
  color: #fff;
  border: none;
  padding: 7px 16px;
  font-size: 13px;
  cursor: pointer;
  border-radius: 0 4px 4px 0;
  transition: background 0.2s;
  white-space: nowrap;
}
.search-area button:hover { background: #c06a00; }
.cart-area a {
  position: relative;
  font-size: 24px;
  color: #e07b00;
  display: flex;
  align-items: center;
}
.cart-num {
  position: absolute;
  top: -6px;
  right: -8px;
  background: #e74c3c;
  color: #fff;
  font-size: 10px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---- 主导航 ---- */
.main-nav {
  background: #222;
}
.main-nav ul { display: flex; }
.main-nav ul li a {
  display: block;
  padding: 14px 22px;
  color: #fff;
  font-size: 14px;
  transition: all 0.2s;
}
.main-nav ul li a:hover,
.main-nav ul li.active a {
  background: #e07b00;
  color: #fff;
}

/* ---- 主内容区（分类+Banner）---- */
.main-content {
  display: flex;
  margin-top: 18px;
  gap: 16px;
  align-items: flex-start;
}

/* 分类侧栏 */
.category-sidebar {
  flex: 0 0 180px;
  background: #fff;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.cat-title {
  background: #e07b00;
  color: #fff;
  padding: 14px 18px;
  font-size: 15px;
  font-weight: bold;
  letter-spacing: 1px;
}
.category-sidebar ul li a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 18px;
  border-bottom: 1px solid #f5f5f5;
  color: #444;
  font-size: 13px;
  transition: all 0.15s;
}
.category-sidebar ul li a i { color: #e07b00; width: 16px; text-align: center; }
.category-sidebar ul li a:hover { background: #fff8f0; color: #e07b00; padding-left: 24px; }

/* Banner */
.banner-wrap {
  flex: 1;
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  height: 320px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.12);
}
.banner-slider { width: 100%; height: 100%; position: relative; }
.slide {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.6s ease;
}
.slide.active { opacity: 1; z-index: 1; }
.slide-content { display: none; }
.slide-content h2 { font-size: 36px; font-weight: 900; text-shadow: 2px 2px 10px rgba(0,0,0,0.8); margin-bottom: 10px; }
.slide-content p { font-size: 16px; text-shadow: 1px 1px 6px rgba(0,0,0,0.8); margin-bottom: 20px; }
.btn-slide {
  display: inline-block;
  background: #e07b00;
  color: #fff;
  padding: 10px 30px;
  border-radius: 25px;
  font-size: 15px;
  transition: all 0.2s;
  box-shadow: 0 4px 12px rgba(224,123,0,0.4);
}
.btn-slide:hover { background: #fff; color: #e07b00; }
.banner-dots { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); z-index: 10; display: flex; gap: 8px; }
.dot { width: 8px; height: 8px; border-radius: 50%; background: rgba(255,255,255,0.5); cursor: pointer; transition: all 0.2s; }
.dot.active { background: #e07b00; width: 20px; border-radius: 4px; }
.banner-prev, .banner-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0,0,0,0.3);
  color: #fff;
  border: none;
  width: 36px; height: 36px;
  border-radius: 50%;
  font-size: 16px;
  cursor: pointer;
  z-index: 10;
  transition: background 0.2s;
  display: flex; align-items: center; justify-content: center;
}
.banner-prev { left: 10px; }
.banner-next { right: 10px; }
.banner-prev:hover, .banner-next:hover { background: #e07b00; }

/* ---- 公告栏 ---- */
.notice-bar {
  display: flex;
  align-items: center;
  background: #fff8ee;
  border: 1px solid #ffe0a0;
  border-radius: 4px;
  padding: 10px 16px;
  margin: 16px 0;
  gap: 12px;
  overflow: hidden;
}
.notice-label { color: #e07b00; font-weight: bold; white-space: nowrap; font-size: 13px; }
.notice-scroll { flex: 1; overflow: hidden; white-space: nowrap; color: #666; font-size: 13px; }
.notice-scroll span { margin-right: 40px; }

/* ---- 商品区块标题 ---- */
.section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0 10px;
  border-bottom: 2px solid #e07b00;
  margin-bottom: 14px;
  margin-top: 10px;
}
.section-title h3 { font-size: 18px; color: #1a3a5c; }
.section-title h3 i { color: #e07b00; margin-right: 8px; }
.view-more { color: #e07b00; font-size: 13px; }

/* ---- 商品网格 ---- */
.product-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 24px; }
.product-card, a.product-card {
  display: block;
  background: #fff;
  border-radius: 6px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
  transition: all 0.25s;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}
.product-card:hover, a.product-card:hover { transform: translateY(-4px); box-shadow: 0 8px 20px rgba(0,0,0,0.12); }
.product-img {
  width: 100%;
  height: 200px;
  background: #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.product-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}
.product-card:hover .product-img img { transform: scale(1.05); }
/* 商品图占位背景色 */
.beauty-bg1 { background: linear-gradient(135deg, #fce4ec, #f8bbd0); }
.beauty-bg1::after { content: "💄"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.beauty-bg2 { background: linear-gradient(135deg, #e8eaf6, #c5cae9); }
.beauty-bg2::after { content: "🌸"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.beauty-bg3 { background: linear-gradient(135deg, #e0f2f1, #b2dfdb); }
.beauty-bg3::after { content: "✨"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.beauty-bg4 { background: linear-gradient(135deg, #fff3e0, #ffe0b2); }
.beauty-bg4::after { content: "🧴"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }

.baby-bg1 { background: linear-gradient(135deg, #e3f2fd, #bbdefb); }
.baby-bg1::after { content: "🍼"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.baby-bg2 { background: linear-gradient(135deg, #f3e5f5, #e1bee7); }
.baby-bg2::after { content: "👶"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.baby-bg3 { background: linear-gradient(135deg, #e8f5e9, #c8e6c9); }
.baby-bg3::after { content: "🌾"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.baby-bg4 { background: linear-gradient(135deg, #fffde7, #fff9c4); }
.baby-bg4::after { content: "🧸"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }

.food-bg1 { background: linear-gradient(135deg, #fafafa, #f0f0f0); }
.food-bg1::after { content: "🥜"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.food-bg2 { background: linear-gradient(135deg, #fff8e1, #ffecb3); }
.food-bg2::after { content: "🍯"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.food-bg3 { background: linear-gradient(135deg, #fce4ec, #f8bbd0); }
.food-bg3::after { content: "🍷"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.food-bg4 { background: linear-gradient(135deg, #e8f5e9, #c8e6c9); }
.food-bg4::after { content: "🍡"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }

.fashion-bg1 { background: linear-gradient(135deg, #f3e5f5, #e1bee7); }
.fashion-bg1::after { content: "👜"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.fashion-bg2 { background: linear-gradient(135deg, #e8eaf6, #c5cae9); }
.fashion-bg2::after { content: "🧣"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.fashion-bg3 { background: linear-gradient(135deg, #fff3e0, #ffe0b2); }
.fashion-bg3::after { content: "👗"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }
.fashion-bg4 { background: linear-gradient(135deg, #e3f2fd, #bbdefb); }
.fashion-bg4::after { content: "🧳"; font-size: 56px; display: flex; align-items: center; justify-content: center; height: 100%; }

.product-info { padding: 12px 14px; }
.product-name { font-size: 13px; color: #444; line-height: 1.5; margin-bottom: 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.product-price { color: #e07b00; font-size: 16px; font-weight: bold; }
.product-price span { font-size: 20px; }

/* ---- 商家入驻横幅 ---- */
.merchant-banner {
  background: linear-gradient(135deg, #1a3a5c 0%, #2d6a9f 100%);
  padding: 40px 0;
  margin: 24px 0;
}
.merchant-content { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 20px; }
.merchant-content h3 { color: #fff; font-size: 22px; }
.merchant-content h3 i { color: #e07b00; margin-right: 10px; }
.merchant-content p { color: #aaccee; font-size: 14px; margin-top: 6px; }
.btn-merchant {
  display: inline-block;
  background: #e07b00;
  color: #fff;
  padding: 12px 36px;
  border-radius: 30px;
  font-size: 16px;
  font-weight: bold;
  transition: all 0.2s;
  white-space: nowrap;
}
.btn-merchant:hover { background: #fff; color: #e07b00; }

/* ---- 页脚（新样式 - 参考悦之米） ---- */
.main-footer { background: #1a1a2e; color: #aaa; padding: 0; }
.footer-inner { display: none; }
.footer-info-line {
  text-align: center;
  padding: 16px 0 8px;
  color: #999;
  font-size: 13px;
}
.footer-info-line span { margin: 0 10px; }
.footer-links-line {
  text-align: center;
  padding: 4px 0 8px;
  color: #999;
  font-size: 13px;
}
.footer-links-line a {
  color: #999;
  margin: 0 8px;
  transition: color 0.2s;
}
.footer-links-line a:hover { color: #e07b00; }
.footer-links-line .sep { color: #444; margin: 0 4px; }
.footer-bottom {
  border-top: 1px solid #2d2d4e;
  padding: 12px 0 16px;
  text-align: center;
  color: #666;
  font-size: 12px;
}
.footer-bottom a { color: #888; }
.footer-bottom a:hover { color: #e07b00; }

/* ---- 返回顶部 ---- */
.float-top {
  position: fixed;
  bottom: 80px;
  right: 20px;
  z-index: 999;
  display: none;
}
.float-top.show { display: block; }
.float-top a {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e07b00;
  color: #fff;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  font-size: 18px;
  text-align: center;
  box-shadow: 0 4px 14px rgba(224,123,0,0.4);
  transition: all 0.2s;
  text-decoration: none;
  cursor: pointer;
}
.float-top a:hover { background: #c06a00; transform: scale(1.1); color: #fff; }

/* ---- 响应式 ---- */
@media (max-width: 900px) {
  .main-content { flex-direction: column; }
  .category-sidebar { flex: none; width: 100%; }
  .category-sidebar ul { display: flex; flex-wrap: wrap; }
  .category-sidebar ul li { flex: 1 1 25%; }
  .banner-wrap { height: 220px; }
  .product-grid { grid-template-columns: repeat(2, 1fr); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .main-nav ul li a { padding: 12px 14px; font-size: 13px; }
}
@media (max-width: 600px) {
  .header-inner { flex-wrap: wrap; }
  .header-right { width: 100%; order: 3; margin-top: 8px; }
  .search-area { flex: 1; width: 100%; }
  .search-area input { flex: 1; width: auto; }
  .top-bar .container { flex-direction: column; gap: 4px; text-align: center; }
  .product-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .footer-inner { grid-template-columns: 1fr; }
  .merchant-content { flex-direction: column; text-align: center; }
  .slide-content h2 { font-size: 22px; }
}

/* ============================================
   登录/注册/购物车/支付 弹窗样式
   ============================================ */

/* 遮罩 */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  z-index: 9000;
}
.modal-overlay.show { display: block; }

/* 弹窗通用 */
.modal-box {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -48%) scale(0.95);
  background: #fff;
  border-radius: 10px;
  width: 380px;
  max-width: 95vw;
  z-index: 9001;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  transition: transform 0.25s ease, opacity 0.25s ease;
  opacity: 0;
}
.modal-box.show {
  display: block;
  transform: translate(-50%, -50%) scale(1);
  opacity: 1;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 22px 14px;
  border-bottom: 1px solid #f0f0f0;
}
.modal-header h3 { font-size: 17px; color: #222; }
.modal-header h3 i { color: #e07b00; margin-right: 6px; }
.modal-close {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #999;
  line-height: 1;
  padding: 0 4px;
}
.modal-close:hover { color: #e07b00; }

.modal-body { padding: 20px 22px 24px; }

/* 表单 */
.form-group { margin-bottom: 14px; }
.form-group label { display: block; font-size: 13px; color: #555; margin-bottom: 5px; }
.form-group input {
  width: 100%;
  border: 1px solid #ddd;
  border-radius: 5px;
  padding: 9px 12px;
  font-size: 14px;
  outline: none;
  transition: border-color 0.2s;
}
.form-group input:focus { border-color: #e07b00; }
.form-tip { font-size: 12px; min-height: 18px; margin-bottom: 8px; }
.btn-submit {
  width: 100%;
  background: #e07b00;
  color: #fff;
  border: none;
  border-radius: 5px;
  padding: 11px 0;
  font-size: 15px;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-submit:hover { background: #c06a00; }
.modal-switch { text-align: center; margin-top: 12px; font-size: 13px; color: #888; }
.modal-switch a { color: #e07b00; }
.user-hello { color: #333; font-size: 12px; margin-right: 6px; }

/* 购物车侧边栏 */
.cart-drawer {
  position: fixed;
  top: 0;
  right: -400px;
  width: 380px;
  max-width: 95vw;
  height: 100vh;
  background: #fff;
  z-index: 9002;
  display: flex;
  flex-direction: column;
  box-shadow: -4px 0 30px rgba(0,0,0,0.15);
  transition: right 0.3s ease;
}
.cart-drawer.open { right: 0; }
.cart-drawer-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px;
  border-bottom: 1px solid #f0f0f0;
}
.cart-drawer-header h3 { font-size: 16px; color: #222; }
.cart-drawer-header h3 i { color: #e07b00; margin-right: 6px; }
.cart-drawer-header button {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #999;
}
.cart-drawer-header button:hover { color: #e07b00; }
.cart-drawer-body { flex: 1; overflow-y: auto; padding: 12px 14px; }
.cart-drawer-footer {
  padding: 14px 18px;
  border-top: 1px solid #f0f0f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.cart-total { font-size: 15px; color: #333; }
.cart-total span { color: #e07b00; font-weight: bold; font-size: 18px; }
.btn-checkout {
  background: #e07b00;
  color: #fff;
  border: none;
  border-radius: 5px;
  padding: 10px 28px;
  font-size: 15px;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-checkout:hover { background: #c06a00; }
.cart-empty { text-align: center; padding: 50px 0; color: #bbb; }
.cart-empty i { font-size: 48px; display: block; margin-bottom: 12px; }

/* 购物车商品项 */
.cart-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid #f5f5f5;
}
.cart-item img { width: 60px; height: 60px; object-fit: cover; border-radius: 4px; flex-shrink: 0; }
.cart-item-info { flex: 1; min-width: 0; }
.cart-item-name { font-size: 12px; color: #333; line-height: 1.4; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cart-item-price { font-size: 14px; color: #e07b00; margin-top: 4px; font-weight: bold; }
.cart-item-ctrl { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.cart-item-ctrl button {
  width: 24px; height: 24px;
  border: 1px solid #ddd;
  background: #f5f5f5;
  border-radius: 3px;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
}
.cart-item-ctrl button:hover { background: #e07b00; color: #fff; border-color: #e07b00; }
.cart-item-ctrl span { font-size: 14px; min-width: 20px; text-align: center; }
.cart-item-del { background: none; border: none; color: #ccc; cursor: pointer; padding: 4px; flex-shrink: 0; }
.cart-item-del:hover { color: #e74c3c; }

/* 支付弹窗 */
.modal-pay { width: 420px; }
.pay-body { text-align: center; }
.pay-amount { font-size: 16px; color: #333; margin-bottom: 14px; }
.pay-amount span { color: #e07b00; font-size: 24px; font-weight: bold; }
.alipay-qr { margin: 0 auto 14px; width: 220px; height: 220px; border: 2px solid #1677ff; border-radius: 8px; padding: 4px; overflow: hidden; }
.alipay-qr img { width: 100%; height: 100%; object-fit: contain; display: block; }
.pay-tip { color: #666; font-size: 13px; margin-bottom: 18px; }
.pay-tip i { color: #1677ff; margin-right: 5px; }
.pay-actions { display: flex; gap: 12px; justify-content: center; }
.btn-pay-done {
  background: #1677ff;
  color: #fff;
  border: none;
  border-radius: 5px;
  padding: 10px 28px;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-pay-done:hover { background: #0e5ecf; }
.btn-pay-cancel {
  background: #fff;
  color: #666;
  border: 1px solid #ddd;
  border-radius: 5px;
  padding: 10px 28px;
  font-size: 14px;
  cursor: pointer;
}
.btn-pay-cancel:hover { border-color: #e07b00; color: #e07b00; }

/* 支付成功 */
.modal-success .success-icon { font-size: 56px; color: #52c41a; margin-bottom: 14px; }
.modal-success h3 { font-size: 20px; color: #222; margin-bottom: 8px; }
.modal-success p { color: #888; font-size: 14px; }
.order-no { color: #999; font-size: 12px; margin-top: 8px; }

/* Toast提示 */
.wk-toast {
  position: fixed;
  bottom: 80px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(0,0,0,0.75);
  color: #fff;
  padding: 10px 24px;
  border-radius: 20px;
  font-size: 14px;
  z-index: 9999;
  opacity: 0;
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
  max-width: 80vw;
  width: auto;
  display: inline-block;
  white-space: nowrap;
  text-align: center;
  line-height: 1.5;
}
.wk-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }
.wk-toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* 通用确认弹窗 */
.modal-confirm-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.55);
  z-index: 9001; display: none;
}
.modal-confirm-overlay.show { display: block; }
.modal-confirm {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) scale(0.95);
  width: 360px;
  max-width: 90vw;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  z-index: 9002;
  opacity: 0;
  transition: opacity 0.25s, transform 0.25s;
  display: none;
}
.modal-confirm.show {
  display: block;
  opacity: 1;
  transform: translate(-50%, -50%) scale(1);
}
.modal-confirm .modal-body {
  text-align: center;
  padding: 24px 22px 22px;
}
.modal-confirm .confirm-icon {
  font-size: 44px; color: #e07b00; margin-bottom: 12px;
}
.modal-confirm.danger .confirm-icon { color: #e74c3c; }
.modal-confirm .confirm-title {
  font-size: 17px; color: #222; font-weight: 600; margin-bottom: 8px;
}
.modal-confirm .confirm-msg {
  font-size: 14px; color: #666; line-height: 1.5; margin-bottom: 22px;
}
.modal-confirm .confirm-actions {
  display: flex; gap: 12px; justify-content: center;
}
.modal-confirm .confirm-actions button {
  padding: 10px 26px; border-radius: 22px; font-size: 14px;
  font-weight: 600; cursor: pointer; border: none; transition: all .2s;
}
.modal-confirm .btn-confirm-cancel {
  background: #f5f5f5; color: #666;
}
.modal-confirm .btn-confirm-cancel:hover { background: #e8e8e8; }
.modal-confirm .btn-confirm-ok {
  background: linear-gradient(135deg, #e07b00, #f09020); color: #fff;
}
.modal-confirm .btn-confirm-ok:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(224,123,0,.3); }
.modal-confirm .btn-confirm-danger {
  background: linear-gradient(135deg, #e74c3c, #ff6b6b); color: #fff;
}
.modal-confirm .btn-confirm-danger:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(231,76,60,.3); }

/* ===========================
   个人中心下拉面板
   =========================== */
.user-dropdown {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  width: 420px;
  max-width: 95vw;
  background: #fff;
  border-radius: 10px;
  box-shadow: 0 12px 48px rgba(0,0,0,0.22);
  z-index: 9100;
  margin-top: 4px;
  overflow: hidden;
}
.user-dropdown.open { display: block; }

.user-dd-inner { max-height: 520px; overflow-y: auto; }

.user-dd-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background: linear-gradient(135deg, #1a1a2e 0%, #2a3a5e 100%);
  color: #fff;
}
.user-dd-avatar {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: rgba(255,255,255,0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  overflow: hidden;
  flex-shrink: 0;
}
.user-dd-avatar img { width: 100%; height: 100%; object-fit: cover; }
.user-dd-avatar i { color: #dce8f5; }
.user-dd-info { flex: 1; min-width: 0; }
.user-dd-name { display: block; font-size: 15px; font-weight: bold; }
.user-dd-phone { display: block; font-size: 12px; color: #aac; margin-top: 2px; }
.user-dd-close {
  background: none; border: none;
  color: #aac; font-size: 18px; cursor: pointer;
  flex-shrink: 0;
}
.user-dd-close:hover { color: #fff; }

/* tabs */
.user-dd-tabs {
  display: flex;
  border-bottom: 2px solid #f0f0f0;
  background: #fafafa;
}
.user-dd-tab {
  flex: 1;
  border: none;
  background: none;
  padding: 12px 4px;
  font-size: 13px;
  color: #888;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  margin-bottom: -2px;
  transition: all 0.2s;
}
.user-dd-tab:hover { color: #e07b00; }
.user-dd-tab.active { color: #e07b00; border-bottom-color: #e07b00; font-weight: bold; }

/* panels */
.user-dd-panel { display: none; padding: 16px 20px 20px; }
.user-dd-panel.active { display: block; }

/* avatar panel */
.dd-avatar-preview {
  width: 100px; height: 100px;
  border-radius: 50%;
  background: #f0f0f0;
  margin: 0 auto 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 56px;
  color: #ccc;
  overflow: hidden;
}
.dd-avatar-preview img { width: 100%; height: 100%; object-fit: cover; }
.dd-avatar-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-bottom: 14px;
}
.dd-upload-btn {
  display: inline-block;
  width: auto !important;
  padding: 10px 20px !important;
  cursor: pointer;
}

/* topRight 相对定位 */
.top-right { position: relative; }

