@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700&family=Nunito:wght@600;700;800&display=swap');

:root {
  --bg: #f7f3ee;
  --surface: #fffdf9;
  --text: #2d2723;
  --muted: #6f665f;
  --sage: #7aa497;
  --rose: #d3a089;
  --gold: #c6a96a;
  --violet: #6b5b7b;
  --line: #e1d7c9;
  --shadow: 0 12px 30px rgba(45, 39, 35, 0.08);
  --radius: 18px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: 'Outfit', sans-serif;
  background: radial-gradient(circle at top, #fff8ef 0%, var(--bg) 45%, #efe7dd 100%);
  color: var(--text);
  min-height: 100vh;
}

.app {
  max-width: 430px;
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, #faf6f0 0%, #f5efe6 100%);
}

.app-header {
  padding: 24px 20px 8px;
}

.brand__chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sage);
  border: 1px solid rgba(132, 169, 140, 0.3);
  background: white;
  padding: 6px 12px;
  border-radius: 999px;
}

.brand__chip--btn {
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 16px rgba(132, 169, 140, 0.15);
  border: 1px solid rgba(132, 169, 140, 0.4);
}

.brand__chip--btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 20px rgba(132, 169, 140, 0.2);
}

.brand__chip--btn:active {
  transform: translateY(1px) scale(0.98);
}

.brand__title {
  font-family: 'Nunito', sans-serif;
  font-size: 28px;
  margin: 14px 0 6px;
}

.brand__subtitle {
  color: var(--muted);
  margin: 0;
}

.app-main {
  padding: 0 20px 24px;
  flex: 1;
}

.app-footer {
  padding: 16px 20px 24px;
  font-size: 12px;
  color: var(--muted);
  border-top: 1px solid var(--line);
}

.view { display: none; }
.view--active { display: block; }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  margin-bottom: 16px;
  position: relative;
  overflow: hidden;
}

.card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--sage), var(--rose), var(--gold));
  opacity: 0.7;
}

.hero {
  display: grid;
  gap: 16px;
}

.hero__badge {
  font-size: 12px;
  font-weight: 700;
  color: var(--violet);
  letter-spacing: 0.06em;
}

.hero__title {
  font-family: 'Nunito', sans-serif;
  font-size: 22px;
  margin: 0;
}

.hero__copy {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
}

.hero__meta {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}

.hero__notice {
  font-size: 12px;
  color: var(--muted);
  margin: 0;
}

.identity {
  text-align: center;
  font-style: italic;
  color: var(--muted);
}

.btn {
  border: none;
  border-radius: 999px;
  padding: 12px 18px;
  font-weight: 600;
  cursor: pointer;
  font-family: 'Outfit', sans-serif;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.btn--primary {
  background: linear-gradient(135deg, var(--sage), #5f8f7f);
  color: white;
  box-shadow: 0 10px 18px rgba(122, 164, 151, 0.25);
}

.btn--accent {
  background: linear-gradient(135deg, #7a3f2f, #5e2e23);
  color: #ffffff;
  box-shadow: 0 10px 18px rgba(94, 46, 35, 0.35);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
  color: var(--text);
  backdrop-filter: blur(6px);
}

.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.test-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px;
  margin-bottom: 12px;
}

.step-indicator {
  font-size: 13px;
  background: white;
  border: 1px solid var(--line);
  padding: 6px 12px;
  border-radius: 999px;
}

.progress {
  height: 10px;
  background: #efe9df;
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 16px;
}

.progress__bar {
  height: 100%;
  background: linear-gradient(90deg, var(--sage), var(--rose));
  width: 0;
  transition: width 0.3s ease;
}

.question-list {
  display: grid;
  gap: 14px;
}

.question {
  background: white;
  border-radius: 16px;
  border: 1px solid var(--line);
  padding: 16px;
}

.question h4 {
  margin: 0 0 12px;
  font-size: 16px;
}

.options {
  display: grid;
  gap: 8px;
}

.option {
  border: 1px solid transparent;
  background: #f7f4ee;
  padding: 10px 12px;
  border-radius: 12px;
  cursor: pointer;
  text-align: left;
}

.option.selected {
  border-color: var(--sage);
  background: rgba(132, 169, 140, 0.16);
  font-weight: 600;
}

.test-actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
  flex-wrap: wrap;
}

.test-actions .btn {
  flex: 1 1 140px;
  min-width: 140px;
  height: 48px;
}

.small { font-size: 12px; }
.muted { color: var(--muted); }

.result-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 12px;
  padding: 0 6px;
}

