/*
 * 物星科云图片处理工具系统 V1.0.2
 * © 2018-2026 长沙木星科技有限公司
 * https://www.muxingkeji.com | 商业授权，禁止盗版、逆向、二次分发
 */
:root {
  --bg: #f0f4f8;
  --bg-2: #e8edf3;
  --panel: #ffffff;
  --panel-fill: #ffffff;
  --line: #e2e8f0;
  --line-2: #cbd5e1;
  --text: #0f172a;
  --muted: #64748b;
  --muted-2: #94a3b8;
  --accent: #2563eb;
  --accent-2: #1d4ed8;
  --accent-light: #3b82f6;
  --accent-soft: rgba(37, 99, 235, 0.08);
  --accent-glow: rgba(37, 99, 235, 0.18);
  --danger: #ef4444;
  --ok: #10b981;
  --shadow: 0 4px 24px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.04);
  --shadow-lg: 0 20px 50px rgba(37, 99, 235, 0.08), 0 8px 20px rgba(15, 23, 42, 0.06);
  --shadow-sm: 0 2px 8px rgba(15, 23, 42, 0.05);
  --radius: 16px;
  --radius-sm: 10px;
  --font: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --ui: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  --serif-ui: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--ui);
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

/* 背景：灰白底 + 蓝色光晕 */
.aurora, .sky-bg {
  position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(ellipse 80% 50% at 50% -10%, rgba(37, 99, 235, 0.12), transparent 55%),
    radial-gradient(ellipse 60% 40% at 100% 0%, rgba(59, 130, 246, 0.08), transparent 50%),
    radial-gradient(ellipse 50% 30% at 0% 100%, rgba(37, 99, 235, 0.05), transparent 45%),
    linear-gradient(180deg, #f8fafc 0%, #f0f4f8 50%, #e8edf3 100%);
}
.aurora::after, .sky-bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(rgba(255,255,255,0.6) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.6) 1px, transparent 1px);
  background-size: 48px 48px;
  opacity: 0.4;
}

a { color: var(--accent); text-decoration: none; transition: color .2s; }
a:hover { color: var(--accent-2); }
.wrap { width: min(1280px, calc(100% - 40px)); margin: 0 auto; }

/* ===== 顶栏 ===== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  width: 100%;
  margin: 0 0 8px;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(18px) saturate(180%);
  -webkit-backdrop-filter: blur(18px) saturate(180%);
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.05);
}

.site-header-inner {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto;
  padding: 12px 20px 10px;
}

.site-header-row {
  display: flex;
  align-items: center;
  gap: 16px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
  flex-shrink: 0;
  min-width: 0;
}
.brand-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}
.brand-name {
  font-weight: 800;
  letter-spacing: 0.01em;
  font-size: 17px;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.brand-tag {
  font-size: 11px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-2);
  font-weight: 600;
}
.brand .mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  position: relative;
  flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent-light), var(--accent-2));
  box-shadow: 0 6px 18px var(--accent-glow);
}
.brand .mark::after {
  content: "";
  position: absolute;
  inset: 10px 9px 11px 13px;
  border: 2px solid rgba(255,255,255,0.92);
  border-radius: 3px;
}
.mark.sm { width: 24px; height: 24px; border-radius: 7px; }
.mark.sm::after { inset: 6px 5px 6px 8px; border-width: 1.6px; border-color: rgba(255,255,255,0.9); }

.site-header-user {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  flex-shrink: 0;
}

.header-link {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  transition: color .2s;
}
.header-link:hover { color: var(--accent); }
.header-link-muted { font-weight: 500; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-soft);
  border: 1px solid rgba(37, 99, 235, 0.18);
  color: var(--accent);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}
.chip-points .chip-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  margin-left: auto;
  padding: 8px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--panel);
  color: var(--text);
  cursor: pointer;
  font: inherit;
}
.nav-toggle-bar {
  display: block;
  width: 16px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
  transition: transform .2s, opacity .2s;
}
.nav-toggle-label {
  font-size: 13px;
  font-weight: 600;
}
.nav-toggle.is-open .nav-toggle-bar:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.nav-toggle.is-open .nav-toggle-bar:nth-child(2) { opacity: 0; }
.nav-toggle.is-open .nav-toggle-bar:nth-child(3) { transform: translateY(-4px) rotate(-45deg); }

.site-nav-tools {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(226, 232, 240, 0.85);
}

.site-nav-scroll {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
  scrollbar-color: rgba(37, 99, 235, 0.25) transparent;
}
.site-nav-scroll::-webkit-scrollbar { height: 4px; }
.site-nav-scroll::-webkit-scrollbar-thumb {
  background: rgba(37, 99, 235, 0.25);
  border-radius: 999px;
}

.nav-tool {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 600;
  white-space: nowrap;
  transition: background .2s, color .2s, border-color .2s, box-shadow .2s;
}
.nav-tool:hover {
  color: var(--accent);
  background: rgba(37, 99, 235, 0.06);
  border-color: rgba(37, 99, 235, 0.12);
}
.nav-tool.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--accent-light), var(--accent-2));
  border-color: transparent;
  box-shadow: 0 8px 20px var(--accent-glow);
}
.nav-tool-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 7px;
  background: rgba(15, 23, 42, 0.05);
  font-size: 12px;
  line-height: 1;
}
.nav-tool.is-active .nav-tool-icon {
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}
.nav-tool-text { line-height: 1; }

/* 兼容旧类名 */
.topbar { display: contents; }
.nav { display: flex; gap: 24px; align-items: center; color: var(--muted); font-size: 14px; }
.nav a { color: var(--muted); font-weight: 500; white-space: nowrap; }
.nav a:hover, .nav .on { color: var(--accent); }

@media (max-width: 900px) {
  .site-header-inner { padding-top: 10px; }
  .site-header-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    grid-template-areas:
      "brand toggle"
      "user user";
    align-items: center;
    gap: 10px 12px;
  }
  .brand { grid-area: brand; }
  .nav-toggle {
    display: inline-flex;
    grid-area: toggle;
    justify-self: end;
  }
  .site-header-user {
    grid-area: user;
    width: 100%;
    margin-left: 0;
    justify-content: flex-end;
    padding-top: 6px;
    border-top: 1px dashed rgba(226, 232, 240, 0.9);
  }
  .brand-tag { display: none; }
  .site-nav-tools {
    display: none;
    margin-top: 0;
    padding-top: 10px;
    border-top: none;
  }
  .site-nav-tools.is-open { display: block; }
  .site-nav-scroll {
    flex-wrap: wrap;
    overflow: visible;
    gap: 8px;
  }
  .nav-tool { flex: 1 1 calc(50% - 4px); justify-content: center; }
}

