/* ==========================================================================
   大肥鱼 · 性格海域 — visual system
   ========================================================================== */

:root {
  --bg: #03101c;
  --bg-soft: #061a2b;
  --surface: rgba(140, 215, 255, 0.05);
  --surface-2: rgba(140, 215, 255, 0.09);
  --border: rgba(150, 220, 255, 0.13);
  --border-strong: rgba(150, 220, 255, 0.26);
  --text: #eaf7ff;
  --text-soft: #b9d3e6;
  --muted: #7e9db6;
  --indigo: #5aa9ff;
  --mint: #4fd6e8;
  --amber: #ffcf6b;
  --pink: #ff8fa8;
  --sky: #9fe0ff;
  --sand: #ffd166;
  --radius: 24px;
  --max: 1160px;
  --shadow: 0 30px 80px rgba(0, 12, 26, 0.5);
  --font-sans: "Segoe UI", "Microsoft YaHei UI", "Microsoft YaHei", "PingFang SC",
    "Hiragino Sans GB", system-ui, -apple-system, sans-serif;
  --font-display: "Iowan Old Style", "Palatino Linotype", Georgia, "Songti SC", "SimSun", serif;
  --font-mono: "Cascadia Code", "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --ease: cubic-bezier(0.22, 0.8, 0.24, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(1200px 700px at 76% -8%, rgba(90, 169, 255, 0.20), transparent 62%),
    radial-gradient(900px 600px at 6% 18%, rgba(79, 214, 232, 0.12), transparent 60%),
    radial-gradient(800px 500px at 92% 78%, rgba(255, 143, 168, 0.07), transparent 65%),
    linear-gradient(180deg, #08263f 0%, #041525 42%, #03101c 100%);
  background-color: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.modal-open { overflow: hidden; }

::selection { background: rgba(90, 169, 255, 0.35); color: #fff; }

h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
button, input, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: inherit; text-decoration: none; }
em { font-style: normal; }

.is-hidden { display: none !important; }
.mono { font-family: var(--font-mono); letter-spacing: 0.02em; }

/* ---------------- 背景 ---------------- */

.backdrop {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.aurora {
  position: absolute;
  border-radius: 50%;
  filter: blur(110px);
  opacity: 0.4;
  animation: drift 26s var(--ease) infinite alternate;
}

.aurora-a {
  width: 560px; height: 560px;
  left: -8%; top: 2%;
  background: radial-gradient(circle, rgba(90, 169, 255, 0.55), transparent 65%);
}

.aurora-b {
  width: 460px; height: 460px;
  right: -6%; top: 26%;
  background: radial-gradient(circle, rgba(255, 143, 168, 0.32), transparent 65%);
  animation-delay: -9s;
}

.aurora-c {
  width: 620px; height: 620px;
  left: 42%; bottom: -32%;
  background: radial-gradient(circle, rgba(79, 214, 232, 0.30), transparent 65%);
  animation-delay: -16s;
}

.grain {
  position: absolute;
  inset: 0;
  opacity: 0.05;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.55'/%3E%3C/svg%3E");
}

@keyframes drift {
  from { transform: translate3d(-2%, -1%, 0) scale(1); }
  to { transform: translate3d(3%, 4%, 0) scale(1.08); }
}

/* ---------------- 通用组件 ---------------- */

.site-header {
  position: sticky;
  top: 10px;
  z-index: 30;
  display: flex;
  align-items: center;
  gap: 28px;
  width: calc(100% - 40px);
  max-width: var(--max);
  margin: 10px auto 0;
  padding: 12px 22px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 16px;
  background: rgba(6, 25, 40, 0.6);
  backdrop-filter: blur(18px) saturate(140%);
}

body[data-view="quiz"] .site-header,
body[data-view="analyzing"] .site-header {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

body[data-view="quiz"] .site-footer,
body[data-view="analyzing"] .site-footer { display: none; }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-right: auto;
}

.brand-mark { width: 30px; height: 30px; }

.brand-text {
  font-size: 19px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.brand-text em {
  margin-left: 8px;
  font-family: var(--font-display);
  font-size: 12px;
  letter-spacing: 0.32em;
  color: var(--muted);
}

.brand-text.small { font-size: 15px; }

.site-nav {
  display: flex;
  gap: 26px;
  font-size: 13.5px;
  color: var(--text-soft);
}

.site-nav a {
  position: relative;
  padding: 4px 0;
  transition: color 0.2s;
}

.site-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%; bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, var(--indigo), var(--mint));
  transition: right 0.28s var(--ease);
}

.site-nav a:hover { color: var(--text); }
.site-nav a:hover::after { right: 0; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 14px 26px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.01em;
  transition: transform 0.2s var(--ease), box-shadow 0.25s, background 0.25s, border-color 0.25s, opacity 0.2s;
}

.btn:active { transform: translateY(1px) scale(0.995); }

.btn-primary {
  color: #07101c;
  background: linear-gradient(120deg, #7bb6ff 0%, #5aa9ff 34%, #4fd6e8 100%);
  box-shadow: 0 10px 34px rgba(105, 124, 255, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.45);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 44px rgba(105, 124, 255, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.5);
}

.btn-primary:disabled {
  opacity: 0.34;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-ghost {
  border-color: var(--border-strong);
  background: rgba(255, 255, 255, 0.025);
  color: var(--text-soft);
}

.btn-ghost:hover {
  border-color: rgba(90, 169, 255, 0.55);
  background: rgba(90, 169, 255, 0.08);
  color: var(--text);
}

.btn-sm { padding: 9px 16px; font-size: 13px; }
.btn-meta { font-size: 12px; font-weight: 500; opacity: 0.72; }

.link-btn {
  border: 0;
  background: none;
  padding: 0;
  font-size: 13.5px;
  color: var(--muted);
  transition: color 0.2s;
}

.link-btn:hover { color: var(--text); }
.link-btn.danger:hover { color: var(--pink); }

.eyebrow {
  display: flex;
  align-items: center;
  gap: 9px;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted);
}

.eyebrow .dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--mint);
  box-shadow: 0 0 12px var(--mint);
}

.grad-text {
  background: linear-gradient(100deg, #8fc8ff 0%, #4fd6e8 52%, #ff9fc4 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.card {
  position: relative;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.055), rgba(255, 255, 255, 0.018));
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.18);
}

/* ---------------- 视图 ---------------- */

.view { display: none; }
.view.is-active { display: block; animation: viewIn 0.55s var(--ease) both; }

@keyframes viewIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ---------------- 首页 ---------------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 0.98fr);
  align-items: center;
  gap: 30px;
  max-width: var(--max);
  min-height: calc(100vh - 110px);
  margin: 0 auto;
  padding: 30px 28px 90px;
}

.hero-copy h1 {
  margin: 22px 0 24px;
  font-size: clamp(2.5rem, 5vw, 4.15rem);
  line-height: 1.14;
  font-weight: 700;
  letter-spacing: -0.045em;
}

.lede {
  max-width: 47ch;
  font-size: 16.5px;
  line-height: 1.95;
  color: var(--text-soft);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-top: 34px;
}

.hero-actions .btn-primary {
  padding: 16px 28px;
  font-size: 15.5px;
}

.hero-facts {
  display: flex;
  gap: 42px;
  margin-top: 46px;
  padding: 0;
  list-style: none;
}

.hero-facts li { display: flex; flex-direction: column; gap: 2px; }

.hero-facts strong {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 500;
  letter-spacing: 0.01em;
  line-height: 1;
}

.hero-facts span { font-size: 11.5px; letter-spacing: 0.12em; color: var(--muted); }

#btn-last-result { margin-top: 18px; }

.hero-visual {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 480px;
}

.orbit {
  position: relative;
  width: 430px;
  height: 430px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.orbit-glow {
  position: absolute;
  inset: 9%;
  border-radius: 50%;
  background: conic-gradient(from 0deg, rgba(90, 169, 255, 0.75), rgba(79, 214, 232, 0.6), rgba(255, 143, 168, 0.65), rgba(90, 169, 255, 0.75));
  filter: blur(58px);
  opacity: 0.36;
  animation: spin 22s linear infinite;
}

.orbit-ring {
  position: absolute;
  inset: 4%;
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 50%;
}

.orbit-ring.ring-2 {
  inset: 19%;
  border-style: dashed;
  border-color: rgba(255, 255, 255, 0.07);
  animation: spin 60s linear infinite reverse;
}

.orbit-core {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 172px;
  height: 172px;
  border-radius: 50%;
  background: radial-gradient(circle at 50% 30%, rgba(90, 169, 255, 0.18), rgba(4, 18, 31, 0.86) 70%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: inset 0 0 40px rgba(90, 169, 255, 0.16), 0 20px 60px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(10px);
}

.orbit-core .core-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.3em;
  color: var(--muted);
}

.orbit-core strong {
  font-family: var(--font-display);
  font-size: 58px;
  font-weight: 500;
  line-height: 1.1;
  background: linear-gradient(120deg, #cfd6ff, #4fd6e8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.orbit-core small { font-size: 11px; letter-spacing: 0.2em; color: var(--muted); }

.orbit-node {
  position: absolute;
  left: 50%;
  top: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  transform: translate(-50%, -50%) rotate(calc(var(--i) * 72deg)) translateY(-198px) rotate(calc(var(--i) * -72deg));
}

.orbit-node i {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--indigo);
  box-shadow: 0 0 14px rgba(90, 169, 255, 0.9);
}

.orbit-node:nth-of-type(5) i { background: var(--indigo); box-shadow: 0 0 14px rgba(90, 169, 255, 0.9); }
.orbit-node:nth-of-type(6) i { background: var(--mint); box-shadow: 0 0 14px rgba(79, 214, 232, 0.9); }
.orbit-node:nth-of-type(7) i { background: var(--amber); box-shadow: 0 0 14px rgba(255, 207, 107, 0.9); }
.orbit-node:nth-of-type(8) i { background: var(--pink); box-shadow: 0 0 14px rgba(255, 143, 168, 0.9); }
.orbit-node:nth-of-type(9) i { background: var(--sky); box-shadow: 0 0 14px rgba(159, 224, 255, 0.9); }

.orbit-node b {
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.08em;
  color: var(--text-soft);
  white-space: nowrap;
}

.float-tag {
  position: absolute;
  padding: 8px 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(6, 25, 40, 0.7);
  backdrop-filter: blur(8px);
  font-size: 11.5px;
  letter-spacing: 0.04em;
  color: var(--text-soft);
  animation: floaty 7s ease-in-out infinite alternate;
}

.tag-a { top: 5%; right: -1%; }
.tag-b { bottom: 6%; left: -4%; animation-delay: -3.5s; }

@keyframes floaty {
  from { transform: translateY(-6px); }
  to { transform: translateY(8px); }
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ---------------- 方法 ---------------- */

.method, .about { max-width: var(--max); margin: 0 auto; padding: 90px 28px; }

.section-head h2,
.about h2 {
  margin: 16px 0 0;
  font-size: clamp(1.7rem, 3vw, 2.3rem);
  letter-spacing: -0.035em;
  font-weight: 650;
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-top: 36px;
}

.cards .card {
  padding: 28px 26px 30px;
  overflow: hidden;
  transition: transform 0.35s var(--ease), border-color 0.35s, background 0.35s;
}

.cards .card:hover {
  transform: translateY(-5px);
  border-color: rgba(90, 169, 255, 0.38);
  background: linear-gradient(180deg, rgba(90, 169, 255, 0.09), rgba(255, 255, 255, 0.02));
}

.card-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  margin-bottom: 22px;
  border-radius: 13px;
  color: #b7c1ff;
  background: rgba(90, 169, 255, 0.13);
  border: 1px solid rgba(90, 169, 255, 0.22);
}

.card-icon svg { width: 22px; height: 22px; }

.cards h3 { font-size: 17px; font-weight: 650; letter-spacing: -0.01em; }

.cards p {
  margin-top: 10px;
  font-size: 13.8px;
  line-height: 1.85;
  color: var(--muted);
}

.card-index {
  position: absolute;
  top: 22px;
  right: 24px;
  font-family: var(--font-mono);
  font-size: 11px;
  color: rgba(255, 255, 255, 0.18);
}

.mid-cta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-top: 40px;
}

.mid-cta span {
  font-size: 12px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.about { padding-top: 40px; padding-bottom: 120px; max-width: 820px; }

.about-inner { border-top: 1px solid var(--border); padding-top: 64px; }

.about p {
  margin-top: 20px;
  font-size: 15px;
  line-height: 2.05;
  color: var(--text-soft);
}

.about p b { color: var(--text); font-weight: 600; }

.about-note {
  margin-top: 34px;
  padding: 18px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255, 207, 107, 0.22);
  background: rgba(255, 207, 107, 0.05);
  font-size: 12.5px;
  line-height: 1.85;
  color: var(--muted);
}

.about-note span {
  display: inline-block;
  margin-right: 8px;
  color: var(--amber);
  font-weight: 600;
}

/* ---------------- 答题 ---------------- */

#view-quiz {
  display: none;
  min-height: 100vh;
  padding: 64px 20px 40px;
}

