:root {
  --bg1: #ffe9f3;
  --bg2: #f4e9ff;
  --bg3: #fff6e9;
  --card-bg: #ffffff;
  --primary: #ff8fb3;
  --primary-dark: #ef6b96;
  --accent2: #b892ff;
  --accent3: #ffcf7a;
  --mint: #7ed9c9;
  --text: #55404f;
  --text-sub: #7d5c72; /* 2026-09-05: WCAG AA対応で#a3899eから濃色化(白背景比5.76:1、最も暗い背景グラデ比でも4.92:1) */
  --border: #ffe3ee;
  --shadow-soft: 0 10px 30px rgba(220, 130, 170, 0.16);
  --shadow-lift: 0 16px 40px rgba(220, 130, 170, 0.24);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  min-height: 100vh;
}

body {
  font-family: "Zen Maru Gothic", "Hiragino Sans", "Yu Gothic", sans-serif;
  background:
    radial-gradient(circle at 15% 8%, rgba(255,255,255,0.6) 0, transparent 2px) 0 0/28px 28px,
    linear-gradient(160deg, var(--bg1) 0%, var(--bg2) 55%, var(--bg3) 100%);
  color: var(--text);
  position: relative;
  overflow-x: hidden;
}

/* ---- 背景の動くブロブ+きらめき装飾 ---- */
.bg-blobs {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.55;
  animation: drift 18s ease-in-out infinite alternate;
}
.blob-1 { width: 340px; height: 340px; background: #ffc2dd; top: -90px; left: -90px; }
.blob-2 { width: 300px; height: 300px; background: #dcc4ff; bottom: -70px; right: -70px; animation-delay: -6s; }
.blob-3 { width: 260px; height: 260px; background: #ffe3ae; top: 42%; left: 58%; animation-delay: -11s; }
.blob-4 { width: 220px; height: 220px; background: #bdeee2; top: 68%; left: 4%; animation-delay: -3s; }

@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to   { transform: translate(30px, 40px) scale(1.15); }
}

.sparkles { position: fixed; inset: 0; z-index: 0; overflow: hidden; pointer-events: none; }
.sparkle {
  position: absolute;
  animation: twinkle 4.5s ease-in-out infinite;
  opacity: 0;
  filter: drop-shadow(0 2px 6px rgba(255,143,179,0.35));
}
.sparkle:nth-child(1)  { top: 8%;  left: 12%; font-size: 1.1rem; animation-delay: 0s; }
.sparkle:nth-child(2)  { top: 18%; left: 82%; font-size: 0.9rem; animation-delay: 0.7s; }
.sparkle:nth-child(3)  { top: 32%; left: 6%;  font-size: 1.3rem; animation-delay: 1.4s; }
.sparkle:nth-child(4)  { top: 46%; left: 90%; font-size: 1rem;   animation-delay: 2.1s; }
.sparkle:nth-child(5)  { top: 62%; left: 15%; font-size: 1.2rem; animation-delay: 2.8s; }
.sparkle:nth-child(6)  { top: 74%; left: 85%; font-size: 1rem;   animation-delay: 0.4s; }
.sparkle:nth-child(7)  { top: 86%; left: 30%; font-size: 1.1rem; animation-delay: 1.8s; }
.sparkle:nth-child(8)  { top: 4%;  left: 55%; font-size: 0.9rem; animation-delay: 3.3s; }

@keyframes twinkle {
  0%, 100% { opacity: 0; transform: translateY(6px) scale(0.7) rotate(0deg); }
  50%      { opacity: 0.85; transform: translateY(-6px) scale(1.05) rotate(12deg); }
}

@keyframes skeleton-shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ---- モーション低減設定への対応(2026-09-05追加、MBTI診断・黒曜診断と同様のガード) ---- */
@media (prefers-reduced-motion: reduce) {
  .blob, .sparkle { animation: none; }
  .bubble { animation: none; }
  .result-card { animation: none; opacity: 1; }
  .vs-avatar, .result-card-preview { animation: none; }
}

/* 超ワイド画面(2026-09-12、MBTI診断と同じ方針)。機能コンテンツの幅は
   広げず、周囲の装飾ブロブ・きらめきを拡大・外側に再配置。 */
@media (min-width: 1400px) {
  .blob-1 { width: 480px; height: 480px; }
  .blob-2 { width: 420px; height: 420px; }
  .blob-3 { width: 380px; height: 380px; left: 74%; }
  .blob-4 { width: 320px; height: 320px; left: -4%; }
  .sparkle:nth-child(2) { left: 92%; }
  .sparkle:nth-child(4) { left: 96%; }
  .sparkle:nth-child(3) { left: 3%; }
  .sparkle:nth-child(6) { left: 90%; }
}

/* 左右の余白に既存イラストを配置(2026-09-12、新規生成なし・既存アセット再利用)。
   気質マスコットは168×168の低解像度アセットのため、拡大しすぎない幅に留める。 */
.bg-illustrations { display: none; }
@media (min-width: 1400px) {
  body:has(#screen-start.active) .bg-illustrations {
    display: block;
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
  }
  .bg-illust {
    position: absolute;
    width: 150px;
    border-radius: 24px;
    opacity: 0.6;
    box-shadow: 0 20px 45px rgba(120,60,100,0.22);
  }
  .bg-illust-left { top: 14%; left: 4%; transform: rotate(-6deg); }
  .bg-illust-right { bottom: 12%; right: 4%; transform: rotate(6deg); }
}

#app {
  position: relative;
  z-index: 1;
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.screen { display: none; flex: 1; flex-direction: column; }
.screen.active { display: flex; }

.grad-text {
  background: linear-gradient(90deg, var(--primary), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.eyebrow {
  display: inline-block;
  font-family: "Poppins", sans-serif;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--primary);
  margin-bottom: 10px;
}

/* ---- スタート画面 ---- */
#screen-start {
  align-items: center;
  justify-content: center;
  padding: 28px 20px;
}
/* PC幅でのスタート画面2カラム化(2026-09-12、MBTI診断・黒曜診断と同じ設計方針) */
.start-sidebar { display: flex; flex-direction: column; gap: 18px; }
.start-sidebar .transparency-box { margin-top: 0; }
@media (min-width: 900px) {
  #app:has(#screen-start.active) { max-width: 980px; }
  .start-layout {
    display: grid;
    grid-template-columns: 480px 1fr;
    gap: 28px;
    align-items: start;
    width: 100%;
  }
  .start-sidebar { padding-top: 6px; }
}
.start-card {
  background: rgba(255, 255, 255, 0.72);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.6);
  border-radius: 28px;
  padding: 40px 26px 32px;
  box-shadow: var(--shadow-lift);
  text-align: center;
}
.lang-toggle {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-bottom: 14px;
}
.lang-btn {
  font-family: "Poppins", "Zen Maru Gothic", sans-serif;
  font-size: 0.74rem;
  font-weight: 700;
  padding: 5px 14px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  border: 1.5px solid var(--border);
  background: #fff;
  color: var(--text-sub);
  cursor: pointer;
  transition: all 0.15s ease;
}
.lang-btn.active {
  background: linear-gradient(135deg, var(--primary), var(--accent2));
  color: #fff;
  border-color: transparent;
}

.site-nav {
  max-width: 980px;
  margin: 0 auto 14px;
}
.site-nav-label {
  display: block;
  text-align: center;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-sub);
  margin-bottom: 8px;
}
.site-nav-links {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 2px 6px;
  scrollbar-width: none;
  justify-content: center;
  flex-wrap: wrap;
}
.site-nav-links::-webkit-scrollbar { display: none; }
.site-nav-link {
  flex: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 7px 14px;
  border-radius: 999px;
  background: var(--card-bg);
  border: 1.5px solid var(--primary);
  color: var(--primary-dark);
  font-size: 0.8rem;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.site-nav-link:hover { background: var(--primary); color: #fff; }
.hero-banner {
  width: 100%;
  max-width: 980px;
  margin: 0 auto 20px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0,0,0,0.15);
}
.hero-banner-img {
  display: block;
  width: 100%;
  aspect-ratio: 4.8 / 1;
  object-fit: cover;
  object-position: center;
}
.hero-banner-crop-top .hero-banner-img { object-position: top; }
.start-emoji {
  font-size: 2.6rem;
  margin-bottom: 6px;
  filter: drop-shadow(0 6px 12px rgba(255,143,179,0.4));
}
.hero-preview {
  display: flex;
  justify-content: center;
  align-items: flex-end;
  margin: 2px 0 16px;
}
.hero-preview-img {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  object-position: top center;
  border: 3px solid var(--card-bg);
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
  margin-left: -16px;
}
.hero-preview-img:first-child { margin-left: 0; transform: rotate(-6deg); }
.hero-preview-img:nth-child(2) { width: 76px; height: 76px; z-index: 2; transform: translateY(-6px); }
.hero-preview-img:nth-child(3) { transform: rotate(6deg); }
.start-card h1 {
  font-size: 1.55rem;
  font-weight: 900;
  margin: 4px 0 14px;
  line-height: 1.5;
}
.start-card .lead {
  color: var(--text-sub);
  line-height: 1.75;
  margin-bottom: 18px;
  font-size: 0.94rem;
}
.badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-bottom: 26px;
}
.badge {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--primary-dark);
  background: linear-gradient(135deg, #efe9ff, #fdeaf3);
  border: 1px solid var(--border);
  padding: 5px 12px;
  border-radius: 999px;
}
.start-card .sub {
  font-size: 0.78rem;
  color: var(--text-sub);
  margin: 16px 0 0;
}

.hub-cta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 22px;
  padding: 14px 16px;
  background: linear-gradient(135deg, #fdeaf3, #efe9ff);
  border: 1.5px solid var(--border);
  border-radius: 16px;
  text-decoration: none;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}
.hub-cta:hover { transform: translateY(-2px); box-shadow: var(--shadow-soft); }
.hub-cta-emoji { font-size: 1.6rem; flex: none; }
.hub-cta-text { flex: 1; display: flex; flex-direction: column; gap: 2px; text-align: left; }
.hub-cta-title { font-size: 0.86rem; font-weight: 700; color: var(--primary-dark); }
.hub-cta-arrow { font-size: 1.3rem; font-weight: 700; color: var(--primary-dark); flex: none; transition: transform 0.18s ease; }
.hub-cta:hover .hub-cta-arrow { transform: translateX(3px); }

.btn-primary {
  background: linear-gradient(135deg, var(--primary), var(--accent2));
  color: #fff;
  border: none;
  padding: 16px 28px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 1.02rem;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(255, 143, 179, 0.45);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  width: 100%;
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 30px rgba(255, 143, 179, 0.55); }
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled {
  background: var(--border);
  color: var(--text-sub);
  box-shadow: none;
  cursor: not-allowed;
}
.btn-primary:disabled:hover { transform: none; box-shadow: none; }

.btn-secondary {
  background: rgba(255,255,255,0.6);
  color: var(--primary-dark);
  border: 2px solid var(--primary);
  padding: 13px 28px;
  border-radius: 999px;
  font-family: inherit;
  font-size: 0.96rem;
  font-weight: 700;
  cursor: pointer;
  width: 100%;
  margin-top: 10px;
  transition: background 0.15s ease;
}
.btn-secondary:hover { background: #fff; }

/* ---- チャット画面 ---- */
.chat-header {
  padding: 16px 18px 12px;
  background: rgba(255, 240, 247, 0.78);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 5;
  border-bottom: 1px solid rgba(255,255,255,0.5);
}
.block-label {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--primary-dark);
  background: #ffe3ee;
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 9px;
  transition: background 0.3s ease, color 0.3s ease;
}
.progress-bar {
  height: 8px;
  background: var(--border);
  border-radius: 999px;
  overflow: hidden;
  box-shadow: inset 0 1px 3px rgba(0,0,0,0.06);
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--primary), var(--accent2));
  width: 0%;
  border-radius: 999px;
  transition: width 0.35s cubic-bezier(.4,0,.2,1);
}
.progress-text {
  display: block;
  font-family: "Poppins", sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  color: var(--text-sub);
  margin-top: 5px;
  text-align: right;
}

