/* ============================================================
   Wxctf Ai 卡密商城 - 全局样式
   复刻 React 版 (Tailwind + shadcn) 视觉体系
   ============================================================ */

:root {
  --brand: 221 83% 53%;
  --brand-foreground: 0 0% 100%;
  --brand-2: 199 89% 48%;

  --background: 0 0% 100%;
  --foreground: 222 47% 11%;
  --card: 0 0% 100%;
  --card-foreground: 222 47% 11%;
  --popover: 0 0% 100%;
  --popover-foreground: 222 47% 11%;
  --primary: 221 83% 53%;
  --primary-foreground: 0 0% 100%;
  --secondary: 214 95% 95%;
  --secondary-foreground: 221 70% 30%;
  --muted: 214 40% 96%;
  --muted-foreground: 215 16% 47%;
  --accent: 214 95% 95%;
  --accent-foreground: 221 70% 30%;
  --destructive: 0 72% 51%;
  --destructive-foreground: 0 0% 98%;
  --border: 214 32% 91%;
  --input: 214 32% 91%;
  --ring: 221 83% 53%;
  --radius: 0.75rem;

  --bg-rgb: 255 255 255;
  --card-rgb: 255 255 255;
}

html.dark {
  --background: 222 47% 7%;
  --foreground: 210 40% 98%;
  --card: 222 44% 9%;
  --card-foreground: 210 40% 98%;
  --popover: 222 44% 9%;
  --popover-foreground: 210 40% 98%;
  --primary: 217 91% 60%;
  --primary-foreground: 0 0% 100%;
  --secondary: 217 33% 16%;
  --secondary-foreground: 210 40% 98%;
  --muted: 217 33% 15%;
  --muted-foreground: 215 20% 65%;
  --accent: 217 33% 18%;
  --accent-foreground: 210 40% 98%;
  --destructive: 0 62% 45%;
  --destructive-foreground: 0 0% 98%;
  --border: 217 33% 18%;
  --input: 217 33% 19%;
  --ring: 217 91% 62%;

  --bg-rgb: 10 12 22;
  --card-rgb: 13 16 27;
}

* {
  box-sizing: border-box;
  border-color: hsl(var(--border));
  scrollbar-width: thin;
  scrollbar-color: hsl(var(--muted-foreground) / 0.4) transparent;
}

*::-webkit-scrollbar { width: 8px; height: 8px; }
*::-webkit-scrollbar-thumb { background: hsl(var(--muted-foreground) / 0.35); border-radius: 9999px; }

html {
  scroll-behavior: smooth;
  overflow-x: clip;
  overflow-y: scroll;
}

