/* ====== 生産性向上ポテンシャルサーベイ - グラスモーフィズムUI ====== */
:root {
  --c-bg-1: #c7d2fe;
  --c-bg-2: #fbcfe8;
  --c-bg-3: #fde68a;
  --c-bg-4: #a5f3fc;
  --c-purple: #8b7cf8;
  --c-blue: #5ba8f5;
  --c-pink: #ff8fb1;
  --c-violet: #a78bfa;
  --c-mint: #34d3c8;
  --c-amber: #f5b85b;
  --c-rose: #ec6b9c;
  --c-indigo: #7c9eff;
  --c-text: #1f2042;
  --c-text-muted: #6b6f8d;
  --c-text-light: #9aa0bf;
  --c-glass-bg: rgba(255, 255, 255, 0.55);
  --c-glass-bg-strong: rgba(255, 255, 255, 0.78);
  --c-glass-border: rgba(255, 255, 255, 0.65);
  --c-glass-shadow: 0 24px 60px -12px rgba(70, 60, 160, 0.18), 0 4px 12px rgba(70, 60, 160, 0.08);
  --c-glass-inner: inset 0 1px 0 rgba(255, 255, 255, 0.9);
  --r-lg: 28px;
  --r-md: 18px;
  --r-sm: 12px;
  --easing: cubic-bezier(0.4, 0, 0.2, 1);
}

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  font-family: 'Inter', 'Hiragino Sans', 'Noto Sans JP', system-ui, -apple-system, sans-serif;
  color: var(--c-text);
  -webkit-font-smoothing: antialiased;
  font-feature-settings: 'palt';
}

