/* ===================================================
   现实行动方式 — 暖黑纸张 + 行动路线图视觉
   Warm dark paper · personal action map · chips · possibility map
   Entertainment-oriented self exploration
   =================================================== */

@import url('https://fonts.googleapis.com/css2?family=DM+Mono:wght@400;500&family=Noto+Serif+SC:wght@400;600;700;900&family=Noto+Sans+SC:wght@400;500;700&display=swap');

:root {
  --paper:       #1e1814;
  --paper2:      #2a221c;
  --panel:       rgba(42, 34, 28, 0.82);
  --card:        rgba(55, 44, 36, 0.68);
  --line:        rgba(200, 170, 130, 0.2);
  --line-strong: rgba(200, 170, 130, 0.35);
  --ink:         #f0e7da;
  --ink-muted:   rgba(240, 231, 218, 0.72);
  --ink-dim:     rgba(240, 231, 218, 0.45);
  --gold:        #d4a85c;
  --gold-light:  #e8c87a;
  --copper:      #c27a4a;
  --rust:        #b85c3a;
  --teal:        #4a9e8e;
  --teal-light:  #6ab8a8;
  --cream:       #f5eddc;
  --map-line:    rgba(212, 168, 92, 0.18);

  --font:   'Noto Sans SC', sans-serif;
  --serif:  'Noto Serif SC', serif;
  --mono:   'DM Mono', monospace;
}

* { box-sizing: border-box; }

html {
  background: var(--paper);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100dvh;
  background:
    radial-gradient(ellipse at 15% 12%, rgba(212, 168, 92, 0.08), transparent 38%),
    radial-gradient(ellipse at 85% 20%, rgba(74, 158, 142, 0.06), transparent 35%),
    radial-gradient(ellipse at 50% 88%, rgba(196, 122, 74, 0.07), transparent 40%),
    linear-gradient(165deg, var(--paper), var(--paper2));
  color: var(--ink);
  font-family: var(--font);
  line-height: 1.65;
  overflow-x: hidden;
}

/* ===== Parchment texture overlay ===== */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    repeating-linear-gradient(0deg, transparent, transparent 120px, rgba(200,170,130,0.015) 120px, rgba(200,170,130,0.015) 121px),
    repeating-linear-gradient(90deg, transparent, transparent 120px, rgba(200,170,130,0.015) 120px, rgba(200,170,130,0.015) 121px);
}

/* ===== Roadmap background pattern ===== */
body::after {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 18% 25%, rgba(212,168,92,0.06) 0, transparent 50%),
    radial-gradient(circle at 72% 40%, rgba(74,158,142,0.05) 0, transparent 45%),
    radial-gradient(circle at 45% 75%, rgba(196,122,74,0.04) 0, transparent 50%),
    url("data:image/svg+xml,%3Csvg viewBox='0 0 400 800' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M0 200 Q100 180 200 220 T400 280' stroke='rgba(212,168,92,0.04)' fill='none' stroke-width='2'/%3E%3Cpath d='M0 400 Q120 370 240 410 T400 460' stroke='rgba(212,168,92,0.035)' fill='none' stroke-width='1.5'/%3E%3Cpath d='M0 600 Q80 580 180 610 T400 650' stroke='rgba(212,168,92,0.03)' fill='none' stroke-width='1'/%3E%3C/svg%3E");
  background-size: auto, auto, auto, 400px 800px;
  background-repeat: repeat, repeat, repeat, repeat;
  opacity: 0.6;
}

/* ===== Shell ===== */
.wealth-shell {
  width: min(100%, 670px);
  margin: 0 auto;
  padding: 0 20px 64px;
}

.standalone-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 16px 0 10px;
  border-bottom: 1px solid var(--line);
  color: var(--ink-dim);
  font: 10px var(--mono);
  letter-spacing: .12em;
}
.standalone-head b { color: var(--gold); font-weight: 500; }

.hub-back {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  margin: 8px 0 14px;
  color: var(--ink-dim);
  font-size: 14px;
  text-decoration: none;
  transition: color 0.2s;
}
.hub-back:hover { color: var(--gold); }

