:root {
  --bg: #fbf8f1;
  --paper: #ffffff;
  --paper-soft: #fffaf0;
  --ink: #25313b;
  --muted: #66737f;
  --line: #eadfcf;
  --brand: #f17a22;
  --brand-dark: #c85e12;
  --brand-soft: #fde7d3;
  --accent: #f5b14c;
  --accent-soft: #fff0d8;
  --rose: #f6d8d5;
  --blue: #dbeafb;
  --green: #dff4df;
  --shadow: 0 24px 70px rgba(60, 47, 33, 0.13);
  --shadow-soft: 0 18px 45px rgba(60, 47, 33, 0.08);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 16px;
  --max: 1120px;
  color-scheme: light;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family:
    "Hiragino Sans",
    "Yu Gothic UI",
    "Yu Gothic",
    "Noto Sans JP",
    system-ui,
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.75;
  overflow-x: hidden;
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  color: inherit;
  text-decoration: none;
}

.site-bg {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
}

.blob {
  position: absolute;
  display: block;
  width: 360px;
  height: 360px;
  border-radius: 999px;
  filter: blur(6px);
  opacity: 0.72;
}

.blob-a {
  background: var(--brand-soft);
  top: -90px;
  right: -100px;
}
.blob-b {
  background: var(--accent-soft);
  bottom: 5%;
  left: -160px;
}
.blob-c {
  background: var(--blue);
  top: 32%;
  right: 12%;
  width: 190px;
  height: 190px;
  opacity: 0.5;
}

.site-header {
  width: min(var(--max), calc(100% - 40px));
  margin: 22px auto 0;
  display: flex;
  align-items: center;
  justify-content: right;
  gap: 16px;
  position: relative;
  z-index: 10;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, var(--brand), var(--brand-dark));
  box-shadow: 0 12px 28px rgba(241, 122, 34, 0.25);
}

.brand small {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
  line-height: 1.1;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.screen {
  width: min(var(--max), calc(100% - 40px));
  margin: 38px auto 72px;
  display: none;
}

.screen-active {
  display: block;
  animation: fadeIn 0.35s ease both;
}

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

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.95fr);
  gap: 36px;
  align-items: center;
  min-height: 540px;
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--brand-dark);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 13px;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(36px, 5vw, 60px);
  line-height: 1.08;
  letter-spacing: -0.05em;
}

h2 {
  line-height: 1.35;
  letter-spacing: -0.02em;
}

.lead {
  color: var(--muted);
  font-size: clamp(16px, 2vw, 19px);
  max-width: 760px;
}

.note {
  margin-top: 18px;
  color: var(--muted);
  font-size: 13px;
  max-width: 720px;
}

.hero-actions,
.center-actions,
.cta-actions,
.quiz-nav {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

.primary-button,
.secondary-button,
.ghost-button {
  border: 0;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  font-weight: 800;
  min-height: 48px;
  padding: 12px 22px;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    background 0.2s ease,
    opacity 0.2s ease;
}

.primary-button {
  background: var(--brand);
  color: #fff;
  box-shadow: 0 16px 34px rgba(241, 122, 34, 0.22);
}

.primary-button:hover,
.secondary-button:hover,
.ghost-button:hover {
  transform: translateY(-2px);
}

.primary-button:disabled {
  opacity: 0.42;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.secondary-button {
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}

.ghost-button {
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  border: 1px solid rgba(234, 223, 207, 0.72);
  min-height: 42px;
  padding: 9px 16px;
}

.large {
  min-height: 56px;
  padding-inline: 26px;
}

.hero-card {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.86);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow);
  min-height: 460px;
  overflow: hidden;
}

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

.feature-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 36px;
}

.feature-row article,
.result-card,
.score-card,
.cta-card,
.question-card,
.types-grid article {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
}

.feature-row article {
  padding: 24px;
}
.feature-row span {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-weight: 900;
  margin-bottom: 14px;
}
.feature-row h2 {
  font-size: 20px;
  margin-bottom: 8px;
}
.feature-row p {
  color: var(--muted);
  margin-bottom: 0;
}

