/* ===== base.css — 共享基础样式 ===== */

:root {
  --bg: #09090B;
  --bg-card: #0F0F12;
  --fg: #F5F5F7;
  --fg-secondary: #a1a1aa;
  --fg-muted: #6b7280;
  --accent: #5E6AD2;
  --accent-soft: rgba(94,106,210,0.1);
  --accent-glow: rgba(94,106,210,0.25);
  --border: rgba(255,255,255,0.06);
  --border-hover: rgba(255,255,255,0.12);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
  --transition: 0.3s var(--ease);
}

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

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  background: var(--bg);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  color: var(--fg);
  padding: 24px;
  padding-top: 80px;
  padding-bottom: 40px;
  -webkit-font-smoothing: antialiased;
}

.container {
  text-align: center;
  max-width: 800px;
  width: 100%;
  flex: 1;
}

/* Badge 组件 */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-soft);
  border: 1px solid rgba(94,106,210,0.2);
  color: #a5b4fc;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.5px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 32px;
}

.badge-dot {
  width: 6px; height: 6px;
  background: var(--accent);
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.4; transform: scale(0.8); }
}

/* 渐变标题 */
h1 {
  font-size: clamp(28px, 5vw, 40px);
  font-weight: 700;
  letter-spacing: -0.5px;
  margin-bottom: 16px;
  background: linear-gradient(135deg, #fff 0%, #a5b4fc 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

p {
  font-size: 15px;
  color: var(--fg-secondary);
  line-height: 1.6;
  margin-bottom: 36px;
}

/* 模块标题 */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}

.section-title {
  font-size: 14px;
  font-weight: 600;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.item-count {
  font-size: 12px;
  color: #8d8d8d;
  background: rgba(255, 255, 255, 0.05);
  padding: 4px 10px;
  border-radius: 12px;
}

/* 加载 & 空状态 */
.loading {
  color: #8d8d8d;
  font-size: 14px;
  padding: 20px;
}

.empty-state {
  color: #8d8d8d;
  font-size: 14px;
  padding: 20px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: 12px;
  border: 1px dashed #393939;
}

/* 分页 */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 20px;
}

.pagination-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #393939;
  color: #9ca3af;
  font-size: 13px;
  padding: 8px 16px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s;
}

.pagination-btn:hover:not(:disabled) {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.pagination-btn:disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.pagination-info {
  font-size: 12px;
  color: #8d8d8d;
}

/* 弹窗基础（覆盖营销和会议使用） */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 20px;
}

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

.modal {
  background: #18181b;
  border: 1px solid #393939;
  border-radius: 20px;
  max-width: 500px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid #393939;
}

.modal-title {
  font-size: 18px;
  font-weight: 600;
  color: #fff;
}

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

.modal-close:hover {
  color: #fff;
}

.modal-body {
  padding: 24px;
}

.modal-section {
  margin-bottom: 24px;
}

.modal-section:last-child {
  margin-bottom: 0;
}

.modal-section-title {
  font-size: 12px;
  font-weight: 600;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
}

/* 弹窗复制框 */
.modal-copy-box {
  background: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 16px;
  position: relative;
}

.modal-copy-text {
  font-size: 14px;
  color: #e5e7eb;
  line-height: 1.6;
  white-space: pre-wrap;
  word-break: break-word;
}

.modal-copy-btn {
  position: absolute;
  top: 12px;
  right: 12px;
  background: #5E6AD2;
  border: none;
  color: #fff;
  font-size: 12px;
  padding: 6px 12px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: background 0.2s;
}

.modal-copy-btn:hover {
  background: #4f5bb8;
}

.modal-copy-btn.copied {
  background: #10b981;
}

.modal-price {
  font-size: 16px;
  color: #10b981;
  font-weight: 600;
}

.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.modal-tag {
  font-size: 12px;
  color: #9ca3af;
  background: rgba(255, 255, 255, 0.05);
  padding: 4px 12px;
  border-radius: 8px;
}

/* 营销卡片 */
.marketing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 16px;
}

.marketing-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #393939;
  border-radius: 16px;
  padding: 20px;
  cursor: pointer;
  transition: all 0.2s;
  text-align: left;
  position: relative;
}

.marketing-card:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(94, 106, 210, 0.3);
  transform: translateY(-4px);
}

.marketing-card-status {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  animation: statusPulse 2s ease-in-out infinite;
}