/* ===== Screen system ===== */
.screen { display: none; }
.screen.active {
  display: block;
  animation: wealthEnter 0.45s ease;
}
@keyframes wealthEnter {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

/* ===== Gate Screen ===== */
.gate-mark {
  height: 160px;
  position: relative;
  margin: 6px 0 10px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(212,168,92,0.06), rgba(74,158,142,0.06));
  overflow: hidden;
}
/* Roadmap nodes */
.gate-mark .map-node {
  position: absolute;
  width: 10px; height: 10px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 12px rgba(212,168,92,0.3);
}
.gate-mark .map-node:nth-child(1) { left: 15%; top: 25%; }
.gate-mark .map-node:nth-child(2) { left: 45%; top: 38%; }
.gate-mark .map-node:nth-child(3) { left: 72%; top: 20%; }
.gate-mark .map-node:nth-child(4) { left: 30%; top: 62%; }
.gate-mark .map-node:nth-child(5) { left: 62%; top: 68%; }
.gate-mark .map-node:nth-child(6) { left: 85%; top: 52%; }

/* Connection lines */
.gate-mark svg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.gate-mark svg path {
  fill: none;
  stroke: var(--map-line);
  stroke-width: 1.5;
  stroke-dasharray: 4 6;
}

/* Chip tokens */
.gate-mark .chip {
  position: absolute;
  width: 30px; height: 30px;
  border-radius: 6px;
  border: 1.5px solid var(--copper);
  background: rgba(196,122,74,0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: var(--gold-light);
  transform: rotate(-8deg);
}
.gate-mark .chip:nth-child(8) { left: 10%; bottom: 28%; }
.gate-mark .chip:nth-child(9) { left: 55%; bottom: 12%; }
.gate-mark .chip:nth-child(10) { right: 12%; top: 45%; transform: rotate(5deg); }

/* Opportunity markers (diamonds) */
.gate-mark .opp {
  position: absolute;
  width: 14px; height: 14px;
  border: 1.5px solid var(--teal);
  background: rgba(74,158,142,0.08);
  transform: rotate(45deg);
}
.gate-mark .opp:nth-child(11) { left: 22%; top: 12%; }
.gate-mark .opp:nth-child(12) { right: 22%; bottom: 30%; }
.gate-mark .opp:nth-child(13) { left: 50%; top: 55%; }

/* Center emblem */
.gate-mark .emblem {
  position: absolute;
  z-index: 2;
  left: calc(50% - 24px);
  top: calc(50% - 24px);
  width: 48px; height: 48px;
  border: 2px solid var(--gold);
  border-radius: 50%;
  background: rgba(212,168,92,0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  color: var(--gold);
  box-shadow: 0 0 26px rgba(212,168,92,0.1);
}

.eyebrow {
  margin: 0 0 10px;
  color: var(--gold);
  font: 11px var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

h1, h2 {
  margin: 0;
  font-family: var(--serif);
  letter-spacing: 0.01em;
}
h1 { font-size: clamp(31px, 8vw, 45px); line-height: 1.25; }
h2 { font-size: clamp(27px, 7vw, 39px); line-height: 1.3; }

.lead {
  margin: 15px 0 18px;
  color: var(--ink-muted);
  font-size: 15px;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--line);
  border-radius: 14px;
  overflow: hidden;
  margin: 0 0 12px;
}
.metric-row div {
  text-align: center;
  padding: 11px 5px;
  border-right: 1px solid var(--line);
}
.metric-row div:last-child { border: 0; }
.metric-row b {
  display: block;
  color: var(--gold-light);
  font: 23px var(--mono);
}
.metric-row span {
  font-size: 11px;
  color: var(--ink-dim);
}

/* Keyword strip */
.keyword-strip {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px 10px;
  margin-bottom: 21px;
}
.keyword-strip span {
  font-size: 10px;
  color: var(--ink-dim);
  position: relative;
  padding-left: 10px;
}
.keyword-strip span::before {
  content: '';
  position: absolute;
  left: 0;
  top: 8px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--teal);
}

/* ===== Access / Gate Card ===== */
.access-card,
.question-card,
.result-card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--panel);
  box-shadow: 0 18px 50px rgba(0,0,0,0.2);
  backdrop-filter: blur(12px);
}
.access-card { padding: 18px; }

.access-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}
.access-head p {
  margin: 0 0 2px;
  color: var(--ink-dim);
  font-size: 12px;
}
.access-head b {
  font-family: var(--serif);
  font-size: 18px;
}
.access-head i {
  font: 20px var(--mono);
  color: var(--copper);
}

