/* CigarPage Clone - Stylesheet */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --black: #1a1a1a;
  --dark: #222;
  --red: #c8102e;
  --red-dark: #a00d24;
  --gray: #f5f5f5;
  --gray-border: #e0e0e0;
  --text: #333;
  --text-light: #777;
  --white: #fff;
  --green: #2e7d32;
}

body {
  font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.5;
  font-size: 15px;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 16px;
}

/* ===== Top Bar ===== */
.topbar {
  background: var(--black);
  color: var(--white);
  font-size: 12px;
  text-align: center;
  padding: 8px 0;
  letter-spacing: 1px;
}

.topbar span {
  text-transform: uppercase;
}

/* ===== Header ===== */
.site-header {
  background: var(--white);
  border-bottom: 1px solid var(--gray-border);
  position: sticky;
  top: 0;
  z-index: 100;
}

/* 移动端导航自动收起（main.js 滚动方向驱动）：
   往下浏览产品时整个头部上滑隐藏，不再遮挡内容；往回滑时滑出 */
.site-header {
  transition: transform 0.28s ease;
  will-change: transform;
}
.site-header.header-hidden {
  transform: translateY(-105%);
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  gap: 24px;
}

.logo {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: 1px;
  color: var(--black);
  white-space: nowrap;
}

.logo .star {
  color: var(--red);
}

.logo small {
  display: block;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 2px;
  color: var(--text-light);
  text-align: center;
}

.search-box {
  flex: 1;
  max-width: 480px;
  position: relative;
}

.search-box input {
  width: 100%;
  padding: 11px 44px 11px 16px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  outline: none;
}

.search-box input:focus {
  border-color: var(--black);
}

.search-box button {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  color: var(--text-light);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.header-action {
  display: flex;
  flex-direction: column;
  align-items: center;
  font-size: 11px;
  font-weight: 600;
  color: var(--black);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  transition: color 0.2s ease;
}

.header-action svg {
  width: 25px;
  height: 25px;
  margin-bottom: 3px;
  transition: transform 0.2s ease;
}

.header-action:hover {
  color: var(--red);
}

.header-action:hover svg {
  transform: translateY(-2px) scale(1.12);
}

/* 注册按钮（头部，登录前） */
.register-action {
  flex-direction: column;
  color: var(--red);
  background: none;
  border: none;
  border-radius: 0;
  padding: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.5px;
  white-space: nowrap;
  transition: color 0.2s ease;
}

.register-action:hover {
  color: var(--red-dark);
}

.cart-link {
  position: relative;
}

.cart-link:hover svg {
  animation: cartBounce 0.5s ease;
}

@keyframes cartBounce {
  0%, 100% { transform: translateY(-2px) scale(1.12) rotate(0deg); }
  30% { transform: translateY(-4px) scale(1.15) rotate(-8deg); }
  60% { transform: translateY(-2px) scale(1.12) rotate(6deg); }
}

.cart-count {
  position: absolute;
  top: -5px;
  right: -9px;
  background: var(--red);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  border-radius: 50%;
  min-width: 18px;
  height: 18px;
  padding: 0 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 0 2px var(--white);
  animation: cartPop 0.3s ease;
}

@keyframes cartPop {
  0% { transform: scale(0); }
  70% { transform: scale(1.25); }
  100% { transform: scale(1); }
}

/* ===== Main Nav ===== */
.main-nav {
  background: var(--black);
  border-top: 1px solid #333;
}

.main-nav .container {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
}

.main-nav a {
  color: var(--white);
  padding: 14px 20px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  display: block;
  transition: background 0.15s;
}

.main-nav a:hover,
.main-nav a.active {
  background: var(--red);
}

/* ===== Hero ===== */
.hero {
  background: linear-gradient(135deg, #efefef 0%, #d8d8d8 100%);
  color: var(--black);
  text-align: center;
  padding: 60px 20px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 120%, rgba(200,16,46,0.10), transparent 60%);
}

.hero-inner {
  position: relative;
  z-index: 1;
}

.hero-announce {
  color: var(--red);
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 2px;
  text-align: center;
  margin-bottom: 18px;
  word-spacing: 4px;
  line-height: 1.6;
}

.hero h1 {
  font-size: 42px;
  font-weight: 900;
  letter-spacing: 1px;
  margin-bottom: 12px;
  text-align: center;
  word-spacing: 4px;
  line-height: 1.4;
}

.hero p {
  font-size: 17px;
  color: #5a5a5a;
  max-width: 640px;
  margin: 0 auto 24px;
}

.hero .btn {
  background: var(--red);
  color: var(--white);
  padding: 14px 34px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  display: inline-block;
  border-radius: 2px;
  transition: background 0.15s;
}

.hero .btn:hover {
  background: var(--red-dark);
}

/* ===== Section ===== */
.section {
  padding: 40px 0;
}

.section-title {
  text-align: center;
  margin-bottom: 30px;
}

.section-title h2 {
  font-size: 26px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.section-title .sub {
  font-size: 13px;
  color: var(--text-light);
  margin-top: 4px;
}

.section-title .sub a {
  color: var(--red);
  font-weight: 700;
  text-decoration: underline;
}

/* ===== Brands Strip ===== */
.brands-strip {
  background: var(--gray);
  padding: 28px 0;
  text-align: center;
}

.brands-strip .label {
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 18px;
}

.brands-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 12px;
  max-width: 1000px;
  margin: 0 auto;
}

.brand-tile {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 3px;
  padding: 16px 8px;
  font-weight: 700;
  font-size: 13px;
  transition: all 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 60px;
  text-align: center;
}

.brand-tile:hover {
  border-color: var(--red);
  color: var(--red);
}

/* ===== Product Grid ===== */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 24px;
}

.product-card {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 3px;
  overflow: hidden;
  transition: all 0.18s;
  display: flex;
  flex-direction: column;
}

.product-card:hover {
  box-shadow: 0 6px 20px rgba(0,0,0,0.12);
  border-color: #ccc;
}

.product-card .img-wrap {
  position: relative;
  background: #fafafa;
  aspect-ratio: 1 / 1;
  overflow: hidden;
}

