/* ききとり（2026-11-05）。猫チームと進むゲーム。スマホを片手で・指1本で。押せる所は高さ52px以上・文字は16px以上 */
:root {
  --bg: #fff7ec; --card: #ffffff; --ink: #2d2620; --mute: #6b6158; --line: #eadfce;
  --ok: #1f7a55; --ok-soft: #e2f3ea; --ng: #b23a32; --ng-soft: #fbe6e3; --cond: #8a5a00; --cond-soft: #fdf1d8;
  --brand: #2f5d8a; --brand-soft: #e5eef8; --gold: #e3a52b; --r: 20px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --bg: #1d1a17; --card: #2a2622; --ink: #f4ede4; --mute: #b9ada1; --line: #3d3731; --ok: #7fd3aa; --ok-soft: #1f3a2d; --ng: #f2948c; --ng-soft: #432622; --cond: #f1c472; --cond-soft: #40331a; --brand: #9cc2ea; --brand-soft: #22324a; }
}
:root[data-theme="dark"] { --bg: #1d1a17; --card: #2a2622; --ink: #f4ede4; --mute: #b9ada1; --line: #3d3731; --ok: #7fd3aa; --ok-soft: #1f3a2d; --ng: #f2948c; --ng-soft: #432622; --cond: #f1c472; --cond-soft: #40331a; --brand: #9cc2ea; --brand-soft: #22324a; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 500 16px/1.7 "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "Yu Gothic UI", sans-serif; word-break: auto-phrase; line-break: strict; }
button { font: inherit; color: inherit; cursor: pointer; }
.g { min-height: 100dvh; max-width: 520px; margin: 0 auto; padding: 12px 16px 32px; display: flex; flex-direction: column; }

/* 頭：道のり */
.map { display: flex; align-items: center; gap: 4px; margin: 4px 0 14px; }
.map__s { flex: 1; text-align: center; font-size: 11px; color: var(--mute); line-height: 1.3; }
.map__s i { display: block; height: 8px; border-radius: 4px; background: var(--line); margin-bottom: 4px; }
.map__s.is-done i { background: var(--ok); }
.map__s.is-now i { background: var(--gold); }
.map__s.is-now { color: var(--ink); font-weight: 700; }

/* 猫と吹き出し */
.talk { display: flex; gap: 10px; align-items: flex-end; margin: 6px 0 14px; }
.cat { flex: none; width: 64px; height: 64px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 2px 8px rgba(0,0,0,.12); object-fit: cover; animation: hop 2.4s ease-in-out infinite; }
.cat--s { width: 44px; height: 44px; }
@keyframes hop { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.bubble { position: relative; background: var(--card); border: 2px solid var(--line); border-radius: 18px 18px 18px 6px; padding: 10px 14px; font-size: 15px; line-height: 1.65; }
.bubble b { color: var(--brand); }
.bubble small { display: block; color: var(--mute); font-size: 12px; margin-top: 2px; }
.cats { display: flex; justify-content: center; gap: 10px; margin: 16px 0; }
.cats img { width: 84px; height: 84px; }
.cats img:nth-child(2) { animation-delay: .3s; } .cats img:nth-child(3) { animation-delay: .6s; }

/* はじめに */
.h1 { font-size: 24px; font-weight: 800; line-height: 1.4; margin: 6px 0 6px; text-align: center; }
.sub { color: var(--mute); text-align: center; margin: 0 0 14px; font-size: 14px; }
.how { list-style: none; padding: 0; margin: 0 0 18px; display: grid; gap: 8px; }
.how li { display: flex; gap: 12px; align-items: center; background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 10px 14px; font-size: 15px; }
.how b { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--brand-soft); color: var(--brand); font-weight: 800; }

/* 例題のカード */
.qhead { display: flex; justify-content: space-between; align-items: center; font-size: 13px; color: var(--mute); margin-bottom: 6px; }
.card { background: var(--card); border: 3px solid var(--line); border-radius: var(--r); padding: 18px 16px 16px; text-align: center; box-shadow: 0 6px 0 var(--line); animation: pop .35s ease-out; }
@keyframes pop { from { transform: translateY(14px) scale(.97); opacity: 0; } to { transform: none; opacity: 1; } }
.card__after { display: inline-block; font-size: 13px; color: var(--mute); background: var(--bg); border-radius: 999px; padding: 2px 12px; }
.card__date { font-size: 30px; font-weight: 800; line-height: 1.3; margin: 8px 0 0; }
.card__time { font-size: 22px; font-weight: 700; margin: 0 0 10px; }
.card__part { font-size: 13px; color: var(--mute); margin: -8px 0 10px; }
.sym { display: inline-flex; align-items: center; gap: 10px; padding: 8px 14px; border-radius: 14px; background: var(--bg); font-size: 15px; }
.sym__m { font-size: 26px; font-weight: 800; line-height: 1; }
.sym--〇 .sym__m { color: var(--ok); } .sym--△ .sym__m { color: var(--cond); } .sym--× .sym__m { color: var(--ng); }
.q { text-align: center; font-weight: 700; font-size: 17px; margin: 16px 0 10px; }
.ans { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.btn { min-height: 56px; border-radius: 16px; border: 3px solid var(--line); background: var(--card); font-weight: 800; font-size: 17px; padding: 8px 12px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; box-shadow: 0 4px 0 var(--line); transition: transform .08s; }
.btn:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--line); }
.btn[disabled] { opacity: .5; cursor: not-allowed; }
.btn--ok { background: var(--ok-soft); border-color: var(--ok); color: var(--ok); box-shadow: 0 4px 0 var(--ok); min-height: 76px; font-size: 19px; }
.btn--ng { background: var(--ng-soft); border-color: var(--ng); color: var(--ng); box-shadow: 0 4px 0 var(--ng); min-height: 76px; font-size: 19px; }
.btn--ok .m, .btn--ng .m { font-size: 28px; line-height: 1; }
.btn--cond { grid-column: 1 / -1; min-height: 52px; font-size: 15px; background: var(--cond-soft); border-color: var(--cond); color: var(--cond); box-shadow: 0 3px 0 var(--cond); }
.btn--main { width: 100%; background: var(--brand); border-color: var(--brand); color: #fff; box-shadow: 0 4px 0 #1d3d5e; }
.btn--sub { width: 100%; }
.btn--wide { width: 100%; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn--main { color: #14202e; box-shadow: 0 4px 0 #5f86ad; } }

/* 読み当ての肉球 */
.paws { display: flex; align-items: center; gap: 8px; background: var(--card); border: 2px solid var(--line); border-radius: 16px; padding: 8px 12px; margin-bottom: 12px; }
.paws__t { font-size: 13px; line-height: 1.4; }
.paws__t b { display: block; font-size: 14px; }
.paws__row { display: flex; gap: 3px; margin-left: auto; }
.paw { width: 18px; height: 18px; border-radius: 50%; background: var(--line); position: relative; }
.paw.is-on { background: var(--gold); animation: pawpop .3s ease-out; }
@keyframes pawpop { 0% { transform: scale(.4); } 70% { transform: scale(1.25); } 100% { transform: scale(1); } }

/* 答え合わせ */
.reveal { margin-top: 14px; border-radius: 16px; padding: 12px 14px; display: flex; gap: 10px; align-items: center; animation: pop .3s ease-out; }
.reveal--hit { background: var(--ok-soft); color: var(--ok); }
.reveal--miss { background: var(--ng-soft); color: var(--ng); }
.reveal p { margin: 0; font-size: 15px; line-height: 1.55; }
.reveal small { display: block; color: var(--mute); font-size: 12px; }

/* 下から出る窓 */
.sheet { position: fixed; inset: 0; z-index: 30; background: rgba(0,0,0,.35); display: grid; place-items: end center; padding: 12px; }
.sheet__box { width: 100%; max-width: 520px; background: var(--card); border-radius: 22px; padding: 18px 16px 16px; animation: up .25s ease-out; }
@keyframes up { from { transform: translateY(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.sheet__t { margin: 0 0 10px; font-weight: 800; font-size: 17px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.chip { min-height: 44px; padding: 8px 14px; border-radius: 999px; border: 2px solid var(--line); background: var(--card); font-size: 15px; }
.chip[aria-pressed="true"] { border-color: var(--brand); background: var(--brand-soft); color: var(--brand); font-weight: 700; }
.input { width: 100%; min-height: 52px; border: 2px solid var(--line); border-radius: 14px; padding: 12px 14px; font: inherit; font-size: 16px; background: var(--card); color: var(--ink); resize: vertical; }
.input:focus { outline: 3px solid var(--brand-soft); border-color: var(--brand); }
.row2 { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }

/* まとめ */
.box { background: var(--card); border: 2px solid var(--line); border-radius: var(--r); padding: 14px 16px; margin-bottom: 12px; }
.box h2 { margin: 0 0 8px; font-size: 16px; }
.rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rules li { display: flex; gap: 10px; align-items: baseline; font-size: 15px; }
.tag { flex: none; padding: 1px 10px; border-radius: 999px; font-size: 13px; font-weight: 800; }
.tag--ok { background: var(--ok-soft); color: var(--ok); } .tag--ng { background: var(--ng-soft); color: var(--ng); } .tag--cond { background: var(--cond-soft); color: var(--cond); }
.none { color: var(--mute); font-size: 14px; margin: 0; }

/* カレンダー */
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 13px; color: var(--mute); margin: 0 0 10px; }
.cal { width: 100%; border-collapse: separate; border-spacing: 4px; }
.cal th { font-size: 12px; color: var(--mute); font-weight: 700; }
.cal td.d { font-size: 14px; white-space: nowrap; padding-right: 4px; }
.cell { width: 100%; min-height: 48px; border-radius: 12px; border: 2px solid var(--line); background: var(--card); font-size: 20px; font-weight: 800; line-height: 1; }
.cell--ok { background: var(--ok-soft); border-color: var(--ok); color: var(--ok); }
.cell--ng { background: var(--ng-soft); border-color: var(--ng); color: var(--ng); }
.cell--q { color: var(--mute); }
.cell--off { background: transparent; border-style: dashed; color: var(--mute); font-size: 12px; cursor: default; }
.cell.is-changed { outline: 3px solid var(--gold); outline-offset: 1px; }
.cell small { display: block; font-size: 10px; font-weight: 700; margin-top: 2px; }

/* クリア */
.clear { text-align: center; padding-top: 18px; }
.clear .h1 { font-size: 30px; color: var(--brand); }
.confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 40; }
.confetti i { position: absolute; top: -12px; width: 9px; height: 14px; border-radius: 2px; animation: fall 2.6s linear forwards; }
@keyframes fall { to { transform: translateY(110vh) rotate(540deg); } }
.err { color: var(--ng); font-weight: 700; }
.foot { margin-top: auto; padding-top: 20px; text-align: center; font-size: 12px; color: var(--mute); }
.space { height: 10px; }
@media (prefers-reduced-motion: reduce) { .cat, .card, .reveal, .paw.is-on, .sheet__box { animation: none; } .confetti { display: none; } }

/* 2026-11-05 改行：決まりの文は「、」と空白でだけ折る（「受｜けています」を防ぐ）。吹き出しは行末をそろえる */
.rules li span, .reveal small, .paws__t { word-break: keep-all; overflow-wrap: anywhere; }
.bubble, .sub, .how li span { text-wrap: pretty; }
.how strong { color: var(--brand); }

/* 2026-11-05 決め手と、本当の予定のカード */
.picks { display: grid; gap: 10px; margin: 0 0 12px; }
.pick { justify-content: flex-start; text-align: left; font-size: 17px; }
.lines { list-style: none; margin: 4px 0 0; padding: 0; display: grid; gap: 6px; text-align: left; }
.line { display: flex; justify-content: space-between; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--bg); font-size: 14px; }
.line span { color: var(--mute); }
.line b { font-size: 16px; white-space: nowrap; }
.line--ok b { color: var(--ok); } .line--ng b { color: var(--ng); }

/* 2026-11-05 戻る */
.btn--back { background: transparent; box-shadow: none; border-color: var(--line); color: var(--mute); font-size: 15px; font-weight: 700; min-height: 52px; }
.backrow { margin: 12px 0 0; text-align: center; }
.backrow .btn--back { border: 0; min-height: 44px; text-decoration: underline; text-underline-offset: 4px; }
.toast { position: fixed; left: 50%; bottom: 20px; transform: translateX(-50%); max-width: calc(100% - 32px); background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-size: 14px; z-index: 50; }
