:root {
  color-scheme: dark;
  --ink: #fcf7ff;
  --muted: #c9bfdf;
  --soft: #a99fc3;
  --line: rgba(237, 226, 255, .19);
  --line-strong: rgba(255, 238, 246, .6);
  --violet: #af96ff;
  --berry: #ff829f;
  --berry-light: #ffb6c7;
  --night: #17132e;
  --card: rgba(27, 24, 57, .82);
  --card-strong: rgba(38, 31, 75, .91);
  font-family: ui-sans-serif, -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html { min-height: 100%; background: var(--night); }
body { min-width: 320px; min-height: 100%; margin: 0; color: var(--ink); background: var(--night); }
button, input { font: inherit; }
button { cursor: pointer; }
button:focus-visible, input:focus-visible { outline: 2px solid var(--berry-light); outline-offset: 3px; }

#response-field {
  position: fixed;
  inset: 0;
  z-index: 0;
  display: block;
  width: 100vw;
  height: 100svh;
  pointer-events: none;
}

#app { position: relative; z-index: 1; min-height: 100svh; }
.shell { position: relative; width: min(100%, 720px); min-height: 100svh; margin: 0 auto; padding: max(26px, env(safe-area-inset-top)) clamp(24px, 7vw, 52px) max(30px, env(safe-area-inset-bottom)); }
.topline, .eyebrow, .scene-label, .card-kicker, .result-code, .question-header, .progress-track, .quiet-note, .reveal-copy { letter-spacing: .08em; }
.topline { display: flex; align-items: center; justify-content: space-between; color: rgba(245, 233, 255, .66); font-size: 11px; font-weight: 700; }
.topline span { color: var(--berry-light); }
.eyebrow { margin: 0; color: var(--berry-light); font-size: 13px; font-weight: 700; }
.display-title, .page-title, .result-title, .incoming-message p { font-family: "Songti SC", "STSong", "Noto Serif CJK SC", serif; }
.display-title { margin: 18px 0 0; font-size: clamp(43px, 10vw, 67px); line-height: 1.11; letter-spacing: -.055em; font-weight: 700; }
.page-title { margin: 17px 0 0; font-size: clamp(32px, 7vw, 48px); line-height: 1.26; letter-spacing: -.04em; font-weight: 700; }
.hero-copy { margin: 25px 0 0; color: var(--muted); font-size: 16px; line-height: 1.9; }
.landing-shell { display: flex; flex-direction: column; }
.landing-hero { padding-top: min(15vh, 118px); }
.landing-foot { margin-top: auto; padding-top: 42px; }
.signal-line { display: flex; align-items: center; gap: 12px; margin: 0 0 20px; color: var(--muted); font-size: 12px; letter-spacing: .12em; }
.signal-line i { flex: 1; height: 1px; background: linear-gradient(90deg, transparent, rgba(255, 218, 232, .5)); }
.signal-line i:last-child { background: linear-gradient(90deg, rgba(255, 218, 232, .5), transparent); }