.product-card .img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 12px;
}

.only-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--red);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 4px 8px;
  border-radius: 2px;
}

.product-card .info {
  padding: 14px;
  display: flex;
  flex-direction: column;
  flex: 1;
}

.product-card .title {
  font-size: 14px;
  font-weight: 600;
  line-height: 1.35;
  margin-bottom: 10px;
  color: var(--text);
  min-height: 38px;
}

.product-card .title:hover {
  color: var(--red);
}

.price-row {
  margin-top: auto;
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.price-now {
  font-size: 22px;
  font-weight: 900;
  color: var(--red);
}

.price-was {
  font-size: 14px;
  color: var(--text-light);
  text-decoration: line-through;
}

.badge-save {
  background: var(--green);
  color: var(--white);
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 2px;
  text-transform: uppercase;
}

/* ===== Instagram Section ===== */
.ig-section {
  background: linear-gradient(135deg, #efefef 0%, #d8d8d8 100%);
  color: var(--black);
  padding: 40px 0;
  text-align: center;
}

.ig-section h2 {
  font-size: 22px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 24px;
}

.ig-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 4px;
}

.ig-tile {
  position: relative;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  background: #e0e0e0;
}

.ig-tile img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.3s;
}

.ig-tile:hover img {
  transform: scale(1.06);
}

.ig-tile .overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.2s;
  color: var(--white);
  font-size: 12px;
  padding: 10px;
  text-align: center;
}

.ig-tile:hover .overlay {
  opacity: 1;
}

/* ===== Footer ===== */
.site-footer {
  background: linear-gradient(135deg, #efefef 0%, #d8d8d8 100%);
  color: #555;
  padding: 40px 0 0;
}

.footer-cols {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 30px;
  padding-bottom: 30px;
}

.footer-col h4 {
  color: var(--black);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 14px;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 8px;
  font-size: 13px;
}

.footer-col a:hover {
  color: var(--red);
}

.newsletter input {
  width: 100%;
  padding: 10px;
  background: #fff;
  border: 1px solid var(--gray-border);
  color: var(--black);
  font-size: 13px;
  margin-bottom: 8px;
  border-radius: 2px;
}

.newsletter button {
  width: 100%;
  padding: 10px;
  background: var(--red);
  color: var(--white);
  border: none;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 2px;
}

.newsletter button:hover {
  background: var(--red-dark);
}

/* PWA 推送通知开启按钮（页脚订阅区） */
.push-toggle {
  width: 100%;
  margin-top: 10px;
  padding: 9px 12px;
  background: transparent;
  color: var(--black);
  border: 1.5px solid var(--black);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: all .15s;
}
.push-toggle:hover {
  border-color: var(--red);
  color: var(--red);
}
.push-toggle.is-on {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}
.push-toggle.is-on:hover {
  background: var(--red-dark);
  border-color: var(--red-dark);
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid var(--gray-border);
  padding: 18px 0;
  text-align: center;
  font-size: 12px;
  color: #666;
}

/* ===== Page Banner ===== */
.page-banner {
  background: var(--gray);
  padding: 24px 0;
  text-align: center;
  border-bottom: 1px solid var(--gray-border);
}

.page-banner h1 {
  font-size: 28px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ===== Brands List Page ===== */
.brands-list .brand-group {
  margin-bottom: 30px;
}

.brands-list .brand-group h3 {
  font-size: 18px;
  font-weight: 800;
  border-bottom: 2px solid var(--red);
  padding-bottom: 6px;
  margin-bottom: 12px;
  display: inline-block;
}

.brands-list .brand-group ul {
  list-style: none;
  columns: 3;
  column-gap: 24px;
}

.brands-list .brand-group li {
  margin-bottom: 6px;
  font-size: 14px;
}

.brands-list .brand-group a:hover {
  color: var(--red);
}

/* ===== Product Detail ===== */
.product-detail {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  padding: 30px 0;
}

.product-gallery .main-img {
  background: #fafafa;
  border: 1px solid var(--gray-border);
  border-radius: 3px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
}

.product-gallery .main-img img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 30px;
}

.product-info h1 {
  font-size: 24px;
  font-weight: 800;
  margin-bottom: 6px;
  line-height: 1.3;
}

.product-info .brand-link {
  color: var(--red);
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 16px;
  display: inline-block;
}

.product-info .meta {
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 14px;
}

.product-info .meta span {
  margin-right: 14px;
}

.detail-price-row {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}

.detail-price-row .now {
  font-size: 32px;
  font-weight: 900;
  color: var(--red);
}

.detail-price-row .was {
  font-size: 18px;
  color: var(--text-light);
  text-decoration: line-through;
}

.detail-price-row .save {
  background: var(--green);
  color: var(--white);
  font-size: 12px;
  font-weight: 700;
  padding: 4px 8px;
  border-radius: 2px;
  text-transform: uppercase;
}

.product-info .description {
  font-size: 14px;
  color: #555;
  line-height: 1.65;
  margin-bottom: 20px;
  padding: 16px;
  background: var(--gray);
  border-radius: 3px;
}

.add-cart-row {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 16px;
}

.qty-select {
  display: flex;
  align-items: center;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  overflow: hidden;
}

.qty-select button {
  width: 38px;
  height: 44px;
  background: var(--white);
  border: none;
  font-size: 18px;
  cursor: pointer;
  font-weight: 700;
}

.qty-select button:hover {
  background: var(--gray);
}

.qty-select input {
  width: 50px;
  height: 44px;
  border: none;
  border-left: 1px solid var(--gray-border);
  border-right: 1px solid var(--gray-border);
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  outline: none;
}

.btn-cart {
  flex: 1;
  background: var(--red);
  color: var(--white);
  border: none;
  padding: 0 30px;
  height: 44px;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 2px;
  transition: background 0.15s;
}

.btn-cart:hover {
  background: var(--red-dark);
}

.stock-note {
  font-size: 13px;
  color: var(--green);
  font-weight: 700;
  margin-bottom: 20px;
}

.stock-note.low {
  color: #d97706;
}

/* Related products */
.related {
  padding: 30px 0 50px;
}

.related h2 {
  font-size: 20px;
  font-weight: 800;
  text-transform: uppercase;
  margin-bottom: 20px;
}

/* ===== Cart Page ===== */
.cart-page {
  padding: 30px 0;
}

.cart-page h1 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 20px;
}

