/* ==========================================================================
   七宗罪 VS 七美德测试 - 全局样式规范
   移动优先 / 纯本地前端 / 零外链
   ========================================================================== */

:root {
  --bg-primary: #0b0d13;
  --bg-secondary: #131722;
  --bg-card: #181d2b;
  --bg-card-hover: #1f2536;
  
  --border-subtle: #242c3d;
  --border-focus: #3b465e;
  
  /* 暗影（七宗罪）主色：深赤 / 炽炎 */
  --sin-crimson: #ef4444;
  --sin-glow: rgba(239, 68, 68, 0.25);
  --sin-bg: rgba(239, 68, 68, 0.08);
  --sin-border: rgba(239, 68, 68, 0.3);

  /* 光辉（七美德）主色：琥珀金 / 晨曦暖金 */
  --virtue-gold: #f59e0b;
  --virtue-glow: rgba(245, 158, 11, 0.25);
  --virtue-bg: rgba(245, 158, 11, 0.08);
  --virtue-border: rgba(245, 158, 11, 0.3);

  --text-main: #f3f4f6;
  --text-secondary: #9ca3af;
  --text-muted: #6b7280;

  --font-serif: "Noto Serif SC", "Source Han Serif SC", "Songti SC", "SimSun", "STSong", serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}

html, body {
  width: 100%;
  min-height: 100%;
  background-color: var(--bg-primary);
  color: var(--text-main);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.5;
  overflow-x: hidden;
}

/* 核心视口包裹层 (固定 440px 最大宽度，移动端满宽) */
.app-container {
  width: 100%;
  max-width: 440px;
  min-height: 100vh;
  margin: 0 auto;
  position: relative;
  background-color: var(--bg-primary);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.6);
  display: flex;
  flex-direction: column;
}

/* 视图切换机制 */
.view {
  display: none;
  flex-direction: column;
  width: 100%;
  min-height: 100vh;
  padding: 20px 18px 36px;
  opacity: 0;
  transition: opacity 0.25s ease-in-out;
}

.view.active {
  display: flex;
  opacity: 1;
}

/* ==========================================================================
   首页组件
   ========================================================================== */

.home-header {
  display: flex;
  justify-content: center;
  align-items: center;
  padding-top: 10px;
  padding-bottom: 12px;
}

.brand-crest {
  display: flex;
  align-items: center;
  gap: 10px;
}

