/* ============================================================
   CardShop — 全站样式
   ============================================================ */
:root {
  --bg: #0a0b10;
  --bg-2: #10121a;
  --panel: #14161f;
  --panel-2: #1a1d28;
  --line: #242836;
  --line-soft: #1c2029;
  --txt: #e8eaf2;
  --txt-dim: #9aa0b4;
  --txt-mute: #646b80;
  --acc: #6d5efc;
  --acc-2: #9b8cff;
  --cyan: #22d3ee;
  --ok: #34d399;
  --warn: #fbbf24;
  --bad: #f87171;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow: 0 10px 40px -12px rgba(0, 0, 0, .7);
  --mono: ui-monospace, "SF Mono", "Cascadia Mono", Consolas, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
               "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  background: var(--bg);
  color: var(--txt);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(900px 500px at 15% -10%, rgba(109, 94, 252, .16), transparent 60%),
    radial-gradient(700px 400px at 90% 0%, rgba(34, 211, 238, .09), transparent 55%);
  pointer-events: none;
  z-index: 0;
}

a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: none; background: none; color: inherit; }
input, textarea, select { font: inherit; color: inherit; }

.wrap { max-width: 1180px; margin: 0 auto; padding: 0 22px; position: relative; z-index: 1; }

/* ---------- 顶栏 ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(10, 11, 16, .78);
  border-bottom: 1px solid var(--line-soft);
}
.topbar-in { display: flex; align-items: center; gap: 18px; height: 62px; }

.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: .2px; }
.brand-mark {
  width: 30px; height: 30px; border-radius: 9px;
  background: linear-gradient(135deg, var(--acc), var(--cyan));
  display: grid; place-items: center;
  font-size: 15px; font-weight: 800; color: #08090d;
}
.brand-sub { font-size: 11px; color: var(--txt-mute); font-weight: 500; letter-spacing: .6px; }

.nav { display: flex; gap: 4px; margin-left: 14px; }
.nav a {
  padding: 7px 13px; border-radius: 8px; font-size: 14px;
  color: var(--txt-dim); transition: .16s;
}
.nav a:hover { color: var(--txt); background: var(--panel-2); }
.nav a.on { color: var(--txt); background: var(--panel-2); }

.topbar .spacer { flex: 1; }

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 7px;
  padding: 9px 18px; border-radius: var(--radius-sm);
  font-size: 14px; font-weight: 600; white-space: nowrap;
  background: var(--panel-2); color: var(--txt);
  border: 1px solid var(--line);
  transition: .16s;
}
.btn:hover { background: #222634; border-color: #303548; }
.btn:active { transform: translateY(1px); }
.btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }

.btn-primary {
  background: linear-gradient(135deg, var(--acc), #7c6cff);
  border-color: transparent; color: #fff;
  box-shadow: 0 6px 22px -8px rgba(109, 94, 252, .9);
}
.btn-primary:hover { filter: brightness(1.1); background: linear-gradient(135deg, var(--acc), #7c6cff); }

.btn-ghost { background: transparent; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-danger { color: var(--bad); border-color: rgba(248, 113, 113, .28); background: rgba(248, 113, 113, .07); }
.btn-danger:hover { background: rgba(248, 113, 113, .14); }

/* ---------- Hero ---------- */
.hero { padding: 52px 0 6px; text-align: center; }
.hero h1 {
  font-size: clamp(30px, 5vw, 46px); font-weight: 800; line-height: 1.15;
  letter-spacing: -.02em;
  background: linear-gradient(180deg, #fff 20%, #a6a9ff 130%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero p { color: var(--txt-dim); margin-top: 14px; font-size: 16px; }

/* 锚点滚动时避开吸顶导航 */
section[id] { scroll-margin-top: 80px; }

/* 页面标题块（独立页用） */
.page-head-block { padding: 46px 0 26px; }
.page-head-block h1 {
  font-size: clamp(28px, 4.2vw, 40px); font-weight: 800; line-height: 1.16;
  letter-spacing: -.02em;
  background: linear-gradient(180deg, #fff 20%, #a6a9ff 130%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.page-head-block p { color: var(--txt-dim); margin-top: 12px; font-size: 15px; }

/* 顶部公告 */
#announcement {
  margin-top: 20px;
  padding: 12px 18px;
  border-radius: 12px;
  background: rgba(109, 94, 252, .1);
  border: 1px solid rgba(109, 94, 252, .28);
  font-size: 13.5px;
  color: var(--acc-2);
  line-height: 1.6;
}

#products .section-head { margin-top: 18px; }
#redeem .section-head { margin-top: 48px; }

/* ---------- 兑换卡 ---------- */
.redeem-box {
  margin: 14px auto 0; max-width: 640px;
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: 18px; padding: 26px;
  box-shadow: var(--shadow);
  text-align: left;
}
.redeem-box h2 { font-size: 15px; font-weight: 700; margin-bottom: 4px; display: flex; align-items: center; gap: 8px; }
.redeem-box .hint { font-size: 12.5px; color: var(--txt-mute); margin-bottom: 16px; }

.code-input-row { display: flex; gap: 10px; }
.code-input-row input {
  flex: 1; padding: 13px 16px; border-radius: var(--radius-sm);
  background: #0b0d13; border: 1px solid var(--line);
  font-family: var(--mono); font-size: 15px; letter-spacing: 1.5px;
  outline: none; transition: .16s;
}
.code-input-row input:focus { border-color: var(--acc); box-shadow: 0 0 0 3px rgba(109, 94, 252, .16); }
.code-input-row input::placeholder { letter-spacing: .5px; color: var(--txt-mute); font-family: inherit; }

/* ---------- 商品网格 ---------- */
.section-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: 54px 0 20px; gap: 16px;
}
.section-head h2 { font-size: 21px; font-weight: 700; }
.section-head .count { font-size: 13px; color: var(--txt-mute); }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(258px, 1fr)); gap: 16px; align-items: stretch; }