.cart-table {
  width: 100%;
  border-collapse: collapse;
}

.cart-table th {
  text-align: left;
  padding: 12px;
  border-bottom: 2px solid var(--black);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.cart-table td {
  padding: 16px 12px;
  border-bottom: 1px solid var(--gray-border);
  vertical-align: middle;
}

.cart-table .cart-product {
  display: flex;
  align-items: center;
  gap: 14px;
}

.cart-table .cart-product img {
  width: 70px;
  height: 70px;
  object-fit: contain;
  background: #fafafa;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
}

.cart-table .cart-product .name {
  font-weight: 600;
  font-size: 14px;
}

.cart-table .cart-product .name:hover {
  color: var(--red);
}

.cart-summary {
  margin-top: 20px;
  display: flex;
  justify-content: flex-end;
}

.summary-box {
  width: 320px;
  background: var(--gray);
  padding: 22px;
  border-radius: 3px;
}

.summary-box .row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 10px;
  font-size: 14px;
}

.summary-box .total {
  border-top: 1px solid var(--gray-border);
  padding-top: 12px;
  margin-top: 12px;
  font-size: 20px;
  font-weight: 800;
}

.summary-box .total .price {
  color: var(--red);
}

.summary-box .btn-cart {
  width: 100%;
  margin-top: 14px;
}

.empty-cart {
  text-align: center;
  padding: 60px 20px;
  color: var(--text-light);
}

.empty-cart a {
  color: var(--red);
  font-weight: 700;
}

.remove-btn {
  background: none;
  border: none;
  color: var(--text-light);
  cursor: pointer;
  font-size: 18px;
}

.remove-btn:hover {
  color: var(--red);
}

/* ===== Toast ===== */
.toast {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--black);
  color: var(--white);
  padding: 14px 22px;
  border-radius: 3px;
  font-size: 14px;
  font-weight: 600;
  box-shadow: 0 6px 24px rgba(0,0,0,0.3);
  z-index: 1000;
  transform: translateY(100px);
  opacity: 0;
  transition: all 0.25s;
}

.toast.show {
  transform: translateY(0);
  opacity: 1;
}

.toast.success {
  background: var(--green);
}

.toast.error {
  background: var(--red);
}

/* ===== 客户评价区 ===== */
.review-section {
  border-top: 1px solid var(--gray-border);
  padding-top: 36px;
}

.review-section-title {
  font-size: 20px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 20px;
}

.review-summary {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 16px 20px;
  background: #fafafa;
  border: 1px solid var(--gray-border);
  border-radius: 4px;
  margin-bottom: 24px;
}

.review-avg {
  display: flex;
  align-items: center;
  gap: 10px;
}

.review-avg-num {
  font-size: 36px;
  font-weight: 900;
  color: var(--black);
  line-height: 1;
}

.review-avg-stars .star {
  font-size: 20px;
  color: #ddd;
}

.review-avg-stars .star.active {
  color: #f5a623;
}

.review-avg-count {
  font-size: 13px;
  color: var(--text-light);
}

.review-list {
  margin-bottom: 28px;
}

.review-empty {
  text-align: center;
  color: var(--text-light);
  padding: 30px 0;
  font-size: 14px;
}

.review-item {
  padding: 16px 0;
  border-bottom: 1px solid var(--gray-border);
}

.review-item:last-child {
  border-bottom: none;
}

.review-item-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.review-author {
  font-weight: 700;
  font-size: 14px;
}

.review-stars .star {
  font-size: 15px;
  color: #ddd;
}

.review-stars .star.active {
  color: #f5a623;
}

.review-date {
  font-size: 12px;
  color: var(--text-light);
  margin-left: auto;
}

.review-content {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text);
  margin: 0;
}

/* 评价表单 */
.review-form-wrap {
  background: #fafafa;
  border: 1px solid var(--gray-border);
  border-radius: 4px;
  padding: 22px;
}

.review-form-wrap h3 {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 16px;
  text-transform: uppercase;
}

.review-rating-input {
  margin-bottom: 14px;
}

.review-rating-input label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 6px;
}

/* Star rating radio */
.star-rating {
  display: inline-flex;
  flex-direction: row-reverse;
  gap: 2px;
}

.star-rating input[type="radio"] {
  display: none;
}

.star-rating label {
  font-size: 28px;
  color: #ddd;
  cursor: pointer;
  transition: color 0.15s;
  line-height: 1;
}

.star-rating label:hover,
.star-rating label:hover ~ label,
.star-rating input:checked ~ label {
  color: #f5a623;
}

.review-textarea {
  margin-bottom: 14px;
}

.review-textarea label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 6px;
}

.review-textarea textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  resize: vertical;
}

.review-textarea textarea:focus {
  border-color: var(--black);
}

.btn-review-submit {
  background: var(--red);
  color: var(--white);
  border: none;
  padding: 10px 24px;
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  border-radius: 2px;
  transition: background 0.15s;
}

.btn-review-submit:hover {
  background: var(--red-dark);
}

.review-msg {
  margin-top: 10px;
  font-size: 13px;
  padding: 0;
}

.review-msg.success {
  color: #2e7d32;
}

.review-msg.error {
  color: var(--red);
}

.review-hint {
  font-size: 14px;
  color: var(--text-light);
  padding: 12px 0;
}

.review-hint a {
  color: var(--red);
  font-weight: 700;
}