.crest-seal {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: radial-gradient(circle, #2d3345 0%, #151821 100%);
  border: 1px solid var(--virtue-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 12px var(--virtue-glow);
}

.crest-roman {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 1px;
  color: var(--virtue-gold);
}

.crest-meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.crest-title {
  font-family: var(--font-serif);
  font-size: 17px;
  font-weight: 600;
  letter-spacing: 1.5px;
  color: var(--text-main);
}

.crest-badge {
  font-size: 11px;
  padding: 2px 7px;
  border-radius: 4px;
  background-color: rgba(245, 158, 11, 0.15);
  color: var(--virtue-gold);
  border: 1px solid rgba(245, 158, 11, 0.3);
  font-weight: 500;
}

/* Hero */
.hero-section {
  text-align: center;
  padding: 16px 8px 12px;
  position: relative;
}

.hero-glow {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 220px;
  height: 120px;
  background: radial-gradient(ellipse at center, rgba(245, 158, 11, 0.15) 0%, rgba(239, 68, 68, 0.08) 50%, transparent 70%);
  filter: blur(24px);
  pointer-events: none;
  z-index: 0;
}

.hero-title {
  position: relative;
  font-family: var(--font-serif);
  font-size: 28px;
  line-height: 1.3;
  font-weight: 700;
  letter-spacing: 2px;
  color: #ffffff;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  margin-bottom: 12px;
}

.hero-desc {
  position: relative;
  font-size: 13px;
  line-height: 1.65;
  color: var(--text-secondary);
  max-width: 360px;
  margin: 0 auto;
}

/* 轮盘 */
.wheel-section {
  margin: 14px 0 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.wheel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 0 4px 10px;
}

.section-label {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.section-hint {
  font-size: 11px;
  color: var(--virtue-gold);
  opacity: 0.85;
}

.wheel-wrapper {
  position: relative;
  width: 310px;
  height: 310px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wheel-glow-bg {
  position: absolute;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(245, 158, 11, 0.07) 0%, rgba(239, 68, 68, 0.05) 55%, transparent 75%);
  pointer-events: none;
}

.wheel-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.wheel-orbit-outer {
  fill: none;
  stroke: rgba(255, 255, 255, 0.08);
  stroke-dasharray: 4 6;
  stroke-width: 1.2;
}

.wheel-orbit-inner {
  fill: none;
  stroke: rgba(245, 158, 11, 0.12);
  stroke-width: 1;
}

.wheel-center {
  position: absolute;
  width: 76px;
  height: 76px;
  border-radius: 50%;
  background: radial-gradient(circle, #202636 0%, #11141c 100%);
  border: 1px solid rgba(245, 158, 11, 0.4);
  box-shadow: 0 0 16px rgba(245, 158, 11, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 2;
}

.center-core {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.center-symbol {
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 700;
  color: var(--virtue-gold);
  line-height: 1;
}

.center-sub {
  font-size: 10px;
  color: var(--text-secondary);
  margin-top: 3px;
  letter-spacing: 0.5px;
}

.wheel-nodes-layer {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 3;
}

.wheel-node-btn {
  position: absolute;
  width: 44px;
  height: 44px;
  transform: translate(-50%, -50%);
  border-radius: 50%;
  background: #171c28;
  border: 1px solid rgba(255, 255, 255, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.4);
}

.wheel-node-btn:hover {
  transform: translate(-50%, -50%) scale(1.1);
  border-color: var(--virtue-gold);
}

.wheel-node-btn.active {
  background: #242c3d;
  border: 1.5px solid var(--virtue-gold);
  box-shadow: 0 0 16px var(--virtue-glow);
  transform: translate(-50%, -50%) scale(1.15);
}

.node-label-sin {
  font-size: 11px;
  font-weight: 600;
  color: var(--sin-crimson);
  line-height: 1.1;
}

.node-label-virtue {
  font-size: 10px;
  color: var(--virtue-gold);
  line-height: 1.1;
}

/* 轮盘选中详情卡片 */
.wheel-detail-card {
  width: 100%;
  margin-top: 12px;
  padding: 12px 14px;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: all 0.25s ease;
}

.detail-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-serif);
  font-size: 13px;
  font-weight: 600;
}

.tag-sin {
  color: var(--sin-crimson);
}

.tag-vs {
  color: var(--text-muted);
  font-size: 11px;
}

.tag-virtue {
  color: var(--virtue-gold);
}

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

/* 元信息卡片群 */
.meta-section {
  margin: 12px 0 16px;
}

.meta-grid {
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 12px 8px;
  background: var(--bg-secondary);
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
}

.meta-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.meta-number {
  font-family: var(--font-serif);
  font-size: 20px;
  font-weight: 700;
  color: var(--virtue-gold);
  line-height: 1.1;
}

.meta-label {
  font-size: 11px;
  color: var(--text-secondary);
  margin-top: 3px;
}

.meta-divider {
  width: 1px;
  height: 28px;
  background-color: var(--border-subtle);
}

/* 主 CTA 按钮 (直接点击开测) */
.cta-section {
  margin: 14px 0 20px;
}

.btn-primary {
  width: 100%;
  padding: 14px 20px;
  border-radius: 12px;
  border: none;
  background: linear-gradient(135deg, #d97706 0%, #b45309 50%, #991b1b 100%);
  color: #ffffff;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 1px;
  cursor: pointer;
  box-shadow: 0 4px 18px rgba(180, 83, 9, 0.45);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  text-decoration: none;
}

.btn-primary:hover {
  filter: brightness(1.1);
  box-shadow: 0 6px 22px rgba(180, 83, 9, 0.6);
  transform: translateY(-1px);
}

.btn-primary:active {
  transform: translateY(1px);
  filter: brightness(0.95);
}

.btn-primary .btn-text {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: 1.5px;
}

.btn-primary .btn-subtext {
  font-size: 11px;
  font-weight: 400;
  opacity: 0.85;
}

/* 作答须知 */
.guidelines-section {
  padding: 16px 14px;
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  margin-bottom: 20px;
}

.guidelines-title {
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 12px;
  letter-spacing: 0.5px;
}

.guidelines-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.guideline-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.guideline-index {
  font-family: var(--font-serif);
  font-size: 12px;
  font-weight: 700;
  color: var(--virtue-gold);
  width: 18px;
  flex-shrink: 0;
  line-height: 1.4;
}

.guideline-content {
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-secondary);
}

.guideline-content strong {
  color: var(--text-main);
}

/* 页脚合规免责声明 */
.app-footer {
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.disclaimer-box {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.disclaimer-text {
  font-size: 11px;
  line-height: 1.5;
  color: var(--text-muted);
}

.privacy-text {
  font-size: 11px;
  color: var(--virtue-gold);
  opacity: 0.75;
}

/* ==========================================================================
   答题视图组件
   ========================================================================== */

.quiz-header {
  margin-bottom: 16px;
}

.quiz-meta-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}

.round-badge {
  font-size: 12px;
  font-weight: 600;
  color: var(--virtue-gold);
  background: var(--virtue-bg);
  padding: 3px 8px;
  border-radius: 6px;
  border: 1px solid var(--virtue-border);
}

.counter-badge {
  font-family: var(--font-serif);
  font-size: 12px;
  color: var(--text-secondary);
}

.progress-track {
  width: 100%;
  height: 4px;
  background: var(--bg-card);
  border-radius: 2px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--sin-crimson) 0%, var(--virtue-gold) 100%);
  border-radius: 2px;
  transition: width 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.quiz-body {
  display: flex;
  flex-direction: column;
  flex: 1;
}

.question-container {
  display: flex;
  flex-direction: column;
  flex: 1;
}

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

.realm-badge {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 4px;
}

.realm-sin {
  background: var(--sin-bg);
  color: var(--sin-crimson);
  border: 1px solid var(--sin-border);
}

.realm-virtue {
  background: var(--virtue-bg);
  color: var(--virtue-gold);
  border: 1px solid var(--virtue-border);
}

.dimension-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
}

.question-card {
  position: relative;
  background: var(--bg-card);
  border-radius: 14px;
  border: 1px solid var(--border-subtle);
  padding: 24px 20px 22px;
  margin-bottom: 20px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
  min-height: 130px;
  display: flex;
  align-items: center;
}

.quote-mark {
  position: absolute;
  top: 8px;
  left: 12px;
  font-family: var(--font-serif);
  font-size: 32px;
  line-height: 1;
  color: rgba(255, 255, 255, 0.1);
  pointer-events: none;
}

.question-statement {
  font-family: var(--font-serif);
  font-size: 16px;
  line-height: 1.65;
  color: #ffffff;
  letter-spacing: 0.5px;
  text-align: left;
}

/* 4 档选项按钮 */
.options-group {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 20px;
}

.option-btn {
  width: 100%;
  padding: 13px 16px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 12px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
  color: var(--text-main);
  text-align: left;
}

.option-btn:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-focus);
}

.option-btn:active {
  transform: scale(0.99);
}

.option-btn.selected {
  background: rgba(245, 158, 11, 0.12);
  border-color: var(--virtue-gold);
  box-shadow: 0 0 12px rgba(245, 158, 11, 0.2);
}

.option-indicator {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  border: 1.5px solid var(--text-muted);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}

.option-btn.selected .option-indicator {
  border-color: var(--virtue-gold);
  background-color: var(--virtue-gold);
}

.option-label {
  font-size: 14px;
  font-weight: 500;
  line-height: 1.4;
}

.quiz-nav-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 6px;
}