body {
  margin: 0;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
  font-feature-settings: "rlig" 1, "calt" 1;
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

/* ---- 工具类（对应 Tailwind 常用） ---- */
.mx-auto { margin-left: auto; margin-right: auto; }
.max-w-6xl { max-width: 72rem; }
.max-w-5xl { max-width: 64rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-2xl { max-width: 42rem; }
.max-w-xl { max-width: 36rem; }
.max-w-sm { max-width: 24rem; }

.grid { display: grid; }
.flex { display: flex; }
.inline-flex { display: inline-flex; }
.hidden { display: none; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.flex-1 { flex: 1 1 0%; }
.shrink-0 { flex-shrink: 0; }
.relative { position: relative; }
.absolute { position: absolute; }
.sticky { position: sticky; }
.z-50 { z-index: 50; }
.top-0 { top: 0; }
.right-4 { right: 1rem; }
.top-4 { top: 1rem; }
.w-full { width: 100%; }
.h-16 { height: 4rem; }
.min-h-screen { min-height: 100vh; }
.overflow-hidden { overflow: hidden; }
.whitespace-nowrap { white-space: nowrap; }
.break-all { word-break: break-all; }
.line-clamp-3 { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.font-mono { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
.font-semibold { font-weight: 600; }
.font-bold { font-weight: 700; }
.font-extrabold { font-weight: 800; }
.font-medium { font-weight: 500; }
.tracking-tight { letter-spacing: -0.025em; }

/* ---- size-* 工具类（对应 Tailwind：width/height = N * 0.25rem） ---- */
.size-1\.5 { width: 0.375rem; height: 0.375rem; }
.size-3\.5 { width: 0.875rem; height: 0.875rem; }
.size-4 { width: 1rem; height: 1rem; }
.size-5 { width: 1.25rem; height: 1.25rem; }
.size-6 { width: 1.5rem; height: 1.5rem; }
.size-7 { width: 1.75rem; height: 1.75rem; }
.size-8 { width: 2rem; height: 2rem; }
.size-9 { width: 2.25rem; height: 2.25rem; }
.size-10 { width: 2.5rem; height: 2.5rem; }
.size-11 { width: 2.75rem; height: 2.75rem; }
.size-14 { width: 3.5rem; height: 3.5rem; }
.size-16 { width: 4rem; height: 4rem; }
.object-cover { object-fit: cover; }
.tracking-wider { letter-spacing: 0.05em; }
.whitespace-pre-wrap { white-space: pre-wrap; }

/* ---- 间距 ---- */
.px-4 { padding-left: 1rem; padding-right: 1rem; }
.px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }
.py-16 { padding-top: 4rem; padding-bottom: 4rem; }
.py-20 { padding-top: 5rem; padding-bottom: 5rem; }
.py-24 { padding-top: 6rem; padding-bottom: 6rem; }
.p-4 { padding: 1rem; }
.p-5 { padding: 1.25rem; }
.p-6 { padding: 1.5rem; }
.p-8 { padding: 2rem; }
.p-10 { padding: 2.5rem; }
.pt-3 { padding-top: 0.75rem; }
.pb-3 { padding-bottom: 0.75rem; }
.px-3 { padding-left: 0.75rem; padding-right: 0.75rem; }
.py-2 { padding-top: 0.5rem; padding-bottom: 0.5rem; }
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }
.py-1 { padding-top: 0.25rem; padding-bottom: 0.25rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.pl-5 { padding-left: 1.25rem; }
.pl-0 { padding-left: 0; }
.list-none { list-style: none; }
.pl-9 { padding-left: 2.25rem; }
.pr-10 { padding-right: 2.5rem; }

.mt-1 { margin-top: 0.25rem; }
.mt-2 { margin-top: 0.5rem; }
.mt-3 { margin-top: 0.75rem; }
.mt-4 { margin-top: 1rem; }
.mt-5 { margin-top: 1.25rem; }
.mt-6 { margin-top: 1.5rem; }
.mt-8 { margin-top: 2rem; }
.mt-10 { margin-top: 2.5rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }
.mb-2 { margin-bottom: 0.5rem; }
.mb-6 { margin-bottom: 1.5rem; }
.mb-8 { margin-bottom: 2rem; }
.ml-auto { margin-left: auto; }
.mr-2 { margin-right: 0.5rem; }
.mr-1\.5 { margin-right: 0.375rem; }

.gap-1 { gap: 0.25rem; }
.gap-1\.5 { gap: 0.375rem; }
.gap-2 { gap: 0.5rem; }
.gap-2\.5 { gap: 0.625rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-5 { gap: 1.25rem; }
.gap-8 { gap: 2rem; }
.gap-10 { gap: 2.5rem; }
.space-y-2 > * + * { margin-top: 0.5rem; }
.space-y-2\.5 > * + * { margin-top: 0.625rem; }
.space-y-3 > * + * { margin-top: 0.75rem; }
.space-y-4 > * + * { margin-top: 1rem; }
.space-y-5 > * + * { margin-top: 1.25rem; }
.space-y-6 > * + * { margin-top: 1.5rem; }

.space-y-7 > * + * { margin-top: 1.75rem; }
.space-y-8 > * + * { margin-top: 2rem; }
.space-y-10 > * + * { margin-top: 2.5rem; }
.scroll-mt-24 { scroll-margin-top: 6rem; }

/* ---- 网格列 ---- */
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* ---- 文字颜色 ---- */
.text-foreground { color: hsl(var(--foreground)); }
.text-muted-foreground { color: hsl(var(--muted-foreground)); }
.text-primary { color: hsl(var(--primary)); }
.text-blue-500 { color: #3b82f6; }
.text-blue-600 { color: #2563eb; }
.text-emerald-600 { color: #059669; }
.text-orange-600 { color: #ea580c; }
.text-destructive { color: hsl(var(--destructive)); }
.text-white { color: #fff; }

/* ---- 背景 ---- */
.bg-background { background: hsl(var(--background)); }
.bg-card { background: hsl(var(--card)); }
.bg-card\/50 { background: hsl(var(--card) / 0.5); }
.bg-background\/60 { background: hsl(var(--background) / 0.6); }
.bg-background\/70 { background: hsl(var(--background) / 0.7); }
.bg-background\/80 { background: hsl(var(--background) / 0.8); }
.bg-blue-500 { background: #3b82f6; }
.bg-blue-500\/5 { background: rgb(59 130 246 / 0.05); }
.bg-blue-500\/10 { background: rgb(59 130 246 / 0.10); }
.bg-blue-500\/15 { background: rgb(59 130 246 / 0.15); }
.bg-blue-500\/20 { background: rgb(59 130 246 / 0.20); }
.bg-emerald-500\/15 { background: rgb(16 185 129 / 0.15); }
.bg-orange-500 { background: #f97316; }
.bg-sky-500 { background: #0ea5e9; }
.bg-violet-500 { background: #8b5cf6; }
.bg-muted { background: hsl(var(--muted)); }
.bg-accent { background: hsl(var(--accent)); }
.bg-primary { background: hsl(var(--primary)); }
.bg-destructive\/5 { background: hsl(var(--destructive) / 0.05); }

/* ---- 边框 ---- */
.border { border: 1px solid hsl(var(--border)); }
.border-0 { border: 0; }
.border-t { border-top: 1px solid hsl(var(--border)); }
.border-b { border-bottom: 1px solid hsl(var(--border)); }
.border-y { border-top: 1px solid hsl(var(--border)); border-bottom: 1px solid hsl(var(--border)); }
.border-border { border-color: hsl(var(--border)); }
.border-border\/60 { border-color: hsl(var(--border) / 0.6); }
.border-border\/70 { border-color: hsl(var(--border) / 0.7); }
.border-blue-500\/30 { border-color: rgb(59 130 246 / 0.30); }
.border-blue-500\/40 { border-color: rgb(59 130 246 / 0.40); }
.border-blue-500\/50 { border-color: rgb(59 130 246 / 0.50); }
.border-destructive\/30 { border-color: hsl(var(--destructive) / 0.30); }
.border-destructive\/40 { border-color: hsl(var(--destructive) / 0.40); }
.border-dashed { border-style: dashed; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-2xl { border-radius: 1rem; }
.rounded-3xl { border-radius: 1.5rem; }
.rounded-full { border-radius: 9999px; }

/* ---- 文本大小 ---- */
.text-xs { font-size: 0.75rem; line-height: 1rem; }
.text-sm { font-size: 0.875rem; line-height: 1.25rem; }
.text-base { font-size: 1rem; line-height: 1.5rem; }
.text-lg { font-size: 1.125rem; line-height: 1.75rem; }
.text-xl { font-size: 1.25rem; line-height: 1.75rem; }
.text-2xl { font-size: 1.5rem; line-height: 2rem; }
.text-3xl { font-size: 1.875rem; line-height: 2.25rem; }
.text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
.text-5xl { font-size: 3rem; line-height: 1; }
.text-6xl { font-size: 3.75rem; line-height: 1; }

/* ---- 品牌渐变文字 ---- */
.text-gradient {
  background-image: linear-gradient(120deg, hsl(var(--brand)), hsl(var(--brand-2)));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---- 科技网格背景 ---- */
.bg-grid {
  background-image:
    linear-gradient(to right, hsl(var(--border) / 0.5) 1px, transparent 1px),
    linear-gradient(to bottom, hsl(var(--border) / 0.5) 1px, transparent 1px);
  background-size: 44px 44px;
}

/* ---- 极光光晕背景 ---- */
.bg-aurora {
  background:
    radial-gradient(60% 50% at 20% 10%, hsl(var(--brand) / 0.18), transparent 60%),
    radial-gradient(50% 50% at 85% 20%, hsl(var(--brand-2) / 0.16), transparent 60%),
    radial-gradient(60% 60% at 50% 100%, hsl(var(--brand) / 0.1), transparent 60%);
}

/* ---- 发光卡片 ---- */
.glow-brand {
  box-shadow:
    0 0 0 1px hsl(var(--brand) / 0.25),
    0 12px 40px -12px hsl(var(--brand) / 0.45);
}
.glow-soft { box-shadow: 0 18px 50px -20px rgba(0, 0, 0, 0.45); }

/* ---- 商品卡片悬浮 ---- */
.card-hover {
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.card-hover:hover {
  transform: translateY(-4px);
  border-color: hsl(var(--brand) / 0.5);
  box-shadow: 0 22px 50px -24px hsl(var(--brand) / 0.55);
}

/* ---- 动画 ---- */
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}
.animate-float { animation: float 6s ease-in-out infinite; }

@keyframes fade-up {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-fade-up { animation: fade-up 0.6s ease both; }

/* ---- 按钮 ---- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.375rem;
  border-radius: 0.5rem;
  font-weight: 500;
  font-size: 0.875rem;
  line-height: 1.25rem;
  padding: 0.5rem 1rem;
  transition: background-color 0.2s, color 0.2s, border-color 0.2s;
  border: 1px solid transparent;
  white-space: nowrap;
}
.btn:disabled { opacity: 0.5; cursor: not-allowed; }
.btn-primary { background: hsl(var(--primary)); color: hsl(var(--primary-foreground)); }
.btn-primary:hover:not(:disabled) { background: hsl(var(--primary) / 0.9); }
.btn-outline { border-color: hsl(var(--border)); background: transparent; color: hsl(var(--foreground)); }
.btn-outline:hover { background: hsl(var(--accent)); color: hsl(var(--accent-foreground)); }
.btn-ghost { background: transparent; color: hsl(var(--foreground)); }
.btn-ghost:hover { background: hsl(var(--accent)); color: hsl(var(--accent-foreground)); }
.btn-lg { padding: 0.625rem 1.5rem; font-size: 1rem; }
.btn-sm { padding: 0.375rem 0.75rem; font-size: 0.8125rem; }
.btn-icon { padding: 0.5rem; width: 2.25rem; height: 2.25rem; }
.btn-block { width: 100%; }

/* ---- 输入框 ---- */
.input {
  width: 100%;
  border: 1px solid hsl(var(--input));
  border-radius: 0.5rem;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  padding: 0.5rem 0.75rem;
  /* 16px 起步：避免 iOS Safari 聚焦输入框时自动放大页面造成晃动 */
  font-size: 1rem;
  line-height: 1.5;
  transition: border-color 0.2s, box-shadow 0.2s;
}
@media (min-width: 768px) {
  .input { font-size: 0.875rem; line-height: 1.25rem; }
}
.input:focus {
  outline: none;
  border-color: hsl(var(--ring));
  box-shadow: 0 0 0 2px hsl(var(--ring) / 0.25);
}
.input-error { border-color: hsl(var(--destructive)); }
.input::placeholder { color: hsl(var(--muted-foreground)); }

/* ---- 标签 ---- */
.label { display: block; font-size: 0.875rem; font-weight: 500; color: hsl(var(--foreground)); }

/* ---- 卡片 ---- */
.card {
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: 1rem;
  background: hsl(var(--card) / 0.5);
}

/* ---- 徽章 ---- */
.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 9999px;
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
}

/* ---- 分割线 ---- */
.separator { height: 1px; background: hsl(var(--border)); border: 0; margin: 1rem 0; }

/* ---- 提示条（toast）---- */
/* 提示条容器定位统一由文件末尾 TOKEN UNIFIED TOAST 层定义 */

/* ============================================================
   补充缺失工具类（与 React 版 Tailwind 一致）
   ============================================================ */

/* 显示 */
.block { display: block; }

/* 透明度背景 */
.bg-background\/60 { background: hsl(var(--background) / 0.6); }
.bg-background\/70 { background: hsl(var(--background) / 0.7); }
.bg-background\/80 { background: hsl(var(--background) / 0.8); }
.bg-blue-500\/5 { background: rgb(59 130 246 / 0.05); }
.bg-blue-500\/10 { background: rgb(59 130 246 / 0.10); }
.bg-blue-500\/15 { background: rgb(59 130 246 / 0.15); }
.bg-card\/50 { background: hsl(var(--card) / 0.5); }
.bg-card\/80 { background: hsl(var(--card) / 0.8); }
.bg-destructive\/5 { background: hsl(var(--destructive) / 0.05); }
.bg-emerald-500\/15 { background: rgb(16 185 129 / 0.15); }

/* 边框透明度 */
.border-border\/60 { border-color: hsl(var(--border) / 0.6); }
.border-border\/70 { border-color: hsl(var(--border) / 0.7); }
.border-blue-500\/30 { border-color: rgb(59 130 246 / 0.30); }
.border-blue-500\/40 { border-color: rgb(59 130 246 / 0.40); }
.border-destructive\/30 { border-color: hsl(var(--destructive) / 0.30); }
.border-destructive\/40 { border-color: hsl(var(--destructive) / 0.40); }

/* 文本 */
.text-primary-foreground { color: hsl(var(--primary-foreground)); }
.line-through { text-decoration: line-through; }
.list-decimal { list-style: decimal; }
.list-decimal > li { margin-bottom: 0.5rem; }
.placeholder\:text-muted-foreground::placeholder { color: hsl(var(--muted-foreground)); }

/* hover 交互 */
.hover\:text-foreground:hover { color: hsl(var(--foreground)); }
.hover\:underline:hover { text-decoration: underline; }
.hover\:bg-primary\/90:hover { background: hsl(var(--primary) / 0.9); }
.hover\:border-blue-500\/40:hover { border-color: rgb(59 130 246 / 0.40); }
.transition-colors { transition: color 0.2s, background-color 0.2s, border-color 0.2s; }

/* 表单控件 */
.accent-blue-500 { accent-color: #3b82f6; }

/* 定位 / 布局辅助 */
.place-items-center { place-items: center; }
.pointer-events-none { pointer-events: none; }
.left-3 { left: 0.75rem; }
.right-3 { right: 0.75rem; }
.top-1\/2 { top: 50%; }
.-translate-y-1\/2 { transform: translateY(-50%); }
.mt-auto { margin-top: auto; }
.mt-0\.5 { margin-top: 0.125rem; }
.mb-1 { margin-bottom: 0.25rem; }
.cursor-pointer { cursor: pointer; }

/* 尺寸 / 间距补充 */
.h-2 { height: 0.5rem; }
.h-full { height: 100%; }
.max-w-lg { max-width: 32rem; }
.gap-1\.5 { gap: 0.375rem; }
.gap-2\.5 { gap: 0.625rem; }
.gap-12 { gap: 3rem; }
.p-3 { padding: 0.75rem; }
.px-2 { padding-left: 0.5rem; padding-right: 0.5rem; }
.px-2\.5 { padding-left: 0.625rem; padding-right: 0.625rem; }
.py-0\.5 { padding-top: 0.125rem; padding-bottom: 0.125rem; }
.py-1\.5 { padding-top: 0.375rem; padding-bottom: 0.375rem; }
.py-2\.5 { padding-top: 0.625rem; padding-bottom: 0.625rem; }
.py-3 { padding-top: 0.75rem; padding-bottom: 0.75rem; }
.space-y-2\.5 > * + * { margin-top: 0.625rem; }
.rounded-md { border-radius: 0.375rem; }
.shadow-lg { box-shadow: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); }
.shadow-blue-500\/30 { box-shadow: 0 4px 6px -1px rgb(59 130 246 / 0.3), 0 2px 4px -2px rgb(59 130 246 / 0.3); }

/* 渐变 / 模糊 */
.bg-gradient-to-br { background-image: linear-gradient(to bottom right, var(--tw-gradient-stops)); }
.from-blue-500 { --tw-gradient-from: #3b82f6; --tw-gradient-stops: var(--tw-gradient-from), var(--tw-gradient-to, rgb(59 130 246 / 0)); }
.to-sky-400 { --tw-gradient-to: #38bdf8; }
.backdrop-blur { backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); }
.backdrop-blur-xl { backdrop-filter: blur(24px); -webkit-backdrop-filter: blur(24px); }

/* 响应式补充 */
@media (min-width: 640px) {
  .sm\:text-4xl { font-size: 2.25rem; line-height: 2.5rem; }
  .sm\:text-5xl { font-size: 3rem; line-height: 1; }
}
@media (min-width: 768px) {
  .md\:col-span-2 { grid-column: span 2 / span 2; }
}
@media (min-width: 1024px) {
  .lg\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .lg\:text-6xl { font-size: 3.75rem; line-height: 1; }
}
/* 提示条主体样式统一由文件末尾 TOKEN UNIFIED TOAST 层定义 */

/* ---- 折叠面板（FAQ）---- */
.accordion-item { border: 1px solid hsl(var(--border) / 0.7); border-radius: 0.75rem; overflow: hidden; }
.accordion-item + .accordion-item { margin-top: 0.75rem; }
.accordion-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  font-weight: 500;
  font-size: 1rem;
  background: transparent;
  border: 0;
  text-align: left;
  color: hsl(var(--foreground));
}
.accordion-trigger:hover { background: hsl(var(--accent) / 0.5); }
.accordion-content { padding: 0 1.25rem 1.25rem; font-size: 0.875rem; color: hsl(var(--muted-foreground)); }
.chevron { transition: transform 0.2s; }
.accordion-item.open .chevron { transform: rotate(180deg); }
.accordion-single .accordion-content { display: none; }
.accordion-single .accordion-item.open .accordion-content { display: block; }

/* ---- 响应式 ---- */
@media (min-width: 640px) {
  .sm\:flex { display: flex; }
  .sm\:inline-flex { display: inline-flex; }
  .sm\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .sm\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .sm\:flex-row { flex-direction: row; }
  .sm\:max-w-xs { max-width: 20rem; }
  .sm\:max-w-sm { max-width: 24rem; }
  .sm\:px-6 { padding-left: 1.5rem; padding-right: 1.5rem; }
  .sm\:items-start { align-items: flex-start; }
  .sm\:justify-between { justify-content: space-between; }
}

@media (min-width: 768px) {
  .md\:flex { display: flex; }
  .md\:hidden { display: none; }
  .md\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .md\:grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

@media (min-width: 1024px) {
  .lg\:block { display: block; }
  .lg\:grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .lg\:grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .lg\:grid-cols-5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .lg\:col-span-2 { grid-column: span 2 / span 2; }
  .lg\:col-span-3 { grid-column: span 3 / span 3; }
  .lg\:col-span-5 { grid-column: span 5 / span 5; }
  .lg\:py-28 { padding-top: 7rem; padding-bottom: 7rem; }
}

@media (prefers-reduced-motion: reduce) {
  .animate-float, .animate-fade-up { animation: none; }
  html { scroll-behavior: auto; }
}
/* HOTFIX: restore size utility selectors */
/* The escaped decimal utility block is ignored by some CSS parsers; attribute selectors are parser-safe. */
[class~="size-1.5"] { width: 0.375rem; height: 0.375rem; }
[class~="size-3.5"] { width: 0.875rem; height: 0.875rem; }
[class~="size-4"] { width: 1rem; height: 1rem; }
[class~="size-5"] { width: 1.25rem; height: 1.25rem; }
[class~="size-6"] { width: 1.5rem; height: 1.5rem; }
[class~="size-7"] { width: 1.75rem; height: 1.75rem; }
[class~="size-8"] { width: 2rem; height: 2rem; }
[class~="size-9"] { width: 2.25rem; height: 2.25rem; }
[class~="size-10"] { width: 2.5rem; height: 2.5rem; }
[class~="size-11"] { width: 2.75rem; height: 2.75rem; }
[class~="size-14"] { width: 3.5rem; height: 3.5rem; }
[class~="size-16"] { width: 4rem; height: 4rem; }
[class~="object-cover"] { object-fit: cover; }
/* HOTFIX: brand lockup */
.brand-lockup { display: flex; flex-direction: column; min-width: 0; line-height: 1.1; }
.brand-subtitle { margin-top: 0.125rem; color: hsl(var(--muted-foreground)); font-size: 0.7rem; font-weight: 500; letter-spacing: 0.02em; white-space: nowrap; }
[class~="mt-0.5"] { margin-top: 0.125rem; }
@media (max-width: 639px) {
  .brand-subtitle { font-size: 0.65rem; }
}
/* ============================================================
   CLOSED LOOP UI - theme/menu controls and FAQ
   ============================================================ */
.theme-toggle,
.menu-toggle {
  appearance: none;
  border: 1px solid hsl(var(--border) / 0.9);
  background: hsl(var(--card) / 0.78);
  color: hsl(var(--muted-foreground));
  box-shadow: 0 10px 26px -18px rgb(15 23 42 / 0.72);
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease,
    box-shadow 0.2s ease, transform 0.2s ease;
}
.theme-toggle:hover,
.menu-toggle:hover {
  border-color: hsl(var(--primary) / 0.5);
  background: hsl(var(--accent) / 0.82);
  color: hsl(var(--primary));
  box-shadow: 0 14px 28px -20px hsl(var(--primary) / 0.8);
}
.theme-toggle:focus-visible,
.menu-toggle:focus-visible {
  outline: 2px solid hsl(var(--ring));
  outline-offset: 2px;
}
.theme-toggle:active,
.menu-toggle:active { transform: translateY(1px); }
.theme-toggle[aria-pressed="true"] {
  border-color: hsl(var(--primary) / 0.45);
  background: hsl(var(--primary) / 0.1);
  color: hsl(var(--primary));
}
.mobile-menu {
  background: hsl(var(--background) / 0.96);
  box-shadow: 0 18px 34px -26px rgb(15 23 42 / 0.75);
}
.mobile-menu a { transition: background-color 0.2s ease, color 0.2s ease; }
.mobile-menu a:hover,
.mobile-menu a:focus-visible {
  background: hsl(var(--accent) / 0.82);
  color: hsl(var(--accent-foreground));
}
.mobile-menu a:focus-visible { outline: 2px solid hsl(var(--ring)); outline-offset: -2px; }

.faq-section {
  background:
    linear-gradient(180deg, hsl(var(--background)), hsl(var(--muted) / 0.28));
}
.faq-grid { display: grid; gap: 2.5rem; }
.faq-intro { max-width: 30rem; }
.faq-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  color: hsl(var(--primary));
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.faq-kicker::before {
  content: "";
  width: 1.5rem;
  height: 1px;
  background: hsl(var(--primary) / 0.6);
}
.faq-proof {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  margin-top: 1.5rem;
  border: 1px solid hsl(var(--border) / 0.8);
  border-radius: 9999px;
  padding: 0.625rem 0.875rem;
  background: hsl(var(--card) / 0.7);
  color: hsl(var(--muted-foreground));
  font-size: 0.8125rem;
  font-weight: 600;
}
.faq-proof svg { color: hsl(var(--primary)); }
.faq-list { margin-top: 0; }
.faq-list .accordion-item {
  background: hsl(var(--card) / 0.64);
  transition: border-color 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
}
.faq-list .accordion-item:hover,
.faq-list .accordion-item.open {
  border-color: hsl(var(--primary) / 0.42);
  background: hsl(var(--card) / 0.9);
  box-shadow: 0 16px 34px -28px hsl(var(--primary) / 0.75);
}
.faq-list .accordion-trigger { gap: 1rem; min-height: 4.5rem; }
.faq-trigger-main { display: inline-flex; align-items: center; gap: 0.875rem; min-width: 0; }
.faq-icon {
  display: inline-grid;
  width: 2rem;
  height: 2rem;
  flex: 0 0 2rem;
  place-items: center;
  border: 1px solid hsl(var(--primary) / 0.22);
  border-radius: 0.625rem;
  background: hsl(var(--primary) / 0.1);
  color: hsl(var(--primary));
}
.faq-icon svg { width: 1rem; height: 1rem; }
.faq-list .accordion-content { padding: 0 1.25rem 1.25rem 4.25rem; line-height: 1.75; }
.faq-list .chevron { color: hsl(var(--primary)); }

html.dark .theme-toggle,
html.dark .menu-toggle { background: hsl(var(--card) / 0.88); }
html.dark .faq-section {
  background: linear-gradient(180deg, hsl(var(--background)), hsl(var(--card) / 0.58));
}

@media (min-width: 1024px) {
  .faq-grid { grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr); align-items: start; gap: 4rem; }
}
@media (max-width: 639px) {
  .faq-list .accordion-trigger { min-height: 4rem; padding-left: 1rem; padding-right: 1rem; }
  .faq-list .accordion-content { padding-left: 1rem; padding-right: 1rem; }
  .faq-proof { max-width: 100%; border-radius: 0.75rem; }
}
/* CLOSED LOOP hidden precedence: the icon utility also has a display class. */
.icon-moon.hidden, .icon-sun.hidden { display: none !important; }
/* ============================================================
   TOKEN ADMIN UI
   ============================================================ */
.admin-layout { display: grid; gap: 1.5rem; width: 100%; }
.admin-sidebar { align-self: start; }
.admin-nav { display: flex; gap: 0.375rem; overflow-x: auto; }
.admin-nav-link { display: inline-flex; align-items: center; gap: 0.625rem; min-height: 2.5rem; border-radius: 0.625rem; padding: 0.625rem 0.75rem; color: hsl(var(--muted-foreground)); font-size: 0.875rem; font-weight: 600; white-space: nowrap; transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease; }
.admin-nav-link:hover, .admin-nav-link:focus-visible { background: hsl(var(--accent) / 0.75); color: hsl(var(--foreground)); outline: none; }
.admin-nav-link-active { background: hsl(var(--primary) / 0.1); color: hsl(var(--primary)); }
.admin-content { min-width: 0; width: 100%; }
.admin-auth-shell { min-height: calc(100vh - 4rem); display: grid; align-items: start; }
.admin-auth-panel { box-shadow: 0 24px 60px -44px hsl(var(--primary) / 0.7); }
.admin-stat-grid { display: grid; gap: 1rem; }
.admin-stat { display: flex; min-height: 8.5rem; flex-direction: column; justify-content: space-between; border: 1px solid hsl(var(--border) / 0.75); border-radius: 1rem; background: hsl(var(--card) / 0.65); padding: 1.25rem; }
.admin-stat strong { font-size: 2rem; line-height: 1; letter-spacing: -0.04em; }
.admin-stat small { color: hsl(var(--muted-foreground)); font-size: 0.75rem; }
.admin-form-panel { box-shadow: 0 20px 50px -44px hsl(var(--primary) / 0.55); }
.admin-form-grid { display: grid; gap: 1rem; }
.admin-form-wide { grid-column: 1 / -1; }
.admin-table-wrap { max-width: 100%; overflow-x: auto; -webkit-overflow-scrolling: touch; }
.admin-table { width: 100%; min-width: 64rem; border-collapse: collapse; font-size: 0.875rem; table-layout: auto; }
.admin-table th { background: hsl(var(--muted) / 0.55); color: hsl(var(--muted-foreground)); font-size: 0.75rem; font-weight: 700; letter-spacing: 0.04em; text-align: left; text-transform: uppercase; }
.admin-table th, .admin-table td { border-bottom: 1px solid hsl(var(--border) / 0.65); padding: 0.875rem 1rem; vertical-align: top; overflow-wrap: normal; word-break: normal; }
.admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-table tbody tr:hover { background: hsl(var(--accent) / 0.35); }
.admin-table td strong, .admin-table td small { display: block; }
.admin-table td small { margin-top: 0.25rem; color: hsl(var(--muted-foreground)); font-size: 0.75rem; }
.admin-status { display: inline-flex; align-items: center; border-radius: 9999px; padding: 0.25rem 0.625rem; font-size: 0.75rem; font-weight: 700; white-space: nowrap; }
.admin-status-ok { background: rgb(16 185 129 / 0.14); color: #047857; }
.admin-status-muted { background: hsl(var(--muted)); color: hsl(var(--muted-foreground)); }
.admin-empty { color: hsl(var(--muted-foreground)); padding: 2rem 1rem !important; text-align: center; }
html.dark .admin-status-ok { color: #6ee7b7; }
@media (min-width: 640px) {
  .admin-stat-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .admin-form-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (min-width: 1180px) {
  .admin-layout { grid-template-columns: 14rem minmax(0, 1fr); align-items: start; }
  .admin-nav { flex-direction: column; overflow-x: visible; }
  .admin-sidebar { position: sticky; top: 5.5rem; }
}
/* TOKEN ADMIN SETTINGS */
.admin-page-heading { max-width: none; }
.admin-settings-grid { display: grid; gap: 1rem; }
.admin-setting-card { border: 1px solid hsl(var(--border) / 0.72); border-radius: 1rem; background: hsl(var(--card) / 0.72); padding: 1.25rem; }
.admin-setting-card-wide { grid-column: 1 / -1; }
.admin-setting-heading { display: flex; align-items: flex-start; gap: 0.75rem; }
.admin-setting-heading h2 { color: hsl(var(--foreground)); font-size: 1rem; font-weight: 700; line-height: 1.4; }
.admin-setting-heading p { margin-top: 0.25rem; color: hsl(var(--muted-foreground)); font-size: 0.8125rem; line-height: 1.5; }
.admin-setting-icon { display: inline-grid; width: 2.25rem; height: 2.25rem; flex: 0 0 2.25rem; place-items: center; border: 1px solid hsl(var(--primary) / 0.22); border-radius: 0.75rem; background: hsl(var(--primary) / 0.1); color: hsl(var(--primary)); }
.admin-setting-icon svg { width: 1.125rem; height: 1.125rem; }
.admin-settings-fields { display: grid; gap: 1rem; margin-top: 1.25rem; }
.admin-field-block { min-width: 0; }
.admin-field-help { margin-top: 0.45rem; color: hsl(var(--muted-foreground)); font-size: 0.78rem; line-height: 1.55; }
.admin-quota-editor { margin-top: 1.25rem; }
.admin-quota-head { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 2.75rem; padding: 0 0.75rem 0.5rem; color: hsl(var(--muted-foreground)); font-size: 0.72rem; font-weight: 700; letter-spacing: 0.05em; text-transform: uppercase; }
.admin-quota-row { display: grid; grid-template-columns: minmax(0, 1fr) 1.5rem minmax(0, 1fr) auto; gap: 0.75rem; align-items: end; margin-top: 0.625rem; border: 1px solid hsl(var(--border) / 0.72); border-radius: 0.875rem; background: hsl(var(--background) / 0.62); padding: 0.75rem; }
.admin-quota-field { min-width: 0; }
.admin-quota-arrow { display: grid; width: 1.5rem; height: 2.5rem; place-items: center; color: hsl(var(--primary)); }
.admin-quota-arrow svg { width: 1rem; height: 1rem; }
.admin-quota-remove { color: hsl(var(--muted-foreground)); }
.admin-quota-remove:hover, .admin-quota-remove:focus-visible { color: hsl(var(--destructive)); }
.admin-quota-remove svg, [data-quota-add] svg { width: 1rem; height: 1rem; }
.admin-quota-footer { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-top: 0.75rem; }
@media (min-width: 640px) {
  .admin-settings-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 639px) {
  .admin-setting-card { padding: 1rem; }
  .admin-quota-head { display: none; }
  .admin-quota-row { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) auto; gap: 0.5rem; }
  .admin-quota-arrow { display: none; }
  .admin-quota-remove { padding: 0.55rem; }
  .admin-quota-remove span { display: none; }
  .admin-quota-footer { align-items: flex-start; flex-direction: column; }
}

/* TOKEN CONTENT MANAGEMENT */
.admin-content-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(250px,.34fr);gap:1.25rem;align-items:start}
.admin-content-main{display:grid;gap:1.25rem;min-width:0}
.admin-content-group{min-width:0}
.admin-content-group-heading{display:flex;align-items:flex-start;gap:.75rem;padding-bottom:1.1rem;border-bottom:1px solid hsl(var(--border)/.7)}
.admin-content-group-heading h2{font-size:1.05rem;font-weight:700;line-height:1.4}
.admin-content-group-heading p{margin-top:.25rem;font-size:.8rem;color:hsl(var(--muted-foreground))}
.admin-content-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem;margin-top:1.1rem}
.admin-content-field{min-width:0}
.admin-content-field-wide{grid-column:1/-1}
.admin-content-field .label{display:block;font-size:.84rem;font-weight:600}
.admin-content-textarea{min-height:5.25rem;resize:vertical;line-height:1.6}
.admin-content-key{display:block;margin-top:.35rem;font:500 .68rem/1.2 ui-monospace,SFMono-Regular,Menlo,monospace;color:hsl(var(--muted-foreground));overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.admin-content-aside{position:sticky;top:1rem}
.admin-content-audit{border-top:1px solid hsl(var(--border)/.55);padding-top:1rem}
.admin-content-actions{display:flex;align-items:center;gap:.75rem;margin-top:1.25rem;padding:1rem 0 .25rem}
@media (max-width:1100px){.admin-content-layout{grid-template-columns:1fr}.admin-content-aside{position:static}.admin-content-fields{grid-template-columns:1fr}.admin-content-field-wide{grid-column:auto}}
@media (max-width:520px){.admin-content-actions{align-items:flex-start;flex-direction:column}}
/* TOKEN HERO VISUAL ALIGNMENT */
/* Keep the first screen on the same surface as the site and header. */
.bg-aurora {
  background-color: hsl(var(--background));
  background-image: none;
}
header.sticky.top-0 {
  background-color: hsl(var(--background)) !important;
  backdrop-filter: none;
}
.mobile-menu {
  background-color: hsl(var(--background)) !important;
}
.theme-toggle,
.menu-toggle {
  background-color: hsl(var(--background));
}
.bg-aurora .animate-fade-up > h1 {
  margin-top: clamp(2.5rem, 5vw, 4rem);
  margin-bottom: clamp(2.25rem, 4vw, 3.5rem);
}
@media (max-width: 639px) {
  .bg-aurora .animate-fade-up > h1 {
    margin-top: 2.75rem;
    margin-bottom: 2.5rem;
  }
}
/* TOKEN HERO VERTICAL RHYTHM V2 */
/* Separate the two title lines from the outer hero spacing. */
.bg-aurora {
  padding-block-start: clamp(5.5rem, 9vw, 8.5rem);
  padding-block-end: clamp(5rem, 8vw, 8rem);
}
.bg-aurora .animate-fade-up > h1 {
  line-height: 1.34;
  margin-top: clamp(2.75rem, 5.5vw, 4.5rem);
  margin-bottom: clamp(2.5rem, 4.5vw, 3.75rem);
}
@media (max-width: 639px) {
  .bg-aurora {
    padding-block-start: 5.5rem;
    padding-block-end: 5.5rem;
  }
  .bg-aurora .animate-fade-up > h1 {
    line-height: 1.34;
    margin-top: 3rem;
    margin-bottom: 2.75rem;
  }
}
/* TOKEN HERO TITLE-ONLY SPACING */
/* Keep the original hero/menu relationship; increase only the gap between title lines. */
.bg-aurora {
  padding-block-start: 5rem;
  padding-block-end: 5rem;
}
.bg-aurora .animate-fade-up > h1 {
  line-height: 1.34;
  margin-top: 1.25rem;
  margin-bottom: 0;
}
@media (min-width: 1024px) {
  .bg-aurora {
    padding-block-start: 7rem;
    padding-block-end: 7rem;
  }
}
@media (max-width: 639px) {
  .bg-aurora {
    padding-block-start: 5rem;
    padding-block-end: 5rem;
  }
  .bg-aurora .animate-fade-up > h1 {
    line-height: 1.34;
    margin-top: 1.25rem;
    margin-bottom: 0;
  }
}
/* TOKEN HERO OUTER PADDING RESET */
/* The inner hero grid already owns the original vertical rhythm; remove the duplicate section padding. */
.bg-aurora {
  padding-block-start: 0;
  padding-block-end: 0;
}
/* TOKEN ORDER INPUT ALIGNMENT */
/* Restore the icon-to-placeholder spacing after the base .input padding rule. */
.input.pl-9 {
  padding-left: 2.25rem;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* PACKAGE DETAIL PURCHASE FLOW */
.package-detail-shell { padding-top: 2rem; padding-bottom: 4rem; }
.package-backlink { margin-bottom: 1.25rem; }
.package-detail-grid { display: grid; gap: 1.5rem; align-items: start; }
.package-overview-panel,
.package-checkout-panel {
  border: 1px solid hsl(var(--border) / 0.78);
  border-radius: 1.25rem;
  background: hsl(var(--card) / 0.72);
}
.package-overview-panel { padding: clamp(1.25rem, 3vw, 2rem); }
.package-overview-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 1.5rem; }
.package-type-badge,
.package-checkout-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  border-radius: 9999px;
  background: hsl(var(--primary) / 0.1);
  color: hsl(var(--primary));
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.35rem 0.7rem;
}
.package-badge-icon { width: 0.9rem; height: 0.9rem; flex: 0 0 0.9rem; }
.package-overview-title { margin: 1rem 0 0; font-size: clamp(2rem, 4vw, 3rem); line-height: 1.15; letter-spacing: -0.035em; }
.package-overview-subtitle { margin: 0.65rem 0 0; color: hsl(var(--muted-foreground)); font-size: 1rem; line-height: 1.65; }
.package-price-block { display: flex; flex-shrink: 0; align-items: baseline; gap: 0.55rem; padding-top: 0.25rem; }
.package-price { color: hsl(var(--primary)); font-size: clamp(2rem, 4vw, 2.75rem); font-weight: 800; letter-spacing: -0.04em; }
.package-original-price { color: hsl(var(--muted-foreground)); font-size: 0.95rem; text-decoration: line-through; }
.package-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem; margin: 1.75rem 0 0; }
.package-metric { min-width: 0; border: 1px solid hsl(var(--border) / 0.72); border-radius: 1rem; background: hsl(var(--background) / 0.72); padding: 1rem; }
.package-metric dt { display: flex; align-items: center; gap: 0.4rem; color: hsl(var(--muted-foreground)); font-size: 0.8rem; }
.package-metric-icon { width: 1rem; height: 1rem; flex: 0 0 1rem; color: hsl(var(--primary)); }
.package-metric dd { margin: 0.35rem 0 0; color: hsl(var(--foreground)); font-size: 1.2rem; font-weight: 700; }
.package-metric span { display: block; margin-top: 0.35rem; color: hsl(var(--muted-foreground)); font-size: 0.75rem; }
.package-benefits { margin-top: 1.75rem; border-top: 1px solid hsl(var(--border) / 0.72); padding-top: 1.5rem; }
.package-section-label { display: flex; align-items: center; gap: 0.45rem; color: hsl(var(--foreground)); font-size: 1rem; font-weight: 700; }
.package-section-label-icon { width: 1.15rem; height: 1.15rem; flex: 0 0 1.15rem; color: hsl(var(--primary)); }
.package-detail-intro { margin: 0.7rem 0 0; color: hsl(var(--muted-foreground)); font-size: 0.875rem; line-height: 1.65; }
.package-feature-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.75rem 1.25rem; margin: 1rem 0 0; padding: 0; list-style: none; }
.package-feature-item { display: flex; align-items: flex-start; gap: 0.55rem; min-width: 0; color: hsl(var(--muted-foreground)); font-size: 0.875rem; line-height: 1.55; }
.package-feature-icon { width: 1rem; height: 1rem; flex: 0 0 1rem; margin-top: 0.2rem; color: hsl(var(--primary)); }
.package-trust-note { display: flex; align-items: center; gap: 0.55rem; margin-top: 1.75rem; border-radius: 0.875rem; background: hsl(var(--primary) / 0.07); color: hsl(var(--primary)); padding: 0.75rem 0.875rem; font-size: 0.8rem; font-weight: 600; }
.package-checkout-panel { padding: 1.25rem; }
.package-checkout-heading h2 { margin: 0.75rem 0 0; font-size: 1.35rem; line-height: 1.35; }
.package-checkout-heading p { margin: 0.45rem 0 0; color: hsl(var(--muted-foreground)); font-size: 0.85rem; line-height: 1.6; }
.package-order-summary { margin: 1.25rem 0; border-top: 1px solid hsl(var(--border) / 0.72); border-bottom: 1px solid hsl(var(--border) / 0.72); }
.package-order-summary > div { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; padding: 0.75rem 0; }
.package-order-summary dt { color: hsl(var(--muted-foreground)); font-size: 0.82rem; }
.package-order-summary dd { margin: 0; color: hsl(var(--foreground)); font-size: 0.9rem; font-weight: 600; text-align: right; }
.package-order-total { border-top: 1px dashed hsl(var(--border) / 0.85); }
.package-order-total dd { color: hsl(var(--primary)); font-size: 1.4rem; font-weight: 800; }
.package-checkout-form { display: grid; gap: 1rem; }
.package-field { min-width: 0; border: 0; margin: 0; padding: 0; }
.package-field-help { margin: 0.4rem 0 0; color: hsl(var(--muted-foreground)); font-size: 0.75rem; line-height: 1.5; }
.package-payment-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0.6rem; }
.package-payment-option { display: flex; align-items: center; gap: 0.55rem; min-height: 2.75rem; border: 1px solid hsl(var(--border) / 0.9); border-radius: 0.75rem; padding: 0.65rem 0.75rem; color: hsl(var(--foreground)); font-size: 0.85rem; font-weight: 600; cursor: pointer; transition: border-color 0.2s ease, background-color 0.2s ease; }
.package-payment-option:has(input:checked) { border-color: hsl(var(--primary) / 0.7); background: hsl(var(--primary) / 0.08); color: hsl(var(--primary)); }
.package-payment-option input { accent-color: hsl(var(--primary)); }
.package-error { display: flex; align-items: flex-start; gap: 0.55rem; border: 1px solid hsl(var(--destructive) / 0.35); border-radius: 0.75rem; background: hsl(var(--destructive) / 0.06); color: hsl(var(--destructive)); padding: 0.75rem; font-size: 0.8rem; line-height: 1.5; }
.package-checkout-footnote { margin: 1rem 0 0; color: hsl(var(--muted-foreground)); font-size: 0.75rem; line-height: 1.6; }
@media (min-width: 768px) {
  .package-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .package-detail-grid { grid-template-columns: minmax(0, 1.35fr) minmax(20rem, 0.65fr); gap: 1.75rem; }
  .package-checkout-panel { position: sticky; top: 5.5rem; }
}
@media (max-width: 767px) {
  .package-overview-top { flex-direction: column; }
  .package-price-block { padding-top: 0.5rem; }
}
@media (max-width: 639px) {
  .package-detail-shell { padding-top: 1.25rem; padding-bottom: 2.5rem; }
  .package-overview-panel, .package-checkout-panel { border-radius: 1rem; padding: 1rem; }
  .package-metrics, .package-feature-list, .package-payment-grid { grid-template-columns: 1fr; }
}

.usage-token-field {
  min-width: 0;
}
.usage-token-icon {
  position: absolute;
  left: 0.875rem;
  top: 50%;
  z-index: 1;
  width: 1.125rem;
  height: 1.125rem;
  color: hsl(var(--muted-foreground));
  pointer-events: none;
  transform: translateY(-50%);
}
.usage-token-toggle {
  position: absolute;
  top: 50%;
  right: 0.625rem;
  display: inline-flex;
  width: 2rem;
  height: 2rem;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 0.625rem;
  background: transparent;
  color: hsl(var(--muted-foreground));
  cursor: pointer;
  transform: translateY(-50%);
  transition: background-color 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.usage-token-toggle:hover {
  border-color: hsl(var(--border));
  background: hsl(var(--muted));
  color: hsl(var(--foreground));
}
.usage-token-toggle:focus-visible {
  outline: 2px solid hsl(var(--ring));
  outline-offset: 2px;
}
.usage-token-toggle svg {
  width: 1.125rem;
  height: 1.125rem;
}


/* TOKEN INPUT ICON SPACING */
.input.pl-10 {
  padding-left: 2.75rem;
}
.input.pr-12 {
  padding-right: 3.25rem;
}




/* DISCOUNT CHECKOUT */
.package-field-icon { width: 1rem; height: 1rem; flex: 0 0 1rem; color: hsl(var(--primary)); }
.package-coupon-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 0.6rem; }
.package-coupon-row .btn { min-width: 4.5rem; }
.package-payment-icon { display: inline-grid; width: 1.25rem; height: 1.25rem; flex: 0 0 1.25rem; place-items: center; color: hsl(var(--primary)); }
.package-payment-icon svg { width: 1.125rem; height: 1.125rem; }
.package-order-discount-row dd { color: hsl(var(--muted-foreground)); }
.package-discount-value { color: #059669 !important; }
.package-checkout-panel { box-shadow: 0 18px 42px -36px hsl(var(--primary) / 0.7); }
.package-checkout-panel .input:focus { border-color: hsl(var(--primary) / 0.7); box-shadow: 0 0 0 3px hsl(var(--primary) / 0.12); outline: none; }
@media (min-width: 768px) {
  .package-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (min-width: 1024px) {
  .package-detail-grid { grid-template-columns: minmax(0, 1.1fr) minmax(24rem, 0.9fr); }
}
@media (max-width: 639px) {
  .package-metrics,
  .package-feature-list,
  .package-payment-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .package-metric { padding: 0.8rem; }
  .package-metric dd { font-size: 1.05rem; }
  .package-metric span { font-size: 0.7rem; }
  .package-feature-list { gap: 0.55rem 0.8rem; }
  .package-feature-item { gap: 0.4rem; font-size: 0.78rem; }
  .package-payment-option { padding: 0.6rem; font-size: 0.8rem; }
}

/* BUY PAGE LAYOUT */
.buy-page {
  padding-top: clamp(3rem, 4vw, 3.5rem);
  padding-bottom: clamp(3rem, 6vw, 5rem);
}
.buy-layout {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.buy-flow {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}
.buy-flow-step {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: 0.875rem;
  background: hsl(var(--card) / 0.5);
  padding: 1rem 1.1rem;
}
.buy-flow-index {
  display: inline-grid;
  width: 1.5rem;
  height: 1.5rem;
  flex: 0 0 1.5rem;
  place-items: center;
  border-radius: 9999px;
  background: hsl(var(--primary) / 0.12);
  color: hsl(var(--primary));
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
}
.buy-flow-step strong {
  display: block;
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.4;
}
.buy-flow-step p {
  margin: 0.2rem 0 0;
  color: hsl(var(--muted-foreground));
  font-size: 0.8125rem;
  line-height: 1.5;
}
@media (min-width: 768px) {
  .buy-flow {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.buy-summary-card {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: 1rem;
  background: hsl(var(--card) / 0.5);
}
.buy-summary-item {
  display: flex;
  min-width: 0;
  min-height: 3.75rem;
  flex-direction: column;
  justify-content: center;
  gap: 0.2rem;
  padding: 0.65rem 0.85rem;
}
.buy-summary-item:nth-child(even) { border-left: 1px solid hsl(var(--border) / 0.7); }
.buy-summary-item:nth-child(n + 3) { border-top: 1px solid hsl(var(--border) / 0.7); }
.buy-summary-label {
  color: hsl(var(--muted-foreground));
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  line-height: 1.35;
}
.buy-summary-item strong {
  color: hsl(var(--foreground));
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1.35;
  overflow-wrap: anywhere;
}
@media (min-width: 640px) {
  .buy-summary-card { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .buy-summary-item:nth-child(even) { border-left: 0; }
  .buy-summary-item + .buy-summary-item { border-left: 1px solid hsl(var(--border) / 0.7); }
  .buy-summary-item:nth-child(n + 3) { border-top: 0; }
}

.buy-rule-note {
  margin: 0;
  border-left: 3px solid hsl(var(--primary) / 0.5);
  padding-left: 0.85rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.8125rem;
  line-height: 1.6;
}
.buy-rule-note span { color: hsl(0 72% 51%); }

.buy-scope-note {
  margin: 0 0 1.25rem;
  border: 1px dashed hsl(var(--border) / 0.8);
  border-radius: 0.75rem;
  background: hsl(var(--card) / 0.4);
  padding: 0.6rem 0.85rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.8125rem;
  line-height: 1.6;
}

.buy-checkout-form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  border: 1px solid hsl(var(--border) / 0.7);
  border-radius: 1rem;
  background: hsl(var(--card) / 0.5);
  padding: 1.25rem;
}
.buy-checkout-form .label {
  font-size: 0.875rem;
  font-weight: 500;
}
.buy-checkout-form .input {
  min-height: 2.75rem;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  border-radius: 0.5rem;
  /* 字号继承 .input 基础规则，移动端 16px 防止 iOS 聚焦缩放 */
}
.buy-scope-note + .grid,
.buy-checkout-form > .grid {
  margin-top: 0.25rem;
}
.buy-field-stack {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}
.buy-discount-positive {
  color: #ea580c;
}
.buy-discount-summary-head {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.75rem;
  color: hsl(var(--foreground));
  font-size: 0.875rem;
  font-weight: 600;
}
.buy-discount-summary-head svg {
  width: 1rem;
  height: 1rem;
  color: hsl(var(--primary));
}
.buy-direct-payment-note {
  color: #ea580c;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.5;
}
.buy-member-field {
  min-width: 0;
}
.buy-coupon-field {
  min-width: 0;
}
.buy-input-wrap {
  position: relative;
  margin-top: 0.75rem;
}
.buy-input-icon {
  position: absolute;
  top: 50%;
  left: 0.75rem;
  z-index: 1;
  width: 1rem;
  height: 1rem;
  transform: translateY(-50%);
  color: hsl(var(--primary));
  pointer-events: none;
}
.buy-input-with-icon {
  padding-left: 2.5rem !important;
}
.coupon-input-wrap {
  position: relative;
  margin-top: 0.75rem;
}
.coupon-input-wrap .input {
  padding-left: 2.5rem;
  padding-right: 8.5rem;
}
.coupon-verify-button {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  top: 50%;
  right: 0.5rem;
  min-height: 2rem;
  transform: translateY(-50%);
  border: 1px solid hsl(var(--primary));
  border-radius: 0.5rem;
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  padding: 0.4rem 0.7rem;
  font-size: 0.75rem;
  font-weight: 600;
  white-space: nowrap;
  transition: background-color 0.2s ease, color 0.2s ease;
}
.coupon-verify-button svg {
  width: 0.95rem;
  height: 0.95rem;
  flex: 0 0 0.95rem;
}
.coupon-verify-button:hover {
  background: hsl(var(--primary) / 0.88);
  color: hsl(var(--primary-foreground));
}
.coupon-verify-button:focus-visible {
  outline: 2px solid hsl(var(--ring));
  outline-offset: 2px;
}
.buy-coupon-field [data-discount-state] {
  min-height: 1.25rem;
}
/* .buy-section-title 已由 .section-title 取代 */
@media (min-width: 768px) {
  .buy-checkout-form { padding: 1.5rem 1.75rem; }
}


/* TOKEN ORDER INPUT SCALE */
#order-query-form .input {
  min-height: 2.75rem;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  border-radius: 0.5rem;
  /* 字号继承 .input 基础规则，移动端 16px 防止 iOS 聚焦缩放 */
}
#order-query-form .input.pl-9 {
  padding-left: 2.5rem;
}
#order-query-form .relative > svg {
  width: 1rem;
  height: 1rem;
}

/* USAGE QUERY INPUT SCALE */
#usage-query-form .input {
  min-height: 2.75rem;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  border-radius: 0.5rem;
  /* 字号继承 .input 基础规则，移动端 16px 防止 iOS 聚焦缩放 */
}
#usage-query-form .input.pl-10 {
  padding-left: 2.5rem;
}
#usage-query-form .usage-token-icon {
  left: 0.75rem;
  width: 1rem;
  height: 1rem;
}

/* TOKEN ORDER RESULT LAYOUT */
.order-result-card { overflow: hidden; }
.order-result-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; flex-wrap: wrap; }
.order-result-title { min-width: 0; flex: 1 1 16rem; }
.order-result-name { display: flex; align-items: center; gap: 0.5rem; min-width: 0; font-weight: 700; line-height: 1.4; }
.order-result-name > span { min-width: 0; overflow-wrap: anywhere; }
.order-result-icon { flex: 0 0 1.125rem; color: hsl(var(--primary)); }
.order-result-meta, .order-result-email { margin-top: 0.35rem; color: hsl(var(--muted-foreground)); font-size: 0.8rem; line-height: 1.5; overflow-wrap: anywhere; }
.order-result-status { flex: 0 0 auto; white-space: nowrap; }
.order-result-summary { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0.75rem; margin-top: 1.25rem; }
.order-result-metric { min-width: 0; padding: 0.75rem; border: 1px solid hsl(var(--border) / 0.72); border-radius: 0.75rem; background: hsl(var(--muted) / 0.16); }
.order-result-metric > span { display: block; color: hsl(var(--muted-foreground)); font-size: 0.75rem; line-height: 1.4; }
.order-result-metric > strong { display: block; margin-top: 0.25rem; color: hsl(var(--foreground)); font-size: 0.95rem; line-height: 1.4; overflow-wrap: anywhere; }
.order-result-metric[data-order-discount] > strong { color: #059669; }
.order-result-notice { display: flex; align-items: flex-start; gap: 0.75rem; margin-top: 1rem; padding: 1rem; border-radius: 0.75rem; }
.order-result-notice > svg { flex: 0 0 1.25rem; margin-top: 0.125rem; }
.order-result-notice-copy { min-width: 0; line-height: 1.5; }
.order-result-notice-success { border: 1px solid hsl(142 71% 45% / 0.3); background: hsl(142 71% 45% / 0.06); color: hsl(142 71% 35%); }
.order-result-notice-pending { border: 1px solid hsl(38 92% 50% / 0.3); background: hsl(38 92% 50% / 0.06); color: hsl(38 80% 38%); }
.order-result-notice-info { border: 1px solid hsl(var(--primary) / 0.3); background: hsl(var(--primary) / 0.06); color: hsl(var(--primary)); }
.order-result-actions { display: flex; justify-content: flex-end; margin-top: 1rem; }
@media (max-width: 767px) {
  .order-result-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .order-result-status { margin-left: auto; }
}
@media (max-width: 520px) {
  .order-result-summary { grid-template-columns: 1fr; }
  .order-result-actions .btn { width: 100%; justify-content: center; }
}


/* Header responsive utilities */
@media (min-width: 1180px) {
  .lg\:flex { display: flex; }
  .lg\:hidden { display: none; }
  .lg\:inline-flex { display: inline-flex; }
}


/* ============================================================
   TOKEN UNIFIED TOAST - BALANCED TRANSLUCENT DIALOG
   中性轻遮罩 + 半实色卡片 + 全中轴布局
   ============================================================ */
.toast-container {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  width: auto;
  padding: 1rem;
  transform: none;
  pointer-events: none;
}
.toast-container:has(.toast) {
  background: rgb(15 23 42 / 0.06);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}
html.dark .toast-container:has(.toast) {
  background: rgb(0 0 0 / 0.16);
}
.toast {
  position: relative;
  display: flex;
  width: min(100%, 22rem);
  box-sizing: border-box;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
  padding: 1.3rem 1.2rem 1.05rem;
  overflow: hidden;
  border: 1px solid hsl(var(--primary) / 0.14);
  border-radius: 0.875rem;
  background: hsl(var(--muted));
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  color: hsl(var(--foreground));
  text-align: center;
  box-shadow: 0 18px 50px -34px rgb(15 23 42 / 0.5);
  animation: token-toast-in 0.18s cubic-bezier(0.22, 1, 0.36, 1) both;
  pointer-events: auto;
}
html.dark .toast {
  border-color: hsl(var(--primary) / 0.18);
  background: hsl(var(--muted));
  box-shadow: 0 20px 54px -34px rgb(0 0 0 / 0.68);
}
.toast-icon {
  display: inline-flex;
  width: 2.375rem;
  height: 2.375rem;
  flex: 0 0 2.375rem;
  align-items: center;
  justify-content: center;
  border-radius: 9999px;
  background: hsl(var(--primary) / 0.09);
  color: hsl(var(--primary));
}
.toast-error .toast-icon {
  background: hsl(var(--destructive) / 0.09);
  color: hsl(var(--destructive));
}
.toast-success .toast-icon {
  background: rgb(5 150 105 / 0.09);
  color: #059669;
}
.toast-icon svg {
  width: 1.15rem;
  height: 1.15rem;
}
.toast-content {
  display: flex;
  width: 100%;
  min-width: 0;
  flex: 1 1 auto;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.toast-title {
  width: 100%;
  color: hsl(var(--foreground));
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.4;
  text-align: center;
}
.toast-message {
  display: block;
  width: 100%;
  margin-top: 0.25rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.875rem;
  line-height: 1.55;
  text-align: center;
  overflow-wrap: anywhere;
}
.toast-actions {
  display: flex;
  width: 100%;
  justify-content: center;
  margin-top: 0.95rem;
  padding-top: 0.9rem;
  border-top: 1px solid hsl(var(--border) / 0.46);
}
.toast-confirm {
  display: inline-flex;
  min-width: 6rem;
  min-height: 2.375rem;
  align-items: center;
  justify-content: center;
  border: 1px solid hsl(var(--primary));
  border-radius: 0.5rem;
  background: hsl(var(--primary));
  color: hsl(var(--primary-foreground));
  padding: 0.5rem 1.1rem;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.25;
  text-align: center;
  cursor: pointer;
  box-shadow: 0 8px 18px -12px hsl(var(--primary) / 0.8);
  transition:
    background-color 0.15s ease,
    border-color 0.15s ease,
    box-shadow 0.15s ease,
    transform 0.15s ease;
}
.toast-confirm:hover {
  border-color: hsl(var(--primary) / 0.9);
  background: hsl(var(--primary) / 0.9);
  box-shadow: 0 10px 22px -12px hsl(var(--primary) / 0.9);
}
.toast-confirm:active {
  transform: translateY(1px);
}
.toast-confirm:focus-visible {
  outline: 3px solid hsl(var(--ring) / 0.2);
  outline-offset: 2px;
}
.toast-close {
  position: absolute;
  top: 0.45rem;
  right: 0.45rem;
  display: inline-flex;
  width: 1.75rem;
  height: 1.75rem;
  align-items: center;
  justify-content: center;
  border: none;
  border-radius: 9999px;
  background: transparent;
  color: hsl(var(--muted-foreground));
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    color 0.15s ease;
}
.toast-close:hover {
  background: hsl(var(--border) / 0.6);
  color: hsl(var(--foreground));
}
.toast-close:focus-visible {
  outline: 3px solid hsl(var(--ring) / 0.2);
  outline-offset: 2px;
}
@keyframes token-toast-in {
  from {
    opacity: 0;
    transform: translateY(0.4rem) scale(0.99);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
@media (max-width: 639px) {
  .toast-container {
    padding: 1rem;
  }
  .toast {
    width: min(100%, 21.5rem);
    padding: 1.2rem 1rem 0.95rem;
  }
}
@media (prefers-reduced-motion: reduce) {
  .toast {
    animation: none;
  }
}

.package-scope-note{display:flex;align-items:center;gap:.65rem;margin-top:1.25rem;padding:.85rem 1rem;border:1px solid rgba(37,99,235,.16);border-radius:.9rem;background:rgba(239,246,255,.72);color:#31527a;font-size:.92rem;line-height:1.55}
.package-scope-note svg{width:1.1rem;height:1.1rem;flex:none;color:#2563eb}
/* TOKEN INNER PAGE TITLE ALIGNMENT */
/* Public non-home page titles share one centered type scale and line box. */
.page-title {
  display: block;
  flex: 0 0 auto;
  margin: 0;
  min-height: 40px;
  font-size: 36px;
  line-height: 40px;
  font-weight: 700;
  letter-spacing: -0.025em;
  text-align: center;
}
@media (max-width: 639px) {
  .page-title {
    min-height: 36px;
    font-size: 30px;
    line-height: 36px;
  }
}

/* 模块页区块小标题统一规格（与 .page-title 同一设计语言） */
.section-title {
  margin: 0;
  font-size: 1.25rem;
  line-height: 1.4;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: hsl(var(--foreground));
}
.subsection-title {
  margin: 0;
  font-size: 1rem;
  line-height: 1.5;
  font-weight: 600;
  color: hsl(var(--foreground));
}

/* ===== admin shell (missing classes) ===== */
.admin-shell { min-height: 100vh; display: flex; flex-direction: column; }
.admin-callout { border-radius: 1rem; }
.admin-quota-rows { display: flex; flex-direction: column; gap: 0.5rem; }
.admin-content-form { width: 100%; max-width: none; }
.admin-settings-form { width: 100%; max-width: none; }
.admin-content-field { display: flex; flex-direction: column; gap: 0.375rem; }
/* ===== end admin shell ===== */


/* TOKEN REQUIRED UTILITIES */
.max-w-md { max-width: 28rem; }
.max-w-7xl { max-width: 80rem; }
.min-w-0 { min-width: 0; }
.min-h-16 { min-height: 4rem; }
.min-h-28 { min-height: 7rem; }
.min-h-32 { min-height: 8rem; }
.min-h-40 { min-height: 10rem; }
.size-12 { width: 3rem; height: 3rem; }
.size-3\.5 { width: .875rem; height: .875rem; }
.inline-block { display: inline-block; }
.overflow-x-auto { overflow-x: auto; }
.self-start { align-self: flex-start; }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.object-contain { object-fit: contain; }
.col-span-2 { grid-column: span 2 / span 2; }
.grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.divide-y > :not([hidden]) ~ :not([hidden]) { border-top: 1px solid hsl(var(--border)); }
.divide-border\/60 > :not([hidden]) ~ :not([hidden]) { border-color: hsl(var(--border) / .6); }
.font-normal { font-weight: 400; }
.uppercase { text-transform: uppercase; }
.leading-6 { line-height: 1.5rem; }
.leading-relaxed { line-height: 1.625; }
.opacity-50 { opacity: .5; }
.gap-1\.5 { gap: .375rem; }
.gap-2\.5 { gap: .625rem; }
.mt-0\.5 { margin-top: .125rem; }
.mt-7 { margin-top: 1.75rem; }
.mb-5 { margin-bottom: 1.25rem; }
.ml-2 { margin-left: .5rem; }
.ml-4 { margin-left: 1rem; }
.mr-1 { margin-right: .25rem; }
.py-1\.5 { padding-top: .375rem; padding-bottom: .375rem; }
.py-2\.5 { padding-top: .625rem; padding-bottom: .625rem; }
.py-4 { padding-top: 1rem; padding-bottom: 1rem; }
.py-6 { padding-top: 1.5rem; padding-bottom: 1.5rem; }
.py-8 { padding-top: 2rem; padding-bottom: 2rem; }
.py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
.bg-background\/90 { background: hsl(var(--background) / .9); }
.bg-card\/60 { background: hsl(var(--card) / .6); }
.bg-card\/70 { background: hsl(var(--card) / .7); }
.bg-muted\/40 { background: hsl(var(--muted) / .4); }
.bg-amber-500\/5 { background: rgb(245 158 11 / .05); }
.bg-amber-500\/10 { background: rgb(245 158 11 / .10); }
.bg-emerald-500\/5 { background: rgb(16 185 129 / .05); }
.bg-emerald-500\/10 { background: rgb(16 185 129 / .10); }
.bg-orange-500\/5 { background: rgb(249 115 22 / .05); }
.bg-orange-500\/10 { background: rgb(249 115 22 / .10); }
.bg-slate-500\/10 { background: rgb(100 116 139 / .10); }
.border-amber-500\/25 { border-color: rgb(245 158 11 / .25); }
.border-amber-500\/30 { border-color: rgb(245 158 11 / .30); }
.border-amber-500\/40 { border-color: rgb(245 158 11 / .40); }
.border-blue-500\/20 { border-color: rgb(59 130 246 / .20); }
.border-blue-500\/25 { border-color: rgb(59 130 246 / .25); }
.border-emerald-500\/20 { border-color: rgb(16 185 129 / .20); }
.border-emerald-500\/30 { border-color: rgb(16 185 129 / .30); }
.border-orange-500\/20 { border-color: rgb(249 115 22 / .20); }
.text-amber-600 { color: #d97706; }
.text-amber-700 { color: #b45309; }
.text-amber-800 { color: #92400e; }
.text-blue-700 { color: #1d4ed8; }
.text-blue-800 { color: #1e40af; }
.text-emerald-700 { color: #047857; }
.text-orange-700 { color: #c2410c; }
.text-red-500 { color: #ef4444; }
.text-slate-600 { color: #475569; }
.text-muted-foreground\/50 { color: hsl(var(--muted-foreground) / .5); }
.hover\:bg-blue-500\/5:hover { background: rgb(59 130 246 / .05); }
.hover\:border-blue-500\/50:hover { border-color: rgb(59 130 246 / .50); }
.hover\:text-blue-600:hover { color: #2563eb; }
.dark .dark\:text-amber-400 { color: #fbbf24; }
.dark .dark\:text-blue-300 { color: #93c5fd; }
@media (min-width: 640px) {
  .sm\:grid { display: grid; }
  .sm\:hidden { display: none; }
  .sm\:inline { display: inline; }
  .sm\:grid-cols-6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .sm\:col-span-2 { grid-column: span 2 / span 2; }
  .sm\:gap-3 { gap: .75rem; }
  .sm\:items-center { align-items: center; }
  .sm\:items-end { align-items: flex-end; }
  .sm\:self-auto { align-self: auto; }
  .sm\:p-4 { padding: 1rem; }
  .sm\:p-5 { padding: 1.25rem; }
  .sm\:p-6 { padding: 1.5rem; }
  .sm\:p-7 { padding: 1.75rem; }
  .sm\:p-8 { padding: 2rem; }
  .sm\:text-lg { font-size: 1.125rem; line-height: 1.75rem; }
}
@media (min-width: 1024px) {
  .lg\:items-start { align-items: flex-start; }
  .lg\:py-8 { padding-top: 2rem; padding-bottom: 2rem; }
  .lg\:py-10 { padding-top: 2.5rem; padding-bottom: 2.5rem; }
  .lg\:py-14 { padding-top: 3.5rem; padding-bottom: 3.5rem; }
  .lg\:py-16 { padding-top: 4rem; padding-bottom: 4rem; }
  .lg\:py-20 { padding-top: 5rem; padding-bottom: 5rem; }
}
/* END TOKEN REQUIRED UTILITIES */

/* ============================================================
   TOKEN PAGE HEADER - 统一页面头部
   ============================================================ */
.page-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-top: 0;
}

.page-header-title-row {
  display: flex;
  max-width: 100%;
  min-height: 2.5rem;
  align-items: center;
  justify-content: center;
  gap: 0.875rem;
}
.page-header-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: hsl(var(--primary) / 0.10);
  color: hsl(var(--primary));
  flex: 0 0 auto;
}
.page-header-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}
.page-subtitle {
  max-width: 42rem;
  margin: 1rem auto 1.5rem;
  color: hsl(var(--muted-foreground));
  font-size: 1rem;
  line-height: 1.7;
  text-align: center;
}
@media (max-width: 639px) {
  .page-header-icon { width: 2rem; height: 2rem; }
  .page-header-icon svg { width: 1rem; height: 1rem; }
  .page-subtitle { font-size: 0.95rem; }
}


/* 用量查询统计卡片：统一模块内的响应式分隔线 */
.usage-summary-grid > div { min-width: 0; }
@media (min-width: 768px) {
  .usage-summary-grid > div + div { border-left: 1px solid hsl(var(--border) / .6); }
}
@media (max-width: 767px) {
  .usage-summary-grid > div:nth-child(odd) { border-right: 1px solid hsl(var(--border) / .6); }
  .usage-summary-grid > div:nth-child(-n + 2) { border-bottom: 1px solid hsl(var(--border) / .6); }
}
