:root {
  --paper: #f7f2ec;
  --paper-2: #fffdf9;
  --ink: #473c43;
  --muted: #7c6b73;
  --rose: #b87991;
  --rose-soft: #f2e3e8;
  --blue: #7188a7;
  --line: #e7dce0;
  --shadow: 0 18px 50px rgba(79, 56, 67, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 10% 5%, rgba(216, 184, 196, .22), transparent 24rem),
    radial-gradient(circle at 92% 35%, rgba(183, 201, 220, .22), transparent 26rem),
    var(--paper);
  font-family: "Yu Mincho", "Hiragino Mincho ProN", "Noto Serif JP", serif;
  line-height: 1.9;
  letter-spacing: .035em;
  min-height: 100vh;
}

button, a { font: inherit; }
button { color: inherit; }
img { display: block; max-width: 100%; }

.app-shell {
  width: min(100%, 680px);
  min-height: 100vh;
  margin: 0 auto;
  background: rgba(255, 253, 249, .88);
  box-shadow: 0 0 48px rgba(80, 62, 69, .07);
  overflow: hidden;
}

.screen { display: none; min-height: 100vh; }
.screen.is-active { display: block; animation: fade-in .38s ease both; }
@keyframes fade-in { from { opacity: 0; transform: translateY(7px); } }

.hero {
  position: relative;
  display: block;
  width: 100%;
  min-height: 520px;
  overflow: hidden;
  background: #e9e1d7;
}
.hero img { width: 100%; height: 520px; object-fit: cover; object-position: 54% center; }
.hero__shade {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(38, 28, 34, .02) 18%, rgba(47, 34, 42, .72) 100%);
}
.hero__copy {
  position: absolute;
  left: clamp(24px, 6vw, 46px);
  right: clamp(24px, 6vw, 46px);
  bottom: 38px;
  color: #fff;
  text-shadow: 0 2px 16px rgba(36, 27, 33, .35);
}
.hero__copy strong {
  display: block;
  margin-bottom: 24px;
  font-size: clamp(40px, 8vw, 58px);
  font-weight: 500;
  letter-spacing: .08em;
  line-height: 1.2;
}
.hero__button { width: min(100%, 420px); }

.primary-button {
  width: min(100%, 500px);
  min-height: 68px;
  padding: 16px 26px;
  border: 0;
  border-radius: 20px;
  color: #fff;
  background: #7a587d;
  box-shadow: 0 12px 28px rgba(86, 57, 90, .20);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: .06em;
  cursor: pointer;
}

