* {
  box-sizing: border-box;
}

:root {
  color-scheme: light;
  --bg: #f5eddf;
  --cream: #fff9eb;
  --paper: rgba(255, 252, 242, 0.84);
  --paper-solid: #fffaf0;
  --ink: #10231b;
  --muted: #657267;
  --line: rgba(21, 36, 29, 0.13);
  --green: #174d36;
  --green-2: #2a7650;
  --sage: #9fbea2;
  --gold: #d9b56f;
  --gold-2: #b88e3d;
  --blue: #8ab5bd;
  --shadow: 0 30px 120px rgba(43, 36, 24, 0.14);
  --soft-shadow: 0 16px 50px rgba(43, 36, 24, 0.1);
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(120deg, rgba(255, 250, 235, 0.9), rgba(243, 232, 211, 0.76)),
    var(--bg);
  font-family:
    -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN",
    "Yu Gothic", "YuGothic", "Noto Sans JP", sans-serif;
  line-height: 1.75;
  overflow-x: hidden;
}

button,
textarea {
  font: inherit;
}

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

.bg-noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -4;
  opacity: 0.16;
  background-image:
    radial-gradient(rgba(21, 36, 29, 0.2) 0.55px, transparent 0.55px);
  background-size: 18px 18px;
  mix-blend-mode: multiply;
}

.light {
  position: fixed;
  pointer-events: none;
  z-index: -3;
  border-radius: 999px;
  filter: blur(8px);
}

.light-a {
  width: 720px;
  height: 720px;
  left: -260px;
  top: -260px;
  background: radial-gradient(circle, rgba(159, 190, 162, 0.38), transparent 68%);
}

.light-b {
  width: 720px;
  height: 720px;
  right: -260px;
  top: 100px;
  background: radial-gradient(circle, rgba(217, 181, 111, 0.34), transparent 66%);
}

.light-c {
  width: 560px;
  height: 560px;
  left: 34%;
  bottom: -260px;
  background: radial-gradient(circle, rgba(138, 181, 189, 0.20), transparent 70%);
}

.app-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 54px 0 78px;
}

.hero-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.94fr) minmax(390px, 0.94fr);
  gap: clamp(32px, 5vw, 68px);
  align-items: center;
  min-height: 720px;
}

.top-labels {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}

.brand-pill,
.pre-title,
.question-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--green);
  font-size: 0.84rem;
  font-weight: 850;
  letter-spacing: 0.08em;
}

.brand-pill {
  padding: 8px 15px;
  border: 1px solid rgba(23, 77, 54, 0.14);
  border-radius: 999px;
  background: rgba(255, 250, 235, 0.78);
  box-shadow: var(--soft-shadow);
}

.brand-pill span {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--green), var(--sage));
  box-shadow: 0 0 0 6px rgba(23, 77, 54, 0.08);
}

.pre-title {
  margin: 0;
}

.hero-title-image {
  display: block;
  width: min(100%, 620px);
  margin: 0;
}

.hero-title-image img {
  display: block;
  width: 100%;
  height: auto;
}

.lead {
  max-width: 620px;
  margin: 22px 0 0;
  color: #314238;
  font-size: clamp(1.02rem, 1.7vw, 1.18rem);
  line-height: 2.05;
  letter-spacing: 0.02em;
}

.promise-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
  max-width: 600px;
  margin-top: 30px;
}

.promise-card {
  min-height: 96px;
  padding: 17px 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 250, 235, 0.72);
  box-shadow: 0 14px 40px rgba(43, 36, 24, 0.08);
  backdrop-filter: blur(16px);
}

.promise-icon {
  width: 28px;
  height: 28px;
  margin-bottom: 8px;
  opacity: 0.95;
}

.clock-icon {
  border: 2px solid var(--green);
  border-radius: 999px;
  position: relative;
}

.clock-icon::before,
.clock-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  background: var(--green);
  transform-origin: left center;
}

.clock-icon::before {
  width: 8px;
  height: 2px;
  transform: translateY(-50%) rotate(0deg);
}

.clock-icon::after {
  width: 2px;
  height: 9px;
  transform: translate(-50%, -100%);
}

.leaf-icon {
  border: 2px solid var(--green);
  border-radius: 100% 0 100% 0;
  transform: rotate(-18deg);
}

.shield-icon {
  position: relative;
  border: 2px solid var(--green);
  border-radius: 15px 15px 18px 18px;
}

.shield-icon::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 6px;
  width: 7px;
  height: 12px;
  border-right: 2px solid var(--gold-2);
  border-bottom: 2px solid var(--gold-2);
  transform: translateX(-50%) rotate(45deg);
}

.promise-card strong {
  display: block;
  color: var(--green);
  font-size: 1.14rem;
  line-height: 1.2;
}

.promise-card span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.primary-button,
.secondary-button,
.copy-button,
.ghost-button,
.option-button {
  border: 0;
  cursor: pointer;
}

