/* ===== 蔚蓝 AI 生图平台 - 全局样式 ===== */
/* 参考 ListenHub 极简风格 + 蔚蓝游泳俱乐部蓝色品牌 */

:root {
  /* 品牌色 - 蔚蓝泳池蓝 */
  --primary: #0ea5e9;
  --primary-light: #e0f2fe;
  --primary-lighter: #f0f9ff;
  --primary-dark: #0284c7;
  --primary-darker: #0369a1;
  --accent: #06b6d4;

  /* 中性色 */
  --bg: #ffffff;
  --surface: #ffffff;
  --surface-secondary: #f8fafc;
  --surface-tertiary: #f1f5f9;
  --text: #0f172a;
  --text-secondary: #475569;
  --text-tertiary: #94a3b8;
  --border: #e2e8f0;
  --border-light: #f1f5f9;
  --divider: #f1f5f9;

  /* 功能色 */
  --success: #10b981;
  --success-light: #d1fae5;
  --warning: #f59e0b;
  --warning-light: #fef3c7;
  --danger: #ef4444;
  --danger-light: #fee2e2;
  --info: #3b82f6;
  --info-light: #dbeafe;

  /* 尺寸 */
  --sidebar-width: 260px;
  --sidebar-collapsed: 64px;
  --radius: 16px;
  --radius-sm: 10px;
  --radius-xs: 6px;
  --shadow: 0 1px 3px rgba(15, 23, 42, 0.05), 0 1px 2px rgba(15, 23, 42, 0.03);
  --shadow-md: 0 4px 12px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 12px 40px rgba(15, 23, 42, 0.12);
  --max-width: 1000px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', 'Noto Sans SC', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  font-size: 14px;
}

a { color: var(--primary-dark); text-decoration: none; }
a:hover { color: var(--primary-darker); }

/* ===== 布局容器 ===== */
.app-layout {
  display: flex;
  min-height: 100vh;
}

.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.content-area {
  flex: 1;
  padding: 40px 48px;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
}

.content-area-wide {
  max-width: 1200px;
  padding: 32px 48px;
}

/* ===== 左侧导航栏 ===== */
.sidebar {
  width: var(--sidebar-width);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: width 0.25s ease;
}

.sidebar-brand {
  padding: 20px 20px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.brand-logo {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 18px;
  flex-shrink: 0;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.3;
}

.brand-name {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.3px;
}

.brand-tagline {
  font-size: 11px;
  color: var(--text-tertiary);
}

.sidebar-nav {
  flex: 1;
  padding: 12px 14px;
  overflow-y: auto;
}

.nav-section {
  margin-bottom: 20px;
}

.nav-section-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-tertiary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 0 10px 8px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border-radius: var(--radius-xs);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s ease;
  margin-bottom: 2px;
}

.nav-item:hover {
  background: var(--surface-tertiary);
  color: var(--text);
}

.nav-item.active {
  background: var(--primary-light);
  color: var(--primary-dark);
}

.nav-item .nav-icon {
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex-shrink: 0;
}

.nav-item .nav-arrow {
  margin-left: auto;
  font-size: 12px;
  color: var(--text-tertiary);
  opacity: 0;
  transition: opacity 0.15s;
}

.nav-item:hover .nav-arrow {
  opacity: 1;
}

.nav-badge {
  margin-left: auto;
  background: var(--warning);
  color: white;
  font-size: 10px;
  font-weight: 600;
  padding: 1px 7px;
  border-radius: 20px;
}

.nav-badge-hot {
  background: var(--danger);
}

/* ===== 侧边栏底部 - 用户区 ===== */
.sidebar-footer {
  padding: 14px;
  border-top: 1px solid var(--border-light);
}

.credits-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 10px;
  margin-bottom: 8px;
  border-radius: var(--radius-xs);
  cursor: pointer;
  transition: background 0.15s;
}

.credits-row:hover {
  background: var(--surface-tertiary);
}

.credits-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
}

.credits-value {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
}

.btn-recharge-mini {
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 14px;
  padding: 3px 10px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

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

.user-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: var(--radius-xs);
  cursor: pointer;
  transition: background 0.15s;
}