body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 8% 12%, #d6c8ff 0%, transparent 38%),
    radial-gradient(circle at 92% 18%, #c7e0ff 0%, transparent 42%),
    radial-gradient(circle at 14% 88%, #ffd6ec 0%, transparent 40%),
    radial-gradient(circle at 88% 92%, #fff3c8 0%, transparent 36%),
    linear-gradient(135deg, #eef0ff 0%, #f6e8ff 50%, #fde8f1 100%);
  background-attachment: fixed;
  overflow-x: hidden;
  position: relative;
}

/* 背景の浮遊する球体 */
body::before, body::after {
  content: '';
  position: fixed;
  border-radius: 50%;
  filter: blur(40px);
  pointer-events: none;
  z-index: 0;
  opacity: 0.6;
}
body::before {
  width: 380px; height: 380px;
  top: -120px; right: -80px;
  background: radial-gradient(circle at 35% 35%, #b8a4ff 0%, #6b88ff 60%, transparent 75%);
  animation: floatA 18s ease-in-out infinite;
}
body::after {
  width: 320px; height: 320px;
  bottom: -100px; left: -60px;
  background: radial-gradient(circle at 35% 35%, #ffb6e1 0%, #c490ff 60%, transparent 75%);
  animation: floatB 22s ease-in-out infinite;
}
.orb {
  position: fixed; border-radius: 50%; filter: blur(50px);
  pointer-events: none; z-index: 0; opacity: 0.45;
}
.orb-1 { width: 260px; height: 260px; top: 40%; left: 35%;
  background: radial-gradient(circle, #fff7c2 0%, #ffd6a8 60%, transparent 80%);
  animation: floatA 26s ease-in-out infinite reverse; }
.orb-2 { width: 200px; height: 200px; top: 70%; right: 28%;
  background: radial-gradient(circle, #b9f5ec 0%, #76d6ff 60%, transparent 80%);
  animation: floatB 20s ease-in-out infinite; }

@keyframes floatA {
  0%, 100% { transform: translate(0,0) scale(1); }
  33% { transform: translate(30px, 40px) scale(1.05); }
  66% { transform: translate(-20px, 20px) scale(0.95); }
}
@keyframes floatB {
  0%, 100% { transform: translate(0,0) scale(1); }
  50% { transform: translate(-30px, -50px) scale(1.08); }
}

/* ====== レイアウト ====== */
.app {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 24px;
  padding: 24px;
  min-height: 100vh;
  width: 100%;
}

@media (max-width: 1280px) {
  .app { grid-template-columns: 230px 1fr; gap: 18px; padding: 18px; }
}
@media (max-width: 900px) {
  .app { grid-template-columns: 1fr; }
  .sidebar { display: none; }
}

/* ====== ガラスカード基本 ====== */
.glass {
  background: var(--c-glass-bg);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid var(--c-glass-border);
  border-radius: var(--r-lg);
  box-shadow: var(--c-glass-shadow), var(--c-glass-inner);
}
.glass-strong {
  background: var(--c-glass-bg-strong);
  backdrop-filter: blur(32px) saturate(190%);
  -webkit-backdrop-filter: blur(32px) saturate(190%);
}

/* ====== サイドバー ====== */
.sidebar {
  background: var(--c-glass-bg);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid var(--c-glass-border);
  border-radius: var(--r-lg);
  box-shadow: var(--c-glass-shadow), var(--c-glass-inner);
  padding: 24px 18px;
  position: sticky;
  top: 22px;
  height: calc(100vh - 44px);
  display: flex;
  flex-direction: column;
}
.brand {
  display: flex; flex-direction: column; align-items: flex-start; gap: 10px;
  padding: 4px 8px 18px;
  border-bottom: 1px solid rgba(180, 170, 220, 0.25);
  margin-bottom: 18px;
}
.brand-logo {
  width: 100%; max-width: 150px; height: auto;
  display: block;
  filter: drop-shadow(0 2px 6px rgba(70, 60, 160, 0.08));
}
.brand-tagline {
  font-size: 10px; font-weight: 700; color: var(--c-text-muted);
  letter-spacing: 0.12em; text-transform: uppercase;
  padding-left: 2px;
}

.nav-label { font-size: 10.5px; font-weight: 600; color: var(--c-text-light); letter-spacing: 0.08em; text-transform: uppercase; padding: 0 8px; margin: 4px 0 8px; }
.nav-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 3px; }
.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 9px 10px; border-radius: 12px;
  color: var(--c-text-muted);
  font-size: 12.5px; font-weight: 500;
  cursor: pointer;
  transition: all 0.2s var(--easing);
  position: relative;
}
.nav-item:hover { background: rgba(255,255,255,0.5); color: var(--c-text); }
.nav-item.active {
  background: linear-gradient(135deg, rgba(139,124,248,0.18), rgba(91,168,245,0.14));
  color: var(--c-text);
  font-weight: 600;
  box-shadow: inset 0 0 0 1px rgba(139,124,248,0.25);
}
.nav-item.done { color: var(--c-text); }
.nav-item.done .nav-dot { background: #34c789; }
.nav-dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: rgba(150, 150, 180, 0.35);
  flex-shrink: 0;
  transition: all 0.3s var(--easing);
}
.nav-item.active .nav-dot { background: var(--c-purple); box-shadow: 0 0 0 4px rgba(139,124,248,0.18); }
.nav-text { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-pct { font-size: 10.5px; color: var(--c-text-light); font-weight: 600; }

.sidebar-footer {
  margin-top: auto; padding-top: 16px;
  border-top: 1px solid rgba(180, 170, 220, 0.25);
  font-size: 10.5px; color: var(--c-text-light);
  display: flex; flex-direction: column; gap: 6px;
}
.sidebar-footer .save-status { display: flex; align-items: center; gap: 6px; }
.sidebar-footer .save-dot { width: 6px; height: 6px; border-radius: 50%; background: #34c789; box-shadow: 0 0 8px rgba(52,199,137,0.5); }

/* ====== メイン ====== */
.main {
  background: var(--c-glass-bg-strong);
  backdrop-filter: blur(32px) saturate(190%);
  -webkit-backdrop-filter: blur(32px) saturate(190%);
  border: 1px solid var(--c-glass-border);
  border-radius: var(--r-lg);
  box-shadow: var(--c-glass-shadow), var(--c-glass-inner);
  padding: 30px 28px 26px;
  min-height: calc(100vh - 44px);
  display: flex;
  flex-direction: column;
}

.main-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 24px; gap: 24px; }
.main-title { font-size: 28px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; margin: 0; }
.main-subtitle { font-size: 14px; color: var(--c-text-muted); margin-top: 6px; line-height: 1.5; }
.section-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 5px 11px; border-radius: 999px;
  background: rgba(139,124,248,0.12);
  font-size: 11px; font-weight: 700; color: var(--c-purple);
  letter-spacing: 0.04em; margin-bottom: 8px;
}
.section-pill .pip { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.range-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 999px;
  background: rgba(255,255,255,0.6);
  border: 1px solid rgba(180,170,220,0.3);
  font-size: 12px; font-weight: 500; color: var(--c-text-muted);
  white-space: nowrap;
}
.range-pill strong { color: var(--c-text); font-weight: 700; }

/* ====== 全体プログレスバー ====== */
.overall-progress {
  margin-bottom: 28px;
  padding: 18px 20px;
  background: linear-gradient(135deg, rgba(139,124,248,0.08), rgba(91,168,245,0.08));
  border-radius: var(--r-md);
  border: 1px solid rgba(180,170,220,0.18);
}
.overall-progress-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.overall-progress-head .label { font-size: 12px; font-weight: 600; color: var(--c-text-muted); letter-spacing: 0.04em; }
.overall-progress-head .value { font-size: 22px; font-weight: 800; color: var(--c-text); letter-spacing: -0.01em; }
.overall-progress-head .value small { font-weight: 500; font-size: 12px; color: var(--c-text-light); margin-left: 4px; }
.progress-bar { height: 8px; background: rgba(255,255,255,0.6); border-radius: 999px; overflow: hidden; box-shadow: inset 0 1px 2px rgba(0,0,0,0.04); }
.progress-bar-fill {
  height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, #8b7cf8 0%, #5ba8f5 50%, #ff8fb1 100%);
  background-size: 200% 100%;
  transition: width 0.6s var(--easing);
  box-shadow: 0 0 12px rgba(139,124,248,0.4);
  animation: shimmer 4s linear infinite;
}
@keyframes shimmer { 0% { background-position: 0% 0; } 100% { background-position: 200% 0; } }

/* ====== 質問カード ====== */
.q-card {
  padding: 22px 24px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(180,170,220,0.22);
  border-radius: var(--r-md);
  margin-bottom: 18px;
  transition: all 0.3s var(--easing);
}
.q-card:hover { background: rgba(255,255,255,0.7); border-color: rgba(139,124,248,0.25); }
.q-head { display: flex; align-items: baseline; gap: 12px; margin-bottom: 14px; }
.q-code {
  font-size: 11px; font-weight: 700; color: #fff; letter-spacing: 0.05em;
  background: linear-gradient(135deg, #8b7cf8, #5ba8f5);
  padding: 4px 9px; border-radius: 6px; flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(139,124,248,0.3);
}
.q-title { font-size: 16px; font-weight: 700; color: var(--c-text); letter-spacing: -0.01em; }
.q-title .opt { font-size: 11px; color: var(--c-text-light); font-weight: 500; margin-left: 6px; }
.q-prompt { font-size: 13px; line-height: 1.7; color: var(--c-text-muted); margin-bottom: 16px; }

/* リッカートグリッド */
.likert-grid { display: flex; flex-direction: column; gap: 6px; }
.likert-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.5);
  border: 1px solid transparent;
  transition: all 0.25s var(--easing);
}
.likert-row:hover { background: rgba(255,255,255,0.85); border-color: rgba(139,124,248,0.15); }
.likert-row.answered { background: rgba(255,255,255,0.85); border-color: rgba(139,124,248,0.22); }
.likert-text { font-size: 13px; line-height: 1.55; color: var(--c-text); }
.likert-options { display: flex; gap: 6px; }
.likert-opt {
  width: 44px; height: 44px; border-radius: 12px;
  display: grid; place-items: center;
  font-size: 15px; font-weight: 700;
  background: rgba(255,255,255,0.7);
  border: 1.5px solid rgba(180,170,220,0.3);
  color: var(--c-text-light);
  cursor: pointer;
  transition: all 0.2s var(--easing);
  position: relative;
  font-family: inherit;
}
.likert-opt:hover { transform: translateY(-2px); border-color: rgba(139,124,248,0.4); color: var(--c-text); box-shadow: 0 4px 12px rgba(139,124,248,0.15); }
.likert-opt.selected {
  background: linear-gradient(135deg, var(--c-purple), var(--c-blue));
  color: #fff; border-color: transparent;
  box-shadow: 0 6px 18px rgba(139,124,248,0.5);
  transform: translateY(-1px);
}

/* 凡例 (選択肢列の真上に配置) */
.likert-legend-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 18px;
  padding: 0 14px;
  margin-bottom: 10px;
}
.legend-labels {
  display: flex;
  justify-content: space-between;
  align-items: center;
  /* リッカートボタン5つ + ギャップ4つ分の幅 = 5*44 + 4*6 = 244px */
  width: 244px;
  font-size: 11px;
  color: var(--c-text-light);
  font-weight: 600;
}
.legend-l, .legend-r { display: inline-flex; align-items: center; gap: 4px; }

/* 数値入力 */
.num-row {
  display: grid;
  grid-template-columns: 1fr 200px;
  gap: 18px;
  align-items: center;
  padding: 12px 14px;
  border-radius: 12px;
  background: rgba(255,255,255,0.5);
  margin-bottom: 8px;
  border: 1px solid transparent;
  transition: all 0.25s var(--easing);
}
.num-row.answered { border-color: rgba(139,124,248,0.22); background: rgba(255,255,255,0.85); }
.num-row .label { font-size: 13px; line-height: 1.55; color: var(--c-text); }
.num-input-wrap { display: flex; align-items: center; gap: 8px; }
.num-input {
  flex: 1; padding: 10px 14px;
  border-radius: 10px; border: 1.5px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  font-size: 14px; font-weight: 600; color: var(--c-text);
  font-family: inherit;
  transition: all 0.2s var(--easing);
  text-align: right;
}
.num-input:focus { outline: none; border-color: var(--c-purple); box-shadow: 0 0 0 4px rgba(139,124,248,0.15); }
.num-input-unit { font-size: 12px; color: var(--c-text-muted); font-weight: 600; min-width: 24px; }

/* テキストエリア */
.textarea {
  width: 100%; min-height: 110px; resize: vertical;
  padding: 14px 16px; border-radius: 14px;
  border: 1.5px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.7);
  font-size: 13.5px; line-height: 1.7; color: var(--c-text);
  font-family: inherit;
  transition: all 0.2s var(--easing);
}
.textarea:focus { outline: none; border-color: var(--c-purple); box-shadow: 0 0 0 4px rgba(139,124,248,0.15); background: rgba(255,255,255,0.95); }
.textarea::placeholder { color: var(--c-text-light); }

/* テキスト入力 */
.text-input {
  width: 100%; padding: 12px 16px;
  border-radius: 12px; border: 1.5px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  font-size: 14px; color: var(--c-text);
  font-family: inherit;
  transition: all 0.2s var(--easing);
}
.text-input:focus { outline: none; border-color: var(--c-purple); box-shadow: 0 0 0 4px rgba(139,124,248,0.15); }

/* セレクト */
.select-wrap { position: relative; }
.select {
  width: 100%; padding: 12px 40px 12px 16px;
  border-radius: 12px; border: 1.5px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  font-size: 14px; color: var(--c-text);
  font-family: inherit;
  appearance: none;
  cursor: pointer;
  transition: all 0.2s var(--easing);
}
.select:focus { outline: none; border-color: var(--c-purple); box-shadow: 0 0 0 4px rgba(139,124,248,0.15); }
.select-wrap::after {
  content: ''; position: absolute; right: 16px; top: 50%; width: 8px; height: 8px;
  border-right: 2px solid var(--c-text-muted); border-bottom: 2px solid var(--c-text-muted);
  transform: translateY(-70%) rotate(45deg); pointer-events: none;
}

/* コンポジット */
.composite { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.composite .field { display: flex; flex-direction: column; gap: 6px; }
.composite .field label { font-size: 11.5px; font-weight: 600; color: var(--c-text-muted); letter-spacing: 0.02em; }

/* ====== ナビゲーションボタン ====== */
.nav-buttons { display: flex; justify-content: space-between; gap: 12px; margin-top: 24px; padding-top: 20px; border-top: 1px solid rgba(180,170,220,0.2); }
.btn {
  padding: 12px 28px; border-radius: 14px; border: none; cursor: pointer;
  font-size: 14px; font-weight: 600; font-family: inherit;
  display: inline-flex; align-items: center; gap: 8px;
  transition: all 0.25s var(--easing);
  letter-spacing: 0.01em;
}
.btn-primary {
  background: linear-gradient(135deg, #8b7cf8, #5ba8f5);
  color: #fff;
  box-shadow: 0 8px 22px rgba(139,124,248,0.4);
}
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgba(139,124,248,0.5); }
.btn-primary:disabled { opacity: 0.45; cursor: not-allowed; transform: none; }
.btn-ghost {
  background: rgba(255,255,255,0.6);
  color: var(--c-text);
  border: 1px solid rgba(180,170,220,0.3);
}
.btn-ghost:hover { background: rgba(255,255,255,0.85); }

/* ====== Welcome / Consent ====== */
.welcome { padding: 28px 8px 0; }
.welcome-logo {
  display: block;
  max-width: 220px; width: 100%; height: auto;
  margin: 0 0 24px;
  filter: drop-shadow(0 4px 12px rgba(70, 60, 160, 0.1));
}
.result-footer-logo {
  display: block;
  max-width: 160px; width: 100%; height: auto;
  margin: 24px auto 6px;
  opacity: 0.85;
}
.welcome-title { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; line-height: 1.25; margin: 6px 0 12px; background: linear-gradient(135deg, #6b5bd6 0%, #4584d6 50%, #d65b88 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.welcome-subtitle { font-size: 14.5px; color: var(--c-text-muted); line-height: 1.7; margin-bottom: 22px; }
.welcome-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 24px; }
.welcome-meta-item { padding: 16px 18px; background: rgba(255,255,255,0.55); border: 1px solid rgba(180,170,220,0.22); border-radius: 16px; }
.welcome-meta-item .lbl { font-size: 10.5px; font-weight: 700; color: var(--c-text-light); letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 4px; }
.welcome-meta-item .val { font-size: 18px; font-weight: 800; color: var(--c-text); }
.welcome-meta-item .val small { font-weight: 500; font-size: 12px; color: var(--c-text-muted); margin-left: 4px; }

.consent-text {
  padding: 20px 22px;
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(180,170,220,0.22);
  border-radius: 16px;
  font-size: 13px; line-height: 1.8; color: var(--c-text);
  margin-bottom: 18px;
  max-height: 320px; overflow-y: auto;
}
.consent-text h4 { font-size: 12.5px; font-weight: 700; margin: 14px 0 6px; color: var(--c-text); }
.consent-text h4:first-child { margin-top: 0; }
.consent-text p { margin: 0 0 8px; color: var(--c-text-muted); }

.consent-check {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 18px; border-radius: 14px;
  background: rgba(255,255,255,0.6);
  border: 1.5px solid rgba(180,170,220,0.3);
  cursor: pointer;
  transition: all 0.25s var(--easing);
  user-select: none;
}
.consent-check:hover { background: rgba(255,255,255,0.85); border-color: rgba(139,124,248,0.4); }
.consent-check.checked { background: linear-gradient(135deg, rgba(139,124,248,0.12), rgba(91,168,245,0.1)); border-color: var(--c-purple); }
.consent-check .checkbox {
  width: 22px; height: 22px; border-radius: 7px;
  border: 2px solid rgba(180,170,220,0.5);
  display: grid; place-items: center;
  background: rgba(255,255,255,0.6);
  transition: all 0.2s var(--easing);
  flex-shrink: 0;
}
.consent-check.checked .checkbox { background: linear-gradient(135deg, #8b7cf8, #5ba8f5); border-color: transparent; box-shadow: 0 4px 12px rgba(139,124,248,0.4); }
.consent-check .checkbox::after { content: ''; width: 6px; height: 11px; border-right: 2px solid #fff; border-bottom: 2px solid #fff; transform: rotate(45deg) scale(0); transition: transform 0.2s var(--easing); margin-bottom: 3px; }
.consent-check.checked .checkbox::after { transform: rotate(45deg) scale(1); }
.consent-check .label { font-size: 13.5px; font-weight: 600; color: var(--c-text); }

/* ====== ダッシュボード（右側） ====== */
.dashboard {
  display: flex; flex-direction: column; gap: 16px;
  position: sticky; top: 22px; height: calc(100vh - 44px); overflow-y: auto;
  padding-right: 4px;
}
.dashboard::-webkit-scrollbar { width: 5px; }
.dashboard::-webkit-scrollbar-thumb { background: rgba(180,170,220,0.3); border-radius: 999px; }

.dash-card {
  padding: 18px 20px;
  background: var(--c-glass-bg);
  backdrop-filter: blur(28px) saturate(180%);
  -webkit-backdrop-filter: blur(28px) saturate(180%);
  border: 1px solid var(--c-glass-border);
  border-radius: var(--r-md);
  box-shadow: var(--c-glass-shadow), var(--c-glass-inner);
  position: relative;
  overflow: hidden;
}
.dash-card-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.dash-card-title { font-size: 13px; font-weight: 700; color: var(--c-text); letter-spacing: -0.005em; }
.dash-card-sub { font-size: 10.5px; color: var(--c-text-light); font-weight: 500; }
.trend-up { color: #34c789; }
.trend-down { color: #f15a8c; }
.trend-pill { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; font-weight: 700; padding: 3px 8px; border-radius: 999px; background: rgba(52,199,137,0.12); color: #2ba874; }

/* スコアゲージ */
.gauge-card .score-row { display: flex; align-items: baseline; gap: 6px; margin-bottom: 10px; }
.gauge-card .score-num { font-size: 36px; font-weight: 800; letter-spacing: -0.025em; background: linear-gradient(135deg, #8b7cf8 0%, #5ba8f5 60%, #ff8fb1 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.gauge-card .score-max { font-size: 13px; color: var(--c-text-light); font-weight: 600; }
.gauge-card .gauge-svg { width: 100%; height: auto; }

/* レーダー */
.radar-wrap { width: 100%; aspect-ratio: 1; position: relative; }
.radar-wrap svg { width: 100%; height: 100%; }
.radar-poly { fill: rgba(139,124,248,0.22); stroke: #8b7cf8; stroke-width: 2; stroke-linejoin: round; transition: all 0.6s var(--easing); }
.radar-grid { fill: none; stroke: rgba(180,170,220,0.3); stroke-width: 1; }
.radar-axis { stroke: rgba(180,170,220,0.4); stroke-width: 1; }
.radar-label { font-size: 9.5px; font-weight: 600; fill: var(--c-text-muted); }
.radar-dot { fill: #8b7cf8; stroke: #fff; stroke-width: 2; }

/* セクション完了 */
.sec-list { display: flex; flex-direction: column; gap: 10px; }
.sec-row { display: flex; align-items: center; gap: 10px; }
.sec-row .sec-color { width: 8px; height: 24px; border-radius: 4px; flex-shrink: 0; }
.sec-row .sec-info { flex: 1; min-width: 0; }
.sec-row .sec-name { font-size: 11.5px; font-weight: 600; color: var(--c-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sec-row .sec-bar { height: 4px; background: rgba(180,170,220,0.2); border-radius: 999px; margin-top: 4px; overflow: hidden; }
.sec-row .sec-bar-fill { height: 100%; border-radius: 999px; transition: width 0.6s var(--easing); }
.sec-row .sec-pct { font-size: 11.5px; font-weight: 700; color: var(--c-text); min-width: 36px; text-align: right; }

/* KPI */
.kpi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kpi {
  padding: 14px;
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(180,170,220,0.18);
  border-radius: 14px;
  position: relative; overflow: hidden;
}
.kpi .lbl { font-size: 10.5px; font-weight: 600; color: var(--c-text-muted); letter-spacing: 0.04em; }
.kpi .val { font-size: 22px; font-weight: 800; color: var(--c-text); letter-spacing: -0.02em; margin-top: 2px; }
.kpi .val small { font-size: 11px; font-weight: 600; color: var(--c-text-light); margin-left: 2px; }
.kpi.purple { background: linear-gradient(135deg, rgba(139,124,248,0.18), rgba(139,124,248,0.06)); }
.kpi.blue   { background: linear-gradient(135deg, rgba(91,168,245,0.18), rgba(91,168,245,0.06)); }
.kpi.pink   { background: linear-gradient(135deg, rgba(255,143,177,0.18), rgba(255,143,177,0.06)); }
.kpi.mint   { background: linear-gradient(135deg, rgba(52,211,200,0.18), rgba(52,211,200,0.06)); }

/* インサイトリスト */
.insight-list { display: flex; flex-direction: column; gap: 8px; max-height: 220px; overflow-y: auto; }
.insight-list::-webkit-scrollbar { width: 4px; }
.insight-list::-webkit-scrollbar-thumb { background: rgba(180,170,220,0.3); border-radius: 999px; }
.insight {
  padding: 9px 12px;
  background: rgba(255,255,255,0.55);
  border-radius: 10px;
  font-size: 11.5px; line-height: 1.5;
  color: var(--c-text-muted);
  border-left: 3px solid var(--c-purple);
  display: flex; flex-direction: column; gap: 2px;
}
.insight .top { display: flex; gap: 8px; align-items: center; font-size: 10.5px; font-weight: 700; color: var(--c-text-light); }
.insight .top .tag { padding: 1px 6px; border-radius: 4px; background: rgba(139,124,248,0.15); color: var(--c-purple); font-size: 9.5px; letter-spacing: 0.04em; }
.insight .body { color: var(--c-text); font-weight: 500; }
.insight.empty { border-left-color: rgba(180,170,220,0.4); color: var(--c-text-light); font-style: italic; text-align: center; }

/* 棒グラフ */
.bars { display: flex; align-items: flex-end; gap: 8px; height: 120px; padding: 10px 4px 0; }
.bars .bar-col { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 6px; height: 100%; min-width: 0; }
.bars .bar-track { flex: 1; width: 100%; background: rgba(180,170,220,0.15); border-radius: 8px 8px 4px 4px; position: relative; overflow: hidden; }
.bars .bar-fill { position: absolute; bottom: 0; left: 0; right: 0; border-radius: 8px 8px 4px 4px; transition: height 0.6s var(--easing); box-shadow: 0 -4px 12px rgba(139,124,248,0.2); }
.bars .bar-label { font-size: 9.5px; font-weight: 600; color: var(--c-text-muted); }

/* アニメーション */
@keyframes fadeUp { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }
.fade-in { animation: fadeUp 0.4s var(--easing) both; }

/* 結果ページ */
.result-hero { text-align: center; padding: 28px 8px 14px; }
.result-hero h1 { font-size: 32px; font-weight: 800; letter-spacing: -0.02em; background: linear-gradient(135deg, #6b5bd6 0%, #4584d6 50%, #d65b88 100%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; margin: 12px 0 8px; }
.result-hero p { color: var(--c-text-muted); font-size: 14px; line-height: 1.7; }

.result-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 22px; }
.result-card {
  padding: 22px 24px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(180,170,220,0.22);
  border-radius: var(--r-md);
}
.result-card h3 { font-size: 14px; font-weight: 700; margin: 0 0 14px; color: var(--c-text); }

.section-scores { display: flex; flex-direction: column; gap: 10px; }
.section-score-row { display: grid; grid-template-columns: 130px 1fr 50px; gap: 10px; align-items: center; }
.section-score-row .name { font-size: 12px; font-weight: 600; color: var(--c-text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.section-score-row .bar { height: 8px; background: rgba(180,170,220,0.2); border-radius: 999px; overflow: hidden; }
.section-score-row .bar-fill { height: 100%; border-radius: 999px; transition: width 0.8s var(--easing); }
.section-score-row .val { font-size: 12.5px; font-weight: 700; color: var(--c-text); text-align: right; }

.completion-message {
  margin-top: 24px;
  padding: 24px;
  background: linear-gradient(135deg, rgba(139,124,248,0.12), rgba(255,143,177,0.1));
  border: 1px solid rgba(139,124,248,0.2);
  border-radius: var(--r-md);
  text-align: center;
}

/* ヘッダー右側のアバター（旧、互換用に残す） */
.user-pill { display: flex; align-items: center; gap: 8px; padding: 5px 14px 5px 5px; background: rgba(255,255,255,0.6); border: 1px solid rgba(180,170,220,0.25); border-radius: 999px; }
.user-avatar { width: 30px; height: 30px; border-radius: 50%; background: linear-gradient(135deg, #ff8fb1, #a78bfa); display: grid; place-items: center; color: #fff; font-size: 12px; font-weight: 700; }
.user-pill .user-name { font-size: 12px; font-weight: 600; color: var(--c-text); }

/* 回答リセットボタン (右上) */
.btn-reset {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.55);
  border: 1px solid rgba(216, 90, 130, 0.28);
  color: #c43a73;
  font-size: 12px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s var(--easing);
}
.btn-reset:hover {
  background: rgba(255, 90, 130, 0.1);
  border-color: rgba(216, 90, 130, 0.55);
  color: #b22c5d;
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(216, 90, 130, 0.18);
}
.btn-reset svg { flex-shrink: 0; }

/* ====== モード切替トグル ====== */
.mode-toggle {
  display: inline-flex;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(180,170,220,0.3);
  border-radius: 999px;
  padding: 4px;
  gap: 2px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.6);
}
.mode-btn {
  padding: 8px 14px;
  border: none;
  background: transparent;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: var(--c-text-muted);
  font-family: inherit;
  border-radius: 999px;
  transition: all 0.25s var(--easing);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}
.mode-btn:hover { color: var(--c-text); }
.mode-btn.active {
  background: linear-gradient(135deg, #8b7cf8, #5ba8f5);
  color: #fff;
  box-shadow: 0 6px 14px rgba(139,124,248,0.35);
}
.mode-btn svg { width: 14px; height: 14px; }

/* ====== ステップモード ====== */
.step-meta {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin: 8px 0 10px;
  font-size: 12px;
  color: var(--c-text-muted);
  font-weight: 600;
}
.step-meta .counter {
  background: rgba(139,124,248,0.12);
  color: var(--c-purple);
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
}
.step-card {
  max-width: 1400px;
  margin: 18px auto 24px;
  padding: 44px 56px 38px;
  background: rgba(255,255,255,0.72);
  border: 1px solid rgba(255,255,255,0.75);
  border-radius: 28px;
  box-shadow: 0 28px 60px -14px rgba(70,60,160,0.22), inset 0 1px 0 rgba(255,255,255,0.95);
  backdrop-filter: blur(30px) saturate(180%);
  -webkit-backdrop-filter: blur(30px) saturate(180%);
  position: relative;
  overflow: hidden;
  animation: stepIn 0.55s cubic-bezier(0.34, 1.4, 0.64, 1) both;
}
.step-card.has-mascot { overflow: visible; }

/* ステップカードのヘッダー（Q番号タグ または マスコット + 質問テキストを横並び） */
.step-q-header {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 28px;
}
.step-q-header .step-q-tag {
  flex: 0 0 auto;
  margin-bottom: 0;
}
.step-q-header .step-q-item-text {
  flex: 1;
  margin: 0;
  min-width: 0;
}

/* Q番号タグの代わりに使うインラインマスコット */
.mascot-inline {
  flex: 0 0 auto;
  width: 124px;
  height: auto;
  display: block;
  margin: -28px 0 0 -22px;
  transform-origin: bottom right;
  filter: drop-shadow(0 10px 20px rgba(70,60,160,0.18)) drop-shadow(0 2px 4px rgba(70,60,160,0.06));
  animation:
    mascotInlineIn 0.85s cubic-bezier(0.34, 1.56, 0.64, 1) 0.25s both,
    mascotInlineBob 5s ease-in-out 1.3s infinite;
}
@keyframes mascotInlineIn {
  from { opacity: 0; transform: scale(0.5) rotate(-26deg) translate(-20px, -10px); }
  to   { opacity: 1; transform: scale(1) rotate(-8deg) translate(0, 0); }
}
@keyframes mascotInlineBob {
  0%, 100% { transform: rotate(-8deg) translateY(0); }
  50%      { transform: rotate(-5deg) translateY(-5px); }
}
@media (max-width: 720px) {
  .step-q-header { gap: 12px; }
  .mascot-inline { width: 90px; margin: -18px 0 0 -12px; }
}

/* マスコットキャラクター — 透過PNGをカードの枠から大胆にはみ出させる */
.mascot {
  position: absolute;
  pointer-events: none;
  user-select: none;
  -webkit-user-drag: none;
  z-index: 5;
  filter: drop-shadow(0 10px 22px rgba(70, 60, 160, 0.18)) drop-shadow(0 2px 4px rgba(70, 60, 160, 0.06));
}
/* pos-r: 右側面、大半が外側、頭と指差しの腕だけカード内に覗く（反転で指がカード内を指す） */
.mascot.pos-r {
  width: 230px;
  bottom: 18px;
  right: -150px;
  transform: rotate(-6deg) scaleX(-1);
  animation: mascotInR 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s both, mascotBobR 5s ease-in-out 1.4s infinite;
}
.mascot.pos-l {
  width: 220px;
  bottom: 18px;
  left: -150px;
  transform: rotate(6deg);
  animation: mascotInL 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s both, mascotBobL 5s ease-in-out 1.4s infinite;
}
.mascot.pos-tr {
  width: 180px;
  top: -90px;
  right: -50px;
  transform: rotate(12deg);
  animation: mascotInTR 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s both, mascotBobTR 5s ease-in-out 1.4s infinite;
}
.mascot.pos-tl {
  width: 180px;
  top: -90px;
  left: -50px;
  transform: rotate(-12deg) scaleX(-1);
  animation: mascotInTL 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s both, mascotBobTL 5s ease-in-out 1.4s infinite;
}
.mascot.pos-br {
  width: 200px;
  bottom: -120px;
  right: -90px;
  transform: rotate(-8deg) scaleX(-1);
  animation: mascotInBR 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s both, mascotBobBR 5s ease-in-out 1.4s infinite;
}
.mascot.pos-bl {
  width: 200px;
  bottom: -120px;
  left: -90px;
  transform: rotate(8deg);
  animation: mascotInBL 0.9s cubic-bezier(0.34, 1.56, 0.64, 1) 0.4s both, mascotBobBL 5s ease-in-out 1.4s infinite;
}

@keyframes mascotInR {
  from { opacity: 0; transform: scale(0.5) rotate(-30deg) scaleX(-1) translate(80px, 40px); }
  to   { opacity: 1; transform: scale(1) rotate(-6deg) scaleX(-1) translate(0, 0); }
}
@keyframes mascotBobR {
  0%, 100% { transform: rotate(-6deg) scaleX(-1) translateY(0); }
  50%      { transform: rotate(-3deg) scaleX(-1) translateY(-8px); }
}
@keyframes mascotInL {
  from { opacity: 0; transform: scale(0.5) rotate(30deg) translate(-80px, 40px); }
  to   { opacity: 1; transform: scale(1) rotate(6deg) translate(0, 0); }
}
@keyframes mascotBobL {
  0%, 100% { transform: rotate(6deg) translateY(0); }
  50%      { transform: rotate(3deg) translateY(-8px); }
}
@keyframes mascotInTR {
  from { opacity: 0; transform: scale(0.5) rotate(34deg) translate(40px, -60px); }
  to   { opacity: 1; transform: scale(1) rotate(12deg) translate(0, 0); }
}
@keyframes mascotBobTR {
  0%, 100% { transform: rotate(12deg) translateY(0); }
  50%      { transform: rotate(9deg) translateY(-6px); }
}
@keyframes mascotInTL {
  from { opacity: 0; transform: scale(0.5) rotate(-34deg) scaleX(-1) translate(-40px, -60px); }
  to   { opacity: 1; transform: scale(1) rotate(-12deg) scaleX(-1) translate(0, 0); }
}
@keyframes mascotBobTL {
  0%, 100% { transform: rotate(-12deg) scaleX(-1) translateY(0); }
  50%      { transform: rotate(-9deg) scaleX(-1) translateY(-6px); }
}
@keyframes mascotInBR {
  from { opacity: 0; transform: scale(0.5) rotate(-30deg) scaleX(-1) translate(60px, 80px); }
  to   { opacity: 1; transform: scale(1) rotate(-8deg) scaleX(-1) translate(0, 0); }
}
@keyframes mascotBobBR {
  0%, 100% { transform: rotate(-8deg) scaleX(-1) translateY(0); }
  50%      { transform: rotate(-5deg) scaleX(-1) translateY(-7px); }
}
@keyframes mascotInBL {
  from { opacity: 0; transform: scale(0.5) rotate(30deg) translate(-60px, 80px); }
  to   { opacity: 1; transform: scale(1) rotate(8deg) translate(0, 0); }
}
@keyframes mascotBobBL {
  0%, 100% { transform: rotate(8deg) translateY(0); }
  50%      { transform: rotate(5deg) translateY(-7px); }
}

@media (max-width: 1080px) {
  .mascot.pos-r { width: 160px; right: -120px; bottom: 30px; }
  .mascot.pos-l { width: 160px; left: -120px; bottom: 30px; }
}
@media (max-width: 720px) {
  .mascot { display: none; }
}
.step-card::before {
  content: '';
  position: absolute;
  top: -80px; right: -80px;
  width: 240px; height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent, rgba(139,124,248,0.18)), transparent 70%);
  pointer-events: none;
  opacity: 0.5;
}
.step-q-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: var(--c-purple);
  background: rgba(139,124,248,0.12);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.step-q-prompt {
  font-size: 13px;
  color: var(--c-text-muted);
  line-height: 1.7;
  margin-bottom: 10px;
}
.step-q-item-text {
  font-size: 23px;
  font-weight: 700;
  color: var(--c-text);
  line-height: 1.55;
  letter-spacing: -0.012em;
  margin: 6px 0 32px;
}
.step-q-item-text.compact {
  font-size: 18px;
  margin-bottom: 22px;
}
.step-q-meta {
  font-size: 11.5px;
  color: var(--c-text-light);
  margin-bottom: 10px;
}

/* ステップ内のリッカート（5つの大きなボタン） */
.step-likert {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 12px;
}
.step-likert-btn {
  padding: 22px 10px 16px;
  background: rgba(255,255,255,0.7);
  border: 2px solid rgba(180,170,220,0.28);
  border-radius: 18px;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.25s var(--easing);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  text-align: center;
  color: var(--c-text);
}
.step-likert-btn:hover {
  border-color: rgba(139,124,248,0.5);
  transform: translateY(-3px);
  box-shadow: 0 12px 24px rgba(139,124,248,0.18);
}
.step-likert-btn.selected {
  background: linear-gradient(135deg, #8b7cf8, #5ba8f5);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 14px 28px rgba(139,124,248,0.45);
  transform: translateY(-2px);
}
.step-likert-btn .num {
  font-size: 26px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.02em;
}
.step-likert-btn .lbl {
  font-size: 10.5px;
  font-weight: 600;
  line-height: 1.4;
}

/* ステップ内の数値入力 */
.step-number {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 14px;
  padding: 18px 0;
}
.step-number input {
  width: 240px;
  text-align: center;
  font-size: 36px;
  font-weight: 800;
  letter-spacing: -0.02em;
  padding: 14px 18px;
  border-radius: 16px;
  border: 2px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  color: var(--c-text);
  font-family: inherit;
  transition: all 0.2s var(--easing);
}
.step-number input:focus {
  outline: none;
  border-color: var(--c-purple);
  box-shadow: 0 0 0 5px rgba(139,124,248,0.15);
}
.step-number .unit {
  font-size: 16px;
  font-weight: 700;
  color: var(--c-text-muted);
}

/* ステップ内のテキスト/テキストエリア/セレクト/コンポジット */
.step-text-input {
  width: 100%;
  padding: 16px 20px;
  border-radius: 14px;
  border: 2px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  font-size: 16px;
  color: var(--c-text);
  font-family: inherit;
  transition: all 0.2s var(--easing);
}
.step-text-input:focus {
  outline: none;
  border-color: var(--c-purple);
  box-shadow: 0 0 0 5px rgba(139,124,248,0.15);
}
.step-textarea {
  width: 100%;
  min-height: 160px;
  resize: vertical;
  padding: 16px 20px;
  border-radius: 14px;
  border: 2px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  font-size: 14.5px;
  line-height: 1.7;
  color: var(--c-text);
  font-family: inherit;
  transition: all 0.2s var(--easing);
}
.step-textarea:focus {
  outline: none;
  border-color: var(--c-purple);
  box-shadow: 0 0 0 5px rgba(139,124,248,0.15);
}
.step-select {
  width: 100%;
  padding: 14px 44px 14px 20px;
  border-radius: 14px;
  border: 2px solid rgba(180,170,220,0.3);
  background: rgba(255,255,255,0.85);
  font-size: 15px;
  color: var(--c-text);
  font-family: inherit;
  appearance: none;
  cursor: pointer;
  transition: all 0.2s var(--easing);
}
.step-select:focus {
  outline: none;
  border-color: var(--c-purple);
  box-shadow: 0 0 0 5px rgba(139,124,248,0.15);
}
.step-composite {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.step-composite .field { display: flex; flex-direction: column; gap: 6px; }
.step-composite .field label { font-size: 11.5px; font-weight: 700; color: var(--c-text-muted); }

/* ステップフッター（戻る/スキップ/次へ） */
.step-nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1400px;
  margin: 0 auto;
  padding: 14px 4px 0;
  gap: 12px;
}
.step-nav .right { display: flex; gap: 10px; align-items: center; }
.step-nav .hint {
  font-size: 11.5px;
  color: var(--c-text-light);
  font-weight: 500;
  margin-right: 4px;
}
.step-skip {
  background: transparent;
  border: none;
  color: var(--c-text-light);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  padding: 8px 14px;
  border-radius: 999px;
  font-family: inherit;
  transition: all 0.2s var(--easing);
}
.step-skip:hover {
  color: var(--c-text);
  background: rgba(255,255,255,0.5);
}

/* ステップ番号インジケーター */
.step-dots {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  max-width: 1400px;
  margin: 14px auto 0;
  padding: 0 4px;
  justify-content: center;
}
.step-dot {
  min-width: 28px;
  height: 28px;
  padding: 0 6px;
  border-radius: 999px;
  background: rgba(255,255,255,0.6);
  border: 1.5px solid rgba(180,170,220,0.35);
  color: var(--c-text-light);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: inherit;
  transition: all 0.25s var(--easing);
  letter-spacing: 0;
}
.step-dot:hover {
  border-color: var(--c-purple);
  color: var(--c-purple);
  transform: translateY(-1px);
}
.step-dot.answered {
  background: linear-gradient(135deg, rgba(139,124,248,0.85), rgba(91,168,245,0.85));
  border-color: transparent;
  color: #fff;
  box-shadow: 0 4px 10px rgba(139,124,248,0.25);
}
.step-dot.current {
  background: linear-gradient(135deg, #8b7cf8, #5ba8f5);
  border-color: transparent;
  color: #fff;
  min-width: 36px;
  height: 32px;
  font-size: 12.5px;
  box-shadow: 0 6px 16px rgba(139,124,248,0.45);
  transform: translateY(-1px);
}
.step-dot.answered.current {
  background: linear-gradient(135deg, #8b7cf8, #5ba8f5);
}
@media (max-width: 720px) {
  .step-dots { gap: 4px; }
  .step-dot { min-width: 24px; height: 24px; font-size: 10px; padding: 0 4px; }
  .step-dot.current { min-width: 30px; height: 28px; font-size: 11px; }
}

/* ステップアニメーション */
@keyframes stepIn {
  from { opacity: 0; transform: translateY(20px) scale(0.97); filter: blur(6px); }
  to { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}

@media (max-width: 720px) {
  .step-card { padding: 28px 22px; }
  .step-q-item-text { font-size: 18px; }
  .step-likert { grid-template-columns: repeat(5, 1fr); gap: 6px; }
  .step-likert-btn { padding: 14px 4px 10px; }
  .step-likert-btn .lbl { display: none; }
  .step-composite { grid-template-columns: 1fr; }
}

/* ====== ダッシュボードスロット（recap & result で使用） ====== */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: auto;
  gap: 18px;
  margin-top: 18px;
}

/* 各サイズのスパン (6カラムグリッド) */
.dashboard-slot[data-size="full"]   { grid-column: span 6; }
.dashboard-slot[data-size="lg"]     { grid-column: span 4; }
.dashboard-slot[data-size="md"]     { grid-column: span 3; }
.dashboard-slot[data-size="sm"]     { grid-column: span 2; }
.dashboard-slot[data-size="hero"]   { grid-column: span 6; grid-row: span 2; }

@media (max-width: 1300px) {
  .dashboard-grid { grid-template-columns: repeat(4, 1fr); }
  .dashboard-slot[data-size="full"]   { grid-column: span 4; }
  .dashboard-slot[data-size="lg"]     { grid-column: span 4; }
  .dashboard-slot[data-size="md"]     { grid-column: span 2; }
  .dashboard-slot[data-size="sm"]     { grid-column: span 2; }
  .dashboard-slot[data-size="hero"]   { grid-column: span 4; grid-row: span 1; }
}
@media (max-width: 800px) {
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-slot[data-size="full"],
  .dashboard-slot[data-size="lg"],
  .dashboard-slot[data-size="hero"]   { grid-column: span 2; }
  .dashboard-slot[data-size="md"]     { grid-column: span 2; }
  .dashboard-slot[data-size="sm"]     { grid-column: span 1; }
}
@media (max-width: 540px) {
  .dashboard-grid { grid-template-columns: 1fr; }
  .dashboard-slot { grid-column: span 1 !important; grid-row: span 1 !important; }
}

/* ====== ウィジェット高度化 - 共通 ====== */
.svg-gauge { width: 100%; max-width: 200px; height: auto; display: block; }
.svg-ring { width: 76px; height: 76px; display: block; }
.svg-heatmap { max-width: 100%; height: auto; display: block; }
.svg-heatmap .hm-cell {
  cursor: pointer;
  transition: filter 0.15s ease, transform 0.15s ease;
  transform-origin: center;
  transform-box: fill-box;
}
.svg-heatmap .hm-cell:hover {
  filter: brightness(1.1) drop-shadow(0 2px 6px rgba(70, 60, 160, 0.35));
  transform: scale(1.25);
}

/* ヒートマップツールチップ */
.heatmap-tooltip {
  position: fixed;
  z-index: 99999;
  pointer-events: none;
  max-width: 320px;
  padding: 11px 14px;
  background: linear-gradient(135deg, rgba(31, 32, 66, 0.96), rgba(46, 48, 96, 0.96));
  color: #fff;
  border-radius: 12px;
  font-size: 12px;
  line-height: 1.55;
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.28), 0 0 0 1px rgba(255,255,255,0.08);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.15s ease, transform 0.15s ease;
  letter-spacing: 0.005em;
}
.heatmap-tooltip.visible { opacity: 1; transform: translateY(0); }
.heatmap-tooltip .tip-head {
  display: flex; align-items: center; gap: 6px;
  margin-bottom: 4px;
}
.heatmap-tooltip .tip-code {
  font-size: 10px; font-weight: 800; letter-spacing: 0.06em;
  color: rgba(255,255,255,0.6);
  text-transform: uppercase;
}
.heatmap-tooltip .tip-reverse {
  font-size: 9.5px; font-weight: 700;
  padding: 1px 6px; border-radius: 4px;
  background: rgba(241, 90, 140, 0.25);
  color: #ffb8d2;
  letter-spacing: 0.04em;
}
.heatmap-tooltip .tip-text {
  font-weight: 600;
  color: #fff;
  margin-bottom: 6px;
}
.heatmap-tooltip .tip-score {
  font-size: 11px;
  color: rgba(255,255,255,0.7);
  font-weight: 500;
  border-top: 1px solid rgba(255,255,255,0.12);
  padding-top: 6px;
}
.heatmap-tooltip .tip-score strong {
  color: #fff;
  font-weight: 800;
  margin-left: 2px;
}
.svg-stacked { border-radius: 6px; overflow: hidden; }

.heatmap-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 8px; gap: 12px; flex-wrap: wrap;
}
.heatmap-title { font-size: 11px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; }
.heatmap-legend { display: inline-flex; align-items: center; gap: 6px; font-size: 10px; color: var(--c-text-light); }
.heatmap-legend .lg-dot { width: 8px; height: 8px; border-radius: 2.5px; display: inline-block; }
.heatmap-legend .lg-text { font-weight: 600; margin-right: 4px; }

.widget-insight {
  margin-top: 12px;
  padding: 10px 12px;
  background: rgba(255,255,255,0.5);
  border-left: 3px solid var(--accent, #8b7cf8);
  border-radius: 8px;
  font-size: 11.5px; line-height: 1.6; color: var(--c-text-muted);
}

/* ====== Sec1 (FULL HERO) ====== */
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1.3fr 1fr;
  gap: 18px;
  margin-bottom: 18px;
}
@media (max-width: 1100px) {
  .hero-grid { grid-template-columns: 1fr; }
}
.hero-pane {
  padding: 18px 20px;
  border-radius: 16px;
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(255,255,255,0.6);
  display: flex; flex-direction: column; gap: 8px;
}
.hero-tag { font-size: 10.5px; font-weight: 800; color: var(--accent); letter-spacing: 0.08em; text-transform: uppercase; }
.hero-title { font-size: 15px; font-weight: 700; color: var(--c-text); }
.hero-score { display: flex; align-items: baseline; gap: 4px; margin: 4px 0; }
.hero-score-num { font-size: 56px; font-weight: 800; line-height: 1; letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-score-max { font-size: 16px; font-weight: 600; color: var(--c-text-light); }
.hero-gauge { margin-top: -10px; }

.hero-time-pane { justify-content: space-between; }
.hero-time-tag { font-size: 11px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; }
.hero-time-main { display: flex; align-items: baseline; gap: 8px; }
.hero-time-num { font-size: 64px; font-weight: 800; letter-spacing: -0.035em; line-height: 1; color: var(--c-text); }
.hero-time-unit { font-size: 14px; font-weight: 700; color: var(--c-text-muted); }
.hero-time-projections { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 8px; }
.time-proj { padding: 10px 12px; border-radius: 12px; background: rgba(255,255,255,0.6); border: 1px solid rgba(255,255,255,0.7); }
.time-proj .lbl { display: block; font-size: 10px; font-weight: 700; color: var(--c-text-light); letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 2px; }
.time-proj .val { font-size: 18px; font-weight: 800; color: var(--c-text); letter-spacing: -0.02em; }
.time-proj .val small { font-size: 10px; font-weight: 600; color: var(--c-text-muted); margin-left: 2px; }

.hero-pane-title { font-size: 11.5px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; margin-bottom: 4px; }
.breakdown-stack { margin-bottom: 6px; }
.breakdown-rows { display: flex; flex-direction: column; gap: 6px; }
.bd-row { display: flex; align-items: center; gap: 10px; }
.bd-dot { width: 8px; height: 8px; border-radius: 2.5px; flex-shrink: 0; }
.bd-label { flex: 1; font-size: 11.5px; color: var(--c-text-muted); font-weight: 600; }
.bd-val { font-size: 13.5px; font-weight: 800; color: var(--c-text); }
.bd-val small { font-size: 10px; font-weight: 600; color: var(--c-text-muted); margin-left: 2px; }

.hero-footer {
  display: grid;
  grid-template-columns: 2.2fr 1fr;
  gap: 18px;
}
@media (max-width: 1100px) {
  .hero-footer { grid-template-columns: 1fr; }
}
.hero-heatmap-pane, .hero-insight-pane {
  padding: 16px 18px;
  border-radius: 14px;
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(255,255,255,0.6);
}
.insight-tag { font-size: 10px; font-weight: 800; color: var(--accent); letter-spacing: 0.1em; margin-bottom: 6px; }
.insight-body { font-size: 12.5px; line-height: 1.65; color: var(--c-text); font-weight: 500; }

/* ====== sm カード共通 ====== */
.sm-score-block {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 4px 6px;
}
.sm-score-num { font-size: 36px; font-weight: 800; letter-spacing: -0.025em; line-height: 1; }
.sm-score-num small { font-size: 12px; font-weight: 600; color: var(--c-text-light); -webkit-text-fill-color: var(--c-text-light); }
.sm-score-label { font-size: 11px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; text-align: right; max-width: 120px; line-height: 1.4; }
.sm-score-gauge { width: 110px; flex-shrink: 0; }
.sm-stat-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.sm-ring { display: flex; flex-direction: column; align-items: center; gap: 4px; flex-shrink: 0; }
.sm-ring-label { font-size: 10px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; }
.sm-mini-stats { flex: 1; display: flex; flex-direction: column; gap: 6px; }
.mini-stat { display: flex; justify-content: space-between; align-items: baseline; padding: 6px 10px; border-radius: 8px; background: rgba(255,255,255,0.55); }
.mini-stat .lbl { font-size: 10.5px; font-weight: 600; color: var(--c-text-muted); }
.mini-stat .val { font-size: 16px; font-weight: 800; color: var(--c-text); letter-spacing: -0.01em; }
.mini-stat .val small { font-size: 10px; color: var(--c-text-light); margin-left: 2px; }

.sm-stat-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 6px 0; }
.sm-card {
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.65);
}
.sm-card-lbl { font-size: 10px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; }
.sm-card-val { font-size: 18px; font-weight: 800; color: var(--c-text); letter-spacing: -0.02em; margin: 2px 0 6px; }
.sm-card-val small { font-size: 10.5px; font-weight: 600; color: var(--c-text-light); margin-left: 2px; }
.sm-card-val.good { color: #2ba874; }
.sm-card-val.bad  { color: #d65b88; }
.sm-card-bar { height: 4px; background: rgba(180,170,220,0.18); border-radius: 999px; overflow: hidden; }
.sm-card-bar-fill { height: 100%; border-radius: 999px; transition: width 0.6s ease; }

.sm-heatmap-block { padding: 8px 0; }

.ring-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; padding: 8px 0; }
.ring-cell { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 8px 6px; background: rgba(255,255,255,0.5); border-radius: 12px; }
.ring-label { font-size: 10.5px; font-weight: 700; color: var(--c-text-muted); }

/* ====== lg カード ====== */
.lg-grid { display: grid; grid-template-columns: 1fr 1.4fr; gap: 18px; margin-bottom: 14px; }
@media (max-width: 900px) { .lg-grid { grid-template-columns: 1fr; } }

.lg-score-pane {
  padding: 16px 18px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(255,255,255,0.6), rgba(255,255,255,0.4));
  border: 1px solid rgba(255,255,255,0.6);
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  text-align: center;
}
.lg-score-num { font-size: 48px; font-weight: 800; letter-spacing: -0.03em; line-height: 1; }
.lg-score-num small { font-size: 14px; font-weight: 600; color: var(--c-text-light); -webkit-text-fill-color: var(--c-text-light); }
.lg-score-label { font-size: 11.5px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; }

.lg-bars-pane {
  padding: 14px 18px;
  border-radius: 14px;
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(255,255,255,0.6);
  display: flex; flex-direction: column; gap: 10px;
}
.lg-bars-title { font-size: 11px; font-weight: 700; color: var(--c-text-muted); letter-spacing: 0.04em; }
.sub-bar-row { display: flex; flex-direction: column; gap: 4px; }
.sub-bar-head { display: flex; align-items: baseline; gap: 8px; }
.sub-bar-name { flex: 1; font-size: 12px; font-weight: 700; color: var(--c-text); }
.sub-bar-val { font-size: 13px; font-weight: 800; color: var(--c-text); letter-spacing: -0.01em; }
.sub-bar-val small { font-size: 10px; font-weight: 600; color: var(--c-text-light); }
.sub-badge { font-size: 9.5px; font-weight: 800; padding: 1px 6px; border-radius: 4px; letter-spacing: 0.06em; }
.sub-badge.top { background: rgba(52,199,137,0.18); color: #2ba874; }
.sub-badge.low { background: rgba(241,90,140,0.16); color: #d65b88; }
.sub-bar-track { height: 8px; background: rgba(180,170,220,0.16); border-radius: 999px; overflow: hidden; }
.sub-bar-fill { height: 100%; border-radius: 999px; transition: width 0.6s ease; }

.lg-footer {
  padding: 14px 18px;
  border-radius: 14px;
  background: rgba(255,255,255,0.5);
  border: 1px solid rgba(255,255,255,0.6);
}

/* ====== Profile (sec8) ====== */
.profile-hero { padding: 8px 0 12px; border-bottom: 1px solid rgba(180,170,220,0.2); margin-bottom: 12px; }
.profile-name { font-size: 18px; font-weight: 800; letter-spacing: -0.01em; color: var(--c-text); margin-bottom: 6px; }
.profile-tags { display: flex; gap: 4px; flex-wrap: wrap; }
.profile-tag {
  font-size: 10.5px; font-weight: 700;
  padding: 3px 8px; border-radius: 6px;
  background: var(--accent-bg);
  color: var(--accent);
  letter-spacing: 0.02em;
}
.profile-stats { display: grid; gap: 8px; margin-bottom: 12px; }
.profile-stat { display: flex; justify-content: space-between; align-items: baseline; padding: 8px 12px; background: rgba(255,255,255,0.55); border-radius: 10px; }
.profile-stat .lbl { font-size: 11px; color: var(--c-text-muted); font-weight: 600; }
.profile-stat .val { font-size: 16px; font-weight: 800; color: var(--c-text); letter-spacing: -0.01em; }
.profile-stat .val small { font-size: 10.5px; color: var(--c-text-light); margin-left: 2px; }
.profile-respondent { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: linear-gradient(135deg, var(--accent-bg), transparent); border-radius: 10px; }
.profile-avatar { width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-size: 14px; font-weight: 700; background: linear-gradient(135deg, var(--accent), var(--accent2)); flex-shrink: 0; }
.resp-name { font-size: 13px; font-weight: 700; color: var(--c-text); }
.resp-meta { font-size: 11px; color: var(--c-text-muted); }

.dashboard-slot {
  position: relative;
  border-radius: 22px;
  --accent: #8b7cf8;
  --accent2: #5ba8f5;
}
.dashboard-slot.unlocked .widget {
  margin: 0;
}
/* 完成済みスロット: ウィジェット自身に box-shadow で枠+グロー（カード境界にぴったり） */
.dashboard-slot.unlocked.just-completed { position: relative; }
@keyframes justCompletedPulse {
  0%   {
    box-shadow:
      0 12px 30px -10px rgba(70,60,160,0.18),
      inset 0 1px 0 rgba(255,255,255,0.95),
      0 0 0 0 var(--accent),
      0 0 0 0 var(--accent-glow);
  }
  35%  {
    box-shadow:
      0 12px 30px -10px rgba(70,60,160,0.18),
      inset 0 1px 0 rgba(255,255,255,0.95),
      0 0 0 3px var(--accent),
      0 0 40px 12px var(--accent-glow);
  }
  100% {
    box-shadow:
      0 12px 30px -10px rgba(70,60,160,0.18),
      inset 0 1px 0 rgba(255,255,255,0.95),
      0 0 0 0 transparent,
      0 0 0 0 transparent;
  }
}

/* 未回答スロット: すりガラス + 回答ボタン */
.dashboard-slot.locked {
  cursor: pointer;
  overflow: hidden;
  border-radius: 22px;
  transition: transform 0.3s var(--easing), box-shadow 0.3s var(--easing);
  isolation: isolate;
}
.dashboard-slot.locked:hover {
  transform: translateY(-3px);
}
.dashboard-slot.locked .widget {
  margin: 0;
  filter: blur(3px) saturate(0.5);
  opacity: 0.55;
  pointer-events: none;
  transform: scale(1.02);
}
.locked-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(255,255,255,0.45), rgba(255,255,255,0.65));
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  border-radius: 22px;
  display: flex; flex-direction: column;
  justify-content: center; align-items: center;
  gap: 14px;
  text-align: center;
  padding: 24px 18px;
  border: 1px solid rgba(255,255,255,0.6);
  z-index: 1;
}
.locked-overlay .lock-icon {
  width: 38px; height: 38px;
  border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  color: #fff;
  box-shadow: 0 8px 18px var(--accent-glow);
}
.locked-info { display: flex; flex-direction: column; gap: 3px; }
.locked-tag {
  font-size: 10px; font-weight: 800; letter-spacing: 0.12em;
  color: var(--accent); text-transform: uppercase;
}
.locked-name { font-size: 14.5px; font-weight: 700; color: var(--c-text); letter-spacing: -0.005em; }
.locked-desc { font-size: 11.5px; color: var(--c-text-muted); line-height: 1.55; max-width: 220px; }
.btn-sm {
  padding: 9px 18px; font-size: 12px; border-radius: 11px;
  display: inline-flex; align-items: center; gap: 6px;
}
.btn-sm svg { width: 13px; height: 13px; }
.dashboard-slot.locked:hover .locked-overlay .btn-primary {
  box-shadow: 0 12px 28px var(--accent-glow);
  transform: translateY(-1px);
}

/* スロット出現アニメ（recap phase 3 のみスタッガー） */
.phase-3 .dashboard-slot { animation: slotFadeIn 0.5s var(--easing) both; }
.phase-3 .dashboard-slot:nth-child(1)  { animation-delay: 0.10s; }
.phase-3 .dashboard-slot:nth-child(2)  { animation-delay: 0.18s; }
.phase-3 .dashboard-slot:nth-child(3)  { animation-delay: 0.26s; }
.phase-3 .dashboard-slot:nth-child(4)  { animation-delay: 0.34s; }
.phase-3 .dashboard-slot:nth-child(5)  { animation-delay: 0.42s; }
.phase-3 .dashboard-slot:nth-child(6)  { animation-delay: 0.50s; }
.phase-3 .dashboard-slot:nth-child(7)  { animation-delay: 0.58s; }
.phase-3 .dashboard-slot:nth-child(8)  { animation-delay: 0.66s; }
.phase-3 .dashboard-slot.just-completed { animation: slotJustCompletedHolder 0.4s 0s both; }
@keyframes slotFadeIn {
  from { opacity: 0; transform: translateY(20px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes slotJustCompletedHolder {
  /* スナップインを待つために枠だけ最初から表示 */
  from { opacity: 0; transform: translateY(0) scale(1); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.phase-3 .dashboard-slot.unlocked.just-completed .widget {
  animation: slotSnapIn 0.85s cubic-bezier(0.34, 1.56, 0.64, 1) 0.45s both,
             justCompletedPulse 2.4s ease-out 1.35s both;
}

/* ====== Recap (セクション完了後の中間画面) ====== */
.recap-hero {
  text-align: center;
  padding: 28px 8px 8px;
}
@keyframes heroIn {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ====== Recap フェーズ管理 ====== */
.recap-screen {
  position: relative;
  min-height: 480px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.recap-phase {
  animation: phaseEnter 0.55s cubic-bezier(0.34, 1.4, 0.64, 1) both;
}
@keyframes phaseEnter {
  from { opacity: 0; transform: translateY(20px) scale(0.97); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.phase-1 { text-align: center; padding: 80px 20px 40px; }
.phase-2 { text-align: center; padding: 40px 20px; }
.phase-3 { padding: 16px 0 0; }

.recap-skip {
  text-align: center;
  margin-top: 16px;
  height: 28px;
}
.recap-skip-btn {
  background: transparent;
  border: none;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: var(--c-text-light);
  cursor: pointer;
  padding: 6px 14px;
  border-radius: 999px;
  transition: all 0.2s var(--easing);
}
.recap-skip-btn:hover { color: var(--c-text); background: rgba(255,255,255,0.5); }

/* Phase 2 スポットライト */
.phase-2 .recap-new-wrap {
  margin: 0 auto;
  max-width: 600px;
  animation: phaseEnter 0.55s cubic-bezier(0.34, 1.4, 0.64, 1) both;
}

/* Phase 3 ダッシュボード */
.phase-3 .dashboard-stage-title {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 18px;
  padding: 0 4px;
}
.phase-3 .dashboard-stage-title h3 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--c-text);
}
.phase-3 .dashboard-stage-title .dashboard-progress {
  background: rgba(139,124,248,0.14);
  color: var(--c-purple);
  padding: 5px 11px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
}

/* Phase 3 で完了スロットがスナップイン (実際のアニメーションはより詳細な
   .phase-3 .dashboard-slot.unlocked.just-completed .widget セレクタで定義) */
@keyframes slotSnapIn {
  0%   { opacity: 0; transform: scale(2) translateY(-220px) rotate(-2deg); filter: blur(14px); }
  40%  { opacity: 1; }
  70%  { transform: scale(1.06) translateY(0) rotate(1deg); filter: blur(0); }
  85%  { transform: scale(0.98) rotate(-0.5deg); }
  100% { transform: scale(1) rotate(0); }
}

/* Phase 3 のナビゲーションは遅れて出現 */
.recap-nav-late {
  opacity: 0;
  transform: translateY(20px);
  pointer-events: none;
}
.recap-nav-late.shown {
  animation: navIn 0.6s var(--easing) both;
}
@keyframes navIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
.recap-check {
  width: 86px; height: 86px;
  margin: 0 auto 14px;
  border-radius: 50%;
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--accent, #8b7cf8), var(--accent2, #5ba8f5));
  box-shadow: 0 16px 36px var(--accent-glow, rgba(139,124,248,0.45)), inset 0 1px 0 rgba(255,255,255,0.3);
  animation: pop 0.6s cubic-bezier(0.34, 1.56, 0.64, 1) both, bob 4s ease-in-out 0.6s infinite;
  color: #fff;
}
.recap-check svg { width: 42px; height: 42px; filter: drop-shadow(0 2px 4px rgba(0,0,0,0.15)); }
.recap-section-num {
  font-size: 11px; font-weight: 800; letter-spacing: 0.18em;
  color: var(--accent, #8b7cf8);
  margin-bottom: 8px;
  text-transform: uppercase;
}
.recap-title {
  font-size: 28px; font-weight: 800; letter-spacing: -0.02em; margin: 0 0 8px;
  background: linear-gradient(135deg, var(--accent, #8b7cf8), var(--accent2, #5ba8f5));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.recap-subtitle { font-size: 14px; color: var(--c-text-muted); line-height: 1.7; }

.recap-new-wrap {
  position: relative;
  max-width: 600px;
  margin: 28px auto 36px;
  padding: 32px 24px 28px;
  border-radius: 24px;
  background:
    radial-gradient(circle at 50% 0%, var(--accent-bg, rgba(139,124,248,0.16)) 0%, transparent 70%),
    rgba(255,255,255,0.4);
  border: 1px dashed var(--accent-border, rgba(139,124,248,0.4));
  text-align: center;
  overflow: hidden;
}
.recap-new-wrap .widget { animation: none; }
.recap-new-wrap::before {
  content: ''; position: absolute; inset: 0;
  background: radial-gradient(circle at 30% 0%, var(--accent-bg, rgba(139,124,248,0.18)), transparent 50%);
  pointer-events: none;
  animation: glowSweep 3s ease-in-out infinite;
}
.recap-new-label {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px; border-radius: 999px;
  background: linear-gradient(135deg, var(--accent, #8b7cf8), var(--accent2, #5ba8f5));
  color: #fff; font-size: 11px; font-weight: 800; letter-spacing: 0.08em;
  margin-bottom: 18px;
  box-shadow: 0 8px 20px var(--accent-glow, rgba(139,124,248,0.4));
  animation: pulse 2s ease-in-out infinite;
}
.recap-new-label .pip { width: 6px; height: 6px; border-radius: 50%; background: #fff; }

.recap-acc-title {
  font-size: 12.5px; font-weight: 700; color: var(--c-text); letter-spacing: 0.04em;
  text-transform: uppercase;
  display: flex; align-items: center; gap: 10px;
  margin: 0 0 16px;
}
.recap-acc-title::after {
  content: ''; flex: 1; height: 1px;
  background: linear-gradient(90deg, rgba(180,170,220,0.4), transparent);
}
.recap-acc-count {
  background: rgba(139,124,248,0.14);
  color: var(--c-purple);
  padding: 2px 8px; border-radius: 999px;
  font-size: 10.5px; font-weight: 700;
}

.widget-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px;
}
@media (max-width: 720px) { .widget-grid { grid-template-columns: 1fr; } }

/* ====== Widget (各セクションのダッシュボードパーツ) ====== */
.widget {
  position: relative;
  padding: 22px 22px 20px;
  border-radius: 22px;
  background: rgba(255,255,255,0.65);
  border: 1px solid rgba(255,255,255,0.7);
  box-shadow: 0 12px 30px -10px rgba(70,60,160,0.18), inset 0 1px 0 rgba(255,255,255,0.95);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  overflow: hidden;
  transition: transform 0.3s var(--easing), box-shadow 0.3s var(--easing);
  --accent: #8b7cf8;
  --accent2: #5ba8f5;
}
.widget:hover { transform: translateY(-2px); box-shadow: 0 20px 40px -10px rgba(70,60,160,0.25), inset 0 1px 0 rgba(255,255,255,0.95); }
.widget::before {
  content: ''; position: absolute; top: -40px; right: -40px;
  width: 140px; height: 140px; border-radius: 50%;
  background: radial-gradient(circle, var(--accent), transparent 70%);
  opacity: 0.15; pointer-events: none;
}
.widget-new {
  animation: widgetIn 0.7s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}
.widget-stagger { animation: fadeInUp 0.5s var(--easing) both; }

.widget-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 14px; gap: 10px; position: relative; }
.widget-tag {
  font-size: 9.5px; font-weight: 800; letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 3px 9px; border-radius: 6px;
  background: var(--accent-bg);
  color: var(--accent);
}
.widget-title { font-size: 14px; font-weight: 700; color: var(--c-text); letter-spacing: -0.01em; line-height: 1.35; margin-top: 4px; }
.widget-score-big {
  font-size: 38px; font-weight: 800; line-height: 1;
  letter-spacing: -0.025em;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.widget-score-big small { font-size: 13px; font-weight: 600; color: var(--c-text-light); margin-left: 4px; -webkit-text-fill-color: var(--c-text-light); }
.widget-score-row { display: flex; align-items: baseline; gap: 8px; margin-bottom: 12px; }
.widget-score-pill {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 999px;
  background: var(--accent-bg);
  color: var(--accent);
  font-size: 10.5px; font-weight: 700;
}

.widget-section-mini {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px;
}
.widget-stat {
  padding: 10px 12px; border-radius: 12px;
  background: rgba(255,255,255,0.55);
  border: 1px solid rgba(255,255,255,0.7);
}
.widget-stat .lbl { font-size: 10px; font-weight: 600; color: var(--c-text-muted); letter-spacing: 0.04em; line-height: 1.3; }
.widget-stat .val { font-size: 20px; font-weight: 800; color: var(--c-text); letter-spacing: -0.02em; margin-top: 2px; line-height: 1; }
.widget-stat .val small { font-size: 10.5px; font-weight: 600; color: var(--c-text-light); margin-left: 2px; }

.widget-bar {
  display: flex; flex-direction: column; gap: 3px; margin-bottom: 6px;
}
.widget-bar-row { display: flex; justify-content: space-between; font-size: 10.5px; color: var(--c-text-muted); font-weight: 600; }
.widget-bar-track { height: 5px; background: rgba(180,170,220,0.18); border-radius: 999px; overflow: hidden; }
.widget-bar-fill { height: 100%; border-radius: 999px; background: linear-gradient(90deg, var(--accent), var(--accent2)); transition: width 0.6s var(--easing); }

.widget-empty {
  font-size: 11px; color: var(--c-text-light); font-style: italic;
  padding: 8px 4px; line-height: 1.5;
}

/* ミニゲージ */
.widget-gauge { position: relative; width: 100%; aspect-ratio: 2/1; }
.widget-gauge svg { width: 100%; height: 100%; display: block; }

/* セクション別の特殊レイアウト */
.widget-time {
  display: flex; align-items: baseline; gap: 8px;
  padding: 12px 14px; border-radius: 14px;
  background: linear-gradient(135deg, var(--accent-bg) 0%, transparent 100%);
  margin: 10px 0;
}
.widget-time .num { font-size: 28px; font-weight: 800; color: var(--accent); letter-spacing: -0.02em; }
.widget-time .unit { font-size: 12px; color: var(--c-text-muted); font-weight: 600; }
.widget-time .desc { font-size: 11px; color: var(--c-text-light); margin-left: auto; line-height: 1.4; text-align: right; }

/* レーダーミニ */
.widget-radar { width: 100%; aspect-ratio: 1; max-height: 160px; margin: 0 auto; }

/* プロフィールカード（最終セクション） */
.widget-profile { display: flex; flex-direction: column; gap: 8px; }
.widget-profile-item { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid rgba(180,170,220,0.18); font-size: 12px; }
.widget-profile-item:last-child { border-bottom: none; }
.widget-profile-item .k { color: var(--c-text-muted); font-weight: 600; }
.widget-profile-item .v { color: var(--c-text); font-weight: 700; }

/* インサイトテキスト */
.widget-insight {
  font-size: 11.5px; line-height: 1.55; color: var(--c-text-muted);
  padding: 10px 12px; margin-top: 10px;
  background: rgba(255,255,255,0.55);
  border-left: 3px solid var(--accent);
  border-radius: 8px;
}

/* リッカートサマリー（5段階分布） */
.likert-distribution { display: flex; gap: 4px; height: 32px; align-items: flex-end; margin-top: 6px; }
.likert-distribution .bar { flex: 1; border-radius: 4px 4px 2px 2px; min-height: 4px; transition: height 0.5s var(--easing); background: linear-gradient(180deg, var(--accent), var(--accent2)); }
.likert-distribution .lbls { display: flex; justify-content: space-between; font-size: 9.5px; color: var(--c-text-light); margin-top: 4px; font-weight: 600; }

/* 累積ダッシュボード見出しのインジケーターアニメ */
.dashboard-builder {
  margin-top: 28px;
  padding-top: 28px;
  border-top: 1px solid rgba(180,170,220,0.25);
}
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* アニメーション */
@keyframes pop {
  0% { transform: scale(0.4); opacity: 0; }
  70% { transform: scale(1.1); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-4px); }
}
@keyframes pulse {
  0%, 100% { box-shadow: 0 8px 20px var(--accent-glow, rgba(139,124,248,0.4)); }
  50% { box-shadow: 0 8px 28px var(--accent-glow, rgba(139,124,248,0.6)); }
}
@keyframes glowSweep {
  0%, 100% { opacity: 0.6; }
  50% { opacity: 1; }
}
@keyframes widgetIn {
  0% { opacity: 0; transform: scale(0.7) translateY(20px); filter: blur(8px); }
  60% { opacity: 1; transform: scale(1.04) translateY(-3px); filter: blur(0); }
  100% { opacity: 1; transform: scale(1) translateY(0); filter: blur(0); }
}
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* スタッガー遅延 (累積ウィジェット用) */
.widget-stagger:nth-child(1) { animation-delay: 0.05s; }
.widget-stagger:nth-child(2) { animation-delay: 0.10s; }
.widget-stagger:nth-child(3) { animation-delay: 0.15s; }
.widget-stagger:nth-child(4) { animation-delay: 0.20s; }
.widget-stagger:nth-child(5) { animation-delay: 0.25s; }
.widget-stagger:nth-child(6) { animation-delay: 0.30s; }
.widget-stagger:nth-child(7) { animation-delay: 0.35s; }
.widget-stagger:nth-child(8) { animation-delay: 0.40s; }

/* 結果ページのウィジェットグリッドは3列 */
.result-widgets {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px;
  margin-top: 24px;
}
@media (max-width: 1080px) { .result-widgets { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 720px) { .result-widgets { grid-template-columns: 1fr; } }

/* スパークル装飾 */
.sparkles {
  position: absolute; inset: 0; pointer-events: none; overflow: hidden;
}
.sparkle {
  position: absolute; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent, #8b7cf8); opacity: 0;
  animation: sparkle 1.6s ease-out forwards;
}
@keyframes sparkle {
  0% { opacity: 0; transform: scale(0); }
  20% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(0.5) translateY(-30px); }
}

/* ====== モバイル簡易表示 ====== */
@media (max-width: 900px) {
  .main { padding: 22px 18px; }
  .composite { grid-template-columns: 1fr; }
  .num-row { grid-template-columns: 1fr; gap: 8px; }
  .likert-row { grid-template-columns: 1fr; gap: 10px; }
  .likert-options { justify-content: stretch; }
  .likert-opt { flex: 1; }
  .welcome-meta { grid-template-columns: 1fr; }
  .result-summary { grid-template-columns: 1fr; }
  .widget-grid { grid-template-columns: 1fr; }
}
