/* PLAY Concierge H5 — mobile-first */
:root {
  --bg: #F7EFE6;
  --bg-card: #FFFBF7;
  --ink: #3D2F28;
  --ink-soft: #6B564C;
  --muted: #9A8478;
  --line: #E8D9CC;
  --accent: #C4785A;
  --accent-dark: #A85E42;
  --accent-soft: #F3E0D6;
  --safe: #5A7A62;
  --safe-bg: #E8F0EA;
  --radius: 16px;
  --tap: 48px;
  --shadow: 0 8px 24px rgba(61, 47, 40, 0.08);
  font-family: "PingFang SC", "Hiragino Sans GB", "Noto Sans SC",
    "Microsoft YaHei", system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: #EDE4DA;
  color: var(--ink);
  -webkit-tap-highlight-color: transparent;
}

body {
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 16px 0 24px;
  background:
    radial-gradient(ellipse at top, #f3e8dc 0%, #EDE4DA 55%, #e0d4c8 100%);
}

.phone-shell {
  width: 100%;
  max-width: 390px;
  border-radius: 28px;
  background: #2a211c;
  padding: 10px;
  box-shadow:
    0 0 0 1px rgba(0,0,0,0.08),
    0 18px 40px rgba(61, 47, 40, 0.22);
}

.phone-shell::before {
  content: "";
  display: block;
  width: 96px;
  height: 5px;
  margin: 4px auto 8px;
  border-radius: 999px;
  background: #4a3c34;
}

.app {
  width: 100%;
  max-width: 420px;
  min-height: min(720px, calc(100dvh - 48px));
  background: var(--bg);
  padding: 18px 16px 24px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  border-radius: 20px;
  overflow: hidden;
}

@media (max-width: 440px) {
  body { padding: 0; background: var(--bg); }
  .phone-shell {
    max-width: none;
    border-radius: 0;
    padding: 0;
    box-shadow: none;
    background: transparent;
  }
  .phone-shell::before { display: none; }
  .app {
    min-height: 100dvh;
    border-radius: 0;
    max-width: none;
  }
}

.topbar { margin-bottom: 4px; }

.brand {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.brand-mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  background: var(--accent-soft);
  color: var(--accent-dark);
  display: grid;
  place-items: center;
  font-size: 18px;
  flex-shrink: 0;
}

.brand h1 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.subtitle {
  margin: 2px 0 0;
  font-size: 0.8rem;
  color: var(--muted);
}

.view[hidden] { display: none !important; }
.view { animation: fadeIn 0.22s ease; }

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: none; }
}

.lead {
  margin: 0 0 6px;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink-soft);
}

.field { margin: 12px 0; }

.field-label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--ink-soft);
  margin-bottom: 8px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  min-height: var(--tap);
  padding: 0 14px;
  border-radius: 999px;
  border: 1.5px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 0.92rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

.chip:active { transform: scale(0.98); }

.chip.selected {
  background: var(--accent-soft);
  border-color: var(--accent);
  color: var(--accent-dark);
  font-weight: 600;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  width: 100%;
  padding: 0 18px;
  border-radius: 14px;
  border: none;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: opacity 0.15s, transform 0.1s;
}

.btn:active { transform: scale(0.985); }
.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.btn-primary {
  background: var(--accent);
  color: #fff;
  margin-top: 10px;
  box-shadow: 0 6px 16px rgba(196, 120, 90, 0.28);
}

.btn-primary:hover { background: var(--accent-dark); }

.btn-secondary {
  background: #fff;
  color: var(--ink);
  border: 1.5px solid var(--line);
}

.btn-ghost {
  background: transparent;
  color: var(--ink-soft);
  border: 1.5px dashed var(--line);
}

.actions-row {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}

.actions-row.twin .btn { flex: 1; margin-top: 0; }

.match-explain {
  margin: 0;
  font-size: 0.82rem;
  color: var(--muted);
  background: rgba(255,255,255,0.6);
  border-radius: 10px;
  padding: 8px 12px;
}

