/* =============================================================
 * 创学社官方 - 共享响应式样式
 * 标准断点：
 *   PC 端   >= 1024px
 *   平板端  768px ~ 1023px
 *   手机端  < 768px
 * ============================================================= */

/* ---------- 全局基础 ---------- */
html { -webkit-text-size-adjust: 100%; -webkit-tap-highlight-color: transparent; }
body { overflow-x: hidden; }
img, video, svg { max-width: 100%; height: auto; display: block; }
table { max-width: 100%; }

/* 防止长字符串/英文撑破布局 */
p, h1, h2, h3, h4, h5, h6, li, td, th, a, span, div {
  word-wrap: break-word;
  overflow-wrap: break-word;
}

/* ---------- 容器 ---------- */
.site-container {
  width: 100%;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  padding-left: 16px;
  padding-right: 16px;
}
@media (min-width: 768px) {
  .site-container { padding-left: 24px; padding-right: 24px; }
}
@media (min-width: 1024px) {
  .site-container { padding-left: 32px; padding-right: 32px; }
}

/* ---------- 顶部导航（统一） ---------- */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  background-color: rgba(255, 255, 255, 0.95);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  transition: all 0.3s ease;
  padding: 12px 0;
}
.site-header.is-scrolled {
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  padding: 8px 0;
}
.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.site-header__brand {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  flex-shrink: 0;
}
.site-header__nav {
  display: none;
  align-items: center;
  gap: 28px;
  flex: 1;
  justify-content: flex-end;
  margin-left: 24px;
}
.site-header__nav a {
  font-weight: 700;
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
  white-space: nowrap;
}
.site-header__nav a:hover,
.site-header__nav a.is-active { color: #DAA520; }
.site-header__actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.site-header__login {
  display: none;
  padding: 8px 18px;
  background: #DAA520;
  color: #fff;
  font-weight: 700;
  border-radius: 6px;
  text-decoration: none;
  white-space: nowrap;
}
.site-header__burger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  background: transparent;
  border: 0;
  cursor: pointer;
  color: inherit;
  font-size: 20px;
}
.site-header__menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
  background: #fff;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}
.site-header__menu.is-open { max-height: 480px; }
.site-header__menu-inner {
  display: flex;
  flex-direction: column;
  padding: 12px 16px 20px;
  gap: 4px;
}
.site-header__menu-inner a {
  display: block;
  padding: 12px 8px;
  font-weight: 700;
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid rgba(0, 0, 0, 0.04);
}
.site-header__menu-inner a.is-active { color: #DAA520; }
.site-header__menu-inner a.site-header__login-mobile {
  margin-top: 8px;
  background: #DAA520;
  color: #fff;
  text-align: center;
  border-radius: 6px;
  border-bottom: 0;
}

@media (min-width: 768px) {
  .site-header { padding: 14px 0; }
  .site-header__menu-inner { padding: 16px 24px 24px; }
}
@media (min-width: 1024px) {
  .site-header { padding: 16px 0; }
  .site-header__nav { display: flex; }
  .site-header__login { display: inline-block; }
  .site-header__burger { display: none; }
  .site-header__menu { display: none !important; }
}

/* ---------- 主体内容主区 ---------- */
main { padding-top: 64px; } /* 给 fixed 导航留位 */
@media (min-width: 768px) { main { padding-top: 72px; } }
@media (min-width: 1024px) { main { padding-top: 80px; } }

/* ---------- 通用按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 700;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  transition: all 0.2s ease;
  white-space: nowrap;
  font-size: 14px;
}
.btn-primary { background: #DAA520; color: #fff; }
.btn-primary:hover { background: #c8941a; }
.btn-ghost { background: transparent; color: inherit; border: 1px solid currentColor; }
.btn-block { width: 100%; }
@media (max-width: 767px) {
  .btn { padding: 9px 16px; font-size: 13px; }
}

/* ---------- 通用卡片 ---------- */
.card {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1); }
@media (max-width: 767px) {
  .card { padding: 16px; border-radius: 10px; }
}