@media (max-width: 520px) {
  .header-link { font-size: 13px; }
  .chip { padding: 5px 10px; font-size: 11px; }
  .nav-tool { flex: 1 1 100%; }
}

/* ===== Hero ===== */
.hero { padding: 48px 0 32px; max-width: 900px; }
.eyebrow {
  display: inline-block; font-size: 12px; letter-spacing: 0.28em;
  color: var(--accent); font-weight: 700; padding-bottom: 16px;
  text-transform: uppercase;
}
.hero h1 {
  font-size: clamp(36px, 5.5vw, 56px);
  font-weight: 800; line-height: 1.12; margin: 0 0 16px;
  letter-spacing: -0.02em; color: var(--text);
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(120deg, var(--accent), var(--accent-light));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero p { margin: 0 0 28px; color: var(--muted); line-height: 1.8; font-size: 16px; }
.hero-cta { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; }
.feats {
  margin-top: 36px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
}
.feat {
  padding: 20px 22px; border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow-sm);
  transition: box-shadow .2s, border-color .2s;
}
.feat:hover { box-shadow: var(--shadow); border-color: rgba(37,99,235,0.2); }
.feat b { display: block; font-size: 16px; font-weight: 700; color: var(--text); margin-bottom: 6px; }
.feat span { color: var(--muted); font-size: 13px; }
@media (max-width: 720px) { .feats { grid-template-columns: 1fr; } }

/* ===== 首页 ===== */
html:has(.page-home) { scroll-behavior: smooth; }
.home-wrap { padding-bottom: 24px; }

.home-hero {
  position: relative;
  padding: 36px 0 56px;
  overflow: hidden;
}
.home-hero-glow {
  position: absolute;
  inset: -20% -10% auto;
  height: 420px;
  background:
    radial-gradient(circle at 20% 40%, rgba(37, 99, 235, 0.18), transparent 42%),
    radial-gradient(circle at 80% 20%, rgba(99, 102, 241, 0.14), transparent 38%);
  pointer-events: none;
}
.home-hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(280px, 0.95fr);
  gap: 36px;
  align-items: center;
}
.home-eyebrow { padding-bottom: 14px; }
.home-hero-copy h1 {
  font-size: clamp(38px, 5.8vw, 62px);
  font-weight: 800;
  line-height: 1.08;
  margin: 0 0 18px;
  letter-spacing: -0.03em;
}
.home-hero-copy h1 em {
  font-style: normal;
  background: linear-gradient(120deg, #2563eb 0%, #6366f1 45%, #0ea5e9 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
.home-hero-lead {
  margin: 0 0 28px;
  max-width: 560px;
  color: var(--muted);
  line-height: 1.85;
  font-size: 17px;
}
.home-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 28px;
}
.home-hero-btn {
  box-shadow: 0 12px 28px rgba(37, 99, 235, 0.28);
}
.home-hero-stats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
  max-width: 560px;
}
.home-hero-stats li {
  padding: 14px 12px;
  border-radius: 14px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  background: rgba(255, 255, 255, 0.78);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow-sm);
}
.home-hero-stats strong {
  display: block;
  font-size: 20px;
  font-weight: 800;
  color: var(--accent);
  line-height: 1.2;
}
.home-hero-stats span {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--muted);
}

.home-hero-visual {
  position: relative;
  min-height: 360px;
}
.home-hero-card {
  border-radius: 18px;
  border: 1px solid rgba(226, 232, 240, 0.95);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: var(--shadow-lg);
  backdrop-filter: blur(12px);
}
.home-hero-card-main {
  position: relative;
  z-index: 1;
  padding: 18px;
  min-height: 280px;
}
.home-hero-card-tag {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--accent);
  background: var(--accent-soft);
}
.home-hero-card-preview {
  margin-top: 16px;
  height: 180px;
  border-radius: 14px;
  background:
    linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(14, 165, 233, 0.08)),
    linear-gradient(180deg, #eef2ff 0%, #f8fafc 100%);
  border: 1px dashed rgba(37, 99, 235, 0.18);
  position: relative;
  overflow: hidden;
}
.home-hero-card-preview::before,
.home-hero-card-preview::after {
  content: "";
  position: absolute;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.72);
  box-shadow: var(--shadow-sm);
}
.home-hero-card-preview::before {
  width: 58%;
  height: 62%;
  top: 16%;
  left: 8%;
  transform: rotate(-4deg);
}
.home-hero-card-preview::after {
  width: 48%;
  height: 52%;
  right: 8%;
  bottom: 10%;
  transform: rotate(6deg);
}
.home-hero-card-bar {
  display: flex;
  gap: 8px;
  margin-top: 16px;
}
.home-hero-card-bar i {
  flex: 1;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent-soft), rgba(37, 99, 235, 0.02));
}
.home-hero-card-float {
  position: absolute;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  font-size: 13px;
  animation: home-float 6s ease-in-out infinite;
}
.home-hero-card-float span {
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 16px;
}
.home-hero-card-float b { font-weight: 700; color: var(--text); }
.home-hero-card-a { top: 8%; left: -6%; animation-delay: 0s; }
.home-hero-card-b { top: 42%; right: -8%; animation-delay: 1.2s; }
.home-hero-card-c { bottom: 6%; left: 4%; animation-delay: 2.4s; }
@keyframes home-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.home-section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}
.home-section-head-center {
  flex-direction: column;
  align-items: center;
  text-align: center;
  margin-bottom: 28px;
}
.home-section-head h2 {
  margin: 0 0 8px;
  font-size: clamp(26px, 3.2vw, 34px);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.home-section-head p {
  margin: 0;
  color: var(--muted);
  line-height: 1.7;
  max-width: 560px;
}
.home-section-link {
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  white-space: nowrap;
}
.home-section-link:hover { text-decoration: underline; }

.home-steps {
  padding: 12px 0 48px;
}
.home-steps-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}
.home-step {
  position: relative;
  padding: 22px 20px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.82);
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s, box-shadow 0.2s, border-color 0.2s;
}
.home-step:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow);
  border-color: rgba(37, 99, 235, 0.22);
}
.home-step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  margin-bottom: 14px;
  border-radius: 12px;
  font-size: 13px;
  font-weight: 800;
  color: var(--accent);
  background: var(--accent-soft);
}
.home-step strong {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 700;
}
.home-step p {
  margin: 0;
  font-size: 13px;
  line-height: 1.65;
  color: var(--muted);
}