.card {
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  display: flex; flex-direction: column; gap: 12px;
  transition: .18s;
  position: relative; overflow: hidden;
  cursor: pointer;
  height: 236px;
  box-sizing: border-box;
}
.card::after {
  content: ""; position: absolute; inset: 0 0 auto 0; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(155, 140, 255, .5), transparent);
  opacity: 0; transition: .25s;
}
.card:hover { transform: translateY(-3px); border-color: #2e3346; box-shadow: var(--shadow); }
.card:hover::after { opacity: 1; }

.card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.card-top h3 {
  font-size: 15.5px; font-weight: 700; line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; height: 2.7em; flex: 1;
}
.card h3 {
  font-size: 16.5px; font-weight: 700; line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  word-break: break-word;
}

/* 描述区固定 3 行，超出省略；完整内容点开详情看 */
/* 注意：这里不能用 flex:1 —— flex item 上 -webkit-line-clamp 会失效 */
.card .desc {
  font-size: 13px;
  color: var(--txt-dim);
  word-break: break-word;
  flex: 0 0 auto;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
  text-overflow: ellipsis;
  height: 3.24em;
  min-height: 3.24em;
  max-height: 3.24em;
  line-height: 1.62;
  -webkit-line-clamp: 2;
}
.card .more-hint {
  font-size: 11.5px; color: var(--acc-2); opacity: .8;
  height: 1.4em; line-height: 1.4em;
  overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
}

.badge {
  font-size: 11px; padding: 3px 9px; border-radius: 20px; font-weight: 600;
  white-space: nowrap; letter-spacing: .3px;
}
.badge-direct { background: rgba(34, 211, 238, .12); color: var(--cyan); border: 1px solid rgba(34, 211, 238, .25); }
.badge-redeem { background: rgba(155, 140, 255, .12); color: var(--acc-2); border: 1px solid rgba(155, 140, 255, .25); }

.card-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding-top: 4px; margin-top: auto; }
.price { font-size: 21px; font-weight: 800; letter-spacing: -.02em; }
.price small { font-size: 13px; font-weight: 600; color: var(--txt-dim); margin-right: 2px; }
.stock { font-size: 12px; color: var(--txt-mute); }
.stock.out { color: var(--bad); }