/* ---------- 通用网格 ---------- */
.grid-2, .grid-3, .grid-4 {
  display: grid;
  gap: 20px;
}
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: 1fr; }
@media (min-width: 768px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); gap: 28px; }
  .grid-4 { grid-template-columns: repeat(4, 1fr); gap: 24px; }
}

/* ---------- 标题 ---------- */
.section-title {
  font-size: clamp(20px, 3.5vw, 32px);
  font-weight: 800;
  text-align: center;
  margin: 0 0 8px;
  line-height: 1.3;
}
.section-subtitle {
  font-size: clamp(13px, 1.8vw, 16px);
  text-align: center;
  color: #6b7280;
  margin: 0 auto 32px;
  max-width: 720px;
  padding: 0 8px;
}
.section {
  padding: 48px 0;
}
@media (min-width: 768px) { .section { padding: 64px 0; } }
@media (min-width: 1024px) { .section { padding: 80px 0; } }

/* ---------- 表格响应式 ---------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table-wrap table { width: 100%; }

/* ---------- 表单 ---------- */
.form-row { display: flex; flex-direction: column; gap: 8px; margin-bottom: 16px; }
.form-row label { font-weight: 600; font-size: 14px; }
.form-row input,
.form-row select,
.form-row textarea {
  width: 100%;
  padding: 10px 12px;
  font-size: 14px;
  border: 1px solid #d1d5db;
  border-radius: 6px;
  background: #fff;
  color: inherit;
}
.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: 0;
  border-color: #DAA520;
  box-shadow: 0 0 0 3px rgba(218, 165, 32, 0.15);
}
@media (min-width: 768px) {
  .form-row.row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
}