.user-row:hover {
  background: var(--surface-tertiary);
}

.user-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary-light), var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--primary-darker);
  font-size: 14px;
  font-weight: 600;
  flex-shrink: 0;
}

.user-info {
  flex: 1;
  min-width: 0;
}

.user-name {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-role {
  font-size: 11px;
  color: var(--text-tertiary);
}

.btn-login {
  width: 100%;
  background: var(--text);
  color: white;
  border: none;
  border-radius: var(--radius-xs);
  padding: 11px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  margin-top: 4px;
}

.btn-login:hover {
  background: var(--text-secondary);
}

/* ===== 按钮 ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: var(--radius-xs);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border: none;
  transition: all 0.15s;
  text-decoration: none;
}

.btn-primary {
  background: var(--primary);
  color: #fff;
}

.btn-primary:hover {
  background: var(--primary-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--primary-lighter);
}

.btn-ghost {
  background: transparent;
  border: 1px solid transparent;
  color: var(--text-secondary);
}

.btn-ghost:hover {
  background: var(--surface-tertiary);
  color: var(--text);
}

.btn-success {
  background: var(--success);
  color: #fff;
}

.btn-success:hover { opacity: 0.9; color: #fff; }

.btn-danger {
  background: var(--danger);
  color: #fff;
}

.btn-danger:hover { opacity: 0.9; color: #fff; }

.btn-lg { padding: 14px 28px; font-size: 15px; }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-xs { padding: 4px 10px; font-size: 12px; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

.btn-icon {
  padding: 8px;
  border-radius: var(--radius-xs);
}

/* ===== 卡片 ===== */
.card {
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  overflow: hidden;
}

.card-body { padding: 24px; }

/* ===== 表单 ===== */
.form-group { margin-bottom: 20px; }
.form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 500;
  font-size: 13px;
  color: var(--text-secondary);
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  font-size: 14px;
  font-family: inherit;
  transition: all 0.15s;
  background: var(--surface);
  color: var(--text);
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-light);
}

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

/* ===== 页面标题 ===== */
.page-header {
  margin-bottom: 32px;
}

.page-title {
  font-size: 32px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -0.5px;
  margin-bottom: 8px;
}

.page-subtitle {
  font-size: 15px;
  color: var(--text-secondary);
}

/* ===== 创作工作台 - AI 生图 ===== */
.create-hero {
  text-align: center;
  padding: 24px 0 40px;
}

.create-hero h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.5px;
}

.create-hero p {
  color: var(--text-secondary);
  font-size: 15px;
}

.prompt-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow);
  max-width: 800px;
  margin: 0 auto 24px;
}

.prompt-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.prompt-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}

.prompt-btn:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--primary-lighter);
}

.prompt-textarea {
  width: 100%;
  border: none;
  padding: 4px 0 12px;
  font-size: 16px;
  line-height: 1.6;
  resize: none;
  min-height: 60px;
  outline: none;
  color: var(--text);
  font-family: inherit;
}

.prompt-textarea::placeholder {
  color: var(--text-tertiary);
}

.prompt-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--border-light);
  padding-top: 12px;
}

.prompt-options {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.prompt-option {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 10px;
  border-radius: var(--radius-xs);
  background: var(--surface-tertiary);
  color: var(--text-secondary);
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  border: 1px solid transparent;
}

.prompt-option:hover {
  border-color: var(--border);
  color: var(--text);
}

.prompt-option.active {
  background: var(--primary-light);
  color: var(--primary-darker);
}

.btn-generate {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--text);
  color: white;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.15s;
  flex-shrink: 0;
}

.btn-generate:hover:not(:disabled) {
  background: var(--primary-dark);
  transform: scale(1.05);
}

.btn-generate:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* 提示词示例 */
.examples-section {
  max-width: 800px;
  margin: 0 auto 40px;
}

.examples-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-tertiary);
  margin-bottom: 12px;
  font-weight: 500;
}

.examples-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}

.example-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  cursor: pointer;
  transition: all 0.15s;
}