.quiz-shell,
.result-shell,
.types-shell {
  max-width: 920px;
  margin: 0 auto;
}

.quiz-top {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: end;
  margin-bottom: 18px;
}

.quiz-top h1 {
  font-size: clamp(30px, 5vw, 52px);
  margin-bottom: 0;
}
.counter {
  min-width: 92px;
  padding: 10px 16px;
  border-radius: 999px;
  background: #fff;
  border: 1px solid var(--line);
  text-align: center;
  font-weight: 900;
  color: var(--brand-dark);
}

.progress-wrap {
  margin-bottom: 18px;
}
.progress-bar {
  width: 100%;
  height: 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
  overflow: hidden;
}
.progress-bar span {
  display: block;
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--brand), var(--accent));
  border-radius: inherit;
  transition: width 0.25s ease;
}

.question-card {
  padding: clamp(24px, 5vw, 44px);
  min-height: 360px;
}

.question-tag {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 4px 12px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 900;
  margin-bottom: 20px;
}

.question-card h2 {
  font-size: clamp(25px, 4.2vw, 40px);
  margin-bottom: 34px;
}

.answer-help {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  margin-bottom: 8px;
}

.answer-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}

.answer-grid button {
  border: 2px solid var(--line);
  border-radius: 22px;
  background: #fff;
  cursor: pointer;
  min-height: 112px;
  padding: 14px 8px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: var(--muted);
  transition:
    transform 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease,
    box-shadow 0.18s ease;
}

.answer-grid button:hover {
  transform: translateY(-2px);
  border-color: var(--brand);
}
.answer-grid button.is-selected {
  background: var(--brand-soft);
  border-color: var(--brand);
  color: var(--brand-dark);
  box-shadow: 0 16px 30px rgba(241, 122, 34, 0.14);
}
.answer-grid span {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: var(--paper-soft);
  color: var(--ink);
  font-weight: 900;
}
.answer-grid small {
  font-weight: 800;
  line-height: 1.35;
}

.quiz-nav {
  justify-content: space-between;
  margin-top: 20px;
}

.result-hero {
  text-align: center;
  padding: 18px 0 28px;
}
.result-avatar {
  width: 45%;
  height: auto;
  margin: 0 auto 14px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--paper-soft);
  border: 4px solid #fff;
  box-shadow: var(--shadow);
}
.result-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.result-hero h1 {
  font-size: clamp(34px, 6vw, 66px);
}
.result-hero h1 span {
  color: var(--brand-dark);
}
.result-hero .lead {
  margin-inline: auto;
}
.result-hero .note {
  margin-inline: auto;
}
.share-actions {
  display: flex;
  justify-content: center;
  margin-top: 16px;
}
.share-actions .ghost-button {
  background: #000;
  color: #fff;
  border-color: #000;
}

.result-badges {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 18px;
}
.result-badges span {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 5px 13px;
  border-radius: 999px;
  font-weight: 900;
  background: #fff;
  border: 1px solid var(--line);
}

.result-layout {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.result-card {
  padding: clamp(22px, 4vw, 30px);
}
.main-result {
  grid-column: 1 / -1;
}
.result-card h2 {
  font-size: 22px;
  margin-bottom: 12px;
}
.result-card p {
  color: var(--muted);
  margin-bottom: 0;
}
ul {
  margin: 0;
  padding: 0;
  list-style: none;
}
.result-card li,
.types-grid li {
  position: relative;
  padding-left: 1.35em;
  color: var(--muted);
  margin-bottom: 8px;
}
.result-card li::before,
.types-grid li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.75em;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: var(--accent);
}

.score-card {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(320px, 1.15fr);
  gap: 26px;
  padding: clamp(22px, 4vw, 30px);
  margin-top: 18px;
  align-items: center;
}
.score-card p {
  color: var(--muted);
  margin-bottom: 0;
}
.score-bars {
  display: grid;
  gap: 14px;
}
.score-row {
  display: grid;
  gap: 6px;
}
.score-label {
  display: flex;
  justify-content: space-between;
  font-weight: 900;
  font-size: 13px;
  color: var(--muted);
}
.score-track {
  height: 12px;
  border-radius: 999px;
  background: var(--paper-soft);
  border: 1px solid var(--line);
  overflow: hidden;
}
.score-track span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--brand);
}