.chat-log {
  flex: 1;
  padding: 18px 16px 8px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  overflow-y: auto;
}

.bubble-row { display: flex; align-items: flex-end; gap: 8px; max-width: 100%; }
.bubble-row.user { justify-content: flex-end; }

.avatar {
  width: 30px;
  height: 30px;
  flex: none;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--accent2));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.95rem;
  box-shadow: 0 4px 10px rgba(255,143,179,0.4);
}

.bubble {
  max-width: 78%;
  padding: 13px 17px;
  border-radius: 20px;
  line-height: 1.6;
  font-size: 0.95rem;
  animation: pop-in 0.28s cubic-bezier(.34,1.56,.64,1);
}
.bubble.ai {
  background: #ffffff;
  border: 1px solid var(--border);
  border-bottom-left-radius: 6px;
  box-shadow: 0 4px 14px rgba(90,70,160,0.08);
}
.bubble.user {
  background: linear-gradient(135deg, var(--primary), var(--accent2));
  color: #fff;
  border-bottom-right-radius: 6px;
  box-shadow: 0 6px 16px rgba(255,143,179,0.35);
  font-size: 0.86rem;
}

@keyframes pop-in {
  from { opacity: 0; transform: translateY(8px) scale(0.97); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-options {
  padding: 10px 16px 22px;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.option-btn {
  background: #ffffff;
  border: 2px solid var(--border);
  color: var(--text);
  padding: 13px 16px;
  border-radius: 16px;
  font-family: inherit;
  font-size: 0.9rem;
  text-align: left;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 12px;
  transition: border-color 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease;
  box-shadow: 0 2px 8px rgba(90,70,160,0.05);
}
.option-btn:hover { border-color: var(--primary); box-shadow: 0 6px 16px rgba(255,143,179,0.2); }
.option-btn:active { transform: scale(0.98); }
.option-num {
  flex: none;
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: "Poppins", sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  border-radius: 50%;
  background: linear-gradient(135deg, #efe9ff, #fdeaf3);
  color: var(--primary-dark);
}
.option-text { line-height: 1.45; }

/* ---- 結果画面 ---- */
#screen-result {
  padding: 26px 18px 36px;
}
.result-header { text-align: center; margin-bottom: 22px; }
.result-title {
  font-size: 1.4rem;
  font-weight: 900;
  margin: 4px 0 0;
}
.result-cards {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.result-card {
  --accent: #b892ff;
  background: rgba(255,255,255,0.85);
  backdrop-filter: blur(10px);
  border-radius: 22px;
  padding: 24px 22px;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(255,255,255,0.7);
  border-top: 5px solid var(--accent);
  position: relative;
  opacity: 0;
  animation: card-in 0.5s ease forwards;
}
@keyframes card-in {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}
.card-icon {
  font-size: 2.3rem;
  margin-bottom: 6px;
  filter: drop-shadow(0 4px 8px rgba(0,0,0,0.12));
}
.result-card .cat-name {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent);
  margin: 0 0 4px;
}
.result-card .type-name {
  font-family: "Poppins", "Zen Maru Gothic", sans-serif;
  font-size: 1.4rem;
  font-weight: 800;
  margin-bottom: 4px;
}
.result-card .mbti-code {
  font-family: "Poppins", sans-serif;
  font-size: 0.74rem;
  font-weight: 600;
  color: var(--text-sub);
  margin-bottom: 12px;
  letter-spacing: 0.05em;
}
.result-card .desc {
  font-size: 0.9rem;
  line-height: 1.75;
  color: var(--text);
}

.lucky-item {
  margin-top: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 16px;
  background: linear-gradient(135deg, #fff8ec, #fff0f5);
  border: 1.5px dashed #ffcf7a;
  text-decoration: none;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.lucky-item:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(255,207,122,0.35); }
.lucky-emoji { font-size: 1.6rem; flex: none; }
.lucky-text { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.lucky-label {
  font-size: 0.66rem;
  font-weight: 700;
  color: #d18b2a;
  letter-spacing: 0.02em;
}
.lucky-name {
  font-size: 0.86rem;
  font-weight: 700;
  color: var(--text);
}
.lucky-arrow {
  font-size: 1.3rem;
  color: #d18b2a;
  flex: none;
}
.result-card-preview {
  margin-bottom: 22px;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 14px 34px rgba(120, 90, 130, 0.22);
  min-height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
  /* ---- 読込中スケルトン(2026-09-05追加)。canvasのプレビュー生成が完了しimgが挿入されるまでの
     空白期間に、読込破綻ではなく「読込中」と伝わるシマーを表示する ---- */
  background: linear-gradient(100deg, rgba(255,143,179,0.12) 30%, rgba(184,146,255,0.18) 50%, rgba(255,143,179,0.12) 70%);
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.6s ease-in-out infinite;
}
.result-card-preview img {
  display: block;
  width: 100%;
  height: auto;
}
.result-card-preview-hint {
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-sub);
  margin: -14px 0 24px;
}

.result-actions {
  margin-top: 28px;
}
.result-actions-card {
  margin-top: 14px;
}
.result-actions-card .btn-secondary {
  font-size: 0.88rem;
  padding: 11px 22px;
  opacity: 0.9;
}
/* ---- CTA群の視覚的分離(2026-09-05、シェア系→保存系→やり直しの順に優先度を分けて配置) ---- */
.result-actions-restart {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px dashed var(--border);
}
.result-actions-restart .btn-secondary {
  font-size: 0.86rem;
  opacity: 0.85;
}

.btn-line {
  background: rgba(6, 199, 85, 0.08);
  border-color: #06c755;
  color: #06c755;
}
.btn-line:hover { background: rgba(6, 199, 85, 0.16); }

.follow-links {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.follow-label {
  font-size: 0.74rem;
  color: var(--text-sub);
  margin: 0 0 8px;
}
.follow-btns {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px;
}
.follow-link {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--primary-dark);
  background: #fff;
  border: 1.5px solid var(--border);
  padding: 6px 16px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  text-decoration: none;
}
.follow-link:hover { border-color: var(--primary); }

.site-footer {
  max-width: 480px;
  margin: 0 auto;
  padding: 18px 20px 32px;
  position: relative;
  z-index: 1;
}
.site-footer p {
  font-size: 0.68rem;
  line-height: 1.6;
  color: var(--text-sub);
  margin: 0 0 8px;
  text-align: center;
}

.lucky-pr-tag {
  display: inline-block;
  font-size: 0.6rem;
  font-weight: 700;
  color: #d18b2a;
  background: #fff3d6;
  border-radius: 6px;
  padding: 1px 6px;
  margin-left: 6px;
  vertical-align: middle;
}

@media (min-width: 520px) {
  .start-card { padding: 48px 40px 40px; }
}

/* ---- 相性診断: コード入力フォーム ---- */
.code-form {
  text-align: left;
  margin-top: 22px;
}
.code-form label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 6px;
}
.code-input {
  width: 100%;
  padding: 13px 16px;
  border-radius: 14px;
  border: 2px solid var(--border);
  background: #fff;
  font-family: inherit;
  font-size: 0.92rem;
  color: var(--text);
  margin-bottom: 6px;
}
.code-input:focus { outline: none; border-color: var(--primary); }
.code-input::placeholder { color: var(--text-sub); opacity: 0.55; font-style: italic; }
.code-hint {
  font-size: 0.72rem;
  color: var(--text-sub);
  margin-bottom: 18px;
  line-height: 1.5;
}
.code-hint a { color: var(--primary-dark); font-weight: 700; text-decoration: underline; }

/* 診断の仕組み・透明性セクション(2026-09-12、他と違うところ+誠実な自己開示) */
.transparency-box {
  margin-top: 18px;
  padding: 18px 20px;
  background: rgba(255,255,255,0.55);
  border: 1.5px dashed var(--border);
  border-radius: 20px;
  text-align: left;
}
.transparency-title { font-size: 0.88rem; font-weight: 700; color: var(--primary-dark); margin: 0 0 8px; }
.transparency-body { font-size: 0.82rem; color: var(--text); line-height: 1.7; margin: 0 0 10px; }
.transparency-note { font-size: 0.72rem; color: var(--text-sub); line-height: 1.6; margin: 0; }
.code-error {
  font-size: 0.78rem;
  color: #e0507a;
  margin: -8px 0 14px;
  display: none;
}
.code-error.show { display: block; }
.divider-or {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 18px 0;
  color: var(--text-sub);
  font-size: 0.74rem;
}
.divider-or::before, .divider-or::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border);
}

/* ---- 相性診断: 質問画面(推測クイズ) ---- */
#screen-guess { padding: 22px 20px 30px; }
.guess-header { text-align: center; margin-bottom: 18px; }
.guess-title { display: block; font-size: 2em; font-weight: bold; margin: 0.67em 0; }
.guess-header p { color: var(--text-sub); font-size: 0.84rem; line-height: 1.6; }
.guess-question {
  background: rgba(255,255,255,0.75);
  border-radius: 20px;
  padding: 20px 18px;
  box-shadow: var(--shadow-soft);
  margin-bottom: 16px;
}
.guess-question .q-num {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--primary-dark);
  margin-bottom: 6px;
}
.guess-question .q-text {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 14px;
  line-height: 1.5;
}
.guess-options { display: flex; flex-direction: column; gap: 9px; }
.option-btn.selected { border-color: var(--primary); background: linear-gradient(135deg, #fff0f6, #f5f0ff); }
.axis-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 12px; }
.axis-chip {
  font-size: 0.7rem;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: #f3eeff;
  color: var(--text-sub);
}
.axis-chip.match { background: #e8f7f2; color: #2f9c82; }

/* ---- 相性診断: 結果画面 ---- */
.score-hero {
  text-align: center;
  background: rgba(255,255,255,0.8);
  border-radius: 24px;
  padding: 28px 20px 22px;
  box-shadow: var(--shadow-lift);
  margin-bottom: 20px;
}
.score-hero .relation-name {
  font-size: 1.3rem;
  font-weight: 900;
  margin: 6px 0 10px;
}
.score-hero .score-num {
  font-family: "Poppins", sans-serif;
  font-size: 3.2rem;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary), var(--accent2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  line-height: 1;
}
.score-hero .score-suffix { font-size: 1rem; color: var(--text-sub); font-weight: 700; }
.score-hero .score-tier {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--primary-dark);
  background: #ffe3ee;
  padding: 4px 14px;
  border-radius: 999px;
  margin-top: 8px;
}
.score-hero .score-hook {
  margin-top: 12px;
  font-size: 0.86rem;
  color: var(--text);
  line-height: 1.6;
}

.vs-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin: 18px 0 6px;
}
.vs-person { text-align: center; flex: 1; max-width: 140px; }
.vs-avatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid #fff;
  box-shadow: 0 6px 18px rgba(120,90,130,0.25);
  margin-bottom: 8px;
  /* ---- 読込中スケルトン(2026-09-05追加、黒曜診断shugorei-hero-imgと同じ方式。
     画像が読み込まれると不透明なJPGが全面を覆うので、下地のシマーは自然に隠れる) ---- */
  background: linear-gradient(100deg, rgba(255,143,179,0.14) 30%, rgba(184,146,255,0.22) 50%, rgba(255,143,179,0.14) 70%);
  background-size: 200% 100%;
  animation: skeleton-shimmer 1.6s ease-in-out infinite;
}
.vs-name { font-size: 0.78rem; font-weight: 700; line-height: 1.4; }
.vs-mark {
  font-family: "Poppins", sans-serif;
  font-weight: 800;
  font-size: 1.1rem;
  color: var(--text-sub);
  flex: none;
}