.example-card:hover {
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.example-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: var(--primary-lighter);
  color: var(--primary-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  margin-bottom: 10px;
}

.example-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.example-desc {
  font-size: 12px;
  color: var(--text-tertiary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* 结果区域 */
.result-area {
  max-width: 800px;
  margin: 0 auto;
}

.result-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 320px;
  color: var(--text-tertiary);
  background: var(--surface-secondary);
  border: 2px dashed var(--border);
  border-radius: var(--radius);
}

.result-placeholder-icon {
  width: 64px;
  height: 64px;
  border-radius: 16px;
  background: var(--primary-lighter);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  margin-bottom: 16px;
}

.result-image-wrapper {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
  margin-bottom: 16px;
}

.result-image {
  width: 100%;
  display: block;
  border-radius: var(--radius);
}

.result-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 16px;
}

.result-success-bar {
  text-align: center;
  padding: 12px;
  background: var(--success-light);
  border-radius: var(--radius-sm);
  color: var(--success);
  font-size: 13px;
  font-weight: 500;
}

/* 加载动画 */
.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--border);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 16px;
}

@keyframes spin { to { transform: rotate(360deg); } }

/* ===== 模板网格 ===== */
.section-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border);
  padding-bottom: 12px;
}

.section-tab {
  padding: 8px 16px;
  border-radius: var(--radius-xs);
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
  border: none;
  background: transparent;
}

.section-tab:hover { color: var(--text); }

.section-tab.active {
  background: var(--primary-light);
  color: var(--primary-dark);
}

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

.template-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  transition: all 0.15s;
}

.template-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.template-thumb {
  width: 100%;
  aspect-ratio: 4/3;
  background: linear-gradient(135deg, var(--primary-lighter), var(--primary-light));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  color: var(--primary);
}

.template-card-body { padding: 12px; }

.template-card-name {
  font-weight: 600;
  font-size: 13px;
  color: var(--text);
  margin-bottom: 4px;
}

.template-card-meta {
  font-size: 11px;
  color: var(--text-tertiary);
  display: flex;
  gap: 8px;
  align-items: center;
}

/* ===== 画廊 ===== */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.gallery-item {
  background: var(--surface);
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform 0.2s;
  position: relative;
  cursor: pointer;
}

.gallery-item:hover { transform: translateY(-2px); }

.gallery-item img {
  width: 100%;
  display: block;
  aspect-ratio: 3/4;
  object-fit: cover;
  background: var(--primary-lighter);
}

.gallery-item-info { padding: 10px 12px; }

.gallery-item-prompt {
  font-size: 12px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.gallery-item-meta {
  font-size: 11px;
  color: var(--text-tertiary);
  margin-top: 4px;
}

.gallery-item-actions {
  position: absolute;
  top: 8px;
  right: 8px;
  display: flex;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.15s;
}

.gallery-item:hover .gallery-item-actions { opacity: 1; }

.gallery-item-actions button {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.95);
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow);
}

.gallery-item-actions button:hover {
  background: white;
}

/* ===== 积分套餐 ===== */
.pricing-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 32px;
  padding: 28px;
  background: linear-gradient(135deg, var(--primary-lighter), var(--primary-light));
  border-radius: var(--radius);
  border: 1px solid var(--border);
}

.balance-display .label {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 4px;
}

.balance-display .value {
  font-size: 36px;
  font-weight: 700;
  color: var(--primary-dark);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.pricing-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  position: relative;
  transition: all 0.2s;
}

.pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.pricing-card.featured {
  border-color: var(--primary);
  box-shadow: 0 0 0 1px var(--primary);
}

.pricing-card.featured::before {
  content: '热门';
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  padding: 2px 12px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
}

.pricing-name { font-size: 16px; font-weight: 600; margin-bottom: 12px; }

.pricing-price {
  font-size: 36px;
  font-weight: 700;
  color: var(--primary-dark);
}

.pricing-price small { font-size: 14px; font-weight: 400; }

.pricing-credits {
  font-size: 15px;
  color: var(--text);
  margin: 12px 0;
}

.pricing-bonus {
  color: var(--success);
  font-size: 12px;
  margin-bottom: 16px;
}

.pricing-original {
  text-decoration: line-through;
  color: var(--text-tertiary);
  font-size: 12px;
  margin-bottom: 16px;
}

