/* ===== screens.css · 六屏布局 ===== */

/* 通用屏容器：默认垂直居中 */
.screen {
  animation: screen-in 0.7s cubic-bezier(0.22, 1, 0.36, 1) both;
}
@keyframes screen-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* ---------- 首页 ---------- */
.screen-home {
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 20px;
}
.home-hero { line-height: 1.4; }
.hero-line { display: block; }
.home-subtitle { line-height: 1.6; max-width: 90%; }
.home-cta { margin-top: 4px; }
.home-disclaimer { margin-top: 26px; line-height: 1.6; max-width: 88%; }
.disc-line { display: block; }
.disc-line + .disc-line { margin-top: 4px; }

/* 首页神秘金黄光芒点（一大两小，构成三角形：大点在上右侧为顶点） */
.home-orbs { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.home-orb {
  position: absolute;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(234,212,150,0.95) 0%, rgba(201,162,75,0.55) 42%, transparent 72%);
  box-shadow: 0 0 18px 6px rgba(201,162,75,0.30);
  animation: orb-breathe 4.6s ease-in-out infinite;
}
/* 大光点：三角形顶点，右上侧 */
.home-orb.orb-big {
  width: 19px; height: 19px;
  top: 12%; left: 70%;
  animation-name: orb-breathe-big;
}
/* 两个小光点：三角形底边，左右展开、间距拉远 */
.home-orb.orb-small-1 { width: 7px; height: 7px; top: 22%; left: 27%; animation-delay: 1.4s; }
.home-orb.orb-small-2 { width: 7px; height: 7px; top: 22%; right: 27%; animation-delay: 2.6s; }
@keyframes orb-breathe {
  0%, 100% { transform: scale(0.7); opacity: 0.45; }
  50% { transform: scale(1.3); opacity: 0.95; }
}
@keyframes orb-breathe-big {
  0%, 100% { transform: scale(0.8); opacity: 0.55; }
  50% { transform: scale(1.25); opacity: 1; }
}

/* ---------- 测试码 ---------- */
.screen-unlock {
  justify-content: center;
  align-items: center;
  text-align: center;
}
.unlock-wrap { display: flex; flex-direction: column; align-items: center; gap: 18px; width: 100%; }
.unlock-input {
  width: 100%; max-width: 300px;
  padding: 15px 18px;
  background: rgba(0,0,0,0.25);
  border: 1px solid var(--gold);
  border-radius: 12px;
  color: var(--text-primary);
  text-align: center;
  letter-spacing: 0.14em;
  outline: none;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.unlock-input:focus { box-shadow: 0 0 0 3px rgba(166,139,91,0.18); }
.unlock-error { min-height: 16px; opacity: 0; transition: opacity 0.3s ease; }
.unlock-error.show { opacity: 1; }
.unlock-cta { margin-top: 56px; } /* 下移至页面下 1/3 区域 */

/* ---------- 答题 ---------- */
.screen-quiz {
  justify-content: flex-start;
  gap: 22px;
  padding-top: 6vh;
}
.quiz-counter { display: flex; align-items: center; gap: 12px; }
.quiz-counter-num { font-size: 12px; color: var(--text-muted); letter-spacing: 0.1em; white-space: nowrap; }
.quiz-progress { flex: 1; height: 2px; background: var(--line); position: relative; border-radius: 2px; overflow: hidden; }
.quiz-progress-fill { position: absolute; left: 0; top: 0; height: 100%; background: var(--gold); transition: width 0.4s ease; }
.quiz-stem { line-height: 1.6; }
.quiz-options { display: flex; flex-direction: column; gap: 14px; margin-top: 4px; }
.quiz-option {
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-card);
  line-height: 1.5;
  backdrop-filter: blur(12px) saturate(110%);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.5s ease, transform 0.5s ease, border-color 0.25s ease;
}
.quiz-option.in { opacity: 1; transform: none; }
.quiz-option:active { border-color: var(--gold); }
.quiz-back {
  margin-top: 8px;
  align-self: center;
  padding: 10px 22px;
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  border: 1px solid var(--line);
  border-radius: 20px;
  background: rgba(0,0,0,0.2);
  transition: border-color 0.25s ease, color 0.25s ease;
}
.quiz-back:active { border-color: var(--gold); color: var(--text-primary); }

/* ---------- 解析 ---------- */
.screen-analyzing {
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 26px;
}
.analyzing-graph { width: 168px; height: 168px; margin: 0 auto; }
.analyzing-lines { display: flex; flex-direction: column; }
.analyzing-line { opacity: 0; transition: opacity 0.6s ease; }
.analyzing-line.show { opacity: 1; }
.analyzing-line.hide { opacity: 0; }

/* ---------- 结果 ---------- */
.screen-result {
  position: relative;
  justify-content: flex-start;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}