.notice {
  margin: 14px 0;
  padding: 11px 12px;
  border-left: 2px solid var(--gold);
  background: rgba(212,168,92,0.06);
}
.notice b { font-size: 13px; color: var(--gold); }
.notice p {
  margin: 3px 0 0;
  color: var(--ink-dim);
  font-size: 12px;
  line-height: 1.6;
}
.claim-panel { margin-top: 18px; }
.claim-divider { display: flex; align-items: center; gap: 10px; margin: 18px 0 10px; color: var(--ink-dim); font-size: 11px; }
.claim-divider::before, .claim-divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.claim-copy { margin: 0; color: var(--ink-muted); font-size: 12px; line-height: 1.62; }
.claim-result { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 9px; margin-top: 11px; padding: 10px; border: 1px solid rgba(212,168,92,.38); border-radius: 10px; background: rgba(212,168,92,.07); font-size: 12px; }
.claim-result span { color: var(--ink-dim); }
.claim-result b { color: var(--gold-light); font: 14px var(--mono); letter-spacing: .06em; }
.claim-result button { min-height: auto; padding: 0; border: 0; background: transparent; color: var(--ink); text-decoration: underline; }

label { display: block; margin-bottom: 7px; font-size: 13px; }
button, input { font: inherit; }
button { cursor: pointer; touch-action: manipulation; }

.access-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 9px;
}
.access-form input {
  min-width: 0;
  min-height: 48px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(0,0,0,0.2);
  color: var(--ink);
  padding: 0 12px;
  outline: none;
}
.access-form input:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(212,168,92,0.1);
}
.access-form button,
.primary-btn {
  min-height: 48px;
  border: 0;
  border-radius: 10px;
  padding: 0 16px;
  color: #1e1814;
  background: linear-gradient(135deg, var(--gold), var(--copper));
  font-weight: 700;
}

.message {
  min-height: 20px;
  margin: 10px 0 0;
  color: var(--teal-light);
  font-size: 13px;
}
.message.error { color: #e07a6a; }

.small-note {
  margin: 17px auto;
  color: var(--ink-dim);
  font-size: 11px;
  text-align: center;
  max-width: 440px;
}

/* ===== Quiz Screen ===== */
.quiz-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
  padding: 13px 0 9px;
}
.quiz-head p { margin: 0; color: var(--ink-dim); font-size: 13px; }
.quiz-head b {
  font: 17px var(--mono);
  color: var(--gold-light);
  white-space: nowrap;
}

.progress {
  height: 6px;
  border-radius: 99px;
  background: rgba(255,255,255,0.08);
  overflow: hidden;
}
.progress i {
  display: block;
  height: 100%;
  width: 4%;
  background: linear-gradient(90deg, var(--teal), var(--gold), var(--copper));
  transition: width 0.3s;
}

/* Roadmap progress markers */
.progress-track {
  display: flex;
  justify-content: space-between;
  margin-top: 4px;
}
.progress-track span {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
}
.progress-track span.done { background: var(--gold); }

/* Question card */
.question-card {
  padding: 24px 20px;
  margin-top: 10px;
}
.scene {
  margin: 0 0 8px;
  color: var(--copper);
  font: 11px var(--mono);
  letter-spacing: 0.1em;
}
.question-card h2 {
  font-size: 23px;
  min-height: 60px;
}

/* ===== Options ===== */
.option-list {
  display: grid;
  gap: 9px;
  margin-top: 17px;
}
.option {
  width: 100%;
  min-height: 56px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: rgba(240,231,218,0.03);
  padding: 11px 14px;
  color: var(--ink);
  text-align: left;
  transition: border-color 0.15s, background 0.15s;
}
.option:hover {
  border-color: var(--gold);
  background: rgba(212,168,92,0.07);
}
.option.pick {
  border-color: var(--teal);
  background: rgba(74,158,142,0.09);
}
.option b, .option span { display: block; }
.option b { font-size: 14px; }
.option span {
  margin-top: 2px;
  font-size: 12px;
  color: var(--ink-dim);
}

.quiz-actions,
.result-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.quiz-actions button,
.result-actions button:not(.primary-btn) {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255,255,255,0.03);
  color: var(--ink-muted);
  padding: 0 13px;
  font-size: 13px;
}
.quiz-actions button:disabled { opacity: 0.35; }