/* ===== 空状态 ===== */
.empty-state {
  text-align: center;
  padding: 80px 20px;
  color: var(--text-tertiary);
}

.empty-state-icon {
  width: 72px;
  height: 72px;
  border-radius: 20px;
  background: var(--primary-lighter);
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin: 0 auto 16px;
}

.empty-state-text { font-size: 15px; margin-bottom: 16px; }

/* ===== Toast 提示 ===== */
.toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.toast {
  padding: 12px 20px;
  border-radius: var(--radius-xs);
  box-shadow: var(--shadow-lg);
  font-size: 14px;
  animation: slideIn 0.2s ease;
  max-width: 360px;
  border: 1px solid;
}

.toast-success { background: var(--success-light); color: #065f46; border-color: #a7f3d0; }
.toast-error { background: var(--danger-light); color: #991b1b; border-color: #fecaca; }
.toast-info { background: var(--primary-light); color: #075985; border-color: #bae6fd; }

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* ===== 分页 ===== */
.pagination {
  display: flex;
  gap: 6px;
  justify-content: center;
  margin-top: 32px;
}

.pagination button {
  padding: 8px 14px;
  border: 1px solid var(--border);
  background: var(--surface);
  border-radius: var(--radius-xs);
  cursor: pointer;
  font-size: 13px;
  color: var(--text-secondary);
  transition: all 0.15s;
}

.pagination button:hover { border-color: var(--primary); color: var(--primary); }
.pagination button.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.pagination button:disabled { opacity: 0.4; cursor: not-allowed; }

/* ===== 模态框 ===== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  backdrop-filter: blur(4px);
}

.modal {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 520px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}

.modal-title { font-size: 18px; font-weight: 600; margin-bottom: 20px; }
.modal-actions { display: flex; gap: 12px; justify-content: flex-end; margin-top: 24px; }

/* ===== 管理后台 ===== */
.admin-stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.stat-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 20px;
  border: 1px solid var(--border);
}

.stat-label { font-size: 13px; color: var(--text-secondary); }
.stat-value { font-size: 28px; font-weight: 700; margin-top: 4px; color: var(--primary-dark); }
.stat-trend { font-size: 12px; color: var(--text-tertiary); margin-top: 4px; }

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.admin-table th {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 2px solid var(--border);
  color: var(--text-secondary);
  font-weight: 500;
  background: var(--surface-secondary);
}

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

.admin-table tr:hover { background: var(--surface-secondary); }

/* ===== 标签 ===== */
.tag {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
}

.tag-success { background: var(--success-light); color: #065f46; }
.tag-warning { background: var(--warning-light); color: #92400e; }
.tag-danger { background: var(--danger-light); color: #991b1b; }
.tag-info { background: var(--primary-light); color: #075985; }
.tag-gray { background: var(--surface-tertiary); color: var(--text-secondary); }

/* ===== 文件上传区 ===== */
.upload-area {
  border: 2px dashed var(--border);
  border-radius: var(--radius-sm);
  padding: 20px;
  text-align: center;
  cursor: pointer;
  transition: all 0.15s;
}

.upload-area:hover { border-color: var(--primary); background: var(--primary-lighter); }
.upload-area.has-file { border-color: var(--success); border-style: solid; }
.upload-preview {
  max-width: 120px;
  max-height: 120px;
  border-radius: var(--radius-sm);
  margin-top: 8px;
}

/* ===== 响应式 ===== */
@media (max-width: 900px) {
  .sidebar {
    width: var(--sidebar-collapsed);
  }
  .main-content {
    margin-left: var(--sidebar-collapsed);
  }
  .brand-text, .nav-item span, .nav-section-title, .credits-label span, .user-info, .user-row .nav-arrow {
    display: none;
  }
  .sidebar-brand { justify-content: center; padding: 20px 14px; }
  .nav-item { justify-content: center; padding: 12px; }
  .nav-item .nav-icon { font-size: 20px; }
  .sidebar-footer { padding: 10px; }
  .credits-row { justify-content: center; padding: 10px; }
  .credits-value { justify-content: center; }
  .btn-recharge-mini { display: none; }
  .user-row { justify-content: center; }
  .btn-login span { display: none; }
  .content-area { padding: 24px 20px; }
}

@media (max-width: 640px) {
  .create-hero h1 { font-size: 26px; }
  .prompt-footer { flex-direction: column; align-items: stretch; }
  .btn-generate { width: 100%; height: 44px; }
  .examples-grid { grid-template-columns: 1fr; }
  .pricing-header { flex-direction: column; gap: 16px; text-align: center; }
  .gallery-grid, .template-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ===== 移动端菜单按钮 ===== */
.mobile-menu-btn {
  display: none;
  position: fixed;
  top: 16px;
  left: 16px;
  z-index: 101;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  align-items: center;
  justify-content: center;
  font-size: 20px;
  cursor: pointer;
}

@media (max-width: 640px) {
  .mobile-menu-btn { display: flex; }
  .sidebar {
    transform: translateX(-100%);
    width: 260px;
  }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; }
  .brand-text, .nav-item span, .nav-section-title, .credits-label span, .user-info, .user-row .nav-arrow {
    display: block;
  }
  .nav-item { justify-content: flex-start; padding: 10px 12px; }
  .credits-row { justify-content: space-between; }
  .btn-recharge-mini { display: inline-block; }
  .user-row { justify-content: flex-start; }
  .sidebar-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.4);
    z-index: 99;
  }
  .sidebar-overlay.show { display: block; }
}

/* ===== 登录页 ===== */
.login-page {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 24px;
  background: var(--surface-secondary);
}

.login-box {
  width: 100%;
  max-width: 400px;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--border);
  padding: 40px;
  box-shadow: var(--shadow-lg);
}

.login-header {
  text-align: center;
  margin-bottom: 32px;
}

.login-logo {
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 26px;
  margin: 0 auto 16px;
}

.login-title {
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 6px;
}

.login-subtitle {
  color: var(--text-secondary);
  font-size: 14px;
}

.login-tabs {
  display: flex;
  gap: 0;
  margin-bottom: 24px;
  border-radius: var(--radius-xs);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface-secondary);
}

.login-tab {
  flex: 1;
  padding: 11px;
  border: none;
  background: transparent;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}

.login-tab.active {
  background: var(--text);
  color: #fff;
}

/* ===== 首页英雄区 ===== */
.home-hero {
  text-align: center;
  padding: 60px 20px 40px;
  max-width: 720px;
  margin: 0 auto;
}

.home-hero h1 {
  font-size: 42px;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}

.home-hero h1 span {
  color: var(--primary-dark);
  position: relative;
}

.home-hero p {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.7;
}

.hero-buttons {
  display: flex;
  gap: 12px;
  justify-content: center;
}

/* ===== 首页功能卡片 ===== */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-top: 48px;
}

.feature-card {
  padding: 24px;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  transition: all 0.2s;
}

.feature-card:hover {
  border-color: var(--primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.feature-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--primary-lighter);
  color: var(--primary-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  margin-bottom: 14px;
}

.feature-title {
  font-size: 15px;
  font-weight: 600;
  margin-bottom: 6px;
}

.feature-desc {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ===== 尺寸/质量/模型选择面板 ===== */
.size-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
}

.size-option {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 10px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--surface);
}

.size-option:hover {
  border-color: var(--primary);
}

.size-option.selected {
  border-color: var(--primary);
  background: var(--primary-lighter);
}

.size-option-icon {
  border: 2px solid var(--text-tertiary);
  border-radius: 4px;
  margin: 0 auto 8px;
}

.size-option.selected .size-option-icon {
  border-color: var(--primary);
}

.size-option-label {
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 2px;
}

.size-option-dim {
  font-size: 11px;
  color: var(--text-tertiary);
}

.quality-options,
.model-options {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
}

.quality-option,
.model-option {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  cursor: pointer;
  transition: all 0.2s;
  background: var(--surface);
}

.quality-option:hover,
.model-option:hover {
  border-color: var(--primary);
}

.quality-option.selected,
.model-option.selected {
  border-color: var(--primary);
  background: var(--primary-lighter);
}

/* ===== 管理员余额提醒面板 ===== */
.alert-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  margin-bottom: 20px;
  font-size: 14px;
}