/* 主罪色晕染层：随主罪变化，置于内容之下、星空之上 */
.result-tint { position: absolute; inset: 0; z-index: 0; pointer-events: none; }
.screen-result > *:not(.result-tint) { position: relative; z-index: 1; }
.result-figure-wrap { position: relative; width: 100%; }
.result-figure {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: center 12%;
  display: block;
}
/* 各原罪专属裁剪比例与位移（object-position Y 越小越靠上、越大越靠下） */
.result-figure.sin-pride { aspect-ratio: 4 / 5; object-position: center 0%; }    /* 皇冠露全 */
.result-figure.sin-envy { aspect-ratio: 4 / 5; object-position: center 25%; }    /* 4:5 + 上移 25% */
.result-figure.sin-wrath { object-position: center 4%; }                         /* 上移 8% */
.result-figure.sin-sloth { aspect-ratio: 4 / 5; object-position: center 75%; }   /* 4:5 + 上移 25%，人脸在画面下半部，锚低才能露脸 */
.result-figure.sin-greed { aspect-ratio: 4 / 5; object-position: center 30%; }   /* 4:5 + 上移 20% */
.result-figure.sin-gluttony { aspect-ratio: 4 / 5; object-position: center 17%; }/* 下移 5% */
.result-figure.sin-lust { object-position: center 12%; }                         /* 不变 */
.result-figure-wrap::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 52%;
  background: linear-gradient(to bottom, transparent 0%, color-mix(in srgb, var(--sin-accent) 28%, transparent) 48%, var(--sin-accent) 100%);
  pointer-events: none;
}
.result-head {
  margin-top: 14px;
  padding: 0 4px 8px;
  text-align: center;
}
.result-title { line-height: 1.4; }
.result-reversal { margin: 22px 0 6px; line-height: 1.85; }
.result-section { margin-top: 26px; }
.result-section-title { text-align: center; margin-bottom: 12px; letter-spacing: 0.12em; }
.result-body { line-height: 1.85; text-indent: 2em; font-size: 13.5px; }
.result-body p { margin-bottom: 14px; }
.result-arc { margin-top: 24px; padding: 18px; border: 1px solid var(--line); border-radius: 14px; background: rgba(0,0,0,0.22); }
.result-arc p { margin-bottom: 12px; line-height: 1.8; }
.result-arc .arc-trap { color: var(--text-muted); }
.result-arc .arc-flip { color: var(--text-primary); }
.result-goldquote { margin: 28px 0; text-align: center; line-height: 1.8; font-size: 17px; }
.result-network { width: 100%; max-width: 320px; margin: 8px auto 0; }
.result-actions { display: flex; flex-direction: column; gap: 12px; margin-top: 30px; align-items: center; }
.result-actions .btn { width: 100%; max-width: 300px; }

/* ---------- 分享 ---------- */
.screen-share {
  justify-content: center;
  align-items: center;
  text-align: center;
  gap: 16px;
}
.share-card-preview {
  width: 100%; max-width: 300px;
  border-radius: 14px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.5);
  margin-bottom: 6px;
}
.share-actions { display: flex; flex-direction: column; gap: 12px; width: 100%; max-width: 300px; align-items: center; }
.share-actions .btn { width: 100%; }
.share-links { display: flex; gap: 22px; margin-top: 8px; }
.share-link { color: var(--text-muted); font-size: 13px; text-decoration: underline; text-underline-offset: 3px; }

/* 七维指数条（结果页 + 卡） */
.dim-bars { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.dim-bar { display: flex; align-items: center; gap: 10px; }
.dim-bar-name { width: 42px; font-size: 12px; color: var(--text-muted); flex-shrink: 0; }
.dim-bar-track { flex: 1; height: 6px; background: rgba(255,255,255,0.08); border-radius: 4px; overflow: hidden; }
.dim-bar-fill { height: 100%; border-radius: 4px; transition: width 0.8s cubic-bezier(0.22,1,0.36,1); }
.dim-bar-val { width: 34px; text-align: right; font-size: 12px; color: var(--text-muted); }

/* 网络图 svg 通用 */
.net-svg { display: block; margin: 0 auto; }
.net-vertex-label { font-size: 9px; fill: var(--text-muted); font-family: var(--font-sans); }

/* 网络图动画 */
.net-spin { animation: net-spin 9s linear infinite; transform-origin: center; }
@keyframes net-spin { to { transform: rotate(360deg); } }
.net-core { animation: net-pulse-core 1.6s ease-in-out infinite; }
@keyframes net-pulse-core { 0%, 100% { r: 4; opacity: 0.6; } 50% { r: 7; opacity: 1; } }
.net-pulse { animation: net-vertex-pulse 1.8s ease-in-out infinite; }
@keyframes net-vertex-pulse { 0%, 100% { opacity: 0.7; } 50% { opacity: 1; } }
.net-draw { animation: net-fade 1.2s ease both; }
@keyframes net-fade { from { opacity: 0; transform: scale(0.92); } to { opacity: 1; transform: none; } }