.home-tools {
  padding: 8px 0 40px;
}
.home-tool-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}
.home-tool-card {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 20px 18px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.9);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  text-decoration: none;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.home-tool-card:hover {
  border-color: rgba(37, 99, 235, 0.32);
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px);
}
.home-tool-icon {
  flex-shrink: 0;
  width: 46px;
  height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  font-size: 20px;
  color: var(--accent);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.12), rgba(99, 102, 241, 0.08));
  border: 1px solid rgba(37, 99, 235, 0.1);
}
.home-tool-body { flex: 1; min-width: 0; }
.home-tool-body strong {
  display: block;
  margin-bottom: 6px;
  font-size: 16px;
  font-weight: 700;
}
.home-tool-body span {
  display: block;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.home-tool-card em {
  flex-shrink: 0;
  align-self: center;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  font-style: normal;
  font-size: 16px;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  transition: transform 0.2s, background 0.2s;
}
.home-tool-card:hover em {
  transform: translateX(2px);
  background: rgba(37, 99, 235, 0.14);
}

.home-batch {
  padding: 8px 0 40px;
}
.home-batch-shell {
  padding: 0;
  overflow: hidden;
}
.home-batch-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 24px 24px 0;
}
.home-batch-head h2 {
  margin: 0 0 8px;
  font-size: clamp(24px, 3vw, 30px);
  font-weight: 800;
  letter-spacing: -0.02em;
}
.home-batch-head p { margin: 0; max-width: 640px; }
.home-batch-badge {
  flex-shrink: 0;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  border: 1px solid rgba(37, 99, 235, 0.12);
}
.home-batch-toolbar {
  padding: 20px 24px 0;
}
.home-batch-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}
.home-batch-tip {
  margin: 0 0 4px;
  font-size: 12px;
}
.home-batch .batch-grid {
  padding: 16px 24px 24px;
}

.home-highlights {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  padding: 8px 0 56px;
}
.home-highlight {
  padding: 24px 22px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(248, 250, 252, 0.88));
  box-shadow: var(--shadow-sm);
}
.home-highlight-icon {
  display: inline-flex;
  width: 42px;
  height: 42px;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  border-radius: 12px;
  font-size: 20px;
  background: var(--accent-soft);
}
.home-highlight strong {
  display: block;
  margin-bottom: 8px;
  font-size: 17px;
  font-weight: 700;
}
.home-highlight p {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
}

@media (max-width: 1080px) {
  .home-hero-inner { grid-template-columns: 1fr; }
  .home-hero-visual { max-width: 520px; margin: 0 auto; min-height: 300px; }
  .home-hero-stats { max-width: none; }
  .home-tool-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-steps-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
  .home-hero { padding: 24px 0 40px; }
  .home-hero-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-hero-card-float { display: none; }
  .home-section-head { flex-direction: column; align-items: flex-start; }
  .home-steps-grid,
  .home-tool-grid,
  .home-highlights { grid-template-columns: 1fr; }
  .home-batch-head { flex-direction: column; }
  .home-batch-toolbar,
  .home-batch-head,
  .home-batch .batch-grid { padding-left: 18px; padding-right: 18px; }
}
@media (max-width: 480px) {
  .home-hero-actions .btn-lg { width: 100%; justify-content: center; }
  .home-batch-actions .btn { flex: 1 1 calc(50% - 5px); justify-content: center; }
}

.tool-cards {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  padding-bottom: 32px;
}
.tool-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow-sm);
  color: var(--text);
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.tool-card:hover {
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow: var(--shadow);
  transform: translateY(-2px);
}
.tool-card strong { font-size: 16px; font-weight: 700; }
.tool-card span { color: var(--muted); font-size: 13px; line-height: 1.6; flex: 1; }
.tool-card em { color: var(--accent); font-style: normal; font-size: 13px; font-weight: 600; }
@media (max-width: 980px) { .tool-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .tool-cards { grid-template-columns: 1fr; } }

.tool-hero { padding-top: 28px; padding-bottom: 16px; }
.studio-single { padding-top: 8px; }

/* ===== 工作室布局 ===== */
.studio {
  display: grid; grid-template-columns: 1.45fr 0.95fr;
  gap: 24px; padding: 24px 0 64px;
}
@media (max-width: 980px) { .studio { grid-template-columns: 1fr; } }

.panel {
  position: relative;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.panel::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit;
  background: linear-gradient(180deg, rgba(37,99,235,0.03), transparent 30%);
}
.panel-head {
  display: flex; align-items: baseline; justify-content: space-between;
  padding: 20px 22px 0;
}
.panel h3 {
  margin: 0; font-size: 13px; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--muted); font-weight: 700;
}
.meta { font-variant-numeric: tabular-nums; color: var(--muted); font-size: 13px; }

.drop {
  margin: 18px; min-height: 420px;
  border: 2px dashed var(--line-2);
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
  background: linear-gradient(180deg, #fafbfc, #f8fafc);
  transition: border-color .25s, background-color .25s;
  cursor: pointer;
}
.drop.drag {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px rgba(37,99,235,0.1);
}
.drop img, .drop canvas { max-width: 100%; max-height: 520px; display: block; border-radius: 8px; }
.drop.is-cropping { cursor: crosshair; touch-action: none; }
.drop.is-cropping img { -webkit-user-drag: none; user-select: none; -webkit-touch-callout: none; }
.crop-box {
  position: absolute; border: 2px solid var(--accent);
  box-shadow: 0 0 0 9999px rgba(15,23,42,0.45);
  cursor: move; display: none;
  touch-action: none;
}
.crop-size {
  position: absolute; left: 50%; top: -32px; transform: translateX(-50%);
  background: rgba(15,23,42,0.85); color: #fff;
  font-size: 12px; line-height: 24px; padding: 0 10px;
  border-radius: 4px; white-space: nowrap; pointer-events: none;
  font-variant-numeric: tabular-nums;
}
.crop-box.pos-top .crop-size { top: auto; bottom: -32px; }
.crop-handle {
  position: absolute; width: 14px; height: 14px;
  background: #fff; border: 2px solid var(--accent); border-radius: 3px;
  box-shadow: 0 1px 4px rgba(15,23,42,0.3);
}
.crop-handle.nw { left: -8px; top: -8px; cursor: nwse-resize; }
.crop-handle.n  { left: calc(50% - 7px); top: -8px; cursor: ns-resize; }
.crop-handle.ne { right: -8px; top: -8px; cursor: nesw-resize; }
.crop-handle.e  { right: -8px; top: calc(50% - 7px); cursor: ew-resize; }
.crop-handle.se { right: -8px; bottom: -8px; cursor: nwse-resize; }
.crop-handle.s  { left: calc(50% - 7px); bottom: -8px; cursor: ns-resize; }
.crop-handle.sw { left: -8px; bottom: -8px; cursor: nesw-resize; }
.crop-handle.w  { left: -8px; top: calc(50% - 7px); cursor: ew-resize; }
.hint { text-align: center; color: var(--muted); padding: 28px; }
.drop-icon { color: var(--accent); opacity: 0.9; margin: 0 auto 16px; display: block; }
.hint strong {
  display: block; color: var(--text); font-size: 18px; font-weight: 700; margin-bottom: 8px;
}
.hint > span { font-size: 13px; color: var(--muted-2); }

.file-input {
  position: absolute;
  width: 0.1px;
  height: 0.1px;
  opacity: 0;
  overflow: hidden;
  z-index: -1;
}

.wm-bg-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-top: 4px;
}
.wm-bg-row .check { margin: 0; white-space: nowrap; }
.wm-bg-color-field { flex: 1; min-width: 140px; margin: 0; }