@media (max-width: 768px) {
  .review-summary {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  .review-avg-num {
    font-size: 28px;
  }
  .star-rating label {
    font-size: 24px;
  }
}

/* ===== Responsive ===== */
@media (max-width: 768px) {
  .header-main {
    flex-wrap: wrap;
  }
  .search-box {
    order: 3;
    max-width: 100%;
    flex: 1 1 100%;
  }
  .logo {
    order: -2;
    flex-basis: 100%;
    text-align: center;
  }
  .lang-action {
    order: -1;
  }
  .header-actions {
    gap: 10px;
    order: 0;
  }
  .header-action {
    font-size: 10px;
  }
  .register-action {
    font-size: 10px;
  }
  .header-action svg {
    width: 22px;
    height: 22px;
  }
  .hero-announce {
    font-size: 13px;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
    text-align: center;
    word-spacing: 2px;
    line-height: 1.8;
  }
  .hero h1 {
    font-size: 24px;
    text-align: center;
    word-spacing: 2px;
    line-height: 1.6;
    letter-spacing: 0.5px;
  }
  .main-nav .container {
    overflow-x: auto;
    justify-content: flex-start;
  }
  .main-nav a {
    padding: 12px 14px;
    font-size: 12px;
    white-space: nowrap;
  }
  .product-detail {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .brands-list .brand-group ul {
    columns: 1;
  }
  .cart-table th:nth-child(3),
  .cart-table td:nth-child(3) {
    display: none;
  }
  .summary-box {
    width: 100%;
  }
}

/* ===== Admin Panel ===== */
.admin-login {
  max-width: 380px;
  margin: 60px auto;
  padding: 30px;
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 4px;
}

.admin-login h1 {
  text-align: center;
  font-size: 22px;
  margin-bottom: 24px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.admin-login .field {
  margin-bottom: 16px;
}

.admin-login label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 6px;
  color: var(--text-light);
}

.admin-login input {
  width: 100%;
  padding: 11px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  outline: none;
}

.admin-login input:focus {
  border-color: var(--black);
}

.admin-login button {
  width: 100%;
  padding: 12px;
  background: var(--black);
  color: var(--white);
  border: none;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 2px;
}

.admin-login button:hover {
  background: var(--red);
}

.admin-login .error {
  color: var(--red);
  font-size: 13px;
  text-align: center;
  margin-bottom: 14px;
}

.admin-login .hint {
  text-align: center;
  font-size: 12px;
  color: var(--text-light);
  margin-top: 16px;
  padding: 10px;
  background: var(--gray);
  border-radius: 2px;
}

/* Admin layout */
.admin-layout {
  display: grid;
  grid-template-columns: 230px 1fr;
  min-height: 100vh;
}

.admin-sidebar {
  background: var(--black);
  color: var(--white);
  padding: 20px 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.admin-sidebar .brand {
  padding: 0 20px 20px;
  font-size: 20px;
  font-weight: 900;
  border-bottom: 1px solid #333;
  margin-bottom: 12px;
}

.admin-sidebar .brand small {
  display: block;
  font-size: 10px;
  color: var(--red);
  letter-spacing: 1px;
  font-weight: 400;
}

.admin-sidebar a {
  display: block;
  padding: 12px 20px;
  color: #bbb;
  font-size: 14px;
  font-weight: 600;
  border-left: 3px solid transparent;
}

.admin-sidebar a:hover {
  background: #1a1a1a;
  color: var(--white);
}

.admin-sidebar a.active {
  background: #1a1a1a;
  color: var(--white);
  border-left-color: var(--red);
}

.admin-sidebar .logout {
  margin-top: 20px;
  border-top: 1px solid #333;
  padding-top: 12px;
}

.admin-content {
  padding: 24px 28px;
  background: #f0f0f0;
}

.admin-content h1 {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

/* Stat cards */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 18px;
  margin-bottom: 30px;
}

.stat-card {
  background: var(--white);
  padding: 20px;
  border-radius: 4px;
  border: 1px solid var(--gray-border);
  box-shadow: 0 1px 3px rgba(0,0,0,0.04);
}

.stat-card .label {
  font-size: 12px;
  color: var(--text-light);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 700;
}

.stat-card .value {
  font-size: 32px;
  font-weight: 900;
  color: var(--black);
  margin-top: 6px;
}

.stat-card .value.red { color: var(--red); }
.stat-card .value.green { color: var(--green); }

.revenue-grid {
  grid-template-columns: repeat(3, 1fr);
}

.revenue-card {
  background: linear-gradient(135deg, #fff8f8, #fff);
  border-left: 3px solid var(--red);
}

.revenue-value {
  color: var(--red) !important;
  font-size: 28px !important;
}

@media (max-width: 700px) {
  .revenue-grid {
    grid-template-columns: 1fr;
  }
}

/* Admin table */
.admin-panel {
  background: var(--white);
  border-radius: 4px;
  border: 1px solid var(--gray-border);
  overflow: hidden;
}

.admin-panel-head {
  padding: 16px 20px;
  border-bottom: 1px solid var(--gray-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-panel-head h2 {
  font-size: 16px;
  font-weight: 800;
}

.btn-add {
  background: var(--red);
  color: var(--white);
  border: none;
  padding: 8px 16px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  cursor: pointer;
  border-radius: 2px;
}

.btn-add:hover {
  background: var(--red-dark);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
}

.admin-table th {
  text-align: left;
  padding: 12px 16px;
  background: var(--gray);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-light);
  font-weight: 700;
}

.admin-table td {
  padding: 12px 16px;
  border-top: 1px solid var(--gray-border);
  font-size: 13px;
  vertical-align: middle;
}

.admin-table tr:hover {
  background: #fafafa;
}

.admin-table img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
}

.admin-table .row-actions {
  display: flex;
  gap: 6px;
}

.btn-icon {
  background: none;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  padding: 5px 8px;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-light);
}

.btn-icon:hover {
  border-color: var(--black);
  color: var(--black);
}

.btn-icon.danger:hover {
  border-color: var(--red);
  color: var(--red);
}

/* Modal/form */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 200;
  padding: 20px;
}

.modal-overlay.show {
  display: flex;
}

.modal {
  background: var(--white);
  border-radius: 4px;
  width: 100%;
  max-width: 560px;
  max-height: 90vh;
  overflow-y: auto;
}

.modal-head {
  padding: 16px 20px;
  border-bottom: 1px solid var(--gray-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-head h2 {
  font-size: 16px;
  font-weight: 800;
}

.modal-close {
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: var(--text-light);
}

.modal-body {
  padding: 20px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-field {
  margin-bottom: 0;
}

.form-field.full {
  grid-column: 1 / -1;
}

.form-field label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 5px;
}

.form-field input,
.form-field select,
.form-field textarea {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  outline: none;
  font-family: inherit;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
  border-color: var(--black);
}

.form-field textarea {
  min-height: 80px;
  resize: vertical;
}

.form-field .checkbox {
  display: flex;
  align-items: center;
  gap: 6px;
  text-transform: none;
  font-weight: 400;
}

.form-field .checkbox input {
  width: auto;
}

.modal-foot {
  padding: 14px 20px;
  border-top: 1px solid var(--gray-border);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}

/* ===== 产品表单增强：必填标记 / 图片预览 / 预设图库 / 校验提示 ===== */
.form-grid .req {
  color: var(--red);
  margin-left: 2px;
}

.img-preview {
  margin-top: 8px;
  width: 100%;
  height: 140px;
  border: 1px dashed var(--gray-border);
  border-radius: 2px;
  background: #fafafa;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.img-preview img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.img-preview .ph {
  color: var(--text-light);
  font-size: 13px;
}

/* 上传区 + 拖拽 */
.upload-zone {
  border: 2px dashed var(--gray-border);
  border-radius: 2px;
  background: #fafafa;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
  text-align: center;
}

.upload-zone:hover,
.upload-zone.drag-over {
  border-color: var(--red);
  background: #fff5f5;
}

.upload-zone.drag-over {
  background: #fff0f0;
  border-style: solid;
}

.upload-zone-inner {
  padding: 22px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--text-light);
}

.upload-zone-inner svg {
  color: var(--text-light);
  margin-bottom: 4px;
}

.upload-zone-inner span {
  font-size: 14px;
  font-weight: 600;
  color: var(--text);
}

.upload-zone-inner small {
  font-size: 11px;
  color: var(--text-light);
}

.upload-zone:hover .upload-zone-inner svg,
.upload-zone.drag-over .upload-zone-inner svg {
  color: var(--red);
}

.upload-progress {
  margin-top: 8px;
  padding: 8px 12px;
  border-radius: 2px;
  font-size: 13px;
  font-weight: 600;
}

.upload-progress.progress {
  background: #eef5ff;
  border: 1px solid #bcd5ff;
  color: #1a5fb4;
}

.upload-progress.success {
  background: #e3f2e3;
  border: 1px solid #a5d6a7;
  color: #2e7d32;
}

.upload-progress.error {
  background: #fff5f5;
  border: 1px solid #ffd5d5;
  color: var(--red);
}

.preset-gallery {
  display: grid;
  grid-template-columns: repeat(8, 1fr);
  gap: 6px;
  margin-top: 4px;
}

.preset-thumb {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  cursor: pointer;
  transition: border-color 0.15s, transform 0.15s;
}

.preset-thumb:hover {
  border-color: var(--red);
  transform: scale(1.05);
}

@media (max-width: 700px) {
  .preset-gallery {
    grid-template-columns: repeat(4, 1fr);
  }
}

.form-msg {
  grid-column: 1 / -1;
  font-size: 13px;
  padding: 8px 12px;
  border-radius: 2px;
  display: none;
  min-height: 0;
}

.form-msg.info {
  display: block;
  background: #eef5ff;
  border: 1px solid #bcd5ff;
  color: #1a5fb4;
}

.form-msg.error {
  display: block;
  background: #fff5f5;
  border: 1px solid #ffd5d5;
  color: var(--red);
}

.btn-secondary {
  background: var(--gray);
  color: var(--text);
  border: 1px solid var(--gray-border);
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border-radius: 2px;
}

.btn-primary {
  background: var(--red);
  color: var(--white);
  border: none;
  padding: 9px 18px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  border-radius: 2px;
}

.btn-primary:hover {
  background: var(--red-dark);
}

@media (max-width: 900px) {
  .admin-layout {
    grid-template-columns: 1fr;
  }
  .admin-sidebar {
    height: auto;
    position: relative;
  }
  .admin-sidebar a {
    display: inline-block;
    padding: 10px 14px;
  }
  .form-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Member Auth Pages ===== */
.auth-page {
  max-width: 420px;
  margin: 40px auto;
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 4px;
  padding: 32px;
}

.auth-page h1 {
  font-size: 24px;
  font-weight: 800;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 8px;
}

.auth-page .auth-sub {
  text-align: center;
  font-size: 13px;
  color: var(--text-light);
  margin-bottom: 22px;
}

.auth-page .field {
  margin-bottom: 16px;
}

.auth-page label {
  display: block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 6px;
  color: var(--text-light);
}

.auth-page label .req {
  color: var(--red);
}

.auth-page input {
  width: 100%;
  padding: 11px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  outline: none;
  font-family: inherit;
}

.auth-page input:focus {
  border-color: var(--black);
}

.auth-page button {
  width: 100%;
  padding: 12px;
  background: var(--red);
  color: var(--white);
  border: none;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  cursor: pointer;
  border-radius: 2px;
  font-size: 14px;
  margin-top: 6px;
}

.auth-page button:hover {
  background: var(--red-dark);
}

.auth-page .error {
  color: var(--red);
  font-size: 13px;
  text-align: center;
  margin-bottom: 14px;
  background: #fff5f5;
  border: 1px solid #ffd5d5;
  padding: 10px;
  border-radius: 2px;
}

.auth-page .auth-foot {
  text-align: center;
  font-size: 13px;
  color: var(--text-light);
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--gray-border);
}

.auth-page .auth-foot a {
  color: var(--red);
  font-weight: 700;
}

/* ===== Account Page ===== */
.account-page {
  padding: 30px 0 60px;
}

.account-page .acc-status {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 10px;
  font-weight: 700;
  display: inline-block;
}
.account-page .acc-paid { background:#fff3cd; color:#856404; }
.account-page .acc-shipped { background:#cce5ff; color:#004085; }
.account-page .acc-completed { background:#e3f2e3; color:#2e7d32; }
.account-page .acc-cancelled { background:#fce4e4; color:#c62828; }

.account-page h1 {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 4px;
}

.account-page .welcome {
  font-size: 14px;
  color: var(--text-light);
  margin-bottom: 24px;
}

.account-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 24px;
  align-items: start;
}

.account-card {
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 4px;
  padding: 22px;
}

.account-card h2 {
  font-size: 15px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
  border-bottom: 2px solid var(--red);
  padding-bottom: 8px;
  display: inline-block;
}

.account-card .field {
  margin-bottom: 14px;
}

.account-card label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 4px;
}

.account-card .field input {
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  outline: none;
}

.account-side {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.account-nav a {
  display: block;
  padding: 12px 16px;
  background: var(--white);
  border: 1px solid var(--gray-border);
  border-radius: 3px;
  font-size: 14px;
  font-weight: 600;
}

.account-nav a:hover {
  border-color: var(--red);
  color: var(--red);
}

.account-nav a.logout {
  color: var(--red);
}

.empty-orders {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-light);
}

.empty-orders a {
  color: var(--red);
  font-weight: 700;
}

@media (max-width: 768px) {
  .account-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== 在线客服组件 ===== */
.chat-widget {
  position: fixed;
  bottom: 22px;
  right: 22px;
  z-index: 999;
}

.chat-toggle {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  border: none;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0,0,0,0.28);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s, background 0.2s;
  position: relative;
}

.chat-toggle:hover {
  background: var(--red-dark);
  transform: scale(1.06);
}

.chat-toggle svg {
  width: 27px;
  height: 27px;
}

.chat-toggle .chat-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: #000;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  border-radius: 50%;
  min-width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 2px solid #fff;
}

.chat-panel {
  position: absolute;
  bottom: 72px;
  right: 0;
  width: 340px;
  max-width: calc(100vw - 44px);
  height: 460px;
  max-height: calc(100vh - 130px);
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--gray-border);
}

.chat-head {
  background: var(--black);
  color: #fff;
  padding: 14px 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.chat-head strong {
  font-size: 15px;
}

.chat-status {
  display: block;
  font-size: 11px;
  color: #6ec56e;
  margin-top: 2px;
}

.chat-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
  padding: 0;
}

.chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  background: #f7f7f7;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.chat-msg {
  max-width: 78%;
  padding: 10px 13px;
  border-radius: 14px;
  font-size: 13.5px;
  line-height: 1.45;
  word-break: break-word;
}

.chat-msg.agent {
  background: #fff;
  border: 1px solid var(--gray-border);
  border-bottom-left-radius: 4px;
  align-self: flex-start;
}

.chat-msg.guest {
  background: var(--red);
  color: #fff;
  border-bottom-right-radius: 4px;
  align-self: flex-end;
}

.chat-msg .time {
  display: block;
  font-size: 10px;
  color: #999;
  margin-top: 3px;
}

.chat-msg.guest .time {
  color: rgba(255,255,255,0.8);
}

.chat-form {
  border-top: 1px solid var(--gray-border);
  padding: 12px;
  background: #fff;
}

.chat-intro input {
  display: block;
  width: 100%;
  padding: 9px 11px;
  border: 1px solid var(--gray-border);
  border-radius: 3px;
  font-size: 13px;
  margin-bottom: 8px;
  outline: none;
  font-family: inherit;
}

.chat-intro input:focus {
  border-color: var(--black);
}

.chat-intro .btn-primary {
  width: 100%;
  padding: 10px;
  background: var(--red);
  color: #fff;
  border: none;
  border-radius: 3px;
  font-weight: 700;
  cursor: pointer;
  font-size: 13px;
}

.chat-input-row {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

.chat-input-row textarea {
  flex: 1;
  border: 1px solid var(--gray-border);
  border-radius: 14px;
  padding: 9px 13px;
  font-size: 13.5px;
  resize: none;
  outline: none;
  font-family: inherit;
  max-height: 80px;
}

.chat-input-row textarea:focus {
  border-color: var(--black);
}

.chat-input-row button {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--red);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.chat-input-row button:hover {
  background: var(--red-dark);
}

.chat-input-row svg {
  width: 18px;
  height: 18px;
}

.chat-typing {
  font-size: 12px;
  color: #999;
  align-self: flex-start;
  padding: 4px 8px;
}

@media (max-width: 480px) {
  .chat-panel {
    right: -22px;
    width: calc(100vw);
  }
  .chat-widget {
    bottom: 16px;
    right: 16px;
  }
  .hero-announce {
    font-size: 12px;
    line-height: 2;
  }
  .hero h1 {
    font-size: 20px;
    line-height: 1.7;
  }
}

/* ===== 语言切换器（头部图标区，登录前） ===== */
.lang-action {
  cursor: default;
}

.lang-mini {
  display: inline-flex;
  border: 1px solid var(--gray-border);
  border-radius: 10px;
  overflow: hidden;
  margin-top: 3px;
  background: #fff;
}

.lang-mini a {
  padding: 1px 7px;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-light);
  text-decoration: none;
  line-height: 1.5;
  transition: background 0.15s ease, color 0.15s ease;
}

.lang-mini a.active {
  background: var(--black);
  color: #fff;
}

.lang-mini a:hover:not(.active) {
  background: #f0f0f0;
  color: var(--black);
}


/* ========== CMS 内容页 & 订单查询 ========== */
.static-page {
  max-width: 860px;
  padding: 40px 20px 60px;
}

.static-page .page-head {
  border-bottom: 2px solid var(--black);
  padding-bottom: 14px;
  margin-bottom: 26px;
}

.static-page .page-head h1 {
  font-size: 30px;
  margin-bottom: 6px;
}

.static-page .page-sub {
  color: var(--text-light);
  font-size: 14px;
  margin: 0;
}

.static-page .page-updated {
  font-size: 12px;
  color: var(--text-light);
}

.static-page .page-content {
  font-size: 15px;
  line-height: 1.9;
}

.static-page .page-content h3 {
  font-size: 18px;
  margin: 26px 0 10px;
}

.static-page .page-content p,
.static-page .page-content ul,
.static-page .page-content ol {
  margin-bottom: 12px;
}

.static-page .page-content ul,
.static-page .page-content ol {
  padding-left: 22px;
}

.static-page .page-content li {
  margin-bottom: 6px;
}

.static-page .page-content a {
  color: var(--red);
  font-weight: 700;
}

/* 订单查询表单 */
.lookup-form {
  max-width: 460px;
  background: #fafafa;
  border: 1px solid var(--gray-border);
  border-radius: 4px;
  padding: 24px;
  margin-bottom: 30px;
}

.lookup-form .form-group {
  margin-bottom: 14px;
}

.lookup-form label {
  display: block;
  font-size: 13px;
  font-weight: 700;
  margin-bottom: 6px;
}

.lookup-form input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--gray-border);
  border-radius: 2px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
}