.result-card .cat-score {
  display: flex;
  align-items: baseline;
  gap: 6px;
  margin-bottom: 14px;
}
.result-card .cat-score .num {
  font-family: "Poppins", sans-serif;
  font-size: 1.7rem;
  font-weight: 800;
  color: var(--accent);
}
.result-card .cat-score .tier {
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--text-sub);
}

.reason-block { margin-top: 14px; }
.reason-block .reason-line {
  font-size: 0.88rem;
  line-height: 1.75;
  color: var(--text);
  margin-bottom: 4px;
}
.reason-block .reason-label {
  font-size: 0.68rem;
  font-weight: 700;
  color: var(--accent);
  display: inline-block;
  margin-right: 4px;
}

.locked-card {
  background: rgba(255,255,255,0.5);
  border-radius: 22px;
  padding: 24px 22px;
  text-align: center;
  border: 1.5px dashed var(--border);
}
.locked-card .lock-emoji { font-size: 1.8rem; margin-bottom: 8px; }
.locked-card p { font-size: 0.86rem; color: var(--text-sub); line-height: 1.7; margin-bottom: 14px; }

.guess-disclaimer {
  font-size: 0.72rem;
  color: var(--text-sub);
  background: #fff8ec;
  border: 1px solid #ffe3ae;
  border-radius: 12px;
  padding: 10px 14px;
  margin: 12px 0 20px;
  line-height: 1.6;
}