.alert-banner-danger {
  background: var(--danger-light);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.alert-banner-warning {
  background: var(--warning-light);
  color: #b45309;
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.alert-banner-info {
  background: var(--info-light);
  color: var(--info);
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.alert-banner a {
  color: inherit;
  text-decoration: underline;
  font-weight: 500;
}

.alert-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.alert-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  transition: all 0.2s;
}

.alert-item.unread {
  border-left: 3px solid var(--danger);
  background: var(--danger-light);
}

.alert-item.read {
  border-left: 3px solid var(--border);
  opacity: 0.8;
}

.alert-item-content {
  flex: 1;
}

.alert-item-title {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 4px;
}

.alert-item-meta {
  font-size: 12px;
  color: var(--text-tertiary);
}

/* ===== 设置表单 ===== */
.settings-form .form-group {
  margin-bottom: 16px;
}

.settings-form .form-label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-secondary);
}

.settings-form .form-input,
.settings-form .form-select,
.settings-form .form-textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  font-size: 14px;
  background: var(--surface);
  color: var(--text);
}

.settings-form .form-checkbox {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

.settings-form .form-checkbox input {
  width: 18px;
  height: 18px;
  accent-color: var(--primary);
}

/* ===== 浮动客服按钮 ===== */
.feedback-fab {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 900;
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 12px 20px;
  background: var(--primary);
  color: #fff;
  border-radius: 28px;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(14, 165, 233, 0.4);
  transition: all 0.2s ease;
  font-size: 14px;
  font-weight: 600;
}
.feedback-fab:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(14, 165, 233, 0.5);
}
.feedback-fab span:first-child {
  font-size: 18px;
}
@media (max-width: 768px) {
  .feedback-fab {
    right: 16px;
    bottom: 16px;
    padding: 10px 16px;
  }
  .feedback-fab .fab-label {
    display: none;
  }
}