.result-theme {
  background: radial-gradient(circle at top, rgba(132, 169, 140, 0.08), transparent 60%);
  border-radius: 20px;
  padding: 8px 0;
}

.result-theme .card {
  background: #ffffff;
  border: 1px solid #efe6dc;
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.05);
}

.result-theme .result-header h2 {
  color: var(--text);
}

.result-theme .pill {
  background: rgba(132, 169, 140, 0.12);
  color: var(--sage);
  border: 1px solid rgba(132, 169, 140, 0.3);
}

.result-hero {
  display: grid;
  gap: 16px;
  align-items: center;
  text-align: center;
}

.pill {
  font-size: 12px;
  font-weight: 700;
  color: var(--sage);
  background: rgba(132, 169, 140, 0.12);
  padding: 6px 12px;
  border-radius: 999px;
  display: inline-flex;
}

.result-code {
  font-size: 48px;
  margin: 10px 0 4px;
  font-family: 'Nunito', sans-serif;
  color: var(--text);
}

.result-name { font-weight: 700; color: var(--muted); }

.result-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
  justify-content: center;
}

.result-tags span {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 10px;
  background: #f2efe8;
  color: var(--gold);
}

.result-summary { color: var(--muted); }

.result-notes { font-size: 13px; color: var(--muted); }

.radar-card {
  background: radial-gradient(circle, #ffffff 0%, #fbf7f0 100%);
  border: 1px solid #efe6dc;
  border-radius: 20px;
  padding: 16px;
  display: grid;
  place-items: center;
  position: relative;
  overflow: hidden;
}

.radar-poly {
  fill: rgba(132, 169, 140, 0.18);
  stroke: #7aa497;
  stroke-width: 1.6;
  filter: drop-shadow(0 0 10px rgba(122, 164, 151, 0.25));
}

.radar-grid { stroke: rgba(225, 215, 201, 0.75); stroke-width: 0.6; fill: none; }
.radar-axis { stroke: rgba(225, 215, 201, 0.6); stroke-width: 0.5; }
.radar-label { font-size: 7.5px; font-weight: 600; fill: #8d8277; text-anchor: middle; letter-spacing: 0.06em; }

.radar-card::before {
  content: "";
  position: absolute;
  inset: 16%;
  background: radial-gradient(circle, rgba(132, 169, 140, 0.18), transparent 65%);
  filter: blur(22px);
  border-radius: 50%;
}

.radar-card::after {
  content: "";
  position: absolute;
  inset: 30%;
  background: radial-gradient(circle, rgba(255, 255, 255, 0.75), transparent 70%);
  filter: blur(12px);
  border-radius: 50%;
  mix-blend-mode: screen;
}

.result-theme .system-card {
  background: #ffffff;
  border: 1px solid #efe6dc;
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.04);
}

.result-theme .system-card__badge {
  background: rgba(132, 169, 140, 0.12);
  color: var(--sage);
}

.result-theme .system-card__body {
  background: #fbf9f4;
}

.card-grid {
  display: grid;
  gap: 12px;
}

.system-card {
  background: white;
  border-radius: 14px;
  border: 1px solid #efe6dc;
  overflow: hidden;
  position: relative;
}

.system-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #84a98c, #d8a48f, #cbb26a);
  opacity: 0.6;
}

.system-card__head {
  padding: 14px;
  display: grid;
  gap: 6px;
}

.system-card__badge {
  font-size: 10px;
  font-weight: 700;
  color: var(--sage);
  background: rgba(132, 169, 140, 0.12);
  padding: 4px 8px;
  border-radius: 999px;
  display: inline-block;
}

.system-card__body {
  padding: 12px 14px;
  background: #fbf9f4;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--muted);
}

.note {
  background: #f7f3eb;
  border-style: dashed;
}

.share-row {
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (min-width: 900px) {
  .app { max-width: 540px; }
  .hero__title { font-size: 26px; }
}
