/* はじめてのミーグリ（村の版）。絵本の絵地図に合わせ、ペンの線・淡い塗り・紙の色でそろえる。
   --hc / --hd はその家の色（body の style で渡す）。 */
:root {
  --paper: #FBF7EC;
  --paper-2: #F4ECD9;
  --ink: #43362A;
  --ink-soft: #77695A;
  --leaf: #B5D2A2;
  --leaf-d: #4C7A3E;
  --sun: #F4D987;
  --rose: #EBAEB4;
  --berry: #B8472F;
  --hc: #DE9373;
  --hd: #A4472D;
  --hand: "Klee One", "Hiragino Maru Gothic ProN", sans-serif;
  --body: "LINE Seed JP", "Hiragino Sans", "Noto Sans JP", sans-serif;
  --wob: 7px 10px 6px 9px / 9px 6px 10px 7px;
}
/* 家の色から作る淡い塗り。家の色を渡した要素ごとに計算し直す */
body, .nextcard, .spot, .hcard { --wash: color-mix(in srgb, var(--hc) 32%, var(--paper)); }
*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 64px; }
body {
  margin: 0; color: var(--ink); font: 400 16px/1.85 var(--body);
  background: var(--paper) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 .26 0 0 0 0 .21 0 0 0 0 .16 0 0 0 .055 0'/%3E%3C/filter%3E%3Crect width='220' height='220' filter='url(%23n)'/%3E%3C/svg%3E");
  padding-bottom: calc(84px + env(safe-area-inset-bottom));
}
body[data-page="index"] { padding-bottom: 0; }
body[data-page="index"] .page { padding-top: 12px; }
a { color: var(--hd); text-underline-offset: 3px; }
h1, h2, h3 { font-family: var(--hand); font-weight: 600; line-height: 1.45; margin: 0; text-wrap: balance; }
p, ul, ol, dl { margin: 0; }
img, svg { max-width: 100%; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--hd); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; z-index: 99; background: var(--paper); padding: 8px 12px; }
.i { flex: none; }

.top { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 10px; padding: 10px 16px; background: color-mix(in srgb, var(--paper) 92%, transparent); backdrop-filter: blur(6px); border-bottom: 1.5px solid var(--ink); }
.top__name { font: 600 16px/1 var(--hand); color: var(--ink); text-decoration: none; }
.top__tag { margin-left: auto; font-size: 11px; font-weight: 700; line-height: 1; padding: 5px 8px; border: 1.5px solid var(--ink); border-radius: 99px; }

.page { max-width: 640px; margin: 0 auto; padding: 22px 18px 8px; }
.page > * + *, .house__side > * + *, .house__main > * + *, .pane > * + * { margin-top: 18px; }
:is(.page, .house__main, .pane) > h2 { margin-top: 44px; font-size: 21px; padding-bottom: 6px; background: linear-gradient(var(--wash), var(--wash)) 0 100% / 100% 9px no-repeat; }
.page h3 { font-size: 17px; }
.page ul, .page ol { padding-left: 1.3em; }
.page li + li { margin-top: 6px; }

/* 入口 */
.gate { text-align: center; }
.gate h1 { font-size: clamp(26px, 7.6vw, 34px); letter-spacing: .04em; }
.gate p { margin-top: 0; font-size: 13px; color: var(--ink-soft); }
.gate__seen { font-family: var(--hand); font-weight: 600; color: var(--leaf-d) !important; }