.tools { padding: 12px 20px 22px; }
.tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 18px; }
.tab {
  border: 1px solid var(--line);
  background: #f8fafc;
  color: var(--muted);
  border-radius: 999px;
  padding: 8px 14px; cursor: pointer; font-size: 13px; font-weight: 500;
  transition: color .2s, background .2s, border-color .2s;
}
.tab:hover { color: var(--accent); border-color: rgba(37,99,235,0.3); background: var(--accent-soft); }
.tab.on {
  color: #fff; background: linear-gradient(135deg, var(--accent-light), var(--accent-2));
  border-color: transparent;
  box-shadow: 0 4px 12px var(--accent-glow);
}

.field { margin: 14px 0; }
.field label {
  display: block; font-size: 13px; color: var(--muted);
  margin-bottom: 8px; font-weight: 600;
}
.field input, .field select, .field textarea {
  width: 100%;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: var(--radius-sm); padding: 11px 14px; outline: none;
  transition: border-color .2s, box-shadow .2s;
  font-size: 14px;
}
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}
.field input::placeholder, .field textarea::placeholder { color: var(--muted-2); }
.field textarea {
  min-height: 84px;
  resize: vertical;
  line-height: 1.55;
  font-family: inherit;
}
.field input[type=color] { padding: 6px; height: 44px; cursor: pointer; }

input[type=range] {
  -webkit-appearance: none; appearance: none; width: 100%; height: 6px;
  background: linear-gradient(90deg, var(--accent) 0%, var(--accent-light) var(--p,50%), var(--line) var(--p,50%));
  border-radius: 999px; outline: none; cursor: pointer;
}
input[type=range]::-webkit-slider-thumb {
  -webkit-appearance: none; appearance: none;
  width: 18px; height: 18px; border-radius: 50%;
  background: #fff; border: 2px solid var(--accent);
  box-shadow: var(--shadow-sm); cursor: pointer;
}
input[type=range]::-moz-range-thumb {
  width: 16px; height: 16px; border-radius: 50%;
  background: #fff; border: 2px solid var(--accent); cursor: pointer;
}

.row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.check { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; cursor: pointer; }
.check input { accent-color: var(--accent); }

.actions { display: flex; gap: 12px; margin-top: 18px; flex-wrap: wrap; align-items: center; }
.btn {
  appearance: none; border: 0; cursor: pointer;
  border-radius: var(--radius-sm); padding: 11px 20px;
  font-weight: 600; font-size: 14px;
  transition: transform .15s, box-shadow .2s, background .2s;
}
.btn-sm { padding: 8px 16px; font-size: 13px; }
.btn-lg { padding: 14px 28px; font-size: 15px; border-radius: 12px; }
.btn-primary {
  background: linear-gradient(135deg, var(--accent-light), var(--accent-2));
  color: #fff;
  box-shadow: 0 4px 14px var(--accent-glow);
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 8px 20px var(--accent-glow); }
.btn-ghost {
  background: #fff; color: var(--text);
  border: 1px solid var(--line);
}
.btn-ghost:hover { background: var(--accent-soft); border-color: rgba(37,99,235,0.25); color: var(--accent); }
.btn-danger { background: var(--danger); color: white; }
.btn:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }
.btn:active:not(:disabled) { transform: translateY(0); }

.toast {
  position: fixed; right: 24px; bottom: 24px; z-index: 50;
  background: var(--panel); border: 1px solid var(--line);
  padding: 14px 20px; border-radius: var(--radius-sm); display: none;
  box-shadow: var(--shadow-lg); font-size: 14px; color: var(--text);
}

.footer {
  display: flex; align-items: center; justify-content: space-between;
  padding: 32px 0 48px; margin-top: 24px;
  border-top: 1px solid var(--line); color: var(--muted);
}
.foot-brand { display: flex; align-items: center; gap: 10px; font-weight: 700; color: var(--text); }

.page-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-shell > .wrap,
.page-shell .page-center {
  flex: 1;
  min-height: auto;
}

.page-shell .page-center {
  padding-bottom: 24px;
}

.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.55) 0%, rgba(248, 250, 252, 0.92) 100%);
  backdrop-filter: blur(10px);
}

.site-footer-wrap {
  width: min(1280px, calc(100% - 40px));
  margin: 0 auto;
  padding: 40px 0 28px;
}

.site-footer-main {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr);
  gap: 40px;
  padding-bottom: 28px;
  border-bottom: 1px solid rgba(226, 232, 240, 0.95);
}

.site-footer-brand .brand {
  margin-bottom: 14px;
}

.site-footer-desc {
  margin: 0;
  max-width: 440px;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.75;
}

.site-footer-nav {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px 20px;
}

.site-footer-col {
  display: flex;
  flex-direction: column;
  gap: 9px;
}

.site-footer-col strong {
  margin-bottom: 2px;
  font-size: 12px;
  color: var(--text);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-footer-col a {
  color: var(--muted);
  text-decoration: none;
  font-size: 14px;
  line-height: 1.5;
  transition: color .2s;
}

.site-footer-col a:hover {
  color: var(--accent);
}

.site-footer-bottom {
  padding-top: 22px;
}

.site-footer-contact {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0 0;
  padding: 8px 12px;
  border-radius: 999px;
  background: rgba(37, 99, 235, 0.06);
  font-size: 13px;
  color: var(--muted);
}

.site-footer-contact span {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}

.site-footer-muted {
  display: block;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted-2);
}