/* ---- 相性タイプ別解説ページ(/pairs/) ---- */
.type-page { padding: 26px 18px 36px; }
.type-page-sub {
  font-size: 0.82rem;
  color: var(--text-sub);
  margin: 6px 0 0;
}
.type-page-card .cat-name { display: block; }
.type-page-note {
  font-size: 0.82rem;
  line-height: 1.7;
  color: var(--text-sub);
  background: rgba(255,255,255,0.6);
  border-radius: 16px;
  padding: 14px 16px;
  margin: 20px 0;
}
.type-nav {
  margin: 28px 0 8px;
  background: rgba(255,255,255,0.6);
  border-radius: 20px;
  padding: 16px;
}
.type-nav-label {
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--primary-dark);
  margin: 0 0 10px;
}
.type-nav-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}
.type-nav-link {
  display: block;
  text-align: center;
  text-decoration: none;
  font-family: "Zen Maru Gothic", sans-serif;
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--text);
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 8px 4px;
}
.type-nav-link.active {
  background: linear-gradient(135deg, var(--primary), var(--accent2));
  color: #fff;
  border-color: transparent;
}
.type-hub-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-bottom: 24px;
}
.type-hub-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
  text-decoration: none;
  color: var(--text);
  background: rgba(255,255,255,0.85);
  border-radius: 18px;
  padding: 18px 10px;
  box-shadow: var(--shadow-soft);
  border: 1px solid rgba(255,255,255,0.7);
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}
.type-hub-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.type-hub-emoji { font-size: 1.8rem; }
.type-hub-code {
  font-family: "Zen Maru Gothic", sans-serif;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--primary-dark);
}
.type-hub-title {
  font-size: 0.78rem;
  color: var(--text-sub);
  line-height: 1.4;
}