/* ===== 反馈弹窗 ===== */
.feedback-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.45);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.feedback-modal {
  background: #fff;
  border-radius: 16px;
  width: 100%;
  max-width: 480px;
  max-height: 85vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
}
.feedback-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid var(--border);
}
.feedback-modal-header h3 {
  font-size: 18px;
  font-weight: 700;
  margin: 0;
}
.feedback-close {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: var(--text-tertiary);
  padding: 4px 8px;
  border-radius: 6px;
}
.feedback-close:hover {
  background: var(--bg-secondary);
}
.feedback-tabs {
  display: flex;
  gap: 4px;
  padding: 12px 20px 0;
}
.feedback-tab {
  padding: 8px 16px;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 13px;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  font-weight: 500;
}
.feedback-tab.active {
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.feedback-item {
  padding: 14px 0;
  border-bottom: 1px solid var(--border);
}
.feedback-item:last-child {
  border-bottom: none;
}

/* ===== 申请状态徽章 ===== */
.status-badge {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}
.status-pending { background: #fef3c7; color: #d97706; }
.status-active { background: #d1fae5; color: #059669; }
.status-rejected { background: #fee2e2; color: #dc2626; }
.status-disabled { background: #f1f5f9; color: #64748b; }

/* ===== 签到组件 ===== */
.checkin-widget {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: linear-gradient(135deg, var(--primary-lighter), var(--primary-light));
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  margin-bottom: 24px;
}

.checkin-widget.checked {
  background: var(--success-light);
  border-color: var(--success);
}

.checkin-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: var(--primary);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.checkin-widget.checked .checkin-icon {
  background: var(--success);
}

.checkin-info {
  flex: 1;
}

.checkin-title {
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 2px;
}

.checkin-desc {
  font-size: 12px;
  color: var(--text-secondary);
}

.checkin-streak {
  display: flex;
  gap: 6px;
  align-items: center;
  margin-top: 6px;
}

.streak-day {
  display: flex;
  align-items: center;
  gap: 3px;
  font-size: 11px;
  color: var(--text-tertiary);
}

.streak-day.done { color: var(--success); font-weight: 600; }
.streak-day.today { color: var(--primary-dark); font-weight: 700; }

.btn-checkin {
  padding: 10px 24px;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: var(--radius-xs);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  white-space: nowrap;
}

.btn-checkin:hover { background: var(--primary-dark); transform: translateY(-1px); }
.btn-checkin:disabled { background: var(--success); cursor: default; opacity: 0.8; transform: none; }

/* ===== 首次免费徽章 ===== */
.free-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 3px 10px;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  color: #fff;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  white-space: nowrap;
}

.free-banner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: linear-gradient(135deg, #fff7ed, #ffedd5);
  border: 1px solid #fed7aa;
  border-radius: var(--radius-sm);
  margin-bottom: 16px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

.free-banner-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.free-banner-text {
  flex: 1;
  font-size: 13px;
  color: #9a3412;
}

.free-banner-text strong { color: #c2410c; }

/* ===== 作品广场 ===== */
.plaza-header {
  margin-bottom: 24px;
}

.plaza-filters {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.plaza-categories {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  flex: 1;
}

.plaza-cat-tab {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.15s;
}

.plaza-cat-tab:hover { border-color: var(--primary); color: var(--primary-dark); }
.plaza-cat-tab.active { background: var(--primary); color: #fff; border-color: var(--primary); }

.plaza-sort {
  display: flex;
  gap: 4px;
  border-radius: var(--radius-xs);
  overflow: hidden;
  border: 1px solid var(--border);
}

.plaza-sort-btn {
  padding: 6px 12px;
  border: none;
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}

.plaza-sort-btn.active { background: var(--primary-light); color: var(--primary-dark); font-weight: 600; }

.plaza-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.plaza-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  transition: all 0.2s;
  cursor: pointer;
}

.plaza-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--primary);
}

.plaza-card-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  background: var(--surface-secondary);
  display: block;
}

.plaza-card-body {
  padding: 12px;
}

.plaza-card-prompt {
  font-size: 12px;
  color: var(--text-secondary);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 6px;
}

.plaza-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.plaza-card-author {
  font-size: 11px;
  color: var(--text-tertiary);
}

.plaza-like-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}

.plaza-like-btn:hover { border-color: var(--danger); color: var(--danger); }
.plaza-like-btn.liked { background: var(--danger-light); color: var(--danger); border-color: var(--danger); }

/* ===== 个人素材库 ===== */
.asset-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}

.asset-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
}

.asset-card-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 4px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.asset-card-desc {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: 16px;
}

.asset-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.asset-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface-secondary);
  transition: all 0.15s;
}