@media (max-width: 860px) {
  .site-footer-main {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .site-footer-nav {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .site-footer-wrap {
    width: calc(100% - 24px);
    padding: 32px 0 24px;
  }

  .site-footer-nav {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 480px) {
  .site-footer-nav {
    grid-template-columns: 1fr;
  }

  .site-copyright-top {
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
  }
}

/* ===== 登录 / 安装 / 后台 / 会员 ===== */
.page-center {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 40px 20px;
}
.auth-card, .install-card {
  width: min(440px, calc(100% - 32px));
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 36px 32px 32px;
}
.auth-card h1, .install-card h1 {
  font-size: 26px; font-weight: 800; margin: 16px 0 6px; color: var(--text);
}
.auth-card .brand, .install-card .brand { margin-bottom: 8px; }
.auth-lead { margin: 0 0 4px; }
.auth-gift {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 700;
}
.auth-alert {
  margin: 16px 0 0;
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  line-height: 1.55;
}
.auth-alert.bad {
  background: rgba(239, 68, 68, 0.08);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.18);
}
.auth-tabs {
  display: flex;
  gap: 4px;
  padding: 4px;
  margin: 18px 0 6px;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
}
.auth-tab {
  flex: 1;
  padding: 10px 12px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background .2s, color .2s, box-shadow .2s;
}
.auth-tab:hover { color: var(--text); }
.auth-tab.on {
  background: var(--panel);
  color: var(--accent);
  box-shadow: var(--shadow-sm);
}
.auth-form .field { margin: 16px 0; }
.auth-sms-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 10px;
  align-items: center;
}
.auth-sms-row input { min-width: 0; }
.auth-sms-row .btn { white-space: nowrap; flex-shrink: 0; }
.auth-actions {
  margin-top: 22px;
}
.auth-actions .btn-lg { flex: 1; min-width: 140px; justify-content: center; }
.auth-foot {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  text-align: center;
  font-size: 14px;
}
.auth-agree {
  margin: 18px 0 0;
  align-items: flex-start;
  line-height: 1.55;
  font-size: 13px;
  color: var(--muted);
}
.auth-agree input { margin-top: 3px; flex-shrink: 0; accent-color: var(--accent); }
.auth-agree a { color: var(--accent); text-decoration: none; }
.auth-agree a:hover { text-decoration: underline; }
.legal-page {
  max-width: 960px;
  margin: 0 auto;
  padding: 0 0 48px;
}
.legal-hero {
  max-width: 960px;
  padding-bottom: 20px;
}
.legal-hero .legal-breadcrumb {
  margin-bottom: 12px;
}
.legal-lead {
  margin: 0 0 10px;
  max-width: 640px;
  color: var(--muted);
  line-height: 1.75;
  font-size: 15px;
}
.legal-meta {
  margin: 0 0 16px;
  font-size: 13px;
}
.legal-switch {
  display: inline-flex;
  gap: 6px;
  padding: 4px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line);
  box-shadow: 0 4px 18px rgba(15, 23, 42, 0.04);
}
.legal-switch-link {
  display: inline-flex;
  align-items: center;
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 13px;
  font-weight: 600;
  color: var(--muted);
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}
.legal-switch-link:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.9);
}
.legal-switch-link.is-active {
  color: #fff;
  background: linear-gradient(135deg, var(--accent), #6366f1);
  box-shadow: 0 6px 16px rgba(99, 102, 241, 0.28);
}
.legal-layout {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}
.legal-toc {
  position: sticky;
  top: 88px;
  padding: 18px 16px;
}
.legal-toc-title {
  display: block;
  margin-bottom: 12px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
}
.legal-toc-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 4px;
}
.legal-toc-list a {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 10px;
  font-size: 13px;
  line-height: 1.45;
  color: var(--muted);
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}
.legal-toc-list a:hover {
  color: var(--accent);
  background: rgba(99, 102, 241, 0.08);
}
.legal-toc-num {
  flex-shrink: 0;
  width: 28px;
  font-size: 11px;
  font-weight: 700;
  color: var(--muted-2);
  font-variant-numeric: tabular-nums;
}
.legal-card {
  padding: 0;
  overflow: hidden;
}
.legal-breadcrumb {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
}
.legal-breadcrumb a { color: var(--accent); text-decoration: none; }
.legal-breadcrumb a:hover { text-decoration: underline; }
.legal-breadcrumb span { margin: 0 6px; color: var(--muted-2); }
.legal-body {
  padding: 24px 26px 8px;
  color: var(--text);
  line-height: 1.8;
  font-size: 15px;
}
html:has(.page-legal) {
  scroll-behavior: smooth;
}
.legal-intro {
  margin-bottom: 8px;
  padding: 16px 18px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(14, 165, 233, 0.06));
  border: 1px solid rgba(99, 102, 241, 0.12);
}
.legal-intro p {
  margin: 0;
  color: var(--text);
}
.legal-section + .legal-section {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px dashed var(--line);
}
.legal-section h2 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  margin: 0 0 12px;
  color: var(--text);
  scroll-margin-top: 96px;
}
.legal-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  height: 34px;
  border-radius: 10px;
  font-size: 12px;
  font-weight: 800;
  color: var(--accent);
  background: rgba(99, 102, 241, 0.1);
}
.legal-section p {
  margin: 0;
  color: var(--muted);
}
.legal-section a {
  color: var(--accent);
  text-decoration: none;
}
.legal-section a:hover { text-decoration: underline; }
.legal-foot {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 18px 26px 24px;
  border-top: 1px solid var(--line);
  background: rgba(248, 250, 252, 0.72);
}
@media (max-width: 860px) {
  .legal-layout {
    grid-template-columns: 1fr;
  }
  .legal-toc {
    position: static;
    padding: 14px 16px;
  }
  .legal-toc-list {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
  }
  .legal-toc-list li { flex: 0 0 auto; }
  .legal-toc-list a {
    white-space: nowrap;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.8);
  }
  .legal-toc-num { display: none; }
  .legal-body { padding: 20px 18px 6px; }
  .legal-foot { padding: 16px 18px 20px; }
}
@media (max-width: 480px) {
  .legal-switch {
    display: flex;
    width: 100%;
  }
  .legal-switch-link {
    flex: 1;
    justify-content: center;
  }
}
.field-hint {
  display: block;
  margin-top: 6px;
  color: var(--muted-2);
  font-size: 12px;
  line-height: 1.5;
}
.field.pwd { position: relative; }
.field.pwd input { padding-right: 72px; }
.field.pwd .pwd-toggle {
  position: absolute;
  right: 12px;
  top: 38px;
  padding: 4px 0;
  border: 0;
  background: transparent;
  color: var(--accent);
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}
.field.pwd .pwd-toggle:hover { color: var(--accent-2); }
.muted { color: var(--muted); font-size: 14px; line-height: 1.6; }
.sms-debug-tip {
  margin: 12px 0 0;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px;
  line-height: 1.6;
}
.ok { color: var(--ok); } .bad { color: var(--danger); }