.temperament-duo {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: 0 auto 14px;
}
.temperament-duo img {
  border-radius: 14px;
  box-shadow: 0 10px 24px rgba(120, 90, 130, 0.22);
}
.temperament-duo-x {
  font-size: 1.4rem;
  color: var(--text-sub);
  font-weight: 700;
}
/* ---- 一覧カード内の小サイズ版(pairs/index.html、2026-09-05追加) ---- */
.type-hub-card .temperament-duo {
  margin: 0 0 8px;
  gap: 4px;
}
.type-hub-card .temperament-duo-x {
  font-size: 1rem;
}

.lang-note {
  font-size: 0.75rem;
  color: var(--text-sub);
  font-style: italic;
  margin: 6px 0 10px;
}

/* ---- キーボードフォーカス視認性(2026-09-05追加、黒曜診断・MBTI診断と同様のfocus-visible定義) ---- */
.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.lang-btn:focus-visible,
.hub-cta:focus-visible,
.follow-link:focus-visible,
.type-hub-card:focus-visible,
.type-nav-link:focus-visible,
.option-btn:focus-visible,
.code-input:focus-visible,
.lucky-item:focus-visible,
.site-nav-link:focus-visible,
.breadcrumb-nav a:focus-visible {
  outline: 2px solid var(--primary-dark);
  outline-offset: 2px;
}

/* ---- パンくずナビ(2026-09-05追加、pairs配下の詳細ページ用。JSON-LDのBreadcrumbListと対になる可視ナビ) ---- */
.breadcrumb-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
  font-size: 0.72rem;
  color: var(--text-sub);
  margin: 0 0 14px;
  line-height: 1.6;
}
.breadcrumb-nav a {
  color: var(--text-sub);
  text-decoration: none;
}
.breadcrumb-nav a:hover {
  color: var(--primary-dark);
  text-decoration: underline;
}
.breadcrumb-nav .crumb-current {
  color: var(--text);
  font-weight: 700;
}
.breadcrumb-nav .crumb-sep {
  color: var(--text-sub);
  opacity: 0.6;
}

/* ---- 招待CTAの無料バッジ(2026-09-05追加) ---- */
.lock-free-badge {
  display: inline-block;
  margin-bottom: 10px;
}

/* ---- pairs配下ページの英語向け注記(2026-09-05追加、日本語専用ページであることを明示) ---- */
.en-only-note {
  font-size: 0.74rem;
  color: var(--text-sub);
  font-style: italic;
}