/* 絵地図 */
.map { position: relative; max-width: 460px; margin: 6px auto 0 !important; }
.map__art { display: block; width: 100%; height: auto; }
img.map__art { mix-blend-mode: multiply; -webkit-mask: linear-gradient(to right, transparent, #000 7%, #000 93%, transparent), linear-gradient(to bottom, transparent, #000 4%, #000 96%, transparent); -webkit-mask-composite: source-in; mask: linear-gradient(to right, transparent, #000 7%, #000 93%, transparent), linear-gradient(to bottom, transparent, #000 4%, #000 96%, transparent); mask-composite: intersect; }
.map__art .w { opacity: .9; }
.map__art .k, .map__art .h { vector-effect: non-scaling-stroke; }
.map__art .k { fill: none; stroke: var(--ink); stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.map__art .h { fill: none; stroke: var(--ink); stroke-width: 1.1; stroke-linecap: round; opacity: .75; }
.map__art .dot { fill: var(--ink); }
.map__txt { font: 600 11px var(--hand); fill: var(--ink); }
.spot { position: absolute; display: flex; flex-direction: column; align-items: center; justify-content: flex-start; padding-top: 24%; gap: 3px; color: var(--ink); text-decoration: none; -webkit-tap-highlight-color: transparent; }
.spot__sign { display: flex; align-items: center; gap: 5px; padding: 6px 9px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 3px 3px 0 var(--hc); font: 600 12.5px/1.3 var(--hand); white-space: nowrap; transition: transform .15s; }
.spot__title small { margin-left: 8px; font: 400 11px/1 var(--body); color: var(--ink-soft); }
.spot__no { flex: none; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--hd); color: #fff; font: 700 12px/1 var(--body); }
.spot__who { display: flex; align-items: center; gap: 4px; font-size: 11px; line-height: 1.3; color: var(--ink-soft); background: color-mix(in srgb, var(--paper) 82%, transparent); border-radius: 99px; padding: 1px 7px 1px 2px; }
.spot--board .spot__who { padding-left: 7px; }
.spot__who .av { width: 22px; height: 22px; font-size: 11px; border-width: 1.2px; margin-right: -2px; }
.spot__who .av + span { margin-left: 3px; }
.spot__seen { flex: none; width: 16px; height: 16px; border-radius: 50%; background: var(--leaf-d) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23fff' stroke-width='3.4' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 12.5l4 4L18 8'/%3E%3C/svg%3E") center / 12px no-repeat; }
/* 家の中の会話が、屋根の上にひとことずつ浮かぶ */
.murmur { position: absolute; bottom: calc(100% - 14px); display: grid; padding: 4px 9px; background: color-mix(in srgb, var(--wash) 45%, var(--paper)); border: 1.3px solid var(--ink); border-radius: 10px 12px 11px 9px / 11px 9px 12px 10px; font: 500 11px/1.35 var(--hand); white-space: nowrap; pointer-events: none; animation: murmur-bob 5.5s ease-in-out var(--d) infinite; }
.map--tall .murmur { display: none; } /* 縦長の地図は家が近く、札と重なるので出さない */
.murmur--r { left: 54%; }
.murmur--l { right: 54%; }
.murmur::before, .murmur::after { content: ""; position: absolute; border: 1.3px solid var(--ink); border-radius: 50%; background: inherit; }
.murmur::before { width: 7px; height: 7px; bottom: -9px; }
.murmur::after { width: 4px; height: 4px; bottom: -15px; }
.murmur--r::before { left: 10px; } .murmur--r::after { left: 4px; }
.murmur--l::before { right: 10px; } .murmur--l::after { right: 4px; }
.murmur > span { grid-area: 1 / 1; text-align: center; opacity: 0; animation: murmur-say calc(var(--n) * 4.5s) linear calc(var(--i) * 4.5s + var(--d)) infinite; }
@keyframes murmur-say { 0% { opacity: 0; } 3% { opacity: 1; } 30% { opacity: 1; } 33.3% { opacity: 0; } 100% { opacity: 0; } }
@keyframes murmur-bob { 50% { transform: translateY(-4px); } }
.spot:active .spot__sign { transform: translateY(2px) rotate(-1deg); }
@media (hover: hover) { .spot:hover .spot__sign { transform: translateY(-2px) rotate(-1.5deg); } }

/* 住人の顔 */
.av { flex: none; width: 46px; height: 46px; border-radius: 50%; border: 1.5px solid var(--ink); background: var(--paper); object-fit: cover; }
.av--ph { display: grid; place-items: center; background: color-mix(in srgb, var(--tint) 62%, var(--paper)); font: 600 20px/1 var(--hand); color: var(--ink); }

/* 家の札 */
.plank { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--wash); border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 4px 4px 0 var(--hc); transform: rotate(-.6deg); }
.plank__no { flex: none; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--hd); color: #fff; font: 700 20px/1 var(--body); }
.plank__owner { font: 600 13px/1.2 var(--hand); color: var(--hd); }
.plank h1, .page > h1 { font-size: clamp(22px, 6.4vw, 27px); }

/* 会話 */
.talk { display: grid; gap: 10px; }
.say { display: flex; gap: 10px; align-items: flex-start; }
.say > p { flex: 1; padding: 9px 13px; background: #fff; border: 1.5px solid var(--ink); border-radius: 3px 10px 9px 11px / 3px 9px 11px 10px; font-family: var(--hand); line-height: 1.7; }
.say__name { display: block; font-size: 12px; color: var(--ink-soft); }
.say[data-who="meet"] { flex-direction: row-reverse; }
.say[data-who="meet"] > p { border-radius: 10px 3px 11px 9px / 9px 3px 10px 11px; background: color-mix(in srgb, var(--rose) 22%, #fff); }
.vn { border: 1.5px solid var(--ink); border-radius: var(--wob); overflow: hidden; background: #fff; cursor: pointer; user-select: none; -webkit-tap-highlight-color: transparent; box-shadow: 4px 4px 0 var(--hc); }
.vn__stage { position: relative; height: clamp(190px, 52vw, 250px); background: radial-gradient(120% 90% at 20% 0%, color-mix(in srgb, var(--hc) 30%, var(--paper)), transparent 60%), radial-gradient(90% 80% at 100% 30%, color-mix(in srgb, var(--hc) 20%, var(--paper)), transparent 65%), var(--paper-2); border-bottom: 1.5px solid var(--ink); overflow: hidden; }
.vn__stage::before { content: ""; position: absolute; left: 0; right: 0; bottom: 22%; border-top: 1.5px solid var(--ink); opacity: .45; }
.vn__stage::after { content: ""; position: absolute; right: 9%; top: 12%; width: 54px; height: 54px; border: 1.5px solid var(--ink); border-radius: 50%; background: linear-gradient(var(--ink), var(--ink)) 50% 0 / 1.5px 100% no-repeat, linear-gradient(var(--ink), var(--ink)) 0 50% / 100% 1.5px no-repeat, #EAF3F0; opacity: .7; }
.talk--room .vn__stage { height: auto; aspect-ratio: 3 / 2; background: var(--room) center / cover; }
.talk--room .vn__stage::before, .talk--room .vn__stage::after { display: none; }
.vn__place { position: absolute; left: 10px; top: 9px; z-index: 2; font: 600 12px/1 var(--hand); padding: 5px 9px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: 99px; }
.vn__cast { position: absolute; inset: auto 0 0 0; z-index: 1; display: flex; justify-content: center; align-items: flex-end; gap: 10px; padding: 0 12px 14px; }
.vn__who { flex: none; display: grid; justify-items: center; gap: 3px; transition: transform .25s cubic-bezier(.2, 1.3, .4, 1), opacity .25s; transform: scale(.62); transform-origin: 50% 100%; opacity: .72; margin: 0 -14px; }
/* 家の会話では、ミートを左、住人を右に離して、向かい合って話しているように見せる */
.talk:not(.talk--intro) .vn__cast { justify-content: flex-end; padding: 0 9% 14px; }
.talk:not(.talk--intro) .vn__cast .vn__who:first-child { margin-left: 0; margin-right: auto; }
.vn__who .av { width: min(124px, 27vw); height: min(124px, 27vw); font-size: 54px; border-width: 2px; }
.vn__who small { font: 600 13px/1 var(--hand); }
.vn__who.is-on { transform: scale(1); opacity: 1; margin: 0; }
.vn__who.is-hop .av { animation: hop .32s; }
@keyframes hop { 40% { transform: translateY(-9px); } }
.vn__box { position: relative; min-height: 124px; padding: 12px 16px 26px; font-family: var(--hand); }
.vn__name { display: inline-block; font-size: 14px; padding: 1px 10px; border-radius: 99px; background: color-mix(in srgb, var(--tint, var(--hc)) 55%, var(--paper)); }
.vn__text { margin-top: 6px; font-size: 17px; line-height: 1.75; }
.vn__note, .say__note { display: block; margin-top: 6px; font: 400 12.5px/1.6 var(--body); color: var(--ink-soft); }
.vn__note:empty { display: none; }
.say__note--tap { display: flex; align-items: center; gap: 8px; width: fit-content; margin-top: 10px; padding: 5px 12px 5px 8px; border: 1.5px dashed var(--ink); border-radius: 99px; background: var(--paper); font: 600 13px/1.4 var(--hand); color: var(--ink); cursor: pointer; }
.say__note--tap::before { content: "＋"; flex: none; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--hd); color: #fff; font: 700 12px/1 var(--body); }
.say__note--tap:hover { background: #fff; }
.vn__next { position: absolute; right: 16px; bottom: 9px; width: 0; height: 0; border: 7px solid transparent; border-top: 9px solid var(--hd); border-bottom: 0; opacity: 0; }
.vn.is-wait:not(.is-end) .vn__next { opacity: 1; animation: bob 1s infinite; }
@keyframes bob { 50% { transform: translateY(4px); } }
.vn__foot { display: flex; align-items: center; gap: 12px; margin-top: 8px !important; font-size: 13px; color: var(--ink-soft); }
.vn__foot button { margin-left: auto; background: none; border: 0; padding: 6px 2px; color: var(--hd); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; font-size: 13px; }
.vn__foot button + button { margin-left: 0; }
.vn__log { display: grid; gap: 10px; }

/* この家の中の近道 */
.jump { display: flex; gap: 8px; overflow-x: auto; margin-inline: -18px; padding: 2px 18px 6px; scrollbar-width: none; }
.jump a { flex: none; font: 600 13.5px/1 var(--hand); padding: 9px 12px; color: var(--ink); text-decoration: none; background: var(--paper); border: 1.5px solid var(--ink); border-radius: 99px; }

/* 札つきの情報 */
.note { padding: 12px 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; }
.note__label { display: inline-block; font: 600 12.5px/1 var(--hand); padding: 5px 9px; border-radius: 99px; margin-bottom: 7px; background: var(--leaf); }
.note--tip .note__label { background: var(--sun); }
.note--voice .note__label { background: var(--rose); }
.note--unknown { border-style: dashed; background: transparent; }
.note--unknown .note__label { background: none; border: 1.5px dashed var(--ink); }
.note__body > * + * { margin-top: 6px; }
.note__src { margin-top: 8px; font-size: 11.5px; line-height: 1.6; color: var(--ink-soft); }
.note__src a { color: inherit; }

.kv { display: grid; border: 1.5px solid var(--ink); border-radius: var(--wob); overflow: hidden; background: #fff; }
.kv > div { display: grid; grid-template-columns: 6.6em 1fr; gap: 10px; padding: 10px 14px; }
.kv > div + div { border-top: 1.5px dashed color-mix(in srgb, var(--ink) 45%, transparent); }
.kv dt { font-family: var(--hand); font-weight: 600; }
.kv dd { margin: 0; }

.steps { list-style: none; padding: 0 !important; counter-reset: s; display: grid; gap: 12px; }
.steps > li { counter-increment: s; position: relative; padding-left: 44px; margin: 0 !important; }
.steps > li::before { content: counter(s); position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 30px; height: 30px; border: 1.5px solid var(--ink); border-radius: 50%; background: var(--wash); font: 700 14px/1 var(--body); }
.steps > li:not(:last-child)::after { content: ""; position: absolute; left: 14px; top: 34px; bottom: -10px; border-left: 1.5px dashed var(--ink); opacity: .5; }
.steps__mark { display: inline-block; font: 700 11.5px/1 var(--body); padding: 4px 7px; border-radius: 99px; background: var(--berry); color: #fff; vertical-align: middle; }

.cmp { display: grid; gap: 12px; }
.cmp__row { padding: 12px 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; }
.cmp__row > b { font: 600 17px var(--hand); }
.cmp__row > p { margin-top: 8px; font-size: 14.5px; }
.flow { list-style: none; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 6px 4px; margin-top: 8px; }
.flow li { margin: 0 !important; display: flex; align-items: center; font: 600 13.5px/1.2 var(--hand); padding: 7px 10px; border: 1.5px solid var(--ink); border-radius: 6px; background: var(--paper); }
.flow li + li::before { content: "→"; margin: 0 8px 0 -22px; transform: translateX(-4px); }
.flow li + li { margin-left: 18px !important; }
.flow__pay { background: var(--sun) !important; }

.when { list-style: none; padding: 0 !important; display: grid; border-left: 1.5px solid var(--ink); margin-left: 6px; }
.when li { position: relative; display: grid; grid-template-columns: 7em 1fr; gap: 8px; padding: 6px 0 6px 18px; margin: 0 !important; }
.when li::before { content: ""; position: absolute; left: -6.5px; top: 15px; width: 10px; height: 10px; border-radius: 50%; background: var(--paper); border: 1.5px solid var(--ink); }
.when__d { font-family: var(--hand); font-weight: 600; }
.when .is-key::before { background: var(--berry); }
.when .is-key { font-weight: 700; }

.tablewrap { overflow-x: auto; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; }
.tbl { width: 100%; border-collapse: collapse; font-size: 14.5px; text-align: center; }
.tbl th, .tbl td { padding: 8px 6px; }
.tbl thead th { font: 600 13px var(--hand); background: var(--wash); }
.tbl tbody tr + tr > * { border-top: 1.5px dashed color-mix(in srgb, var(--ink) 40%, transparent); }
.tbl tbody th { font-family: var(--hand); }

/* チェック */
.check { list-style: none; padding: 0 !important; display: grid; gap: 8px; }
.check li { margin: 0 !important; }
.check label { display: flex; gap: 10px; align-items: flex-start; padding: 11px 12px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; cursor: pointer; }
.check input { appearance: none; flex: none; width: 22px; height: 22px; margin: 3px 0 0; border: 1.5px solid var(--ink); border-radius: 6px 7px 5px 8px; background: var(--paper); cursor: pointer; }
.check input:checked { background: var(--leaf) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2343362A' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7'/%3E%3C/svg%3E") center / 16px no-repeat; }
.check label:has(input:checked) { background: color-mix(in srgb, var(--leaf) 28%, #fff); }
.checkbar { font: 600 13px/1 var(--hand); color: var(--leaf-d); text-align: right; margin-bottom: -10px; }
.checknote { font-size: 12px; color: var(--ink-soft); margin-top: 8px !important; }

/* 押すもの */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 46px; padding: 8px 18px; font: 600 15px/1.2 var(--hand); color: var(--ink); text-decoration: none; background: var(--wash); border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 3px 3px 0 var(--hc); cursor: pointer; transition: transform .1s, box-shadow .1s; }
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--hc); }
.btn--sub { background: var(--paper); }
.btn--big { width: 100%; min-height: 54px; font-size: 17px; }
.seg { display: flex; border: 1.5px solid var(--ink); border-radius: 7px; overflow: hidden; background: #fff; }
.seg label { flex: 1; position: relative; text-align: center; cursor: pointer; }
.seg label + label { border-left: 1.5px solid var(--ink); }
.seg input { position: absolute; opacity: 0; inset: 0; }
.seg span { display: block; padding: 10px 4px; font: 600 13.5px/1.3 var(--hand); }
.seg input:checked + span { background: var(--wash); }
.seg input:focus-visible + span { outline: 3px solid var(--hd); outline-offset: -3px; }

/* 費用の目安 */
.calc { display: grid; gap: 12px; padding: 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; }
.calc__row { display: flex; align-items: center; justify-content: space-between; font-family: var(--hand); font-weight: 600; }
.stepper { display: flex; align-items: center; gap: 4px; }
.stepper button { width: 44px; height: 44px; border: 1.5px solid var(--ink); border-radius: 50%; background: var(--wash); font-size: 20px; line-height: 1; cursor: pointer; }
.stepper output { min-width: 2.2em; text-align: center; font: 700 22px/1 var(--body); }
.calc__sum > div { display: flex; justify-content: space-between; gap: 10px; padding: 5px 0; font-size: 14.5px; }
.calc__total { border-top: 1.5px solid var(--ink); margin-top: 4px; padding-top: 9px !important; font-family: var(--hand); font-weight: 600; align-items: baseline; }
.calc__total b { font: 700 28px/1 var(--body); margin-right: 2px; }

/* シリアル1枚のゆくえ */
.sim { display: grid; gap: 12px; padding: 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; }
.sim__title { font: 600 15px var(--hand); }
.sim__ticket { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 14px; border: 1.5px dashed var(--ink); border-radius: 6px; background: var(--paper); transition: background .2s, opacity .2s; }
.sim__code { font: 700 14px/1 ui-monospace, monospace; letter-spacing: .06em; }
.sim[data-sim="apply"] .sim__code { font: 600 15px/1.2 var(--hand); letter-spacing: 0; }
.sim__mark { font: 600 13px/1 var(--hand); }
.sim__mark:not(:empty) { padding: 6px 9px; border: 1.5px solid var(--ink); border-radius: 99px; background: #fff; transform: rotate(-4deg); }
.sim__ticket[data-state="win"], .sim__ticket[data-state="paid"], .sim__ticket[data-state="ready"] { background: color-mix(in srgb, var(--leaf) 55%, #fff); }
.sim__ticket[data-state="lose"], .sim__ticket[data-state="reapplied"] { background: color-mix(in srgb, var(--sun) 50%, #fff); }
.sim__ticket[data-state="dead"] { background: #E9E4DA; opacity: .75; }
.sim__ticket[data-state="dead"] .sim__code { text-decoration: line-through; }
.sim__btns { display: flex; flex-wrap: wrap; gap: 10px; }
.sim__trail { list-style: none; padding: 0 !important; display: flex; flex-wrap: wrap; gap: 4px 0; font-size: 12.5px; color: var(--ink-soft); }
.sim__trail li { margin: 0 !important; }
.sim__trail li + li::before { content: "→"; margin: 0 6px; }

/* 住人のやり方 */
.stance { margin-top: 44px !important; padding: 16px; background: var(--wash); border: 1.5px solid var(--ink); border-radius: var(--wob); }
.stance__head { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.stance__av { display: flex; }
.stance__oshi { margin: 2px 0 0 !important; font-size: 13px; color: var(--ink-soft); }
.stance__oshi b { font: 600 14px/1.4 var(--hand); color: var(--ink); margin-left: 4px; }
.stance__av .av + .av { margin-left: -10px; }
.stance h2 { font-size: 19px; }
.stance__note { margin-top: 10px; font-size: 12px; color: var(--ink-soft); }

/* 次の家 */
.nextcard { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 30px !important; padding: 14px 16px; color: var(--ink); text-decoration: none; background: var(--wash); border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 4px 4px 0 var(--hc); }
.nextcard span { display: grid; }
.nextcard small { font-size: 12px; color: var(--ink-soft); }
.nextcard b { font: 600 18px/1.5 var(--hand); }
.nextcard:active { transform: translate(2px, 2px); box-shadow: 2px 2px 0 var(--hc); }

/* 掲示板 */
.paper { padding: 16px; background: #fff; border: 1.5px solid var(--ink); border-radius: 3px; box-shadow: 3px 4px 0 var(--paper-2); position: relative; }
.paper:nth-of-type(odd) { transform: rotate(-.4deg); }
.paper:nth-of-type(even) { transform: rotate(.35deg); }
.paper::before { content: ""; position: absolute; top: -7px; left: 50%; width: 13px; height: 13px; margin-left: -6px; border-radius: 50%; background: var(--berry); border: 1.5px solid var(--ink); }
.paper > h2 { font-size: 19px; }
.paper > * + * { margin-top: 12px; }
.short { list-style: none; padding: 0 !important; display: grid; }
.short li { margin: 0 !important; }
.short li + li { border-top: 1.5px dashed color-mix(in srgb, var(--ink) 40%, transparent); }
.short a { display: flex; justify-content: space-between; align-items: center; gap: 10px; min-height: 48px; padding: 8px 2px; color: var(--ink); text-decoration: none; font-family: var(--hand); font-weight: 600; }
.short small { flex: none; font: 400 12px/1 var(--body); color: var(--hd); }
.sidelinks { display: flex; flex-wrap: wrap; gap: 6px 16px; font-size: 14px; }

/* 用語と出典 */
.term { color: inherit; text-decoration: underline dotted var(--hd); text-decoration-thickness: 2px; text-underline-offset: 4px; }
.glossary { display: grid; gap: 10px; }
.gloss { padding: 12px 14px; background: #fff; border: 1.5px solid var(--ink); border-radius: var(--wob); }
.gloss:target { background: color-mix(in srgb, var(--sun) 40%, #fff); }
.gloss dt { font: 600 16px var(--hand); }
.gloss dd { margin: 4px 0 0; font-size: 14.5px; }
.srclist { list-style: none; padding: 0 !important; display: grid; gap: 8px; }
.srclist li { display: grid; margin: 0 !important; font-size: 14.5px; }
.srclist span { font-size: 12px; color: var(--ink-soft); }
.sheet { width: min(100%, 520px); max-width: none; margin: auto auto 0; padding: 18px 18px calc(22px + env(safe-area-inset-bottom)); border: 1.5px solid var(--ink); border-bottom: 0; border-radius: 11px 9px 0 0; background: var(--paper); color: var(--ink); }
.sheet::backdrop { background: rgba(67, 54, 42, .4); }
.sheet__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.sheet__head h2 { font-size: 20px; }
.sheet__close { display: grid; place-items: center; width: 44px; height: 44px; background: none; border: 0; cursor: pointer; }
.sheet__links { margin-top: 12px; font-size: 13.5px; }

.foot { max-width: 640px; margin: 44px auto 0; padding: 18px 18px 26px; border-top: 1.5px dashed var(--ink); font-size: 12px; line-height: 1.75; color: var(--ink-soft); }
.foot p + p { margin-top: 6px; }
.foot__links { display: flex; gap: 16px; }

.nav { position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 8px; padding: 8px 12px calc(8px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--paper) 94%, transparent); backdrop-filter: blur(6px); border-top: 1.5px solid var(--ink); }
.nav a { display: flex; align-items: center; gap: 4px; min-height: 48px; color: var(--ink); text-decoration: none; font: 600 13px/1.25 var(--hand); }
.nav__side span { overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.nav__side--next { justify-content: flex-end; text-align: right; }
.nav__map { flex-direction: column; justify-content: center; gap: 0 !important; width: 64px; height: 52px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: var(--wash); box-shadow: 2px 3px 0 var(--hc); font-size: 11px !important; }

/* 練習 */
.practice { display: grid; gap: 12px; padding: 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; }
.practice__label { font: 600 15px var(--hand); margin-bottom: -6px; }
.practice textarea { width: 100%; padding: 10px 12px; font: 600 16px/1.6 var(--hand); color: var(--ink); background: var(--paper); border: 1.5px solid var(--ink); border-radius: 7px; resize: vertical; }
.ideas { display: flex; flex-wrap: wrap; gap: 6px; }
.ideas button { padding: 7px 10px; font: 400 12.5px/1.2 var(--body); background: var(--paper); border: 1.5px dashed var(--ink); border-radius: 99px; cursor: pointer; }
.toggle { display: flex; gap: 8px; align-items: flex-start; font-size: 14px; cursor: pointer; }
.toggle input { width: 20px; height: 20px; margin: 4px 0 0; accent-color: var(--hd); }
.stage { position: fixed; inset: 0; z-index: 60; margin: 0 !important; background: #E4F1F5; overflow: hidden; display: grid; grid-template-rows: auto 1fr auto; }
.stage[hidden] { display: none; }
.stage__who { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; transition: filter .5s, transform .6s; }
.sprite { flex: none; width: clamp(104vw, 62vh, 132vw); aspect-ratio: 1; margin-top: 4vh; background-repeat: no-repeat; background-size: 300% 200%; transform: translate(var(--fx, 0), var(--fy, 0)); }
.sprite.is-none { width: 0; }
@media (min-aspect-ratio: 4/5) { .sprite { width: min(88vh, 96vw); margin-top: 6vh; } }
.stage.is-wait .stage__who { filter: blur(14px) brightness(.6) saturate(.7); transform: scale(1.08); }
.stage__top { position: relative; z-index: 2; padding: calc(12px + env(safe-area-inset-top)) 16px 0; text-align: center; font: 600 15px/1.4 var(--hand); }
.stage__bar { display: block; height: 10px; margin-bottom: 6px; border: 1.5px solid var(--ink); border-radius: 99px; background: linear-gradient(var(--hd), var(--hd)) 0 0 / calc(var(--left, 1) * 100%) 100% no-repeat, #fff; }
.stage.is-last .stage__bar { background-image: linear-gradient(var(--berry), var(--berry)); }
.stage__mid { position: relative; z-index: 2; display: grid; align-content: start; justify-items: center; gap: 10px; padding: 14px 16px; }
.stage.is-wait .stage__mid { align-content: center; color: #fff; }
.stage__msg { font: 600 22px var(--hand); }
.stage__count { font: 700 96px/1 var(--body); }
.stage__count.is-tick { animation: tick .8s; }
@keyframes tick { from { transform: scale(1.5); opacity: .2; } }
.stage__bubble { max-width: 300px; padding: 10px 16px; font: 600 16px/1.6 var(--hand); background: #fff; border: 1.5px solid var(--ink); border-radius: 11px 10px 11px 3px; }
.stage__alert { padding: 8px 16px; font: 700 15px/1.3 var(--body); color: #fff; background: var(--berry); border-radius: 99px; animation: tick .4s; }
.stage__me, .stage__you { position: absolute; z-index: 3; left: 14px; bottom: calc(150px + env(safe-area-inset-bottom)); width: 86px; height: 116px; border: 1.5px solid var(--ink); border-radius: 7px; background: var(--paper-2); object-fit: cover; transform: scaleX(-1); }
.stage__you { display: grid; place-items: center; transform: none; font: 600 12px var(--hand); color: var(--ink-soft); }
.stage__foot { position: relative; z-index: 3; grid-row: 3; display: grid; gap: 10px; padding: 12px 16px calc(14px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--paper) 92%, transparent); border-top: 1.5px solid var(--ink); }
.stage__memo { display: grid; font: 600 16px/1.5 var(--hand); }
.stage__memo small { font: 400 11.5px/1.4 var(--body); color: var(--ink-soft); }
.stage__actions { display: flex; gap: 10px; justify-content: flex-end; }

/* 入口の会話 */
.gate__again { background: none; border: 0; padding: 2px 0; font: 600 13px/1.3 var(--hand); color: var(--hd); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.talk--intro { max-width: 460px; margin: 10px auto 14px !important; --hc: #D9A866; --hd: #8F6124; }
.vn__foot .intro__skip { border: 1.5px solid var(--ink); border-radius: 99px; background: var(--paper); padding: 5px 14px !important; font: 600 13px/1.3 var(--hand); color: var(--ink) !important; text-decoration: none !important; cursor: pointer; }
.vn__foot .intro__skip.is-go { background: var(--hd); border-color: var(--hd); color: #fff !important; }
.talk--intro .vn__again { display: none; }
.intro__ends { display: flex; flex-wrap: wrap; gap: 8px; margin-left: auto; }
.vn__foot a.intro__skip { display: inline-block; }
.talk--intro.is-last .vn__count, .talk--intro.is-last .vn__toggle { display: none; }
/* 会話の前のテロップ */
.telop { position: fixed; inset: 0; z-index: 40; display: grid; place-items: center; cursor: pointer; background: color-mix(in srgb, var(--paper) 55%, transparent); }
.telop p { display: grid; gap: 6px; justify-items: center; padding: 18px 44px; border-top: 1.5px solid var(--ink); border-bottom: 1.5px solid var(--ink); background: var(--paper); animation: telop 2.6s ease both; }
.telop b { font: 600 clamp(24px, 4vw, 38px)/1.3 var(--hand); letter-spacing: .12em; }
.telop span { font: 400 clamp(14px, 2vw, 18px)/1.4 var(--hand); letter-spacing: .2em; color: var(--ink-soft); }
@keyframes telop { 0% { opacity: 0; transform: translateY(8px); } 18% { opacity: 1; transform: none; } 82% { opacity: 1; } 100% { opacity: 0; } }
.is-telop .talk--intro { visibility: hidden; }
/* せりふに合わせて、地図のその部分を目立たせる */
.spot__sign, .spot__who, .murmur { transition: opacity .3s, transform .15s; }
body[data-point="houses"] .spot--board, body[data-point="houses"] .murmur,
body[data-point="murmur"] .spot__sign, body[data-point="murmur"] .spot__who,
body[data-point="board"] .spot:not(.spot--board) { opacity: .3; }
body[data-point="houses"] .spot:not(.spot--board) .spot__sign,
body[data-point="board"] .spot--board .spot__sign { animation: point 1.1s ease-in-out infinite; }
body[data-point="murmur"] .murmur { background: #fff; box-shadow: 0 0 0 4px color-mix(in srgb, var(--hc) 70%, transparent); }
@keyframes point { 50% { transform: translateY(-5px) scale(1.06); } }

/* 村の住人 */
.lead { color: var(--ink-soft); }
.whos { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.who { --wash: color-mix(in srgb, var(--hc, var(--sky)) 32%, var(--paper)); display: grid; grid-template-rows: auto 1fr; background: #fff; border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 4px 4px 0 var(--hc, var(--paper-2)); overflow: hidden; }
.who:target { outline: 3px solid var(--sun); }
.who__art, .who__face { display: block; width: 100%; height: 230px; background: var(--wash); border-bottom: 1.5px solid var(--ink); }
.who__art { object-fit: contain; mix-blend-mode: multiply; background: none; }
.who:has(.who__art) { background: linear-gradient(var(--wash) 230px, #fff 230px); }
.who__face { display: grid; place-items: center; }
.who__face .av { width: 150px; height: 150px; border-width: 2px; }
.who__body { display: flex; flex-direction: column; gap: 6px; padding: 14px 16px 16px; }
.who__body h2 { font-size: 23px; margin: 0; }
.who__kind { font: 600 13px/1.3 var(--hand); color: var(--hd, var(--ink-soft)); margin: 0; }
.who__body p { margin: 0; }
.who__kv { display: grid; gap: 4px; margin: 4px 0 0; font-size: 14px; }
.who__kv div { display: grid; grid-template-columns: 4.2em 1fr; gap: 8px; }
.who__kv dt { color: var(--ink-soft); }
.who__kv dd { margin: 0; font-family: var(--hand); font-weight: 600; }
.who__home { margin-top: auto; padding-top: 10px; font: 600 15px/1.4 var(--hand); color: var(--hd); }
.who__home small { display: block; font: 400 12.5px/1.4 var(--body); color: var(--ink-soft); }
.castnote { margin-top: 18px; font-size: 13px; color: var(--ink-soft); }

/* 発売の前に申し込み、発売のあとに話す、を1本の帯で見せる */
.tl { margin: 14px 0; padding: 14px 16px 18px; background: #fff; border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 4px 4px 0 var(--hc); }
.tl figcaption { font: 600 16px/1.4 var(--hand); margin-bottom: 30px; }
.tl__body { position: relative; }
.tl__months { display: flex; border-bottom: 1.5px solid var(--ink); font: 600 13px/1.6 var(--hand); color: var(--ink-soft); }
.tl__months span { padding-left: 4px; border-left: 1.5px dashed color-mix(in srgb, var(--ink) 30%, transparent); }
.tl__months span:first-child { border-left: 0; }
.tl__row { position: relative; height: 54px; margin-top: 8px; }
.tl__span { position: absolute; top: 0; bottom: 0; display: flex; flex-direction: column; justify-content: center; padding: 0 10px; border: 1.5px solid var(--ink); border-radius: 6px; white-space: nowrap; overflow: hidden; }
.tl__span b { font: 600 16px/1.3 var(--hand); }
.tl__span small { font-size: 11.5px; line-height: 1.3; color: var(--ink-soft); }
.tl__span--apply { background: color-mix(in srgb, var(--leaf) 45%, #fff); }
.tl__span--talk { background: color-mix(in srgb, var(--sky, #A9D2E0) 55%, #fff); }
.tl__release { position: absolute; top: -26px; bottom: -4px; width: 0; border-left: 2.5px solid var(--berry); }
.tl__release b { position: absolute; top: 0; left: 0; transform: translateX(-50%); padding: 1px 9px; border-radius: 99px; background: var(--berry); color: #fff; font: 600 12px/1.6 var(--hand); white-space: nowrap; }

/* 日付まで正確なカレンダー */
.more { margin-top: 8px; font: 600 14.5px/1.5 var(--hand); }
.cal { margin: 14px 0; padding: 16px 16px 18px; background: #fff; border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 4px 4px 0 var(--paper-2); }
.cal__legend { display: flex; flex-wrap: wrap; gap: 4px 16px; list-style: none; margin: 0 0 14px; padding: 0; font-size: 13px; }
.cal__legend li { display: flex; align-items: center; gap: 6px; }
.cal__months { display: grid; gap: 18px 22px; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }
.cal__month p { margin: 0 0 4px; font: 600 17px/1.2 var(--hand); }
.cal__grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; font-size: 13px; text-align: center; }
.cal__grid em { font-style: normal; font-size: 11px; color: var(--ink-soft); }
.cal__day { position: relative; padding: 4px 0 13px; border-radius: 7px; color: var(--ink-soft); }
.cal__day.is-on { color: var(--ink); font-weight: 700; background: var(--paper); }
.cal__day.is-release { background: var(--berry); color: #fff; outline: 2px solid var(--ink); outline-offset: 1px; z-index: 1; }
.cal__day.is-release small { position: absolute; left: 50%; top: -15px; transform: translateX(-50%); padding: 0 7px; border-radius: 99px; background: var(--berry); color: #fff; font: 600 11px/1.5 var(--hand); white-space: nowrap; border: 1.5px solid var(--ink); }
.cal__day.is-release .cal__dot { border-color: #fff; }
.cal__list tr.is-release td { background: color-mix(in srgb, var(--berry) 16%, #fff); font-weight: 700; }
.cal__dots { position: absolute; left: 0; right: 0; bottom: 3px; display: flex; justify-content: center; gap: 2px; }
.cal__dot { display: inline-block; flex: none; width: 9px; height: 9px; border-radius: 50%; border: 1px solid var(--ink); }
.cal__dot--news { background: #F4D987; }
.cal__dot--apply { background: #8FBF7A; }
.cal__dot--serial { background: #C9A6DD; }
.cal__dot--result { background: #fff; border-width: 2px; }
.cal__dot--release { background: var(--berry); }
.cal__dot--online { background: #7DB8D6; }
.cal__dot--real { background: #E89A5B; }
.cal__list td, .cal__list th { text-align: left; }
.page h3.cal__mh { margin: 26px 0 8px; padding-left: 10px; border-left: 6px solid var(--hc); font: 600 22px/1.3 var(--hand); }
.cal__list { table-layout: fixed; width: 100%; }
.cal__list td:first-child { width: 42%; }
.cal__list td:nth-child(2) { width: 22%; }
.cal__list td:first-child { white-space: nowrap; }
.cal__list td:nth-child(2) { white-space: nowrap; }
.cal__list .cal__dot { margin-right: 6px; vertical-align: -1px; }

.kv--stack > div { display: block; }
.kv--stack dt { width: auto; font: 600 16px/1.5 var(--hand); color: var(--ink); }
.kv--stack dd { margin: 2px 0 0; }

/* 家のページのタブ（説明／住人のやり方） */
.tabs { display: flex; gap: 6px; margin: 0 0 16px; border-bottom: 1.5px solid var(--ink); }
.tabs button { display: flex; align-items: center; gap: 7px; padding: 9px 16px 8px; border: 1.5px solid var(--ink); border-bottom: 0; border-radius: 9px 9px 0 0; background: var(--paper-2); color: var(--ink-soft); font: 600 15px/1.3 var(--hand); cursor: pointer; margin-bottom: -1.5px; }
.tabs button[aria-selected="true"] { background: var(--wash); color: var(--ink); border-bottom: 1.5px solid var(--wash); }
.tabs__av { display: flex; }
.tabs__av .av { width: 26px; height: 26px; border-width: 1.2px; }
.tabs__av .av + .av { margin-left: -8px; }
.pane > .jump:first-child { margin-top: 0; }
.pane .stance { margin-top: 0 !important; }
.pane > :first-child { margin-top: 0 !important; }
.vn__foot a.vn__go { margin-left: auto; padding: 6px 14px; border: 1.5px solid var(--hd); border-radius: 99px; background: var(--hd); color: #fff; font: 600 13.5px/1.3 var(--hand); text-decoration: none; }
.vn__foot a.vn__go + button { margin-left: 0; }
/* たたんである札（体験談・未確認） */
.note--fold > summary { display: flex; align-items: center; gap: 10px; cursor: pointer; list-style: none; }
.note--fold > summary::-webkit-details-marker { display: none; }
.note--fold > summary .note__label { margin-bottom: 0; }
.note__open { font-size: 12.5px; color: var(--ink-soft); text-decoration: underline; text-underline-offset: 3px; }
.note--fold[open] .note__open { display: none; }
.note--fold[open] > summary { margin-bottom: 7px; }
.note--fold:not([open]) { padding-top: 8px; padding-bottom: 8px; }

/* たたんである補足。押すと小さな窓で読める */
.more > summary { display: flex; align-items: center; gap: 10px; width: fit-content; max-width: 100%; padding: 8px 14px 8px 12px; border: 1.5px dashed var(--ink); border-radius: 99px; background: var(--paper); font: 600 14px/1.4 var(--hand); cursor: pointer; list-style: none; }
.more > summary::-webkit-details-marker { display: none; }
.more > summary::before { content: "＋"; flex: none; display: grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: var(--hd); color: #fff; font: 700 13px/1 var(--body); }
.more > summary:hover { background: var(--wash); }
.more[open] > summary { margin-bottom: 10px; }
.more__body > * + * { margin-top: 12px; }
.sheet--more { width: min(600px, calc(100vw - 32px)); max-height: min(78vh, 720px); overflow: auto; }
.sheet__body > * + * { margin-top: 12px; }
.sheet__body { font-size: 15px; }

.tbl--left td, .tbl--left th { text-align: left; vertical-align: top; }
.tbl--left th small { font: 400 11.5px/1.4 var(--body); color: var(--ink-soft); }

/* 会話の終わりの行き先（分かれ道） */
.vn__choices { display: grid; gap: 8px; }
.talk__next { display: flex; align-items: center; gap: 10px; padding: 11px 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: #fff; color: var(--ink); text-decoration: none; font: 600 15px/1.45 var(--hand); box-shadow: 3px 3px 0 var(--hc); }
.talk__next::after { content: "→"; margin-left: auto; color: var(--hd); }
.talk__next.is-main { background: var(--hd); border-color: var(--hd); color: #fff; }
.talk__next.is-main::after { color: #fff; }
.talk__next:hover { transform: translateY(-1px); }

/* 2つのCDの見分け: 通常盤はひなた色、初回仕様限定盤はあお色。札・帯・行き先で同じ色を使う */
:root { --cdn: #FFF1C2; --cdn-d: #E2B93B; --cdf: #DDE3F6; --cdf-d: #7C8FD0; }
.cdchip { display: inline-block; flex: none; margin-left: 8px; padding: 3px 7px 4px; border: 1.3px solid var(--ink); border-radius: 99px; font: 700 10.5px/1 var(--body); font-style: normal; color: var(--ink); white-space: nowrap; vertical-align: middle; }
.cdchip--normal { background: var(--cdn); }
.cdchip--first { background: var(--cdf); }
.talk__next .cdchip { margin: 0; }
.talk__next > span { flex: 1; }
.cdband { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 8px 14px; margin: 0 0 12px; padding: 9px 14px; border: 1.5px solid var(--ink); border-radius: var(--wob); color: var(--ink); text-decoration: none; }
.cdband--normal { background: var(--cdn); }
.cdband--first { background: var(--cdf); }
.cdband__name { font: 600 13px/1.3 var(--hand); }
.cdband__name b { margin: 0 3px; font-size: 16px; }
.cdband__flow { grid-column: 1 / -1; grid-row: 2; display: flex; flex-wrap: nowrap; gap: 4px 0; list-style: none; margin: 0; padding: 0; font: 600 12.5px/1.2 var(--hand); }
.cdband__flow li { margin: 0; padding: 5px 8px; white-space: nowrap; border: 1.3px solid var(--ink); border-radius: 5px; background: #fff; }
.cdband__flow li + li { margin-left: 22px; position: relative; }
.cdband__flow li + li::before { content: "→"; position: absolute; left: -18px; top: 3px; color: var(--ink); }
.cdband__flow li.is-pay { background: var(--berry); border-color: var(--berry); color: #fff; }
.cdband__flow li.is-pay::after { content: "￥"; margin-left: 4px; font-weight: 700; }
.cdband__more { font: 600 12px/1 var(--hand); text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.top__cds { margin-left: auto; padding: 5px 11px 6px; border: 1.5px solid var(--ink); border-radius: 99px; background: #fff; font: 600 12.5px/1.2 var(--hand); color: var(--ink); text-decoration: none; white-space: nowrap; }
.top__cds::before { content: ""; display: inline-block; width: 9px; height: 9px; margin-right: 13px; border-radius: 50%; background: var(--cdn-d); box-shadow: 7px 0 0 var(--cdf-d); vertical-align: 0; }
.top__cds + .top__tag { margin-left: 12px; }
body[data-point="cds"] .top__cds { animation: point 1.1s ease-in-out infinite; box-shadow: 0 0 0 5px color-mix(in srgb, var(--sun) 80%, transparent); }

/* 通常盤と初回仕様限定盤のちがい（動く絵） */
.cds { display: grid; gap: 12px; padding: 18px 18px 14px; background: #fff; border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 5px 5px 0 var(--paper-2); }
/* 上の舞台: 画面のイメージか、物の絵 */
.cds__stage { position: relative; height: 300px; border-radius: 9px; background: #fff; border: 1.5px dashed color-mix(in srgb, var(--ink) 35%, transparent); overflow: hidden; }
.cds__scene { position: absolute; inset: 0; display: grid; place-items: center; opacity: 0; transform: translateY(10px) scale(.97); transition: opacity .4s, transform .45s cubic-bezier(.3, 1.4, .5, 1); pointer-events: none; }
.cds__scene.is-on { opacity: 1; transform: none; }
.cds__mock { position: absolute; right: 10px; bottom: 6px; margin: 0; font-size: 11px; color: var(--ink-soft); }
.cds__img { width: auto; height: 250px; mix-blend-mode: multiply; }
.cds__pair { display: flex; gap: 40px; align-items: flex-end; }
.cds__pair figure { margin: 0; display: grid; justify-items: center; }
.cds__pair .cds__img { height: 215px; }
.cds__pair figcaption { display: grid; justify-items: center; font: 600 15px/1.4 var(--hand); }
.cds__pair figcaption b { font: 600 13px/1.5 var(--hand); color: var(--berry); }
.cds__solo { position: relative; display: grid; place-items: center; }
.cds__tag { position: absolute; right: -34px; top: 18px; padding: 3px 12px; border: 1.5px solid var(--ink); border-radius: 99px; background: var(--sun); font: 600 14px/1.5 var(--hand); transform: rotate(6deg); }
.cds__tag--pay { background: var(--berry); color: #fff; }
.cds__slip { position: absolute; right: -150px; bottom: 44px; display: grid; gap: 2px; padding: 10px 16px; background: #fff; border: 1.5px dashed var(--ink); border-radius: 4px; transform: rotate(-3deg); box-shadow: 3px 3px 0 var(--paper-2); }
.cds__slip small { font-size: 11px; color: var(--ink-soft); }
.cds__slip b { font: 700 16px/1.2 ui-monospace, monospace; letter-spacing: .06em; }
.cds__solo--ticket { transform: translateX(-70px); }
.cds__qr { position: absolute; right: -96px; bottom: 30px; display: grid; justify-items: center; gap: 4px; padding: 10px; background: #fff; border: 1.5px solid var(--ink); border-radius: 8px; transform: rotate(4deg); }
.cds__qr i { width: 58px; height: 58px; background: conic-gradient(var(--ink) 25%, #fff 0 50%, var(--ink) 0 75%, #fff 0) 0 0 / 14px 14px, #fff; border: 4px solid #fff; outline: 1.5px solid var(--ink); }
.cds__qr small { font-size: 10.5px; }
.cds__two { display: flex; gap: 22px; }
.cds__ticket { display: flex; align-items: center; gap: 6px; }
.cds__ticket .cds__img { height: 210px; }
.slip { width: 300px; padding: 10px 12px 10px; background: #fff; border: 1.5px solid var(--ink); box-shadow: 4px 4px 0 var(--paper-2); transform: rotate(-2deg); }
.slip__title { margin: 0; padding: 7px 8px; background: var(--ink); color: #fff; text-align: center; font: 700 12.5px/1.45 var(--body); }
.slip__lines { display: grid; gap: 5px; margin: 9px 2px; }
.slip__lines i { height: 4px; border-radius: 2px; background: color-mix(in srgb, var(--ink) 22%, transparent); }
.slip__lines i:last-child { width: 62%; }
.slip__foot { display: flex; align-items: stretch; gap: 10px; }
.slip__no { flex: 1; display: grid; gap: 3px; align-content: center; padding: 6px 10px; border: 1.5px solid var(--ink); }
.slip__no small { font-size: 10.5px; color: var(--ink-soft); }
.slip__no b { font: 700 15px/1.2 ui-monospace, monospace; letter-spacing: .04em; }
.slip__qr { flex: none; width: 58px; height: 58px; background: conic-gradient(var(--ink) 25%, #fff 0 50%, var(--ink) 0 75%, #fff 0) 0 0 / 12px 12px; border: 4px solid #fff; outline: 1.5px solid var(--ink); }
.cds__venue { display: flex; align-items: center; gap: 22px; }
.cds__venue .cds__img { height: 232px; }
.phone--qr { width: 160px; min-height: 250px; align-items: center; }
.phone--qr .phone__bar { align-self: stretch; }
.phone--qr .slip__lines { align-self: stretch; margin: 4px 6px 2px; }
.phone--qr .slip__qr { width: 96px; height: 96px; background-size: 16px 16px; margin: 4px 0; }
.phone--qr .phone__btn { align-self: stretch; background: #2FA89A; }
/* スマホの画面のイメージ（本物の申込みサイトの見た目はまねない） */
.phone { width: 210px; min-height: 236px; display: flex; flex-direction: column; gap: 7px; padding: 0 12px 14px; background: #fff; border: 2px solid var(--ink); border-radius: 22px; box-shadow: 4px 4px 0 var(--paper-2); font-size: 12.5px; }
.cds__two .phone { width: 168px; min-height: 190px; }
.phone__bar { margin: 0 -12px 2px; padding: 9px 0 7px; text-align: center; border-bottom: 1.5px solid var(--ink); border-radius: 20px 20px 0 0; background: var(--paper-2); font: 600 13px/1.3 var(--hand); }
.phone__row { display: flex; justify-content: space-between; gap: 8px; padding: 5px 8px; border: 1px solid color-mix(in srgb, var(--ink) 30%, transparent); border-radius: 6px; }
.phone__row span { color: var(--ink-soft); }
.phone__row b { font-weight: 700; text-align: right; }
.phone__btn { margin-top: auto; padding: 7px; text-align: center; border-radius: 99px; background: var(--ink); color: #fff; font: 600 13px/1.3 var(--hand); }
.phone__stamp { margin: auto; padding: 6px 22px; border: 2.5px solid currentColor; border-radius: 8px; font: 700 26px/1.3 var(--hand); transform: rotate(-6deg); }
.phone__stamp--win { color: var(--berry); }
.phone__stamp--lose { color: #6b7385; }
.phone__note { margin: 0; text-align: center; font: 600 12px/1.4 var(--hand); }
.phone__opts { display: grid; gap: 5px; }
.phone__opts span { padding: 5px 8px 5px 26px; border: 1px solid color-mix(in srgb, var(--ink) 30%, transparent); border-radius: 6px; position: relative; }
.phone__opts span::before { content: ""; position: absolute; left: 8px; top: 50%; width: 10px; height: 10px; margin-top: -6px; border: 1.5px solid var(--ink); border-radius: 50%; }
.phone__opts span.is-on { background: #E3E7F5; font-weight: 700; }
.phone__opts span.is-on::before { background: var(--ink); box-shadow: inset 0 0 0 2px #fff; }
.phone--call { align-items: center; }
.phone__face { flex: 1; display: grid; place-items: center; }
.phone__face img, .phone__face span { width: 120px; height: 120px; border-radius: 50%; border: 1.5px solid var(--ink); background: var(--paper); object-fit: cover; }
.phone__me { align-self: flex-end; }
.phone__me img { width: 46px; height: 46px; border-radius: 10px; border: 1.5px solid var(--ink); background: #fff; }
/* せりふ */
.cds__say { min-height: 5.2em; padding: 12px 16px; border: 1.5px solid var(--ink); border-radius: var(--wob); background: var(--paper); }
.cds__cap { margin: 0; font: 600 17px/1.7 var(--hand); }
.cds__note { margin: 4px 0 0; font-size: 13px; color: var(--ink-soft); }
.cds__note:empty { display: none; }
.cds__ctl { display: flex; align-items: center; gap: 12px; }
.cds__ctl .btn { flex: none; }
.cds__dots { flex: 1; display: flex; justify-content: center; gap: 5px; }
.cds__dots i { width: 8px; height: 8px; border-radius: 50%; border: 1.3px solid var(--ink); }
.cds__dots i.is-on { background: var(--ink); }
/* 下の道のり */
.cds__lane { display: grid; grid-template-columns: 128px 1fr; gap: 10px; align-items: center; padding: 50px 10px 30px; border-radius: 9px; transition: opacity .4s; }
.cds__lane--day { background: var(--cdn); }
.cds__lane--night { background: var(--cdf); }
.cds[data-on="day"] .cds__lane--night, .cds[data-on="night"] .cds__lane--day { opacity: .38; }
.cds__name { display: grid; gap: 2px; margin: 0; }
.cds__name b { font: 600 16px/1.2 var(--hand); }
.cds__name span { font-size: 11.5px; color: var(--ink-soft); }
.cds__road { position: relative; }
.cds__track { display: grid; grid-template-columns: repeat(var(--n), 1fr); list-style: none; margin: 0; padding: 0; position: relative; }
.cds__track::before { content: ""; position: absolute; left: calc(50% / var(--n)); right: calc(50% / var(--n)); top: 17px; border-top: 2.5px dashed color-mix(in srgb, var(--ink) 45%, transparent); }
.cds__track li { position: relative; display: grid; justify-items: center; align-content: start; gap: 5px; margin: 0; text-align: center; font: 600 12.5px/1.35 var(--hand); }
.cds__track i { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; border: 1.5px solid var(--ink); background: #fff; font: 700 13px/1 var(--body); font-style: normal; transition: transform .3s, background-color .3s; }
.cds__track li.is-here i { transform: scale(1.2); background: var(--sun); }
.cds__lane--night .cds__track li.is-here i { background: #BFCBF2; }
.cds__track li.is-pay span { color: var(--berry); }
.cds__token { position: absolute; top: -46px; left: calc((var(--pos, 0) + .5) * 100% / var(--n)); width: 40px; height: 40px; margin-left: -20px; opacity: 0; transition: left .9s cubic-bezier(.45, 1.4, .5, 1), opacity .3s; pointer-events: none; }
.cds__token img { width: 40px; height: 40px; border-radius: 50%; border: 1.5px solid var(--ink); background: #fff; animation: cds-walk .9s ease-in-out infinite; }
.cds__lane.is-started .cds__token { opacity: 1; }
@keyframes cds-walk { 50% { transform: translateY(-4px) rotate(-4deg); } }
.cds__coin { position: absolute; top: -12px; left: calc((var(--pay) + .5) * 100% / var(--n)); width: 26px; height: 26px; margin-left: 10px; display: grid; place-items: center; border-radius: 50%; background: var(--berry); color: #fff; font: 700 13px/1 var(--body); border: 1.5px solid var(--ink); transform: scale(0); transition: transform .45s cubic-bezier(.3, 1.7, .5, 1); }
.cds__lane.is-paid .cds__coin { transform: scale(1); }
.cds__lose { position: absolute; top: 100%; left: calc((var(--lose) + .5) * 100% / var(--n)); margin-top: 5px; transform: translateX(-50%); padding: 2px 10px; border-radius: 99px; border: 1.3px dashed var(--ink); background: #fff; font: 600 12px/1.5 var(--hand); white-space: nowrap; opacity: 0; transition: opacity .3s; }
.cds__lane.is-lose .cds__lose { opacity: 1; }
.cds.is-sum .cds__coin { animation: point 1s ease-in-out infinite; box-shadow: 0 0 0 5px color-mix(in srgb, var(--sun) 80%, transparent); }
.cds.is-sum .cds__track li.is-pay i { background: color-mix(in srgb, var(--berry) 22%, #fff); }
.cds__auto { margin: 0; text-align: center; }
.cds__auto button { background: none; border: 0; color: var(--hd); text-decoration: underline; text-underline-offset: 3px; font-size: 13px; cursor: pointer; }
.cds__ends { margin-top: 22px; }
@media (max-width: 640px) { .cds__lane { grid-template-columns: 1fr; padding-top: 44px; } .cds__track li { font-size: 12px; } }

.top__nav { display: none; }

/* 地図の下の家の一覧（スマホ）。地図では住人の顔だけを見せ、題とひとことはここで読む */
.hlist { list-style: none; padding: 0 !important; display: grid; gap: 10px; }
.hlist li { margin: 0 !important; }
.hcard { position: relative; display: flex; align-items: center; gap: 12px; padding: 11px 14px 12px; background: #fff; border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 3px 3px 0 var(--hc); color: var(--ink); text-decoration: none; -webkit-tap-highlight-color: transparent; }
.hcard:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--hc); }
.hcard__av { flex: none; display: flex; }
.hcard__av .av + .av { margin-left: -14px; }
.hcard__body { flex: 1; min-width: 0; display: grid; justify-items: start; gap: 1px; }
.hcard__owner { display: flex; align-items: center; font: 400 12px/1.5 var(--body); color: var(--ink-soft); }
.hcard__title { font: 600 17px/1.4 var(--hand); }
.hcard .murmur { position: static; margin-top: 5px; animation: none; }
.hcard .murmur::before, .hcard .murmur::after { display: none; }
.hcard .spot__seen { position: absolute; right: 10px; top: 10px; }
.hcard--board { background: var(--wash); }
.hcard--board::after { content: "→"; color: var(--hd); font: 600 16px/1 var(--hand); }

/* スマホ（縦長の画面）。地図は横長のまま幅いっぱいに出し、家の題は下の一覧で読む */
@media (max-width: 959px) {
  .top { gap: 8px; padding: 9px 14px; }
  .top__name { font-size: 15px; white-space: nowrap; }
  .top__cds { padding: 5px 9px 6px; font-size: 12px; }
  .top__cds + .top__tag { margin-left: 0; }
  .top__tag { white-space: nowrap; }
  .map--wide { max-width: none; margin: 4px -18px 0 !important; }
  .map--wide .murmur, .map--wide .spot:not(.spot--board) .spot__sign, .map--wide .spot__who > span:not(.av) { display: none; }
  .map--wide .spot__who { padding: 2px; background: var(--paper); border: 1.3px solid var(--ink); box-shadow: 2px 2px 0 var(--hc); }
  .map--wide .spot__who .av { width: 26px; height: 26px; margin: 0; }
  .map--wide .spot__who .av + .av { margin-left: -8px; }
  .map--wide .spot--board .spot__sign { padding: 2px 7px; font-size: 10.5px; box-shadow: 2px 2px 0 var(--hc); }
  .map--wide .spot--board small { display: none; }
  body[data-point="houses"] .spot:not(.spot--board) .spot__who { animation: point 1.1s ease-in-out infinite; }
  .talk--intro .vn__stage { height: 150px; }
  .talk--intro .vn__stage::after { width: 40px; height: 40px; }
  .talk--intro .vn__who .av { width: 92px; height: 92px; }
  .talk--intro .vn__box { min-height: 176px; }
  .cdband { padding: 9px 12px; }
  .cdband__flow { flex-wrap: wrap; gap: 6px 0; font-size: 12px; }
  .cdband__flow li { padding: 5px 7px; }
  .cdband__flow li + li { margin-left: 18px; }
  .cdband__flow li + li::before { left: -15px; }
  h1, h2 { word-break: auto-phrase; }
  .cds { padding: 14px 12px 12px; }
  .cds__ctl { gap: 8px; }
  .cds__ctl .btn { min-height: 44px; padding: 8px 14px; }
  .cds__dots { gap: 3px; min-width: 0; }
  .cds__dots i { flex: none; width: 6px; height: 6px; }
  /* 横に並ぶコマは、絵ごと縮めて舞台に収める */
  .cds__ticket, .cds__venue { zoom: .55; }
  .cds__two { zoom: .82; }
  .foot__links { flex-wrap: wrap; gap: 4px 16px; }
  .foot__links a { white-space: nowrap; }
  body[data-point="murmur"] .map--wide .spot__who { opacity: 1; }
  body[data-point="houses"] .hcard--board, body[data-point="board"] .hcard:not(.hcard--board) { opacity: .3; }
}

/* PC（横長の画面）。村は横長の絵地図、家のページは2段組み */
@media (min-width: 960px) {
  .top { padding: 12px 28px; gap: 22px; }
  .top__name { font-size: 18px; }
  .top__nav { display: flex; align-items: center; gap: 4px 22px; font: 600 14.5px/1.3 var(--hand); }
  .top__nav > a, .top__menu > summary { color: var(--ink-soft); text-decoration: none; padding: 3px 0; border-bottom: 2px solid transparent; cursor: pointer; }
  .top__nav > a:hover, .top__nav > a[aria-current], .top__menu > summary:hover, .top__menu[open] > summary, .top__menu > summary[data-current] { color: var(--ink); border-bottom-color: var(--hc); }
  .top__menu { position: relative; }
  .top__menu > summary { list-style: none; display: flex; align-items: center; gap: 6px; }
  .top__menu > summary::-webkit-details-marker { display: none; }
  .top__menu > summary::after { content: ""; width: 0; height: 0; border: 5px solid transparent; border-top: 6px solid currentColor; border-bottom: 0; transition: transform .15s; }
  .top__menu[open] > summary::after { transform: rotate(180deg); }
  .top__topics { position: absolute; left: -14px; top: calc(100% + 12px); z-index: 60; display: grid; grid-template-columns: repeat(2, 250px); gap: 6px; padding: 12px; background: var(--paper); border: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 5px 5px 0 var(--paper-2), 0 14px 40px rgba(60, 40, 20, .18); }
  .top__topics a { display: grid; gap: 2px; padding: 9px 12px; border-radius: 6px; border-left: 5px solid var(--hc); background: #fff; color: var(--ink); text-decoration: none; }
  .top__topics a:hover, .top__topics a[aria-current] { background: color-mix(in srgb, var(--hc) 28%, #fff); }
  .top__topics b { font: 600 15px/1.35 var(--hand); }
  .top__topics small { font: 400 12px/1.3 var(--body); color: var(--ink-soft); }
  .page { padding-top: 30px; }
  body[data-page="cast"] .page { max-width: 1120px; }
  .sheet { margin: auto; padding-bottom: 22px; border-bottom: 1.5px solid var(--ink); border-radius: var(--wob); box-shadow: 6px 6px 0 var(--paper-2), 0 20px 60px rgba(60, 40, 20, .25); }
  body[data-page="calendar"] .page { max-width: 1000px; }
  body[data-page="cds"] .page { max-width: 940px; }
  body[data-page="index"] .page { max-width: none; padding: 14px 28px 0; }
  .gate { display: flex; align-items: baseline; justify-content: center; gap: 20px; }
  .gate h1 { font-size: 30px; }
  .gate p { margin: 0; font-size: 15px; }
  .hlist { display: none; }
  .map--wide { display: block; max-width: min(1240px, calc((100vh - 150px) * 1.5)); }
  .spot__sign { font-size: 15.5px; padding: 8px 14px; box-shadow: 4px 4px 0 var(--hc); }
  .spot__title small { font-size: 12.5px; }
  .spot__who { font-size: 13px; padding: 2px 10px 2px 3px; }
  .spot__who .av { width: 30px; height: 30px; }
  .spot__seen { width: 19px; height: 19px; background-size: 14px; }
  .murmur { font-size: 13.5px; padding: 5px 12px; bottom: calc(100% - 20px); }
  .gate { flex-wrap: wrap; }
  .map--wide { transition: max-width .45s ease; }
  /* 入口の会話は画面の下に出し、地図をそのぶん小さくして全部見せる */
  .is-intro .map--wide { max-width: min(1240px, calc((100vh - 315px) * 1.5)); }
  .is-intro body { padding-bottom: 190px; }
  .map--wide .map__art, .map--wide .spot { transition: filter .6s, opacity .6s; }
  .is-intro.is-prologue .map--wide .map__art { filter: blur(7px) saturate(.5); opacity: .4; }
  .is-intro.is-prologue .map--wide .spot { opacity: 0; pointer-events: none; }
  .is-intro .spot__sign { font-size: 13px; padding: 5px 10px; }
  .is-intro .spot__who { font-size: 12px; }
  .is-intro .spot__who .av { width: 24px; height: 24px; }
  .is-intro .murmur { font-size: 12px; }
  .talk--intro { position: fixed; left: 50%; bottom: 16px; z-index: 30; width: min(900px, calc(100vw - 56px)); max-width: none; margin: 0 !important; transform: translateX(-50%); }
  .talk--intro .vn { display: grid; grid-template-columns: 230px 1fr; box-shadow: 5px 5px 0 var(--hc), 0 14px 40px rgba(60, 40, 20, .22); }
  .talk--intro .vn__place { left: 7px; top: 6px; font-size: 11px; padding: 4px 8px; }
  .talk--intro .vn__stage { height: auto; min-height: 168px; border-right: 1.5px solid var(--ink); }
  .talk--intro .vn__stage::before, .talk--intro .vn__stage::after { display: none; }
  .talk--intro .vn__cast { padding-bottom: 12px; }
  .talk--intro .vn__who .av { width: 96px; height: 96px; }
  .talk--intro .vn__box { min-height: 168px; padding: 16px 22px 54px; }
  .talk--intro .vn__text { font-size: 19px; }
  .talk--intro .vn__foot { position: absolute; right: 44px; bottom: 10px; margin: 0 !important; }
  .talk--intro .vn__toggle { display: none; }

  body[data-house] .page { max-width: 1180px; padding-inline: 32px; }
  .house { display: grid; grid-template-columns: minmax(0, 440px) minmax(0, 1fr); gap: 52px; align-items: start; }
  .house__side { position: sticky; top: 78px; }
  .house__main > :first-child { margin-top: 0; }
  .house__main > h2:first-child, .house__main > .jump + h2 { margin-top: 18px; }
  .jump { margin-inline: 0; padding-inline: 0; flex-wrap: wrap; overflow: visible; }
  .foot { max-width: 1180px; padding-inline: 32px; }
  .nav { left: 50%; right: auto; width: min(620px, 100%); transform: translateX(-50%); padding: 6px 16px; border: 1.5px solid var(--ink); border-bottom: 0; border-radius: 10px 9px 0 0; }
}

@media (prefers-reduced-motion: reduce) {
  .murmur, .murmur > span { animation: none; }
  .telop p { animation: none; }
  .cds__token, .cds__token img, .cds__coin, .cds__scene { transition: none; animation: none; }
  body[data-point] .spot__sign { animation: none; }
  .murmur > span:first-child { opacity: 1; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* 行の見出しを折り返さない表 */
.tbl--rowhead tbody th { white-space: nowrap; }