.layout { display: grid; grid-template-columns: 240px 1fr; gap: 24px; padding: 24px 0 64px; }
.side {
  background: var(--panel); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 12px; height: fit-content;
  box-shadow: var(--shadow-sm);
}
.side a {
  display: block; color: var(--muted); padding: 12px 16px; border-radius: var(--radius-sm);
  font-weight: 500; font-size: 14px;
}
.side a.on, .side a:hover { background: var(--accent-soft); color: var(--accent); font-weight: 600; }

.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th, .table td { padding: 12px 10px; border-bottom: 1px solid var(--line); text-align: left; }
.table th { color: var(--muted); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: 0.06em; }
.table tr:hover td { background: #fafbfc; }

.grid-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 14px; }
.card-img {
  background: var(--panel); border-radius: var(--radius-sm);
  overflow: hidden; border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.card-img img { width: 100%; height: 140px; object-fit: cover; display: block; }
.card-img p { margin: 0; padding: 10px 12px; font-size: 12px; color: var(--muted); }

.stat { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat .panel { padding: 22px; }
.stat .panel p { margin: 0 0 8px; }
.stat b { font-size: 20px; font-weight: 700; color: var(--text); }
.stat .panel:first-child b,
.stat .panel:nth-child(2) b { font-size: 32px; font-weight: 800; color: var(--accent); }
@media (max-width: 900px) { .layout, .stat { grid-template-columns: 1fr; } }

.batch-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 12px;
  padding: 0 18px 18px;
}
.batch-empty { padding: 8px 18px 18px; margin: 0; }
.batch-card {
  position: relative;
  background: var(--panel);
  border: 2px solid var(--line);
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  transition: border-color .2s, box-shadow .2s;
}
.batch-card.active { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.batch-card img { width: 100%; height: 100px; object-fit: cover; display: block; }
.batch-card p {
  margin: 0; padding: 6px 8px 0; font-size: 12px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.batch-card span { display: block; padding: 0 8px 8px; font-size: 11px; }
.batch-check {
  position: absolute; top: 6px; left: 6px; z-index: 2;
  background: rgba(255,255,255,0.92); border-radius: 4px; padding: 2px 4px;
}
.batch-check input { accent-color: var(--accent); }

.wm-mode { display: flex; gap: 8px; margin-bottom: 14px; }
.wm-mode-btn { flex: 1; text-align: center; }
.wm-upload.box {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 14px; border: 1px dashed var(--line-2); border-radius: var(--radius-sm);
  background: #f8fafc; margin-bottom: 12px;
}
.wm-preview {
  width: 64px; height: 64px; object-fit: contain;
  border: 1px solid var(--line); border-radius: 8px; background: #fff; padding: 4px;
}
.wm-tpl-select-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); border: 0;
}
.wm-tpl-grid {
  display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px;
}
.wm-tpl-card {
  width: 72px; cursor: pointer; text-align: center;
  border: 2px solid var(--line); border-radius: 8px;
  background: #fff; padding: 6px 4px 4px; transition: border-color .2s, box-shadow .2s;
}
.wm-tpl-card:hover { border-color: var(--accent); }
.wm-tpl-card.on {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-soft);
}
.wm-tpl-card img, .wm-tpl-card .wm-tpl-icon {
  width: 48px; height: 48px; object-fit: contain;
  display: block; margin: 0 auto 4px; border-radius: 4px;
  background: #f8fafc;
}
.wm-tpl-card .wm-tpl-icon {
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; color: var(--muted);
}
.wm-tpl-card span {
  display: block; font-size: 11px; color: var(--muted);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.wm-drag-hint { font-size: 12px; margin: 8px 0 0; line-height: 1.5; }
.drop.is-wm-drag { cursor: default; touch-action: none; }
.drop.is-wm-drag img { -webkit-user-drag: none; user-select: none; }
.wm-overlay { position: absolute; inset: 0; pointer-events: none; z-index: 4; }
.wm-drag {
  position: absolute; pointer-events: auto; touch-action: none;
  border: 2px dashed rgba(37,99,235,0.85); border-radius: 6px;
  background: rgba(255,255,255,0.08); cursor: move;
  box-sizing: border-box; min-width: 40px; min-height: 24px;
}
.wm-drag-img { z-index: 2; border-color: rgba(16,185,129,0.9); }
.wm-drag-text { z-index: 3; border-color: rgba(37,99,235,0.9); }
.wm-drag-img-el {
  width: 100%; height: 100%; object-fit: contain;
  pointer-events: none; display: block; border-radius: 4px;
}
.wm-drag-tag {
  position: absolute; top: -22px; left: 0;
  font-size: 11px; line-height: 18px; padding: 0 6px;
  border-radius: 4px; color: #fff; pointer-events: none; white-space: nowrap;
}
.wm-drag-img .wm-drag-tag { background: rgba(16,185,129,0.92); }
.wm-drag-text .wm-drag-tag { background: rgba(37,99,235,0.92); }
.wm-drag-text-inner {
  width: 100%; height: 100%; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  text-align: center; pointer-events: none; padding: 2px 4px;
  word-break: break-all; line-height: 1.25;
  transform-origin: center center;
}
.wm-handle {
  position: absolute; width: 12px; height: 12px;
  background: #fff; border: 2px solid var(--accent); border-radius: 3px;
  box-shadow: 0 1px 3px rgba(15,23,42,0.25); z-index: 1;
}
.wm-drag-img .wm-handle { border-color: rgba(16,185,129,0.95); }
.wm-handle.nw { left: -7px; top: -7px; cursor: nwse-resize; }
.wm-handle.ne { right: -7px; top: -7px; cursor: nesw-resize; }
.wm-handle.sw { left: -7px; bottom: -7px; cursor: nesw-resize; }
.wm-handle.se { right: -7px; bottom: -7px; cursor: nwse-resize; }
.wm-align-row { display: flex; gap: 8px; margin-top: 6px; }
.wm-align-btn {
  flex: 1; padding: 8px 10px; font-size: 13px;
  border: 1px solid var(--line-2); border-radius: 8px;
  background: #fff; color: var(--muted); cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
}
.wm-align-btn:hover { border-color: var(--accent); color: var(--accent); }
.wm-align-btn.on {
  border-color: var(--accent); color: var(--accent);
  background: var(--accent-soft); font-weight: 600;
}
.wm-pos-row { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.wm-pos-btn {
  flex: 1 1 calc(33.33% - 8px); min-width: 64px; padding: 8px 6px; font-size: 13px;
  border: 1px solid var(--line-2); border-radius: 8px;
  background: #fff; color: var(--muted); cursor: pointer;
  transition: border-color .2s, color .2s, background .2s;
}
.wm-pos-btn:hover { border-color: var(--accent); color: var(--accent); }
.wm-pos-btn.on {
  border-color: var(--accent); color: var(--accent);
  background: var(--accent-soft); font-weight: 600;
}
.wm-pos-hint { font-size: 12px; margin: 6px 0 0; line-height: 1.45; }

/* ===== 会员中心扩展 ===== */
.page-head { padding: 4px 0 24px; }
.page-head .eyebrow { padding-bottom: 12px; }
.page-head h1 {
  font-size: clamp(26px, 3.6vw, 34px);
  font-weight: 800; margin: 0 0 6px; letter-spacing: -0.02em; color: var(--text);
}
.page-head p { margin: 0; color: var(--muted); font-size: 14px; }

.side-head { padding: 14px 16px 12px; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.side-head .label { font-size: 11px; letter-spacing: 0.26em; color: var(--muted-2); text-transform: uppercase; font-weight: 700; }
.side-head .name { font-size: 15px; margin-top: 4px; color: var(--text); font-weight: 700; }

.balance { padding: 20px 22px; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; }
.balance b { font-size: 32px; font-weight: 800; color: var(--accent); line-height: 1; }

.pkg-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; }
.pkg { padding: 24px; display: flex; flex-direction: column; gap: 6px; }
.pkg .pkg-name { font-size: 16px; font-weight: 700; color: var(--text); }
.pkg .pkg-points { font-size: 32px; font-weight: 800; color: var(--accent); line-height: 1.1; }
.pkg .pkg-points small { font-size: 13px; color: var(--muted); font-weight: 600; margin-left: 4px; }
.pkg .pkg-price { color: var(--muted); font-size: 13px; }
.pkg .pkg-price b { color: var(--text); font-size: 22px; font-weight: 800; }
.pkg .actions { margin-top: 16px; }

.panel-body { padding: 18px 22px 22px; }
.panel-body + .panel-body { padding-top: 0; }

.pagination { list-style: none; display: flex; gap: 6px; padding: 0; margin: 18px 0 0; flex-wrap: wrap; }
.pagination li { list-style: none; }
.pagination li a, .pagination li span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 34px; height: 34px; padding: 0 10px;
  border-radius: 8px; border: 1px solid var(--line);
  color: var(--muted); font-size: 13px; text-decoration: none; font-weight: 600;
}
.pagination li a:hover { color: var(--accent); border-color: rgba(37,99,235,0.3); background: var(--accent-soft); }
.pagination li.active a, .pagination li.active span {
  background: linear-gradient(135deg, var(--accent-light), var(--accent-2));
  color: #fff; border-color: transparent;
}
.idphoto-swatches {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.idphoto-swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  padding: 10px 6px;
  border: 2px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  transition: border-color .2s, box-shadow .2s, color .2s;
}

.idphoto-swatch span {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(15, 23, 42, 0.12);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.35);
}