/* ===== Result Screen ===== */
.result-card {
  padding: 20px;
}
.file-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 9px;
  font: 10px var(--mono);
  letter-spacing: 0.1em;
  color: var(--ink-dim);
}
.file-head b { color: var(--copper); font-weight: 400; }

/* Result art – roadmap map with highlight */
.result-art {
  height: 140px;
  position: relative;
  margin: 12px 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(212,168,92,0.04), rgba(74,158,142,0.04));
  overflow: hidden;
}
.result-art svg {
  position: absolute;
  inset: 8px;
  width: calc(100% - 16px);
  height: calc(100% - 16px);
}
.result-art svg .route-line {
  fill: none;
  stroke: var(--map-line);
  stroke-width: 1.5;
  stroke-dasharray: 3 5;
}
.result-art svg .route-highlight {
  fill: none;
  stroke: var(--gold);
  stroke-width: 2;
  stroke-dasharray: 3 5;
  stroke-dashoffset: 0;
}
.result-art .rp {
  position: absolute;
  width: 8px; height: 8px;
  border-radius: 50%;
}
.result-art .rp-gold { background: var(--gold); box-shadow: 0 0 10px rgba(212,168,92,0.3); }
.result-art .rp-teal { background: var(--teal); box-shadow: 0 0 10px rgba(74,158,142,0.2); }

.result-sub {
  margin: 8px 0 12px;
  color: var(--ink-muted);
  font-size: 15px;
}

.tag-list {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.tag-list span {
  padding: 3px 9px;
  border: 1px solid var(--line);
  border-radius: 99px;
  color: var(--gold);
  font-size: 11px;
}

/* ===== Result detail sections ===== */
.result-section {
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 14px;
}
.score-list{display:grid;gap:8px}.score-list > div{display:grid;grid-template-columns:1fr 2fr auto;gap:8px;align-items:center;padding:5px 0;border-bottom:1px solid rgba(200,170,130,0.08)}.score-list span{font-size:12px;color:var(--ink-dim);white-space:nowrap}.score-bar{height:14px;border-radius:99px;background:rgba(255,255,255,0.06);overflow:hidden}.score-bar i{display:block;height:100%;border-radius:99px;background:linear-gradient(90deg,var(--teal),var(--gold));transition:width 0.4s}.score-list b{font:14px var(--mono);color:var(--gold-light);text-align:right}

.result-section h3 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-size: 19px;
  color: var(--gold-light);
}
.section-head {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}
.section-head b { font-family: var(--serif); }
.section-head span { font: 10px var(--mono); color: var(--ink-dim); }

/* Result detail grid */
.detail-grid {
  display: grid;
  gap: 9px;
}
.detail-grid > div {
  padding: 10px 12px;
  border-left: 2px solid var(--gold);
  background: rgba(240,231,218,0.03);
}
.detail-grid > div h4 {
  margin: 0 0 3px;
  font-size: 13px;
  color: var(--gold);
}
.detail-grid > div p {
  margin: 0;
  color: var(--ink-muted);
  font-size: 13px;
  line-height: 1.65;
}

/* ===== Quote block ===== */
.quote-block {
  margin: 18px 0 0;
  padding: 16px 12px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  text-align: center;
}
.quote-block p {
  margin: 0;
  font-family: var(--serif);
  font-size: 20px;
  color: var(--copper);
  line-height: 1.5;
}
.quote-block small {
  display: block;
  margin-top: 6px;
  font: 10px var(--mono);
  color: var(--ink-dim);
  letter-spacing: 0.08em;
}

.result-footer {
  margin-top: 15px;
  color: var(--ink-dim);
  font: 10px var(--mono);
  letter-spacing: 0.06em;
}

.result-actions button {
  flex: 1;
  min-width: 140px;
}

.center { text-align: center; }

/* ===== Responsive ===== */
@media (max-width: 390px) {
  .wealth-shell {
    padding-left: 14px;
    padding-right: 14px;
  }
  .standalone-head { padding-top: 12px; }
  .claim-result { grid-template-columns: 1fr; }
  .access-form {
    grid-template-columns: 1fr;
  }
  .access-form button { width: 100%; }
  .result-actions button { min-width: 100%; }
  .question-card h2 { font-size: 20px; }
}

/* ===== Smooth scrollbar ===== */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--paper); }
::-webkit-scrollbar-thumb { background: rgba(212,168,92,0.15); border-radius: 99px; }
::-webkit-scrollbar-thumb:hover { background: rgba(212,168,92,0.25); }