.asset-item:hover { border-color: var(--primary); }

.asset-item-thumb {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

.asset-item-info { flex: 1; min-width: 0; }
.asset-item-name { font-size: 13px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.asset-item-meta { font-size: 11px; color: var(--text-tertiary); }

.asset-color-swatch {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: 2px solid var(--surface);
  box-shadow: 0 0 0 1px var(--border);
  flex-shrink: 0;
}

.asset-remove {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: none;
  background: var(--danger-light);
  color: var(--danger);
  cursor: pointer;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.15s;
}

.asset-remove:hover { background: var(--danger); color: #fff; }

.asset-add-form {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.asset-add-form input {
  flex: 1;
  padding: 8px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  font-size: 13px;
}

.asset-add-form input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light); }

.pref-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 12px;
  margin-bottom: 24px;
}

.pref-stat-card {
  padding: 16px;
  background: var(--surface-secondary);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  text-align: center;
}

.pref-stat-label { font-size: 12px; color: var(--text-tertiary); margin-bottom: 4px; }
.pref-stat-value { font-size: 20px; font-weight: 700; color: var(--primary-dark); }

/* ===== 邀请有奖 ===== */
.referral-hero {
  background: linear-gradient(135deg, var(--primary-lighter), var(--primary-light));
  border: 1px solid var(--primary);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
  margin-bottom: 32px;
}

.referral-code-box {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 12px 24px;
  background: var(--surface);
  border: 2px dashed var(--primary);
  border-radius: var(--radius-sm);
  margin: 16px 0;
}

.referral-code {
  font-size: 24px;
  font-weight: 800;
  color: var(--primary-dark);
  letter-spacing: 2px;
  font-family: monospace;
}

.referral-stats-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 16px;
  margin-bottom: 32px;
}