#view-quiz.is-active { display: flex; align-items: center; justify-content: center; }

.quiz-shell { width: 100%; max-width: 780px; }

.quiz-top {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 12.5px;
  color: var(--muted);
}

.quiz-counter { margin-left: auto; color: var(--text-soft); letter-spacing: 0.03em; }
.quiz-answered { font-family: var(--font-mono); font-size: 11px; }

.progress {
  height: 3px;
  margin-top: 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  overflow: hidden;
}

.progress span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--indigo), var(--mint));
  box-shadow: 0 0 14px rgba(79, 214, 232, 0.6);
  transition: width 0.45s var(--ease);
}

.quiz-card {
  margin-top: 38px;
  padding: 46px 46px 32px;
  border-radius: 26px;
  border: 1px solid var(--border);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.018));
  box-shadow: var(--shadow);
}

.q-kicker { font-size: 12.5px; color: var(--muted); letter-spacing: 0.02em; }
.q-kicker b { color: var(--text-soft); font-weight: 600; }

.q-text {
  min-height: 96px;
  margin: 16px 0 34px;
  font-size: clamp(1.35rem, 2.4vw, 1.8rem);
  line-height: 1.55;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.q-text.question-enter { animation: questionIn 0.4s var(--ease) both; }

@keyframes questionIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.options { display: grid; gap: 10px; }

.option {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.022);
  color: var(--text-soft);
  text-align: left;
  transition: border-color 0.22s, background 0.22s, transform 0.22s var(--ease), color 0.22s;
  animation: optionIn 0.4s var(--ease) both;
}

.option:nth-child(1) { animation-delay: 0.02s; }
.option:nth-child(2) { animation-delay: 0.06s; }
.option:nth-child(3) { animation-delay: 0.10s; }
.option:nth-child(4) { animation-delay: 0.14s; }
.option:nth-child(5) { animation-delay: 0.18s; }

@keyframes optionIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.option:hover {
  border-color: rgba(90, 169, 255, 0.5);
  background: rgba(90, 169, 255, 0.07);
  color: var(--text);
  transform: translateX(3px);
}

.option-key {
  width: 20px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--muted);
}

.option-label { font-size: 15px; }

.option-dot {
  position: relative;
  width: 16px;
  height: 16px;
  margin-left: auto;
  border-radius: 50%;
  border: 1.5px solid rgba(255, 255, 255, 0.22);
  transition: border-color 0.2s, background 0.2s;
}

.option.is-selected {
  border-color: rgba(90, 169, 255, 0.85);
  background: linear-gradient(90deg, rgba(90, 169, 255, 0.20), rgba(79, 214, 232, 0.07));
  color: var(--text);
  box-shadow: 0 0 0 1px rgba(90, 169, 255, 0.25), 0 10px 30px rgba(90, 169, 255, 0.12);
}

.option.is-selected .option-key { color: var(--indigo); }

.option.is-selected .option-dot {
  border-color: var(--indigo);
  background: var(--indigo);
  box-shadow: 0 0 0 4px rgba(90, 169, 255, 0.16);
}

.option.is-selected .option-dot::after {
  content: "";
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: #061a2b;
}

.quiz-nav {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 32px;
}

.kbd-hint {
  margin: 0 auto;
  font-size: 11.5px;
  color: var(--muted);
}

kbd {
  display: inline-block;
  min-width: 19px;
  padding: 1px 5px;
  border: 1px solid var(--border-strong);
  border-bottom-width: 2px;
  border-radius: 5px;
  font-family: var(--font-mono);
  font-size: 10.5px;
  text-align: center;
  color: var(--text-soft);
  background: rgba(255, 255, 255, 0.04);
}

.btn-next i { font-style: normal; transition: transform 0.2s; }
.btn-next:hover i { transform: translateX(3px); }

.quiz-footnote {
  margin-top: 18px;
  text-align: center;
  font-size: 11.5px;
  color: var(--muted);
}

/* ---------------- 计算中 ---------------- */

#view-analyzing {
  display: none;
  min-height: 88vh;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#view-analyzing.is-active { display: flex; }

.analyzing { display: flex; flex-direction: column; align-items: center; }

.analyzing-orbit {
  position: relative;
  width: 150px;
  height: 150px;
  margin-bottom: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.ao-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px solid transparent;
  border-top-color: rgba(90, 169, 255, 0.85);
  border-right-color: rgba(90, 169, 255, 0.18);
  animation: spin 1.6s linear infinite;
}

.ao-ring.r2 {
  inset: 16px;
  border-top-color: rgba(79, 214, 232, 0.85);
  border-right-color: transparent;
  animation: spin 2.4s linear infinite reverse;
}

.ao-core {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 30%, #b9c4ff, #6f80ff 45%, #3f4fd0);
  box-shadow: 0 0 44px rgba(90, 169, 255, 0.55);
  animation: pulse 2.2s ease-in-out infinite;
}

@keyframes pulse {
  0%, 100% { transform: scale(0.92); opacity: 0.85; }
  50% { transform: scale(1.05); opacity: 1; }
}

.analyzing h2 {
  margin: 16px 0 10px;
  font-size: 28px;
  letter-spacing: -0.03em;
}

.analyzing-status { font-size: 14px; color: var(--text-soft); }
.analyzing-hint { margin-top: 8px; font-size: 12px; color: var(--muted); }

/* ---------------- 结果 ---------------- */

#view-result { padding: 44px 0 100px; }

.result-shell { max-width: var(--max); margin: 0 auto; padding: 0 28px; }

.report-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 24px;
}

.report-head h1 {
  margin: 14px 0 10px;
  font-size: clamp(2rem, 4.4vw, 3.1rem);
  letter-spacing: -0.045em;
  line-height: 1.1;
}

.report-head h1 em {
  background: linear-gradient(100deg, #8fc8ff, #4fd6e8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.report-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 12.5px;
  color: var(--muted);
}

.report-meta b { color: var(--text-soft); font-weight: 600; }
.report-meta .sep { opacity: 0.5; }

.report-badge {
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--muted);
  white-space: nowrap;
}

.result-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.06fr) minmax(0, 0.94fr);
  gap: 18px;
  margin-top: 34px;
}

.card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.card-head h3 { font-size: 14.5px; font-weight: 650; letter-spacing: 0.01em; }
.card-sub { font-size: 10.5px; letter-spacing: 0.08em; color: var(--muted); }

.chart-card, .bars-card { padding: 24px 26px 26px; }

.radar-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 0 6px;
}

.radar-wrap svg { width: 100%; max-width: 372px; height: auto; overflow: visible; }

.radar-poly {
  transform-origin: center;
  animation: radarIn 0.9s var(--ease) both;
}

@keyframes radarIn {
  from { opacity: 0; transform: scale(0.7); }
  to { opacity: 1; transform: scale(1); }
}

.radar-dot { animation: dotIn 0.5s var(--ease) both; }

@keyframes dotIn {
  from { opacity: 0; r: 0; }
  to { opacity: 1; }
}

.trait-bars { margin-top: 20px; }

.trait-row {
  margin-bottom: 18px;
  animation: rowIn 0.5s var(--ease) both;
  animation-delay: var(--delay);
}

@keyframes rowIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.trait-meta {
  display: flex;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 8px;
}

.trait-name { font-size: 13.5px; font-weight: 600; color: var(--text-soft); }
.trait-band { font-size: 10.5px; color: var(--muted); letter-spacing: 0.02em; }

.trait-score {
  margin-left: auto;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 700;
  color: var(--trait-color);
}

.trait-track {
  height: 7px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.055);
  overflow: hidden;
}

.trait-fill {
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, color-mix(in srgb, var(--trait-color) 55%, transparent), var(--trait-color));
  box-shadow: 0 0 16px color-mix(in srgb, var(--trait-color) 45%, transparent);
  transition: width 1.1s var(--ease);
}