.card {
  background: var(--bg-card);
  border-radius: var(--radius);
  padding: 18px 16px 16px;
  box-shadow: var(--shadow);
  border: 1px solid rgba(232, 217, 204, 0.8);
}

.card-badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--accent-dark);
  background: var(--accent-soft);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}

.card-title {
  margin: 0 0 14px;
  font-size: 1.25rem;
  line-height: 1.35;
  font-weight: 700;
}

.card-block { margin-top: 14px; }

.card-block h3 {
  margin: 0 0 8px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-transform: none;
}

.why-list, .steps {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--ink);
  line-height: 1.55;
  font-size: 0.95rem;
}

.why-list li, .steps li { margin-bottom: 6px; }

.card-block.safety {
  background: var(--safe-bg);
  border-radius: 12px;
  padding: 12px;
  margin-top: 16px;
}

.card-block.safety h3 { color: var(--safe); }
.card-block.safety p {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--ink);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.tag {
  font-size: 0.72rem;
  padding: 3px 8px;
  border-radius: 6px;
  background: rgba(90, 122, 98, 0.15);
  color: var(--safe);
  font-weight: 600;
}

.thanks-box {
  text-align: center;
  padding: 36px 12px 20px;
}

.thanks-emoji { font-size: 2.4rem; margin-bottom: 8px; }

.thanks-box h2 {
  margin: 0 0 8px;
  font-size: 1.3rem;
}

.thanks-box p {
  margin: 0 0 24px;
  color: var(--ink-soft);
  line-height: 1.55;
  font-size: 0.95rem;
}

.footer {
  margin-top: auto;
  padding-top: 18px;
  text-align: center;
  font-size: 0.72rem;
  color: var(--muted);
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 28px;
  transform: translateX(-50%);
  background: var(--ink);
  color: #fff;
  padding: 10px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  z-index: 50;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  max-width: 90vw;
}

.toast.show { opacity: 1; }


.card-meta {
  margin: -6px 0 10px;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.4;
}

.tags.soft { margin-bottom: 4px; }
.tags.soft .tag {
  background: rgba(196, 120, 90, 0.12);
  color: var(--accent-dark);
  font-weight: 500;
}

.why-text {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink);
}

.card-block.tip {
  background: #F8F1E8;
  border-radius: 12px;
  padding: 12px;
  border: 1px dashed var(--line);
}

.card-block.tip h3 { color: var(--accent-dark); }
.card-block.tip p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
}

.safety-list {
  margin: 0;
  padding-left: 1.15rem;
  font-size: 0.92rem;
  line-height: 1.5;
}

.safety-list li { margin-bottom: 6px; }

.card-block.subtle h3 { color: var(--muted); }
.card-block.subtle p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--ink-soft);
  line-height: 1.45;
}


/* PLA-2 §3 result blocks */
.ctx-bind-line {
  margin: 0 0 8px;
  font-size: 0.82rem;
  color: var(--muted);
  line-height: 1.45;
  background: rgba(255,255,255,0.7);
  border-radius: 8px;
  padding: 6px 10px;
}

.age-basis-text {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--ink);
}

.prep-line {
  margin: 0 0 8px;
  font-size: 0.82rem;
  color: var(--muted);
}

.card-block.materials .materials-line {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.5;
  color: var(--ink);
}

.card-block.materials .zero-alt {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--line);
}

.card-block.materials .zero-alt h4 {
  margin: 0 0 6px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--accent-dark);
}

.card-block.materials .zero-alt p {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--ink);
}

.source-badge {
  margin-top: 16px;
  margin-bottom: 0;
}

.card-block.adapt p {
  margin: 0 0 6px;
  font-size: 0.85rem;
  color: var(--ink-soft);
  line-height: 1.45;
}

.card-block.adapt p:last-child { margin-bottom: 0; }