.activation-card { padding: 16px; border: 1px solid var(--line); border-radius: 24px; background: rgba(24, 20, 51, .75); box-shadow: 0 18px 48px rgba(4, 2, 19, .2); backdrop-filter: blur(13px); }
.activation-card label { display: block; margin: 0 0 11px 2px; color: var(--muted); font-size: 13px; font-weight: 700; }
.activation-row { display: grid; grid-template-columns: 1fr auto; gap: 10px; }
.activation-row input { min-width: 0; height: 48px; padding: 0 14px; border: 1px solid rgba(245, 232, 255, .28); border-radius: 14px; color: var(--ink); background: rgba(15, 13, 35, .85); text-transform: uppercase; }
.activation-row input::placeholder { color: #837a9f; text-transform: none; }
.activation-button, .primary-button { border: 0; border-radius: 15px; color: #2a1426; background: linear-gradient(135deg, #ffd7e4, #ff8eab 58%, #c9a8ff); font-weight: 800; box-shadow: 0 9px 25px rgba(255, 113, 153, .22); transition: transform .22s ease, filter .22s ease; }
.activation-button { min-width: 74px; padding: 0 17px; }
.primary-button { display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 58px; padding: 0 22px; font-size: 16px; }
.primary-button span { font-size: 21px; line-height: 1; }
.primary-button:hover, .activation-button:hover { transform: translateY(-2px); filter: brightness(1.06); }
.primary-button:disabled, .activation-button:disabled { cursor: wait; opacity: .62; transform: none; }
.quiet-note { margin: 14px 0 0; color: #958bac; font-size: 11px; text-align: center; }
.form-error, .question-error { margin: 11px 2px 0; color: #ffc1d0; font-size: 13px; line-height: 1.55; }

.text-button, .close-button { border: 0; color: var(--muted); background: transparent; }
.back-button { padding: 0; font-size: 14px; }
.intro-shell { display: flex; flex-direction: column; }
.intro-shell .topline { margin-top: 38px; }
.intro-content { padding-top: min(13vh, 105px); }
.intro-list { display: grid; gap: 13px; margin-top: 38px; }
.intro-list p { display: grid; grid-template-columns: 42px 1fr; gap: 14px; align-items: start; margin: 0; padding: 15px 0; border-bottom: 1px solid var(--line); color: var(--muted); line-height: 1.65; }
.intro-list b { color: var(--berry-light); font-family: Georgia, serif; font-size: 18px; font-weight: 400; }
.intro-shell .primary-button { margin-top: auto; }

.question-shell { padding-inline: clamp(20px, 5.8vw, 46px); }
.question-header { display: grid; grid-template-columns: 44px 1fr 44px; align-items: center; color: var(--muted); font-size: 12px; font-weight: 700; text-align: center; }
.question-header p { margin: 0; }
.close-button { width: 34px; height: 34px; padding: 0; border: 1px solid transparent; border-radius: 50%; font-size: 26px; line-height: 1; }
.close-button:hover { border-color: var(--line); }
.question-count { color: var(--berry-light); font-size: 14px; }
.progress-track { display: grid; grid-template-columns: repeat(10, 1fr); gap: 5px; margin-top: 15px; }
.progress-track i { height: 3px; border-radius: 3px; background: rgba(218, 200, 255, .2); }
.progress-track i.done { background: rgba(255, 175, 199, .75); }
.progress-track i.current { background: #fff1f6; box-shadow: 0 0 16px rgba(255, 197, 216, .9); }
.question-stage { padding-top: min(18vh, 148px); }
.scene-label { max-width: 460px; margin: 0 0 18px; color: #e1d7f4; font-size: 16px; line-height: 1.65; }
.incoming-message { position: relative; max-width: 580px; padding: 24px 24px 23px; border: 1px solid rgba(234, 221, 255, .38); border-radius: 8px 25px 25px 25px; background: rgba(42, 35, 80, .74); box-shadow: 0 15px 45px rgba(7, 4, 28, .16); backdrop-filter: blur(12px); }
.incoming-message::before { content: ""; position: absolute; left: -10px; top: 21px; width: 19px; height: 19px; border-top: 1px solid rgba(234, 221, 255, .38); border-left: 1px solid rgba(234, 221, 255, .38); background: rgba(42, 35, 80, .74); transform: rotate(-45deg); }
.incoming-message p { position: relative; z-index: 1; margin: 0; color: #fffaff; font-size: clamp(26px, 5.7vw, 38px); line-height: 1.37; letter-spacing: -.035em; }
.message-dot { position: absolute; top: -14px; left: 23px; width: 27px; height: 27px; border: 5px solid #d5c3ff; border-radius: 50%; background: linear-gradient(135deg, #ff9fba, #987df4); box-shadow: 0 0 20px rgba(226, 171, 255, .65); }
.answer-prompt { margin: 51px 0 14px; color: #e7def5; font-size: 15px; font-weight: 700; }
.answer-list { display: grid; gap: 12px; }
.answer-button { position: relative; display: grid; grid-template-columns: 34px 1fr 20px; gap: 12px; align-items: center; width: min(100%, 590px); min-height: 75px; padding: 15px 17px; border: 1px solid rgba(235, 222, 255, .38); border-radius: 22px 8px 22px 22px; color: var(--ink); background: rgba(26, 22, 56, .78); text-align: left; transition: transform .22s ease, background .22s ease, border-color .22s ease; backdrop-filter: blur(8px); }
.answer-button:nth-child(2n) { margin-left: auto; border-radius: 8px 22px 22px 22px; background: rgba(48, 39, 88, .77); }
.answer-button span { display: grid; width: 28px; height: 28px; place-items: center; border: 1px solid rgba(255, 218, 232, .55); border-radius: 50%; color: #ffd8e5; font-size: 12px; font-weight: 800; }
.answer-button strong { font-size: 15px; line-height: 1.58; font-weight: 650; }
.answer-button b { color: var(--berry-light); font-size: 17px; font-weight: 400; }
.answer-button:hover, .answer-button.selected { border-color: rgba(255, 225, 237, .93); background: rgba(77, 55, 119, .9); box-shadow: 0 12px 28px rgba(12, 7, 36, .25); transform: translateY(-2px); }
.answer-button:disabled { cursor: wait; }

.reveal-shell { display: grid; place-content: center; min-height: 100svh; text-align: center; }
.reveal-shell .eyebrow { text-align: center; }
.reveal-shell .page-title { margin-top: 20px; }
.reveal-copy { margin: 22px 0 0; color: var(--muted); font-size: 12px; }
.reveal-orbit { width: 150px; height: 150px; margin: 0 auto 44px; border: 1px solid rgba(255, 214, 230, .53); border-radius: 50%; box-shadow: inset 0 0 35px rgba(172, 138, 255, .25), 0 0 45px rgba(255, 117, 159, .17); animation: breathe 2.7s ease-in-out infinite; }

.result-shell { padding-bottom: 52px; }
.result-header { display: flex; align-items: center; justify-content: space-between; color: var(--muted); font-size: 11px; font-weight: 800; letter-spacing: .1em; }
.result-header p { margin: 0; }
.result-header .text-button { color: var(--berry-light); font-size: 13px; }
.result-hero { padding: 51px 0 8px; text-align: center; }
.result-hero .eyebrow { color: #ffd3e0; }
.result-title { max-width: 620px; margin: 16px auto 0; font-size: clamp(34px, 7.4vw, 53px); line-height: 1.18; letter-spacing: -.055em; }
.result-code { margin: 17px 0 10px; color: #a89dbd; font-size: 11px; }
#result-radar { display: block; width: min(100%, 340px); aspect-ratio: 1; height: auto; margin: 2px auto 12px; }
.result-card { margin-top: 18px; padding: 25px 23px; border: 1px solid rgba(240, 228, 255, .2); border-radius: 27px; background: var(--card); box-shadow: 0 14px 40px rgba(4, 3, 20, .13); backdrop-filter: blur(14px); }
.result-card p { margin: 0; color: #ddd4e8; font-size: 15px; line-height: 1.85; }
.result-card p + p { margin-top: 16px; }
.card-kicker { margin-bottom: 12px !important; color: var(--berry-light) !important; font-size: 12px !important; font-weight: 800; }
.two-column-card { display: grid; gap: 25px; }
.two-column-card > div + div { padding-top: 23px; border-top: 1px solid var(--line); }
.companion-card { border-color: rgba(181, 160, 255, .36); background: rgba(48, 38, 93, .8); }
.strength-card { border-color: rgba(255, 191, 210, .38); background: linear-gradient(142deg, rgba(75, 48, 97, .89), rgba(39, 28, 73, .92)); }
.strength-card h2 { margin: 0 0 16px; color: #fff8fb; font-family: "Songti SC", "STSong", serif; font-size: 25px; line-height: 1.4; letter-spacing: -.025em; }
.inner-voice { margin: 18px 0 0; padding: 26px 25px 25px; border-left: 3px solid var(--berry); background: rgba(255, 180, 205, .08); color: #fff1f6; font-family: "Songti SC", "STSong", serif; font-size: 22px; line-height: 1.68; letter-spacing: -.02em; }
.inner-voice span { display: block; margin-bottom: 11px; color: var(--berry-light); font-family: ui-sans-serif, sans-serif; font-size: 12px; font-weight: 800; letter-spacing: .09em; }
.result-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-top: 26px; }
.secondary-button { min-height: 54px; border: 1px solid rgba(247, 232, 255, .47); border-radius: 15px; color: var(--ink); background: rgba(37, 29, 72, .74); font-weight: 750; }
.primary-button.compact { min-height: 54px; padding-inline: 17px; font-size: 14px; }
.result-disclaimer { margin: 21px 8px 0; color: #9e93b6; font-size: 11px; line-height: 1.65; text-align: center; }

.rise-1, .rise-2, .rise-3, .rise-4, .rise-5, .lift-in { animation: rise .68s both cubic-bezier(.22,.72,.25,1); }
.rise-2 { animation-delay: .08s; } .rise-3 { animation-delay: .16s; } .rise-4 { animation-delay: .24s; } .rise-5 { animation-delay: .32s; }
@keyframes rise { from { opacity: 0; transform: translateY(15px); } to { opacity: 1; transform: translateY(0); } }
@keyframes breathe { 0%, 100% { transform: scale(.93); opacity: .65; } 50% { transform: scale(1.07); opacity: 1; } }

@media (min-width: 700px) {
  .shell { padding-inline: 58px; }
  .two-column-card { grid-template-columns: 1fr 1fr; gap: 30px; }
  .two-column-card > div + div { padding-top: 0; padding-left: 30px; border-top: 0; border-left: 1px solid var(--line); }
}

@media (max-width: 390px) {
  .question-stage { padding-top: 10vh; }
  .answer-button { min-height: 67px; padding: 12px 14px; gap: 9px; }
  .answer-button strong { font-size: 14px; }
  .incoming-message { padding: 20px 19px; }
}

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