.type-card {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.2fr);
  gap: 26px;
  margin-top: 18px;
  padding: 30px 34px;
  border-radius: 24px;
  border: 1px solid rgba(90, 169, 255, 0.24);
  background:
    radial-gradient(600px 200px at 0% 0%, rgba(90, 169, 255, 0.16), transparent 70%),
    linear-gradient(120deg, rgba(79, 214, 232, 0.05), rgba(255, 255, 255, 0.015));
}

.type-label { font-size: 11.5px; letter-spacing: 0.06em; color: var(--muted); }

.type-name {
  margin-top: 6px;
  font-size: clamp(2rem, 3.6vw, 2.8rem);
  line-height: 1.15;
  letter-spacing: -0.035em;
}

.type-en {
  margin-top: 4px;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 15px;
  color: var(--muted);
}

.type-copy { display: flex; flex-direction: column; justify-content: center; gap: 16px; }

.type-copy > p { font-size: 14.5px; line-height: 1.95; color: var(--text-soft); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.03);
  font-size: 11.5px;
  color: var(--text-soft);
}

.chip i {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--chip-color);
  box-shadow: 0 0 10px var(--chip-color);
}

.note-card { margin-top: 18px; padding: 22px 26px; }

.note-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.note-head h3 { font-size: 14px; font-weight: 600; }

.note-row { display: flex; gap: 10px; margin-top: 14px; }

.note-row input {
  flex: 1;
  min-width: 0;
  padding: 12px 16px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.24);
  font-size: 13.5px;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.note-row input::placeholder { color: rgba(135, 145, 176, 0.75); }

.note-row input:focus {
  border-color: rgba(90, 169, 255, 0.6);
  box-shadow: 0 0 0 3px rgba(90, 169, 255, 0.12);
}

/* ---------------- AI 面板 ---------------- */

.ai-panel {
  position: relative;
  margin-top: 18px;
  padding: 28px 32px 32px;
  border-radius: 26px;
  border: 1px solid rgba(90, 169, 255, 0.28);
  background:
    radial-gradient(700px 260px at 8% 0%, rgba(90, 169, 255, 0.14), transparent 70%),
    linear-gradient(180deg, rgba(79, 214, 232, 0.035), rgba(4, 18, 31, 0.3));
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.3);
  overflow: hidden;
}

.ai-panel::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(90, 169, 255, 0.7), rgba(79, 214, 232, 0.5), transparent);
}

.ai-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.ai-title { display: flex; gap: 14px; align-items: center; }

.ai-spark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 13px;
  color: #cdd5ff;
  background: linear-gradient(140deg, rgba(90, 169, 255, 0.3), rgba(79, 214, 232, 0.16));
  border: 1px solid rgba(90, 169, 255, 0.35);
}

.ai-spark svg { width: 20px; height: 20px; }

.ai-title h3 { font-size: 17px; font-weight: 650; }
.ai-title p { margin-top: 2px; font-size: 11.5px; color: var(--muted); }

.ai-actions { display: flex; align-items: center; gap: 12px; flex: 0 0 auto; }

.ai-status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  letter-spacing: 0.04em;
  color: var(--muted);
}

.ai-status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.8;
}

.ai-status[data-state="streaming"] { color: var(--mint); }
.ai-status[data-state="streaming"]::before { animation: blink 1.1s ease-in-out infinite; }
.ai-status[data-state="done"] { color: var(--mint); }
.ai-status[data-state="local"] { color: var(--amber); }
.ai-status[data-state="error"] { color: var(--pink); }

@keyframes blink {
  0%, 100% { opacity: 0.25; }
  50% { opacity: 1; }
}

.ai-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  justify-content: space-between;
  margin-top: 20px;
  padding: 14px 16px;
  border-radius: 13px;
  border: 1px solid rgba(255, 207, 107, 0.26);
  background: rgba(255, 207, 107, 0.06);
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--text-soft);
}

.ai-banner-text { flex: 1 1 340px; margin: 0 !important; }
.ai-banner b { color: var(--amber); }

.ai-body { margin-top: 20px; }

.ai-skeleton {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 4px 0 8px;
}

.ai-skeleton span {
  display: block;
  height: 12px;
  border-radius: 6px;
  background: linear-gradient(90deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.13), rgba(255, 255, 255, 0.05));
  background-size: 200% 100%;
  animation: shimmer 1.5s ease-in-out infinite;
}

.ai-skeleton span:nth-child(1) { width: 92%; }
.ai-skeleton span:nth-child(2) { width: 100%; }
.ai-skeleton span:nth-child(3) { width: 68%; }

@keyframes shimmer {
  from { background-position: 200% 0; }
  to { background-position: -200% 0; }
}

.prose { font-size: 14.5px; line-height: 2; color: var(--text-soft); }

.prose h2 {
  margin: 30px 0 12px;
  font-size: 19px;
  letter-spacing: -0.02em;
  color: var(--text);
}

.prose h2:first-child { margin-top: 4px; }

.prose h3 {
  margin: 24px 0 8px;
  font-size: 15.5px;
  font-weight: 650;
  color: #cfd6ff;
}

.prose p { margin: 10px 0; }
.prose strong { color: var(--text); font-weight: 650; }
.prose em { color: var(--text-soft); }
.prose ul, .prose ol { margin: 10px 0; padding-left: 22px; }
.prose li { margin: 6px 0; }
.prose li::marker { color: var(--indigo); }

.prose blockquote {
  margin: 16px 0;
  padding: 10px 18px;
  border-left: 2px solid rgba(90, 169, 255, 0.6);
  color: var(--muted);
  font-size: 13px;
  background: rgba(90, 169, 255, 0.04);
  border-radius: 0 10px 10px 0;
}

.prose code {
  padding: 2px 6px;
  border-radius: 5px;
  background: rgba(255, 255, 255, 0.07);
  font-family: var(--font-mono);
  font-size: 12.5px;
  color: #cfe9ff;
}

.prose hr { margin: 22px 0; border: 0; border-top: 1px solid var(--border); }

.ai-body.is-streaming::after {
  content: "";
  display: inline-block;
  width: 9px;
  height: 18px;
  margin-left: 3px;
  vertical-align: -3px;
  background: var(--mint);
  border-radius: 2px;
  animation: blink 0.9s steps(2, start) infinite;
}

.ai-error {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 18px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid rgba(255, 143, 168, 0.3);
  background: rgba(255, 143, 168, 0.06);
  font-size: 13px;
  color: var(--text-soft);
}

.ai-error p { margin: 0; }

/* ---------------- 结果操作 ---------------- */

.result-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-top: 28px;
}

.report-disclaimer {
  max-width: 660px;
  margin: 30px auto 0;
  text-align: center;
  font-size: 11.5px;
  line-height: 1.9;
  color: var(--muted);
}

/* ---------------- 页脚 ---------------- */

.site-footer {
  border-top: 1px solid var(--border);
  background: rgba(2, 10, 18, 0.5);
}

.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 32px 28px 40px;
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 16px 24px;
  font-size: 12px;
  color: var(--muted);
}

.footer-inner .muted { margin-left: auto; max-width: 480px; line-height: 1.7; }

/* ---------------- 弹窗 ---------------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(2, 10, 18, 0.72);
  backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s;
}

.modal.is-open { opacity: 1; pointer-events: auto; }

.modal-card {
  width: min(520px, 100%);
  padding: 26px 28px 24px;
  border-radius: 22px;
  border: 1px solid var(--border-strong);
  background: #061a2b;
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6);
  transform: translateY(14px) scale(0.985);
  transition: transform 0.3s var(--ease);
}

.modal.is-open .modal-card { transform: translateY(0) scale(1); }

.modal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-head h3 { font-size: 18px; letter-spacing: -0.01em; }

.icon-btn {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-size: 22px;
  line-height: 1;
  transition: background 0.2s, color 0.2s;
}

.icon-btn:hover { background: rgba(255, 255, 255, 0.06); color: var(--text); }

.modal-desc {
  margin-top: 8px;
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--muted);
}

.field { display: block; margin-top: 16px; }

.field span {
  display: block;
  margin-bottom: 7px;
  font-size: 12px;
  color: var(--text-soft);
  letter-spacing: 0.02em;
}

.field span em { color: var(--muted); font-size: 11px; }

.field input {
  width: 100%;
  padding: 11px 14px;
  border-radius: 11px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.28);
  font-size: 13.5px;
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.field input:focus {
  border-color: rgba(90, 169, 255, 0.65);
  box-shadow: 0 0 0 3px rgba(90, 169, 255, 0.12);
}

.modal-hint {
  margin-top: 14px;
  font-size: 11.5px;
  line-height: 1.8;
  color: var(--muted);
}

.modal-hint code {
  padding: 1px 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.06);
  font-family: var(--font-mono);
  font-size: 11px;
  color: #cfe9ff;
}

.modal-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 24px;
}

.modal-actions .right { display: flex; gap: 8px; }

/* ---------------- 提示 ---------------- */

.toast {
  position: fixed;
  left: 50%;
  bottom: 30px;
  z-index: 120;
  transform: translate(-50%, 12px);
  padding: 11px 20px;
  border-radius: 999px;
  border: 1px solid var(--border-strong);
  background: rgba(6, 25, 40, 0.94);
  backdrop-filter: blur(10px);
  font-size: 12.5px;
  color: var(--text-soft);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, transform 0.25s var(--ease);
}

.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

/* ---------------- 响应式 ---------------- */

@media (max-width: 980px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
    padding-top: 10px;
    padding-bottom: 60px;
  }

  .hero-visual { min-height: 420px; order: -1; }
  .orbit { width: 360px; height: 360px; }
  .orbit-node { transform: translate(-50%, -50%) rotate(calc(var(--i) * 72deg)) translateY(-166px) rotate(calc(var(--i) * -72deg)); }
  .hero-copy h1 { margin-top: 18px; }
  .result-grid { grid-template-columns: 1fr; }
  .type-card { grid-template-columns: 1fr; gap: 18px; }
  .cards { grid-template-columns: 1fr; }
  .footer-inner .muted { margin-left: 0; }
}