.btn-ghost {
  padding: 8px 14px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-ghost:hover:not(:disabled) {
  border-color: var(--text-main);
  color: var(--text-main);
}

.btn-ghost:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.nav-hint {
  font-size: 11px;
  color: var(--text-muted);
}

.quiz-footer {
  margin-top: auto;
  text-align: center;
  padding-top: 12px;
}

.footer-note {
  font-size: 11px;
  color: var(--text-muted);
}

/* ==========================================================================
   结果报告视图组件
   ========================================================================== */

.result-header {
  text-align: center;
  padding: 10px 0 16px;
}

.result-seal {
  display: inline-block;
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--virtue-gold);
  margin-bottom: 4px;
}

.result-title {
  font-family: var(--font-serif);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #ffffff;
  margin-bottom: 4px;
}

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

/* 冠位双卡片 */
.archetype-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 20px;
}

.archetype-card {
  padding: 16px;
  border-radius: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.card-shadow {
  border-left: 3px solid var(--sin-crimson);
  background: linear-gradient(135deg, rgba(239, 68, 68, 0.05) 0%, var(--bg-card) 60%);
}

.card-virtue {
  border-left: 3px solid var(--virtue-gold);
  background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, var(--bg-card) 60%);
}

.archetype-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.archetype-tag {
  font-size: 11px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 4px;
}

.archetype-name {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 700;
  color: var(--text-main);
}

.archetype-title {
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
}

.card-shadow .archetype-title {
  color: #fca5a5;
}

.card-virtue .archetype-title {
  color: #fde68a;
}

.archetype-desc {
  font-size: 12px;
  line-height: 1.55;
  color: var(--text-secondary);
}