.primary-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-height: 60px;
  margin-top: 32px;
  padding: 17px 34px;
  border-radius: 999px;
  background:
    radial-gradient(circle at 85% 5%, rgba(255, 255, 255, 0.28), transparent 28%),
    linear-gradient(135deg, #10402c, #17613e 58%, #79a96f);
  color: #fff;
  font-weight: 900;
  letter-spacing: 0.03em;
  box-shadow:
    inset 0 0 0 1px rgba(255, 230, 160, 0.25),
    0 18px 48px rgba(23, 77, 54, 0.3);
  transition:
    transform 0.18s ease,
    box-shadow 0.18s ease,
    opacity 0.18s ease;
}

.primary-button:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow:
    inset 0 0 0 1px rgba(255, 230, 160, 0.32),
    0 28px 60px rgba(23, 77, 54, 0.34);
}

.primary-button:disabled {
  cursor: not-allowed;
  opacity: 0.46;
}

.hero-cta {
  min-width: min(420px, 100%);
  font-size: 1.02rem;
}

.button-star {
  color: #e7c36e;
}

.button-arrow {
  margin-left: auto;
}

.safe-line {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
  text-align: center;
  max-width: min(420px, 100%);
}

.map-card {
  width: min(100%, 620px);
  margin: 0 auto;
}

.map-card img {
  display: block;
  width: 100%;
  height: auto;
}

.process-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin-top: 22px;
}

.process-strip article {
  display: flex;
  align-items: center;
  gap: 16px;
  min-height: 76px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 26px;
  background: rgba(255, 250, 235, 0.76);
  box-shadow: var(--soft-shadow);
  backdrop-filter: blur(16px);
}

.process-strip span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 40px;
  width: 40px;
  height: 40px;
  border-radius: 16px;
  background: var(--green);
  color: #fff;
  font-size: 0.8rem;
  font-weight: 900;
}

.process-strip p {
  margin: 0;
  font-weight: 900;
}

/* diagnosis area */
.diagnosis-screen,
.result-screen {
  min-height: calc(100vh - 126px);
}

.diagnosis-header {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  margin-bottom: 22px;
}

.ghost-button {
  min-height: 44px;
  padding: 10px 18px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 235, 0.7);
  color: var(--green);
  font-weight: 850;
}

.progress-wrap {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: rgba(255, 250, 235, 0.7);
  backdrop-filter: blur(16px);
}

.progress-meta {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 750;
}

.progress-meta span:first-child {
  color: var(--green);
  font-weight: 950;
}

.progress-track {
  width: 100%;
  height: 9px;
  border-radius: 999px;
  background: rgba(23, 77, 54, 0.1);
  overflow: hidden;
}

.progress-fill {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--sage), var(--gold));
  transition: width 0.28s ease;
}

.question-panel {
  max-width: 900px;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 54px);
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 44px;
  background: var(--paper);
  box-shadow: var(--shadow);
  backdrop-filter: blur(24px);
  animation: fadeUp 0.34s ease both;
}

.question-panel h2 {
  max-width: 760px;
  margin: 12px 0 0;
  font-size: clamp(1.9rem, 5vw, 3.6rem);
  line-height: 1.18;
  letter-spacing: -0.07em;
}

.question-description {
  max-width: 720px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 1.02rem;
}

.options-grid {
  display: grid;
  gap: 12px;
  margin-top: 32px;
}

.option-button {
  width: 100%;
  padding: 18px 20px;
  border: 1px solid rgba(23, 77, 54, 0.13);
  border-radius: 24px;
  background: rgba(255, 252, 242, 0.76);
  color: var(--ink);
  text-align: left;
  box-shadow: 0 10px 30px rgba(43, 36, 24, 0.06);
  transition:
    transform 0.16s ease,
    border-color 0.16s ease,
    background 0.16s ease,
    box-shadow 0.16s ease;
}

.option-button:hover {
  transform: translateY(-1px);
  border-color: rgba(23, 77, 54, 0.32);
  box-shadow: 0 16px 38px rgba(43, 36, 24, 0.1);
}

.option-button.selected {
  border-color: rgba(23, 77, 54, 0.62);
  background:
    linear-gradient(135deg, rgba(231, 239, 232, 0.94), rgba(255, 250, 235, 0.9));
  box-shadow:
    0 0 0 5px rgba(23, 77, 54, 0.08),
    0 16px 38px rgba(43, 36, 24, 0.1);
}

.option-title {
  display: block;
  font-weight: 900;
  letter-spacing: -0.02em;
}

.option-desc {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.92rem;
}

.text-area-wrap {
  margin-top: 32px;
}

textarea {
  width: 100%;
  min-height: 160px;
  padding: 20px;
  border: 1px solid rgba(23, 77, 54, 0.18);
  border-radius: 26px;
  background: rgba(255, 252, 242, 0.82);
  color: var(--ink);
  outline: none;
  resize: vertical;
  transition:
    border-color 0.18s ease,
    box-shadow 0.18s ease,
    background 0.18s ease;
}