@media (max-width: 720px) {
  .hero-visual { order: 0; min-height: 300px; }
  .orbit { width: 270px; height: 270px; }
  .orbit-node { transform: translate(-50%, -50%) rotate(calc(var(--i) * 72deg)) translateY(-124px) rotate(calc(var(--i) * -72deg)); }
  .site-header { padding: 16px 20px; }
  .site-nav { display: none; }
  .hero { padding: 0 20px 50px; }
  .orbit-node b { font-size: 10px; }
  .orbit-core { width: 120px; height: 120px; }
  .orbit-core strong { font-size: 42px; }
  .float-tag { display: none; }
  .hero-facts { gap: 28px; }
  .method, .about { padding: 60px 20px; }
  .about { padding-bottom: 80px; }
  #view-quiz { padding: 32px 14px 30px; }
  .quiz-card { padding: 28px 22px 22px; margin-top: 26px; }
  .q-text { min-height: 80px; margin: 14px 0 24px; }
  .kbd-hint { display: none; }
  .quiz-nav { justify-content: space-between; }
  .result-shell { padding: 0 18px; }
  .report-head { flex-direction: column; align-items: flex-start; gap: 12px; }
  .report-badge { display: none; }
  .chart-card, .bars-card { padding: 20px 18px; }
  .ai-panel { padding: 22px 18px 24px; }
  .ai-head { flex-direction: column; }
  .ai-actions { width: 100%; justify-content: space-between; }
  .note-head { flex-direction: column; gap: 4px; }
  .note-row { flex-direction: column; }
  .type-card { padding: 24px 20px; }
  .result-actions .btn { flex: 1 1 auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  html { scroll-behavior: auto; }
}

/* ---------------- 打印 ---------------- */

@media print {
  :root { --bg: #fff; --text: #111; --text-soft: #222; --muted: #555; --border: #ddd; }
  body { background: #fff !important; color: #111; }
  .backdrop, .site-header, .site-footer, .result-actions, .note-card,
  .ai-actions, .ai-banner, .modal, .toast, #view-home, #view-quiz, #view-analyzing { display: none !important; }
  #view-result { display: block !important; padding: 0; }
  .result-shell { padding: 0; max-width: none; }
  .card, .type-card, .ai-panel { border-color: #ddd !important; background: #fff !important; box-shadow: none !important; }
  .prose, .prose p, .prose li { color: #222 !important; }
  .prose h2 { color: #111 !important; }
  .report-badge { display: none; }
  .trait-fill { box-shadow: none !important; }
  a { text-decoration: none; }
}





/* ==========================================================================
   大肥鱼主题层（覆盖上面的基础视觉）
   ========================================================================== */

.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }

/* ---------- 水下背景 ---------- */

.light-ray {
  position: absolute;
  top: -30%;
  width: 170px;
  height: 145%;
  background: linear-gradient(180deg, rgba(190, 240, 255, 0.16), rgba(190, 240, 255, 0) 72%);
  filter: blur(10px);
  transform-origin: top center;
  animation: raySway 15s ease-in-out infinite alternate;
}

.ray-a { left: 5%; }
.ray-b { left: 43%; width: 230px; opacity: 0.7; animation-delay: -5s; }
.ray-c { left: 79%; opacity: 0.5; animation-delay: -9s; }

@keyframes raySway {
  from { opacity: 0.4; transform: rotate(12deg) translateX(-16px); }
  to { opacity: 0.8; transform: rotate(19deg) translateX(18px); }
}

.water-glow { position: absolute; border-radius: 50%; filter: blur(100px); opacity: 0.55; }
.glow-a { width: 640px; height: 640px; left: -12%; top: -4%; background: radial-gradient(circle, rgba(90, 169, 255, 0.5), transparent 65%); }
.glow-b { width: 540px; height: 540px; right: -10%; bottom: -12%; background: radial-gradient(circle, rgba(79, 214, 232, 0.32), transparent 65%); }

.bubbles-bg {
  position: absolute;
  inset: 0;
  opacity: 0.5;
  background-image:
    radial-gradient(circle at 12% 78%, rgba(190, 240, 255, 0.35) 0 1.5px, transparent 2.5px),
    radial-gradient(circle at 26% 42%, rgba(190, 240, 255, 0.22) 0 2px, transparent 3px),
    radial-gradient(circle at 48% 88%, rgba(190, 240, 255, 0.25) 0 1.5px, transparent 2.5px),
    radial-gradient(circle at 64% 26%, rgba(190, 240, 255, 0.18) 0 2px, transparent 3px),
    radial-gradient(circle at 82% 62%, rgba(190, 240, 255, 0.28) 0 1.5px, transparent 2.5px),
    radial-gradient(circle at 92% 14%, rgba(190, 240, 255, 0.2) 0 2px, transparent 3px);
  animation: bubblesDrift 46s linear infinite;
}

@keyframes bubblesDrift {
  from { background-position: 0 0, 0 0, 0 0, 0 0, 0 0, 0 0; }
  to { background-position: 0 -160px, 0 -260px, 0 -120px, 0 -300px, 0 -200px, 0 -240px; }
}

.grain { opacity: 0.03; }

/* ---------- 头部 ---------- */

.site-header {
  background: rgba(6, 26, 42, 0.62);
  border-color: rgba(150, 220, 255, 0.12);
  box-shadow: 0 18px 50px rgba(0, 10, 22, 0.35);
}

.brand-mark { width: 40px; height: 27px; }

.brand-text em { color: var(--muted); font-size: 10.5px; letter-spacing: 0.22em; }

.site-nav a:hover::after { background: linear-gradient(90deg, var(--indigo), var(--mint)); }

/* ---------- 按钮 ---------- */

.btn-primary {
  color: #031624;
  background: linear-gradient(120deg, #b6e9ff 0%, #5aa9ff 44%, #4fd6b0 100%);
  box-shadow: 0 12px 34px rgba(90, 169, 255, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.btn-primary:hover { box-shadow: 0 18px 44px rgba(90, 169, 255, 0.42), inset 0 1px 0 rgba(255, 255, 255, 0.7); }

.btn-ghost {
  border-color: rgba(150, 220, 255, 0.28);
  background: rgba(120, 200, 255, 0.045);
  color: var(--text-soft);
}

.btn-ghost:hover {
  border-color: rgba(79, 214, 232, 0.6);
  background: rgba(79, 214, 232, 0.09);
}

/* ---------- 首页 ---------- */

.hero-copy h1 { text-shadow: 0 16px 60px rgba(90, 169, 255, 0.22); }

.grad-text { background: linear-gradient(100deg, #b6e9ff 0%, #5aa9ff 42%, #4fd6b0 100%); -webkit-background-clip: text; background-clip: text; color: transparent; }

.hero-facts strong { color: #dff3ff; }

.whale-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 480px;
  height: 430px;
}

.whale-hero {
  position: relative;
  z-index: 2;
  width: min(420px, 88%);
  height: auto;
  filter: drop-shadow(0 30px 45px rgba(0, 18, 36, 0.5));
  animation: whaleSwim 6s ease-in-out infinite;
}

@keyframes whaleSwim {
  0%, 100% { transform: translateY(0) rotate(-1.6deg); }
  50% { transform: translateY(-16px) rotate(1.6deg); }
}

.sea-ring {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(150, 220, 255, 0.14);
}

.ring-a { width: 400px; height: 400px; }
.ring-b { width: 300px; height: 300px; border-style: dashed; opacity: 0.6; animation: spin 70s linear infinite; }

.whale-shadow {
  position: absolute;
  bottom: 46px;
  width: 240px;
  height: 22px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0, 8, 18, 0.55), transparent 70%);
  filter: blur(7px);
}

.bubble {
  position: absolute;
  z-index: 1;
  border-radius: 50%;
  border: 1px solid rgba(190, 240, 255, 0.5);
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.65), rgba(160, 225, 255, 0.06) 58%);
  animation: bubbleRise 8s linear infinite;
}

.b1 { left: 14%; bottom: 26%; width: 13px; height: 13px; animation-delay: 0s; }
.b2 { left: 24%; bottom: 38%; width: 8px; height: 8px; animation-delay: -2.4s; }
.b3 { left: 78%; bottom: 20%; width: 17px; height: 17px; animation-delay: -4.1s; }
.b4 { left: 86%; bottom: 42%; width: 10px; height: 10px; animation-delay: -1.2s; }
.b5 { left: 62%; bottom: 12%; width: 7px; height: 7px; animation-delay: -6s; }

@keyframes bubbleRise {
  0% { transform: translateY(26px) scale(0.5); opacity: 0; }
  18% { opacity: 0.9; }
  100% { transform: translateY(-250px) scale(1.15); opacity: 0; }
}

.float-tag {
  background: rgba(5, 28, 46, 0.78);
  border-color: rgba(150, 220, 255, 0.2);
  color: var(--text-soft);
}

/* ---------- 卡片 ---------- */

.card {
  background: linear-gradient(180deg, rgba(120, 200, 255, 0.09), rgba(4, 20, 35, 0.42));
  border-color: var(--border);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06), 0 24px 60px rgba(0, 10, 22, 0.35);
  backdrop-filter: blur(12px);
}

.cards .card:hover {
  border-color: rgba(120, 200, 255, 0.45);
  background: linear-gradient(180deg, rgba(120, 200, 255, 0.14), rgba(4, 20, 35, 0.4));
}

.card-icon {
  color: #bfe7ff;
  background: rgba(90, 169, 255, 0.14);
  border-color: rgba(120, 200, 255, 0.26);
}

.section-head h2, .about h2 { color: #e9f7ff; }

.about-note {
  border-color: rgba(255, 207, 107, 0.28);
  background: rgba(255, 207, 107, 0.055);
}

/* ---------- 答题 ---------- */

.quiz-card {
  position: relative;
  overflow: visible;
  background: linear-gradient(180deg, rgba(120, 200, 255, 0.10), rgba(3, 18, 31, 0.55));
  border-color: rgba(150, 220, 255, 0.18);
  box-shadow: 0 30px 80px rgba(0, 10, 25, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(14px);
}

.quiz-mascot {
  position: absolute;
  top: -54px;
  right: 16px;
  width: 124px;
  height: auto;
  transform: rotate(-6deg);
  filter: drop-shadow(0 14px 22px rgba(0, 18, 36, 0.45));
  pointer-events: none;
}

.q-text { color: #f0faff; }

.option {
  border-color: rgba(150, 220, 255, 0.14);
  background: rgba(120, 200, 255, 0.035);
}

.option:hover {
  border-color: rgba(120, 200, 255, 0.55);
  background: rgba(90, 169, 255, 0.1);
  transform: translateX(3px);
}

.option.is-selected {
  border-color: rgba(79, 214, 232, 0.85);
  background: linear-gradient(90deg, rgba(79, 214, 232, 0.2), rgba(90, 169, 255, 0.08));
  box-shadow: 0 0 0 1px rgba(79, 214, 232, 0.22), 0 12px 30px rgba(0, 40, 60, 0.25);
}

.option.is-selected .option-key { color: var(--mint); }
.option.is-selected .option-dot { border-color: var(--mint); background: var(--mint); box-shadow: 0 0 0 4px rgba(79, 214, 232, 0.16); }
.option.is-selected .option-dot::after { background: #041a2b; }

.progress span { background: linear-gradient(90deg, var(--indigo), var(--mint)); }

/* ---------- 计算中 ---------- */

.analyzing-orbit { width: 250px; height: 220px; }

.analyzing-whale {
  position: relative;
  z-index: 2;
  width: 205px;
  height: auto;
  animation: whaleSwim 4.5s ease-in-out infinite;
  filter: drop-shadow(0 20px 30px rgba(0, 18, 36, 0.45));
}

.ao-ring { inset: 6px; border-top-color: rgba(90, 169, 255, 0.9); border-right-color: rgba(90, 169, 255, 0.12); }
.ao-ring.r2 { inset: 26px; border-top-color: rgba(79, 214, 232, 0.9); }

.ao-bubble {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(190, 240, 255, 0.5);
  background: radial-gradient(circle at 32% 28%, rgba(255, 255, 255, 0.6), rgba(160, 225, 255, 0.05) 60%);
  animation: bubbleRise 5.5s linear infinite;
}

.ao-bubble.a1 { width: 12px; height: 12px; left: 18%; bottom: 16%; animation-delay: -1s; }
.ao-bubble.a2 { width: 8px; height: 8px; right: 16%; bottom: 24%; animation-delay: -3s; }
.ao-bubble.a3 { width: 16px; height: 16px; right: 26%; bottom: 8%; animation-delay: -4.4s; }

/* ---------- 结果 ---------- */

.report-head h1 em { background: linear-gradient(100deg, #b6e9ff, #4fd6b0); -webkit-background-clip: text; background-clip: text; color: transparent; }

.type-card {
  border-color: rgba(120, 200, 255, 0.3);
  background:
    radial-gradient(600px 220px at 0% 0%, rgba(90, 169, 255, 0.18), transparent 70%),
    radial-gradient(500px 200px at 100% 100%, rgba(79, 214, 232, 0.08), transparent 70%),
    linear-gradient(120deg, rgba(4, 22, 38, 0.5), rgba(4, 22, 38, 0.25));
}

.type-name { display: flex; align-items: center; }
.type-emoji { margin-right: 12px; font-size: 0.62em; line-height: 1; filter: saturate(0.92); }
.type-en { color: var(--muted); }

.chip { border-color: rgba(150, 220, 255, 0.18); background: rgba(120, 200, 255, 0.06); }

.note-row input { background: rgba(0, 12, 24, 0.4); border-color: rgba(150, 220, 255, 0.16); }
.note-row input:focus { border-color: rgba(79, 214, 232, 0.6); box-shadow: 0 0 0 3px rgba(79, 214, 232, 0.12); }

.ai-panel {
  border-color: rgba(120, 200, 255, 0.3);
  background:
    radial-gradient(700px 280px at 6% 0%, rgba(90, 169, 255, 0.17), transparent 70%),
    radial-gradient(500px 220px at 100% 100%, rgba(255, 143, 168, 0.06), transparent 70%),
    linear-gradient(180deg, rgba(79, 214, 232, 0.045), rgba(3, 18, 31, 0.35));
  box-shadow: 0 30px 80px rgba(0, 10, 26, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.ai-panel::before { background: linear-gradient(90deg, transparent, rgba(90, 169, 255, 0.75), rgba(79, 214, 232, 0.6), transparent); }

.ai-spark {
  width: 46px;
  height: 46px;
  padding: 4px;
  border-radius: 14px;
  color: #dff4ff;
  background: linear-gradient(140deg, rgba(90, 169, 255, 0.28), rgba(79, 214, 232, 0.14));
  border-color: rgba(120, 200, 255, 0.4);
}

.ai-spark svg { width: 42px; height: auto; }

.ai-title h3 { font-size: 18px; }

.prose h2 { color: #eaf8ff; }
.prose h3 { color: #bfe4ff; }
.prose li::marker { color: var(--mint); }
.prose blockquote { border-left-color: rgba(79, 214, 232, 0.6); background: rgba(79, 214, 232, 0.05); }

.ai-banner { border-color: rgba(255, 207, 107, 0.3); background: rgba(255, 207, 107, 0.07); }

.ai-status[data-state="streaming"] { color: var(--mint); }

.ai-skeleton span { background: linear-gradient(90deg, rgba(140, 215, 255, 0.06), rgba(140, 215, 255, 0.16), rgba(140, 215, 255, 0.06)); }

/* ---------- 页脚 / 弹窗 ---------- */

.site-footer { background: rgba(2, 12, 22, 0.65); border-top-color: rgba(150, 220, 255, 0.12); }

.modal { background: rgba(1, 8, 16, 0.76); }
.modal-card { background: #061a2b; border-color: rgba(150, 220, 255, 0.2); box-shadow: 0 40px 120px rgba(0, 8, 18, 0.65); }
.field input { background: rgba(0, 12, 24, 0.45); border-color: rgba(150, 220, 255, 0.16); }
.field input:focus { border-color: rgba(79, 214, 232, 0.65); box-shadow: 0 0 0 3px rgba(79, 214, 232, 0.12); }
.modal-hint code { background: rgba(120, 200, 255, 0.09); color: #bfe9ff; }

.toast { background: rgba(6, 26, 42, 0.95); border-color: rgba(150, 220, 255, 0.24); }

/* ---------- 响应式补充 ---------- */

@media (max-width: 980px) {
  .whale-stage { width: 400px; height: 360px; }
  .whale-hero { width: 340px; }
  .ring-a { width: 340px; height: 340px; }
  .ring-b { width: 260px; height: 260px; }
}

@media (max-width: 720px) {
  .whale-stage { width: 300px; height: 270px; }
  .whale-hero { width: 270px; }
  .ring-a { width: 270px; height: 270px; }
  .ring-b { width: 210px; height: 210px; }
  .whale-shadow { bottom: 26px; width: 170px; }
  .quiz-mascot { width: 82px; top: -34px; right: 6px; }
  .ai-spark { width: 40px; height: 40px; }
  .ai-spark svg { width: 36px; }
  .type-emoji { margin-right: 8px; }
}

/* ---------- 答题页：让本鱼游在卡片旁边，不挡进度 ---------- */

.quiz-mascot {
  top: 50%;
  right: -88px;
  width: 106px;
  transform: translateY(-50%) rotate(8deg);
  opacity: 0.95;
}

.progress { height: 4px; background: rgba(150, 220, 255, 0.12); }
.progress span { box-shadow: 0 0 16px rgba(79, 214, 232, 0.6); }

@media (max-width: 1100px) {
  .quiz-mascot { display: none; }
}

/* final polish */
.type-copy > p, .prose p { text-wrap: pretty; }
.analyzing-orbit { width: 275px; height: 245px; }
.analyzing-whale { width: 235px; }

/* ==========================================================================
   MAID CAFE THEME - based on the dafeiyu character art
   ========================================================================== */

:root {
  --bg: #0a1226;
  --bg-soft: #101b38;
  --surface: rgba(255, 255, 255, 0.05);
  --surface-2: rgba(255, 255, 255, 0.09);
  --border: rgba(205, 225, 255, 0.16);
  --border-strong: rgba(235, 243, 255, 0.32);
  --text: #f7f3ff;
  --text-soft: #cbd4ee;
  --muted: #95a3c7;
  --indigo: #8ea9ff;
  --mint: #b3ddff;
  --amber: #e8c98d;
  --pink: #f2b8c6;
  --sky: #bfe3ff;
  --sand: #f0d9a8;
  --lace: #fdf9f2;
  --ink: #1d2748;
  --gold: #e8c98d;
  --radius: 26px;
  --shadow: 0 30px 80px rgba(2, 8, 22, 0.55);
}

body {
  background:
    radial-gradient(1100px 650px at 82% -8%, rgba(142, 169, 255, 0.28), transparent 62%),
    radial-gradient(900px 600px at 6% 16%, rgba(179, 221, 255, 0.12), transparent 60%),
    radial-gradient(800px 600px at 88% 82%, rgba(242, 184, 198, 0.08), transparent 65%),
    linear-gradient(180deg, #101c38 0%, #0a1428 46%, #060c1a 100%);
}

.wave-art {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.9;
}

.sparkle {
  position: absolute;
  color: rgba(255, 250, 240, 0.8);
  font-size: 14px;
  text-shadow: 0 0 12px rgba(190, 225, 255, 0.9);
  animation: twinkle 4.5s ease-in-out infinite;
}

.s1 { left: 12%; top: 22%; font-size: 10px; animation-delay: -0.4s; }
.s2 { left: 78%; top: 14%; font-size: 16px; animation-delay: -1.8s; }
.s3 { left: 88%; top: 58%; font-size: 11px; animation-delay: -2.6s; }
.s4 { left: 22%; top: 74%; font-size: 13px; animation-delay: -3.2s; }
.s5 { left: 62%; top: 86%; font-size: 9px; animation-delay: -1.1s; }

@keyframes twinkle {
  0%, 100% { opacity: 0.15; transform: scale(0.8) rotate(0deg); }
  50% { opacity: 0.9; transform: scale(1.15) rotate(18deg); }
}

/* header */
.site-header {
  background: rgba(14, 25, 52, 0.72);
  border-color: rgba(253, 249, 242, 0.16);
  box-shadow: 0 18px 50px rgba(2, 8, 22, 0.4);
}

.brand { gap: 12px; }

.brand-avatar {
  display: block;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(253, 249, 242, 0.85);
  box-shadow: 0 0 0 3px rgba(142, 169, 255, 0.25), 0 8px 18px rgba(0, 0, 0, 0.35);
  flex: 0 0 auto;
}

.brand-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }

.brand-text { font-size: 20px; letter-spacing: 0.06em; }

.brand-text em {
  font-family: var(--font-display);
  color: var(--gold);
  font-size: 9.5px;
  letter-spacing: 0.24em;
}

.site-nav a:hover::after { background: linear-gradient(90deg, var(--gold), var(--mint)); }

/* buttons */
.btn-primary {
  color: #17224a;
  background: linear-gradient(135deg, #e4edff 0%, #a9c0ff 42%, #b9e3ff 100%);
  border: 1px solid rgba(255, 255, 255, 0.65);
  box-shadow: 0 12px 34px rgba(142, 169, 255, 0.34), inset 0 1px 0 rgba(255, 255, 255, 0.8);
}

.btn-primary:hover { box-shadow: 0 18px 44px rgba(142, 169, 255, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.9); }

.btn-ghost {
  border-color: rgba(253, 249, 242, 0.26);
  background: rgba(253, 249, 242, 0.045);
  color: var(--text-soft);
}

.btn-ghost:hover {
  border-color: rgba(232, 201, 141, 0.7);
  background: rgba(232, 201, 141, 0.10);
  color: var(--lace);
}

/* hero */
.hero { min-height: calc(100vh - 120px); gap: 40px; }

.hero h1 { text-shadow: 0 18px 60px rgba(142, 169, 255, 0.28); }

.grad-text {
  background: linear-gradient(100deg, #dfe9ff 0%, #a9c0ff 45%, #b9e3ff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-facts strong { color: var(--lace); font-family: var(--font-display); }
.hero-facts span { color: var(--muted); }

.hero-visual { position: relative; display: flex; align-items: center; justify-content: center; min-height: 540px; }

.portrait-stage {
  position: relative;
  width: 440px;
  height: 500px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.portrait-ring {
  position: absolute;
  inset: 8px;
  border-radius: 230px 230px 40px 40px;
  border: 1px dashed rgba(253, 249, 242, 0.35);
}

.portrait-frame {
  position: relative;
  width: 356px;
  height: 400px;
  border-radius: 190px 190px 28px 28px;
  overflow: hidden;
  border: 4px solid rgba(253, 249, 242, 0.92);
  box-shadow:
    0 0 0 10px rgba(253, 249, 242, 0.06),
    0 34px 70px rgba(0, 6, 18, 0.6),
    inset 0 0 40px rgba(142, 169, 255, 0.2);
  animation: portraitFloat 7s ease-in-out infinite;
}

.portrait-frame::after {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 178px 178px 20px 20px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  pointer-events: none;
}

.portrait-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 26%;
  display: block;
}

@keyframes portraitFloat {
  0%, 100% { transform: translateY(0) rotate(-0.6deg); }
  50% { transform: translateY(-12px) rotate(0.6deg); }
}

.portrait-say {
  position: absolute;
  top: 16px;
  right: -6px;
  z-index: 3;
  padding: 9px 15px;
  border-radius: 16px 16px 16px 4px;
  background: var(--lace);
  color: #2a3560;
  font-size: 12.5px;
  line-height: 1.5;
  white-space: nowrap;
  box-shadow: 0 14px 28px rgba(2, 8, 22, 0.4);
  transform: rotate(2.5deg);
}

.portrait-say::after {
  content: "";
  position: absolute;
  left: 22px;
  bottom: -8px;
  border: 8px solid transparent;
  border-top-color: var(--lace);
  border-bottom: 0;
}

.portrait-bow {
  position: absolute;
  top: 44px;
  left: 26px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #cfe0ff, #7f9be8);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.35);
  z-index: 3;
}

.portrait-bow::before,
.portrait-bow::after {
  content: "";
  position: absolute;
  top: -5px;
  width: 26px;
  height: 26px;
  background: linear-gradient(135deg, #bcd4ff, #7f9be8);
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25);
}

.portrait-bow::before { left: -26px; border-radius: 70% 30% 60% 40%; transform: rotate(18deg); }
.portrait-bow::after { right: -26px; border-radius: 30% 70% 40% 60%; transform: rotate(-18deg); }

.steam {
  position: absolute;
  z-index: 2;
  width: 9px;
  height: 64px;
  border-radius: 50%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.55), rgba(255, 255, 255, 0));
  filter: blur(7px);
  animation: steamRise 4.5s ease-in-out infinite;
}

.st1 { left: 44%; bottom: 32%; animation-delay: 0s; }
.st2 { left: 52%; bottom: 34%; height: 78px; animation-delay: -1.4s; }
.st3 { left: 58%; bottom: 30%; height: 54px; animation-delay: -2.7s; }

@keyframes steamRise {
  0% { opacity: 0; transform: translateY(18px) scaleX(0.8); }
  35% { opacity: 0.8; }
  100% { opacity: 0; transform: translateY(-70px) scaleX(1.5); }
}

.float-tag {
  background: rgba(14, 25, 52, 0.82);
  border-color: rgba(253, 249, 242, 0.2);
  color: var(--text-soft);
}

/* cards and sections */
.card {
  background: linear-gradient(180deg, rgba(42, 61, 110, 0.55), rgba(13, 23, 46, 0.78));
  border-color: rgba(205, 225, 255, 0.18);
  box-shadow: 0 24px 60px rgba(2, 8, 22, 0.4), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.cards .card:hover {
  border-color: rgba(232, 201, 141, 0.55);
  background: linear-gradient(180deg, rgba(52, 73, 128, 0.62), rgba(13, 23, 46, 0.78));
}

.card-icon {
  color: var(--gold);
  background: rgba(232, 201, 141, 0.10);
  border-color: rgba(232, 201, 141, 0.3);
}

.eyebrow .dot {
  background: var(--gold);
  box-shadow: 0 0 12px rgba(232, 201, 141, 0.9);
}

.section-head h2, .about h2 { color: var(--lace); }

.about-note {
  border-color: rgba(232, 201, 141, 0.32);
  background: rgba(232, 201, 141, 0.07);
  color: var(--text-soft);
}

.about-note span { color: var(--gold); }

/* quiz */
.quiz-card {
  background: linear-gradient(180deg, rgba(42, 61, 110, 0.58), rgba(11, 20, 41, 0.85));
  border-color: rgba(253, 249, 242, 0.18);
  box-shadow: 0 34px 80px rgba(2, 8, 22, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.quiz-card::before {
  content: "";
  position: absolute;
  top: 10px;
  left: 34px;
  right: 34px;
  height: 10px;
  background-image: radial-gradient(circle at 6px 0, rgba(253, 249, 242, 0.55) 5px, transparent 5.6px);
  background-size: 12px 10px;
  opacity: 0.65;
  pointer-events: none;
}

.q-text { color: var(--lace); }
.q-kicker { color: var(--muted); }
.q-kicker b { color: var(--gold); }

.option {
  border-color: rgba(205, 225, 255, 0.16);
  background: rgba(255, 255, 255, 0.035);
}

.option:hover {
  border-color: rgba(232, 201, 141, 0.55);
  background: rgba(232, 201, 141, 0.07);
}

.option.is-selected {
  border-color: rgba(142, 169, 255, 0.9);
  background: linear-gradient(90deg, rgba(142, 169, 255, 0.22), rgba(179, 221, 255, 0.08));
  box-shadow: 0 0 0 1px rgba(142, 169, 255, 0.3), 0 12px 30px rgba(5, 12, 30, 0.4);
}

.option.is-selected .option-key { color: var(--gold); }
.option.is-selected .option-dot { border-color: var(--gold); background: var(--gold); box-shadow: 0 0 0 4px rgba(232, 201, 141, 0.18); }
.option.is-selected .option-dot::after { background: #111d3a; }

.progress { height: 5px; background: rgba(253, 249, 242, 0.1); }
.progress span { background: linear-gradient(90deg, var(--gold), var(--indigo), var(--mint)); box-shadow: 0 0 16px rgba(142, 169, 255, 0.6); }

.quiz-mascot-wrap {
  position: absolute;
  top: 50%;
  right: -118px;
  transform: translateY(-50%);
  width: 118px;
  z-index: 3;
}

.quiz-mascot {
  display: block;
  width: 108px;
  height: 108px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(253, 249, 242, 0.92);
  box-shadow: 0 0 0 6px rgba(142, 169, 255, 0.18), 0 18px 34px rgba(2, 8, 22, 0.5);
}

.mascot-say {
  position: absolute;
  top: -8px;
  left: -34px;
  padding: 4px 9px;
  border-radius: 10px;
  background: var(--lace);
  color: #2a3560;
  font-size: 11px;
  line-height: 1.4;
  white-space: nowrap;
  transform: rotate(-5deg);
  box-shadow: 0 8px 18px rgba(2, 8, 22, 0.35);
}

/* analyzing */
.analyzing-stage {
  position: relative;
  width: 300px;
  height: 300px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 24px;
}

.ao-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1px dashed rgba(253, 249, 242, 0.35);
  animation: spin 24s linear infinite;
}

.ao-ring.r2 { inset: 26px; border-color: rgba(142, 169, 255, 0.4); animation-duration: 16s; animation-direction: reverse; }

.analyzing-portrait {
  width: 198px;
  height: 198px;
  border-radius: 50%;
  overflow: hidden;
  border: 4px solid rgba(253, 249, 242, 0.92);
  box-shadow: 0 0 0 8px rgba(142, 169, 255, 0.16), 0 24px 50px rgba(2, 8, 22, 0.55);
  animation: portraitFloat 5s ease-in-out infinite;
}

.analyzing-portrait img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 28%; display: block; }

.steam.ast1 { left: 46%; bottom: 22%; height: 54px; }
.steam.ast2 { left: 54%; bottom: 24%; height: 66px; animation-delay: -1.8s; }

.analyzing h2 { color: var(--lace); }
.analyzing-status { color: var(--gold); }

/* result */
.report-head h1 em {
  background: linear-gradient(100deg, #dfe9ff, #e8c98d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.report-badge { border-color: rgba(232, 201, 141, 0.4); color: var(--gold); }

.card-head h3 { color: var(--lace); }

/* cream menu cards */
.type-card,
.ai-panel,
.modal-card {
  color: #2b3559;
}

.type-card {
  border-color: rgba(232, 201, 141, 0.55);
  background:
    radial-gradient(500px 200px at 0% 0%, rgba(232, 201, 141, 0.18), transparent 70%),
    linear-gradient(180deg, #fffdf8 0%, #f9f1e4 100%);
  box-shadow: 0 26px 60px rgba(2, 8, 22, 0.4), inset 0 0 0 6px rgba(232, 201, 141, 0.12);
}

.type-label { color: #8a7f9f; }
.type-name { color: #1d2748; }
.type-en { color: #8a7f9f; }
.type-copy > p { color: #46517a; }
.chip { border-color: rgba(29, 39, 72, 0.18); background: rgba(29, 39, 72, 0.045); color: #3a4670; }

.note-card { background: linear-gradient(180deg, rgba(42, 61, 110, 0.45), rgba(13, 23, 46, 0.72)); }
.note-head h3 { color: var(--lace); }
.note-row input { background: rgba(4, 10, 24, 0.45); border-color: rgba(205, 225, 255, 0.2); }
.note-row input:focus { border-color: rgba(232, 201, 141, 0.7); box-shadow: 0 0 0 3px rgba(232, 201, 141, 0.12); }

/* AI cream paper */
.ai-panel {
  border: 1px solid rgba(232, 201, 141, 0.6);
  background:
    radial-gradient(700px 280px at 8% 0%, rgba(232, 201, 141, 0.16), transparent 70%),
    linear-gradient(180deg, #fffdf8 0%, #f8efe1 100%);
  box-shadow: 0 30px 80px rgba(2, 8, 22, 0.45), inset 0 0 0 7px rgba(255, 255, 255, 0.5);
}

.ai-panel::before { background: linear-gradient(90deg, transparent, rgba(232, 201, 141, 0.9), transparent); }

.ai-avatar {
  display: block;
  width: 54px;
  height: 54px;
  flex: 0 0 auto;
  border-radius: 50%;
  overflow: hidden;
  border: 2px solid rgba(232, 201, 141, 0.75);
  box-shadow: 0 8px 18px rgba(2, 8, 22, 0.2);
}

.ai-avatar img { width: 100%; height: 100%; object-fit: cover; display: block; }

.ai-title h3 { color: #1d2748; font-size: 18px; }
.ai-title p { color: #857b98; }

.ai-status { color: #857b98; }
.ai-status[data-state="streaming"] { color: #6f7fc0; }
.ai-status[data-state="done"] { color: #3f8f7a; }
.ai-status[data-state="local"] { color: #a5731f; }
.ai-status[data-state="error"] { color: #b7566a; }

.ai-actions .btn-ghost {
  border-color: rgba(29, 39, 72, 0.22);
  background: rgba(255, 255, 255, 0.45);
  color: #3a4670;
}

.ai-actions .btn-ghost:hover {
  border-color: rgba(165, 115, 31, 0.6);
  background: rgba(232, 201, 141, 0.2);
  color: #6b4b14;
}

.ai-banner {
  border-color: rgba(232, 201, 141, 0.55);
  background: rgba(232, 201, 141, 0.14);
  color: #5a5470;
}

.ai-banner b { color: #a5731f; }

.ai-panel .prose { color: #3a4368; }
.ai-panel .prose h2 { color: #1d2748; }
.ai-panel .prose h3 { color: #6b5a8e; }
.ai-panel .prose strong { color: #1d2748; }
.ai-panel .prose em { color: #4b5478; }
.ai-panel .prose blockquote {
  border-left-color: rgba(232, 201, 141, 0.9);
  background: rgba(232, 201, 141, 0.12);
  color: #6b6480;
}
.ai-panel .prose li::marker { color: #b08a4a; }
.ai-panel .prose code { background: rgba(29, 39, 72, 0.08); color: #3c4c7a; }
.ai-panel .prose hr { border-top-color: rgba(29, 39, 72, 0.12); }

.ai-body.is-streaming::after { background: #8ea9ff; }

.ai-error {
  border-color: rgba(183, 86, 106, 0.3);
  background: rgba(183, 86, 106, 0.08);
  color: #8a3f4c;
}

.ai-skeleton span { background: linear-gradient(90deg, rgba(29, 39, 72, 0.06), rgba(29, 39, 72, 0.14), rgba(29, 39, 72, 0.06)); }

/* modal as order slip */
.modal-card {
  background: linear-gradient(180deg, #fffdf8, #f8efe1);
  border: 1px solid rgba(232, 201, 141, 0.6);
  box-shadow: 0 40px 120px rgba(0, 4, 14, 0.65);
}

.modal-head h3 { color: #1d2748; }
.modal-desc, .modal-hint { color: #6b6480; }
.modal-hint code { background: rgba(29, 39, 72, 0.07); color: #3c4c7a; }
.field span { color: #3a4670; }
.field input {
  background: #ffffff;
  border-color: rgba(29, 39, 72, 0.18);
  color: #1d2748;
}
.field input:focus { border-color: rgba(142, 169, 255, 0.8); box-shadow: 0 0 0 3px rgba(142, 169, 255, 0.16); }
.icon-btn { color: #6b6480; }
.modal-actions .btn-ghost { border-color: rgba(29, 39, 72, 0.22); color: #3a4670; background: rgba(255, 255, 255, 0.5); }

.toast {
  background: rgba(253, 249, 242, 0.97);
  color: #2a3560;
  border-color: rgba(232, 201, 141, 0.6);
  box-shadow: 0 16px 40px rgba(2, 8, 22, 0.4);
}

.site-footer {
  background: rgba(5, 11, 24, 0.7);
  border-top: 1px solid rgba(253, 249, 242, 0.14);
}

/* responsive */
@media (max-width: 1100px) {
  .quiz-mascot-wrap { display: none; }
}

@media (max-width: 980px) {
  .hero-visual { order: 0; min-height: 480px; }
  .portrait-stage { width: 400px; height: 440px; }
  .portrait-frame { width: 320px; height: 360px; }
  .portrait-say { right: -14px; }
}

@media (max-width: 720px) {
  .brand-avatar { width: 38px; height: 38px; }
  .brand-text { font-size: 18px; }
  .brand-text em { font-size: 8px; }
  .portrait-stage { width: 320px; height: 370px; }
  .portrait-frame { width: 278px; height: 312px; border-width: 3px; }
  .portrait-say { top: 4px; right: -8px; font-size: 11px; padding: 7px 11px; }
  .portrait-bow { top: 26px; left: 8px; transform: scale(0.85); }
  .hero-visual { min-height: 400px; }
  .analyzing-stage { width: 250px; height: 250px; }
  .analyzing-portrait { width: 168px; height: 168px; }
  .ai-avatar { width: 46px; height: 46px; }
  .ai-panel { padding: 22px 18px 24px; }
}

@media print {
  .type-card, .ai-panel, .modal-card {
    background: #fff !important;
    color: #111 !important;
    box-shadow: none !important;
  }
  .ai-panel .prose, .ai-panel .prose p, .ai-panel .prose li { color: #222 !important; }
  .ai-panel .prose h2, .ai-panel .prose h3 { color: #111 !important; }
  .portrait-stage, .quiz-mascot-wrap, .analyzing-stage { display: none !important; }
}

/* mascot img reset (legacy absolute rules) */
.quiz-mascot {
  position: static;
  top: auto;
  right: auto;
  transform: none;
  width: 108px;
  height: 108px;
  opacity: 1;
}

/* placement fixes */
.tag-a { top: 63%; right: -6%; }
.tag-b { bottom: 2%; left: -4%; }

.quiz-mascot-wrap .mascot-say {
  top: -28px;
  left: 50%;
  transform: translateX(-50%) rotate(-3deg);
}

.quiz-mascot-wrap .mascot-say::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: -7px;
  margin-left: -6px;
  border: 6px solid transparent;
  border-top-color: var(--lace);
  border-bottom: 0;
}

.portrait-stage .portrait-bow { display: none; }

/* reading width on the cream menu */
.ai-panel .prose {
  max-width: 860px;
  margin-left: auto;
  margin-right: auto;
}
.ai-panel .prose h2 { font-size: 21px; letter-spacing: -0.01em; }
.ai-panel .prose h3 { font-size: 15.5px; }

/* ==========================================================================
   DSH-PET CHARACTER - Ciallo maid whale
   ========================================================================== */

.hero-visual { min-height: 570px; }

.pet-stage {
  position: relative;
  width: 500px;
  height: 560px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lace-halo {
  position: absolute;
  width: 430px;
  height: 430px;
  border-radius: 50%;
  border: 1px dashed rgba(253, 249, 242, 0.26);
  background: radial-gradient(circle at 50% 42%, rgba(253, 249, 242, 0.13), rgba(142, 169, 255, 0.07) 55%, transparent 72%);
}

.pet-art {
  position: relative;
  z-index: 2;
  width: 446px;
  height: auto;
  filter: drop-shadow(0 26px 42px rgba(0, 8, 20, 0.55));
  animation: petFloat 5.5s ease-in-out infinite;
  transform-origin: 50% 92%;
}

@keyframes petFloat {
  0%, 100% { transform: translateY(0) rotate(-0.8deg); }
  50% { transform: translateY(-14px) rotate(0.8deg); }
}

.pet-shadow {
  position: absolute;
  bottom: 54px;
  z-index: 1;
  width: 250px;
  height: 26px;
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(0, 6, 16, 0.6), transparent 70%);
  filter: blur(8px);
}

.sparkle.ps1 { left: 6%; top: 22%; font-size: 16px; color: rgba(255, 250, 240, 0.9); }
.sparkle.ps2 { right: 4%; top: 16%; font-size: 11px; animation-delay: -1.6s; }
.sparkle.ps3 { right: 10%; bottom: 22%; font-size: 13px; animation-delay: -2.8s; }

.pet-stage .portrait-say {
  top: 8px;
  right: -4px;
  z-index: 4;
}

/* analyzing pet video */
.analyzing-stage {
  position: relative;
  width: 370px;
  height: 370px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-bottom: 20px;
}

.analyzing-video {
  position: relative;
  z-index: 2;
  width: 1120px;
  max-width: none;
  height: auto;
  filter: drop-shadow(0 22px 36px rgba(0, 8, 20, 0.5));
}

.analyzing-stage .ao-ring { inset: 14px; }
.analyzing-stage .ao-ring.r2 { inset: 42px; }

@media (max-width: 980px) {
  .pet-stage { width: 440px; height: 490px; }
  .pet-art { width: 384px; }
  .lace-halo { width: 370px; height: 370px; }
  .pet-shadow { bottom: 44px; width: 210px; }
}

@media (max-width: 720px) {
  .pet-stage { width: 340px; height: 400px; }
  .pet-art { width: 306px; }
  .lace-halo { width: 300px; height: 300px; }
  .pet-shadow { bottom: 34px; width: 170px; }
  .pet-stage .portrait-say { top: 0; right: -6px; font-size: 11px; padding: 7px 11px; }
  .analyzing-stage { width: 280px; height: 280px; }
  .analyzing-video { width: 860px; }
}

.analyzing-stage { width: 380px; height: 380px; }
.analyzing-video { width: 1280px; }
@media (max-width: 720px) {
  .analyzing-stage { width: 290px; height: 290px; }
  .analyzing-video { width: 980px; }
}

/* ==========================================================================
   AI HOST + PET DOCK
   ========================================================================== */

#view-preparing {
  display: none;
  min-height: 88vh;
  align-items: center;
  justify-content: center;
  text-align: center;
}

#view-preparing.is-active { display: flex; }

.pet-dock {
  display: none;
  position: fixed;
  right: 26px;
  bottom: 18px;
  z-index: 45;
  width: 160px;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
}

body[data-view="quiz"] .pet-dock { display: flex; }

.pet-bubble {
  position: relative;
  max-width: 210px;
  margin-bottom: 10px;
  padding: 8px 12px;
  border-radius: 14px 14px 4px 14px;
  background: var(--lace);
  color: #243057;
  font-size: 12.5px;
  line-height: 1.55;
  box-shadow: 0 12px 26px rgba(2, 8, 22, 0.4);
  opacity: 0;
  transform: translateY(6px) scale(0.96);
  transition: opacity 0.2s, transform 0.25s var(--ease);
}

.pet-bubble.is-visible { opacity: 1; transform: translateY(0) scale(1); }

.pet-bubble::after {
  content: "";
  position: absolute;
  right: 28px;
  bottom: -7px;
  border: 7px solid transparent;
  border-top-color: var(--lace);
  border-bottom: 0;
}

.pet-dock-img {
  width: 108px;
  height: 108px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid rgba(253, 249, 242, 0.92);
  box-shadow: 0 0 0 6px rgba(142, 169, 255, 0.18), 0 18px 34px rgba(2, 8, 22, 0.5);
  animation: dockBob 3.6s ease-in-out infinite;
}

@keyframes dockBob {
  0%, 100% { transform: translateY(0) rotate(-1deg); }
  50% { transform: translateY(-6px) rotate(1deg); }
}

@media (max-width: 1100px) {
  .pet-dock { display: none !important; }
}

/* summary strip */
.summary-strip {
  display: flex;
  align-items: flex-start;
  gap: 18px;
  margin-top: 34px;
  padding: 22px 26px;
  border-radius: 22px;
  border: 1px solid rgba(232, 201, 141, 0.42);
  background:
    radial-gradient(600px 180px at 0% 0%, rgba(232, 201, 141, 0.14), transparent 70%),
    linear-gradient(120deg, rgba(142, 169, 255, 0.10), rgba(9, 18, 38, 0.5));
  box-shadow: 0 22px 50px rgba(2, 8, 22, 0.32);
}

.summary-avatar img {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(232, 201, 141, 0.8);
  box-shadow: 0 8px 18px rgba(2, 8, 22, 0.3);
}

.summary-body { flex: 1; min-width: 0; }

.summary-kicker {
  font-family: var(--font-mono);
  font-size: 10.5px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
}

.summary-line {
  margin-top: 7px;
  font-size: 15.5px;
  line-height: 1.8;
  color: var(--lace);
}

.summary-points {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.summary-points li {
  padding: 6px 11px;
  border-radius: 999px;
  border: 1px solid rgba(253, 249, 242, 0.16);
  background: rgba(253, 249, 242, 0.045);
  font-size: 11.5px;
  color: var(--text-soft);
}

.summary-points b {
  margin-right: 5px;
  font-weight: 600;
  color: var(--gold);
}

@media (max-width: 720px) {
  .summary-strip { flex-direction: column; gap: 12px; padding: 18px 18px; margin-top: 24px; }
  .summary-avatar img { width: 44px; height: 44px; }
  .summary-line { font-size: 14.5px; }
}

body[data-view="preparing"] .site-header {
  opacity: 0;
  pointer-events: none;
}
body[data-view="preparing"] .site-footer { display: none; }

@media print {
  .summary-strip {
    background: #fff !important;
    border-color: #ddd !important;
    box-shadow: none !important;
  }
  .summary-line { color: #111 !important; }
  .summary-kicker { color: #8a6a2a !important; }
  .summary-points li { color: #333 !important; border-color: #ddd !important; background: #fafafa !important; }
}

/* ==========================================================================
   FORTUNE + DREAM SERVICES
   ========================================================================== */

.services {
  max-width: var(--max);
  margin: 0 auto;
  padding: 10px 28px 90px;
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  margin-top: 34px;
}

.service-card {
  display: block;
  padding: 28px 28px 26px;
  border-radius: 26px;
  border: 1px solid rgba(205, 225, 255, 0.18);
  background: linear-gradient(180deg, rgba(42, 61, 110, 0.5), rgba(13, 23, 46, 0.78));
  color: var(--text);
  text-align: left;
  transition: transform 0.3s var(--ease), border-color 0.3s, background 0.3s;
}

.service-card:hover {
  transform: translateY(-4px);
  border-color: rgba(232, 201, 141, 0.55);
  background: linear-gradient(180deg, rgba(52, 73, 128, 0.6), rgba(13, 23, 46, 0.8));
}

.service-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 50px;
  height: 50px;
  margin-bottom: 18px;
  border-radius: 15px;
  color: var(--gold);
  background: rgba(232, 201, 141, 0.10);
  border: 1px solid rgba(232, 201, 141, 0.28);
}

.service-icon svg { width: 24px; height: 24px; }

.service-card h3 { font-size: 19px; letter-spacing: -0.01em; }
.service-card p { margin-top: 8px; font-size: 13.5px; line-height: 1.8; color: var(--muted); }

.service-link {
  display: inline-block;
  margin-top: 16px;
  font-size: 12.5px;
  color: var(--gold);
}

.service-shell {
  max-width: 1000px;
  margin: 0 auto;
  padding: 48px 28px 100px;
}

.service-head .link-btn { margin-bottom: 18px; }

.service-head .eyebrow { margin-bottom: 12px; }

.service-head h1 {
  font-size: clamp(2.1rem, 4.4vw, 3.2rem);
  letter-spacing: -0.04em;
  line-height: 1.12;
}

.service-head h1 em {
  background: linear-gradient(100deg, #dfe9ff, #e8c98d);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.service-lede {
  max-width: 62ch;
  margin-top: 14px;
  font-size: 14.5px;
  line-height: 1.9;
  color: var(--text-soft);
}

.service-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 22px;
  align-items: start;
  margin-top: 32px;
}

.divination-form { padding: 28px 28px 24px; }
.divination-form .field { margin-top: 0; margin-bottom: 18px; }

.field select,
.field textarea {
  width: 100%;
  padding: 11px 14px;
  border-radius: 11px;
  border: 1px solid rgba(205, 225, 255, 0.18);
  background: rgba(0, 12, 24, 0.45);
  color: var(--text);
  font-size: 13.5px;
  outline: none;
}

.field select:focus,
.field textarea:focus {
  border-color: rgba(232, 201, 141, 0.65);
  box-shadow: 0 0 0 3px rgba(232, 201, 141, 0.12);
}

.field textarea {
  min-height: 160px;
  resize: vertical;
  line-height: 1.8;
}

.zodiac-preview {
  margin: -6px 0 16px;
  font-size: 12px;
  color: var(--gold);
}

.form-hint {
  margin-top: 12px;
  font-size: 11px;
  line-height: 1.7;
  color: var(--muted);
}

.service-pet {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 6px;
}

.service-pet img {
  width: 290px;
  height: auto;
  filter: drop-shadow(0 24px 38px rgba(0, 8, 20, 0.55));
  animation: petFloat 6s ease-in-out infinite;
}

.service-bubble {
  max-width: 240px;
  margin-top: 4px;
  padding: 9px 14px;
  border-radius: 14px 14px 14px 4px;
  background: var(--lace);
  color: #243057;
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
  box-shadow: 0 14px 28px rgba(2, 8, 22, 0.4);
  transform: rotate(-1.5deg);
}

.service-result { margin-top: 26px; }
.service-result.is-hidden { display: none; }

.service-note {
  margin-top: 26px;
  font-size: 11px;
  line-height: 1.9;
  color: var(--muted);
  text-align: center;
}

@media (max-width: 900px) {
  .service-layout { grid-template-columns: 1fr; }
  .service-pet { order: -1; }
  .service-pet img { width: 220px; }
}

@media (max-width: 720px) {
  .services { padding: 0 20px 60px; }
  .service-grid { grid-template-columns: 1fr; }
  .service-shell { padding: 32px 18px 80px; }
  .divination-form { padding: 22px 18px; }
  .service-pet img { width: 190px; }
}

.service-config { display: inline-block; margin-top: 12px; color: var(--gold); }
.service-config:hover { color: var(--lace); }

.divination-form { color-scheme: dark; }
.divination-form .field > span { color: var(--text-soft); }
.divination-form .field > span em { color: var(--muted); }
.divination-form .field input {
  background: rgba(0, 12, 24, 0.45);
  border-color: rgba(205, 225, 255, 0.18);
  color: var(--text);
}
.divination-form .field input::placeholder { color: rgba(149, 163, 199, 0.7); }
.divination-form .field input:focus {
  border-color: rgba(232, 201, 141, 0.65);
  box-shadow: 0 0 0 3px rgba(232, 201, 141, 0.12);
}

.service-result { scroll-margin-top: 92px; }

/* ==========================================================================
   DAILY QUOTA
   ========================================================================== */

.quota-line {
  margin-top: 10px;
  font-size: 11.5px;
  line-height: 1.7;
  color: var(--muted);
}

.quota-line b {
  color: var(--gold);
  font-weight: 600;
}

.quota-line.is-empty { color: #f2a8c0; }

.btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none !important;
}

.limit-note {
  padding: 20px 22px;
  border-radius: 12px;
  background: #fdf0f2;
  border: 1px solid #f0c9d1;
  color: #8b3346;
  font-size: 13.5px;
  line-height: 1.9;
}

/* ==========================================================================
   MOBILE PERFORMANCE
   ========================================================================== */

.analyzing-still { display: none; }

@media (max-width: 900px) {
  /* 关闭最耗 GPU 的毛玻璃与装饰动画 */
  * { backdrop-filter: none !important; }
  .grain,
  .sparkle { display: none !important; }

  .pet-art,
  .service-pet img,
  .pet-dock-img,
  .brand-avatar img,
  .ai-avatar img,
  .summary-avatar img,
  .whale-hero,
  .analyzing-still {
    filter: none !important;
    animation: none !important;
  }

  .view.is-active { animation-duration: 0.18s; }
  .site-header { box-shadow: none; }

  /* 手机不加载/不解码透明视频，用静态立绘 */
  .analyzing-video { display: none !important; }
  .analyzing-still {
    display: block;
    width: 240px;
    height: auto;
    margin: 0 auto;
  }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* 手机端答题页：内联桌宠，避免固定悬浮遮挡选项 */
.quiz-pet-mobile { display: none; }

@media (max-width: 1100px) {
  .quiz-pet-mobile {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 12px 0 6px;
    padding: 8px 12px;
    border-radius: 16px 16px 16px 6px;
    background: rgba(253, 249, 242, 0.94);
    color: #243057;
    box-shadow: 0 8px 20px rgba(2, 8, 22, 0.25);
  }
  .quiz-pet-mobile img {
    width: 46px;
    height: 46px;
    flex: 0 0 auto;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid #fff;
  }
  .quiz-pet-say {
    margin: 0;
    font-size: 12px;
    line-height: 1.5;
  }
}