.screen--quiz { padding: 18px clamp(14px, 4vw, 28px) 82px; }
.quiz-head { margin-bottom: 17px; }
.quiz-head__labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 11px;
  color: var(--muted);
  font-size: 13px;
}
.quiz-head__labels b { font-size: 17px; font-weight: 500; color: var(--ink); }
.progress { display: grid; grid-template-columns: repeat(12, 1fr); gap: 5px; }
.progress span { height: 7px; border-radius: 999px; background: #ebe4e9; transition: background .25s, transform .25s; }
.progress span.is-done { background: #c793a7; }
.progress span.is-current { background: #7a587d; transform: scaleY(1.35); }

.question-card {
  padding: 22px clamp(16px, 4vw, 28px) 25px;
  border: 1px solid rgba(211, 193, 201, .72);
  border-radius: 28px;
  background: rgba(255, 255, 255, .88);
  box-shadow: var(--shadow);
}
.question-card.is-changing { animation: question-out .18s ease both; }
@keyframes question-out { to { opacity: 0; transform: translateX(-10px); } }

.concierge-line {
  display: grid;
  grid-template-columns: 62px 1fr;
  align-items: start;
  gap: 12px;
  min-height: 132px;
  margin-bottom: 18px;
}
.concierge-line__icon {
  width: 62px;
  height: 62px;
  border-radius: 19px;
  object-fit: cover;
  object-position: center 16%;
  box-shadow: 0 8px 22px rgba(79, 56, 67, .12);
}
.concierge-line__bubble {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 112px;
  padding: 14px 17px 15px;
  border: 1px solid #eadce2;
  border-radius: 18px;
  background: #fffafa;
}
.concierge-line__bubble::before {
  content: "";
  position: absolute;
  left: -8px;
  top: 21px;
  width: 14px;
  height: 14px;
  background: #fffafa;
  border-left: 1px solid #eadce2;
  border-bottom: 1px solid #eadce2;
  transform: rotate(45deg);
}
.question-card h1 {
  margin: 0;
  font-size: clamp(20px, 4.7vw, 28px);
  font-weight: 500;
  line-height: 1.55;
  letter-spacing: .035em;
}

.choices { display: grid; gap: 10px; }
.choice {
  display: grid;
  grid-template-columns: 54px 1fr;
  align-items: center;
  width: 100%;
  min-height: 76px;
  padding: 11px 20px 11px 12px;
  border: 1px solid #dfd3d9;
  border-radius: 20px;
  background: #fffafc;
  text-align: left;
  font-size: clamp(16px, 3.8vw, 19px);
  line-height: 1.6;
  cursor: pointer;
  transition: transform .14s ease, border-color .14s ease, background .14s ease;
}
.choice:nth-child(2) { background: #f5f8fc; border-color: #d5dce7; }
.choice:nth-child(3) { background: #fbf8f6; }
.choice:hover, .choice:focus-visible { transform: translateY(-2px); border-color: #aa7990; outline: none; }
.choice.is-selected { background: #ead3dc; border-color: #aa7990; transform: scale(.985); }
.choice__mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 14px;
  color: #765164;
  background: rgba(255, 255, 255, .78);
  font-size: 17px;
}

.screen--thinking { display: none; place-items: center; padding: 30px; }
.screen--thinking.is-active { display: grid; }
.thinking-card { width: min(100%, 430px); text-align: center; }
.thinking-title { margin: 0 0 16px; font-size: 24px; font-weight: 500; letter-spacing: .06em; }
.pentagon-wrap { width: 100%; margin: 0 auto; }
.pentagon { display: block; width: min(100%, 330px); margin: auto; overflow: visible; }
.pentagon__ring { fill: none; stroke: #ddd2d8; stroke-width: 1.2; }
.pentagon__axis { stroke: #e6dce1; stroke-width: 1; }
.pentagon__shape { fill: rgba(184, 121, 145, .24); stroke: #9f6d82; stroke-width: 2.5; animation: pentagon-in .65s ease both; transform-origin: center; }
.pentagon__label { fill: #695761; font-size: 13px; font-family: inherit; }
@keyframes pentagon-in { from { opacity: .15; transform: scale(.65); } to { opacity: 1; transform: scale(1); } }

.screen--result { padding-bottom: 96px; }
.result__head { padding: 44px 18px 28px; text-align: center; }
.result__catch {
  margin: 0;
  font-size: clamp(20px, 4.9vw, 31px);
  font-weight: 500;
  line-height: 1.72;
  letter-spacing: .025em;
}
.result__catch span { display: block; white-space: nowrap; }
.result__image {
  width: calc(100% - 32px);
  margin: 0 16px;
  border-radius: 26px;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  box-shadow: var(--shadow);
}
.result__identity { padding: 28px 24px 4px; text-align: center; }
.result__name {
  margin: 0 auto;
  max-width: 100%;
  color: #6d526e;
  font-size: clamp(46px, 10vw, 68px);
  font-weight: 500;
  line-height: 1.2;
  letter-spacing: .08em;
  white-space: nowrap;
}
.result__location { margin: 8px 0 0; color: var(--muted); font-size: 14px; }
.result__body { padding: 24px clamp(24px, 7vw, 52px) 0; }
.result-section { padding: 24px 0; border-bottom: 1px solid var(--line); }
.result-section p { margin: 0; font-size: 16px; }
.result-section p + p { margin-top: 15px; }
.result-section--lead p { font-size: 17px; }
.result__emotion { font-weight: 500; }
.alternatives { color: #665761; }
.alternatives p + p { margin-top: 9px; }
.text-place {
  padding: 0;
  border: 0;
  border-bottom: 1px solid #9f7788;
  background: transparent;
  color: #72526a;
  font-weight: 700;
  cursor: pointer;
}

.concierge { display: grid; grid-template-columns: 62px 1fr; align-items: center; gap: 12px; }
.concierge img {
  width: 62px;
  height: 62px;
  border-radius: 19px;
  object-fit: cover;
  object-position: center 16%;
  box-shadow: 0 8px 22px rgba(79, 56, 67, .12);
}
.concierge__speech {
  position: relative;
  padding: 18px 20px;
  border: 1px solid #eadce2;
  border-radius: 20px;
  background: #fffafa;
  text-align: left;
}
.concierge__speech p { font-size: 15px; }
.concierge__speech strong { color: #6d526e; font-size: 17px; }

.map-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 28px; }
.map-button {
  display: grid;
  place-items: center;
  min-height: 62px;
  padding: 12px;
  border: 1px solid #cdbac5;
  border-radius: 18px;
  color: #6e5169;
  background: #fff;
  text-decoration: none;
  text-align: center;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.5;
}
.meeting { grid-column: 1 / -1; margin: 0 0 4px; color: var(--muted); text-align: center; font-size: 12px; }
.retry { display: block; width: min(100%, 390px); margin: 38px auto 0; }

.corner-links {
  position: fixed;
  z-index: 20;
  right: max(10px, env(safe-area-inset-right));
  bottom: max(12px, env(safe-area-inset-bottom));
  display: grid;
  gap: 7px;
}
.corner-links a {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 104px;
  min-height: 44px;
  padding: 9px 13px;
  border: 1px solid rgba(115, 84, 119, .16);
  border-radius: 14px;
  color: #655568;
  background: rgba(255, 253, 250, .94);
  box-shadow: 0 5px 16px rgba(64, 54, 68, .10);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  text-decoration: none;
  text-align: center;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .02em;
}

@media (max-width: 780px) {
  .app-shell { box-shadow: none; }
}

@media (max-width: 480px) {
  .hero, .hero img { min-height: 455px; height: 455px; }
  .question-card { padding: 18px 14px 21px; }
  .concierge-line { grid-template-columns: 56px 1fr; gap: 10px; }
  .concierge-line__icon { width: 56px; height: 56px; border-radius: 17px; }
  .concierge-line__bubble { padding: 12px 14px 13px; }
  .choice { min-height: 72px; padding-right: 14px; }
  .result__image { width: calc(100% - 20px); margin: 0 10px; border-radius: 20px; }
  .concierge { grid-template-columns: 56px 1fr; gap: 10px; }
  .concierge img { width: 56px; height: 56px; border-radius: 17px; }
  .map-actions { grid-template-columns: 1fr; }
  .meeting { grid-column: auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}
/* v2: 好きの地図。のリズムへ寄せた結果表示 */
.result__placeholder {
  width: calc(100% - 32px);
  margin: 0 16px;
  aspect-ratio: 3 / 2;
  border-radius: 26px;
  display: grid;
  place-items: center;
  padding: 28px;
  background:
    radial-gradient(circle at 20% 20%, rgba(255,255,255,.7), transparent 30%),
    linear-gradient(135deg, #eadde5, #dfe7ef 55%, #eee3d8);
  box-shadow: var(--shadow);
  text-align: center;
}
.result__placeholder span { font-size: clamp(24px,6vw,40px); color:#654f62; letter-spacing:.08em; }
.concierge--center { display:block; text-align:center; }
.concierge--center img { width:88px; height:88px; margin:0 auto 14px; border-radius:24px; }
.concierge--center .concierge__speech { text-align:center; }
.concierge--center .concierge__speech::before { display:none; }
.concierge--center .concierge__speech p { font-size:16px; line-height:1.9; }
.concierge--center .concierge__speech strong { display:inline-block; margin-top:3px; font-size:18px; }
@media (max-width:480px){
  .result__placeholder { width:calc(100% - 20px); margin:0 10px; border-radius:20px; }
}

.result-section--trip p { font-size: 16px; line-height: 2; }
.result-section--trip p + p { margin-top: 17px; }
.result__placeholder small { display:block; margin-top:10px; font-size:12px; opacity:.72; }
@media (max-width: 360px){ .result__catch{font-size:19px;letter-spacing:0;} .question-card h1{font-size:20px;} .concierge-line__bubble{min-height:118px;} .concierge-line{min-height:138px;} }


/* v12: 同じ傾向を別の場所へ広げる「遠くに行っちゃう？」 */
.far-trip {
  margin-top: 34px;
  padding-top: 30px;
  border-top: 1px solid var(--line);
}
.far-trip > .concierge { padding: 0; border: 0; }
.far-trip__button {
  display: block;
  width: min(100%, 390px);
  margin: 18px auto 0;
}
.far-result {
  margin-top: 38px;
  padding-top: 34px;
  border-top: 1px dashed #d9cbd2;
}
.far-result__lead {
  margin: 0 0 20px;
  color: var(--muted);
  text-align: center;
  font-size: 14px;
  letter-spacing: .04em;
}
.far-result__head { padding: 0 0 26px; text-align: center; }
.far-result .result__image,
.far-result .result__placeholder { width: 100%; margin-left: 0; margin-right: 0; }
.far-result .result__identity { padding-left: 0; padding-right: 0; }
.far-result .result-section { border-bottom: 0; }
.far-result .map-actions { margin-bottom: 4px; }
@media (max-width: 480px) {
  .far-result .result__image,
  .far-result .result__placeholder { width: 100%; margin-left: 0; margin-right: 0; }
}