.idphoto-swatch.is-active {
  border-color: var(--accent);
  color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

@media (max-width: 560px) {
  .idphoto-swatches { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* ===== 新闻资讯 ===== */
.news-hero { padding-bottom: 12px; }
.news-toolbar { margin-bottom: 24px; }
.news-search {
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.news-search input {
  flex: 1 1 220px; min-width: 0; max-width: 360px;
  height: 40px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 10px;
  background: rgba(255,255,255,0.85);
}
.news-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 32px;
}
.news-card {
  display: flex; flex-direction: column;
  background: rgba(255,255,255,0.82);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform .2s, box-shadow .2s;
}
.news-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow);
}
.news-card-cover {
  display: block; aspect-ratio: 16/9; overflow: hidden;
  background: var(--accent-soft);
}
.news-card-cover img {
  width: 100%; height: 100%; object-fit: cover;
}
.news-card-body { padding: 18px 20px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.news-meta { font-size: 12px; color: var(--muted-2); }
.news-card h2 {
  margin: 0; font-size: 18px; line-height: 1.45;
}
.news-card h2 a {
  color: var(--text); text-decoration: none;
}
.news-card h2 a:hover { color: var(--accent); }
.news-card p {
  margin: 0; color: var(--muted); font-size: 14px; line-height: 1.65;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.news-read-more {
  margin-top: auto; padding-top: 8px;
  font-size: 13px; font-weight: 600; color: var(--accent); text-decoration: none;
}
.news-read-more:hover { text-decoration: underline; }
.news-empty {
  grid-column: 1 / -1;
  text-align: center; padding: 48px 20px;
  background: rgba(255,255,255,0.72);
  border: 1px dashed var(--line); border-radius: var(--radius);
}
.news-empty strong { display: block; font-size: 18px; margin-bottom: 8px; }
.news-empty span { color: var(--muted); font-size: 14px; }
.news-pagination { margin-bottom: 40px; }
.news-pagination .pagination { justify-content: center; }

.news-detail { max-width: 820px; margin: 0 auto 48px; }
.news-breadcrumb {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 13px; color: var(--muted); margin-bottom: 20px;
}
.news-breadcrumb a { color: var(--muted); text-decoration: none; }
.news-breadcrumb a:hover { color: var(--accent); }
.news-detail-head { margin-bottom: 24px; }
.news-detail-head h1 {
  margin: 0 0 12px; font-size: clamp(26px, 4vw, 36px); line-height: 1.35;
}
.news-detail-meta {
  display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  font-size: 13px; color: var(--muted-2);
}
.news-detail-cover {
  margin: 0 0 24px; border-radius: var(--radius); overflow: hidden;
  border: 1px solid var(--line);
}
.news-detail-cover img { width: 100%; display: block; }
.news-detail-summary {
  margin: 0 0 24px; padding: 16px 18px;
  background: var(--accent-soft); border-left: 3px solid var(--accent);
  border-radius: 0 10px 10px 0; color: var(--muted); line-height: 1.7;
}
.news-detail-content {
  padding: 24px 0;
  line-height: 1.85; font-size: 16px; color: var(--text);
  word-break: break-word;
}
.news-detail-content p { margin: 0 0 1em; }
.news-detail-content img { max-width: 100%; height: auto; border-radius: 8px; }
.news-detail-content h2, .news-detail-content h3 {
  margin: 1.5em 0 0.75em; line-height: 1.4;
}
.news-detail-foot { padding-top: 16px; border-top: 1px solid var(--line); }

.admin-cell-sub {
  display: block; max-width: 280px;
  font-size: 12px; line-height: 1.5;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}

.site-copyright-block {
  font-size: 12px;
  line-height: 1.65;
}

.site-copyright-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.site-copyright-main {
  margin: 0;
  color: var(--text);
  font-weight: 600;
  font-size: 13px;
}

.site-copyright-meta,
.site-copyright-legal {
  margin: 0 0 4px;
  font-size: 11px;
  line-height: 1.6;
}

.site-copyright-meta a,
.site-copyright-legal a {
  color: var(--accent);
  text-decoration: none;
}

.site-copyright-meta a:hover {
  text-decoration: underline;
}

.site-footer-icp {
  flex-shrink: 0;
  font-size: 12px;
  color: var(--muted);
  text-decoration: none;
  white-space: nowrap;
}

.site-footer-icp:hover {
  color: var(--accent);
}

.auth-copyright {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}

.auth-copyright .site-copyright-block {
  text-align: left;
}

.auth-copyright .site-copyright-top {
  flex-direction: column;
  align-items: flex-start;
}
.install-copyright {
  max-width: 920px; margin: 0 auto; padding: 20px 24px 28px;
  text-align: center; font-size: 12px; line-height: 1.6;
}
.install-copyright a { color: var(--accent); text-decoration: none; }
.install-copyright a:hover { text-decoration: underline; }

/* ── 前台客服 ── */
.cs-widget { position: fixed; right: 20px; bottom: 88px; z-index: 1200; }
.cs-fab {
  display: flex; align-items: center; gap: 8px;
  padding: 12px 16px; border: none; border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), #1d4ed8);
  color: #fff; font-size: 14px; font-weight: 600; cursor: pointer;
  box-shadow: 0 10px 30px rgba(37, 99, 235, .35);
  transition: transform .2s ease, box-shadow .2s ease;
}
.cs-fab:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(37, 99, 235, .42); }
.cs-fab-icon { font-size: 18px; line-height: 1; }
.cs-panel {
  position: absolute; right: 0; bottom: calc(100% + 12px); width: min(320px, calc(100vw - 40px));
  background: rgba(255,255,255,.98); border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 18px 50px rgba(15, 23, 42, .16); overflow: hidden;
}
.cs-panel-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px; border-bottom: 1px solid var(--line); background: rgba(37,99,235,.06);
}
.cs-panel-head strong { font-size: 15px; }
.cs-panel-close {
  width: 28px; height: 28px; border: none; border-radius: 8px; background: transparent;
  color: var(--muted); font-size: 20px; line-height: 1; cursor: pointer;
}
.cs-panel-close:hover { background: rgba(15,23,42,.06); color: var(--text); }
.cs-panel-body { padding: 14px 16px 16px; max-height: min(70vh, 420px); overflow: auto; }
.cs-intro { margin: 0 0 10px; font-size: 13px; line-height: 1.6; color: var(--muted); }
.cs-work-time { margin: 0 0 12px; font-size: 12px; color: var(--muted); }
.cs-work-time span { display: inline-block; margin-right: 6px; padding: 2px 8px; border-radius: 999px; background: rgba(37,99,235,.08); color: var(--accent); }
.cs-list { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 8px; }
.cs-item {
  display: grid; grid-template-columns: 1fr auto; gap: 4px 8px; align-items: center;
  padding: 10px 12px; border-radius: 12px; background: rgba(15,23,42,.03); border: 1px solid var(--line);
}
.cs-item-label { grid-column: 1 / -1; font-size: 11px; color: var(--muted); }
.cs-item-value { font-size: 14px; font-weight: 600; color: var(--text); text-decoration: none; word-break: break-all; }
a.cs-item-value:hover { color: var(--accent); }
.cs-copy-btn {
  padding: 4px 10px; border: 1px solid var(--line); border-radius: 8px; background: #fff;
  font-size: 12px; color: var(--muted); cursor: pointer;
}
.cs-copy-btn:hover { color: var(--accent); border-color: rgba(37,99,235,.25); }
.cs-qr { text-align: center; margin: 12px 0; padding-top: 8px; border-top: 1px dashed var(--line); }
.cs-qr img { width: 140px; height: 140px; object-fit: contain; border-radius: 12px; border: 1px solid var(--line); background: #fff; }
.cs-qr p { margin: 8px 0 0; font-size: 12px; color: var(--muted); }
.cs-online-btn { margin-top: 8px; }
.cs-page-link { display: block; margin-top: 10px; font-size: 12px; color: var(--accent); text-decoration: none; text-align: center; }
.cs-page-link:hover { text-decoration: underline; }
.cs-page { padding-bottom: 24px; }
.cs-page-card { padding: 20px; }
.cs-page-meta { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.cs-page-meta-label { font-size: 12px; color: var(--muted); padding: 4px 10px; border-radius: 999px; background: rgba(37,99,235,.08); color: var(--accent); }
.cs-page-grid { display: grid; gap: 12px; }
.cs-page-item {
  display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: center;
  padding: 14px 16px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255,255,255,.72);
}
.cs-page-item-icon { font-size: 24px; }
.cs-page-item strong { display: block; font-size: 13px; color: var(--muted); margin-bottom: 4px; }
.cs-page-item a, .cs-page-item p { margin: 0; font-size: 15px; font-weight: 600; color: var(--text); text-decoration: none; word-break: break-all; }
.cs-page-item a:hover { color: var(--accent); }
.cs-page-qr { margin-top: 20px; text-align: center; padding-top: 16px; border-top: 1px dashed var(--line); }
.cs-page-qr img { width: 180px; height: 180px; object-fit: contain; border-radius: 14px; border: 1px solid var(--line); background: #fff; }
.cs-page-qr p { margin-top: 10px; color: var(--muted); font-size: 13px; }
.cs-page-actions { margin-top: 20px; text-align: center; }
.cs-page-empty {
  margin-top: 8px;
  padding: 28px 20px;
  text-align: center;
  border-radius: 14px;
  background: #f8fafc;
  border: 1px dashed var(--line);
}
.cs-page-empty p { margin: 0 0 8px; line-height: 1.7; }
.cs-page-empty p:last-child { margin-bottom: 0; }
@media (max-width: 768px) {
  .cs-widget { right: 14px; bottom: calc(64px + env(safe-area-inset-bottom, 0px)); }
  .cs-fab-text { display: none; }
  .cs-fab { width: 52px; height: 52px; padding: 0; justify-content: center; border-radius: 50%; }
}