.milestone-track {
  display: flex;
  align-items: center;
  gap: 0;
  margin: 24px 0;
  overflow-x: auto;
  padding: 0 4px;
}

.milestone-node {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  min-width: 80px;
  position: relative;
}

.milestone-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--border);
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-tertiary);
  z-index: 1;
}

.milestone-node.done .milestone-circle {
  background: var(--success);
  border-color: var(--success);
  color: #fff;
}

.milestone-node.current .milestone-circle {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--primary-lighter);
}

.milestone-line {
  flex: 1;
  height: 3px;
  background: var(--border);
  min-width: 30px;
}

.milestone-line.done { background: var(--success); }

.milestone-label { font-size: 11px; color: var(--text-tertiary); text-align: center; }
.milestone-reward { font-size: 12px; font-weight: 600; color: var(--success); }

/* ===== 团队套餐卡片 ===== */
.team-pricing-section {
  margin-top: 48px;
}

.team-pricing-header {
  text-align: center;
  margin-bottom: 24px;
}

.team-pricing-header h2 {
  font-size: 24px;
  font-weight: 700;
  margin-bottom: 6px;
}

.team-pricing-header p {
  font-size: 14px;
  color: var(--text-secondary);
}

.team-pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 16px;
}

.team-pricing-card {
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  text-align: center;
  position: relative;
  transition: all 0.2s;
}

.team-pricing-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary);
}

.team-pricing-card.featured {
  border-color: var(--primary);
  background: linear-gradient(180deg, var(--primary-lighter), var(--surface) 40%);
}

.team-pricing-card .tag-best {
  position: absolute;
  top: -10px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--primary);
  color: #fff;
  padding: 2px 14px;
  border-radius: 12px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}

.team-price {
  font-size: 32px;
  font-weight: 800;
  color: var(--primary-dark);
}

.team-credits {
  font-size: 15px;
  color: var(--text);
  margin: 10px 0;
  font-weight: 600;
}

.team-per-credit {
  font-size: 12px;
  color: var(--text-tertiary);
  margin-bottom: 12px;
}

.team-features {
  text-align: left;
  margin: 16px 0;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 2;
}

/* ===== 分享到广场按钮 ===== */
.share-btn {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}

.share-btn:hover { border-color: var(--primary); color: var(--primary-dark); }
.share-btn.shared { background: var(--success-light); color: var(--success); border-color: var(--success); }

.share-modal-category {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 12px 0;
}

.share-cat-option {
  padding: 8px 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.15s;
}

.share-cat-option:hover { border-color: var(--primary); }
.share-cat-option.selected { background: var(--primary); color: #fff; border-color: var(--primary); }

/* ===== 快捷素材插入条 ===== */
.quick-assets-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 8px 0;
  margin-bottom: 8px;
}

.quick-asset-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 16px;
  background: var(--surface-tertiary);
  color: var(--text-secondary);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
  border: 1px solid transparent;
}

.quick-asset-chip:hover {
  border-color: var(--primary);
  color: var(--primary-dark);
  background: var(--primary-lighter);
}

.quick-color-chip {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  cursor: pointer;
  border: 2px solid var(--surface);
  box-shadow: 0 0 0 1px var(--border);
  transition: transform 0.15s;
}

.quick-color-chip:hover { transform: scale(1.15); }

/* ===== 团队管理 ===== */
.team-info-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 20px;
}

.team-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: #fff;
  flex-shrink: 0;
}

.team-member-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-xs);
  margin-bottom: 8px;
  background: var(--surface);
}

.team-member-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary-light);
  color: var(--primary-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 14px;
  flex-shrink: 0;
}

.team-member-info { flex: 1; }
.team-member-name { font-size: 14px; font-weight: 600; }
.team-member-meta { font-size: 12px; color: var(--text-tertiary); }

/* ===== 管理后台团队标签 ===== */
.admin-tab-content .team-tag {
  font-size: 11px;
  padding: 1px 8px;
  border-radius: 10px;
  font-weight: 600;
}

.team-tag-personal { background: var(--surface-tertiary); color: var(--text-secondary); }
.team-tag-admin { background: var(--primary-light); color: var(--primary-dark); }
.team-tag-member { background: var(--info-light); color: var(--info); }