.marketing-card-status.active {
  background: #10b981;
  box-shadow: 0 0 10px rgba(16, 185, 129, 0.5);
}

.marketing-card-status.inactive {
  background: #ef4444;
  box-shadow: 0 0 10px rgba(239, 68, 68, 0.5);
}

@keyframes statusPulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.6; transform: scale(0.9); }
}

.marketing-card-header {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

.marketing-card-product {
  font-size: 11px;
  color: #5E6AD2;
  background: rgba(94, 106, 210, 0.1);
  padding: 4px 10px;
  border-radius: 10px;
}

.marketing-card-title {
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 8px;
  line-height: 1.4;
}

.marketing-card-price {
  font-size: 13px;
  color: #10b981;
  font-weight: 500;
  margin-bottom: 12px;
}

.marketing-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.marketing-card-tag {
  font-size: 11px;
  color: #8d8d8d;
  background: rgba(255, 255, 255, 0.05);
  padding: 3px 8px;
  border-radius: 6px;
}

/* 营销图片保存提示 */
#mobileSaveTip {
  display: none;
  background: rgba(94, 106, 210, 0.1);
  border: 1px solid rgba(94, 106, 210, 0.3);
  color: #8d8d8d;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 12px;
  text-align: center;
  margin-top: 12px;
}

/* 即将上线 */
.coming-soon {
  background: rgba(94, 106, 210, 0.1);
  border: 1px solid rgba(94, 106, 210, 0.3);
  border-radius: 16px;
  padding: 48px 32px;
  text-align: center;
}

.coming-soon-icon {
  font-size: 64px;
  margin-bottom: 24px;
}

.coming-soon-title {
  font-size: 24px;
  font-weight: 600;
  color: #fff;
  margin-bottom: 12px;
}

.coming-soon-desc {
  font-size: 15px;
  color: #8d8d8d;
  margin-bottom: 24px;
}

.coming-soon-badge {
  display: inline-block;
  background: #5E6AD2;
  color: #fff;
  font-size: 13px;
  font-weight: 500;
  padding: 8px 20px;
  border-radius: 20px;
}

/* 响应式 */@media (max-width: 600px) {
  .marketing-grid {
    grid-template-columns: 1fr;
  }
  #modalImageSave {
    display: none !important;
  }
  #mobileSaveTip {
    display: block !important;
  }
}

/* ===== Footer (shared design system) ===== */
.footer-bar {
  width: 100%;
  max-width: 800px;
  margin: 48px auto 0;
  padding: 20px 24px 8px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.78rem;
  color: rgba(255,255,255,0.35);
  line-height: 1.6;
}
.footer-bar a {
  color: rgba(255,255,255,0.45);
  text-decoration: none;
  transition: color var(--transition);
}
.footer-bar a:hover { color: var(--fg); }
.beian {
  display: flex; flex-wrap: wrap;
  align-items: center; justify-content: center;
  gap: 6px; margin-top: 4px;
}
.beian img { height: 14px; vertical-align: middle; }

@media (max-width: 768px) {
  .footer-bar {
    margin: 32px auto 0;
    padding: 16px 16px 8px;
    font-size: 0.72rem;
  }
  .beian { gap: 4px; }
  .beian img { height: 12px; }
}

/* 动画工具类 — 被 animations.js 使用 */

.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.6s cubic-bezier(0.16, 1, 0.3, 1),
              transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

.ripple {
  position: relative;
  overflow: hidden;
}

.ripple::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.3);
  transform: translate(-50%, -50%) scale(0);
  pointer-events: none;
}

.ripple:active::after {
  animation: ripple-effect 0.6s ease-out;
}

@keyframes ripple-effect {
  to {
    transform: translate(-50%, -50%) scale(4);
    opacity: 0;
  }
}

.touch-feedback {
  transition: transform 0.1s ease;
}

.touch-feedback:active {
  transform: scale(0.95);
}

.skeleton {
  background: linear-gradient(90deg,
    rgba(255,255,255,0.05) 25%,
    rgba(255,255,255,0.1) 50%,
    rgba(255,255,255,0.05) 75%
  );
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

.loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(94, 106, 210, 0.2);
  border-top-color: #5E6AD2;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 20px auto;
}

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

@media (prefers-reduced-motion: reduce) {
  .fade-in {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .ripple::after { animation: none; }
  .skeleton { animation: none; }
  .loading-spinner { animation: none; }
  * { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}