/* ---------- 浮动工具按钮 ---------- */
.floating-tools {
  position: fixed;
  right: 16px;
  bottom: 80px;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.floating-tools a, .floating-tools button {
  width: 48px; height: 48px;
  border-radius: 50%;
  background: #DAA520;
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border: 0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  transition: transform 0.2s;
}
.floating-tools a:hover, .floating-tools button:hover { transform: scale(1.06); }
@media (max-width: 767px) {
  .floating-tools { right: 10px; bottom: 70px; }
  .floating-tools a, .floating-tools button { width: 42px; height: 42px; font-size: 14px; }
}

/* ---------- 返回顶部 ---------- */
.back-to-top {
  position: fixed;
  right: 16px;
  bottom: 20px;
  z-index: 90;
  width: 42px; height: 42px;
  border-radius: 50%;
  background: rgba(15, 23, 42, 0.8);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 0;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
}
.back-to-top.is-show { opacity: 1; visibility: visible; }
@media (min-width: 768px) {
  .back-to-top { right: 24px; bottom: 30px; width: 48px; height: 48px; }
}

/* ---------- 页脚 ---------- */
.site-footer {
  background: #0f172a;
  color: #cbd5e1;
  padding: 40px 0 20px;
  margin-top: 60px;
}
.site-footer a { color: #cbd5e1; text-decoration: none; }
.site-footer a:hover { color: #DAA520; }
.site-footer__grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  margin-bottom: 24px;
}
@media (min-width: 768px) { .site-footer__grid { grid-template-columns: 2fr 1fr 1fr; gap: 32px; } }
.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 16px;
  text-align: center;
  font-size: 13px;
  color: #94a3b8;
}

/* ---------- 工具类 ---------- */
.hide-mobile { display: none !important; }
.hide-tablet { display: block !important; }
.show-mobile-only { display: block !important; }
@media (min-width: 768px) {
  .hide-tablet { display: block !important; }
  .hide-mobile { display: block !important; }
  .show-mobile-only { display: none !important; }
}
@media (min-width: 768px) and (max-width: 1023px) {
  .hide-mobile { display: block !important; }
  .show-mobile-only { display: none !important; }
}
@media (min-width: 1024px) {
  .hide-mobile { display: block !important; }
  .show-mobile-only { display: none !important; }
}

/* ---------- 工具：隐藏滚动条 ---------- */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* ---------- 工具：文字大小适配 ---------- */
.text-fluid-xs { font-size: clamp(11px, 1.4vw, 13px); }
.text-fluid-sm { font-size: clamp(12px, 1.6vw, 14px); }
.text-fluid-md { font-size: clamp(14px, 1.9vw, 16px); }
.text-fluid-lg { font-size: clamp(18px, 2.6vw, 24px); }
.text-fluid-xl { font-size: clamp(22px, 3.4vw, 32px); }
.text-fluid-2xl { font-size: clamp(26px, 4.5vw, 44px); }

/* =============================================================
 * 优惠券组件样式
 * ============================================================= */
:root {
  --coupon-gold: #DAA520;
  --coupon-gold-2: #fbbf24;
  --coupon-red: #ef4444;
  --coupon-bg: #fff7e6;
  --coupon-border: #fde68a;
}

/* 飘窗 FAB（位于客服按钮上方，避免重叠被遮挡） */
.coupon-fab {
  position: fixed;
  right: 16px;
  bottom: 200px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  box-shadow: 0 8px 20px rgba(218, 165, 32, 0.45);
  z-index: 60;
  cursor: pointer;
  transition: transform .2s ease, box-shadow .2s ease;
  user-select: none;
}
.coupon-fab:hover { transform: translateY(-2px); box-shadow: 0 12px 24px rgba(218, 165, 32, 0.55); }
.coupon-fab__dot {
  position: absolute;
  top: 4px; right: 4px;
  width: 12px; height: 12px;
  background: #ef4444;
  border-radius: 50%;
  border: 2px solid #fff;
}
.coupon-fab.no-dot .coupon-fab__dot { display: none; }
@media (max-width: 768px) {
  .coupon-fab { right: 12px; bottom: 200px; width: 48px; height: 48px; font-size: 20px; }
}
@media (max-width: 480px) {
  /* 小屏客服按钮收为圆形(40px)，优惠券 FAB 紧贴其上方 */
  .coupon-fab { right: 8px; bottom: 130px; width: 44px; height: 44px; font-size: 18px; }
}

/* 全屏弹窗 */
.coupon-modal {
  position: fixed; inset: 0; z-index: 10000;
  display: none; align-items: center; justify-content: center;
  padding: 16px;
  overflow: auto;
}
.coupon-modal.is-open { display: flex; }
.coupon-modal__backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, .55);
  backdrop-filter: blur(4px);
}
.coupon-modal__panel {
  position: relative;
  width: min(560px, 100%);
  max-height: 100%;
  background: #fff;
  border-radius: 18px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .25);
  animation: couponModalIn .3s ease;
}
@keyframes couponModalIn {
  from { transform: scale(.92); opacity: 0; }
  to   { transform: scale(1);   opacity: 1; }
}
.coupon-modal__close {
  position: absolute; top: 10px; right: 14px;
  background: transparent; border: 0;
  font-size: 26px; line-height: 1;
  color: #999; cursor: pointer; z-index: 2;
}
.coupon-modal__close:hover { color: #333; }
.coupon-modal__head {
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  padding: 22px 24px 18px;
}
.coupon-modal__title { font-size: 18px; font-weight: 800; }
.coupon-modal__sub   { font-size: 13px; opacity: .9; margin-top: 4px; }
.coupon-modal__list {
  flex: 1;
  overflow-y: auto;
  padding: 14px 18px 6px;
  display: flex; flex-direction: column; gap: 12px;
}
.coupon-modal__foot {
  border-top: 1px solid #f1f1f1;
  padding: 12px 18px;
  display: flex; flex-direction: column; gap: 8px;
  background: #fafafa;
}
.coupon-modal__link {
  text-align: center;
  color: var(--coupon-gold);
  font-size: 13px;
  text-decoration: none;
}
.coupon-manual {
  display: flex; align-items: center; gap: 8px;
}
.coupon-manual input {
  flex: 1; min-width: 0;
  padding: 8px 10px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  font-size: 14px;
  background: #fff;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.coupon-manual input:focus { outline: none; border-color: var(--coupon-gold); }
.coupon-manual button {
  padding: 8px 16px;
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  border: 0; border-radius: 8px;
  cursor: pointer; font-size: 13px;
  white-space: nowrap;
}
.coupon-manual button:hover { opacity: .9; }
.coupon-loading, .coupon-empty {
  text-align: center; color: #999; padding: 40px 0; font-size: 14px;
}

/* 卡片 */
.coupon-card {
  display: flex;
  background: linear-gradient(90deg, #fff7e6 0%, #fff 60%);
  border: 1px dashed #f5c042;
  border-radius: 12px;
  overflow: hidden;
  position: relative;
  min-height: 96px;
}
.coupon-card::before, .coupon-card::after {
  content: '';
  position: absolute;
  width: 14px; height: 14px;
  background: #fff;
  border-radius: 50%;
  left: 96px;
}
.coupon-card::before { top: -7px; }
.coupon-card::after  { bottom: -7px; }
.coupon-card__left {
  width: 96px;
  background: linear-gradient(180deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 8px 4px;
}
.coupon-card__amount { font-size: 24px; font-weight: 900; line-height: 1.1; }
.coupon-card__condition { font-size: 11px; opacity: .9; margin-top: 4px; }
.coupon-card__right {
  flex: 1; min-width: 0;
  padding: 10px 12px;
  display: flex; flex-direction: column; gap: 4px;
}
.coupon-card__name { font-size: 14px; font-weight: 700; color: #1f2937; }
.coupon-card__meta { font-size: 12px; color: #6b7280; }
.coupon-card__desc { font-size: 12px; color: #9ca3af; }
.coupon-card__btn {
  align-self: flex-end;
  margin-top: 4px;
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  border: 0; border-radius: 999px;
  padding: 5px 16px;
  font-size: 12px; font-weight: 600;
  cursor: pointer;
}
.coupon-card__btn:disabled {
  background: #e5e7eb; color: #9ca3af; cursor: not-allowed;
}
.coupon-card.is-claimed .coupon-card__left { filter: grayscale(.4); opacity: .8; }
.coupon-card.is-claimed { border-style: solid; border-color: #e5e7eb; background: #fafafa; }

/* Toast */
.coupon-toast {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) scale(.95);
  background: rgba(0, 0, 0, .82);
  color: #fff;
  padding: 10px 18px;
  border-radius: 10px;
  font-size: 14px;
  z-index: 200;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease, transform .2s ease;
  max-width: 80vw;
  text-align: center;
}
.coupon-toast.is-show { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.coupon-toast.is-error { background: rgba(220, 38, 38, .92); }

/* 用户中心 - 优惠券列表 */
.coupon-list { display: flex; flex-direction: column; gap: 12px; }
.coupon-item {
  display: flex;
  background: #fff;
  border: 1px solid #fde68a;
  border-radius: 12px;
  overflow: hidden;
  min-height: 100px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .04);
  position: relative;
}
.coupon-item.is-used { opacity: .55; filter: grayscale(.6); }
.coupon-item.is-expired { opacity: .45; filter: grayscale(.9); }
.coupon-item__left {
  width: 110px;
  background: linear-gradient(180deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 12px 6px;
}
.coupon-item__amount { font-size: 28px; font-weight: 900; line-height: 1.1; }
.coupon-item__amount small { font-size: 14px; font-weight: 600; margin-left: 2px; }
.coupon-item__condition { font-size: 12px; opacity: .92; margin-top: 4px; }
.coupon-item__right {
  flex: 1; min-width: 0;
  padding: 12px 14px;
  display: flex; flex-direction: column; gap: 6px;
}
.coupon-item__name { font-size: 15px; font-weight: 700; color: #1f2937; }
.coupon-item__meta { font-size: 12px; color: #6b7280; }
.coupon-item__code { font-size: 12px; color: #374151; font-family: monospace; letter-spacing: 1px; }
.coupon-item__action {
  align-self: flex-end;
  margin-top: auto;
  display: flex; gap: 6px;
}
.coupon-item__btn {
  border: 1px solid #DAA520;
  color: #DAA520;
  background: #fff;
  border-radius: 999px;
  padding: 4px 14px;
  font-size: 12px;
  cursor: pointer;
}
.coupon-item__btn:hover { background: #fff7e6; }
.coupon-item__btn--primary {
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  border-color: transparent;
}
.coupon-item__btn--primary:hover { opacity: .9; }
.coupon-item__status {
  position: absolute; top: 8px; right: 10px;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  background: #f3f4f6;
  color: #6b7280;
}
.coupon-item__status.is-unused { background: #fef3c7; color: #92400e; }
.coupon-item__status.is-used { background: #d1fae5; color: #065f46; }
.coupon-item__status.is-expired { background: #fee2e2; color: #991b1b; }
.coupon-empty-block {
  text-align: center;
  padding: 48px 20px;
  color: #9ca3af;
}
.coupon-empty-block i { font-size: 36px; color: #e5e7eb; margin-bottom: 8px; }
.coupon-empty-block p { margin-top: 4px; font-size: 13px; }

/* 优惠券 Tab 切换 */
.coupon-tabs {
  display: flex; gap: 4px;
  border-bottom: 1px solid #e5e7eb;
  margin-bottom: 16px;
}
.coupon-tab {
  padding: 8px 16px;
  cursor: pointer;
  font-size: 14px;
  color: #6b7280;
  border-bottom: 2px solid transparent;
  transition: all .2s ease;
}
.coupon-tab.is-active {
  color: var(--coupon-gold);
  border-color: var(--coupon-gold);
  font-weight: 600;
}

/* 支付页 - 优惠券入口 */
.pay-coupon-block {
  background: #fff;
  border-radius: 12px;
  padding: 14px 16px;
  margin-bottom: 12px;
  display: flex; align-items: center; gap: 12px;
  cursor: pointer;
  border: 1px solid #f3f4f6;
}
.pay-coupon-block:hover { border-color: #fde68a; }
/* 合一模块：状态变体 */
.pay-coupon-block--active {
  border: 1px solid #fbbf24;
  background: linear-gradient(90deg, #fffbeb 0%, #ffffff 60%);
}
.pay-coupon-block--unclaimed {
  border: 1px dashed #fb923c;
  background: linear-gradient(90deg, #fff7ed 0%, #ffffff 70%);
  animation: payCouponPulse 2.2s ease-in-out infinite;
}
@keyframes payCouponPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(251, 146, 60, 0.0); }
  50% { box-shadow: 0 0 0 4px rgba(251, 146, 60, 0.18); }
}
.pay-coupon-block--none {
  background: #f9fafb;
  opacity: 0.85;
}
.pay-coupon-block__icon {
  width: 36px; height: 36px;
  border-radius: 8px;
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}
.pay-coupon-block--unclaimed .pay-coupon-block__icon {
  background: linear-gradient(135deg, #fb923c 0%, #f97316 100%);
}
.pay-coupon-block__body { flex: 1; min-width: 0; }
.pay-coupon-block__title { font-size: 14px; font-weight: 600; color: #1f2937; }
.pay-coupon-block__sub { font-size: 12px; color: #6b7280; margin-top: 2px; }
.pay-coupon-block__arrow { color: #9ca3af; font-size: 14px; }

.pay-coupon-discount {
  display: flex; justify-content: space-between;
  font-size: 13px; color: #ef4444;
  padding: 6px 0;
}

/* 支付页 - 选券弹层 */
.pay-coupon-sheet {
  position: fixed; inset: 0; z-index: 90;
  display: none; align-items: flex-end; justify-content: center;
}
.pay-coupon-sheet.is-open { display: flex; }
.pay-coupon-sheet__backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 0, 0, .5);
}
.pay-coupon-sheet__panel {
  position: relative;
  width: 100%; max-width: 560px;
  background: #fff;
  border-radius: 18px 18px 0 0;
  max-height: 75vh;
  display: flex; flex-direction: column;
  animation: paySheetUp .3s ease;
}
@keyframes paySheetUp {
  from { transform: translateY(100%); }
  to   { transform: translateY(0); }
}
.pay-coupon-sheet__head {
  padding: 14px 18px;
  display: flex; justify-content: space-between; align-items: center;
  border-bottom: 1px solid #f1f1f1;
}
.pay-coupon-sheet__title { font-size: 16px; font-weight: 700; }
.pay-coupon-sheet__close { background: transparent; border: 0; font-size: 22px; color: #999; cursor: pointer; }
.pay-coupon-sheet__body { flex: 1; overflow-y: auto; padding: 12px 14px; }
.pay-coupon-sheet__foot {
  padding: 12px 18px;
  border-top: 1px solid #f1f1f1;
  text-align: center;
}
.pay-coupon-sheet__btn {
  width: 100%;
  background: linear-gradient(135deg, #DAA520 0%, #fbbf24 100%);
  color: #fff;
  border: 0; border-radius: 999px;
  padding: 10px 0;
  font-size: 15px; font-weight: 600;
  cursor: pointer;
}
.pay-coupon-option {
  border: 2px solid transparent;
  border-radius: 10px;
  padding: 0; margin-bottom: 10px;
  transition: border-color .2s ease;
  overflow: hidden;
  background: #fff;
}
.pay-coupon-option.is-active { border-color: #DAA520; }
.pay-coupon-option__radio {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  cursor: pointer;
}
.pay-coupon-option__radio input { accent-color: #DAA520; }
.pay-coupon-option__body { flex: 1; min-width: 0; }
.pay-coupon-option__name { font-size: 14px; font-weight: 600; }
.pay-coupon-option__desc { font-size: 12px; color: #6b7280; margin-top: 2px; }
.pay-coupon-empty { text-align: center; color: #999; padding: 30px 0; font-size: 13px; }

/* 支付页 - 未领券提醒 */
.pay-no-coupon-tip {
  display: flex; gap: 10px;
  background: linear-gradient(90deg, #fff7e6 0%, #fff 100%);
  border: 1px solid #fde68a;
  border-radius: 10px;
  padding: 10px 12px;
  margin-bottom: 12px;
  font-size: 13px;
  align-items: center;
}
.pay-no-coupon-tip i { color: #DAA520; font-size: 16px; }
.pay-no-coupon-tip__body { flex: 1; min-width: 0; }
.pay-no-coupon-tip__title { font-weight: 600; color: #92400e; }
.pay-no-coupon-tip__sub { color: #6b7280; margin-top: 2px; font-size: 12px; }
.pay-no-coupon-tip__btn {
  background: #DAA520; color: #fff;
  border: 0; border-radius: 999px;
  padding: 4px 12px; font-size: 12px;
  cursor: pointer;
}
.pay-no-coupon-tip__btn:hover { opacity: .9; }

/* 管理后台 - 优惠券管理 */
.admin-coupon-toolbar {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 14px; flex-wrap: wrap; gap: 10px;
}
.admin-coupon-table {
  width: 100%; border-collapse: collapse;
  background: #fff; border-radius: 10px; overflow: hidden;
  font-size: 13px;
}
.admin-coupon-table th, .admin-coupon-table td {
  padding: 10px 12px; text-align: left; border-bottom: 1px solid #f1f1f1;
  vertical-align: middle;
}
.admin-coupon-table th { background: #fafafa; font-weight: 600; color: #374151; }
.admin-coupon-table tr:last-child td { border-bottom: 0; }
.admin-coupon-table .row-action { display: flex; gap: 6px; }
.admin-coupon-table .row-action button {
  padding: 3px 10px; font-size: 12px; border-radius: 6px; border: 1px solid #e5e7eb; background: #fff; cursor: pointer;
}
.admin-coupon-table .row-action .danger { color: #ef4444; border-color: #fecaca; }
.admin-coupon-table .row-action .danger:hover { background: #fee2e2; }
.admin-coupon-table .row-action .primary { color: #DAA520; border-color: #fde68a; }
.admin-coupon-table .row-action .primary:hover { background: #fff7e6; }

.admin-coupon-tag {
  display: inline-block; padding: 2px 8px;
  border-radius: 999px; font-size: 11px;
}
.admin-coupon-tag.is-active { background: #d1fae5; color: #065f46; }
.admin-coupon-tag.is-off, .admin-coupon-tag.is-expired { background: #fee2e2; color: #991b1b; }
.admin-coupon-tag.is-pending { background: #fef3c7; color: #92400e; }
.admin-coupon-tag.is-soldout { background: #e0e7ff; color: #3730a3; }

.admin-coupon-modal {
  position: fixed; inset: 0; z-index: 90;
  display: none; align-items: center; justify-content: center;
}
.admin-coupon-modal.is-open { display: flex; }
.admin-coupon-modal__backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.5); }
.admin-coupon-modal__panel {
  position: relative;
  width: min(640px, 94vw);
  max-height: 92vh;
  background: #fff;
  border-radius: 14px;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.admin-coupon-modal__head {
  padding: 14px 18px; border-bottom: 1px solid #f1f1f1;
  display: flex; justify-content: space-between; align-items: center;
}
.admin-coupon-modal__body { padding: 16px 18px; overflow-y: auto; flex: 1 1 auto; min-height: 0; }
.admin-coupon-modal__foot {
  padding: 12px 18px; border-top: 1px solid #f1f1f1;
  display: flex; justify-content: flex-end; gap: 8px;
  flex: 0 0 auto;
  background: #fff;
}
.admin-coupon-form .form-row { display: flex; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.admin-coupon-form .form-row > div { flex: 1; min-width: 160px; }
.admin-coupon-form label { display: block; font-size: 12px; color: #6b7280; margin-bottom: 4px; }
.admin-coupon-form input, .admin-coupon-form select, .admin-coupon-form textarea {
  width: 100%; padding: 8px 10px; font-size: 13px;
  border: 1px solid #e5e7eb; border-radius: 8px; background: #fff;
  box-sizing: border-box;
}
.admin-coupon-form input:focus, .admin-coupon-form select:focus, .admin-coupon-form textarea:focus {
  outline: none; border-color: #DAA520;
}
.admin-coupon-form textarea { min-height: 60px; resize: vertical; }

/* 统计卡 */
.admin-coupon-stat {
  background: linear-gradient(135deg, #fff 0%, #fffbeb 100%);
  border: 1px solid #fde68a;
  border-radius: 12px;
  padding: 12px 14px;
}
.admin-coupon-stat__label { font-size: 12px; color: #6b7280; }
.admin-coupon-stat__value { font-size: 22px; font-weight: 800; color: #1f2937; margin-top: 4px; }

/* 优惠券卡片网格 */
.admin-coupon-cards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 14px;
}
.admin-coupon-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 50px 0;
  color: #9ca3af;
  font-size: 13px;
}
.admin-coupon-empty i { margin-right: 6px; color: #DAA520; }
.admin-coupon-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: all .18s ease;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.admin-coupon-card:hover {
  border-color: #fde68a;
  box-shadow: 0 6px 20px rgba(218, 165, 32, .12);
  transform: translateY(-2px);
}
.admin-coupon-card.is-off { opacity: .65; }
.admin-coupon-card__head {
  padding: 14px 14px 10px;
  background: linear-gradient(90deg, #fffbeb 0%, #fff 70%);
  display: flex; justify-content: space-between; align-items: flex-start; gap: 8px;
}
.admin-coupon-card__title { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; flex-wrap: wrap; }
.admin-coupon-card__name { font-weight: 700; color: #1f2937; font-size: 14px; }
.admin-coupon-card__amount { text-align: right; flex-shrink: 0; }
.admin-coupon-card__amount-num { display: block; font-size: 20px; font-weight: 800; color: #DAA520; line-height: 1.1; }
.admin-coupon-card__amount-cond { display: block; font-size: 11px; color: #6b7280; margin-top: 2px; }
.admin-coupon-card__body { padding: 10px 14px; display: flex; flex-direction: column; gap: 6px; }
.admin-coupon-card__row { display: flex; align-items: flex-start; gap: 8px; font-size: 12px; color: #4b5563; }
.admin-coupon-card__row i { color: #DAA520; width: 14px; flex-shrink: 0; margin-top: 2px; }
.admin-coupon-card__row span { flex: 1; min-width: 0; word-break: break-all; }
.admin-coupon-chip {
  display: inline-block; font-size: 11px; padding: 2px 8px; border-radius: 10px;
  background: #f3f4f6; color: #4b5563; margin-right: 4px; vertical-align: middle;
}
.admin-coupon-chip.is-global { background: #d1fae5; color: #065f46; }
.admin-coupon-code {
  display: inline-block; font-family: monospace; font-size: 11px; letter-spacing: 1px;
  background: #fff7e6; padding: 2px 8px; border-radius: 4px; color: #92400e; vertical-align: middle;
}
.admin-coupon-card__progress {
  height: 4px; background: #f3f4f6; margin: 0 14px 6px; border-radius: 2px; overflow: hidden;
}
.admin-coupon-card__progress-bar { height: 100%; background: linear-gradient(90deg, #DAA520, #fbbf24); }
.admin-coupon-card__foot {
  border-top: 1px solid #f3f4f6; padding: 8px 10px; display: flex; gap: 6px; justify-content: flex-end;
  background: #fafafa;
}
.admin-coupon-card__btn {
  background: #fff; border: 1px solid #e5e7eb; border-radius: 6px; padding: 4px 10px;
  font-size: 12px; color: #374151; cursor: pointer; display: inline-flex; align-items: center; gap: 4px;
  transition: all .15s ease;
}
.admin-coupon-card__btn:hover { background: #fff7e6; border-color: #fde68a; color: #92400e; }
.admin-coupon-card__btn.is-danger { color: #ef4444; border-color: #fecaca; }
.admin-coupon-card__btn.is-danger:hover { background: #fee2e2; border-color: #fca5a5; }
.admin-coupon-card__btn i { font-size: 11px; }

/* 领取记录行 */
.admin-coupon-claim-row {
  display: flex; justify-content: space-between; align-items: flex-start; gap: 12px;
  padding: 10px 12px; border: 1px solid #f3f4f6; border-radius: 8px; margin-bottom: 8px;
  background: #fff;
}
.admin-coupon-claim-row__main { flex: 1; min-width: 0; }
.admin-coupon-claim-row__id { font-weight: 600; color: #1f2937; font-size: 13px; }
.admin-coupon-claim-row__meta { font-size: 12px; color: #6b7280; margin-top: 2px; }
.admin-coupon-claim-row__meta code { background: #f3f4f6; padding: 1px 5px; border-radius: 3px; font-size: 11px; }
.admin-coupon-claim-row__side { text-align: right; flex-shrink: 0; }
.admin-coupon-claim-row__date { font-size: 11px; color: #9ca3af; margin-top: 2px; }
.admin-coupon-tag {
  display: inline-block; font-size: 11px; padding: 2px 8px; border-radius: 10px;
  background: #f3f4f6; color: #4b5563;
}
.admin-coupon-tag.is-pending { background: #fef3c7; color: #92400e; }
.admin-coupon-tag.is-active { background: #d1fae5; color: #065f46; }
.admin-coupon-tag.is-expired { background: #e5e7eb; color: #6b7280; }

/* 移动端优惠券适配 */
@media (max-width: 768px) {
  .coupon-item { min-height: 90px; }
  .coupon-item__left { width: 88px; }
  .coupon-item__amount { font-size: 22px; }
  .coupon-card { min-height: 84px; }
  .coupon-card__left { width: 80px; }
  .coupon-card::before, .coupon-card::after { left: 80px; }
  .admin-coupon-table { font-size: 12px; }
  .admin-coupon-table th, .admin-coupon-table td { padding: 8px; }
  .pay-coupon-sheet__panel { max-height: 80vh; }
  .admin-coupon-form .form-row > div { min-width: 100%; }
  .admin-coupon-cards { grid-template-columns: 1fr; gap: 10px; }
  .admin-coupon-stat__value { font-size: 18px; }
  .admin-coupon-card__foot { flex-wrap: wrap; }
  .admin-coupon-card__btn { flex: 1; justify-content: center; }
}