textarea:focus {
  border-color: var(--green);
  background: #fffdf5;
  box-shadow: 0 0 0 6px rgba(23, 77, 54, 0.08);
}

#text-hint {
  margin: 10px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.insight-box {
  margin-top: 26px;
  padding: 18px 20px;
  border: 1px solid rgba(23, 77, 54, 0.13);
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(231, 239, 232, 0.82), rgba(255, 250, 235, 0.74));
}

.insight-box span {
  display: block;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.08em;
}

.insight-box p {
  margin: 6px 0 0;
  color: #33423a;
  font-weight: 750;
}

.panel-actions {
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  margin-top: 34px;
}

.secondary-button {
  min-height: 56px;
  padding: 15px 24px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 250, 235, 0.74);
  color: var(--green);
  font-weight: 900;
}

.next-button {
  min-width: 180px;
  margin-top: 0;
}

.result-hero {
  max-width: 780px;
  margin: 0 auto 28px;
  text-align: center;
}

.result-hero h2 {
  margin: 8px 0 0;
  font-size: clamp(2.4rem, 7vw, 5.4rem);
  line-height: 1.05;
  letter-spacing: -0.08em;
}

.result-hero p:last-child {
  margin: 20px auto 0;
  max-width: 680px;
  color: var(--muted);
}

.result-layout {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  gap: 20px;
}

.result-map,
.result-card {
  border: 1px solid rgba(255, 255, 255, 0.74);
  border-radius: 34px;
  background: var(--paper);
  box-shadow: var(--shadow);
  backdrop-filter: blur(24px);
}

.result-map {
  align-self: start;
  padding: 24px;
  position: sticky;
  top: 18px;
}

.result-map > p {
  margin: 0 0 16px;
  color: var(--green);
  font-weight: 950;
  letter-spacing: -0.02em;
}

.axis-score-list {
  display: grid;
  gap: 10px;
}

.axis-row {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid rgba(23, 77, 54, 0.1);
  border-radius: 18px;
  background: rgba(255, 252, 242, 0.62);
}

.axis-row strong {
  font-size: 0.88rem;
}

.axis-meter {
  height: 7px;
  border-radius: 999px;
  background: rgba(23, 77, 54, 0.1);
  overflow: hidden;
}

.axis-meter span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--green), var(--sage), var(--gold));
}

.result-card {
  padding: clamp(26px, 5vw, 46px);
}

.result-pill {
  display: inline-flex;
  margin-bottom: 18px;
  padding: 8px 14px;
  border-radius: 999px;
  background: #e7efe8;
  color: var(--green);
  font-size: 0.86rem;
  font-weight: 950;
}

.result-body h3 {
  margin: 30px 0 10px;
  color: var(--green);
  font-size: 1.22rem;
  letter-spacing: -0.03em;
}

.result-body h3:first-child {
  margin-top: 0;
}

.result-body p {
  margin: 0;
  white-space: pre-wrap;
}

.result-body p + p {
  margin-top: 12px;
}

.result-actions {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 12px;
  margin-top: 30px;
}

.copy-button {
  min-height: 56px;
  padding: 15px 22px;
  border-radius: 999px;
  background: linear-gradient(135deg, #174d36, #24714d);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 18px 48px rgba(23, 77, 54, 0.2);
}

.restart-button {
  min-width: 170px;
}

[hidden] {
  display: none !important;
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 980px) {
  .app-shell {
    width: min(100% - 24px, 1180px);
    padding-top: 34px;
  }

  .hero-layout,
  .result-layout {
    grid-template-columns: 1fr;
  }

  .hero-layout {
    min-height: auto;
    gap: 28px;
  }

  .map-card {
    max-width: 580px;
  }

  .process-strip {
    grid-template-columns: 1fr;
  }

  .result-map {
    position: static;
  }
}

@media (max-width: 640px) {
  .top-labels {
    margin-bottom: 20px;
  }

  .hero-title-image {
    width: min(100%, 420px);
  }

  .lead {
    line-height: 1.9;
    margin-top: 8px;
  }

  .promise-row {
    grid-template-columns: 1fr;
  }

  .hero-cta,
  .safe-line {
    max-width: none;
    width: 100%;
  }

  .map-card {
    margin-top: 4px;
  }

  .diagnosis-header {
    grid-template-columns: 1fr;
  }

  .progress-meta {
    display: grid;
    gap: 4px;
  }

  .question-panel {
    border-radius: 32px;
    padding: 24px;
  }

  .question-panel h2 {
    font-size: clamp(1.8rem, 10vw, 2.7rem);
  }

  .panel-actions {
    display: grid;
  }

  .next-button,
  .secondary-button {
    width: 100%;
  }

  .result-actions {
    grid-template-columns: 1fr;
  }

  .restart-button {
    width: 100%;
  }
}