/* ---------- 结果面板 ---------- */
.result {
  margin-top: 18px; border-radius: var(--radius);
  border: 1px solid var(--line); overflow: hidden;
  display: none;
}
.result.show { display: block; animation: pop .22s ease; }
@keyframes pop { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.result.ok { border-color: rgba(52, 211, 153, .35); }
.result.bad { border-color: rgba(248, 113, 113, .35); }

.result-head {
  padding: 12px 16px; font-size: 13.5px; font-weight: 700;
  display: flex; align-items: center; gap: 8px;
}
.result.ok .result-head { background: rgba(52, 211, 153, .09); color: var(--ok); }
.result.bad .result-head { background: rgba(248, 113, 113, .09); color: var(--bad); }
.result-body { padding: 16px; background: #0b0d13; }

.field-row { display: flex; gap: 14px; padding: 9px 0; border-bottom: 1px dashed var(--line-soft); align-items: flex-start; }
.field-row:last-child { border-bottom: none; }
.field-label { width: 84px; flex: none; font-size: 13px; color: var(--txt-mute); padding-top: 3px; }
.field-value {
  flex: 1; font-family: var(--mono); font-size: 14px;
  word-break: break-all; display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.field-value .val { flex: 1; min-width: 0; }
.field-value .val.link {
  color: var(--cyan);
  text-decoration: underline;
  text-underline-offset: 3px;
  word-break: break-all;
}
.field-value .val.link:hover { color: #67e8f9; }

.copy-btn {
  font-size: 11.5px; padding: 3px 9px; border-radius: 6px;
  background: var(--panel-2); border: 1px solid var(--line);
  color: var(--txt-dim); transition: .16s; flex: none;
}
.copy-btn:hover { color: var(--txt); border-color: var(--acc); }
.copy-btn.done { color: var(--ok); border-color: rgba(52, 211, 153, .4); }

/* ---------- 表格 ---------- */
.table-wrap {
  border: 1px solid var(--line); border-radius: var(--radius);
  overflow: auto; background: var(--panel);
}
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
thead th {
  text-align: left; padding: 12px 14px; font-weight: 600; font-size: 12.5px;
  color: var(--txt-mute); text-transform: uppercase; letter-spacing: .5px;
  border-bottom: 1px solid var(--line); white-space: nowrap;
  background: var(--panel-2); position: sticky; top: 0;
}
tbody td { padding: 11px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
tbody tr:last-child td { border-bottom: none; }
tbody tr:hover { background: rgba(255, 255, 255, .018); }
td.mono { font-family: var(--mono); font-size: 12.5px; }

.status-dot { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; }
.status-dot::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.st-available { color: var(--ok); }
.st-redeemed { color: var(--txt-mute); }
.st-void { color: var(--bad); }
.st-delivered { color: var(--cyan); }

/* ---------- 表单 ---------- */
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 13px; font-weight: 600; margin-bottom: 7px; color: var(--txt-dim); }
.field input:not([type=checkbox]):not([type=radio]),
.field textarea, .field select {
  width: 100%; padding: 10px 13px; border-radius: var(--radius-sm);
  background: #0b0d13; border: 1px solid var(--line);
  outline: none; transition: .16s; font-size: 14px;
  color: var(--txt);
  -webkit-appearance: none; appearance: none;
}
.field input::placeholder, .field textarea::placeholder { color: var(--txt-mute); }
.field input:focus, .field textarea:focus, .field select:focus {
  border-color: var(--acc); box-shadow: 0 0 0 3px rgba(109, 94, 252, .14);
}
.field textarea { resize: vertical; min-height: 150px; font-family: var(--mono); font-size: 13px; line-height: 1.65; }
.field .sub { font-size: 12px; color: var(--txt-mute); margin-top: 6px; }
.field-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.field-row-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }

/* ---------- 弹窗 ---------- */
.modal-mask {
  position: fixed; inset: 0; background: rgba(4, 5, 9, .74);
  backdrop-filter: blur(4px);
  display: none; place-items: center; z-index: 200; padding: 20px;
}
.modal-mask.show { display: grid; }
.modal {
  background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 18px; width: min(560px, 100%);
  max-height: 88vh; overflow: auto; box-shadow: 0 30px 80px -20px #000;
  animation: pop .2s ease;
}
.modal-head {
  padding: 18px 22px; border-bottom: 1px solid var(--line-soft);
  display: flex; align-items: center; justify-content: space-between;
}
.modal-head h3 { font-size: 16px; font-weight: 700; }
.modal-body { padding: 22px; }
.modal-foot {
  padding: 14px 22px; border-top: 1px solid var(--line-soft);
  display: flex; justify-content: flex-end; gap: 10px;
}
.x-btn { width: 30px; height: 30px; border-radius: 8px; color: var(--txt-mute); font-size: 18px; }
.x-btn:hover { background: var(--panel-2); color: var(--txt); }

/* ---------- 后台骨架 ---------- */
.admin-shell { display: flex; min-height: 100vh; position: relative; z-index: 1; }
.side {
  width: 216px; flex: none; border-right: 1px solid var(--line-soft);
  padding: 20px 14px; background: rgba(16, 18, 26, .6);
  display: flex; flex-direction: column; gap: 4px;
}
.side .brand { padding: 0 8px 18px; }
.side-item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px; border-radius: 9px;
  font-size: 14px; color: var(--txt-dim); transition: .15s; width: 100%; text-align: left;
}
.side-item:hover { background: var(--panel-2); color: var(--txt); }
.side-item.on { background: rgba(109, 94, 252, .14); color: var(--acc-2); font-weight: 600; }
.side-item .ico { width: 17px; text-align: center; opacity: .85; }
.side .grow { flex: 1; }

.main { flex: 1; min-width: 0; padding: 26px 30px 60px; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.page-head h1 { font-size: 22px; font-weight: 750; letter-spacing: -.01em; }
.page-head .sub { font-size: 13px; color: var(--txt-mute); margin-top: 3px; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(168px, 1fr)); gap: 14px; margin-bottom: 26px; }
.stat {
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  border: 1px solid var(--line); border-radius: var(--radius); padding: 18px;
}
.stat .k { font-size: 12.5px; color: var(--txt-mute); font-weight: 600; letter-spacing: .3px; }
.stat .v { font-size: 27px; font-weight: 800; margin-top: 6px; letter-spacing: -.02em; }
.stat .v.small { font-size: 20px; }

.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.toolbar .grow { flex: 1; }
.toolbar input[type=text], .toolbar select {
  padding: 8px 13px; border-radius: var(--radius-sm);
  background: #0b0d13; border: 1px solid var(--line); outline: none; font-size: 13.5px;
}
.toolbar input[type=text] { min-width: 200px; }
.toolbar input:focus, .toolbar select:focus { border-color: var(--acc); }

/* ---------- 登录 ---------- */
.login-shell { min-height: 100vh; display: grid; place-items: center; padding: 24px; position: relative; z-index: 1; }
.login-card {
  width: min(400px, 100%);
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  border: 1px solid var(--line); border-radius: 20px;
  padding: 34px 30px; box-shadow: var(--shadow);
}
.login-card .brand { justify-content: center; margin-bottom: 8px; }
.login-card h1 { font-size: 18px; text-align: center; margin-bottom: 4px; }
.login-card .sub { text-align: center; font-size: 13px; color: var(--txt-mute); margin-bottom: 26px; }

/* ---------- Toast ---------- */
.toast-host { position: fixed; top: 18px; left: 50%; transform: translateX(-50%); z-index: 400; display: flex; flex-direction: column; gap: 8px; align-items: center; }
.toast {
  padding: 10px 18px; border-radius: 10px; font-size: 13.5px; font-weight: 600;
  background: var(--panel-2); border: 1px solid var(--line);
  box-shadow: var(--shadow); animation: pop .2s ease; white-space: nowrap;
}
.toast.ok { border-color: rgba(52, 211, 153, .4); color: var(--ok); }
.toast.bad { border-color: rgba(248, 113, 113, .4); color: var(--bad); }

/* ---------- 空态 / 加载 ---------- */
.empty { text-align: center; padding: 54px 20px; color: var(--txt-mute); font-size: 14px; }
.empty .big { font-size: 34px; margin-bottom: 10px; opacity: .35; }

.spinner {
  width: 15px; height: 15px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .22); border-top-color: #fff;
  animation: spin .7s linear infinite; display: inline-block;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- 登录 / 注册 ---------- */
.auth-wrap { max-width: 440px; margin: 0 auto; padding: 46px 0 40px; }

/* 覆盖浏览器自动填充的白底 */
input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus {
  -webkit-box-shadow: 0 0 0 1000px #0b0d13 inset !important;
  -webkit-text-fill-color: var(--txt) !important;
  caret-color: var(--txt);
  transition: background-color 9999s ease-in-out 0s;
}
.auth-hero { text-align: center; margin-bottom: 26px; }
.auth-hero h1 {
  font-size: 27px; font-weight: 800; letter-spacing: -.02em;
  background: linear-gradient(180deg, #fff 20%, #a6a9ff 130%);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.auth-hero p { color: var(--txt-dim); font-size: 14px; margin-top: 8px; }

.auth-card {
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  border: 1px solid var(--line); border-radius: 18px;
  padding: 24px; box-shadow: var(--shadow);
}

.auth-tabs {
  display: flex; gap: 4px; padding: 4px;
  background: #0b0d13; border: 1px solid var(--line);
  border-radius: 11px; margin-bottom: 22px;
}
.auth-tab {
  flex: 1; padding: 9px; border-radius: 8px;
  font-size: 14px; font-weight: 600; color: var(--txt-mute);
  transition: .16s; border: none; background: none; cursor: pointer;
}
.auth-tab.on { background: var(--panel-2); color: var(--txt); box-shadow: 0 1px 8px rgba(0,0,0,.35); }

.pw-wrap { position: relative; }
.pw-wrap input { padding-right: 46px !important; }
.pw-eye {
  position: absolute; right: 6px; top: 50%; transform: translateY(-50%);
  width: 32px; height: 32px; border-radius: 7px; font-size: 14px;
  color: var(--txt-mute); display: grid; place-items: center;
}
.pw-eye:hover { background: var(--panel-2); color: var(--txt); }

.code-wrap { display: flex; gap: 8px; }
.code-wrap input { flex: 1; min-width: 0; }
.code-wrap .btn { flex: none; white-space: nowrap; }

.auth-submit { width: 100%; padding: 12px; margin-top: 6px; font-size: 15px; }
.auth-foot { margin-top: 16px; text-align: center; font-size: 13px; color: var(--txt-mute); }
.auth-foot a { color: var(--acc-2); }
.auth-alt { text-align: center; margin-top: 22px; font-size: 13px; }
.auth-alt a { color: var(--txt-mute); }
.auth-alt a:hover { color: var(--acc-2); }

/* ---------- 个人中心 ---------- */
.pc-card {
  background: linear-gradient(180deg, var(--panel), var(--bg-2));
  border: 1px solid var(--line); border-radius: 16px; padding: 20px 22px;
}
.pc-card-head { font-size: 16px; font-weight: 700; letter-spacing: -.01em; }
.pc-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 16px 26px; margin-top: 16px;
}
.pc-k { font-size: 12px; color: var(--txt-mute); margin-bottom: 5px; }
.pc-v { font-size: 14px; color: var(--txt); word-break: break-all; }

.pc-stats {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
}
.pc-stat {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 14px; padding: 16px 18px;
}
.pc-stat .k { font-size: 12px; color: var(--txt-mute); margin-bottom: 8px; }
.pc-stat .v { font-size: 21px; font-weight: 800; letter-spacing: -.02em; }
.pc-stat .v.ok   { color: var(--ok); }
.pc-stat .v.warn { color: var(--warn); }
.pc-stat .v.acc  { color: var(--acc-2); }


/* ---------- 分类导航 ---------- */
.cat-bar {
  display: flex; gap: 8px; flex-wrap: wrap;
  margin-bottom: 22px; padding-bottom: 4px;
}
.cat-chip {
  padding: 7px 16px; border-radius: 999px;
  font-size: 13.5px; font-weight: 600;
  background: var(--panel); border: 1px solid var(--line);
  color: var(--txt-dim); cursor: pointer; transition: .15s;
  display: inline-flex; align-items: center; gap: 6px;
}
.cat-chip:hover { border-color: var(--acc); color: var(--txt); }
.cat-chip.on {
  background: linear-gradient(135deg, var(--acc), var(--acc-2));
  border-color: transparent; color: #fff;
  box-shadow: 0 4px 14px rgba(109,94,252,.3);
}
.cat-chip .n {
  font-size: 11px; opacity: .75; font-weight: 500;
}

/* ---------- 页脚 ---------- */
.foot {
  margin-top: 70px; padding: 26px 0; border-top: 1px solid var(--line-soft);
  color: var(--txt-mute); font-size: 12.5px; display: flex;
  justify-content: space-between; gap: 14px; flex-wrap: wrap;
}

/* ---------- 响应式 ---------- */
@media (max-width: 820px) {
  .admin-shell { flex-direction: column; }
  .side { width: 100%; flex-direction: row; overflow-x: auto; padding: 10px; gap: 2px; border-right: none; border-bottom: 1px solid var(--line-soft); }
  .side .brand, .side .grow { display: none; }
  .side-item { white-space: nowrap; padding: 8px 11px; font-size: 13px; }
  .main { padding: 18px 16px 50px; }
  .hero { padding: 42px 0 30px; }
  .redeem-box { padding: 20px; }
  .field-row-2 { grid-template-columns: 1fr; }

  /* 移动端：导航改为横向滚动，不隐藏 */
  .topbar-in {
    flex-wrap: wrap;
    padding: 10px 14px;
    gap: 8px;
  }
  .nav {
    display: flex;
    order: 3;
    width: 100%;
    overflow-x: auto;
    gap: 2px;
    padding-top: 6px;
    margin-top: 2px;
    border-top: 1px solid var(--line-soft);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }
  .nav::-webkit-scrollbar { display: none; }
  .nav a {
    white-space: nowrap;
    padding: 7px 13px;
    font-size: 13.5px;
    flex: 0 0 auto;
  }
  .spacer { display: none; }
  #userBox { order: 2; margin-left: auto; }
  .brand-sub { display: none; }
}

/* 分类切换淡入 */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.grid.animating .card { animation: fadeUp .22s ease both; }
.grid.animating .card:nth-child(1) { animation-delay: 0ms; }
.grid.animating .card:nth-child(2) { animation-delay: 20ms; }
.grid.animating .card:nth-child(3) { animation-delay: 40ms; }
.grid.animating .card:nth-child(4) { animation-delay: 60ms; }
.grid.animating .card:nth-child(5) { animation-delay: 80ms; }
.grid.animating .card:nth-child(6) { animation-delay: 100ms; }
.grid.animating .card:nth-child(7) { animation-delay: 120ms; }
.grid.animating .card:nth-child(8) { animation-delay: 140ms; }
