/* =========================================================
   WANTYPE — スタイルシート
   ========================================================= */

:root {
  --ink: #343c4b;
  --ink-2: #5f6878;
  --ink-3: #656d7d;
  --line: #e4e7eb;
  --line-2: #eef0f3;
  --bg-soft: #f6f6f7;
  --white: #fff;

  --purple: #88619a; --purple-d: #6c4a7c; --purple-l: #e7dfea; --purple-xl: #f4f0f6;
  --green: #33a474;  --green-d: #207351;  --green-l: #d6ece3;  --green-xl: #eef7f3;
  --blue: #4298b4;   --blue-d: #2a6e84;   --blue-l: #d9eaf0;   --blue-xl: #ecf4f7;
  --yellow: #e4ae3a; --yellow-d: #8f6514; --yellow-l: #f9eed7; --yellow-xl: #fcf7ec;
  --red: #f25e62;    --red-d: #b83b40;    --red-l: #fde3e3;    --red-xl: #fef2f2;
  --neutral: #7d8491;

  --g: var(--purple); --g-d: var(--purple-d); --g-l: var(--purple-l); --g-xl: var(--purple-xl);
  --g-h: var(--g);   /* 大きな見出しの文字色 */
  --g-on: #fff;      /* グループ色の上に置く文字色 */

  --font: "Inter", "Noto Sans JP", "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic", Meiryo, sans-serif;
  --font-head: "Noto Sans JP", "Inter", "Hiragino Sans", "Yu Gothic", Meiryo, sans-serif;

  --wrap: 1180px;
  --radius: 10px;
  --shadow: 0 8px 30px rgba(52, 60, 75, .08);
  --shadow-lg: 0 18px 50px rgba(52, 60, 75, .14);
  --header-h: 64px;
}