.lookup-form input:focus {
  border-color: var(--black);
}

.lookup-error {
  max-width: 460px;
  background: #fce4e4;
  border: 1px solid #f5c6c6;
  color: var(--red);
  padding: 10px 14px;
  border-radius: 2px;
  font-size: 13px;
  margin-bottom: 16px;
}

/* 查询结果 */
.lookup-result h2 {
  font-size: 20px;
  margin-bottom: 14px;
}

.lookup-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.lookup-table th {
  width: 120px;
  text-align: left;
  vertical-align: top;
  padding: 10px 12px;
  background: #fafafa;
  border: 1px solid var(--gray-border);
  color: var(--text-light);
  font-weight: 700;
  white-space: nowrap;
}

.lookup-table td {
  padding: 10px 12px;
  border: 1px solid var(--gray-border);
}

.lookup-ship-time {
  font-size: 12px;
  color: var(--text-light);
}

.lookup-note {
  margin-top: 14px;
}

.lookup-note a {
  color: var(--red);
  font-weight: 700;
}

/* 全局状态标签（订单查询页复用） */
.status-tag {
  display: inline-block;
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 10px;
  font-weight: 700;
  white-space: nowrap;
}

.status-tag.pending { background: #e3f0ff; color: #0d47a1; }
.status-tag.paid { background: #fff3cd; color: #856404; }
.status-tag.shipped { background: #cce5ff; color: #004085; }
.status-tag.completed { background: #e3f2e3; color: #2e7d32; }
.status-tag.cancelled { background: #fce4e4; color: #c62828; }

@media (max-width: 640px) {
  .lookup-table th { width: 88px; }
}


/* ========== APP下载悬浮按钮 ========== */
.pwa-fab {
  position: fixed;
  right: 22px;
  bottom: 162px;
  z-index: 900;
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, #e89b2e, #d4791c);
  color: #fff;
  border: none;
  border-radius: 50%;
  padding: 0;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(212, 121, 28, 0.45);
  transition: transform 0.15s, box-shadow 0.15s;
}

.pwa-fab:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(212, 121, 28, 0.55);
}

.pwa-fab svg {
  width: 26px;
  height: 26px;
}

.pwa-fab-text {
  display: none;
  position: absolute;
  right: 68px;
  top: 50%;
  transform: translateY(-50%);
  background: #222;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 4px;
  white-space: nowrap;
}

.pwa-fab-text::after {
  content: '';
  position: absolute;
  right: -4px;
  top: 50%;
  transform: translateY(-50%);
  border: 4px solid transparent;
  border-left-color: #222;
}

.pwa-fab:hover .pwa-fab-text {
  display: block;
}

/* ========== 微信客服悬浮按钮 & 弹窗 ========== */
.wechat-fab {
  position: fixed;
  right: 22px;
  bottom: 92px; /* 在线客服按钮（58px + bottom 22px）正上方 */
  z-index: 900;
  width: 58px;
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #07C160;
  color: #fff;
  border: none;
  border-radius: 50%;
  padding: 0;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(7, 193, 96, 0.45);
  transition: transform 0.15s, box-shadow 0.15s;
}

.wechat-fab:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(7, 193, 96, 0.55);
}

.wechat-fab svg {
  width: 30px;
  height: 30px;
  fill: currentColor;
}

/* 悬停时在按钮左侧显示文字标签 */
.wechat-fab-text {
  display: none;
  position: absolute;
  right: 68px;
  top: 50%;
  transform: translateY(-50%);
  background: #222;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 10px;
  border-radius: 4px;
  white-space: nowrap;
}

.wechat-fab-text::after {
  content: '';
  position: absolute;
  right: -4px;
  top: 50%;
  transform: translateY(-50%);
  border: 4px solid transparent;
  border-left-color: #222;
}

.wechat-fab:hover .wechat-fab-text {
  display: block;
}

/* 弹窗 */
.wechat-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wechat-modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
}

.wechat-modal-card {
  position: relative;
  background: #fff;
  border-radius: 10px;
  width: min(360px, calc(100vw - 40px));
  padding: 24px 22px 20px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
  text-align: center;
}

.wechat-modal-close {
  position: absolute;
  top: 8px;
  right: 12px;
  border: none;
  background: none;
  font-size: 24px;
  line-height: 1;
  color: #999;
  cursor: pointer;
}

.wechat-modal-close:hover { color: #333; }

.wechat-modal-head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 12px;
}

.wechat-modal-head svg { width: 30px; height: 30px; }
.wechat-modal-head strong { font-size: 18px; display: block; text-align: left; }

.wechat-online {
  font-size: 11px;
  color: #07C160;
  font-weight: 700;
}

.wechat-note {
  font-size: 13px;
  color: #666;
  line-height: 1.7;
  margin: 0 0 14px;
}

.wechat-qr img {
  width: 180px;
  height: 180px;
  object-fit: contain;
  border: 1px solid var(--gray-border, #e5e5e5);
  border-radius: 6px;
  background: #fafafa;
}

.wechat-qr-tip {
  font-size: 12px;
  color: #999;
  margin: 6px 0 12px;
}

.wechat-id-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.wechat-id-label { font-size: 13px; color: #888; }

.wechat-id {
  font-family: Consolas, Monaco, monospace;
  font-size: 15px;
  font-weight: 700;
  background: #f2f7f3;
  border: 1px dashed #07C160;
  color: #0a7d40;
  border-radius: 4px;
  padding: 5px 12px;
  user-select: all;
}

.wechat-copy {
  font-size: 13px;
  padding: 7px 16px;
  background: #07C160;
  border: none;
  color: #fff;
  border-radius: 4px;
  font-weight: 700;
  cursor: pointer;
}

.wechat-copy:hover { background: #06ad56; }
.wechat-copy:disabled { background: #9fdcb8; cursor: default; }

.wechat-steps {
  text-align: left;
  font-size: 12px;
  color: #999;
  padding-left: 20px;
  margin: 0;
  line-height: 1.9;
  border-top: 1px dashed var(--gray-border, #e5e5e5);
  padding-top: 12px;
}

@media (max-width: 640px) {
  .pwa-fab { right: 16px; bottom: 152px; }
  .pwa-fab-text { display: none; }
  .wechat-fab { right: 16px; bottom: 86px; } /* 在线客服（16px+58px）正上方 */
  .wechat-fab-text { display: none; }
}


/* 微信客服弹窗：进入对话按钮 & 打开微信 */
.wechat-enter-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: #07C160;
  color: #fff;
  text-decoration: none;
  font-size: 15px;
  font-weight: 700;
  border-radius: 6px;
  padding: 12px 16px;
  margin-bottom: 14px;
  transition: background 0.15s;
}

.wechat-enter-btn:hover { background: #06ad56; }
.wechat-enter-btn:visited { color: #fff; }
.wechat-enter-icon { width: 20px; height: 20px; fill: currentColor; }

.wechat-open {
  background: #07C160;
}

.wechat-open:hover { background: #06ad56; }

.wechat-open-tip {
  font-size: 12px;
  color: #07C160;
  background: #f0faf4;
  border: 1px solid #bfe8cf;
  border-radius: 4px;
  padding: 7px 10px;
  margin: 0 0 12px;
  line-height: 1.6;
}

/* ===== PWA Install Banner ===== */
.pwa-install-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  border-top: 1px solid var(--gray-border);
  box-shadow: 0 -4px 20px rgba(0,0,0,0.12);
  z-index: 9999;
  transform: translateY(0);
  transition: transform 0.3s ease, opacity 0.3s ease;
  opacity: 1;
}

.pwa-install-banner.pwa-banner-hidden {
  transform: translateY(100%);
  opacity: 0;
  pointer-events: none;
}

.pwa-banner-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  max-width: 600px;
  margin: 0 auto;
}

.pwa-banner-icon {
  flex-shrink: 0;
}

.pwa-banner-icon img {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  object-fit: cover;
}

.pwa-banner-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.pwa-banner-text strong {
  font-size: 14px;
  font-weight: 700;
  color: var(--black);
}

.pwa-banner-text span {
  font-size: 12px;
  color: var(--text-light);
  line-height: 1.4;
}

.pwa-btn-install {
  flex-shrink: 0;
  background: var(--red);
  color: #fff;
  border: none;
  padding: 8px 18px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.15s;
}

.pwa-btn-install:hover {
  background: var(--red-dark);
}

.pwa-btn-close {
  flex-shrink: 0;
  background: none;
  border: none;
  font-size: 22px;
  color: var(--text-light);
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
}

.pwa-btn-close:hover {
  color: var(--black);
}

/* iOS 专用样式 */
.pwa-ios-arrow {
  width: 0;
  height: 0;
  border-left: 10px solid transparent;
  border-right: 10px solid transparent;
  border-bottom: 8px solid #fff;
  position: absolute;
  bottom: 68px;
  left: 50%;
  transform: translateX(-50%);
}

@media (max-width: 768px) {
  .pwa-banner-inner {
    padding: 12px 14px;
    gap: 10px;
  }
  .pwa-banner-icon img {
    width: 38px;
    height: 38px;
  }
  .pwa-banner-text strong {
    font-size: 13px;
  }
  .pwa-btn-install {
    padding: 7px 14px;
    font-size: 12px;
  }
}

/* ===== 产品规格选择器 ===== */
.variant-select { margin: 14px 0 4px; }
.variant-title { font-weight: 700; font-size: 14px; margin-bottom: 8px; }
.variant-opt {
  display: flex;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--gray-border);
  border-radius: 8px;
  padding: 10px 12px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: border-color .15s, background .15s;
}
.variant-opt:hover { border-color: #999; }
.variant-opt.selected { border-color: var(--red); background: rgba(200, 30, 30, .05); }
.variant-opt input[type="radio"] { accent-color: var(--red); flex: 0 0 auto; margin: 0; }
.variant-opt .v-main { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.variant-opt .v-name { font-weight: 600; font-size: 14px; }
.variant-opt .v-specs { font-size: 12px; color: var(--text-light); }
.variant-opt .v-price { font-weight: 700; color: var(--red); font-size: 15px; white-space: nowrap; }
.cart-variant { font-size: 12px; color: var(--text-light); margin-top: 2px; font-weight: 400; }

/* 添加产品弹窗：多规格输入行 */
.vrow { display: flex; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; align-items: center; }
.vrow input { flex: 1; min-width: 72px; padding: 6px 8px; border: 1px solid #ccc; border-radius: 6px; font-size: 12px; box-sizing: border-box; }
.vrow input[name="v_label[]"] { flex: 2.2; min-width: 150px; }
.vrow input[name="v_count[]"] { flex: 1.4; min-width: 100px; }
.vrow-del { flex: 0 0 auto; background: #fff; border: 1px solid #c0392b; color: #c0392b; border-radius: 6px; cursor: pointer; padding: 5px 9px; font-size: 12px; }
@media (max-width: 480px) {
  .variant-opt { padding: 8px 10px; gap: 8px; }
  .variant-opt .v-price { font-size: 14px; }
}