.cta-card {
  margin-top: 18px;
  padding: clamp(24px, 5vw, 36px);
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: center;
  background: var(--ink);
  color: #fff;
}
.cta-card p {
  color: rgba(255, 255, 255, 0.76);
  margin-bottom: 0;
}
.cta-card .secondary-button {
  background: rgba(132 132 132);
  color: #fff;
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: none;
}

.section-head {
  text-align: center;
  max-width: 780px;
  margin: 0 auto 26px;
}
.section-head h1 {
  font-size: clamp(34px, 5.8vw, 62px);
}
.section-head p {
  color: var(--muted);
}
.types-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.types-grid article {
  padding: 24px;
  position: relative;
  overflow: hidden;
}
.type-avatar {
  width: 100%;
  height: auto;
  text-align: center;
  border-radius: 18px;
  overflow: hidden;
  background: var(--paper-soft);
  box-shadow: var(--shadow-soft);
  margin-bottom: 14px;
}
.type-avatar img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.types-grid h2 {
  font-size: 22px;
  margin-bottom: 8px;
  position: relative;
  z-index: 1;
}
.types-grid p {
  color: var(--muted);
  position: relative;
  z-index: 1;
}
.types-grid ul {
  position: relative;
  z-index: 1;
}
.center-actions {
  justify-content: center;
  margin-top: 28px;
}

.about-dialog {
  width: min(620px, calc(100% - 32px));
  padding: 0;
  border: 0;
  border-radius: 28px;
  box-shadow: var(--shadow);
  background: transparent;
}
.about-dialog::backdrop {
  background: rgba(37, 49, 59, 0.35);
  backdrop-filter: blur(3px);
}
.dialog-inner {
  position: relative;
  background: #fff;
  padding: 34px;
  border-radius: 28px;
}
.dialog-inner p {
  color: var(--muted);
}
.close-button {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 42px;
  height: 42px;
  border: 0;
  border-radius: 999px;
  background: var(--paper-soft);
  color: var(--ink);
  cursor: pointer;
  font-size: 26px;
  line-height: 1;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    min-height: unset;
  }
  .hero-card {
    min-height: 420px;
  }
  .feature-row {
    grid-template-columns: 1fr;
  }
  .score-card {
    grid-template-columns: 1fr;
  }
  .cta-card {
    display: grid;
  }
}

@media (max-width: 720px) {
  .site-header {
    width: min(100% - 28px, var(--max));
    margin-top: 14px;
  }
  .brand small {
    display: none;
  }
  .header-actions .ghost-button {
    display: none;
  }
  .result-avatar {
    width: 80%;
  }
  .hero-grid {
    gap: 0;
  }
  .hero-copy {
    display: contents;
  }
  .hero-copy .eyebrow {
    order: 1;
  }
  .hero-copy h1 {
    order: 2;
  }
  .hero-copy .lead {
    order: 3;
  }
  .hero-card {
    order: 4;
    margin-bottom: 20px;
  }
  .hero-copy .hero-actions {
    order: 5;
  }
  .hero-copy .note {
    order: 6;
  }
  .screen {
    width: min(100% - 28px, var(--max));
    margin-top: 28px;
  }
  h1 {
    letter-spacing: -0.04em;
  }
  .hero-actions,
  .center-actions,
  .cta-actions {
    display: grid;
    grid-template-columns: 1fr;
  }
  .hero-actions > *,
  .center-actions > *,
  .cta-actions > * {
    width: 100%;
  }
  .answer-grid {
    display: flex;
    flex-direction: column-reverse;
  }
  .answer-help {
    display: none;
  }
  .answer-grid button {
    min-height: 68px;
    grid-template-columns: 44px 1fr;
    justify-items: start;
    text-align: left;
    padding-inline: 16px;
  }
  .quiz-top {
    align-items: start;
  }
  .counter {
    min-width: 74px;
  }
  .result-layout,
  .types-grid {
    grid-template-columns: 1fr;
  }
}