[data-group="brains"]    { --g: var(--purple); --g-d: var(--purple-d); --g-l: var(--purple-l); --g-xl: var(--purple-xl); }
[data-group="hearts"]    { --g: var(--green);  --g-d: var(--green-d);  --g-l: var(--green-l);  --g-xl: var(--green-xl); }
[data-group="guardians"] { --g: var(--blue);   --g-d: var(--blue-d);   --g-l: var(--blue-l);   --g-xl: var(--blue-xl); }
[data-group="players"]   { --g: var(--yellow); --g-d: var(--yellow-d); --g-l: var(--yellow-l); --g-xl: var(--yellow-xl); --g-h: var(--yellow-d); --g-on: var(--ink); }
[data-group="brains"] { --g-h: var(--purple); --g-on: #fff; }
[data-group="hearts"] { --g-h: #2a8c63; --g-on: #fff; }
[data-group="guardians"] { --g-h: #3584a0; --g-on: #fff; }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 20px); }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 18px;
  line-height: 1.75;
  color: var(--ink);
  background: var(--white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, h4, h5, h6 { font-family: var(--font-head); color: var(--ink); font-weight: 700; line-height: 1.3; margin: 0 0 .5em; letter-spacing: -.01em; }
p { margin: 0 0 1.1em; }
:focus-visible { outline: 3px solid var(--blue-d); outline-offset: 3px; border-radius: 6px; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.wrap--narrow { max-width: 860px; }
.wrap--wide { max-width: 1320px; }
.center { text-align: center; }
.balance { text-wrap: balance; }
.nw { display: inline-block; }
.muted { color: var(--ink-2); }

/* ---------- ボタン ---------- */
.btn {
  --bc: var(--purple); --bc-d: var(--purple-d);
  display: inline-flex; align-items: center; justify-content: center; gap: 12px;
  min-height: 56px; padding: 12px 38px;
  border-radius: 40px; border: 1px solid var(--bc);
  background: var(--bc); color: #fff;
  font-size: 18px; font-weight: 600; letter-spacing: .01em; line-height: 1.2;
  cursor: pointer; white-space: nowrap;
  box-shadow: 0 8px 18px -8px color-mix(in srgb, var(--bc) 80%, transparent);
  transition: background .2s, border-color .2s, transform .2s, box-shadow .2s;
}
.btn:hover { background: var(--bc-d); border-color: var(--bc-d); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn .arrow { width: 18px; height: 18px; transition: transform .2s; flex: none; }
.btn:hover .arrow { transform: translateX(4px); }
.btn--sm { min-height: 42px; padding: 8px 22px; font-size: 15px; gap: 8px; }
.btn--sm .arrow { width: 15px; height: 15px; }
.btn--outline { background: #fff; color: var(--bc); box-shadow: none; }
.btn--outline:hover { background: var(--bc); color: #fff; }
.btn--ghost { background: transparent; border-color: transparent; color: var(--ink-2); box-shadow: none; }
.btn--ghost:hover { background: var(--bg-soft); border-color: var(--bg-soft); color: var(--ink); }
.btn--green { --bc: var(--green); --bc-d: var(--green-d); }
.btn--blue { --bc: var(--blue); --bc-d: var(--blue-d); }
.btn--group { --bc: var(--g); --bc-d: var(--g-d); color: var(--g-on); }
.btn--group:hover { color: #fff; }
.btn[disabled] { opacity: .45; cursor: not-allowed; transform: none; }

/* ---------- ヘッダー ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  height: var(--header-h);
  background: rgba(255, 255, 255, .96);
  backdrop-filter: saturate(1.4) blur(8px);
  border-bottom: 1px solid var(--line-2);
}
.site-header__inner { height: 100%; max-width: 1440px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 24px; }
.logo { display: inline-flex; align-items: center; gap: 10px; flex: none; }
.logo__mark { width: 34px; height: 34px; }
.logo__text { display: flex; flex-direction: column; line-height: 1; }
.logo__en { font-family: "Inter", sans-serif; font-weight: 700; font-size: 19px; letter-spacing: -.02em; color: var(--ink); }
.logo__ja { font-size: 10.5px; color: var(--ink-3); letter-spacing: .12em; margin-top: 4px; }
.nav { flex: 1; display: flex; justify-content: center; height: 100%; }
.nav ul { display: flex; list-style: none; margin: 0; padding: 0; height: 100%; }
.nav li { height: 100%; }
.nav a {
  position: relative; display: flex; align-items: center; height: 100%;
  padding: 0 16px; font-size: 14.5px; color: var(--ink-2); font-weight: 500;
  transition: color .15s;
}
.nav a:hover { color: var(--ink); }
.nav a.is-active { color: var(--ink); }
.nav a.is-active::before { content: ""; position: absolute; top: 0; left: 10px; right: 10px; height: 4px; background: var(--blue); border-radius: 0 0 4px 4px; }
.header-actions { display: flex; align-items: center; gap: 14px; flex: none; }
.header-link { font-size: 14px; color: var(--ink-2); display: inline-flex; align-items: center; gap: 6px; }
.header-link:hover { color: var(--ink); }
.header-link .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green); }
.nav-saved { display: none; }
.nav a { white-space: nowrap; }
.header-link__text { max-width: 12em; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 640px) { .header-actions { display: none; } }
.menu-toggle { display: none; width: 44px; height: 44px; border: 0; background: transparent; cursor: pointer; border-radius: 10px; align-items: center; justify-content: center; }
.menu-toggle span { display: block; width: 22px; height: 2px; background: var(--ink); position: relative; transition: background .2s; }
.menu-toggle span::before, .menu-toggle span::after { content: ""; position: absolute; left: 0; width: 22px; height: 2px; background: var(--ink); transition: transform .25s; }
.menu-toggle span::before { top: -7px; }
.menu-toggle span::after { top: 7px; }
.is-menu-open .menu-toggle span { background: transparent; }
.is-menu-open .menu-toggle span::before { transform: translateY(7px) rotate(45deg); }
.is-menu-open .menu-toggle span::after { transform: translateY(-7px) rotate(-45deg); }

@media (max-width: 1040px) {
  .menu-toggle { display: inline-flex; margin-left: auto; order: 3; }
  .header-actions { order: 2; }
  .header-actions .btn { display: none; }
  .nav {
    position: fixed; top: var(--header-h); left: 0; right: 0; height: auto;
    background: #fff; border-bottom: 1px solid var(--line);
    box-shadow: 0 20px 40px rgba(52, 60, 75, .12);
    transform: translateY(-8px); opacity: 0; pointer-events: none; visibility: hidden;
    transition: opacity .2s, transform .2s, visibility 0s .2s;
  }
  .is-menu-open .nav { transform: none; opacity: 1; pointer-events: auto; visibility: visible; transition-delay: 0s; }
  .nav { max-height: calc(100dvh - var(--header-h)); overflow-y: auto; overscroll-behavior: contain; }
  .nav ul { flex-direction: column; width: 100%; padding: 8px 0 16px; }
  .nav-saved { display: block; border-top: 1px solid var(--line-2); margin-top: 6px; padding-top: 6px; }
  .nav-saved a { color: var(--green-d); font-weight: 700; }
  .nav a { padding: 14px 24px; font-size: 16px; }
  .nav a.is-active::before { top: 10px; bottom: 10px; left: 0; right: auto; width: 4px; height: auto; border-radius: 0 4px 4px 0; }
}

/* ---------- フッター ---------- */
.site-footer { border-top: 1px solid var(--line-2); margin-top: 0; padding: 60px 0 40px; font-size: 15px; color: var(--ink-2); background: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 40px; }
.footer-brand p { margin: 14px 0 0; font-size: 14px; line-height: 1.7; max-width: 300px; }
.footer-col h3 { font-size: 16px; padding-bottom: 12px; margin-bottom: 14px; border-bottom: 1px solid var(--line); }
.footer-col ul { list-style: none; margin: 0; padding: 0; }
.footer-col li { margin: 0 0 8px; }
.footer-col a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.footer-bottom { margin-top: 44px; padding-top: 22px; border-top: 1px solid var(--line); display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 13px; color: var(--ink-3); }
.footer-bottom p { margin: 0; max-width: 760px; }
.footer-paws { display: flex; gap: 10px; }
.footer-paws a { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); display: inline-flex; align-items: center; justify-content: center; transition: background .2s; }
.footer-paws a:hover { background: var(--bg-soft); }
.footer-paws svg { width: 18px; height: 18px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; gap: 28px; } }

/* ---------- 角ばった波形（グループ帯の上辺） ---------- */
.poly-edge { position: absolute; left: 0; width: 100%; height: 80px; display: block; pointer-events: none; }
.poly-edge--top { top: -79px; }
.poly-edge--bottom { bottom: -79px; transform: scaleY(-1); }
.poly-edge polygon { fill: var(--edge, var(--g-l)); }

/* =========================================================
   トップページ
   ========================================================= */
.home-hero { position: relative; background: var(--blue-xl); padding: 70px 0 0; overflow: hidden; text-align: center; }
.home-hero h1 { font-size: clamp(30px, 4.6vw, 52px); letter-spacing: -.02em; margin-bottom: 18px; }
.home-hero .lead { font-size: clamp(16px, 1.6vw, 19px); color: var(--ink-2); max-width: 720px; margin: 0 auto 32px; }
.home-hero__art { position: relative; z-index: 0; margin: 6px auto 0; max-width: 1600px; }
.home-hero .wrap { position: relative; z-index: 1; }
.home-hero__art img { width: 100%; height: auto; aspect-ratio: 1600 / 520; object-fit: cover; }
.hero-badges { display: flex; justify-content: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; font-size: 14px; color: var(--ink-2); }
.hero-badges span { display: inline-flex; align-items: center; gap: 6px; }
.hero-badges svg { width: 16px; height: 16px; color: var(--green); }

.saved-chip { display: inline-flex; align-items: center; gap: 10px; margin-top: 22px; padding: 6px 18px 6px 6px; border-radius: 40px; background: #fff; box-shadow: var(--shadow); font-size: 15px; color: var(--ink-2); transition: transform .2s; }
.saved-chip:hover { transform: translateY(-2px); }
.saved-chip img { width: 40px; height: 40px; border-radius: 50%; background: var(--g-l); }
.saved-chip b { color: var(--g-d); margin: 0 2px; }
.saved-chip .arrow { width: 16px; height: 16px; color: var(--ink-3); }
.stat-strip { background: #fff; padding: 40px 0 50px; }
.stat-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.stat { text-align: center; padding: 18px 10px; border-radius: var(--radius); border-top: 4px solid var(--c, var(--blue)); background: #fff; box-shadow: var(--shadow); }
.stat p { margin: 0; }
.stat__label { font-size: 14px; color: var(--ink-2); }
.stat__num { font-family: "Inter", var(--font-head); font-size: clamp(26px, 3vw, 36px); font-weight: 800; color: var(--ct, var(--c, var(--blue))); letter-spacing: -.02em; line-height: 1.2; }
.stat__num small { font-size: .5em; font-weight: 700; margin-left: 2px; }
@media (max-width: 700px) { .stat-grid { grid-template-columns: repeat(2, 1fr); } }

.section { padding: 90px 0; }
.section--soft { background: var(--bg-soft); }
.section-head { text-align: center; max-width: 760px; margin: 0 auto 50px; }
.section-head .eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .14em; color: var(--ink-3); text-transform: uppercase; margin-bottom: 10px; }
.section-head h2 { font-size: clamp(26px, 3.4vw, 38px); }
.section-head p { color: var(--ink-2); margin: 0; }

.group-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.group-tile { position: relative; border-radius: 14px; background: var(--g-l); padding: 24px 22px 22px; overflow: hidden; display: flex; flex-direction: column; transition: transform .25s, box-shadow .25s; }
.group-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.group-tile__letters { position: absolute; right: -8px; top: -18px; font-family: "Inter", sans-serif; font-weight: 900; font-size: 110px; color: rgba(255, 255, 255, .55); letter-spacing: -.04em; line-height: 1; pointer-events: none; }
.group-tile h3 { color: var(--g-d); font-size: 26px; margin: 0 0 2px; position: relative; }
.group-tile .en { font-size: 13px; font-weight: 700; letter-spacing: .12em; color: var(--g-d); opacity: .9; text-transform: uppercase; position: relative; }
.group-tile p { font-size: 15px; color: var(--ink-2); margin: 14px 0 18px; position: relative; flex: 1; }
.group-tile__types { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; position: relative; }
.group-tile__types a { display: flex; align-items: center; gap: 8px; background: rgba(255, 255, 255, .75); border-radius: 10px; padding: 6px 8px; font-size: 13.5px; font-weight: 600; transition: background .2s; min-width: 0; }
.group-tile__types a:hover { background: #fff; }
.group-tile__types img { width: 28px; height: 28px; flex: none; }
.group-tile__types span { min-width: 0; line-height: 1.35; word-break: keep-all; overflow-wrap: anywhere; }
.group-tile__types small { display: block; font-size: 11px; color: var(--ink-3); font-weight: 600; letter-spacing: .04em; }
@media (max-width: 1050px) { .group-tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .group-tiles { grid-template-columns: 1fr; } }

.trait-list { display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.trait-item { background: #fff; border-radius: 12px; padding: 22px 18px; box-shadow: var(--shadow); border-top: 4px solid var(--c); }
.trait-item h3 { font-size: 18px; margin-bottom: 10px; }
.trait-item .poles { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; color: var(--cd, var(--c)); margin-bottom: 8px; }
.trait-item .poles i { font-style: normal; color: var(--ink-3); font-weight: 400; }
.trait-item p { font-size: 14px; color: var(--ink-2); margin: 0; line-height: 1.7; }
@media (max-width: 1050px) { .trait-list { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .trait-list { grid-template-columns: 1fr; } }

.compat-promo { display: grid; grid-template-columns: 1.05fr 1fr; gap: 60px; align-items: center; }
.compat-promo h2 { font-size: clamp(26px, 3.2vw, 36px); }
.compat-promo p { color: var(--ink-2); }
.compat-mock { position: relative; background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); padding: 28px; }
.compat-mock__pair { display: flex; align-items: center; justify-content: center; gap: 18px; }
.compat-mock__pair .who { text-align: center; font-size: 13px; color: var(--ink-2); }
.compat-mock__pair .who b { display: block; font-size: 22px; color: var(--ink); font-family: "Inter", sans-serif; letter-spacing: .02em; }
.compat-mock__pair img { width: 90px; height: 90px; margin: 0 auto 6px; }
.compat-mock__heart { width: 54px; height: 54px; color: var(--red); }
.compat-mock__score { text-align: center; margin-top: 18px; }
.compat-mock__score b { font-family: "Inter", sans-serif; font-size: 44px; font-weight: 800; color: var(--red); letter-spacing: -.03em; }
.compat-mock__score span { display: block; font-weight: 700; }
@media (max-width: 900px) { .compat-promo { grid-template-columns: 1fr; gap: 36px; } }

.faq { max-width: 860px; margin: 0 auto; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 44px 22px 0; font-weight: 700; font-size: 18px; position: relative; font-family: var(--font-head); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 8px; top: 50%; width: 12px; height: 12px; border-right: 2.5px solid var(--ink-3); border-bottom: 2.5px solid var(--ink-3); transform: translateY(-70%) rotate(45deg); transition: transform .2s; }
.faq details[open] summary::after { transform: translateY(-30%) rotate(-135deg); }
.faq details p { color: var(--ink-2); font-size: 16px; padding-right: 30px; }

.cta-band { position: relative; background: var(--purple-l); text-align: center; padding: 70px 0 80px; margin-top: 80px; --edge: var(--purple-l); }
.cta-band h2 { font-size: clamp(24px, 3vw, 34px); }
.cta-band p { color: var(--ink-2); margin-bottom: 28px; }

/* =========================================================
   性格タイプ一覧
   ========================================================= */
.page-hero { text-align: center; padding: 50px 0 30px; }
.page-hero h1 { font-size: clamp(32px, 4vw, 44px); margin-bottom: 18px; }
.page-hero p { color: var(--ink-2); max-width: 680px; margin: 0 auto 24px; }

.type-group { position: relative; background: var(--g-l); padding: 0 0 100px; margin-top: 120px; scroll-margin-top: calc(var(--header-h) + 90px); }
.type-group:first-of-type { margin-top: 110px; }
.type-group__name {
  position: relative; z-index: 0; text-align: center; color: #fff;
  font-family: var(--font-head); font-weight: 800;
  font-size: clamp(64px, 10.5vw, 135px); line-height: 1.1; letter-spacing: -1px;
  margin: 0; padding-top: 0; transform: translateY(-46px);
  user-select: none;
}
.type-group__desc { position: relative; z-index: 1; text-align: center; color: var(--g-d); font-weight: 600; font-size: 16px; margin: -64px auto 30px; max-width: 640px; padding: 0 20px; }
.types-row { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; max-width: 1300px; margin: 0 auto; padding: 0 30px; }
.type-card { display: block; text-align: center; padding: 0 6px 10px; border-radius: 16px; transition: transform .25s; }
.type-card__img { width: 100%; max-width: 250px; aspect-ratio: 1 / 1; margin: 0 auto 6px; object-fit: contain; transition: transform .35s cubic-bezier(.2, .8, .2, 1.2); filter: drop-shadow(0 10px 14px rgba(52, 60, 75, .08)); }
.type-card:hover .type-card__img { transform: translateY(-8px) scale(1.03); }
.type-card h3 { font-size: 25px; color: var(--g-h); margin: 0 0 4px; letter-spacing: -.01em; }
.type-card:hover h3 { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 5px; }
.type-card .code { font-weight: 700; color: var(--ink); font-size: 15px; font-family: "Inter", var(--font-head); letter-spacing: .02em; margin: 0 auto 10px; }
.type-card p { font-size: 15.5px; line-height: 1.75; color: var(--ink-2); margin: 0 auto; max-width: 290px; text-wrap: balance; }
.types-cta { text-align: center; margin: 80px 0 0; }
@media (max-width: 1000px) { .types-row { grid-template-columns: repeat(2, 1fr); row-gap: 40px; } }
@media (max-width: 520px) {
  .types-row { gap: 14px; row-gap: 30px; padding: 0 14px; }
  .type-card h3 { font-size: 20px; }
  .type-card p { font-size: 13.5px; }
  .type-group__desc { margin-top: -40px; font-size: 14px; }
}

/* =========================================================
   診断テスト
   ========================================================= */
.quiz-top { background: var(--bg-soft); text-align: center; padding: 46px 0 0; }
.quiz-top h1 { font-size: clamp(30px, 4vw, 44px); margin-bottom: 6px; }
.quiz-top .sub { color: var(--ink-2); font-size: 16px; margin: 0; }
.quiz-steps { background: linear-gradient(var(--bg-soft) 0 50%, #fff 50% 100%); padding: 34px 0 30px; }
.step-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step-card { --c: var(--blue); --cl: var(--blue-l); --cd: var(--blue-d); position: relative; overflow: hidden; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px 22px 22px; border-top: 4px solid var(--c); }
.step-card--green { --c: var(--green); --cl: var(--green-l); --cd: var(--green-d); }
.step-card--purple { --c: var(--purple); --cl: var(--purple-l); --cd: var(--purple-d); }
.step-card__img { position: absolute; right: 10px; top: 14px; width: 92px; height: 62px; object-fit: contain; }
.step-badge { display: inline-flex; align-items: center; min-height: 24px; padding: 3px 12px; border-radius: 40px; background: var(--cl); color: var(--cd); font-size: 12.5px; font-weight: 800; letter-spacing: .06em; margin-bottom: 8px; }
.step-card h2, .step-card h3 { font-size: 19px; margin: 0 0 8px; padding-right: 96px; }
.step-card p { font-size: 15px; line-height: 1.7; color: var(--ink-2); margin: 0; }
@media (max-width: 860px) {
  .step-cards { grid-template-columns: 1fr; gap: 10px; }
  .quiz-steps .step-card { padding: 14px 16px 14px 92px; min-height: 76px; display: flex; flex-direction: column; justify-content: center; }
  .quiz-steps .step-card__img { left: 12px; right: auto; top: 50%; transform: translateY(-50%); width: 66px; height: 50px; }
  .quiz-steps .step-card h2 { padding-right: 0; font-size: 16px; margin: 0; }
  .quiz-steps .step-card .step-badge, .quiz-steps .step-card p { display: none; }
}

.dog-name-card { max-width: 1080px; margin: 10px auto 0; display: flex; align-items: center; gap: 22px; padding: 22px 26px; border-radius: 14px; background: var(--green-xl); border: 1px solid var(--green-l); }
.dog-name-card img { width: 76px; height: 76px; flex: none; }
.dog-name-card__body { flex: 1; min-width: 0; }
.dog-name-card label { font-weight: 700; display: block; margin-bottom: 8px; font-size: 16px; }
.dog-name-card .hint { font-size: 13px; color: var(--ink-2); margin: 8px 0 0; }
.name-row { display: flex; gap: 10px; flex-wrap: wrap; }
.input {
  flex: 1 1 220px; min-width: 0; height: 50px; padding: 0 16px; border-radius: 10px;
  border: 2px solid #8a919e; background: #fff; font: inherit; font-size: 17px; color: var(--ink);
  transition: border-color .2s, box-shadow .2s;
}
.input:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 4px rgba(51, 164, 116, .15); }
.select { flex: 0 0 auto; height: 50px; padding: 0 40px 0 14px; border-radius: 10px; border: 2px solid #8a919e; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235f6878' stroke-width='2' fill='none'/%3E%3C/svg%3E") no-repeat right 14px center; appearance: none; font: inherit; font-size: 16px; color: var(--ink); cursor: pointer; }
.select:focus { outline: none; border-color: var(--green); }
@media (max-width: 600px) { .dog-name-card { flex-direction: column; text-align: center; padding: 20px 18px; } .dog-name-card img { width: 64px; height: 64px; } }

.answer-tips { max-width: 1080px; margin: 14px auto 0; padding: 16px 22px; border-radius: 14px; background: var(--blue-xl); border: 1px solid var(--blue-l); font-size: 15px; color: var(--ink-2); }
.answer-tips b { display: flex; align-items: center; gap: 8px; color: var(--blue-d); font-size: 15px; margin-bottom: 6px; }
.answer-tips b svg { width: 18px; height: 18px; }
.answer-tips ul { margin: 0; padding-left: 1.2em; }
.answer-tips li { margin: 2px 0; line-height: 1.6; }
.quiz { max-width: 1080px; margin: 0 auto; padding: 20px 24px 60px; }
.quiz-page { animation: pageIn .45s ease both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

.question { border: 0; margin: 0; padding: 40px 0; border-bottom: 1px solid var(--line); min-width: 0; transition: opacity .35s; }
.question:last-of-type { border-bottom: 0; }
.question .options, .question .captions-mobile, .question .statement { transition: opacity .35s, color .35s; }
.question.is-dim .options, .question.is-dim .captions-mobile { opacity: .35; }
.question.is-dim .statement { color: var(--ink-3); }
.question.is-dim:hover .options, .question.is-dim:hover .captions-mobile { opacity: .7; }
.question legend { display: contents; }
.statement { display: block; font-family: var(--font-head); font-size: clamp(18px, 2vw, 22px); font-weight: 700; color: var(--ink); line-height: 1.5; margin: 0 0 28px; text-wrap: balance; }
.statement .qnum { display: none; }
.options { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.caption { flex: 0 0 150px; font-size: 18px; font-weight: 600; line-height: 1.3; }
.caption--agree { color: var(--green-d); }
.caption--disagree { color: var(--purple); text-align: right; }
.captions-mobile { display: none; }
.circles { flex: 1; display: flex; align-items: center; justify-content: space-between; max-width: 600px; margin: 0 auto; }
.opt { position: relative; display: inline-flex; align-items: center; justify-content: center; width: 72px; height: 72px; cursor: pointer; }
.opt input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; }
.opt .tick {
  --s: 46px; --c: var(--neutral);
  width: var(--s); height: var(--s); border-radius: 50%;
  border: 3px solid var(--c); background: transparent;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background .15s, transform .15s, box-shadow .15s;
  pointer-events: none;
}
.opt .tick svg { width: 46%; height: 46%; color: #fff; opacity: 0; transition: opacity .15s; }
.opt--a .tick { --c: var(--green); }
.opt--d .tick { --c: var(--purple); }
.opt--s70 .tick { --s: 70px; }
.opt--s56 .tick { --s: 56px; }
.opt--s46 .tick { --s: 46px; }
.opt--s36 .tick { --s: 36px; }
.opt:hover .tick { background: color-mix(in srgb, var(--c) 28%, white); transform: scale(1.04); }
.opt:hover .tick svg { opacity: .9; }
.opt input:checked + .tick { background: var(--c); box-shadow: 0 6px 16px -6px var(--c); }
.opt input:checked + .tick svg { opacity: 1; }
.opt input:focus-visible + .tick { outline: 3px solid var(--blue-d); outline-offset: 4px; }
.question.is-dim:focus-within .options, .question.is-dim:focus-within .captions-mobile { opacity: 1; }
.question.is-dim:focus-within .statement { color: var(--ink); }
.question.is-shake { animation: shake .45s; }
@keyframes shake { 0%, 100% { transform: none; } 20%, 60% { transform: translateX(-8px); } 40%, 80% { transform: translateX(8px); } }

@media (max-width: 1100px) {
  .opt--s70 .tick { --s: 56px; } .opt--s56 .tick { --s: 46px; } .opt--s46 .tick { --s: 38px; } .opt--s36 .tick { --s: 30px; }
  .opt { width: 60px; height: 60px; }
}
@media (max-width: 820px) {
  .question { padding: 30px 0; }
  .statement { text-align: center; margin-bottom: 20px; }
  .options .caption { display: none; }
  .circles { max-width: 100%; }
  .captions-mobile { display: flex; justify-content: space-between; margin-top: 8px; font-size: 14px; font-weight: 700; }
  .captions-mobile .caption--agree { color: var(--green-d); }
  .captions-mobile .caption--disagree { color: var(--purple); }
  .opt--s70 .tick { --s: 46px; } .opt--s56 .tick { --s: 38px; } .opt--s46 .tick { --s: 32px; } .opt--s36 .tick { --s: 26px; }
  .opt { width: 46px; height: 52px; }
}
@media (max-width: 360px) { .opt { width: 40px; } }

.quiz-nav { display: flex; align-items: center; justify-content: center; gap: 16px; margin-top: 40px; }
.quiz-nav .btn--ghost { min-width: 120px; }
.quiz-note { text-align: center; font-size: 14px; color: var(--ink-3); margin-top: 18px; }

.quiz-progress {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
  background: rgba(255, 255, 255, .97); box-shadow: 0 -6px 24px rgba(52, 60, 75, .08);
  padding: 12px 24px calc(12px + env(safe-area-inset-bottom));
}
.quiz-progress__inner { max-width: 1080px; margin: 0 auto; display: flex; align-items: center; gap: 18px; }
.quiz-progress__bar { flex: 1; height: 10px; border-radius: 10px; background: var(--line-2); overflow: hidden; }
.quiz-progress__fill { height: 100%; width: 0; border-radius: 10px; background: linear-gradient(90deg, var(--blue), var(--green)); transition: width .4s ease; }
.quiz-progress__text { font-family: "Inter", sans-serif; font-weight: 700; font-size: 15px; color: var(--ink-2); min-width: 80px; text-align: right; }
.quiz-progress__paw { width: 22px; height: 22px; color: var(--green); flex: none; }
body.page-test { padding-bottom: 80px; }

.analyzing { position: fixed; inset: 0; z-index: 200; background: rgba(255, 255, 255, .97); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 18px; opacity: 0; pointer-events: none; visibility: hidden; transition: opacity .3s, visibility 0s .3s; padding: 24px; }
.analyzing.is-on { opacity: 1; pointer-events: auto; visibility: visible; transition-delay: 0s; }
.analyzing h2 { font-size: 24px; margin: 0; }
.analyzing p { color: var(--ink-2); margin: 0; font-size: 16px; min-height: 1.6em; }
.paw-trail { display: flex; gap: 16px; height: 50px; align-items: flex-end; }
.paw-trail svg { width: 30px; height: 30px; opacity: 0; animation: pawStep 1.6s infinite; }
.paw-trail svg:nth-child(odd) { transform: translateY(-14px) rotate(-12deg); }
.paw-trail svg:nth-child(even) { transform: rotate(12deg); }
.paw-trail svg:nth-child(1) { color: var(--purple); animation-delay: 0s; }
.paw-trail svg:nth-child(2) { color: var(--green); animation-delay: .2s; }
.paw-trail svg:nth-child(3) { color: var(--blue); animation-delay: .4s; }
.paw-trail svg:nth-child(4) { color: var(--yellow); animation-delay: .6s; }
.paw-trail svg:nth-child(5) { color: var(--red); animation-delay: .8s; }
@keyframes pawStep { 0% { opacity: 0; } 20%, 60% { opacity: 1; } 100% { opacity: 0; } }

/* =========================================================
   タイプ詳細・結果ページ共通ヒーロー
   ========================================================= */
.type-hero { position: relative; background: var(--g-l); overflow: hidden; }
.type-hero__inner { position: relative; z-index: 1; max-width: 1240px; margin: 0 auto; padding: 50px 24px 70px; display: grid; grid-template-columns: 1fr 1.05fr; gap: 30px; align-items: center; }
.type-hero__kicker { font-size: 16px; font-weight: 700; color: var(--g-d); margin: 0 0 6px; }
.type-hero h1 { font-size: clamp(42px, 6vw, 68px); letter-spacing: -.03em; margin: 0 0 4px; }
.type-hero__code { font-family: var(--font-head); font-size: clamp(22px, 2.6vw, 30px); font-weight: 800; color: var(--g-d); margin: 0 0 16px; letter-spacing: .01em; }
.type-hero__code small { font-size: .62em; color: var(--ink-2); font-weight: 700; margin-left: 8px; }
.type-hero__desc { font-size: 18px; color: var(--ink); max-width: 520px; margin: 0 0 22px; }
.type-hero__tags { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 6px; padding: 0; list-style: none; }
.type-hero__tags li { background: rgba(255, 255, 255, .75); color: var(--g-d); font-weight: 700; font-size: 13.5px; padding: 5px 14px; border-radius: 30px; }
.type-hero__art { position: relative; }
.type-hero__art img { width: 100%; max-width: 560px; margin-left: auto; aspect-ratio: 1200 / 925; object-fit: contain; filter: drop-shadow(0 18px 24px rgba(52, 60, 75, .12)); }
.type-hero__wave { position: absolute; left: 0; right: 0; bottom: -1px; height: 70px; width: 100%; z-index: 0; }
.type-hero__wave polygon { fill: #fff; }
.type-hero__bgletters { position: absolute; z-index: 0; right: -20px; top: 10px; font-family: "Inter", sans-serif; font-weight: 900; font-size: clamp(120px, 22vw, 300px); line-height: .9; letter-spacing: -.06em; color: rgba(255, 255, 255, .35); pointer-events: none; user-select: none; }
@media (max-width: 860px) {
  .type-hero__inner { grid-template-columns: 1fr; text-align: center; padding: 34px 20px 70px; gap: 10px; }
  .type-hero__art { order: -1; }
  .type-hero__art img { margin: 0 auto; max-width: 420px; }
  .type-hero__desc { margin-left: auto; margin-right: auto; font-size: 16.5px; }
  .type-hero__tags { justify-content: center; }
}

/* =========================================================
   タイプ詳細ページ
   ========================================================= */
.profile { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 60px; max-width: 1180px; margin: 0 auto; padding: 40px 24px 60px; }
.toc { position: sticky; top: calc(var(--header-h) + 24px); align-self: start; max-height: calc(100vh - var(--header-h) - 48px); overflow: auto; }
.toc__title { font-size: 12.5px; font-weight: 800; letter-spacing: .14em; color: var(--ink-3); text-transform: uppercase; margin: 0 0 10px; }
.toc ol { list-style: none; margin: 0; padding: 0; counter-reset: toc; border-left: 2px solid var(--line); }
.toc li { counter-increment: toc; }
.toc a { display: block; padding: 8px 0 8px 16px; margin-left: -2px; border-left: 2px solid transparent; font-size: 15px; color: var(--ink-2); line-height: 1.45; transition: color .15s, border-color .15s; }
.toc a::before { content: counter(toc, decimal-leading-zero); font-family: "Inter", sans-serif; font-size: 11px; font-weight: 700; color: var(--ink-3); margin-right: 8px; }
.toc a:hover { color: var(--ink); }
.toc a:focus-visible { outline-offset: -3px; }
.toc a.is-active { color: var(--g-d); border-left-color: var(--g); font-weight: 700; }
.toc__cta { margin-top: 22px; padding: 18px; border-radius: 12px; background: var(--g-xl); font-size: 14px; }
.toc__cta p { margin: 0 0 10px; color: var(--ink-2); line-height: 1.6; }

.article { min-width: 0; }
.article > section { padding: 10px 0 50px; }
.article h2.chapter { font-size: clamp(26px, 3vw, 34px); padding-bottom: 16px; margin: 0 0 26px; border-bottom: 1px solid var(--line); display: flex; align-items: baseline; gap: 14px; }
.article h2.chapter .num { font-family: "Inter", sans-serif; font-size: 15px; font-weight: 800; color: var(--g-d); letter-spacing: .06em; }
.article h3 { font-size: 22px; margin: 34px 0 14px; }
.article p { color: var(--ink); }
.article .lead { font-size: 19px; }

.quote { border-left: 4px solid var(--g); padding: 6px 0 6px 28px; margin: 0 0 36px; }
.quote p { font-family: var(--font-head); font-size: clamp(19px, 2.2vw, 24px); font-weight: 700; line-height: 1.6; margin: 0 0 10px; color: var(--ink); }
.quote cite { font-style: normal; font-size: 15px; color: var(--ink-2); }

.sw-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 26px; }
.sw-col h3 { display: flex; align-items: center; gap: 10px; margin-top: 0; font-size: 20px; }
.sw-col h3 .ico { width: 34px; height: 34px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; color: #fff; flex: none; }
.sw-col--s h3 .ico { background: var(--green); }
.sw-col--w h3 .ico { background: var(--red); }
.sw-col h3 .ico svg { width: 18px; height: 18px; }
.sw-item { padding: 18px 20px; border-radius: 12px; background: var(--bg-soft); margin-bottom: 12px; }
.sw-col--s .sw-item { background: var(--green-xl); }
.sw-col--w .sw-item { background: var(--red-xl); }
.sw-item b { display: block; font-family: var(--font-head); font-size: 17px; margin-bottom: 4px; }
.sw-item p { font-size: 15.5px; line-height: 1.75; margin: 0; color: var(--ink-2); }
@media (max-width: 760px) { .sw-grid { grid-template-columns: 1fr; } }

.point-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 24px; }
.point-card { border-radius: 14px; padding: 22px 20px; background: var(--g-xl); border: 1px solid var(--g-l); }
.point-card .k { font-family: "Inter", sans-serif; font-size: 12px; font-weight: 800; letter-spacing: .12em; color: var(--g-d); text-transform: uppercase; }
.point-card b { display: block; font-family: var(--font-head); font-size: 17px; margin: 6px 0 8px; line-height: 1.45; }
.point-card p { font-size: 15px; line-height: 1.75; color: var(--ink-2); margin: 0; }
@media (max-width: 860px) { .point-cards { grid-template-columns: 1fr; } }

.mini-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 24px; }
.mini-card { border-radius: 14px; padding: 20px; background: #fff; box-shadow: var(--shadow); }
.mini-card .ico { width: 44px; height: 44px; border-radius: 12px; background: var(--g-l); color: var(--g-d); display: flex; align-items: center; justify-content: center; margin-bottom: 12px; }
.mini-card .ico svg { width: 24px; height: 24px; }
.mini-card b { display: block; font-family: var(--font-head); font-size: 16.5px; margin-bottom: 6px; }
.mini-card p { font-size: 15px; line-height: 1.75; color: var(--ink-2); margin: 0; }
@media (max-width: 860px) { .mini-cards { grid-template-columns: 1fr; } }

.tips { list-style: none; margin: 24px 0 0; padding: 0; counter-reset: tip; }
.tips li { counter-increment: tip; position: relative; padding: 18px 20px 18px 74px; border-radius: 14px; background: var(--bg-soft); margin-bottom: 12px; }
.tips li::before { content: counter(tip); position: absolute; left: 20px; top: 18px; width: 38px; height: 38px; border-radius: 50%; background: var(--g-d); color: #fff; font-family: "Inter", sans-serif; font-weight: 800; display: flex; align-items: center; justify-content: center; font-size: 17px; }
.tips b { display: block; font-family: var(--font-head); font-size: 17px; margin-bottom: 4px; }
.tips p { margin: 0; font-size: 15.5px; color: var(--ink-2); line-height: 1.75; }

.callout { border-radius: 14px; padding: 20px 22px; margin-top: 22px; border: 1px solid var(--red-l); background: var(--red-xl); }
.callout h4 { font-size: 16px; color: var(--red-d); margin: 0 0 10px; display: flex; align-items: center; gap: 8px; }
.callout h4 svg { width: 20px; height: 20px; }
.callout ul { margin: 0; padding-left: 1.2em; }
.callout li { font-size: 15.5px; color: var(--ink-2); margin-bottom: 6px; line-height: 1.7; }
.callout--info { border-color: var(--blue-l); background: var(--blue-xl); }
.callout--info h4 { color: var(--blue-d); }
.callout--plain { border-color: var(--line); background: #fff; }
.callout--plain p { margin: 0; color: var(--ink-2); font-size: 15.5px; }

.activity-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px; margin-top: 24px; }
.activity { border-radius: 14px; padding: 18px; border: 1px solid var(--line); background: #fff; transition: border-color .2s, transform .2s; }
.activity:hover { border-color: var(--g); transform: translateY(-2px); }
.activity .emoji { width: 40px; height: 40px; border-radius: 50%; background: var(--g-l); display: flex; align-items: center; justify-content: center; margin-bottom: 10px; color: var(--g-d); }
.activity .emoji svg { width: 22px; height: 22px; }
.activity b { display: block; font-family: var(--font-head); font-size: 16px; margin-bottom: 4px; }
.activity p { margin: 0; font-size: 14.5px; line-height: 1.7; color: var(--ink-2); }

.two-lists { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 22px; }
.list-card { border-radius: 14px; padding: 20px 22px; background: var(--bg-soft); }
.list-card h4 { font-size: 16px; margin: 0 0 12px; }
.list-card ul { margin: 0; padding: 0; list-style: none; }
.list-card li { position: relative; padding-left: 22px; font-size: 15.5px; line-height: 1.7; margin-bottom: 8px; color: var(--ink-2); }
.list-card li::before { content: ""; position: absolute; left: 2px; top: .62em; width: 9px; height: 9px; border-radius: 50%; background: var(--c, var(--g)); }
@media (max-width: 760px) { .two-lists { grid-template-columns: 1fr; } }

.identity-compare { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 22px; }
.identity-card { border-radius: 14px; padding: 22px; border: 2px solid var(--red-l); position: relative; }
.identity-card--T { background: var(--red-xl); }
.identity-card .tag { display: inline-flex; align-items: center; gap: 6px; font-weight: 800; font-size: 14px; color: var(--red-d); margin-bottom: 8px; font-family: "Inter", var(--font-head); }
.identity-card p { margin: 0; font-size: 15.5px; line-height: 1.75; color: var(--ink-2); }
@media (max-width: 760px) { .identity-compare { grid-template-columns: 1fr; } }

.aruaru-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; margin-bottom: 18px; }
.aruaru-meter { display: flex; align-items: center; gap: 12px; font-weight: 700; font-size: 15px; }
.aruaru-meter__bar { width: 160px; height: 10px; border-radius: 10px; background: var(--line-2); overflow: hidden; }
.aruaru-meter__fill { height: 100%; width: 0; background: var(--g); border-radius: 10px; transition: width .3s; }
.aruaru-meter b { font-family: "Inter", sans-serif; color: var(--g-d); font-size: 20px; }
.aruaru { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; list-style: none; margin: 0; padding: 0; }
.aruaru label { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: 12px; border: 2px solid var(--line); background: #fff; cursor: pointer; transition: border-color .15s, background .15s; font-size: 15.5px; line-height: 1.65; }
.aruaru label:hover { border-color: var(--g-l); }
.aruaru input { position: absolute; opacity: 0; pointer-events: none; }
.aruaru .box { flex: none; width: 24px; height: 24px; border-radius: 7px; border: 2px solid var(--neutral); display: inline-flex; align-items: center; justify-content: center; margin-top: 1px; transition: .15s; background: #fff; }
.aruaru .box svg { width: 14px; height: 14px; color: #fff; opacity: 0; }
.aruaru input:checked + label { border-color: var(--g); background: var(--g-xl); }
.aruaru input:checked + label .box { background: var(--g); border-color: var(--g); }
.aruaru input:checked + label .box svg { opacity: 1; }
.aruaru input:focus-visible + label { outline: 3px solid var(--blue-d); outline-offset: 2px; }
.aruaru-verdict { margin-top: 16px; padding: 16px 20px; border-radius: 12px; background: var(--g-xl); font-weight: 700; color: var(--g-d); }
.aruaru-verdict:not(.is-on) { padding: 0; margin: 0; background: none; }
.aruaru-verdict.is-on { animation: pageIn .35s both; }
@media (max-width: 760px) { .aruaru { grid-template-columns: 1fr; } }

.owner-match { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin-top: 20px; }
.owner-match a { display: block; border-radius: 14px; padding: 18px; background: #fff; box-shadow: var(--shadow); text-align: center; transition: transform .2s; }
.owner-match a:hover { transform: translateY(-3px); }
.owner-match .rank { font-size: 12px; font-weight: 800; letter-spacing: .12em; color: var(--ink-3); }
.owner-match .mbti { display: block; font-family: "Inter", sans-serif; font-size: 28px; font-weight: 800; color: var(--g-d); letter-spacing: .02em; }
.owner-match .score { font-weight: 700; color: var(--red-d); }
.owner-match .tier { display: block; font-size: 13.5px; color: var(--ink-2); }
@media (max-width: 560px) { .owner-match { grid-template-columns: 1fr; } }

.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; padding: 0; list-style: none; }
.chips li { padding: 8px 16px; border-radius: 30px; background: var(--g-xl); border: 1px solid var(--g-l); font-weight: 700; font-size: 15px; color: var(--g-d); }

.type-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 20px; }
.type-nav a { display: flex; align-items: center; gap: 14px; padding: 16px 18px; border-radius: 14px; border: 1px solid var(--line); transition: border-color .2s, box-shadow .2s; }
.type-nav a:hover { box-shadow: var(--shadow); border-color: transparent; }
.type-nav a.next { flex-direction: row-reverse; text-align: right; }
.type-nav img { width: 64px; height: 64px; flex: none; }
.type-nav small { display: block; font-size: 12.5px; color: var(--ink-3); font-weight: 700; letter-spacing: .06em; }
.type-nav b { font-family: var(--font-head); font-size: 18px; color: var(--g-d); }
.type-nav .code { font-family: "Inter", sans-serif; font-size: 13px; color: var(--ink-2); font-weight: 700; }

.sibling-strip { background: var(--g-l); position: relative; padding: 30px 0 70px; margin-top: 110px; }
.sibling-strip h2 { text-align: center; font-size: 26px; color: var(--g-d); margin: -10px 0 30px; }
.sibling-strip .types-row { grid-template-columns: repeat(4, 1fr); }
.sibling-strip .type-card__img { max-width: 160px; }
.sibling-strip .type-card h3 { font-size: 20px; }
.sibling-strip .type-card.is-current { opacity: .45; }
@media (max-width: 1000px) { .sibling-strip .types-row { grid-template-columns: repeat(2, 1fr); } }

@media (max-width: 1000px) {
  html { scroll-padding-top: calc(var(--header-h) + 70px); }
  .profile { grid-template-columns: 1fr; gap: 0; padding-top: 10px; }
  .toc { position: sticky; top: var(--header-h); z-index: 20; max-height: none; background: rgba(255, 255, 255, .97); margin: 0 -24px 20px; padding: 10px 24px; border-bottom: 1px solid var(--line-2); overflow-x: auto; scrollbar-width: none; }
  .toc::-webkit-scrollbar { display: none; }
  .toc__title, .toc__cta { display: none; }
  .toc ol { display: flex; gap: 6px; border: 0; white-space: nowrap; }
  .toc a { border: 1px solid var(--line); border-radius: 30px; padding: 6px 14px; margin: 0; font-size: 14px; }
  .toc a::before { display: none; }
  .toc a.is-active { background: var(--g-d); color: #fff; border-color: var(--g-d); }
}

/* =========================================================
   診断結果ページ
   ========================================================= */
.result-intro { text-align: center; padding: 60px 0 10px; }
.result-intro h2 { font-size: clamp(26px, 3.2vw, 36px); }
.traits-card { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.traits { display: flex; flex-direction: column; gap: 6px; }
.trait { --c: var(--blue); --cl: var(--blue-l); --cd: var(--blue-d); position: relative; display: block; width: 100%; text-align: left; border: 0; background: transparent; padding: 16px 20px 18px; border-radius: 14px; cursor: pointer; transition: background .2s; }
.trait:hover { background: var(--bg-soft); }
.trait.is-active { background: var(--bg-soft); }
.trait.is-active::before { content: ""; position: absolute; left: 0; top: 18px; bottom: 18px; width: 4px; border-radius: 4px; background: var(--c); }
.trait__label { display: flex; align-items: baseline; justify-content: center; gap: 8px; font-size: 15.5px; color: var(--ink-2); margin-bottom: 10px; }
.trait__label b { color: var(--cd); font-size: 18px; font-family: var(--font-head); }
.trait__label .pct { font-family: "Inter", sans-serif; }
.trait__bar { position: relative; display: block; height: 12px; border-radius: 12px; background: var(--cl); }
.trait__fill { position: absolute; top: 0; bottom: 0; left: 50%; width: 0; border-radius: 12px; background: var(--c); transition: left .9s cubic-bezier(.2, .8, .2, 1), width .9s cubic-bezier(.2, .8, .2, 1); }
.trait__marker { position: absolute; top: 50%; left: 50%; width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 4px solid var(--c); transform: translate(-50%, -50%); box-shadow: 0 2px 8px rgba(0, 0, 0, .15); transition: left .9s cubic-bezier(.2, .8, .2, 1); }
.trait__poles { display: flex; justify-content: space-between; margin-top: 10px; font-size: 14px; color: var(--ink-3); font-weight: 600; }
.trait__poles .on { color: var(--cd); font-weight: 800; }
.trait-detail { position: sticky; top: calc(var(--header-h) + 20px); border-radius: 16px; overflow: hidden; background: #fff; box-shadow: var(--shadow-lg); }
.trait-detail__img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; background: var(--cl, var(--blue-l)); }
.trait-detail__body { padding: 24px 26px 28px; }
.trait-detail__axis { font-size: 13px; font-weight: 800; letter-spacing: .12em; color: var(--ink-3); text-transform: uppercase; margin: 0 0 4px; }
.trait-detail h3 { font-size: 26px; color: var(--cd, var(--ink)); margin: 0 0 12px; }
.trait-detail h3 .pct { font-family: "Inter", sans-serif; }
.trait-detail p { font-size: 16px; color: var(--ink-2); margin: 0 0 10px; }
.trait-detail .personal { color: var(--ink); background: var(--cl); border-radius: 10px; padding: 12px 14px; font-size: 15px; }
@media (max-width: 900px) { .traits-card { grid-template-columns: 1fr; } .trait-detail { position: relative; top: 0; } }

.summary-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.summary-grid .article p { font-size: 17px; }
.pill-list { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 10px 0 24px; }
.pill-list li { padding: 7px 14px; border-radius: 30px; font-size: 14.5px; font-weight: 700; }
.pill-list--s li { background: var(--green-xl); color: var(--green-d); }
.pill-list--w li { background: var(--red-xl); color: var(--red-d); }
.aside-card { border-radius: 16px; padding: 24px; background: var(--g-xl); border: 1px solid var(--g-l); }
.aside-card h3 { font-size: 18px; margin: 0 0 12px; }
.aside-card ul { margin: 0; padding: 0; list-style: none; }
.aside-card li { position: relative; padding: 10px 0 10px 28px; border-bottom: 1px dashed var(--g-l); font-size: 15px; line-height: 1.6; }
.aside-card li:last-child { border-bottom: 0; }
.aside-card li svg { position: absolute; left: 0; top: 13px; width: 18px; height: 18px; color: var(--g); }
@media (max-width: 900px) { .summary-grid { grid-template-columns: 1fr; } }

.owner-picker { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; max-width: 760px; margin: 0 auto; }
.seg { display: flex; border-radius: 12px; background: var(--bg-soft); padding: 4px; gap: 4px; }
.seg button { flex: 1; border: 0; background: transparent; border-radius: 9px; padding: 10px 6px; cursor: pointer; font-family: "Inter", var(--font-head); font-weight: 800; font-size: 20px; color: var(--ink-3); transition: .15s; line-height: 1.1; }
.seg button small { display: block; font-family: var(--font); font-size: 11px; font-weight: 600; margin-top: 3px; letter-spacing: 0; }
.seg button:hover { color: var(--ink); }
.seg button.is-on { background: var(--ink); color: #fff; box-shadow: 0 2px 10px rgba(52, 60, 75, .2); }
@media (max-width: 640px) { .owner-picker { grid-template-columns: repeat(2, 1fr); } }

.compat-result { max-width: 900px; margin: 36px auto 0; }
.compat-score { display: grid; grid-template-columns: 180px 1fr; gap: 30px; align-items: center; background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); padding: 28px 30px; }
.score-ring { position: relative; width: 170px; height: 170px; }
.score-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.score-ring .track { stroke: var(--red-l); }
.score-ring .val { stroke: var(--red); transition: stroke-dashoffset 1.1s cubic-bezier(.2, .8, .2, 1); stroke-linecap: round; }
.score-ring .num { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; font-family: "Inter", sans-serif; font-weight: 800; font-size: 44px; color: var(--ink); letter-spacing: -.03em; line-height: 1; }
.score-ring .num small { font-size: 13px; color: var(--ink-3); letter-spacing: .1em; margin-top: 6px; font-family: var(--font); }
.compat-score h3 { font-size: 26px; margin: 0 0 6px; color: var(--red-d); }
.compat-score .pair { font-size: 14px; font-weight: 700; color: var(--ink-3); letter-spacing: .04em; margin: 0 0 6px; }
.compat-score p { margin: 0; color: var(--ink-2); font-size: 16px; }
.compat-axes { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 18px; }
.compat-axis { --c: var(--blue); --cl: var(--blue-l); --cd: var(--blue-d); border-radius: 14px; padding: 20px 22px; background: #fff; border: 1px solid var(--line); border-top: 4px solid var(--c); }
.compat-axis .axis { font-size: 12.5px; font-weight: 800; letter-spacing: .1em; color: var(--cd); }
.compat-axis .letters { font-family: "Inter", sans-serif; font-weight: 800; font-size: 14px; color: var(--ink-3); margin-left: 8px; }
.compat-axis b { display: block; font-family: var(--font-head); font-size: 17px; margin: 6px 0 6px; }
.compat-axis p { margin: 0; font-size: 15px; line-height: 1.75; color: var(--ink-2); }
@media (max-width: 760px) { .compat-score { grid-template-columns: 1fr; text-align: center; justify-items: center; } .compat-axes { grid-template-columns: 1fr; } }

.share-box { text-align: center; background: var(--bg-soft); border-radius: 20px; padding: 40px 24px; }
.share-box h2 { font-size: 26px; margin-bottom: 8px; }
.share-box p { color: var(--ink-2); font-size: 16px; }
.share-buttons { display: flex; justify-content: center; gap: 12px; flex-wrap: wrap; margin-top: 18px; }
.share-btn { display: inline-flex; align-items: center; gap: 10px; min-height: 50px; padding: 10px 22px; border-radius: 40px; border: 1px solid var(--line); background: #fff; font-weight: 700; font-size: 15.5px; cursor: pointer; transition: transform .2s, box-shadow .2s; }
.share-btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.share-btn svg { width: 20px; height: 20px; }
.share-btn--x { background: #111; color: #fff; border-color: #111; }
.share-btn--line { background: #047a35; color: #fff; border-color: #047a35; }
.share-preview { max-width: 600px; margin: 26px auto 0; border-radius: 14px; overflow: hidden; box-shadow: var(--shadow-lg); display: none; }
.share-preview.is-on { display: block; }
.share-preview img { width: 100%; }

.history-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.history-card { display: flex; align-items: center; gap: 14px; padding: 14px 16px; border-radius: 14px; background: #fff; box-shadow: var(--shadow); border-left: 4px solid var(--g); transition: transform .2s; }
.history-card:hover { transform: translateY(-2px); }
.history-card img { width: 64px; height: 64px; flex: none; }
.history-card b { display: block; font-family: var(--font-head); font-size: 17px; }
.history-card em { display: block; font-style: normal; font-weight: 700; font-size: 14px; color: var(--g-d); }
.history-card small { display: block; font-size: 12.5px; color: var(--ink-3); }

.toast { position: fixed; left: 50%; bottom: 30px; width: max-content; max-width: calc(100vw - 32px); text-align: center; z-index: 300; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 12px 22px; border-radius: 40px; font-size: 15px; font-weight: 600; opacity: 0; transition: .25s; pointer-events: none; box-shadow: var(--shadow-lg); }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

.empty-state { text-align: center; padding: 100px 24px; max-width: 640px; margin: 0 auto; }
.empty-state img { width: 160px; height: 160px; margin: 0 auto 20px; }
.empty-state h1 { font-size: 30px; }
.empty-state p { color: var(--ink-2); }

/* =========================================================
   理論ページ
   ========================================================= */
.theory-hero { background: var(--bg-soft); padding: 60px 0 70px; text-align: center; }
.theory-hero h1 { font-size: clamp(32px, 4vw, 46px); }
.theory-hero p { color: var(--ink-2); max-width: 720px; margin: 0 auto; }
.code-anatomy { display: flex; justify-content: center; gap: 6px; margin: 40px auto 10px; flex-wrap: wrap; }
.code-anatomy .ch { width: 86px; text-align: center; }
.code-anatomy .ch b { display: flex; align-items: center; justify-content: center; height: 86px; border-radius: 16px; background: var(--c); color: var(--on, #fff); font-family: "Inter", sans-serif; font-size: 46px; font-weight: 800; box-shadow: 0 10px 20px -10px var(--c); }
.code-anatomy .ch span { display: block; font-size: 13px; color: var(--ink-2); margin-top: 10px; line-height: 1.4; font-weight: 600; }
.code-anatomy .dash { align-self: flex-start; height: 86px; display: flex; align-items: center; font-size: 40px; font-weight: 800; color: var(--ink-3); padding: 0 2px; }
@media (max-width: 560px) { .code-anatomy .ch { width: 58px; } .code-anatomy .ch b { height: 58px; font-size: 30px; border-radius: 12px; } .code-anatomy .dash { height: 58px; font-size: 28px; } .code-anatomy .ch span { font-size: 11px; } }

.axis-block { --c: var(--blue); --cl: var(--blue-l); --cd: var(--blue-d); --cxl: var(--blue-xl); display: grid; grid-template-columns: 260px 1fr; gap: 40px; padding: 44px 0; border-bottom: 1px solid var(--line); }
.axis-block:last-child { border-bottom: 0; }
.axis-block__head .k { font-family: "Inter", sans-serif; font-weight: 800; font-size: 13px; letter-spacing: .14em; color: var(--cd); text-transform: uppercase; }
.axis-block__head h3 { font-size: 30px; margin: 4px 0 8px; }
.axis-block__head p { font-size: 15px; color: var(--ink-2); }
.axis-poles { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.axis-pole { border-radius: 14px; padding: 22px; background: var(--cxl); border: 1px solid var(--cl); }
.axis-pole h4 { display: flex; align-items: center; gap: 10px; font-size: 20px; color: var(--cd); margin: 0 0 8px; }
.axis-pole h4 .letter { width: 38px; height: 38px; border-radius: 10px; background: var(--c); color: var(--on, #fff); display: inline-flex; align-items: center; justify-content: center; font-family: "Inter", sans-serif; font-weight: 800; font-size: 20px; }
.axis-pole p { font-size: 15.5px; color: var(--ink-2); margin: 0 0 12px; }
.axis-pole ul { margin: 0; padding-left: 1.1em; }
.axis-pole li { font-size: 14.5px; color: var(--ink-2); margin-bottom: 4px; }
@media (max-width: 860px) { .axis-block { grid-template-columns: 1fr; gap: 16px; } .axis-poles { grid-template-columns: 1fr; } }

.refs { list-style: none; margin: 0; padding: 0; counter-reset: ref; }
.refs li { counter-increment: ref; position: relative; padding: 20px 0 20px 54px; border-bottom: 1px solid var(--line); }
.refs li::before { content: counter(ref); position: absolute; left: 0; top: 20px; width: 36px; height: 36px; border-radius: 50%; background: var(--bg-soft); font-family: "Inter", sans-serif; font-weight: 800; font-size: 15px; color: var(--ink-2); display: flex; align-items: center; justify-content: center; }
.refs .cite { font-size: 14px; color: var(--ink-3); margin: 0 0 4px; }
.refs .cite a { text-decoration: underline; text-underline-offset: 3px; }
.refs b { display: block; font-family: var(--font-head); font-size: 16.5px; margin-bottom: 4px; }
.refs p { margin: 0; font-size: 15.5px; color: var(--ink-2); }
.refs .tag { display: inline-block; font-size: 12px; font-weight: 800; padding: 2px 10px; border-radius: 20px; background: var(--blue-xl); color: var(--blue-d); margin-top: 8px; }

/* =========================================================
   相性診断ページ
   ========================================================= */
.compat-hero { background: var(--red-xl); padding: 60px 0 60px; text-align: center; position: relative; overflow: hidden; }
.compat-hero h1 { font-size: clamp(30px, 4vw, 44px); }
.compat-hero p { color: var(--ink-2); max-width: 680px; margin: 0 auto; }
.compat-form { display: grid; grid-template-columns: 1fr 70px 1fr; gap: 20px; align-items: center; max-width: 1000px; margin: -30px auto 0; position: relative; z-index: 2; }
.compat-side { background: #fff; border-radius: 18px; box-shadow: var(--shadow-lg); padding: 24px; }
.compat-side h2 { font-size: 18px; margin: 0 0 14px; display: flex; align-items: center; gap: 8px; }
.compat-side h2 svg { width: 22px; height: 22px; color: var(--ink-3); }
.compat-side .owner-picker { grid-template-columns: 1fr 1fr; }
.compat-x { display: flex; align-items: center; justify-content: center; }
.compat-x svg { width: 56px; height: 56px; color: var(--red); filter: drop-shadow(0 6px 12px rgba(242, 94, 98, .35)); }
.dog-select { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.dog-select button { border: 2px solid transparent; background: var(--bg-soft); border-radius: 12px; padding: 8px 4px 6px; cursor: pointer; transition: .15s; text-align: center; min-width: 0; }
.dog-select button img { width: 44px; height: 44px; margin: 0 auto 2px; }
.dog-select button b { display: block; font-family: "Inter", sans-serif; font-size: 12.5px; letter-spacing: .02em; }
.dog-select button small { display: block; font-size: 10.5px; color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dog-select button:hover { background: var(--g-xl); }
.dog-select button.is-on { border-color: var(--g); background: var(--g-xl); }
@media (max-width: 860px) { .compat-form { grid-template-columns: 1fr; margin-top: -20px; } .compat-x svg { width: 40px; height: 40px; transform: rotate(90deg); } }

.ranking { max-width: 900px; margin: 40px auto 0; }
.ranking h3 { font-size: 20px; text-align: center; margin-bottom: 18px; }
.rank-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 24px; }
.rank-list li { display: grid; grid-template-columns: 30px 64px 1fr 46px; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid var(--line-2); font-size: 14.5px; }
.rank-list .r { font-family: "Inter", sans-serif; font-weight: 800; color: var(--ink-3); text-align: right; }
.rank-list .m { font-family: "Inter", sans-serif; font-weight: 800; letter-spacing: .02em; }
.rank-list .bar { height: 8px; border-radius: 8px; background: var(--red-l); overflow: hidden; }
.rank-list .bar i { display: block; height: 100%; background: var(--red); border-radius: 8px; }
.rank-list .s { font-family: "Inter", sans-serif; font-weight: 700; text-align: right; color: var(--ink-2); }
.rank-list li.is-me { background: var(--red-xl); border-radius: 8px; padding-left: 6px; padding-right: 6px; }
@media (max-width: 700px) { .rank-list { grid-template-columns: 1fr; } }

/* ---------- その他 ---------- */
.notice { font-size: 13.5px; color: var(--ink-3); line-height: 1.7; }
.fade-up { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.fade-up.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
  .fade-up { opacity: 1; transform: none; }
}
@media print {
  .site-header, .site-footer, .toc, .share-box, .quiz-progress { display: none !important; }
}

/* ---------- 狭い画面での調整 ---------- */
@media (max-width: 560px) {
  .btn { white-space: normal; max-width: 100%; text-align: center; padding-left: 26px; padding-right: 26px; }
  .type-nav { grid-template-columns: 1fr; }
  .type-nav img { width: 48px; height: 48px; }
}
@media (max-width: 400px) {
  .code-anatomy { gap: 4px; }
  .code-anatomy .ch { width: 50px; }
  .code-anatomy .ch b { height: 50px; font-size: 26px; }
  .code-anatomy .dash { height: 50px; font-size: 24px; }
}
body.page-test .toast { bottom: calc(80px + env(safe-area-inset-bottom)); }
.code-anatomy .ch span { word-break: keep-all; }

/* ---------- 相性（数値を出さない表示） ---------- */
.compat-badge { width: 150px; height: 150px; border-radius: 50%; background: var(--red-l); display: flex; align-items: center; justify-content: center; color: var(--red); flex: none; }
.compat-badge svg { width: 92px; height: 92px; filter: drop-shadow(0 8px 14px rgba(242, 94, 98, .3)); }
.compat-score { grid-template-columns: 160px 1fr; }
.compat-tags { list-style: none; padding: 0; margin: 14px 0 0; display: flex; flex-wrap: wrap; gap: 8px; }
.compat-tags li { font-size: 13.5px; font-weight: 700; padding: 5px 12px; border-radius: 30px; }
.compat-tags .same { background: var(--green-xl); color: var(--green-d); }
.compat-tags .diff { background: var(--blue-xl); color: var(--blue-d); }
.tier-groups { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.tier-group { background: #fff; border-radius: 14px; box-shadow: var(--shadow); padding: 16px; text-align: center; }
.tier-group b { display: block; font-family: var(--font-head); color: var(--red-d); margin-bottom: 10px; }
.tier-group ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; }
.tier-group li { font-family: "Inter", sans-serif; font-weight: 800; font-size: 14px; padding: 4px 10px; border-radius: 8px; background: var(--bg-soft); }
.tier-group li.is-me { background: var(--ink); color: #fff; }
.compat-mock__score b { font-size: 30px; letter-spacing: 0; font-family: var(--font-head); }
.compat-mock__score span { font-size: 14px; color: var(--ink-2); font-weight: 600; }
@media (max-width: 860px) { .tier-groups { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px) { .compat-badge { margin: 0 auto; } }
.logo__en { font-weight: 900; letter-spacing: .02em; }
.logo__type { color: var(--purple); font-weight: 800; }