.archetype-score-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.bar-label {
  font-size: 11px;
  color: var(--text-muted);
  width: 60px;
  flex-shrink: 0;
}

.score-track {
  flex: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 3px;
  overflow: hidden;
}

.score-fill {
  height: 100%;
  border-radius: 3px;
  transition: width 0.6s ease;
}

.fill-sin {
  background: linear-gradient(90deg, #b91c1c 0%, var(--sin-crimson) 100%);
}

.fill-virtue {
  background: linear-gradient(90deg, #d97706 0%, var(--virtue-gold) 100%);
}

.score-val {
  font-family: var(--font-serif);
  font-size: 12px;
  font-weight: 700;
  width: 38px;
  text-align: right;
  color: var(--text-main);
}

/* 双环图表 */
.chart-section {
  padding: 16px 14px;
  background: var(--bg-card);
  border-radius: 14px;
  border: 1px solid var(--border-subtle);
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.chart-header {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.chart-title {
  font-family: var(--font-serif);
  font-size: 14px;
  font-weight: 600;
  color: var(--text-main);
}

.chart-legend {
  display: flex;
  align-items: center;
  gap: 10px;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  color: var(--text-secondary);
}

.dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
}

.dot-sin {
  background-color: var(--sin-crimson);
}

.dot-virtue {
  background-color: var(--virtue-gold);
}

.chart-svg-container {
  width: 290px;
  height: 290px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.double-ring-svg {
  width: 100%;
  height: 100%;
}

/* 双列详单对照 */
.breakdown-section {
  margin-bottom: 20px;
}

.breakdown-title {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 12px;
}

.dual-columns-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.column-panel {
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border-subtle);
  padding: 12px 10px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.column-head {
  display: flex;
  align-items: center;
  gap: 6px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.col-icon {
  font-size: 13px;
}

.col-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.panel-sin .col-title {
  color: var(--sin-crimson);
}

.panel-virtue .col-title {
  color: var(--virtue-gold);
}

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

.dim-row {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dim-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

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

.dim-score {
  font-family: var(--font-serif);
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
}

.dim-track {
  width: 100%;
  height: 4px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 2px;
  overflow: hidden;
}

.dim-bar {
  height: 100%;
  border-radius: 2px;
}

.panel-sin .dim-bar {
  background: var(--sin-crimson);
}

.panel-virtue .dim-bar {
  background: var(--virtue-gold);
}

/* 自我整合建议 */
.advice-section {
  margin-bottom: 24px;
}

.advice-title {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 10px;
}

.advice-card {
  padding: 16px;
  border-radius: 12px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.advice-quote {
  font-family: var(--font-serif);
  font-size: 13px;
  font-weight: 600;
  color: var(--virtue-gold);
  line-height: 1.5;
  border-left: 2px solid var(--virtue-gold);
  padding-left: 8px;
}

.advice-content {
  font-size: 12px;
  line-height: 1.65;
  color: var(--text-secondary);
}

/* 按钮组 */
.result-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 24px;
}

.secondary-actions {
  display: flex;
  gap: 10px;
}

.btn-secondary {
  flex: 1;
  padding: 11px 14px;
  border-radius: 10px;
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  color: var(--text-main);
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-secondary:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-focus);
}

.secondary-actions .btn-ghost {
  flex: 1;
  padding: 11px 14px;
  border-radius: 10px;
  font-size: 14px;
}

/* ==========================================================================
   卡片导出弹窗
   ========================================================================== */

.modal-backdrop {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(8px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  transition: opacity 0.25s ease;
}

.modal-backdrop.active {
  display: flex;
  opacity: 1;
}

.modal-card {
  width: 100%;
  max-width: 380px;
  background: var(--bg-secondary);
  border-radius: 14px;
  border: 1px solid var(--border-focus);
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.7);
  max-height: 90vh;
}

.modal-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.modal-title {
  font-family: var(--font-serif);
  font-size: 15px;
  font-weight: 600;
  color: var(--text-main);
}

.modal-close {
  background: none;
  border: none;
  font-size: 20px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0 4px;
  line-height: 1;
}

.modal-close:hover {
  color: var(--text-main);
}

.modal-body {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  overflow-y: auto;
}

.card-preview-wrapper {
  width: 100%;
  max-height: 55vh;
  overflow-y: auto;
  border-radius: 8px;
  background: #000000;
  display: flex;
  justify-content: center;
}

.export-preview-img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 6px;
}

.modal-tip {
  font-size: 11px;
  color: var(--text-secondary);
}

.modal-actions {
  width: 100%;
}
